@stihl-design-system/components 1.0.0-RC.44 → 1.0.0-RC.45
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/{accordion.fQnuIgvf.js → accordion.MzP6R77w.js} +2 -2
- package/{actionbutton.CrKiuo82.js → actionbutton.G5W7UVFl.js} +2 -2
- package/{actioncard.WFXhVqOa.js → actioncard.BwquHtM_.js} +1 -1
- package/{actionlink.Df17YKFt.js → actionlink.DquMiuMX.js} +2 -2
- package/assets/ActionCard.BG8w8xUC.css +1 -0
- package/assets/Dialog.BKwWy1g2.css +1 -0
- package/assets/Drawer.BU-fi5Hk.css +1 -0
- package/assets/LinkButton.CxJvjEY5.css +1 -0
- package/assets/LinkCard.DkQoQJxx.css +1 -0
- package/assets/NavigationTabList.DYjNT2Di.css +1 -0
- package/assets/Pagination.DZ1yCAMR.css +1 -0
- package/assets/buttonround.CMrJRIeW.css +1 -0
- package/assets/link.Dcsio57m.css +1 -0
- package/{banner.Zxe9epVx.js → banner.XeTbC8mq.js} +1 -1
- package/{breadcrumb.FfS9gDhB.js → breadcrumb.BOz3Hst7.js} +3 -3
- package/{button.Bq_b-jF3.js → button.I5z8VEXa.js} +5 -4
- package/buttonround.BX_81KOF.js +101 -0
- package/{checkbox.DiIxW8xI.js → checkbox.CcEypLD0.js} +3 -3
- package/{checkboxgroup.CN0WCDIo.js → checkboxgroup.15fvJ2SQ.js} +2 -2
- package/{chip.C9GLR8lU.js → chip.DZP-2LVl.js} +2 -2
- package/{chipgroup.DEMaFBAV.js → chipgroup.Ckvmby1Q.js} +1 -1
- package/chunks/{Accordion.CHgxTFzp.js → Accordion.Drq0YoeJ.js} +1 -1
- package/chunks/{ActionButton.CLeOd9rU.js → ActionButton.CCI5IUFy.js} +1 -1
- package/chunks/ActionCard.DJSGkwVG.js +227 -0
- package/chunks/{ActionLink.BsBKNYu5.js → ActionLink.BrJB7T0A.js} +1 -1
- package/chunks/{Breadcrumb.Dz3JQ2Vx.js → Breadcrumb.CNABp45n.js} +2 -2
- package/chunks/Button.D8U6Bs7T.js +160 -0
- package/chunks/{Checkbox.B3g2P15v.js → Checkbox.91fwuJ-0.js} +2 -2
- package/chunks/{CheckboxGroup.Bg9WSL5B.js → CheckboxGroup.DlZcoyo_.js} +2 -2
- package/chunks/{Chip.CfxdI4_r.js → Chip.wHEr-saO.js} +1 -1
- package/chunks/{CustomReactSelect.DuAr_i4b.js → CustomReactSelect.DHwRSrva.js} +4 -4
- package/chunks/Dialog.DNrQmu4n.js +102 -0
- package/chunks/Drawer.DaiiAoa8.js +107 -0
- package/chunks/{Fieldset.DdYeI2CZ.js → Fieldset.BB4NftRU.js} +2 -2
- package/chunks/{Icon.BoywkLCM.js → Icon.DCdL1Vnp.js} +1 -1
- package/chunks/{InputFile.CR8ucopi.js → InputFile.C-m2Hp0n.js} +5 -5
- package/chunks/{InputNumber.BFZFmfye.js → InputNumber.DOrbq0Hf.js} +3 -3
- package/chunks/{InputPassword.C311ncrv.js → InputPassword.BrQLXv_R.js} +3 -3
- package/chunks/{InputSearch.BxDshauv.js → InputSearch.DsT4ESbN.js} +3 -3
- package/chunks/LinkButton.CNLxmfVF.js +150 -0
- package/chunks/LinkCard.CsK31XXo.js +197 -0
- package/chunks/NavigationTabList.9r9_yTmR.js +68 -0
- package/chunks/{NavigationTabs.B57dlMSM.js → NavigationTabs.CCFAm8-N.js} +1 -1
- package/chunks/{Notification.C6oDyXgu.js → Notification.BlyUQinT.js} +2 -2
- package/chunks/Pagination.Dl8CU-yY.js +247 -0
- package/chunks/{Popover.BmpyqKuQ.js → Popover.BBT_kVGM.js} +1 -1
- package/chunks/{RadioGroup.DkBkatv7.js → RadioGroup.BWe0nG6N.js} +1 -1
- package/chunks/{Select.Tt9kT7fQ.js → Select.fgSB8mUs.js} +3 -3
- package/chunks/Slider.8H5oki70.js +307 -0
- package/chunks/{Stepper.BnrFN6cJ.js → Stepper.UvgTZCCb.js} +2 -2
- package/chunks/{SystemFeedback.D4aWwoC8.js → SystemFeedback.CZhoSxrC.js} +1 -1
- package/chunks/{Tabs.kCft3oEd.js → Tabs.DtfpA30P.js} +1 -1
- package/chunks/{Textarea.DDcx_Pdr.js → Textarea.B-Ii-p0C.js} +2 -2
- package/chunks/{Toast.DddHXsvZ.js → Toast.B7_VJE8V.js} +2 -2
- package/chunks/heart-filled.CmO7eae5.js +10 -0
- package/{combobox.B-BIvd5K.js → combobox.C2DBgO0t.js} +1 -1
- package/components/Accordion/Accordion.d.ts +2 -2
- package/components/ActionCard/ActionCard.d.ts +11 -4
- package/components/Banner/Banner.d.ts +1 -1
- package/components/Breadcrumb/Breadcrumb.d.ts +4 -1
- package/components/ButtonRound/ButtonRound.d.ts +14 -7
- package/components/ButtonRound/ButtonRound.utils.d.ts +3 -1
- package/components/FloatingActionButton/FloatingActionButton.d.ts +8 -5
- package/components/LinkCard/LinkCard.d.ts +13 -3
- package/components/MegaMenu/MegaMenu.d.ts +1 -1
- package/components/Pagination/Pagination.d.ts +51 -0
- package/components/Pagination/Pagination.responsive.test.d.ts +1 -0
- package/components/Pagination/Pagination.test.d.ts +1 -0
- package/components/Pagination/Pagination.utils.d.ts +59 -0
- package/components/Pagination/Pagination.utils.test.d.ts +1 -0
- package/components/Tooltip/Tooltip.d.ts +1 -1
- package/{customreactselect.B7p1pKdD.js → customreactselect.Dle5ReLL.js} +5 -5
- package/{dialog.BqLpjUB7.js → dialog.Br6FeS8M.js} +2 -2
- package/{drawer.Cd-nCvZc.js → drawer.Dyjx6fy3.js} +2 -2
- package/{fieldset.CZZsUwkL.js → fieldset.D6sz1Wn2.js} +3 -3
- package/{filelist.BhBVr4dj.js → filelist.0CUvj_hg.js} +4 -4
- package/{filepreview.BTWX71Xh.js → filepreview.DfYhhi7K.js} +1 -1
- package/{flag.B0fg5_Ly.js → flag.B61fRxrP.js} +1 -1
- package/{floatingactionbutton.C97oLCcd.js → floatingactionbutton.C-V33tkz.js} +2 -2
- package/{icon.DfDzyo8I.js → icon.pia3k1bW.js} +1 -1
- package/index.d.ts +7 -0
- package/index.es.js +231 -218
- package/{input.DIJfEjWf.js → input.CNC3QIQR.js} +4 -4
- package/{inputfile.h6E4CGVo.js → inputfile.CN9IBCM5.js} +6 -6
- package/{inputnumber.mm_Irbl8.js → inputnumber.DIccXoqM.js} +4 -4
- package/{inputpassword.C2lyKMkw.js → inputpassword.BWIKqwcK.js} +4 -4
- package/{inputsearch.BjkPPx6s.js → inputsearch.BQVA1P3t.js} +4 -4
- package/link.DFt6ae6h.js +81 -0
- package/{linkbutton.Brcp-b5r.js → linkbutton.DSzhpA7y.js} +3 -3
- package/{linkcard.COvLNYk7.js → linkcard.Azap4eIT.js} +4 -4
- package/{navigationtablist.BBeiLPse.js → navigationtablist.B0QFyk6c.js} +2 -2
- package/{navigationtabs.DzPsYusL.js → navigationtabs.drPy054A.js} +2 -2
- package/{notification.CliKozt4.js → notification.DT8ZQWy-.js} +3 -3
- package/{optioncheckbox.BOfgK3U_.js → optioncheckbox.BO9lhnF3.js} +1 -1
- package/package.json +1 -1
- package/pagination.DqHkkeMR.js +14 -0
- package/pagination.d.ts +2 -0
- package/partials/index.js +24 -18
- package/partials/lib/partials.d.ts +1 -1
- package/{popover.ChNhlQVw.js → popover.HlTN79us.js} +2 -2
- package/product-card-example-5.webp +0 -0
- package/product-card-example-6.webp +0 -0
- package/product-card-example-7.webp +0 -0
- package/{progressindicator.DIzH179H.js → progressindicator.DdaSeRcV.js} +1 -1
- package/{radiogroup.DL5scGbv.js → radiogroup.CtkyrkVj.js} +2 -2
- package/{scroller.DwhsKecL.js → scroller.BZy0pXNL.js} +1 -1
- package/{select.mbkkptY-.js → select.BSRwHZl9.js} +4 -4
- package/{skiptocontent.CAXMZlhM.js → skiptocontent.D-qA8MV6.js} +1 -1
- package/{slider.DvrNqhCC.js → slider.jgy1gPS-.js} +3 -3
- package/{spinner.CJmvEaCu.js → spinner.CioXs_gr.js} +1 -1
- package/{step.B-afaoZI.js → step.C8Um5fyx.js} +2 -2
- package/{stepper.B0euF2om.js → stepper.ChHYe3pv.js} +3 -3
- package/{switch.BadzT87Z.js → switch.BWByas7M.js} +2 -2
- package/{systemfeedback.BfGF0ENk.js → systemfeedback.Dr99Uwoi.js} +2 -2
- package/{tablist.CLKzkkTc.js → tablist.DuaTT6zK.js} +3 -3
- package/{tabs.ClFPZyaL.js → tabs.BGmxVK_3.js} +2 -2
- package/{textarea.B06ZGH_0.js → textarea.BoxcJ2tx.js} +3 -3
- package/{toast.uarxRSg4.js → toast.BJs2VWI4.js} +3 -3
- package/{toastmanager.ClwydHnH.js → toastmanager.Bh9XSJty.js} +1 -1
- package/types/icon-types.d.ts +1 -1
- package/assets/ActionCard.C85bSGRa.css +0 -1
- package/assets/Dialog.DyiHUgTp.css +0 -1
- package/assets/Drawer.UugEajR2.css +0 -1
- package/assets/LinkButton.BEbmxP7h.css +0 -1
- package/assets/LinkCard.z1Yjue7-.css +0 -1
- package/assets/NavigationTabList.CzAiHz7G.css +0 -1
- package/assets/buttonround.BTC-HthI.css +0 -1
- package/assets/link.BemYqm4d.css +0 -1
- package/buttonround.C2Tbq4wh.js +0 -96
- package/chunks/ActionCard.oi3u27DL.js +0 -242
- package/chunks/Button.P9uWeVnl.js +0 -139
- package/chunks/Dialog.C8pnDioL.js +0 -102
- package/chunks/Drawer.wTQvINDy.js +0 -107
- package/chunks/LinkButton.D20xLcuG.js +0 -140
- package/chunks/LinkCard.CXJLlBi2.js +0 -193
- package/chunks/NavigationTabList.CUFceGFf.js +0 -68
- package/chunks/Slider.XqqBxGnd.js +0 -306
- package/link.Cej-vl_K.js +0 -81
|
@@ -1,242 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsxs as J, Fragment as re, jsx as v } from "react/jsx-runtime";
|
|
3
|
-
import { d as A } from "./index.cKLI89Eg.js";
|
|
4
|
-
import { c as S } from "./index.DQOqod3i.js";
|
|
5
|
-
import oe, { isValidElement as te, useRef as le, useEffect as ne, cloneElement as se } from "react";
|
|
6
|
-
import { g as ee } from "./helpers.CexwVao7.js";
|
|
7
|
-
import '../assets/ActionCard.C85bSGRa.css';const ie = "ds-action-card_root_rfquv_1", ce = "ds-action-card_root--clickable_rfquv_11", de = "ds-action-card_primary-action_rfquv_20", me = "ds-action-card_header_rfquv_34", pe = "ds-action-card_content_rfquv_34", fe = "ds-action-card_footer_rfquv_34", ue = "ds-action-card_supplementary_rfquv_34", ye = "ds-action-card_root--horizontal_rfquv_43", _e = "ds-action-card_image-wrapper_rfquv_51", Ne = "ds-action-card_content-wrapper_rfquv_62", he = "ds-action-card_content-wrapper--padding-small_rfquv_67", be = "ds-action-card_root--horizontal-has-supplementary_rfquv_75", ge = "ds-action-card_root--padding-small_rfquv_78", ve = "ds-action-card_primary-action-label_rfquv_158", d = {
|
|
8
|
-
root: ie,
|
|
9
|
-
rootClickable: ce,
|
|
10
|
-
primaryAction: de,
|
|
11
|
-
header: me,
|
|
12
|
-
content: pe,
|
|
13
|
-
footer: fe,
|
|
14
|
-
supplementary: ue,
|
|
15
|
-
rootHorizontal: ye,
|
|
16
|
-
imageWrapper: _e,
|
|
17
|
-
contentWrapper: Ne,
|
|
18
|
-
contentWrapperPaddingSmall: he,
|
|
19
|
-
rootHorizontalHasSupplementary: be,
|
|
20
|
-
rootPaddingSmall: ge,
|
|
21
|
-
primaryActionLabel: ve
|
|
22
|
-
}, Ce = ({
|
|
23
|
-
aria: n,
|
|
24
|
-
cardElement: e
|
|
25
|
-
}) => {
|
|
26
|
-
const a = n?.["aria-labelledby"], t = n?.["aria-label"];
|
|
27
|
-
if (e) {
|
|
28
|
-
if (!a && !t)
|
|
29
|
-
throw new Error(ee("DSActionCard", "The 'aria' prop is required and must include either 'aria-labelledby' or 'aria-label'."));
|
|
30
|
-
if (a && !e.querySelector("#" + a))
|
|
31
|
-
throw new Error(ee("DSActionCard", `The provided 'aria-labelledby' value '${a}' does not match any element ID within the card.`));
|
|
32
|
-
}
|
|
33
|
-
}, P = (n, e) => {
|
|
34
|
-
const a = [];
|
|
35
|
-
return oe.Children.forEach(n, (t) => {
|
|
36
|
-
if (!te(t))
|
|
37
|
-
return;
|
|
38
|
-
const r = t.type, o = e, l = o.displayName || o.name, m = r.displayName || r.name;
|
|
39
|
-
(t.type === e || m === l) && a.push(t);
|
|
40
|
-
}), a;
|
|
41
|
-
}, q = (n) => {
|
|
42
|
-
const e = A.c(48);
|
|
43
|
-
let a, t, r, o, l, m, c;
|
|
44
|
-
e[0] !== n ? ({
|
|
45
|
-
aria: a,
|
|
46
|
-
className: r,
|
|
47
|
-
classNameContentWrapper: o,
|
|
48
|
-
children: t,
|
|
49
|
-
orientation: m,
|
|
50
|
-
padding: c,
|
|
51
|
-
...l
|
|
52
|
-
} = n, e[0] = n, e[1] = a, e[2] = t, e[3] = r, e[4] = o, e[5] = l, e[6] = m, e[7] = c) : (a = e[1], t = e[2], r = e[3], o = e[4], l = e[5], m = e[6], c = e[7]);
|
|
53
|
-
const h = m === void 0 ? "vertical" : m, b = c === void 0 ? "medium" : c, p = le(null);
|
|
54
|
-
let f;
|
|
55
|
-
e[8] !== t ? (f = P(t, K), e[8] = t, e[9] = f) : f = e[9];
|
|
56
|
-
const _ = f;
|
|
57
|
-
let u;
|
|
58
|
-
e[10] !== t ? (u = P(t, Q), e[10] = t, e[11] = u) : u = e[11];
|
|
59
|
-
const g = u;
|
|
60
|
-
let y;
|
|
61
|
-
e[12] !== t ? (y = P(t, U), e[12] = t, e[13] = y) : y = e[13];
|
|
62
|
-
const N = y;
|
|
63
|
-
let s;
|
|
64
|
-
e[14] !== t ? (s = P(t, Y), e[14] = t, e[15] = s) : s = e[15];
|
|
65
|
-
const i = s;
|
|
66
|
-
let C;
|
|
67
|
-
e[16] !== t ? (C = P(t, X), e[16] = t, e[17] = C) : C = e[17];
|
|
68
|
-
const H = C;
|
|
69
|
-
let E;
|
|
70
|
-
e[18] !== t ? (E = P(t, Z), e[18] = t, e[19] = E) : E = e[19];
|
|
71
|
-
const z = E, T = z.length > 0, x = h === "horizontal", F = b === "small", M = h === "horizontal" && i.length > 0;
|
|
72
|
-
let W;
|
|
73
|
-
e[20] !== r || e[21] !== T || e[22] !== F || e[23] !== M || e[24] !== x ? (W = S(d.root, r, {
|
|
74
|
-
[d.rootHorizontal]: x,
|
|
75
|
-
[d.rootPaddingSmall]: F,
|
|
76
|
-
[d.rootHorizontalHasSupplementary]: M,
|
|
77
|
-
[d.rootClickable]: T
|
|
78
|
-
}), e[20] = r, e[21] = T, e[22] = F, e[23] = M, e[24] = x, e[25] = W) : W = e[25];
|
|
79
|
-
const R = W, j = b === "small";
|
|
80
|
-
let k;
|
|
81
|
-
e[26] !== o || e[27] !== j ? (k = S(d.contentWrapper, o, {
|
|
82
|
-
[d.contentWrapperPaddingSmall]: j
|
|
83
|
-
}), e[26] = o, e[27] = j, e[28] = k) : k = e[28];
|
|
84
|
-
const O = k;
|
|
85
|
-
let w;
|
|
86
|
-
e[29] !== a ? (w = () => {
|
|
87
|
-
const ae = p.current;
|
|
88
|
-
process.env.NODE_ENV !== "production" && Ce({
|
|
89
|
-
aria: a,
|
|
90
|
-
cardElement: ae
|
|
91
|
-
});
|
|
92
|
-
}, e[29] = a, e[30] = w) : w = e[30];
|
|
93
|
-
const V = a?.["aria-labelledby"], B = a?.["aria-label"];
|
|
94
|
-
let L;
|
|
95
|
-
e[31] !== V || e[32] !== B ? (L = [V, B], e[31] = V, e[32] = B, e[33] = L) : L = e[33], ne(w, L);
|
|
96
|
-
const I = a?.["aria-labelledby"], G = a?.["aria-label"];
|
|
97
|
-
let D;
|
|
98
|
-
e[34] !== O || e[35] !== g || e[36] !== N || e[37] !== _ ? (D = /* @__PURE__ */ J("div", { className: O, children: [
|
|
99
|
-
_,
|
|
100
|
-
g,
|
|
101
|
-
N
|
|
102
|
-
] }), e[34] = O, e[35] = g, e[36] = N, e[37] = _, e[38] = D) : D = e[38];
|
|
103
|
-
let $;
|
|
104
|
-
return e[39] !== H || e[40] !== z || e[41] !== l || e[42] !== R || e[43] !== i || e[44] !== I || e[45] !== G || e[46] !== D ? ($ = /* @__PURE__ */ J("article", { ...l, "aria-labelledby": I, "aria-label": G, ref: p, className: R, children: [
|
|
105
|
-
z,
|
|
106
|
-
D,
|
|
107
|
-
i,
|
|
108
|
-
H
|
|
109
|
-
] }), e[39] = H, e[40] = z, e[41] = l, e[42] = R, e[43] = i, e[44] = I, e[45] = G, e[46] = D, e[47] = $) : $ = e[47], $;
|
|
110
|
-
}, K = (n) => {
|
|
111
|
-
const e = A.c(5), {
|
|
112
|
-
children: a,
|
|
113
|
-
className: t
|
|
114
|
-
} = n;
|
|
115
|
-
let r;
|
|
116
|
-
e[0] !== t ? (r = S(d.header, t) || void 0, e[0] = t, e[1] = r) : r = e[1];
|
|
117
|
-
const o = r;
|
|
118
|
-
let l;
|
|
119
|
-
return e[2] !== a || e[3] !== o ? (l = /* @__PURE__ */ v("header", { className: o, children: a }), e[2] = a, e[3] = o, e[4] = l) : l = e[4], l;
|
|
120
|
-
};
|
|
121
|
-
K.displayName = "DSActionCard.Header";
|
|
122
|
-
const Q = (n) => {
|
|
123
|
-
const e = A.c(5), {
|
|
124
|
-
children: a,
|
|
125
|
-
className: t
|
|
126
|
-
} = n;
|
|
127
|
-
let r;
|
|
128
|
-
e[0] !== t ? (r = S(d.content, t) || void 0, e[0] = t, e[1] = r) : r = e[1];
|
|
129
|
-
const o = r;
|
|
130
|
-
let l;
|
|
131
|
-
return e[2] !== a || e[3] !== o ? (l = /* @__PURE__ */ v("div", { className: o, children: a }), e[2] = a, e[3] = o, e[4] = l) : l = e[4], l;
|
|
132
|
-
};
|
|
133
|
-
Q.displayName = "DSActionCard.Content";
|
|
134
|
-
const U = (n) => {
|
|
135
|
-
const e = A.c(5), {
|
|
136
|
-
children: a,
|
|
137
|
-
className: t
|
|
138
|
-
} = n;
|
|
139
|
-
let r;
|
|
140
|
-
e[0] !== t ? (r = S(d.footer, t) || void 0, e[0] = t, e[1] = r) : r = e[1];
|
|
141
|
-
const o = r;
|
|
142
|
-
let l;
|
|
143
|
-
return e[2] !== a || e[3] !== o ? (l = /* @__PURE__ */ v("footer", { className: o, children: a }), e[2] = a, e[3] = o, e[4] = l) : l = e[4], l;
|
|
144
|
-
};
|
|
145
|
-
U.displayName = "DSActionCard.Footer";
|
|
146
|
-
const X = (n) => {
|
|
147
|
-
const e = A.c(5), {
|
|
148
|
-
children: a,
|
|
149
|
-
className: t
|
|
150
|
-
} = n;
|
|
151
|
-
let r;
|
|
152
|
-
e[0] !== t ? (r = S(d.imageWrapper, t) || void 0, e[0] = t, e[1] = r) : r = e[1];
|
|
153
|
-
const o = r;
|
|
154
|
-
let l;
|
|
155
|
-
return e[2] !== a || e[3] !== o ? (l = /* @__PURE__ */ v("div", { className: o, children: a }), e[2] = a, e[3] = o, e[4] = l) : l = e[4], l;
|
|
156
|
-
};
|
|
157
|
-
X.displayName = "DSActionCard.Media";
|
|
158
|
-
const Y = (n) => {
|
|
159
|
-
const e = A.c(5), {
|
|
160
|
-
children: a,
|
|
161
|
-
className: t
|
|
162
|
-
} = n;
|
|
163
|
-
let r;
|
|
164
|
-
e[0] !== t ? (r = S(d.supplementary, t) || void 0, e[0] = t, e[1] = r) : r = e[1];
|
|
165
|
-
const o = r;
|
|
166
|
-
let l;
|
|
167
|
-
return e[2] !== a || e[3] !== o ? (l = /* @__PURE__ */ v("div", { className: o, children: a }), e[2] = a, e[3] = o, e[4] = l) : l = e[4], l;
|
|
168
|
-
};
|
|
169
|
-
Y.displayName = "DSActionCard.Supplementary";
|
|
170
|
-
const Z = (n) => {
|
|
171
|
-
const e = A.c(56);
|
|
172
|
-
let a, t, r, o, l, m;
|
|
173
|
-
e[0] !== n ? ({
|
|
174
|
-
children: a,
|
|
175
|
-
className: t,
|
|
176
|
-
href: r,
|
|
177
|
-
linkComponent: o,
|
|
178
|
-
onClick: l,
|
|
179
|
-
...m
|
|
180
|
-
} = n, e[0] = n, e[1] = a, e[2] = t, e[3] = r, e[4] = o, e[5] = l, e[6] = m) : (a = e[1], t = e[2], r = e[3], o = e[4], l = e[5], m = e[6]);
|
|
181
|
-
let c, h, b, p, f, _, u, g, y, N;
|
|
182
|
-
if (e[7] !== a || e[8] !== t || e[9] !== o || e[10] !== m) {
|
|
183
|
-
g = /* @__PURE__ */ Symbol.for("react.early_return_sentinel");
|
|
184
|
-
e: {
|
|
185
|
-
p = S(d.primaryAction, t) || void 0;
|
|
186
|
-
const s = m;
|
|
187
|
-
if (e[21] !== s ? ({
|
|
188
|
-
download: h,
|
|
189
|
-
hrefLang: b,
|
|
190
|
-
ping: f,
|
|
191
|
-
referrerPolicy: _,
|
|
192
|
-
rel: u,
|
|
193
|
-
target: y,
|
|
194
|
-
type: N,
|
|
195
|
-
...c
|
|
196
|
-
} = s, e[21] = s, e[22] = c, e[23] = h, e[24] = b, e[25] = f, e[26] = _, e[27] = u, e[28] = y, e[29] = N) : (c = e[22], h = e[23], b = e[24], f = e[25], _ = e[26], u = e[27], y = e[28], N = e[29]), o && te(o)) {
|
|
197
|
-
let i;
|
|
198
|
-
e[30] !== a ? (i = /* @__PURE__ */ v("span", { className: d.primaryActionLabel, children: a }), e[30] = a, e[31] = i) : i = e[31];
|
|
199
|
-
let C;
|
|
200
|
-
e[32] !== o.props.children || e[33] !== i ? (C = /* @__PURE__ */ J(re, { children: [
|
|
201
|
-
i,
|
|
202
|
-
o.props.children
|
|
203
|
-
] }), e[32] = o.props.children, e[33] = i, e[34] = C) : C = e[34], g = se(o, {
|
|
204
|
-
...o.props,
|
|
205
|
-
className: S(p, o.props.className),
|
|
206
|
-
children: C
|
|
207
|
-
});
|
|
208
|
-
break e;
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
e[7] = a, e[8] = t, e[9] = o, e[10] = m, e[11] = c, e[12] = h, e[13] = b, e[14] = p, e[15] = f, e[16] = _, e[17] = u, e[18] = g, e[19] = y, e[20] = N;
|
|
212
|
-
} else
|
|
213
|
-
c = e[11], h = e[12], b = e[13], p = e[14], f = e[15], _ = e[16], u = e[17], g = e[18], y = e[19], N = e[20];
|
|
214
|
-
if (g !== /* @__PURE__ */ Symbol.for("react.early_return_sentinel"))
|
|
215
|
-
return g;
|
|
216
|
-
if (r) {
|
|
217
|
-
let s;
|
|
218
|
-
e[35] !== a ? (s = /* @__PURE__ */ v("span", { className: d.primaryActionLabel, children: a }), e[35] = a, e[36] = s) : s = e[36];
|
|
219
|
-
let i;
|
|
220
|
-
return e[37] !== c || e[38] !== h || e[39] !== r || e[40] !== b || e[41] !== p || e[42] !== f || e[43] !== _ || e[44] !== u || e[45] !== s || e[46] !== y || e[47] !== N ? (i = /* @__PURE__ */ v("a", { href: r, className: p, download: h, hrefLang: b, ping: f, referrerPolicy: _, rel: u, target: y, type: N, ...c, children: s }), e[37] = c, e[38] = h, e[39] = r, e[40] = b, e[41] = p, e[42] = f, e[43] = _, e[44] = u, e[45] = s, e[46] = y, e[47] = N, e[48] = i) : i = e[48], i;
|
|
221
|
-
}
|
|
222
|
-
if (l) {
|
|
223
|
-
let s;
|
|
224
|
-
e[49] !== a ? (s = /* @__PURE__ */ v("span", { className: d.primaryActionLabel, children: a }), e[49] = a, e[50] = s) : s = e[50];
|
|
225
|
-
let i;
|
|
226
|
-
return e[51] !== c || e[52] !== p || e[53] !== l || e[54] !== s ? (i = /* @__PURE__ */ v("button", { type: "button", className: p, onClick: l, ...c, children: s }), e[51] = c, e[52] = p, e[53] = l, e[54] = s, e[55] = i) : i = e[55], i;
|
|
227
|
-
}
|
|
228
|
-
return null;
|
|
229
|
-
};
|
|
230
|
-
Z.displayName = "DSActionCard.PrimaryAction";
|
|
231
|
-
q.Header = K;
|
|
232
|
-
q.Content = Q;
|
|
233
|
-
q.Footer = U;
|
|
234
|
-
q.Media = X;
|
|
235
|
-
q.PrimaryAction = Z;
|
|
236
|
-
q.Supplementary = Y;
|
|
237
|
-
q.displayName = "DSActionCard";
|
|
238
|
-
export {
|
|
239
|
-
q as D,
|
|
240
|
-
P as g,
|
|
241
|
-
Ce as v
|
|
242
|
-
};
|
|
@@ -1,139 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsxs as O, jsx as c } from "react/jsx-runtime";
|
|
3
|
-
import { c as p } from "./index.DQOqod3i.js";
|
|
4
|
-
import { forwardRef as T } from "react";
|
|
5
|
-
import { u as r } from "./useBreakpoint.1txsny17.js";
|
|
6
|
-
import { D as F } from "./Icon.BoywkLCM.js";
|
|
7
|
-
import { DSSpinner as L } from "../spinner.CJmvEaCu.js";
|
|
8
|
-
import { Tooltip as k } from "../tooltip.C6HKano9.js";
|
|
9
|
-
import { g as a } from "./helpers.CexwVao7.js";
|
|
10
|
-
import "./index.cKLI89Eg.js";
|
|
11
|
-
import '../assets/Button.C-UYIggc.css';const C = "ds-button_root_146u3_1", A = "ds-button_root--highlight_146u3_75", E = "ds-button_root--dark-highlight_146u3_75", P = "ds-button_root--filled_146u3_151", x = "ds-button_root--outline_146u3_179", V = "ds-button_root--ghost_146u3_206", j = "ds-button_root--ghost-flush_146u3_231", R = "ds-button_root--small_146u3_237", U = "ds-button_root--navigation_146u3_317", M = "ds-button_root--navigation--stretched_146u3_393", Z = "ds-button_root--navigation--stretched--icon-left_146u3_396", q = "ds-button_root--dark-filled_146u3_399", J = "ds-button_root--dark-outline_146u3_456", K = "ds-button_root--dark-ghost_146u3_512", Q = "ds-button_root--dark-ghost-flush_146u3_566", W = "ds-button_root--stretched_146u3_641", X = "ds-button_root--icon-left_146u3_644", Y = "ds-button_root--icon-only_146u3_647", $ = "ds-button_root--icon-only-small_146u3_656", z = "ds-button_icon--navigation_146u3_672", oo = "ds-button_icon--hidden_146u3_679", to = "ds-button_label--hidden_146u3_683", no = "ds-button_label--loading_146u3_695", eo = "ds-button_loader_146u3_699", o = {
|
|
12
|
-
root: C,
|
|
13
|
-
rootHighlight: A,
|
|
14
|
-
rootDarkHighlight: E,
|
|
15
|
-
rootFilled: P,
|
|
16
|
-
rootOutline: x,
|
|
17
|
-
rootGhost: V,
|
|
18
|
-
rootGhostFlush: j,
|
|
19
|
-
rootSmall: R,
|
|
20
|
-
rootNavigation: U,
|
|
21
|
-
rootNavigationStretched: M,
|
|
22
|
-
rootNavigationStretchedIconLeft: Z,
|
|
23
|
-
rootDarkFilled: q,
|
|
24
|
-
rootDarkOutline: J,
|
|
25
|
-
rootDarkGhost: K,
|
|
26
|
-
rootDarkGhostFlush: Q,
|
|
27
|
-
rootStretched: W,
|
|
28
|
-
rootIconLeft: X,
|
|
29
|
-
rootIconOnly: Y,
|
|
30
|
-
rootIconOnlySmall: $,
|
|
31
|
-
iconNavigation: z,
|
|
32
|
-
iconHidden: oo,
|
|
33
|
-
labelHidden: to,
|
|
34
|
-
labelLoading: no,
|
|
35
|
-
loader: eo
|
|
36
|
-
}, bo = ["medium", "small"], po = ["highlight", "filled", "outline", "ghost", "navigation"], ro = ({
|
|
37
|
-
hideLabel: f,
|
|
38
|
-
iconName: m,
|
|
39
|
-
iconSource: b,
|
|
40
|
-
isFlush: d,
|
|
41
|
-
size: s,
|
|
42
|
-
stretched: l,
|
|
43
|
-
theme: u,
|
|
44
|
-
variant: e
|
|
45
|
-
}) => {
|
|
46
|
-
if (e === "navigation" && (s === "small" && console.warn(a("DSButton", 'A "size" prop should not be used in combination with variant="navigation". Please remove the "size" prop.')), u === "dark"))
|
|
47
|
-
throw new Error(a("DSButton", 'A DSButton with variant="navigation" does not support theme="dark". Please remove the "theme" prop.'));
|
|
48
|
-
e !== "ghost" && d ? console.warn(a("DSButton", 'The "isFlush" prop only has an effect when used with variant="ghost". Please remove the "isFlush" prop or set variant="ghost".')) : e === "ghost" && d && l && console.warn(a("DSButton", 'The "stretched" and "isFlush" props do not have an effect when used together. Please remove one of them.')), f && (!m && !b && console.warn(a("DSButton", 'The "hideLabel" prop is set to true but no icon is provided via "iconName" or "iconSource". Please provide an icon to ensure the button is not empty when the label is hidden.')), l && console.warn(a("DSButton", 'The "stretched" and "hideLabel" props do not have an effect when used together. Please remove one of them.')));
|
|
49
|
-
}, so = T(({
|
|
50
|
-
children: f,
|
|
51
|
-
aria: m,
|
|
52
|
-
className: b,
|
|
53
|
-
disabled: d = !1,
|
|
54
|
-
hideLabel: s = !1,
|
|
55
|
-
iconName: l,
|
|
56
|
-
iconPosition: u = "left",
|
|
57
|
-
iconSource: e,
|
|
58
|
-
isFlush: h = !1,
|
|
59
|
-
loading: i = !1,
|
|
60
|
-
size: _ = "medium",
|
|
61
|
-
stretched: g = !1,
|
|
62
|
-
theme: n = "light",
|
|
63
|
-
tooltip: D,
|
|
64
|
-
variant: t = "filled",
|
|
65
|
-
onClick: S,
|
|
66
|
-
...w
|
|
67
|
-
}, I) => {
|
|
68
|
-
process.env.NODE_ENV !== "production" && ro({
|
|
69
|
-
hideLabel: r(s),
|
|
70
|
-
iconName: l,
|
|
71
|
-
iconSource: e,
|
|
72
|
-
isFlush: h,
|
|
73
|
-
size: _,
|
|
74
|
-
stretched: g,
|
|
75
|
-
theme: n,
|
|
76
|
-
variant: t
|
|
77
|
-
});
|
|
78
|
-
const y = p(o.root, b, {
|
|
79
|
-
// variant
|
|
80
|
-
[o.rootFilled]: t === "filled",
|
|
81
|
-
[o.rootHighlight]: t === "highlight",
|
|
82
|
-
[o.rootOutline]: t === "outline",
|
|
83
|
-
[o.rootGhost]: t === "ghost" && h !== !0,
|
|
84
|
-
[o.rootNavigation]: t === "navigation",
|
|
85
|
-
[o.rootNavigationStretched]: t === "navigation" && r(g) && u === "right",
|
|
86
|
-
[o.rootNavigationStretchedIconLeft]: t === "navigation" && r(g) && u === "left",
|
|
87
|
-
// isFlush
|
|
88
|
-
[o.rootGhostFlush]: t === "ghost" && h === !0,
|
|
89
|
-
// dark theme
|
|
90
|
-
[o.rootDarkFilled]: n === "dark" && t === "filled",
|
|
91
|
-
[o.rootDarkHighlight]: n === "dark" && t === "highlight",
|
|
92
|
-
[o.rootDarkOutline]: n === "dark" && t === "outline",
|
|
93
|
-
[o.rootDarkGhost]: n === "dark" && t === "ghost" && h !== !0,
|
|
94
|
-
// dark isFlush
|
|
95
|
-
[o.rootDarkGhostFlush]: n === "dark" && t === "ghost" && h === !0,
|
|
96
|
-
// size
|
|
97
|
-
[o.rootSmall]: _ === "small" || t === "navigation",
|
|
98
|
-
// stretched
|
|
99
|
-
[o.rootStretched]: r(g),
|
|
100
|
-
// icon position
|
|
101
|
-
[o.rootIconLeft]: u === "left",
|
|
102
|
-
// icon only
|
|
103
|
-
[o.rootIconOnly]: r(s) && _ === "medium" && t !== "navigation",
|
|
104
|
-
[o.rootIconOnlySmall]: r(s) && _ === "small" && t !== "navigation"
|
|
105
|
-
}), B = p({
|
|
106
|
-
// hide label only visually to keep them available for assistive technologies
|
|
107
|
-
[o.labelHidden]: r(s) && t !== "navigation",
|
|
108
|
-
// set label opacity to 0 when loading to prevent button size from changing
|
|
109
|
-
[o.labelLoading]: i
|
|
110
|
-
// if no label classes are set via classNames, return undefined to avoid empty class attribute
|
|
111
|
-
}) || void 0, G = p({
|
|
112
|
-
[o.iconNavigation]: t === "navigation",
|
|
113
|
-
// set icon opacity to 0 when loading to prevent button size from changing
|
|
114
|
-
[o.iconHidden]: i
|
|
115
|
-
}), H = n === "light" && t === "filled" || n === "dark" && t === "outline" || n === "dark" && t === "ghost" ? "dark" : "light", v = /* @__PURE__ */ O("button", { className: y, type: "submit", onClick: (N) => {
|
|
116
|
-
if (d || i) {
|
|
117
|
-
N.preventDefault();
|
|
118
|
-
return;
|
|
119
|
-
}
|
|
120
|
-
S && S(N);
|
|
121
|
-
}, ...m, ...w, "aria-disabled": d || i, "aria-busy": i, ref: I, children: [
|
|
122
|
-
i && /* @__PURE__ */ c(L, { className: o.loader, aria: {
|
|
123
|
-
"aria-label": "Loading state"
|
|
124
|
-
} }),
|
|
125
|
-
/* @__PURE__ */ c("span", { className: B, children: f }),
|
|
126
|
-
(l || e) && /* @__PURE__ */ c(F, { name: l, theme: H, source: e, className: G, "aria-hidden": "true" })
|
|
127
|
-
] });
|
|
128
|
-
return D ? /* @__PURE__ */ O(k, { placement: "top", tooltipOffset: 6, children: [
|
|
129
|
-
/* @__PURE__ */ c(k.Anchor, { children: v }),
|
|
130
|
-
/* @__PURE__ */ c(k.Content, { children: D })
|
|
131
|
-
] }) : v;
|
|
132
|
-
});
|
|
133
|
-
so.displayName = "DSButton";
|
|
134
|
-
export {
|
|
135
|
-
bo as B,
|
|
136
|
-
so as D,
|
|
137
|
-
po as a,
|
|
138
|
-
ro as v
|
|
139
|
-
};
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx as n, jsxs as E } from "react/jsx-runtime";
|
|
3
|
-
import { c as r } from "./index.DQOqod3i.js";
|
|
4
|
-
import { useRef as g, useState as F, useEffect as v } from "react";
|
|
5
|
-
import { D as W } from "./Button.P9uWeVnl.js";
|
|
6
|
-
import { g as x } from "./helpers.CexwVao7.js";
|
|
7
|
-
import "./index.cKLI89Eg.js";
|
|
8
|
-
import '../assets/Dialog.DyiHUgTp.css';const R = "ds-dialog_root_kvopn_5", y = "ds-dialog_content-wrapper_kvopn_166", z = "ds-dialog_content-wrapper--no-footer_kvopn_172", L = "ds-dialog_close-button_kvopn_180", M = "ds-dialog_header_kvopn_193", j = "ds-dialog_content_kvopn_166", H = "ds-dialog_footer_kvopn_195", I = "ds-dialog_header--scrollable_kvopn_216", O = "ds-dialog_header--close-button_kvopn_225", P = "ds-dialog_content--no-footer_kvopn_238", T = "ds-dialog_footer--scrollable_kvopn_245", o = {
|
|
9
|
-
root: R,
|
|
10
|
-
contentWrapper: y,
|
|
11
|
-
contentWrapperNoFooter: z,
|
|
12
|
-
closeButton: L,
|
|
13
|
-
header: M,
|
|
14
|
-
content: j,
|
|
15
|
-
footer: H,
|
|
16
|
-
headerScrollable: I,
|
|
17
|
-
headerCloseButton: O,
|
|
18
|
-
contentNoFooter: P,
|
|
19
|
-
footerScrollable: T
|
|
20
|
-
}, V = ({
|
|
21
|
-
tabIndex: s
|
|
22
|
-
}) => {
|
|
23
|
-
if (s || s === 0)
|
|
24
|
-
throw new Error(x("DSDialog", "Do not pass the tabindex property to the DSDialog component as it is not interactive and does not receive focus. The DSDialogs contents, including the close button contained in the DSDialog, can receive focus and be interactive."));
|
|
25
|
-
}, U = ({
|
|
26
|
-
children: s,
|
|
27
|
-
className: m,
|
|
28
|
-
closeButtonProps: b,
|
|
29
|
-
disableBackdropClose: D = !1,
|
|
30
|
-
footer: c,
|
|
31
|
-
header: S,
|
|
32
|
-
hideCloseButton: a = !1,
|
|
33
|
-
isOpen: i = !1,
|
|
34
|
-
onClose: l,
|
|
35
|
-
...d
|
|
36
|
-
}) => {
|
|
37
|
-
if (process.env.NODE_ENV !== "production") {
|
|
38
|
-
const {
|
|
39
|
-
tabIndex: e
|
|
40
|
-
} = d;
|
|
41
|
-
V({
|
|
42
|
-
tabIndex: e
|
|
43
|
-
});
|
|
44
|
-
}
|
|
45
|
-
const {
|
|
46
|
-
label: k = "Close dialog",
|
|
47
|
-
...N
|
|
48
|
-
} = b || {}, t = g(null), p = g(null), [u, B] = F(!1);
|
|
49
|
-
v(() => {
|
|
50
|
-
const e = p.current;
|
|
51
|
-
if (e) {
|
|
52
|
-
const _ = () => {
|
|
53
|
-
B(e.scrollHeight > e.clientHeight);
|
|
54
|
-
};
|
|
55
|
-
_();
|
|
56
|
-
const h = new ResizeObserver(_);
|
|
57
|
-
return h.observe(e), () => {
|
|
58
|
-
h.disconnect();
|
|
59
|
-
};
|
|
60
|
-
}
|
|
61
|
-
}, []), v(() => {
|
|
62
|
-
const e = t.current;
|
|
63
|
-
if (e)
|
|
64
|
-
return e.addEventListener("close", f), i ? e.showModal() : e.close(), () => {
|
|
65
|
-
e.removeEventListener("close", f);
|
|
66
|
-
};
|
|
67
|
-
}, [i, l]);
|
|
68
|
-
const f = () => {
|
|
69
|
-
l && l();
|
|
70
|
-
}, w = (e) => {
|
|
71
|
-
D || t.current && e.target === t.current && t.current.close();
|
|
72
|
-
}, C = () => {
|
|
73
|
-
t.current && t.current.close();
|
|
74
|
-
};
|
|
75
|
-
return /* @__PURE__ */ n("dialog", { ...d, ref: t, className: r(o.root, m), onMouseDown: (e) => w(e), "aria-modal": "true", children: /* @__PURE__ */ E("div", { className: r(o.contentWrapper, {
|
|
76
|
-
[o.contentWrapperNoFooter]: !c
|
|
77
|
-
}), children: [
|
|
78
|
-
!a && /* @__PURE__ */ n(W, { ...N, className: o.closeButton, hideLabel: !0, iconName: "cross", size: "small", type: "button", variant: "ghost", onClick: () => C(), children: k }),
|
|
79
|
-
/* @__PURE__ */ n("header", { className: r(o.header, {
|
|
80
|
-
[o.headerCloseButton]: !a,
|
|
81
|
-
[o.headerScrollable]: u
|
|
82
|
-
}), children: S }),
|
|
83
|
-
/* @__PURE__ */ n(
|
|
84
|
-
"div",
|
|
85
|
-
{
|
|
86
|
-
ref: p,
|
|
87
|
-
className: r(o.content, {
|
|
88
|
-
[o.contentNoFooter]: !c
|
|
89
|
-
}),
|
|
90
|
-
tabIndex: 0,
|
|
91
|
-
children: s
|
|
92
|
-
}
|
|
93
|
-
),
|
|
94
|
-
c && /* @__PURE__ */ n("footer", { className: r(o.footer, {
|
|
95
|
-
[o.footerScrollable]: u
|
|
96
|
-
}), children: c })
|
|
97
|
-
] }) });
|
|
98
|
-
};
|
|
99
|
-
export {
|
|
100
|
-
U as D,
|
|
101
|
-
V as v
|
|
102
|
-
};
|
|
@@ -1,107 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx as t, jsxs as F } from "react/jsx-runtime";
|
|
3
|
-
import { c as n } from "./index.DQOqod3i.js";
|
|
4
|
-
import { useRef as p, useState as R, useEffect as v } from "react";
|
|
5
|
-
import { D as k } from "./Button.P9uWeVnl.js";
|
|
6
|
-
import { g as x } from "./helpers.CexwVao7.js";
|
|
7
|
-
import "./index.cKLI89Eg.js";
|
|
8
|
-
import '../assets/Drawer.UugEajR2.css';const I = "ds-drawer_root_4nbv0_10", O = "ds-drawer_root--end_4nbv0_68", y = "ds-drawer_content-wrapper_4nbv0_169", z = "ds-drawer_content-wrapper--no-footer_4nbv0_175", L = "ds-drawer_close-button_4nbv0_178", M = "ds-drawer_header_4nbv0_191", P = "ds-drawer_content_4nbv0_169", j = "ds-drawer_footer_4nbv0_193", H = "ds-drawer_header--scrollable_4nbv0_214", T = "ds-drawer_header--close-button_4nbv0_223", A = "ds-drawer_content--no-footer_4nbv0_237", V = "ds-drawer_footer--scrollable_4nbv0_244", o = {
|
|
9
|
-
root: I,
|
|
10
|
-
rootEnd: O,
|
|
11
|
-
contentWrapper: y,
|
|
12
|
-
contentWrapperNoFooter: z,
|
|
13
|
-
closeButton: L,
|
|
14
|
-
header: M,
|
|
15
|
-
content: P,
|
|
16
|
-
footer: j,
|
|
17
|
-
headerScrollable: H,
|
|
18
|
-
headerCloseButton: T,
|
|
19
|
-
contentNoFooter: A,
|
|
20
|
-
footerScrollable: V
|
|
21
|
-
}, Y = ["start", "end"], q = ({
|
|
22
|
-
tabIndex: s
|
|
23
|
-
}) => {
|
|
24
|
-
if (s || s === 0)
|
|
25
|
-
throw new Error(x("DSDrawer", "Do not pass the tabindex property to the DSDrawer component as it is not interactive and does not receive focus. The DSDrawers contents, including the close button contained in the DSDrawer, can receive focus and be interactive."));
|
|
26
|
-
}, Z = ({
|
|
27
|
-
children: s,
|
|
28
|
-
className: w,
|
|
29
|
-
closeButtonProps: m,
|
|
30
|
-
disableBackdropClose: D = !1,
|
|
31
|
-
footer: c,
|
|
32
|
-
header: S,
|
|
33
|
-
hideCloseButton: l = !1,
|
|
34
|
-
position: N = "start",
|
|
35
|
-
isOpen: d = !1,
|
|
36
|
-
onClose: a,
|
|
37
|
-
...i
|
|
38
|
-
}) => {
|
|
39
|
-
if (process.env.NODE_ENV !== "production") {
|
|
40
|
-
const {
|
|
41
|
-
tabIndex: e
|
|
42
|
-
} = i;
|
|
43
|
-
q({
|
|
44
|
-
tabIndex: e
|
|
45
|
-
});
|
|
46
|
-
}
|
|
47
|
-
const {
|
|
48
|
-
label: E = "Close modal",
|
|
49
|
-
...g
|
|
50
|
-
} = m || {}, r = p(null), _ = p(null), [u, B] = R(!1);
|
|
51
|
-
v(() => {
|
|
52
|
-
const e = _.current;
|
|
53
|
-
if (e) {
|
|
54
|
-
const f = () => {
|
|
55
|
-
B(e.scrollHeight > e.clientHeight);
|
|
56
|
-
};
|
|
57
|
-
f();
|
|
58
|
-
const h = new ResizeObserver(f);
|
|
59
|
-
return h.observe(e), () => {
|
|
60
|
-
h.disconnect();
|
|
61
|
-
};
|
|
62
|
-
}
|
|
63
|
-
}, []), v(() => {
|
|
64
|
-
const e = r.current;
|
|
65
|
-
if (e)
|
|
66
|
-
return e.addEventListener("close", b), d ? e.showModal() : e.close(), () => {
|
|
67
|
-
e.removeEventListener("close", b);
|
|
68
|
-
};
|
|
69
|
-
}, [d, a]);
|
|
70
|
-
const b = () => {
|
|
71
|
-
a && a();
|
|
72
|
-
}, C = (e) => {
|
|
73
|
-
D || r.current && e.target === r.current && r.current.close();
|
|
74
|
-
}, W = () => {
|
|
75
|
-
r.current && r.current.close();
|
|
76
|
-
};
|
|
77
|
-
return /* @__PURE__ */ t("dialog", { ...i, ref: r, className: n(o.root, {
|
|
78
|
-
[o.rootEnd]: N === "end"
|
|
79
|
-
}), onMouseDown: (e) => C(e), "aria-modal": "true", children: /* @__PURE__ */ F("div", { className: n(o.contentWrapper, w, {
|
|
80
|
-
[o.contentWrapperNoFooter]: !c
|
|
81
|
-
}), children: [
|
|
82
|
-
!l && /* @__PURE__ */ t(k, { ...g, className: o.closeButton, hideLabel: !0, iconName: "cross", size: "small", type: "button", variant: "ghost", onClick: () => W(), children: E }),
|
|
83
|
-
/* @__PURE__ */ t("header", { className: n(o.header, {
|
|
84
|
-
[o.headerCloseButton]: !l,
|
|
85
|
-
[o.headerScrollable]: u
|
|
86
|
-
}), children: S }),
|
|
87
|
-
/* @__PURE__ */ t(
|
|
88
|
-
"div",
|
|
89
|
-
{
|
|
90
|
-
ref: _,
|
|
91
|
-
className: n(o.content, {
|
|
92
|
-
[o.contentNoFooter]: !c
|
|
93
|
-
}),
|
|
94
|
-
tabIndex: 0,
|
|
95
|
-
children: s
|
|
96
|
-
}
|
|
97
|
-
),
|
|
98
|
-
c && /* @__PURE__ */ t("footer", { className: n(o.footer, {
|
|
99
|
-
[o.footerScrollable]: u
|
|
100
|
-
}), children: c })
|
|
101
|
-
] }) });
|
|
102
|
-
};
|
|
103
|
-
export {
|
|
104
|
-
Z as D,
|
|
105
|
-
Y as a,
|
|
106
|
-
q as v
|
|
107
|
-
};
|