• Stars
    star
    164
  • Rank 230,032 (Top 5 %)
  • Language
    JavaScript
  • License
    GNU General Publi...
  • Created over 7 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

The VTEX Design System and React component library.

Styleguide

VTEX Styleguide React components (Docs)

Usage

For instructions on how to use the Styleguide in your project refer to the page itself: https://vtex.github.io/styleguide/.

Developing

Setup

yarn install

Running

yarn styleguide

Storybook

We use Storybook environment to help us build and test our components in real time. You can edit the Playground file and add the components you are working on, after this run the command below to see your changes in http://localhost:6006/ :

yarn storybook

If you want to change or add stories, take a look at this guide before.

Developing using npm link

Run this in this repo:

yarn develop

In your project run:

npm link @vtex/styleguide

Import (case a <Button> component in lib):

import Button from '@vtex/styleguide/lib/Button'

Testing

Developing new tests

To add tests to a component, just add a test file with the .test.js extension next to the component implementation.

Example:

react/components/Alert/
โ”œโ”€โ”€ README.md
โ”œโ”€โ”€ index.js
โ””โ”€โ”€ index.test.js

We use react-testing-library to test our components.

Running tests

To run the test use:

yarn test

You can also pass the --watch flag:

yarn test --watch

Publishing


To post the changelog on Github Release Notes, is required to configure a Personal Token. See more here

We use releasy to publish our styleguide. To publish on both npm and render(VTEX IO) with Github Release Notes, execute the command below:

releasy --stable

Docs

To update the docs:

yarn deploy

Known issues

  • Your project has to run with webpack >= 2. Here's a guide for upgrading Webpack to v2.

  • VTEX Styleguide is a project built to run on top of either npm or VTEX IO. To make this viable, we currently use two package.json files, one in the top repository folder for npm, and one inside the react folder for VTEX IO. We are looking into how we can improve this architecture, but for now we have to live with duplicated dependencies in these package.json files.

    For more info, please refer to #483

  • We currently have two majors of the Styleguide, 8.x and 9.x (master branch). Each major supports a specific VTEX's Render version. This means that we develop new features only on the master branch (9.x major) and do bug fixes on both master and 8.x branches.

Custom icons

The icon components supports customization through the <use> element available in SVG. Read more

How to use: In the same page that has a icon, load in any place inside the <html> a SVG with the following structure:

<svg class="dn" height="0" version="1.1" width="0" xmlns="http://www.w3.org/2000/svg">
  <defs>
    <g id="icon-columns">
      <path d="M10.8 4.4L9.4 3L5.4 7L3.4 5L2 6.4L5.4 9.8L10.8 4.4Z" fill="currentColor" />
    </g>
    <g id="OTHER-ICON-ID">
      <path d="M11.7 0.3C11.5 0.1 11.3 0 11 0H10V3C10 3.6 9.6 4 9 4H4C3.4 4 3 3.6 3 3V0H1C0.4 0 0 0.4 0 1V15C0 15.6 0.4 16 1 16H15C15.6 16 16 15.6 16 15V5C16 4.7 15.9 4.5 15.7 4.3L11.7 0.3ZM13 14H3V11C3 10.4 3.4 10 4 10H12C12.6 10 13 10.4 13 11V14Z" fill="currentColor"/>
      <path d="M9 0H7V3H9V0Z" fill="currentColor"/>
    </g>
  </defs>
</svg>
  • The ID must match the ID of the icon you want to replace. To see all available options, view icons folder.
  • Inside one SVG you can have more than one <g id="">, one for each icon you want to update.

More Repositories

1

faststore

Digital commerce toolkit for frontend developers
TypeScript
185
star
2

react-hook-form-jsonschema

๐Ÿš€ Lightweight project that exposes an API for easily creating customizable forms with built-in validation based on a JSON Schema.
TypeScript
177
star
3

vtex.js

VTEX SDK for JavaScript
CoffeeScript
114
star
4

openapi-schemas

OpenAPI 3.0 JSON schemas. Files are automatically synced to the VTEX Developer Portal.
JavaScript
102
star
5

node-vtex-api

VTEX IO API Client for Node
TypeScript
75
star
6

speed

