@alfadocs/ui-kit 1.45.0 → 1.47.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/_chunks/{actions-cell-renderer-BXBy9c0f.js → actions-cell-renderer-B5m9lwgC.js} +2 -2
- package/dist/_chunks/ai-credits-notice-xszqOZTC.js +90 -0
- package/dist/_chunks/ai-credits-notice.agent-C9L7orrP.js +17 -0
- package/dist/_chunks/{ai-consent-banner-D7I2U-cz.js → ai-permission-notice-D7I2U-cz.js} +1 -1
- package/dist/_chunks/ai-sparkle-D23NT8Z_.js +45 -0
- package/dist/_chunks/{anamnesis-summary-rows-DQUqwWc1.js → anamnesis-summary-rows-DI-UX5r6.js} +2 -2
- package/dist/_chunks/{appointment-card-TgR_2GKS.js → appointment-card-DluZy8Iv.js} +2 -2
- package/dist/_chunks/{appointment-peek-abiR0T9e.js → appointment-peek-BsfCpiJs.js} +3 -3
- package/dist/_chunks/{appointment-timeline-CCnyUYKz.js → appointment-timeline-Cs5f9viN.js} +3 -3
- package/dist/_chunks/{appointment-tray-N0yEI8UF.js → appointment-tray-CLrGGnKR.js} +2 -2
- package/dist/_chunks/baby-Dku-Xvg9.js +23 -0
- package/dist/_chunks/{balance-badge-cell-o6LldMUA.js → balance-badge-cell-YGrYdrvR.js} +3 -3
- package/dist/_chunks/booking-C4MwImkS.js +3362 -0
- package/dist/_chunks/button-group-CA1tmu39.js +325 -0
- package/dist/_chunks/{calendar-U6N0F99w.js → calendar-OzSeTb4V.js} +2 -2
- package/dist/_chunks/{calendar-event-card-DKUnT9Be.js → calendar-event-card-B6N5h1dO.js} +57 -48
- package/dist/_chunks/calendar-workspace-DDnQmiIL.js +12427 -0
- package/dist/_chunks/{chart-PF2krCZC.js → chart-D8ucl8hH.js} +2 -2
- package/dist/_chunks/{data-table-CcAx_I1w.js → data-table-DnKOmEVw.js} +2 -2
- package/dist/_chunks/{editable-currency-cell-renderer-Psb6XKHR.js → editable-currency-cell-renderer-OUkUv7U4.js} +2 -2
- package/dist/_chunks/{face-scheme-Bm6pe7R8.js → face-scheme-mIhwrQXt.js} +3 -3
- package/dist/_chunks/{file-manager-BfLQxF5t.js → file-manager-DOcJGIx2.js} +4 -4
- package/dist/_chunks/{freemium-paywall-Cz-O9lQD.js → freemium-paywall-BaW5ODc9.js} +2 -2
- package/dist/_chunks/{header-settings-CTe45iDy.js → header-settings-BEfx_-TF.js} +2 -2
- package/dist/_chunks/{help-me-write-templates-GUeEn3Ff.js → help-me-write-templates-DHIwa4xR.js} +205 -199
- package/dist/_chunks/{hover-card-BMJBVqIf.js → hover-card-nUae8NPJ.js} +67 -62
- package/dist/_chunks/{icon-button-group-DkkdIygu.js → icon-button-group-DZKC6KGf.js} +181 -168
- package/dist/_chunks/kit-extensions-DuoFF1R3.js +94 -0
- package/dist/_chunks/{marketplace-app-shell-DdwPj03y.js → marketplace-app-shell-PB89Dkk_.js} +2 -2
- package/dist/_chunks/{notes-panel-Dkk9QPPX.js → notes-panel-CHbDDMx8.js} +83 -73
- package/dist/_chunks/{patient-details-C8ImUrVg.js → patient-details-yrgkSeEY.js} +2 -2
- package/dist/_chunks/{patient-field-row-BRSOKvme.js → patient-field-row-DCMkFGqI.js} +3 -3
- package/dist/_chunks/{patient-summary-card-BhmKB2KR.js → patient-summary-card-CmEFflGS.js} +59 -45
- package/dist/_chunks/payment-form-DqJFiplX.js +881 -0
- package/dist/_chunks/{phone-input-BsZIoE36.js → phone-input-IWrGOCwm.js} +40 -39
- package/dist/_chunks/rich-text-editor-BwDV2XkZ.js +4153 -0
- package/dist/_chunks/{stepper-accordion-DmVykr5F.js → stepper-accordion-jMR8NaOB.js} +2 -1
- package/dist/_chunks/{tasks-panel-CpcikOeY.js → tasks-panel-DncuBPIZ.js} +2 -2
- package/dist/_chunks/{theme-toggle-bI0pgDDv.js → theme-toggle-BP0XRGMM.js} +2 -2
- package/dist/_chunks/use-ai-sparkle-Cf4yVTLB.js +76 -0
- package/dist/_chunks/{workflow-status-xeaJTzD3.js → workflow-status-CuJAOuKL.js} +43 -42
- package/dist/agent-catalog.json +36 -7
- package/dist/agent-i18n/en.json +3 -3
- package/dist/components/ai-credits-notice/ai-credits-notice.agent.d.ts +3 -0
- package/dist/components/ai-credits-notice/ai-credits-notice.d.ts +48 -0
- package/dist/components/ai-credits-notice/index.d.ts +4 -0
- package/dist/components/ai-credits-notice/index.js +7 -0
- package/dist/components/{ai-consent-banner/ai-consent-banner.agent.d.ts → ai-permission-notice/ai-permission-notice.agent.d.ts} +2 -2
- package/dist/components/{ai-consent-banner/ai-consent-banner.d.ts → ai-permission-notice/ai-permission-notice.d.ts} +1 -1
- package/dist/components/ai-permission-notice/index.d.ts +4 -0
- package/dist/components/{ai-consent-banner → ai-permission-notice}/index.js +1 -1
- package/dist/components/ai-sparkle/ai-sparkle.d.ts +3 -3
- package/dist/components/ai-sparkle/index.js +1 -1
- package/dist/components/appointment-card/index.js +2 -2
- package/dist/components/appointment-peek/index.js +1 -1
- package/dist/components/appointment-timeline/index.js +1 -1
- package/dist/components/booking/booking-types.d.ts +60 -1
- package/dist/components/booking/booking.d.ts +1 -1
- package/dist/components/booking/details-form.d.ts +5 -1
- package/dist/components/booking/index.d.ts +1 -1
- package/dist/components/booking/index.js +1 -1
- package/dist/components/booking/payment.d.ts +9 -0
- package/dist/components/booking/use-booking-payment.d.ts +14 -0
- package/dist/components/button-group/index.js +1 -1
- package/dist/components/calendar/index.js +1 -1
- package/dist/components/calendar-event-card/index.js +1 -1
- package/dist/components/chart/index.js +1 -1
- package/dist/components/data-table/index.js +3 -3
- package/dist/components/face-scheme/index.js +1 -1
- package/dist/components/file-manager/index.js +1 -1
- package/dist/components/freemium-paywall/index.js +1 -1
- package/dist/components/header-settings/index.js +1 -1
- package/dist/components/hover-card/hover-card.d.ts +4 -0
- package/dist/components/hover-card/index.d.ts +1 -1
- package/dist/components/hover-card/index.js +3 -2
- package/dist/components/icon-button-group/index.js +1 -1
- package/dist/components/index.d.ts +2 -1
- package/dist/components/notes-panel/index.js +1 -1
- package/dist/components/notes-panel/notes-panel.d.ts +10 -0
- package/dist/components/patient-details/index.js +1 -1
- package/dist/components/patient-summary-card/index.js +1 -1
- package/dist/components/patient-table/index.js +1 -1
- package/dist/components/payment-form/index.d.ts +1 -1
- package/dist/components/payment-form/index.js +1 -1
- package/dist/components/payment-form/payment-form.d.ts +35 -3
- package/dist/components/phone-input/index.js +1 -1
- package/dist/components/rich-text-editor/editor-extensions.d.ts +54 -0
- package/dist/components/rich-text-editor/editor-toolbar.d.ts +2 -1
- package/dist/components/rich-text-editor/help-me-write-overlay.d.ts +4 -0
- package/dist/components/rich-text-editor/index.d.ts +2 -0
- package/dist/components/rich-text-editor/index.js +6 -4
- package/dist/components/rich-text-editor/kit-extensions.d.ts +4 -0
- package/dist/components/rich-text-editor/rich-text-editor.d.ts +18 -2
- package/dist/components/stepper-accordion/index.js +1 -1
- package/dist/components/tasks-panel/index.js +1 -1
- package/dist/components/theme-toggle/index.js +1 -1
- package/dist/components/workflow-status/index.js +1 -1
- package/dist/hooks/index.d.ts +1 -1
- package/dist/hooks/index.js +51 -53
- package/dist/hooks/use-ai-sparkle.d.ts +7 -25
- package/dist/host-compat.css +2 -2
- package/dist/i18n/locales/ar.d.ts +67 -1
- package/dist/i18n/locales/ar.js +69 -3
- package/dist/i18n/locales/de.d.ts +67 -1
- package/dist/i18n/locales/de.js +69 -3
- package/dist/i18n/locales/el.d.ts +67 -1
- package/dist/i18n/locales/el.js +69 -3
- package/dist/i18n/locales/en.d.ts +67 -1
- package/dist/i18n/locales/en.js +69 -3
- package/dist/i18n/locales/es.d.ts +67 -1
- package/dist/i18n/locales/es.js +69 -3
- package/dist/i18n/locales/fr.d.ts +67 -1
- package/dist/i18n/locales/fr.js +69 -3
- package/dist/i18n/locales/hi.d.ts +67 -1
- package/dist/i18n/locales/hi.js +69 -3
- package/dist/i18n/locales/it.d.ts +67 -1
- package/dist/i18n/locales/it.js +69 -3
- package/dist/i18n/locales/ja.d.ts +67 -1
- package/dist/i18n/locales/ja.js +69 -3
- package/dist/i18n/locales/nl.d.ts +67 -1
- package/dist/i18n/locales/nl.js +69 -3
- package/dist/i18n/locales/pl.d.ts +67 -1
- package/dist/i18n/locales/pl.js +69 -3
- package/dist/i18n/locales/pt.d.ts +67 -1
- package/dist/i18n/locales/pt.js +69 -3
- package/dist/i18n/locales/ro.d.ts +67 -1
- package/dist/i18n/locales/ro.js +69 -3
- package/dist/i18n/locales/ru.d.ts +67 -1
- package/dist/i18n/locales/ru.js +69 -3
- package/dist/i18n/locales/sq.d.ts +67 -1
- package/dist/i18n/locales/sq.js +69 -3
- package/dist/i18n/locales/sv.d.ts +67 -1
- package/dist/i18n/locales/sv.js +69 -3
- package/dist/i18n/locales/tr.d.ts +67 -1
- package/dist/i18n/locales/tr.js +69 -3
- package/dist/i18n/locales/zh.d.ts +67 -1
- package/dist/i18n/locales/zh.js +69 -3
- package/dist/index.js +648 -641
- package/dist/locales/ar.json +69 -3
- package/dist/locales/de.json +69 -3
- package/dist/locales/el.json +69 -3
- package/dist/locales/en.json +69 -3
- package/dist/locales/es.json +69 -3
- package/dist/locales/fr.json +69 -3
- package/dist/locales/hi.json +69 -3
- package/dist/locales/it.json +69 -3
- package/dist/locales/ja.json +69 -3
- package/dist/locales/nl.json +69 -3
- package/dist/locales/pl.json +69 -3
- package/dist/locales/pt.json +69 -3
- package/dist/locales/ro.json +69 -3
- package/dist/locales/ru.json +69 -3
- package/dist/locales/sq.json +69 -3
- package/dist/locales/sv.json +69 -3
- package/dist/locales/tr.json +69 -3
- package/dist/locales/zh.json +69 -3
- package/dist/patterns/anamnesis/index.js +1 -1
- package/dist/patterns/calendar/calendar-editor-fields.d.ts +33 -0
- package/dist/patterns/calendar/calendar-sticky-offset.d.ts +20 -0
- package/dist/patterns/calendar/calendar-workspace.d.ts +6 -4
- package/dist/patterns/calendar/calendar.data.d.ts +26 -0
- package/dist/patterns/calendar/calendar.journey.d.ts +1 -1
- package/dist/patterns/calendar/calendar.sheets.d.ts +16 -5
- package/dist/patterns/calendar/calendar.types.d.ts +25 -9
- package/dist/patterns/calendar/index.js +1 -1
- package/dist/patterns/help-me-write-templates/help-me-write-templates.d.ts +11 -2
- package/dist/patterns/help-me-write-templates/index.js +1 -1
- package/dist/patterns/marketplace-app-shell/index.js +1 -1
- package/dist/tokens.css +1 -1
- package/package.json +14 -4
- package/dist/_chunks/ai-sparkle-DXeP_6a0.js +0 -52
- package/dist/_chunks/booking-D43ASl8y.js +0 -3034
- package/dist/_chunks/button-group-R32U7SyV.js +0 -307
- package/dist/_chunks/calendar-workspace-B7KvZ1_D.js +0 -12161
- package/dist/_chunks/payment-form-BHMDqW9C.js +0 -767
- package/dist/_chunks/rich-text-editor-BrAvNajV.js +0 -3779
- package/dist/_chunks/use-ai-sparkle-CyQSRTCe.js +0 -103
- package/dist/components/ai-consent-banner/index.d.ts +0 -4
|
@@ -1,307 +0,0 @@
|
|
|
1
|
-
import { jsx as s, jsxs as z } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as be, useRef as L, useState as ee, useCallback as ge, Children as T, isValidElement as re, useEffect as we, cloneElement as G } from "react";
|
|
3
|
-
import { c as ve } from "./index-D2ZczOXr.js";
|
|
4
|
-
import { useTranslation as ye } from "react-i18next";
|
|
5
|
-
import { I as te } from "./icon-button-CehAeZoP.js";
|
|
6
|
-
import { D as C } from "./dropdown-menu-DU-Hrf33.js";
|
|
7
|
-
import { T as he } from "./tooltip-Cp-PLePW.js";
|
|
8
|
-
import { u as Re } from "./use-isomorphic-layout-effect-BGfaCOP1.js";
|
|
9
|
-
import { u as xe } from "./use-priority-overflow-c9SjxZkZ.js";
|
|
10
|
-
import { E as oe } from "./ellipsis-dRo9ouSU.js";
|
|
11
|
-
const ne = ve(
|
|
12
|
-
"ds:inline-flex ds:isolate ds:[&>*]:relative ds:[&>*:focus-visible]:z-10",
|
|
13
|
-
{
|
|
14
|
-
variants: {
|
|
15
|
-
orientation: {
|
|
16
|
-
horizontal: [
|
|
17
|
-
"ds:flex-row",
|
|
18
|
-
"ds:[&>*:not(:first-child)]:rounded-s-none",
|
|
19
|
-
"ds:[&>*:not(:last-child)]:rounded-e-none",
|
|
20
|
-
"ds:[&>*:not(:first-child)]:-ms-px"
|
|
21
|
-
].join(" "),
|
|
22
|
-
vertical: [
|
|
23
|
-
"ds:flex-col",
|
|
24
|
-
"ds:[&>*:not(:first-child)]:rounded-t-none",
|
|
25
|
-
"ds:[&>*:not(:last-child)]:rounded-b-none",
|
|
26
|
-
"ds:[&>*:not(:first-child)]:-mt-px"
|
|
27
|
-
].join(" ")
|
|
28
|
-
},
|
|
29
|
-
separator: {
|
|
30
|
-
true: "",
|
|
31
|
-
false: ""
|
|
32
|
-
}
|
|
33
|
-
},
|
|
34
|
-
compoundVariants: [
|
|
35
|
-
{
|
|
36
|
-
orientation: "horizontal",
|
|
37
|
-
separator: !0,
|
|
38
|
-
class: "ds:[&>*:not(:last-child)]:border-e ds:[&>*:not(:last-child)]:border-border"
|
|
39
|
-
},
|
|
40
|
-
{
|
|
41
|
-
orientation: "vertical",
|
|
42
|
-
separator: !0,
|
|
43
|
-
class: "ds:[&>*:not(:last-child)]:border-b ds:[&>*:not(:last-child)]:border-border"
|
|
44
|
-
}
|
|
45
|
-
],
|
|
46
|
-
defaultVariants: {
|
|
47
|
-
orientation: "horizontal",
|
|
48
|
-
separator: !1
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
), K = "ds:absolute ds:start-0 ds:top-0 ds:invisible ds:pointer-events-none", Ie = be(
|
|
52
|
-
({
|
|
53
|
-
className: $,
|
|
54
|
-
orientation: f = "horizontal",
|
|
55
|
-
separator: V = !1,
|
|
56
|
-
toolbar: g = !1,
|
|
57
|
-
intent: w = "outline",
|
|
58
|
-
background: v = "transparent",
|
|
59
|
-
size: l,
|
|
60
|
-
label: se,
|
|
61
|
-
overflow: ae = "none",
|
|
62
|
-
collapseToIcons: A = !1,
|
|
63
|
-
children: N,
|
|
64
|
-
...M
|
|
65
|
-
}, y) => {
|
|
66
|
-
const { t: O } = ye(), P = se ?? O("buttonGroup.label", "Button group"), U = O("buttonGroup.more", "More options"), u = ae === "menu" && f !== "vertical", d = g, m = L([]), [c, h] = ee(0), _ = L(null), [S, ie] = ee(!1);
|
|
67
|
-
Re(() => {
|
|
68
|
-
if (typeof window > "u") return;
|
|
69
|
-
const e = _.current;
|
|
70
|
-
e && ie(window.getComputedStyle(e).direction === "rtl");
|
|
71
|
-
}, []);
|
|
72
|
-
const H = ge(
|
|
73
|
-
(e) => {
|
|
74
|
-
var R;
|
|
75
|
-
if (!d) return;
|
|
76
|
-
const r = m.current.filter(Boolean).length;
|
|
77
|
-
if (r === 0) return;
|
|
78
|
-
const t = f === "vertical" ? "ArrowDown" : S ? "ArrowLeft" : "ArrowRight", o = f === "vertical" ? "ArrowUp" : S ? "ArrowRight" : "ArrowLeft";
|
|
79
|
-
let n = null;
|
|
80
|
-
if (e.key === t ? n = (c + 1) % r : e.key === o ? n = (c - 1 + r) % r : e.key === "Home" ? n = 0 : e.key === "End" && (n = r - 1), n === null) return;
|
|
81
|
-
const i = r;
|
|
82
|
-
let a = 0, p = n;
|
|
83
|
-
for (; a < i; ) {
|
|
84
|
-
const x = m.current[p];
|
|
85
|
-
if (x && x.getAttribute("aria-disabled") !== "true" && !x.disabled)
|
|
86
|
-
break;
|
|
87
|
-
p = e.key === o || e.key === "End" ? (p - 1 + r) % r : (p + 1) % r, a += 1;
|
|
88
|
-
}
|
|
89
|
-
e.preventDefault(), h(p), (R = m.current[p]) == null || R.focus();
|
|
90
|
-
},
|
|
91
|
-
[d, f, S, c]
|
|
92
|
-
), b = u ? T.toArray(N).filter(re) : [], j = (e) => {
|
|
93
|
-
if (typeof e.props.children == "string") return e.props.children;
|
|
94
|
-
const r = e.props["aria-label"];
|
|
95
|
-
return typeof r == "string" ? r : null;
|
|
96
|
-
};
|
|
97
|
-
L(!1);
|
|
98
|
-
const le = b.map((e) => {
|
|
99
|
-
const r = e.props["data-overflow-pin"] !== void 0, t = j(e) !== null;
|
|
100
|
-
return r || !t;
|
|
101
|
-
}), {
|
|
102
|
-
containerRef: ue,
|
|
103
|
-
fullRowRef: de,
|
|
104
|
-
iconRowRef: ce,
|
|
105
|
-
triggerProbeRef: pe,
|
|
106
|
-
stage: fe,
|
|
107
|
-
visible: B,
|
|
108
|
-
overflowing: I
|
|
109
|
-
} = xe({
|
|
110
|
-
enabled: u,
|
|
111
|
-
count: b.length,
|
|
112
|
-
twoStage: A,
|
|
113
|
-
pinned: le
|
|
114
|
-
}), W = L(null), k = u ? B.filter(Boolean).length : T.count(N);
|
|
115
|
-
we(() => {
|
|
116
|
-
var r;
|
|
117
|
-
if (!d || !u) return;
|
|
118
|
-
const e = k + (I ? 1 : 0);
|
|
119
|
-
e > 0 && c >= e && (h(e - 1), document.activeElement === document.body && ((r = W.current) == null || r.focus()));
|
|
120
|
-
}, [
|
|
121
|
-
d,
|
|
122
|
-
u,
|
|
123
|
-
k,
|
|
124
|
-
I,
|
|
125
|
-
c
|
|
126
|
-
]);
|
|
127
|
-
const q = (e, r) => (t) => {
|
|
128
|
-
m.current[r] = t;
|
|
129
|
-
const o = e.ref;
|
|
130
|
-
typeof o == "function" ? o(t) : o != null && typeof o == "object" && (o.current = t);
|
|
131
|
-
}, me = u ? null : T.map(N, (e, r) => {
|
|
132
|
-
if (!re(e)) return e;
|
|
133
|
-
const t = e, o = {
|
|
134
|
-
intent: t.props.intent ?? w,
|
|
135
|
-
background: t.props.background ?? v,
|
|
136
|
-
...l ? { size: t.props.size ?? l } : null
|
|
137
|
-
};
|
|
138
|
-
return d && (o.tabIndex = r === c ? 0 : -1, o.onFocus = (n) => {
|
|
139
|
-
var i, a;
|
|
140
|
-
h(r), (a = (i = t.props).onFocus) == null || a.call(i, n);
|
|
141
|
-
}, o.ref = q(t, r)), G(
|
|
142
|
-
t,
|
|
143
|
-
o
|
|
144
|
-
);
|
|
145
|
-
});
|
|
146
|
-
let J = null, Q = null;
|
|
147
|
-
if (u) {
|
|
148
|
-
m.current.length = k + (I ? 1 : 0);
|
|
149
|
-
let e = -1;
|
|
150
|
-
J = b.map((r, t) => {
|
|
151
|
-
if (!B[t]) return null;
|
|
152
|
-
e += 1;
|
|
153
|
-
const o = e, n = {
|
|
154
|
-
intent: r.props.intent ?? w,
|
|
155
|
-
background: r.props.background ?? v,
|
|
156
|
-
...l ? { size: r.props.size ?? l } : null
|
|
157
|
-
};
|
|
158
|
-
A && fe === "icons" && r.props.children && (r.props.startIcon || r.props.endIcon) && (n.hideLabel = !0), d && (n.tabIndex = o === c ? 0 : -1, n.onFocus = (x) => {
|
|
159
|
-
var Z, E;
|
|
160
|
-
h(o), (E = (Z = r.props).onFocus) == null || E.call(Z, x);
|
|
161
|
-
}, n.ref = q(r, o));
|
|
162
|
-
const i = n.hideLabel === !0, a = G(
|
|
163
|
-
r,
|
|
164
|
-
n
|
|
165
|
-
), p = r.props["data-overflow-tip"] === !1 || r.props["data-overflow-tip"] === "false", R = i && !p ? j(r) : null;
|
|
166
|
-
return R ? /* @__PURE__ */ s(he, { label: R, children: a }, r.key ?? t) : a;
|
|
167
|
-
}), Q = b.map((r, t) => {
|
|
168
|
-
if (B[t]) return null;
|
|
169
|
-
const o = j(r);
|
|
170
|
-
return o === null ? null : /* @__PURE__ */ s(
|
|
171
|
-
C.Item,
|
|
172
|
-
{
|
|
173
|
-
startIcon: r.props.startIcon,
|
|
174
|
-
disabled: r.props.disabled === !0 || r.props.loading === !0,
|
|
175
|
-
onSelect: (n) => {
|
|
176
|
-
var i, a;
|
|
177
|
-
(a = (i = r.props).onClick) == null || a.call(
|
|
178
|
-
i,
|
|
179
|
-
n
|
|
180
|
-
);
|
|
181
|
-
},
|
|
182
|
-
children: o
|
|
183
|
-
},
|
|
184
|
-
r.key ?? t
|
|
185
|
-
);
|
|
186
|
-
});
|
|
187
|
-
}
|
|
188
|
-
const X = (e) => {
|
|
189
|
-
_.current = e, typeof y == "function" ? y(e) : y && typeof y == "object" && (y.current = e);
|
|
190
|
-
};
|
|
191
|
-
if (!u)
|
|
192
|
-
return /* @__PURE__ */ s(
|
|
193
|
-
"div",
|
|
194
|
-
{
|
|
195
|
-
ref: X,
|
|
196
|
-
role: g ? "toolbar" : "group",
|
|
197
|
-
"aria-label": P,
|
|
198
|
-
"aria-orientation": g ? f ?? "horizontal" : void 0,
|
|
199
|
-
"data-component": "button-group",
|
|
200
|
-
onKeyDown: H,
|
|
201
|
-
className: ne({ orientation: f, separator: V, className: $ }),
|
|
202
|
-
...M,
|
|
203
|
-
children: me
|
|
204
|
-
}
|
|
205
|
-
);
|
|
206
|
-
const D = ne({ orientation: f, separator: V }), F = k, Y = (e, r, t) => G(e, {
|
|
207
|
-
key: e.key ?? r,
|
|
208
|
-
intent: e.props.intent ?? w,
|
|
209
|
-
background: e.props.background ?? v,
|
|
210
|
-
...l ? { size: e.props.size ?? l } : null,
|
|
211
|
-
tabIndex: -1,
|
|
212
|
-
// Same rule as the live strip: icon-only children never hideLabel.
|
|
213
|
-
...t && e.props.children && (e.props.startIcon || e.props.endIcon) ? { hideLabel: !0 } : null,
|
|
214
|
-
ref: null
|
|
215
|
-
});
|
|
216
|
-
return /* @__PURE__ */ s(
|
|
217
|
-
"div",
|
|
218
|
-
{
|
|
219
|
-
ref: X,
|
|
220
|
-
"data-component": "button-group",
|
|
221
|
-
className: [
|
|
222
|
-
"ds:relative ds:block ds:w-full ds:min-w-0 ds:overflow-x-clip",
|
|
223
|
-
$ ?? ""
|
|
224
|
-
].join(" ").trim(),
|
|
225
|
-
...M,
|
|
226
|
-
children: /* @__PURE__ */ z("div", { ref: ue, className: "ds:block ds:w-full ds:min-w-0", children: [
|
|
227
|
-
/* @__PURE__ */ s(
|
|
228
|
-
"div",
|
|
229
|
-
{
|
|
230
|
-
ref: de,
|
|
231
|
-
"aria-hidden": "true",
|
|
232
|
-
inert: !0,
|
|
233
|
-
className: `${K} ${D}`,
|
|
234
|
-
children: b.map((e, r) => Y(e, r, !1))
|
|
235
|
-
}
|
|
236
|
-
),
|
|
237
|
-
A ? /* @__PURE__ */ s(
|
|
238
|
-
"div",
|
|
239
|
-
{
|
|
240
|
-
ref: ce,
|
|
241
|
-
"aria-hidden": "true",
|
|
242
|
-
inert: !0,
|
|
243
|
-
className: `${K} ${D}`,
|
|
244
|
-
children: b.map((e, r) => Y(e, r, !0))
|
|
245
|
-
}
|
|
246
|
-
) : null,
|
|
247
|
-
/* @__PURE__ */ s(
|
|
248
|
-
"span",
|
|
249
|
-
{
|
|
250
|
-
ref: pe,
|
|
251
|
-
"aria-hidden": "true",
|
|
252
|
-
inert: !0,
|
|
253
|
-
className: K,
|
|
254
|
-
children: /* @__PURE__ */ s(
|
|
255
|
-
te,
|
|
256
|
-
{
|
|
257
|
-
icon: /* @__PURE__ */ s(oe, {}),
|
|
258
|
-
intent: w,
|
|
259
|
-
background: v,
|
|
260
|
-
size: l,
|
|
261
|
-
"aria-label": U,
|
|
262
|
-
tabIndex: -1
|
|
263
|
-
}
|
|
264
|
-
)
|
|
265
|
-
}
|
|
266
|
-
),
|
|
267
|
-
/* @__PURE__ */ z(
|
|
268
|
-
"div",
|
|
269
|
-
{
|
|
270
|
-
role: g ? "toolbar" : "group",
|
|
271
|
-
"aria-label": P,
|
|
272
|
-
"aria-orientation": g ? "horizontal" : void 0,
|
|
273
|
-
onKeyDown: H,
|
|
274
|
-
className: `${D} ds:max-w-full ds:align-top`,
|
|
275
|
-
children: [
|
|
276
|
-
J,
|
|
277
|
-
I ? /* @__PURE__ */ z(C.Root, { children: [
|
|
278
|
-
/* @__PURE__ */ s(C.Trigger, { asChild: !0, children: /* @__PURE__ */ s(
|
|
279
|
-
te,
|
|
280
|
-
{
|
|
281
|
-
icon: /* @__PURE__ */ s(oe, {}),
|
|
282
|
-
intent: w,
|
|
283
|
-
background: v,
|
|
284
|
-
size: l,
|
|
285
|
-
"aria-label": U,
|
|
286
|
-
ref: (e) => {
|
|
287
|
-
W.current = e, m.current[F] = e;
|
|
288
|
-
},
|
|
289
|
-
tabIndex: d ? c === F ? 0 : -1 : void 0,
|
|
290
|
-
onFocus: d ? () => h(F) : void 0
|
|
291
|
-
}
|
|
292
|
-
) }),
|
|
293
|
-
/* @__PURE__ */ s(C.Content, { align: "end", children: Q })
|
|
294
|
-
] }) : null
|
|
295
|
-
]
|
|
296
|
-
}
|
|
297
|
-
)
|
|
298
|
-
] })
|
|
299
|
-
}
|
|
300
|
-
);
|
|
301
|
-
}
|
|
302
|
-
);
|
|
303
|
-
Ie.displayName = "ButtonGroup";
|
|
304
|
-
export {
|
|
305
|
-
Ie as B
|
|
306
|
-
};
|
|
307
|
-
//# sourceMappingURL=button-group-R32U7SyV.js.map
|