'Wix Style' is a common name to the different UX style libraries designed by the UX guild (for dashboard, settings, editor, and viewer). The wix-style-react package contains React implemenations for the different components in the style library.
Storybook can be seen here.
Storybook will allow you to see all the different components implemented, and the different usages of each one of them.
npm installnpm start
npm install --save wix-style-react
This library depends on watchman, please install it from here
The files are brought 'uncompiled' and 'unpacked'. You will need to make sure webpack standard loaders run on this project by adding 'node_modules/wix-style-react/src' to your loaders' include array, for example:
generateScopedName: '[path][name]__[local]__[hash:base64:5]'extensions: '.scss' '.css'camelCase: true;
The scope name pattern has to be the same as in the webpack.config file
loaders:test: /\.jsx?$/loader: 'babel-loader'include:path
test: /\.$/loader: 'file-loader'
package json - dependency "images-require-hook": "^1.0.3",
Please refer to the specific elements for code-based examples of how to use this library, e.g., Button
For wix-js stack projects no config needed just use
import Button from 'wix-style-react/dist/src/Button';
See the Storybook, and the story fields, for all the elements and the different parameters they receive.
Important: Make sure your body contains either the 'ltr' or 'rtl' class (dependent, of course, on the displayed language).
This project is currently still in initial development. It is advisable to be dependent on a specific version of this component for the time being.
Please refer the Testing page
Please refer the Contribution page
This project is offered under MIT License.