Sha256: 93ebf8c452eb2aa6be1e0968690e0da232da3822b1bb5bdbef7c7d80271ba1e7

Contents?: true

Size: 1.02 KB

Versions: 151

Compression:

Stored size: 1.02 KB

Contents

import React, { useState } from 'react'
import { SelectableCardIcon } from '../../'

const SelectableCardIconSingleSelect = () => {
  const [selectedFormat, toggleFormat] = useState(null)

  return (
    <div className="pb--doc-demo-row">
      <SelectableCardIcon
          checked={selectedFormat === 'car'}
          icon="car"
          inputId={7}
          name="select"
          onChange={() => toggleFormat('car')}
          titleText="Car"
          value="car"
      />
      <SelectableCardIcon
          checked={selectedFormat === 'bus'}
          icon="bus"
          inputId={8}
          name="select"
          onChange={() => toggleFormat('bus')}
          titleText="Bus"
          value="bus"
      />
      <SelectableCardIcon
          checked={selectedFormat === 'subway'}
          icon="subway"
          inputId={9}
          name="select"
          onChange={() => toggleFormat('subway')}
          titleText="Subway"
          value="subway"
      />
    </div>
  )
}

export default SelectableCardIconSingleSelect

Version data entries

151 entries across 151 versions & 1 rubygems

Version Path
playbook_ui-7.11.1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.11.0 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.11.0.pre.alpha1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.10.0 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.9.0 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.8.4 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.8.3 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.8.2 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.8.1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.8.0 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.7.0.pre.alpha1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.7.0 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.6.2.pre.alpha1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.6.2 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.6.1.pre.alpha1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.6.1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.6.0 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.5.1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.5.0 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.4.2 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx