Skip to content

Checkbox

Two-state or indeterminate checkbox input for binary selection.

Open in Storybook

Interactive Demo

Usage

vue
<script setup>
import { ref } from 'vue';
import { Checkbox } from '@yellowcard/b2b-design-system';

const agreed = ref(false);
</script>

<template>
  <Checkbox v-model="agreed" ariaLabel="I agree to the terms" />
</template>

API Reference

Props

PropTypeDefaultDescription
modelValuebooleanChecked state (v-model)
sizestringCheckbox size
disabledbooleanfalseDisabled state
ariaLabelstringAccessible label
ariaDescribedbystringID of describing element

Events

EventPayloadDescription
update:modelValuebooleanEmitted when checked state changes