mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-15 04:29:37 +01:00
chore(components): improve jsdoc
This commit is contained in:
@@ -31,7 +31,7 @@ export interface AlertProps {
|
||||
actions?: ButtonProps[]
|
||||
/**
|
||||
* Display a close button to dismiss the alert.
|
||||
* Will render with `{ size: 'md', color: 'gray', variant: 'link' }`.
|
||||
* `{ size: 'md', color: 'gray', variant: 'link' }`
|
||||
* @emits `close`
|
||||
* @defaultValue false
|
||||
*/
|
||||
|
||||
@@ -36,7 +36,12 @@ export interface CommandPaletteGroup<T> {
|
||||
highlightedIcon?: string
|
||||
}
|
||||
|
||||
export interface CommandPaletteProps<G, T> extends Pick<ComboboxRootProps, 'as' | 'multiple' | 'disabled' | 'modelValue' | 'defaultValue'>, Pick<UseComponentIconsProps, 'loading' | 'loadingIcon'> {
|
||||
export interface CommandPaletteProps<G, T> extends Pick<ComboboxRootProps, 'multiple' | 'disabled' | 'modelValue' | 'defaultValue'>, Pick<UseComponentIconsProps, 'loading' | 'loadingIcon'> {
|
||||
/**
|
||||
* The element or component this component should render as.
|
||||
* @defaultValue 'div'
|
||||
*/
|
||||
as?: any
|
||||
/**
|
||||
* The icon displayed in the input.
|
||||
* @defaultValue appConfig.ui.icons.search
|
||||
@@ -54,7 +59,7 @@ export interface CommandPaletteProps<G, T> extends Pick<ComboboxRootProps, 'as'
|
||||
placeholder?: InputProps['placeholder']
|
||||
/**
|
||||
* Display a close button in the input (useful when inside a `UModal`).
|
||||
* Will render with `{ size: 'md', color: 'gray', variant: 'ghost' }`.
|
||||
* `{ size: 'md', color: 'gray', variant: 'ghost' }`
|
||||
* @defaultValue false
|
||||
*/
|
||||
close?: ButtonProps | boolean
|
||||
|
||||
@@ -25,7 +25,7 @@ export interface ModalProps extends DialogRootProps {
|
||||
portal?: boolean
|
||||
/**
|
||||
* Display a close button to dismiss the modal.
|
||||
* Will render with `{ size: 'md', color: 'gray', variant: 'ghost' }`.
|
||||
* `{ size: 'md', color: 'gray', variant: 'ghost' }`
|
||||
* @defaultValue true
|
||||
*/
|
||||
close?: ButtonProps | boolean
|
||||
|
||||
@@ -35,7 +35,7 @@ export interface SlideoverProps extends DialogRootProps {
|
||||
portal?: boolean
|
||||
/**
|
||||
* Display a close button to dismiss the slideover.
|
||||
* Will render with `{ size: 'md', color: 'gray', variant: 'ghost' }`.
|
||||
* `{ size: 'md', color: 'gray', variant: 'ghost' }`
|
||||
* @defaultValue true
|
||||
*/
|
||||
close?: ButtonProps | boolean
|
||||
|
||||
@@ -31,7 +31,7 @@ export interface ToastProps extends Pick<ToastRootProps, 'defaultOpen' | 'open'
|
||||
actions?: ButtonProps[]
|
||||
/**
|
||||
* Display a close button to dismiss the toast.
|
||||
* Will render with `{ size: 'md', color: 'gray', variant: 'link' }`.
|
||||
* `{ size: 'md', color: 'gray', variant: 'link' }`
|
||||
* @defaultValue true
|
||||
*/
|
||||
close?: ButtonProps | boolean
|
||||
|
||||
Reference in New Issue
Block a user