How to use the @pluralsight/ps-design-system-theme/react.names.dark 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 / index.js View on Github external
decorator: ({ themeName }) => {
    const base = css({
      overflow: 'auto',
      width: '100%',
      height: '100vh',
      transition: `background ${core.motion.speedNormal}`,
      backgroundSize: 'cover',
      background: 'transparent'
    })

    const theme = css(
      themeName === names.dark && { background: core.colors.gray06 },
      themeName === names.light && { background: core.colors.bone }
    )

    return compose(
      base,
      theme
    )
  }
}