@mt-gloss/ui 0.0.9 → 0.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/catalog.d.ts +7 -0
- package/catalog.js +614 -0
- package/index.d.ts +274 -2
- package/index.js +2217 -18330
- package/internals.d.ts +64 -0
- package/internals.js +279 -0
- package/lib/base/BaseAccordion/BaseAccordion.d.ts +51 -0
- package/lib/base/BaseAlert/BaseAlert.d.ts +28 -0
- package/lib/base/BaseAsyncButton/BaseAsyncButton.d.ts +22 -0
- package/lib/base/BaseAvatar/BaseAvatar.d.ts +28 -0
- package/lib/base/BaseBadge/BaseBadge.d.ts +31 -0
- package/lib/base/BaseBox/BaseBox.d.ts +35 -0
- package/lib/base/BaseBreadcrumbs/BaseBreadcrumbs.d.ts +26 -0
- package/lib/base/BaseButton/BaseButton.d.ts +38 -0
- package/lib/base/BaseCard/BaseCard.d.ts +109 -0
- package/lib/base/BaseCheckbox/BaseCheckbox.d.ts +23 -0
- package/lib/base/BaseChip/BaseChip.d.ts +38 -0
- package/lib/base/BaseColorPicker/BaseColorPicker.d.ts +77 -0
- package/lib/base/BaseDatePicker/BaseDatePicker.d.ts +76 -0
- package/lib/base/BaseDateRangePicker/BaseDateRangePicker.d.ts +47 -0
- package/lib/base/BaseDialog/BaseDialog.d.ts +54 -0
- package/lib/base/BaseDivider/BaseDivider.d.ts +24 -0
- package/lib/base/BaseFileUpload/BaseFileUpload.d.ts +57 -0
- package/lib/base/BaseIcon/BaseIcon.d.ts +23 -0
- package/lib/base/BaseInput/BaseInput.d.ts +34 -0
- package/lib/base/BaseLabel/BaseLabel.d.ts +21 -0
- package/lib/base/BaseLink/BaseLink.d.ts +29 -0
- package/lib/base/BaseMaskedInput/BaseMaskedInput.d.ts +31 -0
- package/lib/base/BaseMenu/BaseMenu.d.ts +70 -0
- package/lib/base/BaseNumberInput/BaseNumberInput.d.ts +31 -0
- package/lib/base/BaseOverlay/BaseOverlay.d.ts +39 -0
- package/lib/base/BaseOverlay/useOverlayDismiss.d.ts +15 -0
- package/lib/base/BaseOverlay/useOverlayPositioning.d.ts +13 -0
- package/lib/base/BasePopover/BasePopover.d.ts +40 -0
- package/lib/base/BaseProgressBar/BaseProgressBar.d.ts +27 -0
- package/lib/base/BaseRadio/BaseRadio.d.ts +20 -0
- package/lib/base/BaseRangeSlider/BaseRangeSlider.d.ts +31 -0
- package/lib/base/BaseRating/BaseRating.d.ts +25 -0
- package/lib/base/BaseSegmentedControl/BaseSegmentedControl.d.ts +26 -0
- package/lib/base/BaseSelect/BaseSelect.d.ts +83 -0
- package/lib/base/BaseSlider/BaseSlider.d.ts +29 -0
- package/lib/base/BaseStack/BaseStack.d.ts +26 -0
- package/lib/base/BaseTable/BaseTable.d.ts +97 -0
- package/lib/base/BaseText/BaseText.d.ts +19 -0
- package/lib/base/BaseTextarea/BaseTextarea.d.ts +37 -0
- package/lib/base/BaseTimePicker/BaseTimePicker.d.ts +55 -0
- package/lib/base/BaseTitle/BaseTitle.d.ts +22 -0
- package/lib/base/BaseToast/BaseToast.d.ts +35 -0
- package/lib/base/BaseToggle/BaseToggle.d.ts +22 -0
- package/lib/base/BaseTooltip/BaseTooltip.d.ts +27 -0
- package/lib/base/BaseTypography/BaseTypography.d.ts +30 -0
- package/lib/base/BaseValue/BaseValue.d.ts +20 -0
- package/lib/base/index.d.ts +65 -0
- package/lib/base/types.d.ts +9 -0
- package/lib/base/utils.d.ts +18 -0
- package/lib/composites/controls/ThresholdRamp/ThresholdRamp.d.ts +24 -0
- package/lib/composites/controls/ThresholdRamp/index.d.ts +2 -0
- package/lib/composites/controls/index.d.ts +1 -0
- package/lib/composites/dashboard/QuickConfigPanel/QuickConfigPanel.d.ts +14 -0
- package/lib/composites/dashboard/QuickConfigPanel/index.d.ts +2 -0
- package/lib/composites/dashboard/QuickConfigPanel/types.d.ts +38 -0
- package/lib/composites/data/DataTable.d.ts +61 -0
- package/lib/composites/data/PinToMetric/PinToMetric.d.ts +11 -0
- package/lib/composites/data/PinToMetric/index.d.ts +2 -0
- package/lib/composites/data/PinToMetric/types.d.ts +17 -0
- package/lib/composites/data/index.d.ts +4 -0
- package/lib/composites/index.d.ts +5 -0
- package/lib/composites/inputs/Autocomplete.d.ts +36 -0
- package/lib/composites/inputs/EntityPicker.d.ts +36 -0
- package/lib/composites/inputs/FilterChip.d.ts +29 -0
- package/lib/composites/inputs/MultiSelect.d.ts +38 -0
- package/lib/composites/inputs/index.d.ts +8 -0
- package/lib/composites/navigation/Stepper.d.ts +40 -0
- package/lib/composites/navigation/index.d.ts +2 -0
- package/lib/composites/overlay/Dropdown/Dropdown.d.ts +22 -0
- package/lib/composites/overlay/Dropdown/index.d.ts +2 -0
- package/lib/composites/overlay/FormDialog.d.ts +38 -0
- package/lib/composites/overlay/InlineNudge/InlineNudge.d.ts +26 -0
- package/lib/composites/overlay/InlineNudge/index.d.ts +12 -0
- package/lib/composites/overlay/MergePrompt/MergePrompt.d.ts +16 -0
- package/lib/composites/overlay/MergePrompt/index.d.ts +2 -0
- package/lib/composites/overlay/MergePrompt/types.d.ts +15 -0
- package/lib/composites/overlay/SplitButton/SplitButton.d.ts +27 -0
- package/lib/composites/overlay/SplitButton/index.d.ts +2 -0
- package/lib/composites/overlay/index.d.ts +6 -0
- package/lib/compositions/feedback/DestructiveModal.d.ts +1 -1
- package/lib/compositions/filters/OrderFilterBar.d.ts +35 -0
- package/lib/compositions/filters/index.d.ts +2 -0
- package/lib/compositions/forms/AddressGroup.d.ts +13 -1
- package/lib/compositions/forms/ContactForm.d.ts +31 -0
- package/lib/compositions/forms/CreditCardForm.d.ts +3 -1
- package/lib/compositions/forms/LoginForm.d.ts +3 -1
- package/lib/compositions/forms/PaymentForm.d.ts +50 -0
- package/lib/compositions/forms/RegistrationForm.d.ts +39 -0
- package/lib/compositions/forms/index.d.ts +3 -0
- package/lib/compositions/index.d.ts +3 -0
- package/lib/compositions/navigation/ImportWizard.d.ts +28 -0
- package/lib/compositions/navigation/index.d.ts +2 -0
- package/lib/compositions/panels/EntitySearchPanel.d.ts +41 -0
- package/lib/compositions/panels/ProfileCard.d.ts +34 -0
- package/lib/compositions/panels/index.d.ts +4 -0
- package/lib/containers/ContainerCard/ContainerCard.d.ts +13 -0
- package/lib/containers/ContainerDialog/ContainerDialog.d.ts +27 -0
- package/lib/containers/ContainerForm/ContainerForm.d.ts +45 -0
- package/lib/containers/ContainerFormField/ContainerFormField.d.ts +31 -0
- package/lib/containers/ContainerFormSection/ContainerFormSection.d.ts +13 -0
- package/lib/containers/ContainerPanel/ContainerPanel.d.ts +14 -0
- package/lib/containers/ContainerTable/ContainerTable.d.ts +12 -0
- package/lib/containers/ContainerToolbar/ContainerToolbar.d.ts +11 -0
- package/lib/containers/UIContext.d.ts +26 -0
- package/lib/containers/index.d.ts +18 -0
- package/lib/dictionary/border.d.ts +11 -0
- package/lib/dictionary/breakpoint.d.ts +12 -0
- package/lib/dictionary/color.d.ts +67 -0
- package/lib/dictionary/elevation.d.ts +16 -0
- package/lib/dictionary/index.d.ts +14 -0
- package/lib/dictionary/motion.d.ts +13 -0
- package/lib/dictionary/opacity.d.ts +11 -0
- package/lib/dictionary/radius.d.ts +14 -0
- package/lib/dictionary/spacing.d.ts +18 -0
- package/lib/dictionary/typography.d.ts +25 -0
- package/lib/dictionary/z-index.d.ts +13 -0
- package/lib/facade/composites.d.ts +56 -0
- package/lib/facade/compositions.d.ts +27 -0
- package/lib/facade/containers.d.ts +8 -0
- package/lib/facade/data-display.d.ts +41 -0
- package/lib/facade/display.d.ts +50 -0
- package/lib/facade/feedback.d.ts +6 -0
- package/lib/facade/index.d.ts +17 -0
- package/lib/facade/inputs.d.ts +43 -0
- package/lib/facade/layout.d.ts +8 -0
- package/lib/facade/overlay.d.ts +26 -0
- package/lib/facade/typography.d.ts +12 -0
- package/lib/facade/wrappers.d.ts +26 -0
- package/lib/presets/PresetAccordion/PresetAccordion.d.ts +21 -0
- package/lib/presets/PresetAlert/PresetAlert.d.ts +17 -0
- package/lib/presets/PresetAsyncButton/PresetAsyncButton.d.ts +22 -0
- package/lib/presets/PresetAsyncLoader/PresetAsyncLoader.d.ts +6 -0
- package/lib/presets/PresetAvatar/PresetAvatar.d.ts +18 -0
- package/lib/presets/PresetBadge/PresetBadge.d.ts +15 -0
- package/lib/presets/PresetBreadcrumbs/PresetBreadcrumbs.d.ts +15 -0
- package/lib/presets/PresetButton/PresetButton.d.ts +27 -0
- package/lib/presets/PresetButtonGroup/PresetButtonGroup.d.ts +6 -0
- package/lib/presets/PresetCard/PresetCard.d.ts +45 -0
- package/lib/presets/PresetCheckbox/PresetCheckbox.d.ts +23 -0
- package/lib/presets/PresetCheckboxGroup/PresetCheckboxGroup.d.ts +6 -0
- package/lib/presets/PresetChip/PresetChip.d.ts +22 -0
- package/lib/presets/PresetColorPicker/PresetColorPicker.d.ts +22 -0
- package/lib/presets/PresetDatePicker/PresetDatePicker.d.ts +29 -0
- package/lib/presets/PresetDateRangePicker/PresetDateRangePicker.d.ts +37 -0
- package/lib/presets/PresetDialog/PresetDialog.d.ts +46 -0
- package/lib/presets/PresetDivider/PresetDivider.d.ts +13 -0
- package/lib/presets/PresetDropdown/PresetDropdown.d.ts +6 -0
- package/lib/presets/PresetFileUpload/PresetFileUpload.d.ts +35 -0
- package/lib/presets/PresetForm/PresetForm.d.ts +6 -0
- package/lib/presets/PresetFormField/PresetFormField.d.ts +6 -0
- package/lib/presets/PresetInput/PresetInput.d.ts +24 -0
- package/lib/presets/PresetInputGroup/PresetInputGroup.d.ts +6 -0
- package/lib/presets/PresetLabel/PresetLabel.d.ts +18 -0
- package/lib/presets/PresetLink/PresetLink.d.ts +21 -0
- package/lib/presets/PresetMaskedInput/PresetMaskedInput.d.ts +41 -0
- package/lib/presets/PresetMenu/PresetMenu.d.ts +33 -0
- package/lib/presets/PresetNumberInput/PresetNumberInput.d.ts +26 -0
- package/lib/presets/PresetPopover/PresetPopover.d.ts +17 -0
- package/lib/presets/PresetProgressBar/PresetProgressBar.d.ts +19 -0
- package/lib/presets/PresetRadio/PresetRadio.d.ts +21 -0
- package/lib/presets/PresetRadioGroup/PresetRadioGroup.d.ts +6 -0
- package/lib/presets/PresetRangeSlider/PresetRangeSlider.d.ts +30 -0
- package/lib/presets/PresetRating/PresetRating.d.ts +19 -0
- package/lib/presets/PresetSegmentedControl/PresetSegmentedControl.d.ts +28 -0
- package/lib/presets/PresetSelect/PresetSelect.d.ts +63 -0
- package/lib/presets/PresetSlider/PresetSlider.d.ts +29 -0
- package/lib/presets/PresetSplitButton/PresetSplitButton.d.ts +6 -0
- package/lib/presets/PresetSwatchRow/PresetSwatchRow.d.ts +28 -0
- package/lib/presets/PresetSwatchRow/index.d.ts +2 -0
- package/lib/presets/PresetText/PresetText.d.ts +17 -0
- package/lib/presets/PresetTextarea/PresetTextarea.d.ts +25 -0
- package/lib/presets/PresetTimePicker/PresetTimePicker.d.ts +27 -0
- package/lib/presets/PresetTitle/PresetTitle.d.ts +19 -0
- package/lib/presets/PresetToast/PresetToast.d.ts +19 -0
- package/lib/presets/PresetToggle/PresetToggle.d.ts +21 -0
- package/lib/presets/PresetTooltip/PresetTooltip.d.ts +20 -0
- package/lib/presets/PresetTransition/PresetTransition.d.ts +6 -0
- package/lib/presets/PresetValue/PresetValue.d.ts +15 -0
- package/lib/presets/createPreset.d.ts +64 -0
- package/lib/presets/index.d.ts +86 -0
- package/lib/presets/types.d.ts +13 -0
- package/lib/primitives/Accordion.d.ts +12 -102
- package/lib/primitives/AsyncLoader.d.ts +4 -39
- package/lib/primitives/Badge.d.ts +5 -40
- package/lib/primitives/Button.d.ts +4 -71
- package/lib/primitives/ButtonGroup.d.ts +4 -70
- package/lib/primitives/Card.d.ts +20 -138
- package/lib/primitives/Checkbox.d.ts +4 -68
- package/lib/primitives/CheckboxGroup.d.ts +4 -160
- package/lib/primitives/Chip.d.ts +5 -66
- package/lib/primitives/ColorPicker.d.ts +4 -80
- package/lib/primitives/DatePicker.d.ts +4 -100
- package/lib/primitives/DateRangePicker.d.ts +4 -107
- package/lib/primitives/Dropdown.d.ts +4 -63
- package/lib/primitives/FileUpload.d.ts +4 -107
- package/lib/primitives/Form.d.ts +4 -117
- package/lib/primitives/FormField.d.ts +4 -67
- package/lib/primitives/Input.d.ts +4 -87
- package/lib/primitives/InputGroup.d.ts +4 -57
- package/lib/primitives/Link.d.ts +4 -67
- package/lib/primitives/MaskedInput.d.ts +4 -93
- package/lib/primitives/Menu.d.ts +12 -131
- package/lib/primitives/NumberInput.d.ts +4 -79
- package/lib/primitives/Radio.d.ts +4 -58
- package/lib/primitives/RadioGroup.d.ts +4 -161
- package/lib/primitives/RangeSlider.d.ts +4 -103
- package/lib/primitives/Rating.d.ts +4 -113
- package/lib/primitives/SegmentedControl.d.ts +4 -94
- package/lib/primitives/Select.d.ts +5 -203
- package/lib/primitives/Slider.d.ts +4 -109
- package/lib/primitives/SplitButton.d.ts +4 -82
- package/lib/primitives/Textarea.d.ts +4 -57
- package/lib/primitives/TimePicker.d.ts +4 -91
- package/lib/primitives/Toggle.d.ts +4 -66
- package/lib/primitives/Tooltip.d.ts +6 -86
- package/lib/primitives/Transition.d.ts +4 -105
- package/lib/primitives/dashboard/MetricCard/CardBack.d.ts +17 -2
- package/lib/primitives/dashboard/MetricCard/CardShell.d.ts +1 -1
- package/lib/primitives/dashboard/MetricCard/EdgeHoverHandle.d.ts +20 -0
- package/lib/primitives/dashboard/MetricCard/GhostPreview.d.ts +24 -0
- package/lib/primitives/dashboard/MetricCard/GutterActions.d.ts +12 -2
- package/lib/primitives/dashboard/MetricCard/MetricCard.d.ts +0 -28
- package/lib/primitives/dashboard/MetricCard/StatusModeCard.d.ts +5 -0
- package/lib/primitives/dashboard/MetricCard/StatusSlotChipMenu.d.ts +28 -0
- package/lib/primitives/dashboard/MetricCard/flipAndStage/FlipAndStageProvider.d.ts +29 -0
- package/lib/primitives/dashboard/MetricCard/flipAndStage/index.d.ts +15 -0
- package/lib/primitives/dashboard/MetricCard/flipAndStage/types.d.ts +83 -0
- package/lib/primitives/dashboard/MetricCard/flipAndStage/useFlipAndStage.d.ts +10 -0
- package/lib/primitives/dashboard/MetricCard/index.d.ts +10 -0
- package/lib/primitives/dashboard/MetricCard/types.d.ts +48 -4
- package/lib/primitives/dashboard/MetricCard/useEdgeHoverResize.d.ts +52 -0
- package/lib/primitives/dashboard/MetricCard/useSlotCapacity.d.ts +12 -0
- package/lib/primitives/dashboard/MetricCardGrid/MetricCardGrid.d.ts +21 -19
- package/lib/primitives/dashboard/MetricCardGrid/types.d.ts +8 -1
- package/lib/primitives/dashboard/MetricGroupContainer/MetricGroupContainer.d.ts +5 -0
- package/lib/primitives/dashboard/MetricGroupContainer/__tests__/fixtures.d.ts +13 -0
- package/lib/primitives/dashboard/MetricGroupContainer/index.d.ts +2 -0
- package/lib/primitives/dashboard/MetricGroupContainer/types.d.ts +34 -0
- package/lib/primitives/dashboard/PageChip/PageChip.d.ts +27 -0
- package/lib/primitives/dashboard/PageChip/PageDropdown.d.ts +29 -0
- package/lib/primitives/dashboard/PageChip/index.d.ts +3 -0
- package/lib/primitives/dashboard/PageChip/types.d.ts +36 -0
- package/lib/primitives/dashboard/TimeFrame/SimpleSelector.d.ts +9 -0
- package/lib/primitives/dashboard/TimeFrame/index.d.ts +2 -0
- package/lib/primitives/dashboard/TimeFrame/types.d.ts +8 -0
- package/lib/primitives/dashboard/UnifiedContextMenu/types.d.ts +2 -0
- package/lib/primitives/dashboard/index.d.ts +2 -0
- package/lib/wrappers/Actionable/Actionable.d.ts +17 -0
- package/lib/wrappers/AsyncLoader/AsyncLoader.d.ts +13 -0
- package/lib/wrappers/ButtonGroup/ButtonGroup.d.ts +23 -0
- package/lib/wrappers/CheckboxGroup/CheckboxGroup.d.ts +52 -0
- package/lib/wrappers/Dismissible/Dismissible.d.ts +24 -0
- package/lib/wrappers/Expandable/Expandable.d.ts +23 -0
- package/lib/wrappers/InputGroup/InputGroup.d.ts +20 -0
- package/lib/wrappers/RadioGroup/RadioGroup.d.ts +52 -0
- package/lib/wrappers/Selectable/Selectable.d.ts +19 -0
- package/lib/wrappers/Sortable/Sortable.d.ts +27 -0
- package/lib/wrappers/SortableZones/SortableZones.d.ts +32 -0
- package/lib/wrappers/SortableZones/index.d.ts +4 -0
- package/lib/wrappers/SortableZones/useSortableZones.d.ts +66 -0
- package/lib/wrappers/Transition/Transition.d.ts +49 -0
- package/lib/wrappers/index.d.ts +25 -0
- package/lib/wrappers/utils.d.ts +10 -0
- package/package.json +36 -2
- package/index.css +0 -1
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
export interface FileUploadFile {
|
|
4
|
+
file: File;
|
|
5
|
+
id: string;
|
|
6
|
+
progress?: number;
|
|
7
|
+
error?: string;
|
|
8
|
+
preview?: string;
|
|
9
|
+
}
|
|
10
|
+
export declare const FILEUPLOAD_VARIANTS: readonly ["default", "error"];
|
|
11
|
+
export type PresetFileUploadVariant = (typeof FILEUPLOAD_VARIANTS)[number];
|
|
12
|
+
export interface PresetFileUploadProps {
|
|
13
|
+
variant?: PresetFileUploadVariant;
|
|
14
|
+
size?: SharedSize;
|
|
15
|
+
value?: FileUploadFile[];
|
|
16
|
+
onChange?: (files: FileUploadFile[]) => void;
|
|
17
|
+
accept?: string;
|
|
18
|
+
maxFiles?: number;
|
|
19
|
+
maxSize?: number;
|
|
20
|
+
multiple?: boolean;
|
|
21
|
+
disabled?: boolean;
|
|
22
|
+
showPreview?: boolean;
|
|
23
|
+
onRemove?: (fileId: string) => void;
|
|
24
|
+
dropzoneText?: string;
|
|
25
|
+
label?: string;
|
|
26
|
+
helperText?: string;
|
|
27
|
+
onError?: (error: string) => void;
|
|
28
|
+
id?: string;
|
|
29
|
+
name?: string;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* FileUpload with drag-and-drop, file list, variant styling, size scale.
|
|
33
|
+
* Re-exports FileUploadFile type.
|
|
34
|
+
*/
|
|
35
|
+
export declare const PresetFileUpload: React.ForwardRefExoticComponent<PresetFileUploadProps & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @deprecated Moved to containers/ tier (Phase 25.1).
|
|
3
|
+
* Use `import * as UI from '@mt-gloss/ui/catalog'` -> `<UI.Form>` instead.
|
|
4
|
+
*/
|
|
5
|
+
export { ContainerForm as PresetForm, useFormContext } from '../../containers/ContainerForm/ContainerForm';
|
|
6
|
+
export type { ContainerFormProps as PresetFormProps, FormContextValue, FormErrors, FormTouched } from '../../containers/ContainerForm/ContainerForm';
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @deprecated Moved to containers/ tier (Phase 25.1).
|
|
3
|
+
* Use `import * as UI from '@mt-gloss/ui/catalog'` -> `<UI.FormField>` instead.
|
|
4
|
+
*/
|
|
5
|
+
export { ContainerFormField as PresetFormField } from '../../containers/ContainerFormField/ContainerFormField';
|
|
6
|
+
export type { ContainerFormFieldProps as PresetFormFieldProps } from '../../containers/ContainerFormField/ContainerFormField';
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
export type PresetInputVariant = 'default' | 'error' | 'success';
|
|
4
|
+
export interface PresetInputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'className' | 'style' | 'size' | 'onCopy'> {
|
|
5
|
+
variant?: PresetInputVariant;
|
|
6
|
+
size?: SharedSize;
|
|
7
|
+
label?: string;
|
|
8
|
+
helperText?: string;
|
|
9
|
+
status?: 'default' | 'error' | 'success';
|
|
10
|
+
clearable?: boolean;
|
|
11
|
+
/** Callback when the clear button is clicked */
|
|
12
|
+
onClear?: () => void;
|
|
13
|
+
copyable?: boolean;
|
|
14
|
+
/** Callback after copying the input value */
|
|
15
|
+
onCopy?: (value: string) => void;
|
|
16
|
+
/** Show character counter (requires maxLength) */
|
|
17
|
+
showCounter?: boolean;
|
|
18
|
+
leftIcon?: React.ReactNode;
|
|
19
|
+
rightIcon?: React.ReactNode;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Input with semantic variant/size API. Wraps BaseInput.
|
|
23
|
+
*/
|
|
24
|
+
export declare const PresetInput: React.ForwardRefExoticComponent<PresetInputProps & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @deprecated Moved to wrappers/ tier (Phase 25.1).
|
|
3
|
+
* Use `import * as UI from '@mt-gloss/ui/catalog'` -> `<UI.InputGroup>` instead.
|
|
4
|
+
*/
|
|
5
|
+
export { InputGroup as PresetInputGroup, InputAddon as PresetInputAddon } from '../../wrappers/InputGroup/InputGroup';
|
|
6
|
+
export type { InputGroupProps as PresetInputGroupProps, InputAddonProps as PresetInputAddonProps } from '../../wrappers/InputGroup/InputGroup';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { PolymorphicProps } from '../../base/types';
|
|
3
|
+
export declare const LABEL_VARIANTS: readonly ["default", "required", "optional"];
|
|
4
|
+
export type PresetLabelVariant = (typeof LABEL_VARIANTS)[number];
|
|
5
|
+
export interface PresetLabelProps {
|
|
6
|
+
variant?: PresetLabelVariant;
|
|
7
|
+
htmlFor?: string;
|
|
8
|
+
children?: React.ReactNode;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Label with semantic variant API. Wraps BaseLabel.
|
|
12
|
+
* Required variant adds asterisk via CSS pseudo-element.
|
|
13
|
+
* Optional variant adds "(optional)" text via CSS pseudo-element.
|
|
14
|
+
*/
|
|
15
|
+
export declare const PresetLabel: {
|
|
16
|
+
<C extends React.ElementType = "label">(props: PolymorphicProps<C, PresetLabelProps>): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
displayName: string;
|
|
18
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
export type PresetLinkVariant = 'default' | 'muted' | 'destructive';
|
|
4
|
+
export interface PresetLinkProps {
|
|
5
|
+
variant?: PresetLinkVariant;
|
|
6
|
+
size?: SharedSize;
|
|
7
|
+
external?: boolean;
|
|
8
|
+
leftIcon?: React.ReactNode;
|
|
9
|
+
rightIcon?: React.ReactNode;
|
|
10
|
+
underline?: 'always' | 'hover' | 'none';
|
|
11
|
+
disabled?: boolean;
|
|
12
|
+
href?: string;
|
|
13
|
+
as?: React.ElementType;
|
|
14
|
+
children?: React.ReactNode;
|
|
15
|
+
onClick?: React.MouseEventHandler;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Link with semantic variant/size API. Wraps BaseLink.
|
|
19
|
+
* Navigation element with consistent styling and icon support.
|
|
20
|
+
*/
|
|
21
|
+
export declare const PresetLink: React.ForwardRefExoticComponent<PresetLinkProps & React.RefAttributes<HTMLAnchorElement>>;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
export interface MaskConfig {
|
|
4
|
+
mask: string | RegExp | NumberConstructor | Array<string | RegExp | {
|
|
5
|
+
mask: string;
|
|
6
|
+
[key: string]: unknown;
|
|
7
|
+
}>;
|
|
8
|
+
placeholderChar?: string;
|
|
9
|
+
lazy?: boolean;
|
|
10
|
+
definitions?: Record<string, RegExp>;
|
|
11
|
+
unmask?: boolean | 'typed';
|
|
12
|
+
[key: string]: unknown;
|
|
13
|
+
}
|
|
14
|
+
export declare const MaskPresets: Record<string, MaskConfig>;
|
|
15
|
+
export type MaskPresetName = keyof typeof MaskPresets;
|
|
16
|
+
export declare const MASKEDINPUT_VARIANTS: readonly ["default", "error", "success"];
|
|
17
|
+
export type PresetMaskedInputVariant = (typeof MASKEDINPUT_VARIANTS)[number];
|
|
18
|
+
export interface PresetMaskedInputProps {
|
|
19
|
+
variant?: PresetMaskedInputVariant;
|
|
20
|
+
size?: SharedSize;
|
|
21
|
+
mask: MaskConfig | MaskPresetName;
|
|
22
|
+
value?: string;
|
|
23
|
+
onAccept?: (value: string) => void;
|
|
24
|
+
onComplete?: (value: string) => void;
|
|
25
|
+
onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
26
|
+
onBlur?: (event: React.FocusEvent<HTMLInputElement>) => void;
|
|
27
|
+
label?: string;
|
|
28
|
+
helperText?: string;
|
|
29
|
+
status?: 'default' | 'error' | 'success';
|
|
30
|
+
disabled?: boolean;
|
|
31
|
+
guide?: boolean;
|
|
32
|
+
placeholder?: string;
|
|
33
|
+
required?: boolean;
|
|
34
|
+
id?: string;
|
|
35
|
+
name?: string;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* MaskedInput with imask integration, variant styling, size scale.
|
|
39
|
+
* Re-exports MaskConfig, MaskPresetName, and MaskPresets.
|
|
40
|
+
*/
|
|
41
|
+
export declare const PresetMaskedInput: React.ForwardRefExoticComponent<PresetMaskedInputProps & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export type PresetMenuSize = 'sm' | 'md';
|
|
3
|
+
export interface PresetMenuProps {
|
|
4
|
+
size?: PresetMenuSize;
|
|
5
|
+
children: React.ReactNode;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* Menu container with semantic size API. Wraps BaseMenu.
|
|
9
|
+
*/
|
|
10
|
+
export declare const PresetMenu: React.ForwardRefExoticComponent<PresetMenuProps & Omit<React.HTMLAttributes<HTMLDivElement>, "style" | "className"> & React.RefAttributes<HTMLDivElement>>;
|
|
11
|
+
export interface PresetMenuGroupProps {
|
|
12
|
+
label?: string;
|
|
13
|
+
open?: boolean;
|
|
14
|
+
onOpenChange?: (open: boolean) => void;
|
|
15
|
+
showCount?: 'always' | 'collapsed-only' | 'never';
|
|
16
|
+
children: React.ReactNode;
|
|
17
|
+
}
|
|
18
|
+
export declare function PresetMenuGroup({ label, open, onOpenChange, showCount, children, ...rest }: PresetMenuGroupProps & Omit<React.HTMLAttributes<HTMLDivElement>, 'className' | 'style'>): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export declare namespace PresetMenuGroup {
|
|
20
|
+
var displayName: string;
|
|
21
|
+
}
|
|
22
|
+
export interface PresetMenuItemProps {
|
|
23
|
+
disabled?: boolean;
|
|
24
|
+
active?: boolean;
|
|
25
|
+
as?: React.ElementType;
|
|
26
|
+
icon?: React.ReactNode;
|
|
27
|
+
children: React.ReactNode;
|
|
28
|
+
}
|
|
29
|
+
export declare const PresetMenuItem: React.ForwardRefExoticComponent<PresetMenuItemProps & Omit<React.HTMLAttributes<HTMLElement>, "style" | "className"> & React.RefAttributes<HTMLElement>>;
|
|
30
|
+
export declare function PresetMenuDivider(): import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
export declare namespace PresetMenuDivider {
|
|
32
|
+
var displayName: string;
|
|
33
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
export declare const NUMBERINPUT_VARIANTS: readonly ["default", "error", "success"];
|
|
4
|
+
export type PresetNumberInputVariant = (typeof NUMBERINPUT_VARIANTS)[number];
|
|
5
|
+
export interface PresetNumberInputProps {
|
|
6
|
+
variant?: PresetNumberInputVariant;
|
|
7
|
+
size?: SharedSize;
|
|
8
|
+
value?: number;
|
|
9
|
+
defaultValue?: number;
|
|
10
|
+
onChange?: (value: number) => void;
|
|
11
|
+
min?: number;
|
|
12
|
+
max?: number;
|
|
13
|
+
step?: number;
|
|
14
|
+
precision?: number;
|
|
15
|
+
label?: string;
|
|
16
|
+
helperText?: string;
|
|
17
|
+
disabled?: boolean;
|
|
18
|
+
allowNegative?: boolean;
|
|
19
|
+
placeholder?: string;
|
|
20
|
+
showStepper?: boolean;
|
|
21
|
+
formatValue?: (value: number) => string;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* NumberInput with increment/decrement buttons, variant styling, size scale.
|
|
25
|
+
*/
|
|
26
|
+
export declare const PresetNumberInput: React.ForwardRefExoticComponent<PresetNumberInputProps & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export type PresetPopoverPlacement = 'top' | 'bottom' | 'left' | 'right' | 'top-start' | 'top-end' | 'bottom-start' | 'bottom-end';
|
|
3
|
+
export interface PresetPopoverProps {
|
|
4
|
+
open: boolean;
|
|
5
|
+
onDismiss?: () => void;
|
|
6
|
+
anchorRef: React.RefObject<HTMLElement | null>;
|
|
7
|
+
placement?: PresetPopoverPlacement;
|
|
8
|
+
showArrow?: boolean;
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Anchored floating content panel with preset styling. Wraps BasePopover.
|
|
13
|
+
*/
|
|
14
|
+
export declare function PresetPopover({ open, onDismiss, anchorRef, placement, showArrow, children, }: PresetPopoverProps): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
export declare namespace PresetPopover {
|
|
16
|
+
var displayName: string;
|
|
17
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export declare const PROGRESS_BAR_VARIANTS: readonly ["default", "success", "warning", "error"];
|
|
3
|
+
export type PresetProgressBarVariant = (typeof PROGRESS_BAR_VARIANTS)[number];
|
|
4
|
+
export interface PresetProgressBarProps {
|
|
5
|
+
variant?: PresetProgressBarVariant;
|
|
6
|
+
value?: number;
|
|
7
|
+
max?: number;
|
|
8
|
+
indeterminate?: boolean;
|
|
9
|
+
label?: string;
|
|
10
|
+
labelPosition?: 'none' | 'right' | 'top';
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Progress bar with semantic variant API. Wraps BaseProgressBar.
|
|
14
|
+
* Supports determinate/indeterminate modes and optional label.
|
|
15
|
+
*/
|
|
16
|
+
export declare function PresetProgressBar(props: PresetProgressBarProps & Omit<React.HTMLAttributes<HTMLDivElement>, keyof PresetProgressBarProps | 'className' | 'style' | 'role'>): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
export declare namespace PresetProgressBar {
|
|
18
|
+
var displayName: string;
|
|
19
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
export type PresetRadioVariant = 'default' | 'error';
|
|
4
|
+
export interface PresetRadioProps {
|
|
5
|
+
variant?: PresetRadioVariant;
|
|
6
|
+
size?: SharedSize;
|
|
7
|
+
label?: React.ReactNode;
|
|
8
|
+
description?: React.ReactNode;
|
|
9
|
+
helperText?: string;
|
|
10
|
+
checked?: boolean;
|
|
11
|
+
onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
12
|
+
disabled?: boolean;
|
|
13
|
+
required?: boolean;
|
|
14
|
+
name?: string;
|
|
15
|
+
value?: string;
|
|
16
|
+
id?: string;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Radio with semantic variant/size API. Wraps BaseRadio.
|
|
20
|
+
*/
|
|
21
|
+
export declare const PresetRadio: React.ForwardRefExoticComponent<PresetRadioProps & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @deprecated Moved to wrappers/ tier (Phase 25.1).
|
|
3
|
+
* Use `import * as UI from '@mt-gloss/ui/catalog'` -> `<UI.RadioGroup>` instead.
|
|
4
|
+
*/
|
|
5
|
+
export { RadioGroup as PresetRadioGroup, useRadioGroupContext, GroupRadio } from '../../wrappers/RadioGroup/RadioGroup';
|
|
6
|
+
export type { RadioGroupProps as PresetRadioGroupProps, RadioGroupOption, RadioGroupContextValue, GroupRadioProps } from '../../wrappers/RadioGroup/RadioGroup';
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
export interface SliderMark {
|
|
4
|
+
value: number;
|
|
5
|
+
label?: React.ReactNode;
|
|
6
|
+
}
|
|
7
|
+
export interface PresetRangeSliderProps {
|
|
8
|
+
size?: SharedSize;
|
|
9
|
+
value?: [number, number];
|
|
10
|
+
defaultValue?: [number, number];
|
|
11
|
+
onChange?: (value: [number, number]) => void;
|
|
12
|
+
onChangeEnd?: (value: [number, number]) => void;
|
|
13
|
+
min?: number;
|
|
14
|
+
max?: number;
|
|
15
|
+
step?: number;
|
|
16
|
+
minDistance?: number;
|
|
17
|
+
marks?: boolean | SliderMark[];
|
|
18
|
+
showValue?: boolean;
|
|
19
|
+
formatValue?: (value: number) => string;
|
|
20
|
+
orientation?: 'horizontal' | 'vertical';
|
|
21
|
+
disabled?: boolean;
|
|
22
|
+
label?: string;
|
|
23
|
+
helperText?: string;
|
|
24
|
+
id?: string;
|
|
25
|
+
name?: string;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* RangeSlider with dual thumbs, semantic size API. Wraps BaseRangeSlider.
|
|
29
|
+
*/
|
|
30
|
+
export declare const PresetRangeSlider: React.ForwardRefExoticComponent<PresetRangeSliderProps & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
export interface PresetRatingProps {
|
|
4
|
+
size?: SharedSize;
|
|
5
|
+
value?: number;
|
|
6
|
+
defaultValue?: number;
|
|
7
|
+
onChange?: (value: number) => void;
|
|
8
|
+
max?: number;
|
|
9
|
+
allowHalf?: boolean;
|
|
10
|
+
readOnly?: boolean;
|
|
11
|
+
disabled?: boolean;
|
|
12
|
+
icon?: string;
|
|
13
|
+
emptyIcon?: string;
|
|
14
|
+
children?: React.ReactNode;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Rating with semantic size API. Wraps BaseRating.
|
|
18
|
+
*/
|
|
19
|
+
export declare const PresetRating: React.ForwardRefExoticComponent<PresetRatingProps & Omit<React.HTMLAttributes<HTMLDivElement>, "style" | "className"> & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
import { IconValue } from '../../types/icon';
|
|
4
|
+
export type PresetSegmentedControlVariant = 'default' | 'filled';
|
|
5
|
+
export interface SegmentedControlOption {
|
|
6
|
+
value: string;
|
|
7
|
+
label: React.ReactNode;
|
|
8
|
+
icon?: IconValue;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
}
|
|
11
|
+
export interface PresetSegmentedControlProps {
|
|
12
|
+
variant?: PresetSegmentedControlVariant;
|
|
13
|
+
size?: SharedSize;
|
|
14
|
+
options?: SegmentedControlOption[];
|
|
15
|
+
value?: string;
|
|
16
|
+
defaultValue?: string;
|
|
17
|
+
onChange?: (value: string) => void;
|
|
18
|
+
disabled?: boolean;
|
|
19
|
+
fullWidth?: boolean;
|
|
20
|
+
children?: React.ReactNode;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* SegmentedControl with semantic variant/size API. Wraps BaseSegmentedControl.
|
|
24
|
+
*/
|
|
25
|
+
export declare function PresetSegmentedControl(props: PresetSegmentedControlProps): import("react/jsx-runtime").JSX.Element;
|
|
26
|
+
export declare namespace PresetSegmentedControl {
|
|
27
|
+
var displayName: string;
|
|
28
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
import { IconValue } from '../../types/icon';
|
|
4
|
+
export interface SelectOption<T = string> {
|
|
5
|
+
value: T;
|
|
6
|
+
label: React.ReactNode;
|
|
7
|
+
triggerLabel?: React.ReactNode;
|
|
8
|
+
icon?: IconValue;
|
|
9
|
+
description?: React.ReactNode;
|
|
10
|
+
disabled?: boolean;
|
|
11
|
+
}
|
|
12
|
+
export interface SelectTriggerRenderProps<T = string> {
|
|
13
|
+
selectedOption: SelectOption<T> | undefined;
|
|
14
|
+
isOpen: boolean;
|
|
15
|
+
placeholder: React.ReactNode;
|
|
16
|
+
}
|
|
17
|
+
export interface SelectOptionRenderProps<T = string> {
|
|
18
|
+
option: SelectOption<T>;
|
|
19
|
+
isSelected: boolean;
|
|
20
|
+
isDisabled: boolean;
|
|
21
|
+
}
|
|
22
|
+
export interface SelectOptionGroup<T = string> {
|
|
23
|
+
label: string;
|
|
24
|
+
options: SelectOption<T>[];
|
|
25
|
+
}
|
|
26
|
+
export declare const SELECT_VARIANTS: readonly ["default", "error", "success"];
|
|
27
|
+
export type PresetSelectVariant = (typeof SELECT_VARIANTS)[number];
|
|
28
|
+
export interface PresetSelectProps<T = string> {
|
|
29
|
+
variant?: PresetSelectVariant;
|
|
30
|
+
size?: SharedSize;
|
|
31
|
+
options: SelectOption<T>[] | SelectOptionGroup<T>[];
|
|
32
|
+
value?: T | T[];
|
|
33
|
+
onChange?: (value: T | T[], option: SelectOption<T> | SelectOption<T>[]) => void;
|
|
34
|
+
placeholder?: React.ReactNode;
|
|
35
|
+
renderTrigger?: (props: SelectTriggerRenderProps<T>) => React.ReactNode;
|
|
36
|
+
renderOption?: (props: SelectOptionRenderProps<T>) => React.ReactNode;
|
|
37
|
+
searchable?: boolean;
|
|
38
|
+
searchPlaceholder?: string;
|
|
39
|
+
clearable?: boolean;
|
|
40
|
+
onClear?: () => void;
|
|
41
|
+
multiple?: boolean;
|
|
42
|
+
multiDisplayMode?: 'chips' | 'count' | 'text';
|
|
43
|
+
maxChips?: number;
|
|
44
|
+
creatable?: boolean;
|
|
45
|
+
onCreate?: (value: string) => void;
|
|
46
|
+
disabled?: boolean;
|
|
47
|
+
maxSelections?: number;
|
|
48
|
+
onSearch?: (query: string) => void;
|
|
49
|
+
showSelectionIndicator?: boolean;
|
|
50
|
+
children?: React.ReactNode;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* Select with semantic variant/size API. Wraps BaseSelect structural container.
|
|
54
|
+
* The full search/multi/keyboard state machine is preserved from the original Select.
|
|
55
|
+
*/
|
|
56
|
+
export declare function PresetSelect<T = string>(props: PresetSelectProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
57
|
+
export declare namespace PresetSelect {
|
|
58
|
+
var displayName: string;
|
|
59
|
+
}
|
|
60
|
+
export { BaseSelectTrigger as SelectTrigger } from '../../base/BaseSelect/BaseSelect';
|
|
61
|
+
export { BaseSelectDropdown as SelectDropdown } from '../../base/BaseSelect/BaseSelect';
|
|
62
|
+
export { BaseSelectOption as SelectOption_ } from '../../base/BaseSelect/BaseSelect';
|
|
63
|
+
export { BaseSelectGroup as SelectGroup } from '../../base/BaseSelect/BaseSelect';
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
export interface SliderMark {
|
|
4
|
+
value: number;
|
|
5
|
+
label?: React.ReactNode;
|
|
6
|
+
}
|
|
7
|
+
export interface PresetSliderProps {
|
|
8
|
+
size?: SharedSize;
|
|
9
|
+
min?: number;
|
|
10
|
+
max?: number;
|
|
11
|
+
step?: number;
|
|
12
|
+
value?: number;
|
|
13
|
+
defaultValue?: number;
|
|
14
|
+
onChange?: (value: number) => void;
|
|
15
|
+
onChangeEnd?: (value: number) => void;
|
|
16
|
+
marks?: boolean | SliderMark[];
|
|
17
|
+
showValue?: boolean;
|
|
18
|
+
formatValue?: (value: number) => string;
|
|
19
|
+
orientation?: 'horizontal' | 'vertical';
|
|
20
|
+
disabled?: boolean;
|
|
21
|
+
children?: React.ReactNode;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Slider with semantic size API. Wraps BaseSlider.
|
|
25
|
+
*/
|
|
26
|
+
export declare function PresetSlider(props: PresetSliderProps): import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
export declare namespace PresetSlider {
|
|
28
|
+
var displayName: string;
|
|
29
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @deprecated Moved to composites/overlay/ tier (Phase 25.1).
|
|
3
|
+
* Use `import * as UI from '@mt-gloss/ui/catalog'` -> `<UI.SplitButton>` instead.
|
|
4
|
+
*/
|
|
5
|
+
export { SplitButton as PresetSplitButton } from '../../composites/overlay/SplitButton/SplitButton';
|
|
6
|
+
export type { SplitButtonProps as PresetSplitButtonProps, SplitButtonMenuItem } from '../../composites/overlay/SplitButton/SplitButton';
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
export interface SwatchOption {
|
|
2
|
+
value: string;
|
|
3
|
+
colorToken?: string;
|
|
4
|
+
color?: string;
|
|
5
|
+
label?: string;
|
|
6
|
+
disabled?: boolean;
|
|
7
|
+
}
|
|
8
|
+
export interface PresetSwatchRowProps {
|
|
9
|
+
swatches: SwatchOption[];
|
|
10
|
+
value?: string;
|
|
11
|
+
defaultValue?: string;
|
|
12
|
+
onChange?: (value: string) => void;
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
name: string;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* PresetSwatchRow — Preset-tier wrapper around RadioGroup.
|
|
18
|
+
* Conceptually equivalent to createPreset(RadioGroup, swatchVariants) — hand-written
|
|
19
|
+
* because RadioGroup is Wrapper-tier. Per D-02.
|
|
20
|
+
*
|
|
21
|
+
* Renders a horizontal row of circular color swatches with radio-group semantics.
|
|
22
|
+
* All colors derive from design tokens — no hardcoded palette values.
|
|
23
|
+
* Generic: no reptime domain strings in props. D-10, D-11 compliant.
|
|
24
|
+
*/
|
|
25
|
+
export declare function PresetSwatchRow({ swatches, value, defaultValue, onChange, disabled, name, }: PresetSwatchRowProps): import("react/jsx-runtime").JSX.Element;
|
|
26
|
+
export declare namespace PresetSwatchRow {
|
|
27
|
+
var displayName: string;
|
|
28
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { PolymorphicProps } from '../../base/types';
|
|
3
|
+
import { SharedSize } from '../types';
|
|
4
|
+
export declare const TEXT_VARIANTS: readonly ["body", "caption", "overline"];
|
|
5
|
+
export type PresetTextVariant = (typeof TEXT_VARIANTS)[number];
|
|
6
|
+
export interface PresetTextProps {
|
|
7
|
+
variant?: PresetTextVariant;
|
|
8
|
+
size?: SharedSize;
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Text with semantic variant/size API. Wraps BaseText.
|
|
13
|
+
*/
|
|
14
|
+
export declare const PresetText: {
|
|
15
|
+
<C extends React.ElementType = "span">(props: PolymorphicProps<C, PresetTextProps>): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
displayName: string;
|
|
17
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
export type PresetTextareaVariant = 'default' | 'error' | 'success';
|
|
4
|
+
export interface PresetTextareaProps extends Omit<React.TextareaHTMLAttributes<HTMLTextAreaElement>, 'className' | 'style'> {
|
|
5
|
+
variant?: PresetTextareaVariant;
|
|
6
|
+
size?: SharedSize;
|
|
7
|
+
label?: string;
|
|
8
|
+
helperText?: string;
|
|
9
|
+
status?: 'default' | 'error' | 'success';
|
|
10
|
+
/** Show character counter (requires maxLength) */
|
|
11
|
+
showCounter?: boolean;
|
|
12
|
+
/** Custom counter renderer */
|
|
13
|
+
renderCounter?: (current: number, max: number) => React.ReactNode;
|
|
14
|
+
/** @deprecated Use showCounter instead */
|
|
15
|
+
showCount?: boolean;
|
|
16
|
+
/** Auto-grow/shrink the textarea based on content */
|
|
17
|
+
autoResize?: boolean;
|
|
18
|
+
minRows?: number;
|
|
19
|
+
maxRows?: number;
|
|
20
|
+
resize?: 'none' | 'vertical' | 'both';
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Textarea with semantic variant/size API. Wraps BaseTextarea.
|
|
24
|
+
*/
|
|
25
|
+
export declare const PresetTextarea: React.ForwardRefExoticComponent<PresetTextareaProps & React.RefAttributes<HTMLTextAreaElement>>;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
export declare const TIMEPICKER_VARIANTS: readonly ["default", "error", "success"];
|
|
4
|
+
export type PresetTimePickerVariant = (typeof TIMEPICKER_VARIANTS)[number];
|
|
5
|
+
export interface PresetTimePickerProps {
|
|
6
|
+
variant?: PresetTimePickerVariant;
|
|
7
|
+
size?: SharedSize;
|
|
8
|
+
value?: string;
|
|
9
|
+
defaultValue?: string;
|
|
10
|
+
onChange?: (time: string) => void;
|
|
11
|
+
format?: '12h' | '24h';
|
|
12
|
+
showSeconds?: boolean;
|
|
13
|
+
step?: number;
|
|
14
|
+
minTime?: string;
|
|
15
|
+
maxTime?: string;
|
|
16
|
+
placeholder?: string;
|
|
17
|
+
label?: string;
|
|
18
|
+
helperText?: string;
|
|
19
|
+
disabled?: boolean;
|
|
20
|
+
clearable?: boolean;
|
|
21
|
+
id?: string;
|
|
22
|
+
name?: string;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* TimePicker with scrollable time options, variant styling, and size scale.
|
|
26
|
+
*/
|
|
27
|
+
export declare const PresetTimePicker: React.ForwardRefExoticComponent<PresetTimePickerProps & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { PolymorphicProps } from '../../base/types';
|
|
3
|
+
export declare const TITLE_VARIANTS: readonly ["page", "section", "subsection", "card"];
|
|
4
|
+
export type PresetTitleVariant = (typeof TITLE_VARIANTS)[number];
|
|
5
|
+
type HeadingLevel = 1 | 2 | 3 | 4 | 5 | 6;
|
|
6
|
+
export interface PresetTitleProps {
|
|
7
|
+
variant?: PresetTitleVariant;
|
|
8
|
+
level?: HeadingLevel;
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Title with semantic variant/level API. Wraps BaseTitle.
|
|
13
|
+
* `level` controls the HTML element (h1-h6), `variant` controls visual styling.
|
|
14
|
+
*/
|
|
15
|
+
export declare const PresetTitle: {
|
|
16
|
+
<C extends React.ElementType = "h2">(props: PolymorphicProps<C, PresetTitleProps>): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
displayName: string;
|
|
18
|
+
};
|
|
19
|
+
export {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export type PresetToastVariant = 'info' | 'success' | 'warning' | 'error';
|
|
3
|
+
export type PresetToastPosition = 'top-right' | 'top-left' | 'bottom-right' | 'bottom-left' | 'top-center' | 'bottom-center';
|
|
4
|
+
export interface PresetToastProps {
|
|
5
|
+
open: boolean;
|
|
6
|
+
onDismiss?: () => void;
|
|
7
|
+
variant?: PresetToastVariant;
|
|
8
|
+
position?: PresetToastPosition;
|
|
9
|
+
/** Auto-dismiss duration in ms. Default 5000. Set 0 to disable. */
|
|
10
|
+
duration?: number;
|
|
11
|
+
children?: React.ReactNode;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Notification toast with semantic variant and auto-dismiss. Wraps BaseToast.
|
|
15
|
+
*/
|
|
16
|
+
export declare function PresetToast({ open, onDismiss, variant, position, duration, children, }: PresetToastProps): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
export declare namespace PresetToast {
|
|
18
|
+
var displayName: string;
|
|
19
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { SharedSize } from '../types';
|
|
3
|
+
export type PresetToggleVariant = 'default' | 'success' | 'error';
|
|
4
|
+
export interface PresetToggleProps {
|
|
5
|
+
variant?: PresetToggleVariant;
|
|
6
|
+
size?: SharedSize;
|
|
7
|
+
label?: React.ReactNode;
|
|
8
|
+
onLabel?: React.ReactNode;
|
|
9
|
+
offLabel?: React.ReactNode;
|
|
10
|
+
helperText?: string;
|
|
11
|
+
checked?: boolean;
|
|
12
|
+
defaultChecked?: boolean;
|
|
13
|
+
onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
14
|
+
onCheckedChange?: (checked: boolean) => void;
|
|
15
|
+
disabled?: boolean;
|
|
16
|
+
id?: string;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Toggle/Switch with semantic variant/size API. Wraps BaseToggle.
|
|
20
|
+
*/
|
|
21
|
+
export declare const PresetToggle: React.ForwardRefExoticComponent<PresetToggleProps & React.RefAttributes<HTMLInputElement>>;
|