Skip to content

aaron-nance/skin-react

 
 

Repository files navigation

Build Status

skin-react

Skin components built with React (Typescript). https://github.com/eBay/skin

Components

Install

$ yarn add skin-react
$ yarn add @ebay/skin

Why

skin-react eases the use of the original skin for developers who are more conversant with Rx style programming by condensing it into React-styled components.

html skin

<button class="btn btn--primary">
    <span class="btn__cell">
        <svg aria-hidden="true" focusable="false" class="icon icon--menu btn__icon">
          <use xlink:href="#icon-menu"></use>
        </svg>
        <span>Button</span>
    </span>
</button>

skin-react

import * as React from 'react';
import {Button, BtnCell, Icon} from 'skin-react';

function Example() {
  return (
    <Button btnColor="primary" >
        <BtnCell>
          <Icon className="btn__icon" iconType="menu" />
          <span>Button</span>
        </BtnCell>
    </Button>
  )
}

Usage

import * as React from 'react';
import * as ReactDOM from 'react-dom';
import { Spinner } from 'skin-react';

ReactDOM.render(
    <div>
      <Spinner />
    </div>,
  document.getElementById('root')
);

Stylesheets

stylesheet is required to use these components.

    //The following line can be included in your root .js/ts file
    import '@ebay/skin/dist/spinner/ds6/spinner.css';

Accessibility (A11Y)

We take accessibility very seriously. Very seriously indeed. Therefore all modules are built in accordance to the eBay MIND Patterns. These patterns, in turn, build on from the specifications provided by the WAI-ARIA Authoring Practices.

Issues

Please use our issues page to ask questions, report issues or submit feature requests. To help track your issue, the team will assign it with a label from one or more issue categories.

Developing & Contributing

Interested in contributing? Head over to our contributing guide for information on how to get started.

Contributions don't have to be code! They can be ideas, inspiration, discussion or filing bugs!

License

Copyright 2019 eBay Inc. Developers: Arturo Montoya, Jake Hall

Use of this source code is governed by an MIT-style license that can be found in the LICENSE file or at https://opensource.org/licenses/MIT.

About

Skin components built with React (Typescript)

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 71.7%
  • CSS 25.1%
  • JavaScript 3.2%