@chassis-ui/react 0.1.2 → 0.2.0
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/dist/accordion.d.ts +2 -0
- package/dist/accordion.js +1 -0
- package/dist/autocomplete.d.ts +2 -0
- package/dist/autocomplete.js +1 -0
- package/dist/avatar.d.ts +2 -0
- package/dist/avatar.js +1 -0
- package/dist/badge.d.ts +2 -0
- package/dist/badge.js +1 -0
- package/dist/breadcrumb.d.ts +2 -0
- package/dist/breadcrumb.js +1 -0
- package/dist/button-group.d.ts +2 -0
- package/dist/button-group.js +1 -0
- package/dist/button.d.ts +3 -0
- package/dist/button.js +1 -0
- package/dist/calendar.d.ts +3 -0
- package/dist/calendar.js +1 -0
- package/dist/card.d.ts +2 -0
- package/dist/card.js +1 -0
- package/dist/carousel.d.ts +2 -0
- package/dist/carousel.js +1 -0
- package/dist/checkbox.d.ts +3 -0
- package/dist/checkbox.js +1 -0
- package/dist/chip-input.d.ts +2 -0
- package/dist/chip-input.js +1 -0
- package/dist/chip.d.ts +2 -0
- package/dist/chip.js +1 -0
- package/dist/chunks/Button-Cptd4Yk7.d.ts +65 -0
- package/dist/chunks/Button-I0aUy5h-.js +1 -0
- package/dist/chunks/Chip-D0Cw0mAr.js +1 -0
- package/dist/chunks/CloseButton-DJM7FRKh.js +1 -0
- package/dist/chunks/ComboboxItem-C9TpoJOI.d.ts +54 -0
- package/dist/chunks/ComboboxListBox-BhO8uRNg.js +1 -0
- package/dist/chunks/FormHelp-Be2PQL0y.js +1 -0
- package/dist/chunks/FormLabel-CYcQiFUI.js +1 -0
- package/dist/chunks/Icon-BIwkD-kx.js +1 -0
- package/dist/chunks/Icon-CioraWLF.d.ts +36 -0
- package/dist/chunks/Link-B0Y1xgYi.d.ts +69 -0
- package/dist/chunks/Link-Cq7FNWpm.js +1 -0
- package/dist/chunks/MenuItemDef-D0VDtYIQ.d.ts +82 -0
- package/dist/chunks/RangeCalendar-COnSfurr.js +1 -0
- package/dist/chunks/accordion-okRicuG5.js +1 -0
- package/dist/chunks/autocomplete-B0xTc6kg.js +1 -0
- package/dist/chunks/avatar-Bjm0DlPO.js +1 -0
- package/dist/chunks/badge-Bj8mf8lu.js +1 -0
- package/dist/chunks/breadcrumb-DDxnx_iS.js +1 -0
- package/dist/chunks/breakpoints-SLMTNHF9.d.ts +5 -0
- package/dist/chunks/breakpoints-o_2Ev7ir.js +1 -0
- package/dist/chunks/button-group-CPZYA6aZ.js +1 -0
- package/dist/chunks/card-DfF2K_5p.js +1 -0
- package/dist/chunks/carousel-DEvwcA7H.js +1 -0
- package/dist/chunks/checkbox-BFPS0pD6.js +1 -0
- package/dist/chunks/chip-input-CB1lE6vP.js +1 -0
- package/dist/chunks/collapse-WifcChO8.js +1 -0
- package/dist/chunks/color-input-CyRaLR_G.js +1 -0
- package/dist/chunks/combobox-DWEj-Sv7.js +1 -0
- package/dist/chunks/datagrid-nbnNThsT.js +2 -0
- package/dist/chunks/dateRangePresets-R1FtA1zp.d.ts +41 -0
- package/dist/chunks/datepicker-CslLKMm1.js +1 -0
- package/dist/chunks/dialogTransition-i9vw0i2Z.js +1 -0
- package/dist/chunks/direction-CPhdeL3A.js +1 -0
- package/dist/chunks/drawer-zReFjoJG.js +1 -0
- package/dist/chunks/file-input-RRqZSzjH.js +1 -0
- package/dist/chunks/flex-BTvpgaRv.js +1 -0
- package/dist/chunks/floating-input-CIC9Lm2a.js +1 -0
- package/dist/chunks/focus-ring-SR_LwaN7.js +1 -0
- package/dist/chunks/focusRedirect-BrvK3U_o.js +1 -0
- package/dist/chunks/form-GpdAyWWi.js +1 -0
- package/dist/chunks/form-field-BjQ9SIjx.js +1 -0
- package/dist/chunks/grid-CuFw89yV.js +1 -0
- package/dist/chunks/icon-mxYpL5nL.js +1 -0
- package/dist/chunks/iconConfig-Bu6Pt9o3.d.ts +69 -0
- package/dist/chunks/iconSlot-BmWxJh27.js +1 -0
- package/dist/chunks/index--0_IpTDT.d.ts +17 -0
- package/dist/chunks/index-6uob77s9.d.ts +80 -0
- package/dist/chunks/index-8PhBSbNQ.d.ts +93 -0
- package/dist/chunks/index-B0-8n-Gs.d.ts +105 -0
- package/dist/chunks/index-B8uaSJA9.d.ts +95 -0
- package/dist/chunks/index-BA-raEMm.d.ts +28 -0
- package/dist/chunks/index-BDfh8YBc.d.ts +39 -0
- package/dist/chunks/index-BKMW0rkw.d.ts +80 -0
- package/dist/chunks/index-BO9jLOIb.d.ts +58 -0
- package/dist/chunks/index-BO_1MN66.d.ts +87 -0
- package/dist/chunks/index-BTDgfLxK.d.ts +94 -0
- package/dist/chunks/index-BTTeKpiE.d.ts +363 -0
- package/dist/chunks/index-BVGGIaPX.d.ts +110 -0
- package/dist/chunks/index-Bi8FFadV.d.ts +98 -0
- package/dist/chunks/index-Bkj17NEQ.d.ts +50 -0
- package/dist/chunks/index-BlgkO3dn.d.ts +280 -0
- package/dist/chunks/index-BxTlIaZu.d.ts +301 -0
- package/dist/chunks/index-C61tPIJ-.d.ts +50 -0
- package/dist/chunks/index-CCXJXToc.d.ts +52 -0
- package/dist/chunks/index-CJzKu7QI.d.ts +40 -0
- package/dist/chunks/index-COsIPd8L.d.ts +62 -0
- package/dist/chunks/index-COsYSDrz.d.ts +109 -0
- package/dist/chunks/index-CRfm7W6C.d.ts +230 -0
- package/dist/chunks/index-CVUMS0x7.d.ts +73 -0
- package/dist/chunks/index-CaQ1JY5D.d.ts +49 -0
- package/dist/chunks/index-Cf2n0l0U.d.ts +138 -0
- package/dist/chunks/index-CftERHnE.d.ts +24 -0
- package/dist/chunks/index-ClT3E_hv.d.ts +302 -0
- package/dist/chunks/index-CsMIgBsd.d.ts +39 -0
- package/dist/chunks/index-Ctuk1xBU.d.ts +99 -0
- package/dist/chunks/index-D2VVO8rx.d.ts +49 -0
- package/dist/chunks/index-D949AidR.d.ts +40 -0
- package/dist/chunks/index-D9PZHY_I.d.ts +135 -0
- package/dist/chunks/index-DAoPg59I.d.ts +80 -0
- package/dist/chunks/index-DB_ToPdz.d.ts +202 -0
- package/dist/chunks/index-DEb9zXlC.d.ts +210 -0
- package/dist/chunks/index-DHGgezXU.d.ts +58 -0
- package/dist/chunks/index-DJJocp_q.d.ts +132 -0
- package/dist/chunks/index-DKma0jQw.d.ts +104 -0
- package/dist/chunks/index-DPV62IdF.d.ts +118 -0
- package/dist/chunks/index-DR8sYtvd.d.ts +296 -0
- package/dist/chunks/index-Dcc_W6Kv.d.ts +146 -0
- package/dist/chunks/index-Dfg4Ftb8.d.ts +68 -0
- package/dist/chunks/index-Dfy1YW5j.d.ts +73 -0
- package/dist/chunks/index-Dh5CaHTP.d.ts +44 -0
- package/dist/chunks/index-DtbUXxjz.d.ts +53 -0
- package/dist/chunks/index-Dum6Y9XR.d.ts +187 -0
- package/dist/chunks/index-HrKN6s8z.d.ts +66 -0
- package/dist/chunks/index-JllMXhVx.d.ts +176 -0
- package/dist/chunks/index-XjLvaH4G.d.ts +67 -0
- package/dist/chunks/index-dh3TKanY.d.ts +235 -0
- package/dist/chunks/index-nklPDKlC.d.ts +137 -0
- package/dist/chunks/index-qgZ5VGmc.d.ts +177 -0
- package/dist/chunks/index-tOodmT36.d.ts +129 -0
- package/dist/chunks/index-t_x6jj7l.d.ts +96 -0
- package/dist/chunks/input-adorn-C_EHML68.js +1 -0
- package/dist/chunks/input-group-iI7azfvE.js +1 -0
- package/dist/chunks/list-CMr-wB9d.js +1 -0
- package/dist/chunks/menu-CXUc-Gva.js +1 -0
- package/dist/chunks/modal-ByIj71Mq.js +1 -0
- package/dist/chunks/nav-BldxFo_B.js +1 -0
- package/dist/chunks/navbar-BwcsQuBk.js +1 -0
- package/dist/chunks/notification-DdqigVB1.js +1 -0
- package/dist/chunks/otp-input-CXe_wkII.js +1 -0
- package/dist/chunks/overlayPlacement-B7843a-Q.d.ts +6 -0
- package/dist/chunks/overlayPlacement-BtS90IVf.js +1 -0
- package/dist/chunks/pagination-BOpEAYW2.js +1 -0
- package/dist/chunks/password-strength-BfLiYiGj.js +1 -0
- package/dist/chunks/placeholder-pg95KELl.js +1 -0
- package/dist/chunks/polymorphic-CACPOv1_.js +1 -0
- package/dist/chunks/polymorphic-CVHbTHSN.d.ts +40 -0
- package/dist/chunks/popover-BpSfnZzk.js +1 -0
- package/dist/chunks/progress-DlrZ71aV.js +1 -0
- package/dist/chunks/radio-BV7Sq6D1.js +1 -0
- package/dist/chunks/range-input-BN3430j-.js +1 -0
- package/dist/chunks/renderFormCheck-BXBs6_ov.js +1 -0
- package/dist/chunks/renderFormCheck-CYWG-Rbt.d.ts +23 -0
- package/dist/chunks/renderFormField-fBEny6JV.d.ts +14 -0
- package/dist/chunks/renderFormField-wiaxvvLG.js +1 -0
- package/dist/chunks/renderMenuItemContent-CmqT3YUQ.js +1 -0
- package/dist/chunks/select-CclIIux8.js +1 -0
- package/dist/chunks/skeleton-CKq76sE_.js +1 -0
- package/dist/chunks/spacingClassName-DVhk8m3P.js +1 -0
- package/dist/chunks/spinner-BEq4PAlu.js +1 -0
- package/dist/chunks/stack-D3retZ-W.js +1 -0
- package/dist/chunks/static-table-D0M4oc_t.js +1 -0
- package/dist/chunks/stepper-CTa6e8uv.js +1 -0
- package/dist/chunks/switch-BmHpq4tL.js +1 -0
- package/dist/chunks/table-Fme9GbAR.js +1 -0
- package/dist/chunks/tableClassName-CZA2Bse8.js +1 -0
- package/dist/chunks/tabs-BnbMJM_b.js +1 -0
- package/dist/chunks/text-input-DD3d08Yf.js +1 -0
- package/dist/chunks/textarea-C0qQdCcu.js +1 -0
- package/dist/chunks/toast-BQhZ2pv5.js +1 -0
- package/dist/chunks/tooltip-DHtVAYUo.js +1 -0
- package/dist/chunks/triggerElement-BIqA4KqZ.js +1 -0
- package/dist/chunks/types-CS_40Txv.d.ts +34 -0
- package/dist/chunks/useButtonSemantics-CILM_lhi.js +1 -0
- package/dist/chunks/useDialogElement-BRIU60cT.js +1 -0
- package/dist/chunks/useDisabledAnchorGuard-Cz58UCXy.js +1 -0
- package/dist/chunks/useFloatingOverlay-CcmDZKMK.js +1 -0
- package/dist/chunks/useForkedRef-DVEfT-KI.js +1 -0
- package/dist/chunks/useFormField-BOqmBTC4.js +1 -0
- package/dist/chunks/useIsomorphicLayoutEffect-BbqRwuqn.js +1 -0
- package/dist/chunks/useToastRegionQueue-BH6bWZ73.js +1 -0
- package/dist/chunks/validationClassName-gRGs4KBm.js +1 -0
- package/dist/close-button.d.ts +2 -0
- package/dist/close-button.js +1 -0
- package/dist/collapse.d.ts +2 -0
- package/dist/collapse.js +1 -0
- package/dist/color-input.d.ts +2 -0
- package/dist/color-input.js +1 -0
- package/dist/combobox.d.ts +3 -0
- package/dist/combobox.js +1 -0
- package/dist/datagrid.d.ts +2 -0
- package/dist/datagrid.js +1 -0
- package/dist/datepicker.d.ts +2 -0
- package/dist/datepicker.js +1 -0
- package/dist/drawer.d.ts +2 -0
- package/dist/drawer.js +1 -0
- package/dist/file-input.d.ts +2 -0
- package/dist/file-input.js +1 -0
- package/dist/flex.d.ts +2 -0
- package/dist/flex.js +1 -0
- package/dist/floating-input.d.ts +2 -0
- package/dist/floating-input.js +1 -0
- package/dist/form-field.d.ts +2 -0
- package/dist/form-field.js +1 -0
- package/dist/form.d.ts +2 -0
- package/dist/form.js +1 -0
- package/dist/grid.d.ts +2 -0
- package/dist/grid.js +1 -0
- package/dist/icon.d.ts +4 -0
- package/dist/icon.js +1 -0
- package/dist/index.d.ts +72 -6354
- package/dist/index.js +1 -2
- package/dist/input-adorn.d.ts +2 -0
- package/dist/input-adorn.js +1 -0
- package/dist/input-group.d.ts +2 -0
- package/dist/input-group.js +1 -0
- package/dist/link.d.ts +3 -0
- package/dist/link.js +1 -0
- package/dist/list.d.ts +2 -0
- package/dist/list.js +1 -0
- package/dist/menu.d.ts +3 -0
- package/dist/menu.js +1 -0
- package/dist/modal.d.ts +2 -0
- package/dist/modal.js +1 -0
- package/dist/nav.d.ts +2 -0
- package/dist/nav.js +1 -0
- package/dist/navbar.d.ts +2 -0
- package/dist/navbar.js +1 -0
- package/dist/notification.d.ts +2 -0
- package/dist/notification.js +1 -0
- package/dist/otp-input.d.ts +2 -0
- package/dist/otp-input.js +1 -0
- package/dist/pagination.d.ts +2 -0
- package/dist/pagination.js +1 -0
- package/dist/password-strength.d.ts +2 -0
- package/dist/password-strength.js +1 -0
- package/dist/placeholder.d.ts +2 -0
- package/dist/placeholder.js +1 -0
- package/dist/popover.d.ts +2 -0
- package/dist/popover.js +1 -0
- package/dist/progress.d.ts +2 -0
- package/dist/progress.js +1 -0
- package/dist/radio.d.ts +2 -0
- package/dist/radio.js +1 -0
- package/dist/range-input.d.ts +2 -0
- package/dist/range-input.js +1 -0
- package/dist/select.d.ts +2 -0
- package/dist/select.js +1 -0
- package/dist/skeleton.d.ts +2 -0
- package/dist/skeleton.js +1 -0
- package/dist/spinner.d.ts +2 -0
- package/dist/spinner.js +1 -0
- package/dist/stack.d.ts +2 -0
- package/dist/stack.js +1 -0
- package/dist/static-table.d.ts +2 -0
- package/dist/static-table.js +1 -0
- package/dist/stepper.d.ts +2 -0
- package/dist/stepper.js +1 -0
- package/dist/style.css +1 -1
- package/dist/switch.d.ts +2 -0
- package/dist/switch.js +1 -0
- package/dist/table.d.ts +2 -0
- package/dist/table.js +1 -0
- package/dist/tabs.d.ts +2 -0
- package/dist/tabs.js +1 -0
- package/dist/text-input.d.ts +2 -0
- package/dist/text-input.js +1 -0
- package/dist/textarea.d.ts +2 -0
- package/dist/textarea.js +1 -0
- package/dist/toast.d.ts +2 -0
- package/dist/toast.js +1 -0
- package/dist/tooltip.d.ts +2 -0
- package/dist/tooltip.js +1 -0
- package/package.json +62 -4
- package/src/components/accordion/index.ts +4 -0
- package/src/components/autocomplete/index.ts +4 -0
- package/src/components/avatar/index.ts +4 -0
- package/src/components/badge/index.ts +4 -0
- package/src/components/breadcrumb/index.ts +4 -0
- package/src/components/button/index.ts +4 -0
- package/src/components/button-group/index.ts +4 -0
- package/src/components/calendar/index.ts +4 -0
- package/src/components/card/index.ts +4 -0
- package/src/components/carousel/CarouselControlButton.tsx +11 -4
- package/src/components/carousel/CarouselControlNext.tsx +6 -0
- package/src/components/carousel/CarouselControlPrev.tsx +6 -0
- package/src/components/carousel/CarouselPlayPause.tsx +27 -4
- package/src/components/carousel/index.ts +4 -0
- package/src/components/checkbox/Checkbox.tsx +19 -4
- package/src/components/checkbox/index.ts +4 -0
- package/src/components/chip/index.ts +4 -0
- package/src/components/chip-input/index.ts +4 -0
- package/src/components/close-button/index.ts +4 -0
- package/src/components/collapse/index.ts +4 -0
- package/src/components/color-input/index.ts +4 -0
- package/src/components/combobox/ComboboxListBox.tsx +2 -2
- package/src/components/combobox/index.ts +4 -0
- package/src/components/datagrid/index.ts +4 -0
- package/src/components/datepicker/index.ts +4 -0
- package/src/components/drawer/index.ts +8 -0
- package/src/components/file-input/index.ts +4 -0
- package/src/components/flex/index.ts +4 -0
- package/src/components/floating-input/index.ts +4 -0
- package/src/components/form/index.ts +4 -0
- package/src/components/form-field/index.ts +4 -0
- package/src/components/grid/index.ts +4 -0
- package/src/components/icon/Icon.tsx +69 -38
- package/src/components/icon/IconProvider.tsx +40 -0
- package/src/components/icon/index.ts +7 -0
- package/src/components/input-adorn/index.ts +4 -0
- package/src/components/input-group/index.ts +4 -0
- package/src/components/link/index.ts +4 -0
- package/src/components/list/index.ts +4 -0
- package/src/components/menu/index.ts +4 -0
- package/src/components/modal/index.ts +8 -0
- package/src/components/nav/index.ts +4 -0
- package/src/components/navbar/NavbarToggler.tsx +9 -3
- package/src/components/navbar/index.ts +4 -0
- package/src/components/notification/Notification.tsx +6 -5
- package/src/components/notification/index.ts +8 -0
- package/src/components/otp-input/index.ts +4 -0
- package/src/components/pagination/Pagination.tsx +16 -3
- package/src/components/pagination/index.ts +8 -0
- package/src/components/password-strength/index.ts +4 -0
- package/src/components/placeholder/index.ts +4 -0
- package/src/components/popover/index.ts +4 -0
- package/src/components/progress/index.ts +4 -0
- package/src/components/radio/Radio.tsx +13 -3
- package/src/components/radio/index.ts +4 -0
- package/src/components/range-input/index.ts +4 -0
- package/src/components/select/index.ts +4 -0
- package/src/components/skeleton/SkeletonLoader.tsx +13 -6
- package/src/components/skeleton/index.ts +4 -0
- package/src/components/spinner/index.ts +4 -0
- package/src/components/stack/index.ts +4 -0
- package/src/components/static-table/StaticTable.tsx +78 -0
- package/src/components/static-table/index.ts +8 -0
- package/src/components/stepper/index.ts +4 -0
- package/src/components/switch/Switch.tsx +16 -3
- package/src/components/switch/index.ts +4 -0
- package/src/components/table/Table.tsx +14 -22
- package/src/components/table/index.ts +4 -0
- package/src/components/tabs/index.ts +4 -0
- package/src/components/text-input/index.ts +4 -0
- package/src/components/textarea/index.ts +4 -0
- package/src/components/toast/Toast.tsx +2 -1
- package/src/components/toast/ToastHeader.tsx +4 -3
- package/src/components/toast/index.ts +8 -0
- package/src/components/tooltip/index.ts +4 -0
- package/src/hooks/useIconConfig.ts +6 -0
- package/src/index.ts +24 -4
- package/src/utils/iconConfig.ts +88 -0
- package/src/utils/iconSlot.tsx +41 -0
- package/src/utils/polymorphic.ts +49 -2
- package/src/utils/renderMenuItemContent.tsx +4 -9
- package/src/utils/slot.tsx +78 -0
- package/src/utils/tableClassName.ts +93 -0
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import "./focus-ring-SR_LwaN7.js";
|
|
2
|
+
import { n as PolymorphicRef, t as PolymorphicComponentProps } from "./polymorphic-CVHbTHSN.js";
|
|
3
|
+
import { n as ContextColor } from "./types-CS_40Txv.js";
|
|
4
|
+
import { ElementType, ReactElement } from "react";
|
|
5
|
+
//#region src/components/spinner/Spinner.d.ts
|
|
6
|
+
type SpinnerOwnProps<C extends ElementType> = {
|
|
7
|
+
/**
|
|
8
|
+
* A string of all className you want applied to the component.
|
|
9
|
+
*/
|
|
10
|
+
className?: string;
|
|
11
|
+
/**
|
|
12
|
+
* Sets the color of the component to one of Chassis context colors.
|
|
13
|
+
*/
|
|
14
|
+
color?: ContextColor;
|
|
15
|
+
/**
|
|
16
|
+
* Component used for the root node. Either a string to use a HTML element or a component.
|
|
17
|
+
*/
|
|
18
|
+
component?: C;
|
|
19
|
+
/**
|
|
20
|
+
* Size the component sm.
|
|
21
|
+
*/
|
|
22
|
+
size?: 'sm';
|
|
23
|
+
/**
|
|
24
|
+
* Set the button variant to an outlined button or a ghost button.
|
|
25
|
+
*/
|
|
26
|
+
variant?: 'border' | 'grow';
|
|
27
|
+
/**
|
|
28
|
+
* Set visually hidden label for accessibility purposes.
|
|
29
|
+
*/
|
|
30
|
+
visuallyHiddenLabel?: string;
|
|
31
|
+
};
|
|
32
|
+
type SpinnerProps<C extends ElementType = 'div'> = PolymorphicComponentProps<C, SpinnerOwnProps<C>>;
|
|
33
|
+
type SpinnerComponent = (<C extends ElementType = 'div'>(props: SpinnerProps<C> & {
|
|
34
|
+
ref?: PolymorphicRef<C>;
|
|
35
|
+
}) => ReactElement | null) & {
|
|
36
|
+
displayName?: string;
|
|
37
|
+
};
|
|
38
|
+
declare const Spinner: SpinnerComponent;
|
|
39
|
+
//#endregion
|
|
40
|
+
export { SpinnerProps as n, Spinner as t };
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import "./focus-ring-SR_LwaN7.js";
|
|
2
|
+
import { r as PolymorphicRefWithFallback, t as PolymorphicComponentProps } from "./polymorphic-CVHbTHSN.js";
|
|
3
|
+
import { n as ContextColor, r as ContextStyle } from "./types-CS_40Txv.js";
|
|
4
|
+
import { ElementType, MouseEventHandler, ReactElement } from "react";
|
|
5
|
+
//#region src/components/chip/Chip.d.ts
|
|
6
|
+
type ChipOwnProps<C extends ElementType> = {
|
|
7
|
+
/**
|
|
8
|
+
* A string of all className you want applied to the component.
|
|
9
|
+
*/
|
|
10
|
+
className?: string;
|
|
11
|
+
/**
|
|
12
|
+
* Sets the color of the component to one of Chassis context colors.
|
|
13
|
+
*/
|
|
14
|
+
color?: ContextColor;
|
|
15
|
+
/**
|
|
16
|
+
* Component used for the root node. Either a string to use a HTML element or a component.
|
|
17
|
+
* Defaults to `span`, or `a` when `href` is set.
|
|
18
|
+
*/
|
|
19
|
+
component?: C;
|
|
20
|
+
/**
|
|
21
|
+
* Toggle the disabled state for the component. Applied as the native `disabled` attribute when
|
|
22
|
+
* `component` is `button`, or the `.disabled` class for every other element (a bare `<span>`/
|
|
23
|
+
* `<a>` has no real `disabled` attribute).
|
|
24
|
+
*/
|
|
25
|
+
disabled?: boolean;
|
|
26
|
+
/**
|
|
27
|
+
* Renders the chip as a link to this URL. Defaults `component` to `a`.
|
|
28
|
+
*/
|
|
29
|
+
href?: string;
|
|
30
|
+
/**
|
|
31
|
+
* Fires on click. Typed for every element `component` can actually render, rather than
|
|
32
|
+
* narrowed to whichever element `C` happens to be.
|
|
33
|
+
*/
|
|
34
|
+
onClick?: MouseEventHandler<HTMLElement>;
|
|
35
|
+
/**
|
|
36
|
+
* Marks the chip as pressed for toggle-style usage (e.g. a filter chip). Applies the `.active`
|
|
37
|
+
* class and sets `aria-pressed` so assistive technology announces the toggle state.
|
|
38
|
+
*/
|
|
39
|
+
pressed?: boolean;
|
|
40
|
+
/**
|
|
41
|
+
* Size the component sm or lg.
|
|
42
|
+
*/
|
|
43
|
+
size?: 'sm' | 'lg';
|
|
44
|
+
/**
|
|
45
|
+
* Specifies the type of button. Only applies when `component` is `button`. Different browsers
|
|
46
|
+
* may use different default types for the `<button>` element, so always specify it explicitly.
|
|
47
|
+
*/
|
|
48
|
+
type?: 'button' | 'submit' | 'reset';
|
|
49
|
+
/**
|
|
50
|
+
* Set the chip style variant. `solid`/`basic` render the default look with no extra class.
|
|
51
|
+
*/
|
|
52
|
+
variant?: ContextStyle;
|
|
53
|
+
};
|
|
54
|
+
type ChipProps<C extends ElementType = 'span'> = PolymorphicComponentProps<C, ChipOwnProps<C>>;
|
|
55
|
+
type ChipComponent = (<C extends ElementType = 'span'>(props: ChipProps<C> & {
|
|
56
|
+
ref?: PolymorphicRefWithFallback<C, HTMLSpanElement | HTMLAnchorElement>;
|
|
57
|
+
}) => ReactElement | null) & {
|
|
58
|
+
displayName?: string;
|
|
59
|
+
};
|
|
60
|
+
declare const Chip: ChipComponent;
|
|
61
|
+
//#endregion
|
|
62
|
+
export { ChipProps as n, Chip as t };
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import "./focus-ring-SR_LwaN7.js";
|
|
2
|
+
import { n as PolymorphicRef, t as PolymorphicComponentProps } from "./polymorphic-CVHbTHSN.js";
|
|
3
|
+
import React, { AriaAttributes, ElementType, HTMLAttributes, ReactElement, ReactNode } from "react";
|
|
4
|
+
import { Key as Key$1 } from "react-stately";
|
|
5
|
+
//#region src/components/tabs/Tabs.d.ts
|
|
6
|
+
type TabsOwnProps<C extends ElementType> = {
|
|
7
|
+
/**
|
|
8
|
+
* A `TabList` (containing `Tab` children) followed by one `TabPanel` per tab.
|
|
9
|
+
*/
|
|
10
|
+
children?: ReactNode;
|
|
11
|
+
/**
|
|
12
|
+
* A string of all className you want applied to the base component.
|
|
13
|
+
*/
|
|
14
|
+
className?: string;
|
|
15
|
+
/**
|
|
16
|
+
* Component used for the root node. Either a string to use a HTML element or a component.
|
|
17
|
+
*/
|
|
18
|
+
component?: C;
|
|
19
|
+
/**
|
|
20
|
+
* The initially selected tab's key (uncontrolled).
|
|
21
|
+
*/
|
|
22
|
+
defaultSelectedKey?: Key$1;
|
|
23
|
+
/**
|
|
24
|
+
* The keys of tabs that cannot be selected, focused, or otherwise interacted with.
|
|
25
|
+
*/
|
|
26
|
+
disabledKeys?: Iterable<Key$1>;
|
|
27
|
+
/**
|
|
28
|
+
* Whether tabs are selected automatically on arrow-key focus (`'automatic'`, the default) or
|
|
29
|
+
* only on explicit activation — Enter/Space or click (`'manual'`).
|
|
30
|
+
*/
|
|
31
|
+
keyboardActivation?: 'automatic' | 'manual';
|
|
32
|
+
/**
|
|
33
|
+
* Callback fired when the selected tab changes.
|
|
34
|
+
*/
|
|
35
|
+
onSelectionChange?: (key: Key$1) => void;
|
|
36
|
+
/**
|
|
37
|
+
* The orientation of the tab list.
|
|
38
|
+
*/
|
|
39
|
+
orientation?: 'horizontal' | 'vertical';
|
|
40
|
+
/**
|
|
41
|
+
* The selected tab's key (controlled).
|
|
42
|
+
*/
|
|
43
|
+
selectedKey?: Key$1;
|
|
44
|
+
};
|
|
45
|
+
type TabsProps<C extends ElementType = 'div'> = PolymorphicComponentProps<C, TabsOwnProps<C>>;
|
|
46
|
+
type TabsComponent = (<C extends ElementType = 'div'>(props: TabsProps<C> & {
|
|
47
|
+
ref?: PolymorphicRef<C>;
|
|
48
|
+
}) => ReactElement | null) & {
|
|
49
|
+
displayName?: string;
|
|
50
|
+
};
|
|
51
|
+
declare const Tabs: TabsComponent;
|
|
52
|
+
//#endregion
|
|
53
|
+
//#region src/components/tabs/Tab.d.ts
|
|
54
|
+
interface TabProps {
|
|
55
|
+
/**
|
|
56
|
+
* Label content for the tab. Must be a plain string for it to be used as the tab's accessible
|
|
57
|
+
* name when the rendered content itself doesn't expose one (e.g. an icon-only tab).
|
|
58
|
+
*/
|
|
59
|
+
children: ReactNode;
|
|
60
|
+
/**
|
|
61
|
+
* Prevents the tab from being selected, focused, or otherwise interacted with.
|
|
62
|
+
*/
|
|
63
|
+
disabled?: boolean;
|
|
64
|
+
/**
|
|
65
|
+
* Identifies this tab and pairs it with the `TabPanel` of the same `id`.
|
|
66
|
+
*/
|
|
67
|
+
id: Key$1;
|
|
68
|
+
}
|
|
69
|
+
declare const Tab: {
|
|
70
|
+
(_props: TabProps): null;
|
|
71
|
+
displayName: string;
|
|
72
|
+
};
|
|
73
|
+
//#endregion
|
|
74
|
+
//#region src/components/tabs/TabList.d.ts
|
|
75
|
+
interface TabListProps extends AriaAttributes {
|
|
76
|
+
/**
|
|
77
|
+
* `Tab` elements — read as data by `Tabs` to build the tab collection (see `Tabs.tsx`). Not
|
|
78
|
+
* rendered directly.
|
|
79
|
+
*/
|
|
80
|
+
children: ReactNode;
|
|
81
|
+
/**
|
|
82
|
+
* A string of all className you want applied to the base component.
|
|
83
|
+
*/
|
|
84
|
+
className?: string;
|
|
85
|
+
/**
|
|
86
|
+
* Set the tab list variant to tabs or pills.
|
|
87
|
+
*/
|
|
88
|
+
variant?: 'tabs' | 'pills';
|
|
89
|
+
}
|
|
90
|
+
declare const TabList: React.ForwardRefExoticComponent<TabListProps & React.RefAttributes<HTMLUListElement>>;
|
|
91
|
+
//#endregion
|
|
92
|
+
//#region src/components/tabs/TabPanel.d.ts
|
|
93
|
+
interface TabPanelProps extends Omit<HTMLAttributes<HTMLDivElement>, 'id'> {
|
|
94
|
+
/**
|
|
95
|
+
* Content of the panel, shown while the `Tab` of the same `id` is selected.
|
|
96
|
+
*/
|
|
97
|
+
children: ReactNode;
|
|
98
|
+
/**
|
|
99
|
+
* A string of all className you want applied to the base component.
|
|
100
|
+
*/
|
|
101
|
+
className?: string;
|
|
102
|
+
/**
|
|
103
|
+
* Pairs this panel with the `Tab` of the same `id`.
|
|
104
|
+
*/
|
|
105
|
+
id: Key$1;
|
|
106
|
+
}
|
|
107
|
+
declare const TabPanel: React.ForwardRefExoticComponent<TabPanelProps & React.RefAttributes<HTMLDivElement>>;
|
|
108
|
+
//#endregion
|
|
109
|
+
export { Tab as a, TabsProps as c, TabListProps as i, TabPanelProps as n, TabProps as o, TabList as r, Tabs as s, TabPanel as t };
|
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
import "./focus-ring-SR_LwaN7.js";
|
|
2
|
+
import { n as ContextColor } from "./types-CS_40Txv.js";
|
|
3
|
+
import { Key, ReactElement, ReactNode, Ref } from "react";
|
|
4
|
+
import { Key as Key$1 } from "react-aria";
|
|
5
|
+
import { Selection, SortDescriptor, TableBodyProps, TableHeaderProps } from "react-stately";
|
|
6
|
+
//#region src/components/table/Table.d.ts
|
|
7
|
+
interface TableProps<T extends object> {
|
|
8
|
+
/**
|
|
9
|
+
* An accessible label for the table, used when there's no visible heading.
|
|
10
|
+
*/
|
|
11
|
+
'aria-label'?: string;
|
|
12
|
+
/**
|
|
13
|
+
* Identifies a visible heading element for the table.
|
|
14
|
+
*/
|
|
15
|
+
'aria-labelledby'?: string;
|
|
16
|
+
/**
|
|
17
|
+
* Set the vertical alignment of cell content.
|
|
18
|
+
*/
|
|
19
|
+
align?: 'bottom' | 'middle' | 'top';
|
|
20
|
+
/**
|
|
21
|
+
* Add borders on all sides of the table and cells.
|
|
22
|
+
*/
|
|
23
|
+
bordered?: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Remove borders on all sides of the table and cells.
|
|
26
|
+
*/
|
|
27
|
+
borderless?: boolean;
|
|
28
|
+
/**
|
|
29
|
+
* Content shown above the table, functioning as a heading for it.
|
|
30
|
+
*/
|
|
31
|
+
caption?: ReactNode;
|
|
32
|
+
/**
|
|
33
|
+
* A `TableHeader` and a `TableBody`, each built from `TableColumn`/`TableRow`/
|
|
34
|
+
* `TableCell` — read as data to build the table's collection. Not rendered directly.
|
|
35
|
+
*/
|
|
36
|
+
children: [ReactElement<TableHeaderProps<T> & {
|
|
37
|
+
className?: string;
|
|
38
|
+
}>, ReactElement<TableBodyProps<T> & {
|
|
39
|
+
className?: string;
|
|
40
|
+
}>];
|
|
41
|
+
/**
|
|
42
|
+
* A string of all className you want applied to the component.
|
|
43
|
+
*/
|
|
44
|
+
className?: string;
|
|
45
|
+
/**
|
|
46
|
+
* Sets the color of the component.
|
|
47
|
+
*/
|
|
48
|
+
color?: ContextColor;
|
|
49
|
+
/**
|
|
50
|
+
* A list of row keys to disable. Disabled rows cannot be selected, focused, or interacted with.
|
|
51
|
+
*/
|
|
52
|
+
disabledKeys?: Iterable<Key$1>;
|
|
53
|
+
/**
|
|
54
|
+
* Content shown below the table in a `<tfoot>`, e.g. a totals row. Rendered as plain markup —
|
|
55
|
+
* not part of the keyboard-navigable grid.
|
|
56
|
+
*/
|
|
57
|
+
footer?: ReactNode;
|
|
58
|
+
/**
|
|
59
|
+
* Enable a hover state on table rows.
|
|
60
|
+
*/
|
|
61
|
+
hover?: boolean;
|
|
62
|
+
/**
|
|
63
|
+
* `id` forwarded to the table element.
|
|
64
|
+
*/
|
|
65
|
+
id?: string;
|
|
66
|
+
/**
|
|
67
|
+
* Handler that is called when the selection changes.
|
|
68
|
+
*/
|
|
69
|
+
onSelectionChange?: (keys: Selection) => void;
|
|
70
|
+
/**
|
|
71
|
+
* Handler that is called when a column is sorted.
|
|
72
|
+
*/
|
|
73
|
+
onSortChange?: (descriptor: SortDescriptor) => void;
|
|
74
|
+
/**
|
|
75
|
+
* Make any table responsive across all viewports or pick a maximum breakpoint.
|
|
76
|
+
*/
|
|
77
|
+
responsive?: boolean | 'sm' | 'md' | 'lg' | 'xl' | '2xl';
|
|
78
|
+
/**
|
|
79
|
+
* The currently selected row keys (controlled).
|
|
80
|
+
*/
|
|
81
|
+
selectedKeys?: Selection;
|
|
82
|
+
/**
|
|
83
|
+
* The type of selection that is allowed.
|
|
84
|
+
*/
|
|
85
|
+
selectionMode?: 'none' | 'single' | 'multiple';
|
|
86
|
+
/**
|
|
87
|
+
* Make table more compact by cutting all cell padding.
|
|
88
|
+
*/
|
|
89
|
+
sm?: boolean;
|
|
90
|
+
/**
|
|
91
|
+
* The current sort column and direction.
|
|
92
|
+
*/
|
|
93
|
+
sortDescriptor?: SortDescriptor;
|
|
94
|
+
/**
|
|
95
|
+
* Convert rows into stacked label/value blocks below a container width, for tables with too
|
|
96
|
+
* many columns to read comfortably even with horizontal scrolling. `true` always stacks; a
|
|
97
|
+
* breakpoint name stacks only below it. Implies `responsive` when `responsive` isn't set
|
|
98
|
+
* separately, since stacking needs the same `.table-responsive` container-query ancestor.
|
|
99
|
+
* Labels come from each `TableColumn`'s text (or its `textValue`, for non-text headers).
|
|
100
|
+
*/
|
|
101
|
+
stacked?: boolean | 'sm' | 'md' | 'lg' | 'xl' | '2xl';
|
|
102
|
+
/**
|
|
103
|
+
* Add zebra-striping to table rows.
|
|
104
|
+
*/
|
|
105
|
+
striped?: boolean;
|
|
106
|
+
}
|
|
107
|
+
declare const Table: <T extends object>(props: TableProps<T> & {
|
|
108
|
+
ref?: Ref<HTMLTableElement>;
|
|
109
|
+
}) => ReactElement;
|
|
110
|
+
//#endregion
|
|
111
|
+
//#region src/components/table/TableBody.d.ts
|
|
112
|
+
interface TableBodyProps$1<T> {
|
|
113
|
+
/**
|
|
114
|
+
* `TableRow` elements, or a render function paired with `items` for dynamic row generation.
|
|
115
|
+
*/
|
|
116
|
+
children: ReactElement | ReactElement[] | ((item: T) => ReactElement);
|
|
117
|
+
/**
|
|
118
|
+
* A string of all className you want applied to the `<tbody>` element.
|
|
119
|
+
*/
|
|
120
|
+
className?: string;
|
|
121
|
+
/**
|
|
122
|
+
* A list of row data objects, rendered via the function form of `children`.
|
|
123
|
+
*/
|
|
124
|
+
items?: Iterable<T>;
|
|
125
|
+
}
|
|
126
|
+
/**
|
|
127
|
+
* Collection node, data-only — read by `Table` to build the table's row collection. Never
|
|
128
|
+
* rendered directly.
|
|
129
|
+
*/
|
|
130
|
+
declare const TableBody$1: <T>(props: TableBodyProps$1<T>) => ReactElement;
|
|
131
|
+
//#endregion
|
|
132
|
+
//#region src/components/table/TableCell.d.ts
|
|
133
|
+
interface TableCellProps {
|
|
134
|
+
/**
|
|
135
|
+
* The contents of the cell.
|
|
136
|
+
*/
|
|
137
|
+
children: ReactNode;
|
|
138
|
+
/**
|
|
139
|
+
* A string of all className you want applied to the cell.
|
|
140
|
+
*/
|
|
141
|
+
className?: string;
|
|
142
|
+
/**
|
|
143
|
+
* Indicates how many columns the cell spans.
|
|
144
|
+
*/
|
|
145
|
+
colSpan?: number;
|
|
146
|
+
/**
|
|
147
|
+
* A string representation of the cell's contents, used for typeahead.
|
|
148
|
+
*/
|
|
149
|
+
textValue?: string;
|
|
150
|
+
}
|
|
151
|
+
/**
|
|
152
|
+
* Collection node, data-only — see `TableHeader`. Read by `Table` to build a cell in the
|
|
153
|
+
* table's collection; never rendered directly.
|
|
154
|
+
*/
|
|
155
|
+
declare const TableCell: (props: TableCellProps) => ReactElement;
|
|
156
|
+
//#endregion
|
|
157
|
+
//#region src/components/table/TableColumn.d.ts
|
|
158
|
+
interface TableColumnProps {
|
|
159
|
+
/**
|
|
160
|
+
* Whether the column allows sorting. Adds a sort indicator and makes the header
|
|
161
|
+
* clickable/keyboard-activatable.
|
|
162
|
+
*/
|
|
163
|
+
allowsSorting?: boolean;
|
|
164
|
+
/**
|
|
165
|
+
* Rendered contents of the column header.
|
|
166
|
+
*/
|
|
167
|
+
children: ReactNode;
|
|
168
|
+
/**
|
|
169
|
+
* A string of all className you want applied to the column header.
|
|
170
|
+
*/
|
|
171
|
+
className?: string;
|
|
172
|
+
/**
|
|
173
|
+
* A string representation of the column header, used for accessibility announcements and,
|
|
174
|
+
* when `Table`'s `stacked` prop is set, as the label shown before each row's value for this
|
|
175
|
+
* column. Defaults to `children` when it's a plain string — set this explicitly when the
|
|
176
|
+
* header contains anything else (an icon, a `Tooltip`, etc.).
|
|
177
|
+
*/
|
|
178
|
+
textValue?: string;
|
|
179
|
+
}
|
|
180
|
+
/**
|
|
181
|
+
* Collection node, data-only — see `TableHeader`. Read by `Table` to build a column in the
|
|
182
|
+
* table's collection; never rendered directly.
|
|
183
|
+
*/
|
|
184
|
+
declare const TableColumn: (props: TableColumnProps) => ReactElement;
|
|
185
|
+
//#endregion
|
|
186
|
+
//#region src/components/table/TableHeader.d.ts
|
|
187
|
+
interface TableHeaderProps$1<T> {
|
|
188
|
+
/**
|
|
189
|
+
* `TableColumn` elements, or a render function paired with `columns` for dynamic column
|
|
190
|
+
* generation.
|
|
191
|
+
*/
|
|
192
|
+
children: ReactElement | ReactElement[] | ((column: T) => ReactElement);
|
|
193
|
+
/**
|
|
194
|
+
* A string of all className you want applied to the `<thead>` element.
|
|
195
|
+
*/
|
|
196
|
+
className?: string;
|
|
197
|
+
/**
|
|
198
|
+
* A list of column data objects, rendered via the function form of `children`.
|
|
199
|
+
*/
|
|
200
|
+
columns?: readonly T[];
|
|
201
|
+
}
|
|
202
|
+
/**
|
|
203
|
+
* Collection node, data-only — read by `Table` to build the table's column collection. Never
|
|
204
|
+
* rendered directly.
|
|
205
|
+
*/
|
|
206
|
+
declare const TableHeader$1: <T>(props: TableHeaderProps$1<T>) => ReactElement;
|
|
207
|
+
//#endregion
|
|
208
|
+
//#region src/components/table/TableRow.d.ts
|
|
209
|
+
interface TableRowProps {
|
|
210
|
+
/**
|
|
211
|
+
* `TableCell` elements, or a render function called once per column with that column's key —
|
|
212
|
+
* required when the row's parent `TableBody` uses the `items`/render-function form.
|
|
213
|
+
*/
|
|
214
|
+
children: ReactElement | ReactElement[] | ((columnKey: Key) => ReactElement);
|
|
215
|
+
/**
|
|
216
|
+
* A string of all className you want applied to the row.
|
|
217
|
+
*/
|
|
218
|
+
className?: string;
|
|
219
|
+
/**
|
|
220
|
+
* A string representation of the row's contents, used for typeahead.
|
|
221
|
+
*/
|
|
222
|
+
textValue?: string;
|
|
223
|
+
}
|
|
224
|
+
/**
|
|
225
|
+
* Collection node, data-only — see `TableHeader`. Read by `Table` to build a row in the
|
|
226
|
+
* table's collection; never rendered directly.
|
|
227
|
+
*/
|
|
228
|
+
declare const TableRow: (props: TableRowProps) => ReactElement;
|
|
229
|
+
//#endregion
|
|
230
|
+
export { TableColumn as a, TableCellProps as c, Table as d, TableProps as f, TableHeaderProps$1 as i, TableBody$1 as l, TableRowProps as n, TableColumnProps as o, TableHeader$1 as r, TableCell as s, TableRow as t, TableBodyProps$1 as u };
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import "./focus-ring-SR_LwaN7.js";
|
|
2
|
+
import { n as PolymorphicRef, t as PolymorphicComponentProps } from "./polymorphic-CVHbTHSN.js";
|
|
3
|
+
import { s as Spacing, t as Breakpoint } from "./types-CS_40Txv.js";
|
|
4
|
+
import { ElementType, ReactElement } from "react";
|
|
5
|
+
//#region src/components/flex/Flex.d.ts
|
|
6
|
+
interface FlexLayout {
|
|
7
|
+
/**
|
|
8
|
+
* Sets `flex-direction`. Omit for the browser default (`row`).
|
|
9
|
+
*/
|
|
10
|
+
direction?: 'row' | 'column' | 'row-reverse' | 'column-reverse';
|
|
11
|
+
/**
|
|
12
|
+
* Sets `flex-wrap`. Omit for the browser default (`nowrap`).
|
|
13
|
+
*/
|
|
14
|
+
wrap?: 'wrap' | 'nowrap' | 'wrap-reverse';
|
|
15
|
+
/**
|
|
16
|
+
* Sets `justify-content`, aligning items along the main axis.
|
|
17
|
+
*/
|
|
18
|
+
justify?: 'start' | 'end' | 'center' | 'between' | 'around' | 'evenly';
|
|
19
|
+
/**
|
|
20
|
+
* Sets `align-items`, aligning items along the cross axis.
|
|
21
|
+
*/
|
|
22
|
+
align?: 'start' | 'end' | 'center' | 'baseline' | 'stretch';
|
|
23
|
+
/**
|
|
24
|
+
* Sets `align-content`, distributing wrapped lines along the cross axis. Has no effect on
|
|
25
|
+
* single-line (non-wrapping) containers.
|
|
26
|
+
*/
|
|
27
|
+
alignContent?: 'start' | 'end' | 'center' | 'between' | 'around' | 'stretch';
|
|
28
|
+
/**
|
|
29
|
+
* Spacing between children on both axes, mapped to the `gap-*` utility classes. Overridden per
|
|
30
|
+
* axis by `rowGap`/`columnGap` where set.
|
|
31
|
+
*/
|
|
32
|
+
gap?: Spacing | 0;
|
|
33
|
+
/**
|
|
34
|
+
* Spacing between rows (the cross axis when wrapped), mapped to the `row-gap-*` utility
|
|
35
|
+
* classes. Independent of `gap`/`columnGap`.
|
|
36
|
+
*/
|
|
37
|
+
rowGap?: Spacing | 0;
|
|
38
|
+
/**
|
|
39
|
+
* Spacing between columns (the main axis), mapped to the `column-gap-*` utility classes.
|
|
40
|
+
* Independent of `gap`/`rowGap`.
|
|
41
|
+
*/
|
|
42
|
+
columnGap?: Spacing | 0;
|
|
43
|
+
}
|
|
44
|
+
type FlexOwnProps<C extends ElementType> = FlexLayout & {
|
|
45
|
+
/**
|
|
46
|
+
* A string of all className you want applied to the component.
|
|
47
|
+
*/
|
|
48
|
+
className?: string;
|
|
49
|
+
/**
|
|
50
|
+
* Component used for the root node. Either a string to use a HTML element or a component.
|
|
51
|
+
*/
|
|
52
|
+
component?: C;
|
|
53
|
+
/**
|
|
54
|
+
* Renders an inline flex container (`.d-inline-flex`) instead of a block-level one (`.d-flex`,
|
|
55
|
+
* the default).
|
|
56
|
+
*/
|
|
57
|
+
inline?: boolean;
|
|
58
|
+
/**
|
|
59
|
+
* Overrides any of `direction`/`wrap`/`justify`/`align`/`alignContent`/`gap`/`rowGap`/
|
|
60
|
+
* `columnGap` at one or more breakpoints, via regular viewport media queries (unlike `Stack`'s
|
|
61
|
+
* `responsive` prop, this doesn't require a `.contains-inline` ancestor).
|
|
62
|
+
*/
|
|
63
|
+
responsive?: Partial<Record<Breakpoint, FlexLayout>>;
|
|
64
|
+
};
|
|
65
|
+
type FlexProps<C extends ElementType = 'div'> = PolymorphicComponentProps<C, FlexOwnProps<C>>;
|
|
66
|
+
type FlexComponent = (<C extends ElementType = 'div'>(props: FlexProps<C> & {
|
|
67
|
+
ref?: PolymorphicRef<C>;
|
|
68
|
+
}) => ReactElement | null) & {
|
|
69
|
+
displayName?: string;
|
|
70
|
+
};
|
|
71
|
+
declare const Flex: FlexComponent;
|
|
72
|
+
//#endregion
|
|
73
|
+
export { FlexProps as n, Flex as t };
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import "./focus-ring-SR_LwaN7.js";
|
|
2
|
+
import { t as FormFieldIds } from "./renderFormField-fBEny6JV.js";
|
|
3
|
+
import { ReactNode } from "react";
|
|
4
|
+
//#region src/components/form-field/FormField.d.ts
|
|
5
|
+
interface FormFieldProps {
|
|
6
|
+
/**
|
|
7
|
+
* The form control(s) this field wraps.
|
|
8
|
+
*/
|
|
9
|
+
children: ReactNode;
|
|
10
|
+
/**
|
|
11
|
+
* A string of all className you want applied to the component.
|
|
12
|
+
*/
|
|
13
|
+
className?: string;
|
|
14
|
+
/**
|
|
15
|
+
* A description for the field, rendered below the control(s).
|
|
16
|
+
*/
|
|
17
|
+
help?: ReactNode;
|
|
18
|
+
/**
|
|
19
|
+
* The DOM ids of the wrapped control(s), used to associate the label (`htmlFor`) and
|
|
20
|
+
* point your control's own `aria-describedby` at the rendered help/feedback text.
|
|
21
|
+
*/
|
|
22
|
+
ids?: FormFieldIds;
|
|
23
|
+
/**
|
|
24
|
+
* Set field validation state to invalid.
|
|
25
|
+
*/
|
|
26
|
+
invalid?: boolean;
|
|
27
|
+
/**
|
|
28
|
+
* An error message for the field, rendered below the control(s) when `invalid` is set.
|
|
29
|
+
*/
|
|
30
|
+
invalidFeedback?: ReactNode;
|
|
31
|
+
/**
|
|
32
|
+
* The field's caption, rendered as a `FormLabel` associated with `ids.input`.
|
|
33
|
+
*/
|
|
34
|
+
label?: ReactNode;
|
|
35
|
+
/**
|
|
36
|
+
* Set field validation state to valid.
|
|
37
|
+
*/
|
|
38
|
+
valid?: boolean;
|
|
39
|
+
/**
|
|
40
|
+
* A success message for the field, rendered below the control(s) when `valid` is set.
|
|
41
|
+
*/
|
|
42
|
+
validFeedback?: ReactNode;
|
|
43
|
+
}
|
|
44
|
+
declare const FormField: {
|
|
45
|
+
({ children, className, help, ids, invalid, invalidFeedback, label, valid, validFeedback }: FormFieldProps): ReactNode;
|
|
46
|
+
displayName: string;
|
|
47
|
+
};
|
|
48
|
+
//#endregion
|
|
49
|
+
export { FormFieldProps as n, FormField as t };
|