@midas-ds/components 16.2.5 → 16.3.1
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/CHANGELOG.md +16 -0
- package/accordion/index.js +1 -1
- package/assets/Select.css +1 -1
- package/button/index.js +1 -1
- package/calendar/index.js +1 -1
- package/character-counter/CharacterCounter.d.ts +1 -3
- package/character-counter/index.js +1 -1
- package/checkbox/Checkbox.d.ts +3 -2
- package/checkbox/CheckboxGroupItem.d.ts +1 -1
- package/checkbox/CheckboxInner.d.ts +1 -2
- package/checkbox/SingleCheckbox.d.ts +1 -1
- package/checkbox/index.js +2 -2
- package/checkbox/types.d.ts +0 -1
- package/chunks/{AccordionItem-BUUDZ7l6.js → AccordionItem-D6vWtoJN.js} +2 -2
- package/chunks/{Button-wBgWrXj3.js → Button-BYrLbzir.js} +1 -1
- package/chunks/CharacterCounter-R6vh7AE5.js +22 -0
- package/chunks/Checkbox-BTAfwDxU.js +130 -0
- package/chunks/{CheckboxGroup-A7UJMi5J.js → CheckboxGroup-C6LIpj_R.js} +4 -4
- package/chunks/{ColorSchemeSwitch-DugvPh6T.js → ColorSchemeSwitch-D-vCkxQo.js} +1 -1
- package/chunks/{ComboBox-yl5zHYPk.js → ComboBox-CzwpRxSH.js} +3 -3
- package/chunks/{DateField-BsT1K-bB.js → DateField-DPJrihTz.js} +2 -2
- package/chunks/{DateRangePicker-BsK7pMRv.js → DateRangePicker-DzgK_p0d.js} +3 -3
- package/chunks/{Dialog-DC0cGNj5.js → Dialog-DprWZBKT.js} +2 -2
- package/chunks/{FeedbackStatusIcon-COWuMusk.js → FeedbackStatusIcon-YJaUAfjp.js} +1 -1
- package/chunks/FieldError-Bra5aRT3.js +24 -0
- package/chunks/{InfoBanner-DLiVpNON.js → InfoBanner-BOKZ4lBE.js} +3 -3
- package/chunks/{Label-Dup4lWaR.js → Label-6SXmzRZE.js} +2 -2
- package/chunks/{Layout-DX3HUm5b.js → Layout-DveMXIKw.js} +3 -3
- package/chunks/{ListBoxLoadMoreItem-CB67meAb.js → ListBoxLoadMoreItem-CygpsU3W.js} +2 -2
- package/chunks/{Logo-InDSslpO.js → Logo-CsWcKqIg.js} +1 -1
- package/chunks/{ProgressBar-CbwvcHvk.js → ProgressBar-67lCngwJ.js} +1 -1
- package/chunks/{Radio-CSFYbin8.js → Radio-XQA8CylD.js} +2 -2
- package/chunks/{RangeCalendar-BF-6p7u2.js → RangeCalendar-Bt8q3FZi.js} +2 -2
- package/chunks/{SearchField-mBHZ9pFg.js → SearchField-CxoPi6Ql.js} +3 -3
- package/chunks/Select-BNCz_ox4.js +221 -0
- package/chunks/{Select-BjD5iQvX.js → Select-CyYUhMOg.js} +6 -6
- package/chunks/{Spinner-BORNnHph.js → Spinner-tvJ7rPiT.js} +1 -1
- package/chunks/{Table-t3rVzb31.js → Table-BgsgXhC_.js} +1 -1
- package/chunks/{Tag-DxBoeE_n.js → Tag-BKcduKRR.js} +1 -1
- package/chunks/TextArea-BM5wOL3b.js +137 -0
- package/chunks/{Toast-DTwUGSJ8.js → Toast-C-EV39pd.js} +2 -2
- package/chunks/useLocalizedStringFormatter-BHvsRxDk.js +25 -0
- package/color-scheme-switch/index.js +1 -1
- package/combobox/index.js +1 -1
- package/date-field/index.js +1 -1
- package/date-picker/index.js +1 -1
- package/field-error/FieldError.d.ts +1 -3
- package/field-error/index.js +1 -1
- package/index.d.ts +1 -0
- package/index.js +68 -66
- package/info-banner/index.js +1 -1
- package/label/index.js +1 -1
- package/layout/index.js +1 -1
- package/legacy-select/Select.d.ts +4 -2
- package/legacy-select/index.js +1 -1
- package/legacy-select/types.d.ts +1 -2
- package/list-box/index.js +1 -1
- package/logo/index.js +1 -1
- package/modal/index.js +1 -1
- package/package.json +1 -1
- package/progress-bar/index.js +1 -1
- package/radio/index.js +1 -1
- package/search-field/index.js +1 -1
- package/select/MultiSelectValue.d.ts +4 -0
- package/select/SelectTrigger.d.ts +4 -2
- package/select/index.js +1 -1
- package/spinner/index.js +1 -1
- package/table/index.js +1 -1
- package/tag/index.js +1 -1
- package/textfield/Input.d.ts +1 -3
- package/textfield/PasswordField.d.ts +1 -1
- package/textfield/TextArea.d.ts +2 -5
- package/textfield/TextField.d.ts +2 -5
- package/textfield/TextFieldBase.d.ts +1 -1
- package/textfield/index.js +1 -1
- package/toast/index.js +1 -1
- package/chunks/CharacterCounter-_m-SgTMV.js +0 -20
- package/chunks/Checkbox-gsEu5wcB.js +0 -119
- package/chunks/FieldError-Bc0acYNs.js +0 -21
- package/chunks/Select-Df4333VV.js +0 -208
- package/chunks/TextArea-B2BePnZz.js +0 -136
- package/chunks/useLocalizedStringFormatter-ZgRJmvHC.js +0 -25
- package/select/SelectValueTag.d.ts +0 -5
package/index.js
CHANGED
|
@@ -1,84 +1,85 @@
|
|
|
1
|
-
import { a as r, A as e } from "./chunks/AccordionItem-
|
|
1
|
+
import { a as r, A as e } from "./chunks/AccordionItem-D6vWtoJN.js";
|
|
2
2
|
import { B as s, a as p } from "./chunks/BadgeContainer-CKVsfTlF.js";
|
|
3
3
|
import { B as m } from "./chunks/Breadcrumbs-By2bMbQd.js";
|
|
4
|
-
import { B as
|
|
4
|
+
import { B as f } from "./chunks/Button-BYrLbzir.js";
|
|
5
5
|
import { B as d } from "./chunks/ButtonGroup-Dr6HOBo2.js";
|
|
6
|
-
import { C as l, R as
|
|
7
|
-
import { C as g, d as
|
|
8
|
-
import { C as G } from "./chunks/CharacterCounter-
|
|
9
|
-
import { C as R } from "./chunks/Checkbox-
|
|
10
|
-
import { C as
|
|
11
|
-
import { C as v } from "./chunks/ColorSchemeSwitch-
|
|
12
|
-
import { C as h, a as H, b as y } from "./chunks/ComboBox-
|
|
13
|
-
import { D as N } from "./chunks/DateField-
|
|
14
|
-
import { a as
|
|
15
|
-
import { D as
|
|
16
|
-
import { F as O } from "./chunks/FieldError-
|
|
6
|
+
import { C as l, R as u } from "./chunks/RangeCalendar-Bt8q3FZi.js";
|
|
7
|
+
import { C as g, d as b, c, a as B, e as L, f as S, b as D } from "./chunks/Card-ia98VoKL.js";
|
|
8
|
+
import { C as G } from "./chunks/CharacterCounter-R6vh7AE5.js";
|
|
9
|
+
import { C as R } from "./chunks/Checkbox-BTAfwDxU.js";
|
|
10
|
+
import { C as F } from "./chunks/CheckboxGroup-C6LIpj_R.js";
|
|
11
|
+
import { C as v } from "./chunks/ColorSchemeSwitch-D-vCkxQo.js";
|
|
12
|
+
import { C as h, a as H, b as y } from "./chunks/ComboBox-CzwpRxSH.js";
|
|
13
|
+
import { D as N } from "./chunks/DateField-DPJrihTz.js";
|
|
14
|
+
import { a as E, b as Q, D as Z } from "./chunks/DateInputDivider-CkTB5q5k.js";
|
|
15
|
+
import { D as q, a as J } from "./chunks/DateRangePicker-DzgK_p0d.js";
|
|
16
|
+
import { F as O } from "./chunks/FieldError-Bra5aRT3.js";
|
|
17
17
|
import { D as V, F as W } from "./chunks/FileUpload-h1PxqQmb.js";
|
|
18
18
|
import { G as Y } from "./chunks/Grid-B-WgMwON.js";
|
|
19
19
|
import { G as $ } from "./chunks/GridItem-5t1Z14sM.js";
|
|
20
20
|
import { H as ao } from "./chunks/Heading-D8tNNJkt.js";
|
|
21
|
-
import { I as eo } from "./chunks/InfoBanner-
|
|
22
|
-
import { L as so } from "./chunks/Label-
|
|
23
|
-
import { H as xo, L as mo, N as
|
|
21
|
+
import { I as eo } from "./chunks/InfoBanner-BOKZ4lBE.js";
|
|
22
|
+
import { L as so } from "./chunks/Label-6SXmzRZE.js";
|
|
23
|
+
import { H as xo, L as mo, N as io, S as fo, a as no } from "./chunks/Layout-DveMXIKw.js";
|
|
24
24
|
import { L as lo } from "./chunks/Link-yTNUNv3C.js";
|
|
25
|
-
import { L as
|
|
26
|
-
import { L as
|
|
27
|
-
import { M as
|
|
25
|
+
import { L as Co } from "./chunks/LinkButton-3nAekUJ4.js";
|
|
26
|
+
import { L as bo } from "./chunks/Logo-CsWcKqIg.js";
|
|
27
|
+
import { M as Bo } from "./chunks/Dialog-DprWZBKT.js";
|
|
28
28
|
import { P as So } from "./chunks/Popover-BcEtFiU1.js";
|
|
29
|
-
import { P as Io } from "./chunks/ProgressBar-
|
|
30
|
-
import { R as Po, a as Ro } from "./chunks/Radio-
|
|
31
|
-
import { S as
|
|
32
|
-
import { S as vo } from "./chunks/Select-
|
|
33
|
-
import { S as ho } from "./chunks/Select-
|
|
29
|
+
import { P as Io } from "./chunks/ProgressBar-67lCngwJ.js";
|
|
30
|
+
import { R as Po, a as Ro } from "./chunks/Radio-XQA8CylD.js";
|
|
31
|
+
import { S as Fo } from "./chunks/SearchField-CxoPi6Ql.js";
|
|
32
|
+
import { S as vo } from "./chunks/Select-BNCz_ox4.js";
|
|
33
|
+
import { S as ho } from "./chunks/Select-CyYUhMOg.js";
|
|
34
34
|
import { S as yo } from "./chunks/Skeleton-DqIHQLQl.js";
|
|
35
|
-
import { S as No } from "./chunks/Spinner-
|
|
36
|
-
import { b as
|
|
35
|
+
import { S as No } from "./chunks/Spinner-tvJ7rPiT.js";
|
|
36
|
+
import { b as Eo, C as Qo, R as Zo, T as jo, c as qo, a as Jo } from "./chunks/Table-BgsgXhC_.js";
|
|
37
37
|
import { a as Oo, c as Uo, b as Vo, T as Wo } from "./chunks/TabList-D2XV5ixe.js";
|
|
38
|
-
import { T as Yo, a as _o } from "./chunks/Tag-
|
|
38
|
+
import { T as Yo, a as _o } from "./chunks/Tag-BKcduKRR.js";
|
|
39
39
|
import { T as oa } from "./chunks/Text-TWzJxnto.js";
|
|
40
|
-
import { I as ra, b as ea, a as ta, T as sa } from "./chunks/TextArea-
|
|
41
|
-
import { G as xa, b as ma, T as
|
|
40
|
+
import { I as ra, b as ea, a as ta, T as sa } from "./chunks/TextArea-BM5wOL3b.js";
|
|
41
|
+
import { G as xa, b as ma, T as ia, a as fa, t as na } from "./chunks/Toast-C-EV39pd.js";
|
|
42
42
|
import { T as Ta, a as la } from "./chunks/ToggleButtonGroup-CXKTrLbb.js";
|
|
43
|
-
import { T as
|
|
44
|
-
import { L as
|
|
45
|
-
import { L as La, a as Sa } from "./chunks/ListBoxLoadMoreItem-
|
|
43
|
+
import { T as Ca, a as ga } from "./chunks/Tooltip-m032jGgF.js";
|
|
44
|
+
import { L as ca } from "./chunks/ListBox-D5BBeZWL.js";
|
|
45
|
+
import { L as La, a as Sa } from "./chunks/ListBoxLoadMoreItem-CygpsU3W.js";
|
|
46
46
|
import { c as Ia, L as Ga, a as Pa, b as Ra } from "./chunks/ListBoxSection-MZB_5DdD.js";
|
|
47
|
-
import { M as
|
|
48
|
-
import {
|
|
49
|
-
import {
|
|
47
|
+
import { M as Fa, a as Ma, b as va, c as Aa, S as ha } from "./chunks/Separator-BcnQEA9f.js";
|
|
48
|
+
import { u as ya } from "./chunks/useLocalizedStringFormatter-BHvsRxDk.js";
|
|
49
|
+
import { DialogTrigger as Na, MenuTrigger as za, RouterProvider as Ea } from "react-aria-components";
|
|
50
|
+
import { useToastState as Za } from "react-stately";
|
|
50
51
|
export {
|
|
51
52
|
r as Accordion,
|
|
52
53
|
e as AccordionItem,
|
|
53
54
|
s as Badge,
|
|
54
55
|
p as BadgeContainer,
|
|
55
56
|
m as Breadcrumbs,
|
|
56
|
-
|
|
57
|
+
f as Button,
|
|
57
58
|
d as ButtonGroup,
|
|
58
59
|
l as Calendar,
|
|
59
60
|
g as Card,
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
61
|
+
b as CardActionArea,
|
|
62
|
+
c as CardActions,
|
|
63
|
+
B as CardContent,
|
|
63
64
|
L as CardImage,
|
|
64
65
|
S as CardLink,
|
|
65
66
|
D as CardTitle,
|
|
66
|
-
|
|
67
|
+
Eo as Cell,
|
|
67
68
|
G as CharacterCounter,
|
|
68
69
|
R as Checkbox,
|
|
69
|
-
|
|
70
|
+
F as CheckboxGroup,
|
|
70
71
|
v as ColorSchemeSwitch,
|
|
71
|
-
|
|
72
|
+
Qo as Column,
|
|
72
73
|
h as ComboBox,
|
|
73
74
|
H as ComboBoxItem,
|
|
74
75
|
y as ComboBoxSection,
|
|
75
76
|
N as DateField,
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
77
|
+
E as DateInput,
|
|
78
|
+
Q as DateInputDivider,
|
|
79
|
+
q as DatePicker,
|
|
79
80
|
J as DateRangePicker,
|
|
80
|
-
|
|
81
|
-
|
|
81
|
+
Z as DateSegment,
|
|
82
|
+
Na as DialogTrigger,
|
|
82
83
|
V as DropZone,
|
|
83
84
|
O as FieldError,
|
|
84
85
|
W as FileTrigger,
|
|
@@ -93,41 +94,41 @@ export {
|
|
|
93
94
|
mo as Layout,
|
|
94
95
|
ho as LegacySelect,
|
|
95
96
|
lo as Link,
|
|
96
|
-
|
|
97
|
-
|
|
97
|
+
Co as LinkButton,
|
|
98
|
+
ca as ListBox,
|
|
98
99
|
La as ListBoxButton,
|
|
99
100
|
Ia as ListBoxHeader,
|
|
100
101
|
Ga as ListBoxItem,
|
|
101
102
|
Sa as ListBoxLoadMoreItem,
|
|
102
103
|
Pa as ListBoxPopover,
|
|
103
104
|
Ra as ListBoxSection,
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
105
|
+
bo as Logo,
|
|
106
|
+
Fa as Menu,
|
|
107
|
+
Ma as MenuItem,
|
|
107
108
|
va as MenuPopover,
|
|
108
109
|
Aa as MenuSection,
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
110
|
+
za as MenuTrigger,
|
|
111
|
+
Bo as Modal,
|
|
112
|
+
io as Navbar,
|
|
112
113
|
So as Popover,
|
|
113
114
|
Io as ProgressBar,
|
|
114
115
|
Po as Radio,
|
|
115
116
|
Ro as RadioGroup,
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
117
|
+
u as RangeCalendar,
|
|
118
|
+
Ea as RouterProvider,
|
|
119
|
+
Zo as Row,
|
|
120
|
+
Fo as SearchField,
|
|
120
121
|
vo as Select,
|
|
121
122
|
ha as Separator,
|
|
122
|
-
|
|
123
|
+
fo as Sidebar,
|
|
123
124
|
no as SidebarLink,
|
|
124
125
|
yo as Skeleton,
|
|
125
126
|
No as Spinner,
|
|
126
127
|
Oo as Tab,
|
|
127
128
|
Uo as TabList,
|
|
128
129
|
Vo as TabPanel,
|
|
129
|
-
|
|
130
|
-
|
|
130
|
+
jo as Table,
|
|
131
|
+
qo as TableBody,
|
|
131
132
|
Jo as TableHeader,
|
|
132
133
|
Wo as Tabs,
|
|
133
134
|
Yo as Tag,
|
|
@@ -137,12 +138,13 @@ export {
|
|
|
137
138
|
ta as TextField,
|
|
138
139
|
sa as TextFieldBase,
|
|
139
140
|
ma as Toast,
|
|
140
|
-
|
|
141
|
-
|
|
141
|
+
ia as ToastProvider,
|
|
142
|
+
fa as ToastRegion,
|
|
142
143
|
Ta as ToggleButton,
|
|
143
144
|
la as ToggleButtonGroup,
|
|
144
|
-
|
|
145
|
+
Ca as Tooltip,
|
|
145
146
|
ga as TooltipTrigger,
|
|
146
147
|
na as toastQueue,
|
|
147
|
-
|
|
148
|
+
ya as useLocalizedStringFormatter,
|
|
149
|
+
Za as useToastState
|
|
148
150
|
};
|
package/info-banner/index.js
CHANGED
package/label/index.js
CHANGED
package/layout/index.js
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { SelectProps } from './types';
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
/**
|
|
4
4
|
* @deprecated since v15.2.0 Kept for backwards compatibility, but will be removed in a future version. Use `Select` from `@midas-ds/components` instead.
|
|
5
5
|
*/
|
|
6
|
-
export declare const Select: React.ForwardRefExoticComponent<Omit<
|
|
6
|
+
export declare const Select: React.ForwardRefExoticComponent<Omit<SelectProps, "children" | "items"> & {
|
|
7
|
+
options: import('..').ListBoxOption[];
|
|
8
|
+
} & React.RefAttributes<HTMLButtonElement>>;
|
package/legacy-select/index.js
CHANGED
package/legacy-select/types.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ import { FormValidationState } from '@react-stately/form';
|
|
|
3
3
|
import { OverlayTriggerProps } from '@react-types/overlays';
|
|
4
4
|
import { ListState } from '@react-stately/list';
|
|
5
5
|
import { AsyncLoadable, CollectionBase, FocusableProps, InputBase, LabelableProps, MultipleSelection, TextInputBase, Validation, Key, Node, CollectionChildren } from '@react-types/shared';
|
|
6
|
-
import { HTMLAttributes
|
|
6
|
+
import { HTMLAttributes } from 'react';
|
|
7
7
|
import { AriaListBoxOptions } from 'react-aria';
|
|
8
8
|
import { AriaButtonProps } from '@react-types/button';
|
|
9
9
|
import { AriaSelectProps } from '@react-types/select';
|
|
@@ -176,5 +176,4 @@ export interface SelectProps extends MultiSelectStateProps<ListBoxOption> {
|
|
|
176
176
|
export type SelectContainerProps = Omit<SelectProps, 'children' | 'items'> & {
|
|
177
177
|
/** Item objects in the collection. */
|
|
178
178
|
options: ListBoxOption[];
|
|
179
|
-
ref?: Ref<HTMLButtonElement>;
|
|
180
179
|
};
|
package/list-box/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { L as s } from "../chunks/ListBox-D5BBeZWL.js";
|
|
2
|
-
import { L, a as e } from "../chunks/ListBoxLoadMoreItem-
|
|
2
|
+
import { L, a as e } from "../chunks/ListBoxLoadMoreItem-CygpsU3W.js";
|
|
3
3
|
import { c as r, L as i, a as B, b as m } from "../chunks/ListBoxSection-MZB_5DdD.js";
|
|
4
4
|
export {
|
|
5
5
|
s as ListBox,
|
package/logo/index.js
CHANGED
package/modal/index.js
CHANGED
package/package.json
CHANGED
package/progress-bar/index.js
CHANGED
package/radio/index.js
CHANGED
package/search-field/index.js
CHANGED
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { MidasSelectProps, SelectionMode } from '.';
|
|
2
|
+
type MultiSelectValueProps<T extends object, M extends SelectionMode = 'single'> = Pick<MidasSelectProps<T, M>, 'isDisabled'>;
|
|
3
|
+
export declare const MultiSelectValue: <T extends object, M extends SelectionMode = "single">({ isDisabled, }: MultiSelectValueProps<T, M>) => import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
export {};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { Size } from '../common/types';
|
|
2
|
-
|
|
2
|
+
import { MidasSelectProps } from './Select';
|
|
3
|
+
import { SelectionMode } from '.';
|
|
4
|
+
interface SelectTriggerProps<T extends object, M extends SelectionMode = 'single'> extends Pick<MidasSelectProps<T, M>, 'isDisabled' | 'selectionMode'> {
|
|
3
5
|
size: Size;
|
|
4
6
|
}
|
|
5
|
-
export declare const SelectTrigger: ({ size }: SelectTriggerProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare const SelectTrigger: <T extends object, M extends SelectionMode = "single">({ isDisabled, selectionMode, size, }: SelectTriggerProps<T, M>) => import("react/jsx-runtime").JSX.Element;
|
|
6
8
|
export {};
|
package/select/index.js
CHANGED
package/spinner/index.js
CHANGED
package/table/index.js
CHANGED
package/tag/index.js
CHANGED
package/textfield/Input.d.ts
CHANGED
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
import { InputProps as AriaInputProps } from 'react-aria-components';
|
|
2
|
-
import { Ref } from 'react';
|
|
3
2
|
export interface InputProps extends AriaInputProps {
|
|
4
3
|
/** If the component should use local props and ref instead of a parent context
|
|
5
4
|
* @default false
|
|
6
5
|
*/
|
|
7
6
|
skipContext?: boolean;
|
|
8
|
-
ref?: Ref<HTMLInputElement>;
|
|
9
7
|
}
|
|
10
|
-
export declare const Input: (
|
|
8
|
+
export declare const Input: import('react').ForwardRefExoticComponent<InputProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { InputProps } from './Input';
|
|
2
|
-
export declare const PasswordField: (
|
|
2
|
+
export declare const PasswordField: import('react').ForwardRefExoticComponent<InputProps & import('react').RefAttributes<HTMLInputElement>>;
|
package/textfield/TextArea.d.ts
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
|
-
import { Ref } from 'react';
|
|
2
1
|
import { TextFieldBaseProps } from './TextFieldBase';
|
|
3
2
|
import { TextAreaProps as AriaTextAreaProps } from 'react-aria-components';
|
|
4
3
|
import { Complement } from '../utils/types';
|
|
5
|
-
export
|
|
6
|
-
|
|
7
|
-
}
|
|
8
|
-
export declare const TextArea: ({ className, form, rows, wrap, ref, ...rest }: TextAreaProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
export type TextAreaProps = Omit<TextFieldBaseProps, 'type' | 'pattern'> & Complement<TextFieldBaseProps, AriaTextAreaProps>;
|
|
5
|
+
export declare const TextArea: import('react').ForwardRefExoticComponent<Omit<TextFieldBaseProps, "type" | "pattern"> & Complement<TextFieldBaseProps, AriaTextAreaProps> & import('react').RefAttributes<HTMLTextAreaElement>>;
|
package/textfield/TextField.d.ts
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
|
-
import { Ref } from 'react';
|
|
2
1
|
import { TextFieldBaseProps } from './TextFieldBase';
|
|
3
2
|
import { InputProps } from './Input';
|
|
4
3
|
import { Complement } from '../utils/types';
|
|
5
|
-
export
|
|
6
|
-
|
|
7
|
-
}
|
|
8
|
-
export declare const TextField: ({ className, form, list, min, max, ref, type, ...rest }: TextFieldProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
export type TextFieldProps = TextFieldBaseProps & Complement<TextFieldBaseProps, InputProps>;
|
|
5
|
+
export declare const TextField: import('react').ForwardRefExoticComponent<TextFieldBaseProps & Complement<TextFieldBaseProps, InputProps> & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -23,4 +23,4 @@ export interface TextFieldBaseProps extends Omit<TextFieldProps, 'className'> {
|
|
|
23
23
|
size?: Size;
|
|
24
24
|
popover?: InfoPopoverProps;
|
|
25
25
|
}
|
|
26
|
-
export declare const TextFieldBase: (
|
|
26
|
+
export declare const TextFieldBase: import('react').ForwardRefExoticComponent<TextFieldBaseProps & import('react').RefAttributes<HTMLDivElement>>;
|
package/textfield/index.js
CHANGED
package/toast/index.js
CHANGED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { jsx as s } from "react/jsx-runtime";
|
|
2
|
-
import { useContextProps as h, InputContext as i } from "react-aria-components";
|
|
3
|
-
import '../assets/CharacterCounter.css';const d = "_characterCounter_1f0mh_1", u = {
|
|
4
|
-
characterCounter: d
|
|
5
|
-
}, m = ({ ref: r, ...t }) => {
|
|
6
|
-
[t] = h(t, r, i);
|
|
7
|
-
const { maxLength: e, value: a, isLonely: c } = t, { length: n } = a?.toString() ?? "", o = e !== void 0;
|
|
8
|
-
return /* @__PURE__ */ s(
|
|
9
|
-
"span",
|
|
10
|
-
{
|
|
11
|
-
className: u.characterCounter,
|
|
12
|
-
"data-exceeded": o && n > e || void 0,
|
|
13
|
-
"data-lonely": c || void 0,
|
|
14
|
-
children: o ? `${n} / ${e}` : n
|
|
15
|
-
}
|
|
16
|
-
);
|
|
17
|
-
};
|
|
18
|
-
export {
|
|
19
|
-
m as C
|
|
20
|
-
};
|
|
@@ -1,119 +0,0 @@
|
|
|
1
|
-
import { jsxs as b, jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import v, { useContext as k, useRef as f } from "react";
|
|
3
|
-
import { mergeProps as l, VisuallyHidden as C, useCheckboxGroupItem as _, useCheckbox as R, useHover as I, usePress as P, useFocusRing as g } from "react-aria";
|
|
4
|
-
import { useContextProps as G, CheckboxContext as y, useSlottedContext as z, FormContext as B } from "react-aria-components";
|
|
5
|
-
import { a as u } from "./clsx-AexbMWKp.js";
|
|
6
|
-
import { variables as h } from "@midas-ds/theme";
|
|
7
|
-
import { c as F } from "./createLucideIcon-D4r5Phnh.js";
|
|
8
|
-
import { C as L } from "./check-BxlvVsvD.js";
|
|
9
|
-
import { useToggleState as N } from "@react-stately/toggle";
|
|
10
|
-
import '../assets/Checkbox.css';const S = [["path", { d: "M5 12h14", key: "1ays0h" }]], D = F("minus", S), H = v.createContext(null), O = "_checkboxInner_tzrii_1", j = "_checkbox_tzrii_1", q = "_checkboxGroup_tzrii_143", A = "_checkboxList_tzrii_154", x = {
|
|
11
|
-
checkboxInner: O,
|
|
12
|
-
checkbox: j,
|
|
13
|
-
checkboxGroup: q,
|
|
14
|
-
checkboxList: A
|
|
15
|
-
}, m = ({ ref: t, ...e }) => {
|
|
16
|
-
const { hoverProps: i, isHovered: c } = e.hoverResult, { pressProps: s, isPressed: n } = e.pressResult, { isFocused: a, isFocusVisible: r, focusProps: d } = e.focusRingAria;
|
|
17
|
-
return /* @__PURE__ */ b(
|
|
18
|
-
"label",
|
|
19
|
-
{
|
|
20
|
-
ref: t,
|
|
21
|
-
...l(i, s, e.labelProps),
|
|
22
|
-
slot: e.slot || void 0,
|
|
23
|
-
className: u(x.checkbox, e.className),
|
|
24
|
-
"data-hovered": c || void 0,
|
|
25
|
-
"data-selected": e.isSelected || void 0,
|
|
26
|
-
"data-indeterminate": e.isIndeterminate || void 0,
|
|
27
|
-
"data-pressed": n || void 0,
|
|
28
|
-
"data-disabled": e.isDisabled || void 0,
|
|
29
|
-
"data-readonly": e.isReadOnly || void 0,
|
|
30
|
-
"data-invalid": e.isInvalid || void 0,
|
|
31
|
-
"data-focused": a || void 0,
|
|
32
|
-
"data-focus-visible": r || void 0,
|
|
33
|
-
"data-required": e.isRequired || void 0,
|
|
34
|
-
children: [
|
|
35
|
-
/* @__PURE__ */ o("div", { className: u(x.checkboxInner), children: e.isIndeterminate ? /* @__PURE__ */ o(
|
|
36
|
-
D,
|
|
37
|
-
{
|
|
38
|
-
size: 14,
|
|
39
|
-
color: h.iconOnColor
|
|
40
|
-
}
|
|
41
|
-
) : /* @__PURE__ */ o(
|
|
42
|
-
L,
|
|
43
|
-
{
|
|
44
|
-
size: 14,
|
|
45
|
-
color: h.iconOnColor
|
|
46
|
-
}
|
|
47
|
-
) }),
|
|
48
|
-
/* @__PURE__ */ o(C, { children: /* @__PURE__ */ o(
|
|
49
|
-
"input",
|
|
50
|
-
{
|
|
51
|
-
...l(e.inputProps, d),
|
|
52
|
-
ref: e.inputRef
|
|
53
|
-
}
|
|
54
|
-
) }),
|
|
55
|
-
e.children
|
|
56
|
-
]
|
|
57
|
-
}
|
|
58
|
-
);
|
|
59
|
-
}, M = ({ ref: t, ...e }) => {
|
|
60
|
-
const i = _(
|
|
61
|
-
{
|
|
62
|
-
...e,
|
|
63
|
-
value: e.value || ""
|
|
64
|
-
},
|
|
65
|
-
e.state,
|
|
66
|
-
e.inputRef
|
|
67
|
-
);
|
|
68
|
-
return /* @__PURE__ */ o(
|
|
69
|
-
m,
|
|
70
|
-
{
|
|
71
|
-
...e,
|
|
72
|
-
...i,
|
|
73
|
-
ref: t
|
|
74
|
-
}
|
|
75
|
-
);
|
|
76
|
-
}, V = ({ ref: t, ...e }) => {
|
|
77
|
-
const i = R(e, N(e), e.inputRef);
|
|
78
|
-
return /* @__PURE__ */ o(
|
|
79
|
-
m,
|
|
80
|
-
{
|
|
81
|
-
...e,
|
|
82
|
-
...i,
|
|
83
|
-
ref: t
|
|
84
|
-
}
|
|
85
|
-
);
|
|
86
|
-
}, Y = ({ ref: t, ...e }) => {
|
|
87
|
-
[e, t] = G(e, t, y);
|
|
88
|
-
const i = z(B), c = e.validationBehavior ?? i?.validationBehavior ?? "native", s = k(H), n = f(null), a = I(e), r = P({
|
|
89
|
-
ref: t,
|
|
90
|
-
isDisabled: e.isDisabled
|
|
91
|
-
}), d = g();
|
|
92
|
-
return s ? /* @__PURE__ */ o(
|
|
93
|
-
M,
|
|
94
|
-
{
|
|
95
|
-
...e,
|
|
96
|
-
state: s,
|
|
97
|
-
inputRef: n,
|
|
98
|
-
hoverResult: a,
|
|
99
|
-
pressResult: r,
|
|
100
|
-
focusRingAria: d,
|
|
101
|
-
validationBehavior: c
|
|
102
|
-
}
|
|
103
|
-
) : /* @__PURE__ */ o(
|
|
104
|
-
V,
|
|
105
|
-
{
|
|
106
|
-
...e,
|
|
107
|
-
inputRef: n,
|
|
108
|
-
hoverResult: a,
|
|
109
|
-
pressResult: r,
|
|
110
|
-
focusRingAria: d,
|
|
111
|
-
validationBehavior: c
|
|
112
|
-
}
|
|
113
|
-
);
|
|
114
|
-
};
|
|
115
|
-
export {
|
|
116
|
-
Y as C,
|
|
117
|
-
H as a,
|
|
118
|
-
x as s
|
|
119
|
-
};
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { jsx as i } from "react/jsx-runtime";
|
|
2
|
-
import { useContext as l } from "react";
|
|
3
|
-
import { FieldErrorContext as c, FieldError as f } from "react-aria-components";
|
|
4
|
-
import { c as m } from "./clsx-AexbMWKp.js";
|
|
5
|
-
import { T as d } from "./Text-TWzJxnto.js";
|
|
6
|
-
import '../assets/FieldError.css';const a = "_fieldError_u3cks_1", E = {
|
|
7
|
-
fieldError: a
|
|
8
|
-
}, v = ({ ref: s, ...r }) => {
|
|
9
|
-
const { children: o, isInvalid: n } = r, t = m(E.fieldError, r.className), e = l(c);
|
|
10
|
-
return !e && n && typeof o != "function" ? /* @__PURE__ */ i(d, { className: t, children: o }) : e?.isInvalid ? /* @__PURE__ */ i(
|
|
11
|
-
f,
|
|
12
|
-
{
|
|
13
|
-
...r,
|
|
14
|
-
ref: s,
|
|
15
|
-
className: t
|
|
16
|
-
}
|
|
17
|
-
) : null;
|
|
18
|
-
};
|
|
19
|
-
export {
|
|
20
|
-
v as F
|
|
21
|
-
};
|