@midas-ds/components 1.0.3 → 1.2.3
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 +39 -1
- package/accordion/Accordion.d.ts +8 -8
- package/accordion/AccordionItem.d.ts +11 -3
- package/accordion/index.d.ts +0 -3
- package/global.css +1 -0
- package/index.cjs +138 -0
- package/index.css +1 -1
- package/index.d.ts +0 -1
- package/index.js +27067 -110
- package/package.json +21 -4
- package/theme.cjs +1 -0
- package/tokens-BskyMDHv.cjs +1 -0
- package/Breadcrumbs.css +0 -1
- package/Button-B4vMZbC6.js +0 -182
- package/Button.css +0 -1
- package/ButtonGroup.css +0 -1
- package/Card.css +0 -1
- package/Checkbox-DnKWanep.js +0 -402
- package/Checkbox.css +0 -1
- package/Collection-COLWgm24.js +0 -510
- package/ComboBox.css +0 -1
- package/DatePicker.css +0 -1
- package/Dialog-Cb6toyXO.js +0 -1951
- package/DragAndDrop-B0T3WgjL.js +0 -40
- package/Dropdown.css +0 -1
- package/FileUpload.css +0 -1
- package/Flex.css +0 -1
- package/Flex.module-CpoxBzQX.js +0 -37
- package/FocusScope-C8i7CH6y.js +0 -513
- package/Form-BQQs3jUk.js +0 -238
- package/Grid.css +0 -1
- package/Grid.module-Ia0e9Dix.js +0 -36
- package/Group-CdwXhx8Q.js +0 -42
- package/Hidden-DngIphiL.js +0 -37
- package/InfoBanner.css +0 -1
- package/Layout.css +0 -1
- package/Link-iAZLB3RI.js +0 -75
- package/Link.css +0 -1
- package/LinkButton.css +0 -1
- package/ListBox-BKWkIIm6.js +0 -474
- package/ListKeyboardDelegate-BH-K5hyq.js +0 -172
- package/Logo.css +0 -1
- package/Modal.css +0 -1
- package/MultiSelect.css +0 -1
- package/PressResponder-Cz-TRBHO.js +0 -31
- package/RSPContexts-EOiWkKOf.js +0 -11
- package/Radio.css +0 -1
- package/SearchField.css +0 -1
- package/Select.css +0 -1
- package/SelectionManager-8o40f7mx.js +0 -1047
- package/Separator-BlvmQjwz.js +0 -49
- package/Spinner.css +0 -1
- package/Table.css +0 -1
- package/Tabs.css +0 -1
- package/Tag--W5TgxmK.js +0 -728
- package/Tag.css +0 -1
- package/Text-CQPW6xs7.js +0 -15
- package/TextArea.css +0 -1
- package/TextField-DeK_yiK-.js +0 -225
- package/TextField.css +0 -1
- package/TextField.module-0-u4LVPp.js +0 -143
- package/Toast.css +0 -1
- package/VisuallyHidden-CFx06Bae.js +0 -39
- package/accordion/AccordionContent.d.ts +0 -3
- package/accordion/AccordionTagContext.d.ts +0 -3
- package/accordion/AccordionTrigger.d.ts +0 -3
- package/chevron-down-Cd1bkzXT.js +0 -13
- package/chevron-right-DBMc9VMi.js +0 -23
- package/clsx-OuTLNxxd.js +0 -16
- package/context-Bnqknrce.js +0 -80
- package/createLucideIcon-DeWljiyi.js +0 -79
- package/index-B-jHjTDC.js +0 -120
- package/index-BPdc9gJ8.js +0 -3122
- package/index-DK9ZACEc.js +0 -642
- package/index-KSgQWWiy.js +0 -26984
- package/index10.js +0 -4
- package/index11.js +0 -5
- package/index12.js +0 -4
- package/index13.js +0 -4
- package/index14.js +0 -4
- package/index15.js +0 -6
- package/index16.js +0 -6
- package/index17.js +0 -6
- package/index18.js +0 -4
- package/index19.js +0 -6
- package/index2.js +0 -8
- package/index20.js +0 -6
- package/index21.js +0 -4
- package/index22.js +0 -5
- package/index23.js +0 -5
- package/index24.js +0 -5
- package/index25.js +0 -6
- package/index26.js +0 -6
- package/index27.js +0 -6
- package/index28.js +0 -4
- package/index29.js +0 -12
- package/index3.js +0 -6
- package/index31.js +0 -22
- package/index32.js +0 -14
- package/index33.js +0 -11
- package/index34.js +0 -31
- package/index35.js +0 -8
- package/index36.js +0 -9
- package/index37.js +0 -19
- package/index38.js +0 -9
- package/index39.js +0 -9
- package/index4.js +0 -4
- package/index40.js +0 -16
- package/index41.js +0 -16
- package/index42.js +0 -31
- package/index43.js +0 -16
- package/index44.js +0 -6
- package/index45.js +0 -53
- package/index46.js +0 -18
- package/index47.js +0 -27
- package/index48.js +0 -18
- package/index49.js +0 -21
- package/index5.js +0 -5
- package/index50.js +0 -49
- package/index51.js +0 -5
- package/index52.js +0 -25
- package/index53.js +0 -18
- package/index54.js +0 -9
- package/index55.js +0 -25
- package/index56.js +0 -18
- package/index57.js +0 -11
- package/index58.js +0 -12
- package/index59.js +0 -15
- package/index6.js +0 -4
- package/index60.js +0 -9
- package/index61.js +0 -9
- package/index62.js +0 -19
- package/index63.js +0 -22
- package/index64.js +0 -61
- package/index65.js +0 -15
- package/index66.js +0 -11
- package/index67.js +0 -63
- package/index68.js +0 -85
- package/index69.js +0 -74
- package/index7.js +0 -9
- package/index70.js +0 -24
- package/index71.js +0 -69
- package/index72.js +0 -80
- package/index73.js +0 -140
- package/index74.js +0 -70
- package/index75.js +0 -42
- package/index76.js +0 -82
- package/index77.js +0 -71
- package/index78.js +0 -104
- package/index79.js +0 -274
- package/index8.js +0 -4
- package/index80.js +0 -723
- package/index81.js +0 -489
- package/index82.js +0 -314
- package/index83.js +0 -389
- package/index84.js +0 -252
- package/index85.js +0 -1363
- package/index86.js +0 -1009
- package/index87.js +0 -386
- package/index88.js +0 -2101
- package/index89.js +0 -2369
- package/index9.js +0 -5
- package/index90.js +0 -6836
- package/index91.js +0 -17
- package/index92.js +0 -14
- package/index93.js +0 -6
- package/index94.js +0 -9
- package/intlStrings-Cd44R5hT.js +0 -278
- package/react.esm-sMU8Z7rL.js +0 -11060
- package/triangle-alert-1OYl9KWz.js +0 -56
- package/useControlledState-DrAoodI6.js +0 -45
- package/useDescription-BPs7eRff.js +0 -32
- package/useField-Dz62UHCP.js +0 -67
- package/useFilter-ViwzkzZe.js +0 -35
- package/useFocusRing-BKGhL91C.js +0 -1297
- package/useFocusable-CRSmYEQc.js +0 -59
- package/useGridSelectionCheckbox-CVEvUCJL.js +0 -22
- package/useHasTabbableChild-C8y4fwiY.js +0 -34
- package/useHighlightSelectionDescription-CD74uzLh.js +0 -552
- package/useListState-DKnP5TB5.js +0 -119
- package/useLocalizedStringFormatter-DsZ-ZWSk.js +0 -96
- package/useSingleSelectListState-BHTLh8Ob.js +0 -34
- package/useUpdateEffect-Dtz-i14F.js +0 -12
- package/x-JK7i-TQC.js +0 -14
- /package/{index30.js → theme.js} +0 -0
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
import { c as e } from "./createLucideIcon-DeWljiyi.js";
|
|
2
|
-
/**
|
|
3
|
-
* @license lucide-react v0.453.0 - ISC
|
|
4
|
-
*
|
|
5
|
-
* This source code is licensed under the ISC license.
|
|
6
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
7
|
-
*/
|
|
8
|
-
const y = e("CircleAlert", [
|
|
9
|
-
["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
|
|
10
|
-
["line", { x1: "12", x2: "12", y1: "8", y2: "12", key: "1pkeuh" }],
|
|
11
|
-
["line", { x1: "12", x2: "12.01", y1: "16", y2: "16", key: "4dfq90" }]
|
|
12
|
-
]);
|
|
13
|
-
/**
|
|
14
|
-
* @license lucide-react v0.453.0 - ISC
|
|
15
|
-
*
|
|
16
|
-
* This source code is licensed under the ISC license.
|
|
17
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
18
|
-
*/
|
|
19
|
-
const a = e("CircleCheck", [
|
|
20
|
-
["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
|
|
21
|
-
["path", { d: "m9 12 2 2 4-4", key: "dzmm74" }]
|
|
22
|
-
]);
|
|
23
|
-
/**
|
|
24
|
-
* @license lucide-react v0.453.0 - ISC
|
|
25
|
-
*
|
|
26
|
-
* This source code is licensed under the ISC license.
|
|
27
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
28
|
-
*/
|
|
29
|
-
const r = e("Info", [
|
|
30
|
-
["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
|
|
31
|
-
["path", { d: "M12 16v-4", key: "1dtifu" }],
|
|
32
|
-
["path", { d: "M12 8h.01", key: "e9boi3" }]
|
|
33
|
-
]);
|
|
34
|
-
/**
|
|
35
|
-
* @license lucide-react v0.453.0 - ISC
|
|
36
|
-
*
|
|
37
|
-
* This source code is licensed under the ISC license.
|
|
38
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
39
|
-
*/
|
|
40
|
-
const l = e("TriangleAlert", [
|
|
41
|
-
[
|
|
42
|
-
"path",
|
|
43
|
-
{
|
|
44
|
-
d: "m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",
|
|
45
|
-
key: "wmoenq"
|
|
46
|
-
}
|
|
47
|
-
],
|
|
48
|
-
["path", { d: "M12 9v4", key: "juzpu7" }],
|
|
49
|
-
["path", { d: "M12 17h.01", key: "p32p05" }]
|
|
50
|
-
]);
|
|
51
|
-
export {
|
|
52
|
-
a as C,
|
|
53
|
-
r as I,
|
|
54
|
-
l as T,
|
|
55
|
-
y as a
|
|
56
|
-
};
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import { l as m } from "./useFocusRing-BKGhL91C.js";
|
|
2
|
-
import { useState as w, useRef as x, useEffect as y, useCallback as C } from "react";
|
|
3
|
-
function h(n, a) {
|
|
4
|
-
let { id: l, "aria-label": r, "aria-labelledby": e } = n;
|
|
5
|
-
return l = m(l), e && r ? e = [
|
|
6
|
-
.../* @__PURE__ */ new Set([
|
|
7
|
-
l,
|
|
8
|
-
...e.trim().split(/\s+/)
|
|
9
|
-
])
|
|
10
|
-
].join(" ") : e && (e = e.trim().split(/\s+/).join(" ")), !r && !e && a && (r = a), {
|
|
11
|
-
id: l,
|
|
12
|
-
"aria-label": r,
|
|
13
|
-
"aria-labelledby": e
|
|
14
|
-
};
|
|
15
|
-
}
|
|
16
|
-
function j(n, a, l) {
|
|
17
|
-
let [r, e] = w(n || a), f = x(n !== void 0), t = n !== void 0;
|
|
18
|
-
y(() => {
|
|
19
|
-
let i = f.current;
|
|
20
|
-
i !== t && console.warn(`WARN: A component changed from ${i ? "controlled" : "uncontrolled"} to ${t ? "controlled" : "uncontrolled"}.`), f.current = t;
|
|
21
|
-
}, [
|
|
22
|
-
t
|
|
23
|
-
]);
|
|
24
|
-
let o = t ? n : r, p = C((i, ...d) => {
|
|
25
|
-
let u = (c, ...s) => {
|
|
26
|
-
l && (Object.is(o, c) || l(c, ...s)), t || (o = c);
|
|
27
|
-
};
|
|
28
|
-
typeof i == "function" ? (console.warn("We can not support a function callback. See Github Issues for details https://github.com/adobe/react-spectrum/issues/2320"), e((s, ...$) => {
|
|
29
|
-
let b = i(t ? o : s, ...$);
|
|
30
|
-
return u(b, ...d), t ? s : b;
|
|
31
|
-
})) : (t || e(i), u(i, ...d));
|
|
32
|
-
}, [
|
|
33
|
-
t,
|
|
34
|
-
o,
|
|
35
|
-
l
|
|
36
|
-
]);
|
|
37
|
-
return [
|
|
38
|
-
o,
|
|
39
|
-
p
|
|
40
|
-
];
|
|
41
|
-
}
|
|
42
|
-
export {
|
|
43
|
-
j as $,
|
|
44
|
-
h as a
|
|
45
|
-
};
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { k as o } from "./useFocusRing-BKGhL91C.js";
|
|
2
|
-
import { useState as l } from "react";
|
|
3
|
-
let $ = 0;
|
|
4
|
-
const d = /* @__PURE__ */ new Map();
|
|
5
|
-
function u(t) {
|
|
6
|
-
let [f, n] = l();
|
|
7
|
-
return o(() => {
|
|
8
|
-
if (!t) return;
|
|
9
|
-
let e = d.get(t);
|
|
10
|
-
if (e)
|
|
11
|
-
n(e.element.id);
|
|
12
|
-
else {
|
|
13
|
-
let r = `react-aria-description-${$++}`;
|
|
14
|
-
n(r);
|
|
15
|
-
let a = document.createElement("div");
|
|
16
|
-
a.id = r, a.style.display = "none", a.textContent = t, document.body.appendChild(a), e = {
|
|
17
|
-
refCount: 0,
|
|
18
|
-
element: a
|
|
19
|
-
}, d.set(t, e);
|
|
20
|
-
}
|
|
21
|
-
return e.refCount++, () => {
|
|
22
|
-
e && --e.refCount === 0 && (e.element.remove(), d.delete(t));
|
|
23
|
-
};
|
|
24
|
-
}, [
|
|
25
|
-
t
|
|
26
|
-
]), {
|
|
27
|
-
"aria-describedby": t ? f : void 0
|
|
28
|
-
};
|
|
29
|
-
}
|
|
30
|
-
export {
|
|
31
|
-
u as $
|
|
32
|
-
};
|
package/useField-Dz62UHCP.js
DELETED
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
import { a as n, l as s, B as f, e as c } from "./useFocusRing-BKGhL91C.js";
|
|
2
|
-
import { $ } from "./Hidden-DngIphiL.js";
|
|
3
|
-
import p, { createContext as m } from "react";
|
|
4
|
-
import { a as y } from "./useControlledState-DrAoodI6.js";
|
|
5
|
-
const u = /* @__PURE__ */ m({}), g = /* @__PURE__ */ $(function(e, l) {
|
|
6
|
-
[e, l] = n(e, l, u);
|
|
7
|
-
let { elementType: a = "label", ...r } = e;
|
|
8
|
-
return /* @__PURE__ */ p.createElement(a, {
|
|
9
|
-
className: "react-aria-Label",
|
|
10
|
-
...r,
|
|
11
|
-
ref: l
|
|
12
|
-
});
|
|
13
|
-
});
|
|
14
|
-
function P(t) {
|
|
15
|
-
let { id: e, label: l, "aria-labelledby": a, "aria-label": r, labelElementType: d = "label" } = t;
|
|
16
|
-
e = s(e);
|
|
17
|
-
let o = s(), i = {};
|
|
18
|
-
l ? (a = a ? `${o} ${a}` : o, i = {
|
|
19
|
-
id: o,
|
|
20
|
-
htmlFor: d === "label" ? e : void 0
|
|
21
|
-
}) : !a && !r && console.warn("If you do not provide a visible label, you must specify an aria-label or aria-labelledby attribute for accessibility");
|
|
22
|
-
let b = y({
|
|
23
|
-
id: e,
|
|
24
|
-
"aria-label": r,
|
|
25
|
-
"aria-labelledby": a
|
|
26
|
-
});
|
|
27
|
-
return {
|
|
28
|
-
labelProps: i,
|
|
29
|
-
fieldProps: b
|
|
30
|
-
};
|
|
31
|
-
}
|
|
32
|
-
function E(t) {
|
|
33
|
-
let { description: e, errorMessage: l, isInvalid: a, validationState: r } = t, { labelProps: d, fieldProps: o } = P(t), i = f([
|
|
34
|
-
!!e,
|
|
35
|
-
!!l,
|
|
36
|
-
a,
|
|
37
|
-
r
|
|
38
|
-
]), b = f([
|
|
39
|
-
!!e,
|
|
40
|
-
!!l,
|
|
41
|
-
a,
|
|
42
|
-
r
|
|
43
|
-
]);
|
|
44
|
-
return o = c(o, {
|
|
45
|
-
"aria-describedby": [
|
|
46
|
-
i,
|
|
47
|
-
// Use aria-describedby for error message because aria-errormessage is unsupported using VoiceOver or NVDA. See https://github.com/adobe/react-spectrum/issues/1346#issuecomment-740136268
|
|
48
|
-
b,
|
|
49
|
-
t["aria-describedby"]
|
|
50
|
-
].filter(Boolean).join(" ") || void 0
|
|
51
|
-
}), {
|
|
52
|
-
labelProps: d,
|
|
53
|
-
fieldProps: o,
|
|
54
|
-
descriptionProps: {
|
|
55
|
-
id: i
|
|
56
|
-
},
|
|
57
|
-
errorMessageProps: {
|
|
58
|
-
id: b
|
|
59
|
-
}
|
|
60
|
-
};
|
|
61
|
-
}
|
|
62
|
-
export {
|
|
63
|
-
u as $,
|
|
64
|
-
g as a,
|
|
65
|
-
E as b,
|
|
66
|
-
P as c
|
|
67
|
-
};
|
package/useFilter-ViwzkzZe.js
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { $ as p } from "./ListKeyboardDelegate-BH-K5hyq.js";
|
|
2
|
-
import { useCallback as o, useMemo as $ } from "react";
|
|
3
|
-
function F(h) {
|
|
4
|
-
let l = p({
|
|
5
|
-
usage: "search",
|
|
6
|
-
...h
|
|
7
|
-
}), r = o((a, e) => e.length === 0 ? !0 : (a = a.normalize("NFC"), e = e.normalize("NFC"), l.compare(a.slice(0, e.length), e) === 0), [
|
|
8
|
-
l
|
|
9
|
-
]), c = o((a, e) => e.length === 0 ? !0 : (a = a.normalize("NFC"), e = e.normalize("NFC"), l.compare(a.slice(-e.length), e) === 0), [
|
|
10
|
-
l
|
|
11
|
-
]), f = o((a, e) => {
|
|
12
|
-
if (e.length === 0) return !0;
|
|
13
|
-
a = a.normalize("NFC"), e = e.normalize("NFC");
|
|
14
|
-
let t = 0, m = e.length;
|
|
15
|
-
for (; t + m <= a.length; t++) {
|
|
16
|
-
let n = a.slice(t, t + m);
|
|
17
|
-
if (l.compare(e, n) === 0) return !0;
|
|
18
|
-
}
|
|
19
|
-
return !1;
|
|
20
|
-
}, [
|
|
21
|
-
l
|
|
22
|
-
]);
|
|
23
|
-
return $(() => ({
|
|
24
|
-
startsWith: r,
|
|
25
|
-
endsWith: c,
|
|
26
|
-
contains: f
|
|
27
|
-
}), [
|
|
28
|
-
r,
|
|
29
|
-
c,
|
|
30
|
-
f
|
|
31
|
-
]);
|
|
32
|
-
}
|
|
33
|
-
export {
|
|
34
|
-
F as $
|
|
35
|
-
};
|