How to use the @edtr-io/ui.styled.select function in @edtr-io/ui

To help you get started, we’ve selected a few @edtr-io/ui 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 edtr-io / edtr-io / packages / plugin-text / src / toolbar / dropdown.tsx View on Github external
import { styled, ThemeProps } from '@edtr-io/ui'

import { createTextPluginTheme } from '..'

export const Dropdown = styled.select(
  (props: { name: string } & ThemeProps) => {
    const theme = createTextPluginTheme(props.name, props.theme)
    return {
      backgroundColor: theme.backgroundColor,
      cursor: 'pointer',
      color: theme.color,
      outline: 'none',
      height: '25px',
      border: 'none',
      borderRadius: '4px',
      margin: '5px',
      '&:hover': {
        color: theme.hoverColor
      }
    }
  }
github edtr-io / edtr-io / packages / plugins / text / src / toolbar / dropdown.tsx View on Github external
import { styled } from '@edtr-io/ui'

import { TextConfig } from '..'

export const Dropdown = styled.select<{ config: TextConfig }>(props => {
  const { theme } = props.config
  return {
    backgroundColor: theme.backgroundColor,
    cursor: 'pointer',
    color: theme.color,
    outline: 'none',
    height: '25px',
    border: 'none',
    borderRadius: '4px',
    margin: '5px',
    '&:hover': {
      color: theme.hoverColor
    }
  }
})