Sha256: b32ffd8f71db39eaec64ec7facac4e957d208576b2e1468d086a6130b5255587

Contents?: true

Size: 820 Bytes

Versions: 112

Compression:

Stored size: 820 Bytes

Contents

/* @flow */

import React, { Node } from 'react'
import classnames from 'classnames'

import { globalProps } from '../../utilities/globalProps'

import Card from '../../pb_card/_card'

type FilterBackgroundProps = {
  background: boolean,
  className: string,
  children: Node,
  dark: boolean,
}

const FilterBackground = (props: FilterBackgroundProps) => {
  const { background = true, className, children, dark } = props

  return (
    <div className={classnames(`pb_filter_kit ${className}`, globalProps(props))}>
      <Choose>
        <When condition={background}>
          <Card
              dark={dark}
              padding="none"
          >
            {children}
          </Card>
        </When>
        <Otherwise>{children}</Otherwise>
      </Choose>
    </div>
  )
}

export default FilterBackground

Version data entries

112 entries across 112 versions & 1 rubygems

Version Path
playbook_ui-11.19.0 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.18.0.pre.alpha.pagutility1 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.19.0.pre.typeahead1 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.18.0 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.17.0 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.15.0.pre.alpha.dependencies1 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.16.0.pre.alpha.paginationrails1 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.16.0 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.16.0.pre.alpha.reactupgrade1 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.15.0.pre.alpha.table1 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.16.0.pre.alpha.pagination.rails1 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.15.0 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.14.0 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.13.0.pre.alpha.fontawesome1 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.13.0 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.12.1.pre.alpha.charts1 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.12.1.pre.alpha.passphrase1 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.12.1 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.13.0.pre.alpha.fileupload1 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx
playbook_ui-11.12.0 app/pb_kits/playbook/pb_filter/Filter/FilterBackground.jsx