How to use the react-fela.createComponentWithProxy function in react-fela

To help you get started, we’ve selected a few react-fela 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 Kilix / selectless / stories / fela.js View on Github external
() => ({
    zIndex: 9,
    pointerEvents: 'none',
    position: 'absolute',
    top: 0,
    left: 0,
    width: '100%',
    height: 36,
    padding: 8,
    fontSize: '16px',
    color: '#333',
  }),
  Label
)

const Flear = createComponentWithProxy(
  () => ({
    zIndex: 12,
    position: 'absolute',
    top: 0,
    right: 15,
    height: 36,
    lineHeight: '36px',
    opacity: 0.3,
    cursor: 'pointer',
    transition: 'opacity .3s ease-out',
    ':hover': {
      opacity: 1,
    },
  }),
  Clear
)
github Kilix / selectless / stories / basics.js View on Github external
top: 0,
    right: 5,
    height: '100%',
    width: 15,
    padding: 0,
    color: '#B3B3B3',
    backgroundColor: 'transparent',
    outline: 'none',
    border: 'none',
    padding: 4,
    transition: 'transform .1s ease',
    transform: opened ? 'rotate(180deg)' : 'rotate(0deg)',
  }),
  'button'
)
const Clear = createComponentWithProxy(
  () => ({
    zIndex: 11,
    display: 'flex',
    justifyContent: 'center',
    alignItems: 'center',
    position: 'absolute',
    top: 0,
    right: 20,
    height: '100%',
    width: 15,
    padding: 0,
    marginTop: -4,
    fontSize: '25px',
    color: '#B3B3B3',
    backgroundColor: 'transparent',
    outline: 'none',
github Kilix / selectless / stories / basics.js View on Github external
position: 'absolute',
    top: 0,
    left: 0,
    width: '100%',
    height: 36,
    border: 'none',
    outline: 'none',
    padding: '0 8px',
    backgroundColor: '#FAFAFA',
    fontFamily: 'sans-serif',
    fontSize: 14,
    fontWeight: 'normal',
  }),
  'input'
)
const L = createComponentWithProxy(
  ({color}) => ({
    position: 'absolute',
    top: 0,
    left: 0,
    width: '100%',
    height: 36,
    lineHeight: '36px',
    padding: '0 8px',
    pointerEvents: 'none',
    fontFamily: 'sans-serif',
    fontSize: 14,
    fontWeight: 'normal',
    color,
  }),
  'label'
)
github Kilix / selectless / stories / fela.js View on Github external
top: -2,
    width: '100%',
    maxHeight: 150,
    overflow: 'auto',
    backgroundColor: '#fff',
    color: '#333',
    fontFamily: 'sans-serif',
    fontWeight: 'normal',
    borderRadius: '0 0 4px 4px',
    border: '1px solid #ccc',
    borderColor: '#d9d9d9 #ccc #b3b3b3',
  }),
  List
)

const Ftem = createComponentWithProxy(
  ({isSelected, isCurrent}) => ({
    padding: 8,
    cursor: 'pointer',
    backgroundColor: isSelected || isCurrent ? '#232323' : '#FFF',
    color: '#B3B3B3',
    transition: 'all .3s ease-out',
    ':hover': {
      color: '#333',
      backgroundColor: '#D9D9D9',
    },
  }),
  Item
)

storiesOf('Fela', module).addDecorator(felaProvider).add('Basic callback', () =>
  <div style="{{width:"></div>
github Kilix / selectless / stories / fela.js View on Github external
border: '1px solid #ccc',
  color: '#333',
  cursor: 'default',
  display: 'table',
  borderSpacing: '0',
  borderCollapse: 'separate',
  height: '36px',
  outline: 'none',
  overflow: 'hidden',
  position: 'relative',
  fontFamily: 'sans-serif',
  fontWeight: 'normal',
  width: '100%',
}))

