How to use the @pluralsight/ps-design-system-theme/react.names function in @pluralsight/ps-design-system-theme

To help you get started, we’ve selected a few @pluralsight/ps-design-system-theme examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github pluralsight / design-system / packages / storybook-addon-theme / src / swatch.js View on Github external
function handleClick(evt) {
    onSelect(evt, name)
  }

  return (
    
      
      
        <title>{name}</title>
      
    
  )
}

Swatch.propTypes = {
  name: PropTypes.oneOf(Object.values(Theme.names)).isRequired,
  onSelect: PropTypes.func.isRequired
}

const Container = props =&gt; <button>

const Preview = props =&gt; <div>

const Info = props =&gt; <div>

const Title = props =&gt; <h2>

Title.propTypes = {
  children: PropTypes.string.isRequired
}
</h2></div></div></button>