How to use the @instructure/ui-react-utils/lib/pickProps.pickProps function in @instructure/ui-react-utils

To help you get started, we’ve selected a few @instructure/ui-react-utils 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 instructure / instructure-ui / packages / ui-toggle-details / src / components / ToggleGroup / index.js View on Github external
render () {
    const Element = getElementType(ToggleGroup, this.props)

    return (
      
      {({ expanded, getToggleProps, getDetailsProps }) => {
        return (
github instructure / instructure-ui / packages / ui-toggle-details / src / components / ToggleDetails / index.js View on Github external
variant,
      iconPosition,
      fluidWidth
    } = this.props

    const positionIconAtEnd = iconPosition === 'end' && (variant === 'filled' || fluidWidth)

    const classes = {
      [styles.root]: true,
      [styles[this.props.size]]: true,
      [styles.positionIconAtEnd]: positionIconAtEnd
    }

    return (
      
      {({ expanded, getToggleProps, getDetailsProps}) => {
        return (
          <div>
            {this.renderToggle(getToggleProps(), expanded)}
            {this.renderDetails(expanded, getDetailsProps())}
          </div>
        )
      }}
      
    )
  }
}