@burdenoff/fe-libs 2026.1030.2 → 2026.1030.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.
|
@@ -18,6 +18,7 @@ var s = ({ open: s, onKeep: c, onDiscard: l }) => {
|
|
|
18
18
|
title: u("closeConfirm.title", "Discard your unsent message?"),
|
|
19
19
|
description: u("closeConfirm.body", "What you typed or attached has not been sent. If you close the assistant now, it is discarded."),
|
|
20
20
|
ariaModal: !0,
|
|
21
|
+
omitBody: !0,
|
|
21
22
|
footer: /* @__PURE__ */ o(i, { children: [/* @__PURE__ */ a(e, {
|
|
22
23
|
ref: d,
|
|
23
24
|
variant: "outline",
|
|
@@ -4,37 +4,41 @@ import { jsx as n, jsxs as r } from "react/jsx-runtime";
|
|
|
4
4
|
//#region src/shared/assistant/ui/compact/AssistantVoiceReady.tsx
|
|
5
5
|
var i = ({ blockedReason: i, onStart: a }) => {
|
|
6
6
|
let o = e();
|
|
7
|
-
return /* @__PURE__ */
|
|
8
|
-
className: "
|
|
7
|
+
return /* @__PURE__ */ n("div", {
|
|
8
|
+
className: "min-h-0 flex-1 [container-type:size]",
|
|
9
9
|
"data-testid": "assistant-window-voice-ready",
|
|
10
|
-
children:
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
"
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
className: "
|
|
34
|
-
"
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
10
|
+
children: /* @__PURE__ */ r("div", {
|
|
11
|
+
className: "flex h-full flex-col items-center [justify-content:safe_center] gap-4 overflow-y-auto px-6 py-4 text-center [@container_(min-height:13.75rem)_and_(max-height:19.25rem)]:gap-2 [@container_(max-height:19.25rem)]:px-4 [@container_(min-height:13.75rem)_and_(max-height:19.25rem)]:py-2 [@container_(max-height:13.75rem)]:gap-1 [@container_(max-height:13.75rem)]:py-1",
|
|
12
|
+
"data-testid": "assistant-window-voice-ready-content",
|
|
13
|
+
children: [
|
|
14
|
+
/* @__PURE__ */ n("span", {
|
|
15
|
+
className: "size-28 shrink-0 [@container_(max-height:19.25rem)]:size-16 [@container_(max-height:13.75rem)]:hidden rounded-full bg-gradient-to-br from-action-primary-bg/80 to-action-primary-bg/20 shadow-[var(--shadow-elevation-3)]",
|
|
16
|
+
"aria-hidden": "true",
|
|
17
|
+
"data-testid": "assistant-window-orb"
|
|
18
|
+
}),
|
|
19
|
+
/* @__PURE__ */ n("h2", {
|
|
20
|
+
className: "shrink-0 text-lg font-semibold text-text-primary [@container_(max-height:13.75rem)]:text-base",
|
|
21
|
+
children: o("window.voiceReadyTitle", "Talk to the assistant")
|
|
22
|
+
}),
|
|
23
|
+
/* @__PURE__ */ n("p", {
|
|
24
|
+
role: "status",
|
|
25
|
+
"aria-live": "polite",
|
|
26
|
+
className: "max-w-[16rem] shrink-0 text-sm text-text-secondary [@container_(max-height:13.75rem)]:max-w-full [@container_(max-height:13.75rem)]:text-xs",
|
|
27
|
+
"data-testid": "assistant-window-voice-status",
|
|
28
|
+
children: i ?? o("window.voiceReadyStatus", "The microphone starts only when you press Start voice.")
|
|
29
|
+
}),
|
|
30
|
+
i === null ? /* @__PURE__ */ r("button", {
|
|
31
|
+
type: "button",
|
|
32
|
+
onClick: a,
|
|
33
|
+
className: "flex h-12 shrink-0 items-center gap-2 rounded-full bg-action-primary-bg px-6 text-base font-medium text-action-primary-text transition-colors hover:bg-action-primary-bg-hover focus:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)] focus-visible:ring-offset-2 focus-visible:ring-offset-[var(--color-bg-elevated)]",
|
|
34
|
+
"data-testid": "assistant-window-start-voice",
|
|
35
|
+
children: [/* @__PURE__ */ n(t, {
|
|
36
|
+
className: "size-5",
|
|
37
|
+
"aria-hidden": "true"
|
|
38
|
+
}), o("window.startVoice", "Start voice")]
|
|
39
|
+
}) : null
|
|
40
|
+
]
|
|
41
|
+
})
|
|
38
42
|
});
|
|
39
43
|
};
|
|
40
44
|
//#endregion
|
package/dist/ui/modal-shell.d.ts
CHANGED
|
@@ -5,6 +5,11 @@ export interface ModalShellProps {
|
|
|
5
5
|
title: string;
|
|
6
6
|
description?: string;
|
|
7
7
|
children: ReactNode;
|
|
8
|
+
/**
|
|
9
|
+
* Omit the body slot when the description is the entire message. Opt-in:
|
|
10
|
+
* existing callers, including those with null children, keep their body.
|
|
11
|
+
*/
|
|
12
|
+
omitBody?: boolean;
|
|
8
13
|
size?: 'sm' | 'md' | 'lg' | 'xl';
|
|
9
14
|
footer?: ReactNode;
|
|
10
15
|
/**
|
|
@@ -36,4 +41,4 @@ export interface ModalShellProps {
|
|
|
36
41
|
* primitives (which already own the scrim, Escape, focus trap and scroll lock);
|
|
37
42
|
* it does not replace them.
|
|
38
43
|
*/
|
|
39
|
-
export declare function ModalShell({ open, onClose, title, description, children, size, footer, role, ariaModal, onOpenAutoFocus, testId, }: ModalShellProps): import('react/jsx-runtime').JSX.Element;
|
|
44
|
+
export declare function ModalShell({ open, onClose, title, description, children, omitBody, size, footer, role, ariaModal, onOpenAutoFocus, testId, }: ModalShellProps): import('react/jsx-runtime').JSX.Element;
|
package/dist/ui/modal-shell.js
CHANGED
|
@@ -9,32 +9,32 @@ var f = {
|
|
|
9
9
|
lg: "sm:max-w-2xl",
|
|
10
10
|
xl: "sm:max-w-3xl"
|
|
11
11
|
};
|
|
12
|
-
function p({ open: p, onClose: m, title: h, description: g, children: _,
|
|
13
|
-
let
|
|
12
|
+
function p({ open: p, onClose: m, title: h, description: g, children: _, omitBody: v = !1, size: y = "md", footer: b, role: x, ariaModal: S, onOpenAutoFocus: C, testId: w }) {
|
|
13
|
+
let T = l(null);
|
|
14
14
|
return /* @__PURE__ */ u(e, {
|
|
15
15
|
open: p,
|
|
16
16
|
onOpenChange: (e) => {
|
|
17
17
|
e || m();
|
|
18
18
|
},
|
|
19
19
|
children: /* @__PURE__ */ d(t, {
|
|
20
|
-
className: f[
|
|
21
|
-
...
|
|
22
|
-
...
|
|
23
|
-
...
|
|
20
|
+
className: f[y],
|
|
21
|
+
...x ? { role: x } : {},
|
|
22
|
+
...S ? { "aria-modal": !0 } : {},
|
|
23
|
+
...w ? { "data-testid": w } : {},
|
|
24
24
|
onOpenAutoFocus: (e) => {
|
|
25
|
-
|
|
25
|
+
T.current = s(document), C?.(e);
|
|
26
26
|
},
|
|
27
27
|
onCloseAutoFocus: (e) => {
|
|
28
|
-
let t =
|
|
29
|
-
|
|
28
|
+
let t = T.current;
|
|
29
|
+
T.current = null, o(document) && c(document, [t]) && e.preventDefault();
|
|
30
30
|
},
|
|
31
31
|
children: [
|
|
32
32
|
/* @__PURE__ */ d(i, { children: [h && /* @__PURE__ */ u(a, { children: h }), g && /* @__PURE__ */ u(n, { children: g })] }),
|
|
33
|
-
/* @__PURE__ */ u("div", {
|
|
33
|
+
!v && /* @__PURE__ */ u("div", {
|
|
34
34
|
className: "max-h-[60dvh] overflow-y-auto overscroll-contain pr-1",
|
|
35
35
|
children: _
|
|
36
36
|
}),
|
|
37
|
-
|
|
37
|
+
b && /* @__PURE__ */ u(r, { children: b })
|
|
38
38
|
]
|
|
39
39
|
})
|
|
40
40
|
});
|