Sha256: 2dc41afff34c55a18424351b77713673320d54aa15a702c1138a708de3aca283

Contents?: true

Size: 1.46 KB

Versions: 948

Compression:

Stored size: 1.46 KB

Contents

import React, { useState } from 'react'
import { Body, SelectableCard, Title } from 'playbook-ui'

const SelectableCardError = (props) => {
  const [football, setFootball] = useState(false)
  const [basketball, setBasketball] = useState(false)
  const [baseball, setBaseball] = useState(false)

  return (
    <div>
      <Title
          {...props}
          size={3}
          text="What sports do you like?"
      />
      <br />
      <SelectableCard
          {...props}
          checked={football}
          error
          inputId="football"
          name="football"
          onChange={() => setFootball(!football)}
          value="football"
          variant="displayInput"
      >
        <Body {...props}>{'Football'}</Body>
      </SelectableCard>

      <SelectableCard
          {...props}
          checked={basketball}
          error
          inputId="basketball"
          name="basketball"
          onChange={() => setBasketball(!basketball)}
          value="basketball"
          variant="displayInput"
      >
        <Body {...props}>{'Basketball'}</Body>
      </SelectableCard>

      <SelectableCard
          {...props}
          checked={baseball}
          error
          inputId="baseball"
          name="baseball"
          onChange={() => setBaseball(!baseball)}
          value="baseball"
          variant="displayInput"
      >
        <Body {...props}>{'Baseball'}</Body>
      </SelectableCard>
    </div>
  )
}
export default SelectableCardError

Version data entries

948 entries across 948 versions & 2 rubygems

Version Path
playbook_ui_docs-14.11.1.pre.alpha.PLAY17445539 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui-14.11.1.pre.alpha.PLAY17445539 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui_docs-14.11.1.pre.alpha.PBNTR798datepickerturbo5537 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui-14.11.1.pre.alpha.PBNTR798datepickerturbo5537 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui_docs-14.11.1.pre.alpha.pbntr703collapsiblerowsrails5536 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui-14.11.1.pre.alpha.pbntr703collapsiblerowsrails5536 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui_docs-14.11.1.pre.alpha.PLAY1751pbcontenttagpt25529 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui-14.11.1.pre.alpha.PLAY1751pbcontenttagpt25529 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui_docs-14.11.1.pre.alpha.PBNTR7495495 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui-14.11.1.pre.alpha.PBNTR7495495 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui_docs-14.12.0.pre.rc.11 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui-14.12.0.pre.rc.11 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui_docs-14.12.0.pre.rc.10 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui-14.12.0.pre.rc.10 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui_docs-14.12.0.pre.rc.9 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui-14.12.0.pre.rc.9 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui_docs-14.12.0.pre.rc.8 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui-14.12.0.pre.rc.8 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui_docs-14.12.0.pre.rc.7 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx
playbook_ui-14.12.0.pre.rc.7 app/pb_kits/playbook/pb_selectable_card/docs/_selectable_card_error.jsx