import { Size } from '../types'; import { ChipVariant } from '../Chips/ChipTypes'; import React from "react"; export interface ChipInputProps extends Omit, 'autoSave' | 'list' | 'type' | 'id' | 'required' | 'tabIndex' | 'value' | 'onChange' | 'onKeyDown' | 'placeholder' | 'onClick' | 'disabled' | 'size'> { /** * Required. The ID of the input element. */ inputId: string; /** * Required. An array of strings representing the current values (chips) in the input. */ values: string[]; /** * Optional. An icon to be displayed inside the input. */ icon?: React.ReactNode; /** * Optional. An array of ChipVariant objects representing the variants of the chips. */ variants?: ChipVariant[]; /** * Optional. The placeholder text to be displayed in the input when it is empty and no items available for selecting. */ placeholder?: string; /** * Optional. An alternative placeholder text to be displayed in the input when it is empty and there are items to select. */ altPlaceholder?: string; /** * Required. A function to be called when the values (chips) change. * It should take an array of strings representing the new values. */ onValueChange: (chips: string[]) => void; /** * Optional. A boolean indicating whether the input supports multiple lines. */ multiLine?: boolean; /** * Optional. A boolean indicating whether the input is disabled. */ disabled?: boolean; /** * Optional. The size of the input. Can be 'Medium' or 'Small'. */ size?: Size.Medium | Size.Small; /** * Optional. The validation message to be displayed when the input is in an error state. */ validationMessage?: string; /** * Optional. A boolean indicating whether the input is required. */ required?: boolean; /** * Optional. A boolean indicating whether the input should automatically save its value. */ autoSave?: boolean; } export interface ChipItem { label: string; icon?: React.ReactNode; disabled?: boolean; variant?: ChipVariant; }