@levo-so/studio 0.3.9 → 0.3.10
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/{KBChatWidget-Cgsubvuk.js → KBChatWidget-ChIYlltB.js} +388 -382
- package/index.js +1 -1
- package/{kbChat-QDHdRejh.js → kbChat-BLHDnA-T.js} +15 -15
- package/package.json +4 -4
- package/pillChrome-wmdnlFIE.js +50 -0
- package/studio.css +1 -1
- package/pillChrome-CYoMtUAv.js +0 -30
package/pillChrome-CYoMtUAv.js
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
//#region ../../libraries/ai-chat/src/helpers.ts
|
|
2
|
-
var e = (e, t = {
|
|
3
|
-
hour: "numeric",
|
|
4
|
-
minute: "2-digit"
|
|
5
|
-
}) => {
|
|
6
|
-
if (!e) return "";
|
|
7
|
-
let n = e instanceof Date ? e : new Date(e);
|
|
8
|
-
return Number.isNaN(n.getTime()) ? "" : n.toLocaleTimeString([], t);
|
|
9
|
-
}, t = (e, t) => t ? `levo.site_chat.${e}.${t}` : null, n = (e, t) => {
|
|
10
|
-
e.style.height = "auto", e.style.height = t === void 0 ? `${e.scrollHeight}px` : `${Math.min(e.scrollHeight, t)}px`;
|
|
11
|
-
}, r = (e, t) => {
|
|
12
|
-
e.setText(t);
|
|
13
|
-
let n = document.activeElement?.closest("[data-ai-chat-root]") ?? document;
|
|
14
|
-
requestAnimationFrame(() => {
|
|
15
|
-
let e = n.querySelector("textarea[data-ai-chat-composer]");
|
|
16
|
-
if (!e) return;
|
|
17
|
-
e.focus();
|
|
18
|
-
let t = e.value.length;
|
|
19
|
-
e.setSelectionRange(t, t);
|
|
20
|
-
});
|
|
21
|
-
}, i = "w-72", a = "ai-chat-pill-gradient relative rounded-[30px] p-[2px] transition-shadow duration-300", o = "shadow-lg shadow-zinc-950/10", s = "shadow-md", c = "ai-chat-pill-surface min-h-14 w-full rounded-[28px] bg-white p-1.5", l = "ai-chat-pill-surface--stacked", u = "ai-chat-pill-input relative min-w-0", d = "ai-chat-pill-actions flex items-center gap-1.5", f = "ai-chat-pill-spark flex h-11 w-11 flex-shrink-0 items-center justify-center rounded-full text-blue-500 transition-[background-color,transform] duration-150 hover:bg-zinc-50 active:scale-95", p = "flex h-11 w-11 flex-shrink-0 items-center justify-center rounded-full shadow-sm transition-[transform,box-shadow] duration-150 hover:scale-105 hover:shadow-md active:scale-95", m = "block h-6 max-h-[120px] w-full resize-none overflow-y-auto bg-transparent text-base text-zinc-900 leading-6 placeholder:text-zinc-400 focus:outline-none", h = 24, g = (e, t) => {
|
|
22
|
-
e.classList.remove(l), t.style.height = "auto";
|
|
23
|
-
let r = t.scrollHeight > h + 4;
|
|
24
|
-
return e.classList.toggle(l, r), n(t, 120), r;
|
|
25
|
-
}, _ = "ai-chat-pill-label pointer-events-none absolute inset-y-0 left-0 flex max-w-full items-center truncate bg-clip-text font-semibold text-[15px] text-transparent", v = {
|
|
26
|
-
backgroundColor: "var(--color-brand, #0a0a0a)",
|
|
27
|
-
color: "var(--color-brand-foreground, #fff)"
|
|
28
|
-
}, y = (e) => e ? `Ask ${e}` : "Ask AI";
|
|
29
|
-
//#endregion
|
|
30
|
-
export { r as _, p as a, o as c, l as d, m as f, n as g, y as h, _ as i, f as l, g as m, a as n, v as o, i as p, u as r, s, d as t, c as u, e as v, t as y };
|