Skip to content

Dropdown ​

Searchable dropdown input supporting text, flag, icon, and multi-select modes.

Open in Storybook

Interactive Demo ​

Usage ​

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

const selected = ref(null);
const options = [
  { label: 'Option 1', value: '1' },
  { label: 'Option 2', value: '2' },
  { label: 'Option 3', value: '3' },
];
</script>

<template>
  <DropdownInput
    v-model="selected"
    :options="options"
    label="Select an option"
    placeholder="Choose..."
  />
</template>

API Reference ​

Props ​

PropTypeDefaultDescription
modelValueany—Selected value (v-model)
typestring—Dropdown type (text, flag, icon, multi)
size'large' | 'small''large'Input size
labelstring—Label text
placeholderstring—Placeholder text
helperTextstring—Helper text below input
errorbooleanfalseError state
errorMessagestring—Error message text
disabledbooleanfalseDisabled state
requiredbooleanfalseRequired indicator
options*array—Array of options
searchablebooleanfalseEnable search filtering
maxTagsnumber—Max selected tags in multi-select mode

Events ​

EventPayloadDescription
update:modelValueanyEmitted when selection changes