@hachej/boring-workspace 0.1.61 → 0.1.63
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/{FileTree-zGmxifl_.js → FileTree-CUvn5K86.js} +1 -1
- package/dist/{MarkdownEditor-BykEKKxv.js → MarkdownEditor-5f4lhBqc.js} +11 -11
- package/dist/{WorkspaceLoadingState-Dfnk7JjR.js → WorkspaceLoadingState-y087Q6ek.js} +40 -40
- package/dist/{WorkspaceProvider-kf-pjz6V.js → WorkspaceProvider-U4izhS84.js} +3568 -3438
- package/dist/app-front.d.ts +10 -4
- package/dist/app-front.js +149 -148
- package/dist/app-server.d.ts +14 -4
- package/dist/app-server.js +80 -43
- package/dist/events.d.ts +9 -0
- package/dist/filesystem-vhLA0ERd.d.ts +17 -0
- package/dist/plugin.d.ts +4 -3
- package/dist/{runtimeEnv-XVFZ1OkV.d.ts → runtimeEnv-HolIkcoB.d.ts} +2 -2
- package/dist/server.d.ts +6 -4
- package/dist/server.js +44 -23
- package/dist/shared.d.ts +3 -2
- package/dist/shared.js +35 -1
- package/dist/{surface-CDklwi48.d.ts → surface-aLQ_Hryw.d.ts} +2 -0
- package/dist/testing.d.ts +4 -0
- package/dist/testing.js +1 -1
- package/dist/{ui-bridge-BbuUZ5iC.d.ts → ui-bridge-D2eO3epD.d.ts} +4 -0
- package/dist/workspace.css +2 -0
- package/dist/workspace.d.ts +77 -17
- package/dist/workspace.js +74 -73
- package/docs/README.md +29 -0
- package/package.json +4 -4
|
@@ -2,7 +2,7 @@ import { jsx as d, jsxs as y } from "react/jsx-runtime";
|
|
|
2
2
|
import { useRef as C, useMemo as I, useEffect as M, useCallback as k, createContext as E, useContext as J } from "react";
|
|
3
3
|
import { Tree as K } from "react-arborist";
|
|
4
4
|
import { FolderOpenIcon as U, FolderIcon as V, ChevronRightIcon as X, Loader2Icon as Y } from "lucide-react";
|
|
5
|
-
import { a2 as Z } from "./WorkspaceProvider-
|
|
5
|
+
import { a2 as Z } from "./WorkspaceProvider-U4izhS84.js";
|
|
6
6
|
import { EmptyState as G, Input as H } from "@hachej/boring-ui-kit";
|
|
7
7
|
import { c as g } from "./utils-B6yFEsav.js";
|
|
8
8
|
import { createDragDropManager as Q } from "dnd-core";
|
|
@@ -15,7 +15,7 @@ import { TableHeader as mt } from "@tiptap/extension-table-header";
|
|
|
15
15
|
import { TableCell as ht } from "@tiptap/extension-table-cell";
|
|
16
16
|
import wt from "@tiptap/extension-image";
|
|
17
17
|
import { c as B } from "./utils-B6yFEsav.js";
|
|
18
|
-
import { ac as V,
|
|
18
|
+
import { ac as V, aG as X, p as kt } from "./WorkspaceProvider-U4izhS84.js";
|
|
19
19
|
import { uploadFile as bt } from "@hachej/boring-agent/front";
|
|
20
20
|
import vt from "@tiptap/extension-code-block-lowlight";
|
|
21
21
|
import { createLowlight as It, common as xt } from "lowlight";
|
|
@@ -129,10 +129,10 @@ const Q = wt.extend({
|
|
|
129
129
|
};
|
|
130
130
|
},
|
|
131
131
|
addNodeView() {
|
|
132
|
-
return et(
|
|
132
|
+
return et(Gt);
|
|
133
133
|
}
|
|
134
134
|
});
|
|
135
|
-
function
|
|
135
|
+
function Gt({ node: t, updateAttributes: e, selected: r, extension: o }) {
|
|
136
136
|
const l = L(null), s = L(null), [c, a] = j(!1), m = t.attrs.src ?? "", x = (o.options.resolveSrc ?? ((h) => h))(m), A = t.attrs.alt ?? "", i = t.attrs.title ?? void 0, g = t.attrs.width, k = t.attrs.align ?? "left";
|
|
137
137
|
z(() => {
|
|
138
138
|
if (!c) return;
|
|
@@ -193,7 +193,7 @@ function Zt({ node: t, updateAttributes: e, selected: r, extension: o }) {
|
|
|
193
193
|
}
|
|
194
194
|
);
|
|
195
195
|
}
|
|
196
|
-
const
|
|
196
|
+
const Zt = It(xt), Jt = [
|
|
197
197
|
/<script[\s>][\s\S]*?<\/script>/gi,
|
|
198
198
|
/<iframe[\s>][\s\S]*?<\/iframe>/gi,
|
|
199
199
|
/\s+on\w+\s*=\s*["'][^"']*["']/gi,
|
|
@@ -234,7 +234,7 @@ function ae(t, e, r, o) {
|
|
|
234
234
|
function oe(t) {
|
|
235
235
|
return /^(?:[a-z][a-z0-9+.-]*:|\/\/|\/|#|\?)/i.test(t);
|
|
236
236
|
}
|
|
237
|
-
function
|
|
237
|
+
function G(t, e) {
|
|
238
238
|
const r = t.trim();
|
|
239
239
|
if (!r || oe(r)) return null;
|
|
240
240
|
const o = r.split(/[?#]/, 1)[0];
|
|
@@ -266,7 +266,7 @@ const le = [
|
|
|
266
266
|
autolink: !0,
|
|
267
267
|
linkOnPaste: !0,
|
|
268
268
|
defaultProtocol: "https",
|
|
269
|
-
isAllowedUri: (t, e) => W(t) && (
|
|
269
|
+
isAllowedUri: (t, e) => W(t) && (G(t) !== null || e.defaultValidate(t)),
|
|
270
270
|
HTMLAttributes: { rel: "noopener noreferrer nofollow", target: "_blank" }
|
|
271
271
|
}),
|
|
272
272
|
O.configure({
|
|
@@ -288,7 +288,7 @@ const le = [
|
|
|
288
288
|
inline: !1,
|
|
289
289
|
allowBase64: !0
|
|
290
290
|
}),
|
|
291
|
-
vt.configure({ lowlight:
|
|
291
|
+
vt.configure({ lowlight: Zt }),
|
|
292
292
|
yt.configure({
|
|
293
293
|
markedOptions: {
|
|
294
294
|
gfm: !0,
|
|
@@ -535,11 +535,11 @@ function Be({
|
|
|
535
535
|
var d;
|
|
536
536
|
!w || w.isDestroyed || t === h.current || (((d = w.getMarkdown) == null ? void 0 : d.call(w)) ?? w.getHTML()) === t || (k.current = !0, w.commands.setContent(H, { contentType: S }), k.current = !1, h.current = t);
|
|
537
537
|
}, [w, t]);
|
|
538
|
-
const
|
|
538
|
+
const Z = (u) => {
|
|
539
539
|
if (!se(u.nativeEvent)) return;
|
|
540
540
|
const d = u.target instanceof Element ? u.target.closest("a[href]") : null, p = d == null ? void 0 : d.getAttribute("href");
|
|
541
541
|
if (!p) return;
|
|
542
|
-
const y =
|
|
542
|
+
const y = G(p, s);
|
|
543
543
|
y && (u.preventDefault(), u.stopPropagation(), kt({ kind: "openFile", params: { path: y } }));
|
|
544
544
|
};
|
|
545
545
|
return /* @__PURE__ */ E(
|
|
@@ -566,7 +566,7 @@ function Be({
|
|
|
566
566
|
uploading: C
|
|
567
567
|
}
|
|
568
568
|
),
|
|
569
|
-
/* @__PURE__ */ n("div", { className: "min-h-0 flex-1 overflow-auto", onClickCapture:
|
|
569
|
+
/* @__PURE__ */ n("div", { className: "min-h-0 flex-1 overflow-auto", onClickCapture: Z, children: x && !r ? /* @__PURE__ */ n(
|
|
570
570
|
"textarea",
|
|
571
571
|
{
|
|
572
572
|
"aria-label": "Raw markdown",
|
|
@@ -594,5 +594,5 @@ export {
|
|
|
594
594
|
ae as rawFileUrlForMarkdownImage,
|
|
595
595
|
ce as readFileAsDataUrl,
|
|
596
596
|
Yt as sanitizeHtml,
|
|
597
|
-
|
|
597
|
+
G as workspaceFilePathForMarkdownLink
|
|
598
598
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { jsx as a, jsxs as h, Fragment as Pe } from "react/jsx-runtime";
|
|
2
2
|
import { useState as j, useMemo as R, useCallback as k, useRef as H, useEffect as y, useSyncExternalStore as _e, Suspense as Ne } from "react";
|
|
3
|
-
import { IconButton as te, LoadingState as We, ResizeHandle as Oe, Button as
|
|
4
|
-
import { Minimize2 as Re, Maximize2 as Be, PanelRightClose as
|
|
3
|
+
import { IconButton as te, LoadingState as We, ResizeHandle as Oe, Button as ze, Kbd as Ie } from "@hachej/boring-ui-kit";
|
|
4
|
+
import { Minimize2 as Re, Maximize2 as Be, PanelRightClose as Me, PanelRightOpen as Ae, MessageSquare as Le, Search as De, Plus as Ee } from "lucide-react";
|
|
5
5
|
import { c as b } from "./utils-B6yFEsav.js";
|
|
6
|
-
import {
|
|
6
|
+
import { b4 as pe, az as Te, aJ as Ke, ag as He, ar as je, Z as Fe, aM as ge, b0 as Ve, al as $e, b5 as qe, u as Ue, aC as Xe } from "./WorkspaceProvider-U4izhS84.js";
|
|
7
7
|
function lt(e, t, r = !0) {
|
|
8
8
|
if (!r || typeof window > "u") return t;
|
|
9
9
|
try {
|
|
@@ -39,7 +39,7 @@ function Ze(e, t, r = !0) {
|
|
|
39
39
|
} catch {
|
|
40
40
|
}
|
|
41
41
|
}
|
|
42
|
-
const
|
|
42
|
+
const Je = "pointer-events-auto relative border border-border/70 bg-muted text-muted-foreground transition-colors hover:bg-foreground/[0.06] hover:text-foreground", Ye = "border-border bg-foreground/[0.09] text-foreground";
|
|
43
43
|
function be({
|
|
44
44
|
label: e,
|
|
45
45
|
hint: t,
|
|
@@ -60,8 +60,8 @@ function be({
|
|
|
60
60
|
"aria-pressed": l,
|
|
61
61
|
title: e,
|
|
62
62
|
className: b(
|
|
63
|
-
|
|
64
|
-
l &&
|
|
63
|
+
Je,
|
|
64
|
+
l && Ye
|
|
65
65
|
),
|
|
66
66
|
children: [
|
|
67
67
|
d,
|
|
@@ -122,16 +122,16 @@ function ut(e = {}) {
|
|
|
122
122
|
}
|
|
123
123
|
function ht(e) {
|
|
124
124
|
var ue, he;
|
|
125
|
-
const t = e.nav !== null, r = e.surface !== void 0, n = !!e.surface, l = e.nav || "session-list", s = e.center ?? "chat", d = e.surface || "artifact-surface", i = Qe(), [f, w] =
|
|
125
|
+
const t = e.nav !== null, r = e.surface !== void 0, n = !!e.surface, l = e.nav || "session-list", s = e.center ?? "chat", d = e.surface || "artifact-surface", i = Qe(), [f, w] = G(
|
|
126
126
|
e.storageKey ? `${e.storageKey}:drawerWidth` : void 0,
|
|
127
127
|
260
|
|
128
|
-
), [ne, xe] =
|
|
128
|
+
), [ne, xe] = G(
|
|
129
129
|
e.storageKey ? `${e.storageKey}:surfaceWidth` : void 0,
|
|
130
130
|
680
|
|
131
|
-
), [ye, ke] =
|
|
131
|
+
), [ye, ke] = G(
|
|
132
132
|
e.storageKey ? `${e.storageKey}:sidebarWidth` : void 0,
|
|
133
133
|
280
|
|
134
|
-
), [c, m] =
|
|
134
|
+
), [c, m] = Ge(
|
|
135
135
|
e.storageKey ? `${e.storageKey}:chatCollapsed` : void 0,
|
|
136
136
|
!1
|
|
137
137
|
), [Ce, B] = j(!1), { blockers: W } = Te(), C = e.activeChatPaneId ?? ((ue = e.centerParams) == null ? void 0 : ue.sessionId), ae = R(
|
|
@@ -140,14 +140,14 @@ function ht(e) {
|
|
|
140
140
|
), Se = R(
|
|
141
141
|
() => W.some((o) => !!o.sessionId && !!Ke(o)),
|
|
142
142
|
[W]
|
|
143
|
-
), v = He(), F = _(f, 200, 360), V = _(ye, 200, Math.max(240, Math.floor(i * 0.5))), re = Math.max(480, Math.floor(i * 0.72)), $ = _(ne, 480, re), q = N(e.centerParams, "getSurface"), U = N(e.centerParams, "isWorkbenchOpen"), X = N(e.centerParams, "openWorkbench"), oe = N(e.centerParams, "openWorkbenchSources"), ie = N(e.centerParams, "closeWorkbench"), se = et(e.centerParams, "surfaceDispatch"), p = K(e.navParams, "onClose"), x = K(e.surfaceParams, "onClose"), P = K(e.sidebarParams, "onClose"), Z = K(e.navParams, "onCreate"),
|
|
143
|
+
), v = He(), F = _(f, 200, 360), V = _(ye, 200, Math.max(240, Math.floor(i * 0.5))), re = Math.max(480, Math.floor(i * 0.72)), $ = _(ne, 480, re), q = N(e.centerParams, "getSurface"), U = N(e.centerParams, "isWorkbenchOpen"), X = N(e.centerParams, "openWorkbench"), oe = N(e.centerParams, "openWorkbenchSources"), ie = N(e.centerParams, "closeWorkbench"), se = et(e.centerParams, "surfaceDispatch"), p = K(e.navParams, "onClose"), x = K(e.surfaceParams, "onClose"), P = K(e.sidebarParams, "onClose"), Z = K(e.navParams, "onCreate"), M = ((he = e.chatPanes) == null ? void 0 : he.filter((o) => o.id.length > 0)) ?? [], ce = M.length > 0, g = !!e.sidebar, A = t ? !!p : !!e.onOpenNav, O = n ? !!x : !!e.onOpenSurface, L = g ? !!P : !!e.onOpenSidebar, D = k(() => {
|
|
144
144
|
var o;
|
|
145
145
|
if (t) {
|
|
146
146
|
p == null || p();
|
|
147
147
|
return;
|
|
148
148
|
}
|
|
149
149
|
(o = e.onOpenNav) == null || o.call(e);
|
|
150
|
-
}, [p, t, e.onOpenNav]),
|
|
150
|
+
}, [p, t, e.onOpenNav]), z = k(() => {
|
|
151
151
|
var o;
|
|
152
152
|
if (n) {
|
|
153
153
|
x == null || x();
|
|
@@ -163,8 +163,8 @@ function ht(e) {
|
|
|
163
163
|
(o = e.onOpenSidebar) == null || o.call(e);
|
|
164
164
|
}, [P, e.onOpenSidebar, g]), T = k(() => {
|
|
165
165
|
c && m(!1), t && (p == null || p()), n && (x == null || x()), ee(), we();
|
|
166
|
-
}, [c, p, x, t, m, n]),
|
|
167
|
-
!c && e.chatOverlay && (
|
|
166
|
+
}, [c, p, x, t, m, n]), J = H(!1), Y = k(() => {
|
|
167
|
+
!c && e.chatOverlay && (J.current = !0), m((u) => {
|
|
168
168
|
var fe;
|
|
169
169
|
const S = !u;
|
|
170
170
|
return S && !n && ((fe = e.onOpenSurface) == null || fe.call(e)), S;
|
|
@@ -173,8 +173,8 @@ function ht(e) {
|
|
|
173
173
|
je({
|
|
174
174
|
shortcuts: R(() => {
|
|
175
175
|
const o = [];
|
|
176
|
-
return
|
|
177
|
-
}, [
|
|
176
|
+
return A && o.push({ key: "1", mod: !0, handler: D }), O && o.push({ key: "2", mod: !0, handler: z }), L && o.push({ key: "3", mod: !0, allowInEditable: !0, handler: E }), s === "chat" && (o.push({ key: "Escape", allowInEditable: !0, handler: T }), o.push({ key: "\\", mod: !0, allowInEditable: !0, handler: Y })), o;
|
|
177
|
+
}, [A, L, O, s, T, Y, D, E, z])
|
|
178
178
|
}), y(() => {
|
|
179
179
|
const o = "workspace:chat-layout", u = "agent:chat-layout";
|
|
180
180
|
return v.unregisterByPluginId(o), v.unregisterByPluginId(u), v.registerCommand({
|
|
@@ -183,7 +183,7 @@ function ht(e) {
|
|
|
183
183
|
keywords: ["sessions", "history", "drawer", t ? "close" : "open"],
|
|
184
184
|
shortcut: "⌘1",
|
|
185
185
|
pluginId: o,
|
|
186
|
-
when: () =>
|
|
186
|
+
when: () => A,
|
|
187
187
|
run: D
|
|
188
188
|
}), v.registerCommand({
|
|
189
189
|
id: "workspace:open-workbench",
|
|
@@ -192,14 +192,14 @@ function ht(e) {
|
|
|
192
192
|
shortcut: "⌘2",
|
|
193
193
|
pluginId: o,
|
|
194
194
|
when: () => O,
|
|
195
|
-
run:
|
|
195
|
+
run: z
|
|
196
196
|
}), v.registerCommand({
|
|
197
197
|
id: "workspace:toggle-workbench-left-panel",
|
|
198
198
|
title: g ? "Close Workbench Left Panel" : "Open Workbench Left Panel",
|
|
199
199
|
keywords: ["left", "sidebar", "tabs", "workbench", g ? "close" : "open"],
|
|
200
200
|
shortcut: "⌘3",
|
|
201
201
|
pluginId: o,
|
|
202
|
-
when: () =>
|
|
202
|
+
when: () => L,
|
|
203
203
|
run: E
|
|
204
204
|
}), s === "chat" && v.registerCommand({
|
|
205
205
|
id: "agent:focus-chat",
|
|
@@ -227,9 +227,9 @@ function ht(e) {
|
|
|
227
227
|
e.onOpenNav,
|
|
228
228
|
e.onOpenSurface,
|
|
229
229
|
e.onOpenSidebar,
|
|
230
|
-
M,
|
|
231
|
-
O,
|
|
232
230
|
A,
|
|
231
|
+
O,
|
|
232
|
+
L,
|
|
233
233
|
p,
|
|
234
234
|
x,
|
|
235
235
|
P,
|
|
@@ -237,7 +237,7 @@ function ht(e) {
|
|
|
237
237
|
T,
|
|
238
238
|
g,
|
|
239
239
|
D,
|
|
240
|
-
|
|
240
|
+
z,
|
|
241
241
|
E
|
|
242
242
|
]), y(() => {
|
|
243
243
|
const o = se ?? (q && U && X ? {
|
|
@@ -276,8 +276,8 @@ function ht(e) {
|
|
|
276
276
|
!n || c || e.chatOverlay || i < 1180 && m(!0);
|
|
277
277
|
}, [c, e.chatOverlay, m, n, i]), y(() => {
|
|
278
278
|
if (!(!e.chatOverlay || !c)) {
|
|
279
|
-
if (
|
|
280
|
-
|
|
279
|
+
if (J.current) {
|
|
280
|
+
J.current = !1;
|
|
281
281
|
return;
|
|
282
282
|
}
|
|
283
283
|
m(!1);
|
|
@@ -321,7 +321,7 @@ function ht(e) {
|
|
|
321
321
|
"transition-opacity duration-[200ms] ease-[cubic-bezier(0.22,1,0.36,1)]",
|
|
322
322
|
t ? "opacity-100" : "invisible pointer-events-none opacity-0"
|
|
323
323
|
),
|
|
324
|
-
children: /* @__PURE__ */ a(
|
|
324
|
+
children: /* @__PURE__ */ a(I, { id: l, params: e.navParams })
|
|
325
325
|
}
|
|
326
326
|
),
|
|
327
327
|
t ? /* @__PURE__ */ a(
|
|
@@ -362,7 +362,7 @@ function ht(e) {
|
|
|
362
362
|
"transition-opacity duration-[200ms] ease-[cubic-bezier(0.22,1,0.36,1)]",
|
|
363
363
|
g ? "opacity-100" : "opacity-0"
|
|
364
364
|
),
|
|
365
|
-
children: g ? /* @__PURE__ */ a(
|
|
365
|
+
children: g ? /* @__PURE__ */ a(I, { id: e.sidebar ?? "workbench-left", params: e.sidebarParams }) : null
|
|
366
366
|
}
|
|
367
367
|
),
|
|
368
368
|
g ? /* @__PURE__ */ a(
|
|
@@ -403,7 +403,7 @@ function ht(e) {
|
|
|
403
403
|
children: ce ? /* @__PURE__ */ a(
|
|
404
404
|
qe,
|
|
405
405
|
{
|
|
406
|
-
panes:
|
|
406
|
+
panes: M,
|
|
407
407
|
activePaneId: e.activeChatPaneId,
|
|
408
408
|
onActivePaneChange: e.onActiveChatPaneChange,
|
|
409
409
|
onClosePane: e.onCloseChatPane,
|
|
@@ -411,14 +411,14 @@ function ht(e) {
|
|
|
411
411
|
storageKey: e.storageKey,
|
|
412
412
|
onDropSession: e.onDropChatSession,
|
|
413
413
|
renderPane: (o) => /* @__PURE__ */ a(
|
|
414
|
-
|
|
414
|
+
I,
|
|
415
415
|
{
|
|
416
416
|
id: o.panel ?? s,
|
|
417
417
|
params: o.params ?? e.centerParams
|
|
418
418
|
}
|
|
419
419
|
)
|
|
420
420
|
}
|
|
421
|
-
) : /* @__PURE__ */ a(
|
|
421
|
+
) : /* @__PURE__ */ a(I, { id: s, params: e.centerParams })
|
|
422
422
|
}
|
|
423
423
|
),
|
|
424
424
|
e.chatOverlay ? /* @__PURE__ */ a(
|
|
@@ -463,7 +463,7 @@ function ht(e) {
|
|
|
463
463
|
"transition-[opacity,padding] duration-[200ms] ease-[cubic-bezier(0.22,1,0.36,1)]",
|
|
464
464
|
n ? "opacity-100" : "opacity-0"
|
|
465
465
|
),
|
|
466
|
-
children: e.surfaceOverlay ? /* @__PURE__ */ a("div", { className: "relative h-full min-h-0", children: e.surfaceOverlay }) : /* @__PURE__ */ a(
|
|
466
|
+
children: e.surfaceOverlay ? /* @__PURE__ */ a("div", { className: "relative h-full min-h-0", children: e.surfaceOverlay }) : /* @__PURE__ */ a(I, { id: d, params: e.surfaceParams })
|
|
467
467
|
}
|
|
468
468
|
),
|
|
469
469
|
n && !c ? /* @__PURE__ */ a(
|
|
@@ -483,10 +483,10 @@ function ht(e) {
|
|
|
483
483
|
{
|
|
484
484
|
surfaceOpen: n,
|
|
485
485
|
canToggleSurface: O,
|
|
486
|
-
onToggleSurface:
|
|
486
|
+
onToggleSurface: z,
|
|
487
487
|
chatCollapsed: c,
|
|
488
488
|
canToggleChat: s === "chat" && (!r || n && !c),
|
|
489
|
-
onToggleChat:
|
|
489
|
+
onToggleChat: Y,
|
|
490
490
|
chatPulse: Ce || W.length > 0,
|
|
491
491
|
surfaceConfigured: r
|
|
492
492
|
}
|
|
@@ -509,7 +509,7 @@ function ht(e) {
|
|
|
509
509
|
icon: "plus",
|
|
510
510
|
onClick: () => {
|
|
511
511
|
var u, S;
|
|
512
|
-
const o = e.activeChatPaneId ?? ((u =
|
|
512
|
+
const o = e.activeChatPaneId ?? ((u = M[M.length - 1]) == null ? void 0 : u.id);
|
|
513
513
|
o && ((S = e.onCreateChatPaneAfter) == null || S.call(e, o));
|
|
514
514
|
},
|
|
515
515
|
label: "New chat",
|
|
@@ -523,7 +523,7 @@ function ht(e) {
|
|
|
523
523
|
function _(e, t, r) {
|
|
524
524
|
return Math.max(t, Math.min(r, e));
|
|
525
525
|
}
|
|
526
|
-
function
|
|
526
|
+
function G(e, t) {
|
|
527
527
|
const [r, n] = j(
|
|
528
528
|
() => e ? me(e, t) : t
|
|
529
529
|
);
|
|
@@ -541,7 +541,7 @@ function J(e, t) {
|
|
|
541
541
|
);
|
|
542
542
|
return [r, l];
|
|
543
543
|
}
|
|
544
|
-
function
|
|
544
|
+
function Ge(e, t) {
|
|
545
545
|
const [r, n] = j(() => !e || typeof window > "u" ? t : window.localStorage.getItem(e) === "1");
|
|
546
546
|
y(() => {
|
|
547
547
|
if (!e || typeof window > "u") {
|
|
@@ -624,7 +624,7 @@ function we() {
|
|
|
624
624
|
ee(), window.setTimeout(ee, 320);
|
|
625
625
|
});
|
|
626
626
|
}
|
|
627
|
-
function
|
|
627
|
+
function I({ id: e, params: t }) {
|
|
628
628
|
const r = Ue(), { debug: n } = Xe(), l = _e(
|
|
629
629
|
r.subscribe,
|
|
630
630
|
r.getSnapshot,
|
|
@@ -705,7 +705,7 @@ function nt({
|
|
|
705
705
|
hint: "⌘2",
|
|
706
706
|
onClick: r,
|
|
707
707
|
pressed: e,
|
|
708
|
-
children: e ? /* @__PURE__ */ a(
|
|
708
|
+
children: e ? /* @__PURE__ */ a(Me, { className: "size-3", strokeWidth: 1.75 }) : /* @__PURE__ */ a(Ae, { className: "size-3", strokeWidth: 1.75 })
|
|
709
709
|
}
|
|
710
710
|
) : null
|
|
711
711
|
] });
|
|
@@ -745,7 +745,7 @@ function ve({
|
|
|
745
745
|
] }),
|
|
746
746
|
i ? /* @__PURE__ */ a("span", { className: "absolute -right-1.5 -top-1.5 h-2 w-2 rounded-full bg-[color:var(--accent)]", "aria-hidden": "true", "data-boring-workspace-part": "edge-attention-dot" }) : null
|
|
747
747
|
] }) : t === "chat" ? /* @__PURE__ */ h("span", { className: "relative flex items-center justify-center", children: [
|
|
748
|
-
/* @__PURE__ */ a(
|
|
748
|
+
/* @__PURE__ */ a(Le, { className: "h-[15px] w-[15px]", strokeWidth: 1.8, "aria-hidden": "true" }),
|
|
749
749
|
i ? /* @__PURE__ */ a("span", { className: "absolute -right-1.5 -top-1.5 h-2 w-2 rounded-full bg-[color:var(--accent)]", "aria-hidden": "true" }) : null
|
|
750
750
|
] }) : t === "plus" ? /* @__PURE__ */ a("svg", { width: "15", height: "15", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ a("path", { d: "M12 5v14M5 12h14", stroke: "currentColor", strokeWidth: "1.8", strokeLinecap: "round" }) }) : /* @__PURE__ */ a("svg", { width: "15", height: "15", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ a("path", { d: "M3 7.5 A1.5 1.5 0 0 1 4.5 6 h4 l2 2 h9 A1.5 1.5 0 0 1 21 9.5 V17.5 A1.5 1.5 0 0 1 19.5 19 H4.5 A1.5 1.5 0 0 1 3 17.5 Z", stroke: "currentColor", strokeWidth: "1.8", strokeLinejoin: "round" }) })
|
|
751
751
|
}
|
|
@@ -784,7 +784,7 @@ function ft({
|
|
|
784
784
|
/* @__PURE__ */ a("span", { className: "truncate text-[13px] font-medium leading-none tracking-tight text-foreground", children: f })
|
|
785
785
|
] }) }),
|
|
786
786
|
/* @__PURE__ */ h(
|
|
787
|
-
|
|
787
|
+
ze,
|
|
788
788
|
{
|
|
789
789
|
type: "button",
|
|
790
790
|
variant: "ghost",
|
|
@@ -796,7 +796,7 @@ function ft({
|
|
|
796
796
|
children: [
|
|
797
797
|
/* @__PURE__ */ a(De, { className: "h-3.5 w-3.5 shrink-0 opacity-80", strokeWidth: 1.75 }),
|
|
798
798
|
/* @__PURE__ */ a("span", { className: "font-normal tracking-tight", children: "Search" }),
|
|
799
|
-
/* @__PURE__ */ a(
|
|
799
|
+
/* @__PURE__ */ a(Ie, { className: "ml-0.5 bg-muted/40 leading-none shadow-none", children: "⌘K" })
|
|
800
800
|
]
|
|
801
801
|
}
|
|
802
802
|
),
|