const Fabel = createComponentWithProxy(
  () => ({
    zIndex: 9,
    pointerEvents: 'none',
    position: 'absolute',
    top: 0,
    left: 0,
    width: '100%',
    height: 36,
    padding: 8,
    fontSize: '16px',
    color: '#333',
  }),
  Label
)

const Flear = createComponentWithProxy(
github Kilix / selectless / stories / basics.js View on Github external
'opened',
  'selectedValue',
  'searchValue',
  'sourceOptions',
  'toggleCaseSensitive',
  'toggleSearch',
  'toggleSelect',
  'transform',
])

const felaProvider = story =&gt;
  
    {story()}
  

const I = createComponentWithProxy(
  () =&gt; ({
    position: 'absolute',
    top: 0,
    left: 0,
    width: '100%',
    height: 36,
    border: 'none',
    outline: 'none',
    padding: '0 8px',
    backgroundColor: '#FAFAFA',
    fontFamily: 'sans-serif',
    fontSize: 14,
    fontWeight: 'normal',
  }),
  'input'
)
github Kilix / selectless / stories / basics.js View on Github external
}),
  'button'
)

const Ul = createComponentWithProxy(() => ({
  fontFamily: 'sans-serif',
  fontSize: 14,
  fontWeight: 'normal',
  backgroundColor: '#FAFAFA',
  borderTop: '1px solid #333',
  borderBottomLeftRadius: 3,
  borderBottomRightRadius: 3,
  overflow: 'auto',
  maxHeight: 200,
}))
const Li = createComponentWithProxy(
  ({color}) => ({
    display: 'flex',
    justifyContent: 'flex-start',
    alignItems: 'center',
    height: 38,
    paddingLeft: 8,
    color: color,
    borderBottom: '1px solid #F1F1F1',
    cursor: 'pointer',
    transition: 'all .3s ease-out',
    ':hover': {paddingLeft: 14, color},
  }),
  'div'
)

const SlideIn = createComponentWithProxy(({opened}) => ({
github robinweser / fela / examples / example-react / components / Header.js View on Github external
'@supports (-webkit-flex:1)': {
      fontSize: 180,
    },
    fontSize: '40px',
  },
  animationDuration: '2s',
  animationIterationCount: 'infinite',
  animationName: {
    '0%': { color: 'green' },
    '50%': { color: 'blue' },
    '80%': { color: 'purple' },
    '100%': { color: 'green' },
  },
})

export default createComponentWithProxy(rule, Header)
github Kilix / selectless / stories / basics.js View on Github external
({color}) => ({
    display: 'flex',
    justifyContent: 'flex-start',
    alignItems: 'center',
    height: 38,
    paddingLeft: 8,
    color: color,
    borderBottom: '1px solid #F1F1F1',
    cursor: 'pointer',
    transition: 'all .3s ease-out',
    ':hover': {paddingLeft: 14, color},
  }),
  'div'
)

const SlideIn = createComponentWithProxy(({opened}) => ({
  overflow: 'hidden',
  height: opened ? 300 : 0,
  transition: 'height .2s ease',
}))
const SearchLabel = enhance(
  ({
    clearSearchValue,
    clearValue,
    hasSearch,
    onChangeSearchValue,
    searchValue,
    toggleCaseSensitive,
    toggleSearch,
    toggleSelect,
    selectedValue,
    placeholder,
github Kilix / selectless / stories / fela.js View on Github external
Label,
  Search,
  List,
  TagList,
  Tag,
  controller,
} from '../src'

const renderer = createRenderer()

const felaProvider = story =&gt;
  
    {story()}
  

const SelectContainer = createComponentWithProxy(() =&gt; ({
  backgroundColor: '#fff',
  borderColor: '#d9d9d9 #ccc #b3b3b3',
  borderRadius: '4px',
  border: '1px solid #ccc',
  color: '#333',
  cursor: 'default',
  display: 'table',
  borderSpacing: '0',
  borderCollapse: 'separate',
  height: '36px',
  outline: 'none',
  overflow: 'hidden',
  position: 'relative',
  fontFamily: 'sans-serif',
  fontWeight: 'normal',
  width: '100%',