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.3.0.pre.alpha3 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.3.0.pre.alpha2 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.3.0.pre.alpha1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.2.0 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.1.2 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.1.0.pre.alpha2 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.1.1.pre.alpha1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.0.1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.1.1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.1.0.pre.alpha1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.1.0 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.0.1.pre.alpha15 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-6.8.2.pre.alpha1 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.0.0.pre.alpha15 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.0.1.pre.alpha14 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.0.0.pre.alpha14 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.0.0.pre.alpha13 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.0.0.pre.alpha12 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.0.0 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx
playbook_ui-7.0.0.pre.alpha11 app/pb_kits/playbook/pb_selectable_card_icon/docs/_selectable_card_icon_single_select.jsx