VTEX Store development tools - reverse proxy, compilation, minification, optimization and more!
CoffeeScript
61
star
7

toolbelt

CLI for creating and managing VTEX apps
TypeScript
59
star
8

front.phone

front.phone is a Javascript library that identifies, validates and formats phone numbers.
CoffeeScript
58
star
9

releasy

CLI tool to release node applications with tag and auto semver bump
JavaScript
55
star
10

typescript

VTEX's TypeScript tools, style guide and best practices
JavaScript
54
star
11

test-tools

Add tests to your VTEX IO app in an instant ๐Ÿš€
TypeScript
51
star
12

becoming-a-driver

VTEX's Engineering Individual Contributors Career Track
Smarty
50
star
13

react-csv-parse

Import data from a csv file to your app and your api.
JavaScript
43
star
14

country-iso-3-to-2

Convert a country code ISO 3166-1 Alpha 3 to ISO 3166-1 Alpha 2
JavaScript
33
star
15

vtex-emails

Email framework for developing transactional email templates for VTEX E-commerces
Handlebars
33
star
16

front.portal-plugins

Portal front end plugins
CoffeeScript
32
star
17

country-iso-2-to-3

Convert a country code ISO 3166-1 Alpha-2 to ISO 3166-1 Alpha-3
JavaScript
30
star
18

dotfiles

Mac OSX Developer Setup
Shell
28
star
19

io-clients

TypeScript
27
star
20

address-form

A React component that renders VTEX's address forms
TypeScript
24
star
21

react-jsonschema-table

React component for generating a Table using JSON Schema specification
JavaScript
21
star
22

msk

Small library to mask strings
JavaScript
21
star
23

shoreline

VTEX Design System for back-office experiences. Currently available for internal usage at VTEX.
TypeScript
20
star
24

vtex-courses

TypeScript
20
star
25

splunkevents-js

Javascript lib to create Splunk Logs via HTTP
TypeScript
19
star
26

development-guidelines

Development Guidelines
17
star
27

vtex-tachyons

Functional CSS for humans โ€” customized by the VTEX team
HTML
17
star
28

tortin

Tortin is a responsive theme for GitHub Pages with color options
CSS
16
star
29

github-pull-request-script

This script automates the process of creating pull requests with specific changes in multiple repositories.
TypeScript
15
star
30

exercise-tdd-javascript

Problem-solving with Test Driven Development and Javascript
JavaScript
14
star
31

speedbag

The no-nonsense front end boilerplate
HTML
14
star
32

intl-equalizer

๐Ÿ‘ฏโ€โ™‚๏ธ
JavaScript
11
star
33

andromedocs

andromedocs provides simple yet flexible tools for documenting Design Systems.
TypeScript
10
star
34

micro

A full-lifecycle meta-framework for fast web apps.
TypeScript
9
star
35

front.messages

jQuery and Bootstrap based messages plugin
CoffeeScript
9
star
36

findhelp

A simple and hackable lib to create modular CLI's
JavaScript
9
star
37

action-sonarqube

A Github action that runs the SonarScanner and adds SonarQube Issues as annotations in your pull requests.
TypeScript
9
star
38

ng-currency-mask

CoffeeScript
9
star
39

danger-plugin-keepachangelog

Makes changes to CHANGELOG consistent with keepachangelog standard
TypeScript
8
star
40

grunt-vtex

A Grunt convention-over-configuration meta-project
CoffeeScript
8
star
41

payment-mocker

A boilerplate to develop and test a Payment Method to VTEX Smart Checkout
CSS
8
star
42

action-toolbelt

This action deploys, cache for faster deploy, and do a login on VTEX Toolbet tool to automate CI/CD pipelines on GitHub
Shell
8
star
43

mkp-app-template

TypeScript
7
star
44

front.utils

VTEX Underscore extensions
CoffeeScript
7
star
45

FeedConsumerCSharp

A consumer boilerplate to VTEX Feed v3
C#
7
star
46

tachyons-generator

Generate a custom Tachyons build from a json configuration
JavaScript
6
star
47

action-io-app-test

Github action to run tests in VTEX IO Apps
JavaScript
6
star
48

show-time

a simple countdown timer powered by vtex-io
JavaScript
6
star
49

cron.js

JavaScript
6
star
50

workshop-react-native

Workshop to teach React Native by doing a Todo App
JavaScript
6
star
51

front.libs

Shared front end libs
CoffeeScript
6
star
52

profile-form

React component for managing user profiles
JavaScript
6
star
53

action-toolbelt-login

Perform login with VTEX Toolbelt using App Key/Token
TypeScript
6
star
54

danger

A opinionated danger.js configurable rule set and a companion github action
JavaScript
6
star
55

hyper-cas

hyper-cas is a Content-Addressable Storage aimed at JAMStack websites.
Go
6
star
56

admin-ui-example

Admin app example for the admin v4 with the admin-ui design system
TypeScript
5
star
57

ux-writing

UX Writing guidelines
JavaScript
5
star
58

formula-vtex

Site da Hackaton da VTEX
HTML
5
star
59

action-lint

Github action to optionally lint a project
JavaScript
5
star
60

delivery-packages

Small library to separate items in packages
JavaScript
5
star
61

vtex-copy-cart-example

This is an example of how to copy a cart and send it to inStore as checkout
JavaScript
5
star
62

pickup-points-modal

JavaScript
5
star
63

generator-vtex

Create a VTEX app
JavaScript
4
star
64

angular-google-analytics

Google Analytics wrapper for Angular
JavaScript
4
star
65

lens

VTEX Development Tools as Chrome Extension
CoffeeScript
4
star
66

estimate-calculator

Small library to calculate and compare SLAs' shippingEstimate
JavaScript
3
star
67

academy

Site pรบblico do programa de estรกgio da VTEX - http://academy.vtex.com
HTML
3
star
68

faststore-vtex-integrations

CSS
3
star
69

lean-shipping-calculator

JavaScript
3
star
70

react-tree-path

React decorator to uniquely identify components in a render tree.
JavaScript
3
star
71

render-extension-loader

JavaScript lib to fetch and render a Render extension point in a given DOM element
TypeScript
3
star
72

intl-container

A React component for loading i18n translations and intl locale data
JavaScript
3
star
73

interviews-mock-api

Mock API to server Interviews data
2
star
74

version-map

An easy-to-use package for manipulating version maps in S3.
CoffeeScript
2
star
75

react-address-book

Address book front end component made with React, Webpack and CommonJS
JavaScript
2
star
76

css-handles

TypeScript
2
star
77

api.protocol

Shell
2
star
78

checkout-ui-payment-guide

Guia de integraรงรฃo de meios pagamentos com a UI do Smart Checkout
HTML
2
star
79

act

A git-based configuration management and evolution tool
TypeScript
2
star
80

go-io

Collection of general-purpose packages for writing scalable go services.
Go
2
star
81

php-connector

Attempt to set up a REST API that passes the PPP tests
PHP
2
star
82

angular-intercom

Intercom wrapper for Angular
JavaScript
2
star
83

angular-locale

CoffeeScript
2
star
84

electron-cappta-debug

A simple repo for testing cappta checkout on VTEX
JavaScript
2
star
85

grunt-defaults

Grunt config mixins
CoffeeScript
2
star
86

pino-splunk-events

TypeScript
1
star
87

i18n-iso

Flexible, future proof and easy to use localization library based on the ISO language set standards
TypeScript
1
star
88

admin-assembly-options

TypeScript
1
star
89

vtex-ng-pagination

angular pagination module
JavaScript
1
star
90

eslint-config-vtex-react

JavaScript
1
star
91

search-tests

JavaScript
1
star
92

tsconfig

1
star
93

cli-plugin-support

TypeScript
1
star
94

cli-plugin-edition

TypeScript
1
star
95

git-tag-match

Check if the git tag matches package.json version
JavaScript
1
star
96

academy-guide

Guia de como estruturar e executar um VTEX Academy
1
star
97

camp

VTEX guides for on-boarding new engineers.
1
star
98

vtex.github.io

Organization GitHub page for VTEX
HTML
1
star
99

action-internal-docs

GitHub Action to automatically publish your documentation to VTEX Tech Docs
TypeScript
1
star
100

cli-plugin-submit

TypeScript
1
star