@alivault/pico 0.3.2 → 0.4.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/.output/nitro.json +1 -1
- package/.output/public/assets/{index-ga3WrbUv.js → index-BiaOlsw0.js} +2 -2
- package/.output/public/assets/routes-C7eqqi44.js +2152 -0
- package/.output/public/screenshots/pico-mobile-alt.png +0 -0
- package/.output/public/screenshots/pico-mobile.png +0 -0
- package/.output/public/screenshots/pico-workspace-alt.png +0 -0
- package/.output/public/screenshots/pico-workspace.png +0 -0
- package/.output/server/_libs/@pierre/diffs+[...].mjs +53 -1
- package/.output/server/_libs/entities.mjs +372 -0
- package/.output/server/_libs/hast-util-from-parse5+[...].mjs +741 -0
- package/.output/server/_libs/hast-util-raw+[...].mjs +7897 -0
- package/.output/server/_libs/hast-util-sanitize.mjs +780 -0
- package/.output/server/_libs/hast-util-to-jsx-runtime+[...].mjs +3 -82
- package/.output/server/_libs/mdast-util-find-and-replace.mjs +198 -0
- package/.output/server/_libs/mdast-util-gfm+[...].mjs +4 -288
- package/.output/server/_libs/mdast-util-to-hast+[...].mjs +1 -2
- package/.output/server/_libs/react-markdown+[...].mjs +1 -1
- package/.output/server/_libs/rehype-raw.mjs +37 -0
- package/.output/server/_libs/rehype-sanitize.mjs +27 -0
- package/.output/server/_ssr/{router-DQcefit6.mjs → router-CgnX-Js0.mjs} +2 -2
- package/.output/server/_ssr/{routes-C7eO3ZVn.mjs → routes-CmLc8G9G.mjs} +162 -117
- package/.output/server/_ssr/{routes-DHXvlqAP.mjs → routes-D2MVUd_A.mjs} +2 -2
- package/.output/server/_ssr/ssr.mjs +2 -2
- package/.output/server/{_tanstack-start-manifest_v-ChF3TvKp.mjs → _tanstack-start-manifest_v-BSXP2b2T.mjs} +4 -4
- package/.output/server/index.mjs +495 -481
- package/README.md +6 -2
- package/package.json +3 -1
- package/public/screenshots/pico-mobile-alt.png +0 -0
- package/public/screenshots/pico-mobile.png +0 -0
- package/public/screenshots/pico-workspace-alt.png +0 -0
- package/public/screenshots/pico-workspace.png +0 -0
- package/.output/public/assets/routes-BApV813x.js +0 -2151
- package/.output/server/_libs/mdast-util-find-and-replace+[...].mjs +0 -636
|
@@ -2,7 +2,7 @@ import { i as __toESM } from "../_runtime.mjs";
|
|
|
2
2
|
import { X as require_react, Y as require_jsx_runtime } from "../_libs/@base-ui/react+[...].mjs";
|
|
3
3
|
import { a as createRouter, c as createRootRoute, n as Scripts, r as HeadContent, s as createFileRoute } from "../_libs/@tanstack/react-router+[...].mjs";
|
|
4
4
|
import { h as OctagonX, i as TriangleAlert, k as CircleCheck, v as Info } from "../_libs/lucide-react.mjs";
|
|
5
|
-
import { A as createCompactionSummaryItem, D as assistantBlocksFromMessage, F as extractToolText, N as extractMessageImages, O as buildItemsFromSync, P as extractMessageText$1, R as mergeAssistantBlocksForStreaming, b as THEME_STORAGE_KEY, h as Route$46, lt as toolCategoryFromTool, w as TooltipProvider, y as Spinner } from "./routes-
|
|
5
|
+
import { A as createCompactionSummaryItem, D as assistantBlocksFromMessage, F as extractToolText, N as extractMessageImages, O as buildItemsFromSync, P as extractMessageText$1, R as mergeAssistantBlocksForStreaming, b as THEME_STORAGE_KEY, h as Route$46, lt as toolCategoryFromTool, w as TooltipProvider, y as Spinner } from "./routes-D2MVUd_A.mjs";
|
|
6
6
|
import { t as QueryClient } from "../_libs/tanstack__query-core.mjs";
|
|
7
7
|
import { t as setupRouterSsrQueryIntegration } from "../_libs/@tanstack/react-router-ssr-query+[...].mjs";
|
|
8
8
|
import { n as HotkeysProvider } from "../_libs/tanstack__react-hotkeys.mjs";
|
|
@@ -20,7 +20,7 @@ import os, { homedir } from "node:os";
|
|
|
20
20
|
import { performance } from "node:perf_hooks";
|
|
21
21
|
import { isMainThread } from "node:worker_threads";
|
|
22
22
|
import { execSync, spawn } from "node:child_process";
|
|
23
|
-
//#region node_modules/.nitro/vite/services/ssr/assets/router-
|
|
23
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/router-CgnX-Js0.js
|
|
24
24
|
var import_react = /* @__PURE__ */ __toESM(require_react());
|
|
25
25
|
var import_jsx_runtime = require_jsx_runtime();
|
|
26
26
|
var Toaster$1 = ({ ...props }) => {
|
|
@@ -2,7 +2,7 @@ import { i as __toESM } from "../_runtime.mjs";
|
|
|
2
2
|
import { A as DialogRoot, C as MenuPortal, D as TabsTab, E as TabsList$1, F as DialogBackdrop, I as Separator, K as mergeProps, L as Input, M as DialogPopup, N as DialogDescription$1, O as TabsRoot, P as DialogClose, R as Button, S as MenuPositioner, T as MenuItem, X as require_react, Y as require_jsx_runtime, _ as AccordionRoot, a as CollapsiblePanel, b as MenuSubmenuRoot, c as PopoverPopup, d as PopoverTrigger$1, f as PopoverRoot, g as AccordionItem$1, h as AccordionHeader, i as ContextMenuRoot, j as DialogPortal$1, k as DialogTitle$1, l as PopoverPositioner, m as AccordionTrigger$1, n as Toggle, o as CollapsibleTrigger$1, p as AccordionPanel, r as ContextMenuTrigger$1, s as CollapsibleRoot, t as ToggleGroup, u as PopoverPortal, v as MenuSubmenuTrigger, w as MenuPopup, x as MenuRoot, y as MenuTrigger, z as useRender } from "../_libs/@base-ui/react+[...].mjs";
|
|
3
3
|
import { t as cva } from "../_libs/class-variance-authority+clsx.mjs";
|
|
4
4
|
import { A as ChevronsUpDown, B as ArrowDown, C as FolderPlus, D as Copy, E as Download, F as Check, I as ArrowUp, L as ArrowUpToLine, M as ChevronUp, N as ChevronRight, O as Command, P as ChevronDown, S as Folder, T as EllipsisVertical, _ as ListEnd, a as Square, b as GitBranch, c as Settings2, d as PanelLeft, f as PanelLeftOpen, g as ListStart, h as OctagonX, j as ChevronsDownUp, l as Search, n as WandSparkles, o as SquarePen, p as PanelLeftClose, r as Upload, s as SquareArrowOutUpRight, t as X, u as PanelRight, w as Ellipsis, x as GitCommitHorizontal, y as ImagePlus, z as ArrowLeft } from "../_libs/lucide-react.mjs";
|
|
5
|
-
import { $ as readStoredRightSidebarOpen, B as normalizeSessionSelectionKeys, C as TooltipContent, E as VIEWER_CONTEXT_STORAGE_KEY, G as readStoredAutoScrollEnabled, H as normalizeThemeMode, I as flattenTree, J as readStoredDraftDirectory, K as readStoredCenterMessages, L as getSessionTitle, M as createInitialSessionState, O as buildItemsFromSync, Q as readStoredRecentDirectories, S as Tooltip$1, T as TooltipTrigger, U as previewUrlForImage, V as normalizeStoredDirectoryList, W as promptDraftKey, X as readStoredPinnedSessionKeys, Y as readStoredHideToolBlocks, Z as readStoredPromptDraft, _ as SESSION_DONE_SOUND_ENABLED_STORAGE_KEY, a as HIDE_TOOL_BLOCKS_STORAGE_KEY, at as safeLocalStorageSetItem, c as PINNED_SESSIONS_STORAGE_KEY, ct as thinkingSummaryText, d as RIGHT_SIDEBAR_FILE_TREE_WIDTH_STORAGE_KEY, et as readStoredSessionDoneDesktopNotificationsEnabled, f as RIGHT_SIDEBAR_HISTORY_HEIGHT_STORAGE_KEY, g as SESSION_DONE_DESKTOP_NOTIFICATIONS_ENABLED_STORAGE_KEY, h as Route, i as DRAFT_DIRECTORY_STORAGE_KEY, it as safeLocalStorageGetItem, j as createContextId, k as cn, l as RECENT_DIRECTORIES_STORAGE_KEY, m as RIGHT_SIDEBAR_WIDTHS_STORAGE_KEY, n as CENTER_MESSAGES_STORAGE_KEY, nt as readStoredSidebarDirectories, o as Kbd, ot as sameContextUsage, p as RIGHT_SIDEBAR_OPEN_STORAGE_KEY, q as readStoredCollapsedDirectories, r as COLLAPSED_DIRECTORIES_STORAGE_KEY, rt as rememberStoredPromptDraft, s as KeyboardShortcutContent, st as sessionListEntryKey, t as AUTO_SCROLL_ENABLED_STORAGE_KEY, tt as readStoredSessionDoneSoundEnabled, u as RIGHT_SIDEBAR_ACTIVE_TAB_STORAGE_KEY, v as SIDEBAR_DIRECTORIES_STORAGE_KEY, x as TitleTooltip, y as Spinner, z as normalizePromptImage } from "./routes-
|
|
5
|
+
import { $ as readStoredRightSidebarOpen, B as normalizeSessionSelectionKeys, C as TooltipContent, E as VIEWER_CONTEXT_STORAGE_KEY, G as readStoredAutoScrollEnabled, H as normalizeThemeMode, I as flattenTree, J as readStoredDraftDirectory, K as readStoredCenterMessages, L as getSessionTitle, M as createInitialSessionState, O as buildItemsFromSync, Q as readStoredRecentDirectories, S as Tooltip$1, T as TooltipTrigger, U as previewUrlForImage, V as normalizeStoredDirectoryList, W as promptDraftKey, X as readStoredPinnedSessionKeys, Y as readStoredHideToolBlocks, Z as readStoredPromptDraft, _ as SESSION_DONE_SOUND_ENABLED_STORAGE_KEY, a as HIDE_TOOL_BLOCKS_STORAGE_KEY, at as safeLocalStorageSetItem, c as PINNED_SESSIONS_STORAGE_KEY, ct as thinkingSummaryText, d as RIGHT_SIDEBAR_FILE_TREE_WIDTH_STORAGE_KEY, et as readStoredSessionDoneDesktopNotificationsEnabled, f as RIGHT_SIDEBAR_HISTORY_HEIGHT_STORAGE_KEY, g as SESSION_DONE_DESKTOP_NOTIFICATIONS_ENABLED_STORAGE_KEY, h as Route, i as DRAFT_DIRECTORY_STORAGE_KEY, it as safeLocalStorageGetItem, j as createContextId, k as cn, l as RECENT_DIRECTORIES_STORAGE_KEY, m as RIGHT_SIDEBAR_WIDTHS_STORAGE_KEY, n as CENTER_MESSAGES_STORAGE_KEY, nt as readStoredSidebarDirectories, o as Kbd, ot as sameContextUsage, p as RIGHT_SIDEBAR_OPEN_STORAGE_KEY, q as readStoredCollapsedDirectories, r as COLLAPSED_DIRECTORIES_STORAGE_KEY, rt as rememberStoredPromptDraft, s as KeyboardShortcutContent, st as sessionListEntryKey, t as AUTO_SCROLL_ENABLED_STORAGE_KEY, tt as readStoredSessionDoneSoundEnabled, u as RIGHT_SIDEBAR_ACTIVE_TAB_STORAGE_KEY, v as SIDEBAR_DIRECTORIES_STORAGE_KEY, x as TitleTooltip, y as Spinner, z as normalizePromptImage } from "./routes-D2MVUd_A.mjs";
|
|
6
6
|
import { i as useQuery, n as useIsMutating, o as useQueryClient, r as useIsFetching, t as useMutation } from "../_libs/tanstack__react-query.mjs";
|
|
7
7
|
import { t as useHotkeys } from "../_libs/tanstack__react-hotkeys.mjs";
|
|
8
8
|
import { a as matchesKeyboardEvent, i as batch, o as formatForDisplay, r as createStore } from "../_libs/@tanstack/hotkeys+[...].mjs";
|
|
@@ -15,11 +15,14 @@ import { t as _e } from "../_libs/cmdk.mjs";
|
|
|
15
15
|
import { t as Drawer } from "../_libs/vaul.mjs";
|
|
16
16
|
import { n as MultiFileDiff, t as PatchDiff } from "../_libs/@pierre/diffs+[...].mjs";
|
|
17
17
|
import { t as Markdown } from "../_libs/react-markdown+[...].mjs";
|
|
18
|
+
import { t as rehypeRaw } from "../_libs/rehype-raw.mjs";
|
|
19
|
+
import { n as defaultSchema } from "../_libs/hast-util-sanitize.mjs";
|
|
20
|
+
import { t as rehypeSanitize } from "../_libs/rehype-sanitize.mjs";
|
|
18
21
|
import { t as remarkGfm } from "../_libs/remark-gfm.mjs";
|
|
19
22
|
import { a as getBuiltInSpriteSheet, i as getBuiltInFileIconColor, n as FileTree, r as createFileTreeIconResolver, t as useFileTree } from "../_libs/@pierre/trees+[...].mjs";
|
|
20
23
|
import { a as closestCenter, d as useSensors, f as CSS$1, i as PointerSensor, n as DragOverlay, t as DndContext, u as useSensor } from "../_libs/@dnd-kit/core+[...].mjs";
|
|
21
24
|
import { a as verticalListSortingStrategy, i as useSortable, n as arrayMove, r as horizontalListSortingStrategy, t as SortableContext } from "../_libs/dnd-kit__sortable.mjs";
|
|
22
|
-
//#region node_modules/.nitro/vite/services/ssr/assets/routes-
|
|
25
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/routes-CmLc8G9G.js
|
|
23
26
|
var import_react = /* @__PURE__ */ __toESM(require_react());
|
|
24
27
|
var import_jsx_runtime = require_jsx_runtime();
|
|
25
28
|
var MOBILE_BREAKPOINT = 768;
|
|
@@ -8547,26 +8550,9 @@ function applyCompletionItem({ value, query, item }) {
|
|
|
8547
8550
|
selectionEnd: selection
|
|
8548
8551
|
};
|
|
8549
8552
|
}
|
|
8550
|
-
function Collapsible$1({ ...props }) {
|
|
8551
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CollapsibleRoot, {
|
|
8552
|
-
"data-slot": "collapsible",
|
|
8553
|
-
...props
|
|
8554
|
-
});
|
|
8555
|
-
}
|
|
8556
|
-
function CollapsibleTrigger({ ...props }) {
|
|
8557
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CollapsibleTrigger$1, {
|
|
8558
|
-
"data-slot": "collapsible-trigger",
|
|
8559
|
-
...props
|
|
8560
|
-
});
|
|
8561
|
-
}
|
|
8562
|
-
function CollapsibleContent({ ...props }) {
|
|
8563
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CollapsiblePanel, {
|
|
8564
|
-
"data-slot": "collapsible-content",
|
|
8565
|
-
...props
|
|
8566
|
-
});
|
|
8567
|
-
}
|
|
8568
8553
|
var highlightCache = /* @__PURE__ */ new Map();
|
|
8569
8554
|
var MemoizedReactMarkdown = import_react.memo(Markdown);
|
|
8555
|
+
var MARKDOWN_REHYPE_PLUGINS = [rehypeRaw, [rehypeSanitize, defaultSchema]];
|
|
8570
8556
|
var MARKDOWN_REMARK_PLUGINS = [remarkGfm];
|
|
8571
8557
|
var MarkdownRenderingContext = import_react.createContext({ streaming: false });
|
|
8572
8558
|
function MarkdownAnchor({ children, href, node: _node, ...props }) {
|
|
@@ -8850,6 +8836,7 @@ var MarkdownBlock = import_react.memo(function MarkdownBlock({ streaming = false
|
|
|
8850
8836
|
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
8851
8837
|
className: "prose prose-sm max-w-none wrap-break-word dark:prose-invert prose-headings:font-semibold prose-p:my-2 prose-pre:m-0 prose-ol:my-2 prose-ul:my-2",
|
|
8852
8838
|
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(MemoizedReactMarkdown, {
|
|
8839
|
+
rehypePlugins: MARKDOWN_REHYPE_PLUGINS,
|
|
8853
8840
|
remarkPlugins: MARKDOWN_REMARK_PLUGINS,
|
|
8854
8841
|
components: MARKDOWN_COMPONENTS,
|
|
8855
8842
|
children: text
|
|
@@ -8857,6 +8844,24 @@ var MarkdownBlock = import_react.memo(function MarkdownBlock({ streaming = false
|
|
|
8857
8844
|
})
|
|
8858
8845
|
});
|
|
8859
8846
|
});
|
|
8847
|
+
function Collapsible$1({ ...props }) {
|
|
8848
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CollapsibleRoot, {
|
|
8849
|
+
"data-slot": "collapsible",
|
|
8850
|
+
...props
|
|
8851
|
+
});
|
|
8852
|
+
}
|
|
8853
|
+
function CollapsibleTrigger({ ...props }) {
|
|
8854
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CollapsibleTrigger$1, {
|
|
8855
|
+
"data-slot": "collapsible-trigger",
|
|
8856
|
+
...props
|
|
8857
|
+
});
|
|
8858
|
+
}
|
|
8859
|
+
function CollapsibleContent({ ...props }) {
|
|
8860
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CollapsiblePanel, {
|
|
8861
|
+
"data-slot": "collapsible-content",
|
|
8862
|
+
...props
|
|
8863
|
+
});
|
|
8864
|
+
}
|
|
8860
8865
|
function promptImageKey(image) {
|
|
8861
8866
|
return `${image.previewUrl}:${image.data.slice(0, 24)}`;
|
|
8862
8867
|
}
|
|
@@ -10111,7 +10116,7 @@ function ToolBlockCardContent({ blockKey, header, store }) {
|
|
|
10111
10116
|
className: "truncate font-medium whitespace-nowrap text-foreground",
|
|
10112
10117
|
children: toolDisplayName(header.name)
|
|
10113
10118
|
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
10114
|
-
className: "truncate text-muted-foreground",
|
|
10119
|
+
className: cn("truncate text-muted-foreground", header.name === "write" && "tabular-nums"),
|
|
10115
10120
|
children: header.summary
|
|
10116
10121
|
})]
|
|
10117
10122
|
}),
|
|
@@ -13104,6 +13109,65 @@ function ContextMenuSeparator({ className, ...props }) {
|
|
|
13104
13109
|
...props
|
|
13105
13110
|
});
|
|
13106
13111
|
}
|
|
13112
|
+
var toggleVariants = cva("group/toggle inline-flex items-center justify-center gap-1 rounded-lg text-sm font-medium whitespace-nowrap transition-all outline-none hover:bg-muted hover:text-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 aria-pressed:bg-muted data-[state=on]:bg-muted dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", {
|
|
13113
|
+
variants: {
|
|
13114
|
+
variant: {
|
|
13115
|
+
default: "bg-transparent",
|
|
13116
|
+
outline: "border border-input bg-transparent hover:bg-muted"
|
|
13117
|
+
},
|
|
13118
|
+
size: {
|
|
13119
|
+
default: "h-8 min-w-8 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
|
|
13120
|
+
sm: "h-7 min-w-7 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5",
|
|
13121
|
+
lg: "h-9 min-w-9 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2"
|
|
13122
|
+
}
|
|
13123
|
+
},
|
|
13124
|
+
defaultVariants: {
|
|
13125
|
+
variant: "default",
|
|
13126
|
+
size: "default"
|
|
13127
|
+
}
|
|
13128
|
+
});
|
|
13129
|
+
var ToggleGroupContext = import_react.createContext({
|
|
13130
|
+
size: "default",
|
|
13131
|
+
variant: "default",
|
|
13132
|
+
spacing: 0,
|
|
13133
|
+
orientation: "horizontal"
|
|
13134
|
+
});
|
|
13135
|
+
function ToggleGroup$1({ className, variant, size, spacing = 0, orientation = "horizontal", children, ...props }) {
|
|
13136
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToggleGroup, {
|
|
13137
|
+
"data-slot": "toggle-group",
|
|
13138
|
+
"data-variant": variant,
|
|
13139
|
+
"data-size": size,
|
|
13140
|
+
"data-spacing": spacing,
|
|
13141
|
+
"data-orientation": orientation,
|
|
13142
|
+
style: { "--gap": spacing },
|
|
13143
|
+
className: cn("group/toggle-group flex w-fit flex-row items-center gap-[--spacing(var(--gap))] rounded-lg data-[size=sm]:rounded-[min(var(--radius-md),10px)] data-vertical:flex-col data-vertical:items-stretch", className),
|
|
13144
|
+
...props,
|
|
13145
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToggleGroupContext.Provider, {
|
|
13146
|
+
value: {
|
|
13147
|
+
variant,
|
|
13148
|
+
size,
|
|
13149
|
+
spacing,
|
|
13150
|
+
orientation
|
|
13151
|
+
},
|
|
13152
|
+
children
|
|
13153
|
+
})
|
|
13154
|
+
});
|
|
13155
|
+
}
|
|
13156
|
+
function ToggleGroupItem({ className, children, variant = "default", size = "default", ...props }) {
|
|
13157
|
+
const context = import_react.useContext(ToggleGroupContext);
|
|
13158
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Toggle, {
|
|
13159
|
+
"data-slot": "toggle-group-item",
|
|
13160
|
+
"data-variant": context.variant || variant,
|
|
13161
|
+
"data-size": context.size || size,
|
|
13162
|
+
"data-spacing": context.spacing,
|
|
13163
|
+
className: cn("shrink-0 group-data-[spacing=0]/toggle-group:rounded-none group-data-[spacing=0]/toggle-group:px-2 focus:z-10 focus-visible:z-10 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-end]:pr-1.5 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-start]:pl-1.5 group-data-horizontal/toggle-group:data-[spacing=0]:first:rounded-l-lg group-data-vertical/toggle-group:data-[spacing=0]:first:rounded-t-lg group-data-horizontal/toggle-group:data-[spacing=0]:last:rounded-r-lg group-data-vertical/toggle-group:data-[spacing=0]:last:rounded-b-lg group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:border-l-0 group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:border-t-0 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-l group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-t", toggleVariants({
|
|
13164
|
+
variant: context.variant || variant,
|
|
13165
|
+
size: context.size || size
|
|
13166
|
+
}), className),
|
|
13167
|
+
...props,
|
|
13168
|
+
children
|
|
13169
|
+
});
|
|
13170
|
+
}
|
|
13107
13171
|
function GitSectionNote({ children, tone = "muted", className }) {
|
|
13108
13172
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
13109
13173
|
className: cn("flex min-h-8 items-center gap-2 text-sm leading-6", tone === "destructive" ? "text-destructive" : "text-muted-foreground", className),
|
|
@@ -13135,6 +13199,8 @@ var CODE_LANGUAGE_BY_EXTENSION = {
|
|
|
13135
13199
|
js: "javascript",
|
|
13136
13200
|
jsx: "jsx",
|
|
13137
13201
|
json: "json",
|
|
13202
|
+
markdown: "markdown",
|
|
13203
|
+
md: "markdown",
|
|
13138
13204
|
jsonc: "jsonc",
|
|
13139
13205
|
mjs: "javascript",
|
|
13140
13206
|
mdx: "mdx",
|
|
@@ -13146,11 +13212,18 @@ var CODE_LANGUAGE_BY_EXTENSION = {
|
|
|
13146
13212
|
yaml: "yaml",
|
|
13147
13213
|
yml: "yaml"
|
|
13148
13214
|
};
|
|
13215
|
+
function fileExtensionFromPath(path) {
|
|
13216
|
+
return (path.split(/[?#]/)[0] || "").match(/\.([A-Za-z0-9]+)$/)?.[1]?.toLowerCase();
|
|
13217
|
+
}
|
|
13149
13218
|
function codeLanguageFromPath(path) {
|
|
13150
|
-
const extension = (path
|
|
13219
|
+
const extension = fileExtensionFromPath(path);
|
|
13151
13220
|
if (!extension) return void 0;
|
|
13152
13221
|
return CODE_LANGUAGE_BY_EXTENSION[extension];
|
|
13153
13222
|
}
|
|
13223
|
+
function isMarkdownFilePath(path) {
|
|
13224
|
+
const extension = fileExtensionFromPath(path);
|
|
13225
|
+
return extension === "md" || extension === "markdown";
|
|
13226
|
+
}
|
|
13154
13227
|
function hasHighlightHtml(payload) {
|
|
13155
13228
|
return Boolean(payload && "html" in payload && payload.html);
|
|
13156
13229
|
}
|
|
@@ -13464,10 +13537,14 @@ function ProjectFileContent({ viewerContextId, cwd, active, path }) {
|
|
|
13464
13537
|
});
|
|
13465
13538
|
const content = fileQuery.data?.content ?? "";
|
|
13466
13539
|
const language = codeLanguageFromPath(path);
|
|
13540
|
+
const isMarkdownFile = isMarkdownFilePath(path);
|
|
13541
|
+
const [markdownViewModes, setMarkdownViewModes] = import_react.useState({});
|
|
13542
|
+
const markdownViewMode = isMarkdownFile ? markdownViewModes[path] || "preview" : "source";
|
|
13543
|
+
const showMarkdownPreview = isMarkdownFile && markdownViewMode === "preview";
|
|
13467
13544
|
const [highlighted, setHighlighted] = import_react.useState(null);
|
|
13468
13545
|
import_react.useEffect(() => {
|
|
13469
13546
|
let cancelled = false;
|
|
13470
|
-
if (!active || !content || !language) {
|
|
13547
|
+
if (!active || !content || !language || showMarkdownPreview) {
|
|
13471
13548
|
setHighlighted(null);
|
|
13472
13549
|
return;
|
|
13473
13550
|
}
|
|
@@ -13486,33 +13563,63 @@ function ProjectFileContent({ viewerContextId, cwd, active, path }) {
|
|
|
13486
13563
|
}, [
|
|
13487
13564
|
active,
|
|
13488
13565
|
content,
|
|
13489
|
-
language
|
|
13566
|
+
language,
|
|
13567
|
+
showMarkdownPreview
|
|
13490
13568
|
]);
|
|
13491
13569
|
if (!path) return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
13492
13570
|
className: "flex h-full items-center justify-center p-6 text-center text-sm text-muted-foreground",
|
|
13493
13571
|
children: "Select a file to preview it."
|
|
13494
13572
|
});
|
|
13495
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.
|
|
13496
|
-
className: "h-full min-h-0
|
|
13497
|
-
children:
|
|
13498
|
-
className: "
|
|
13499
|
-
children:
|
|
13500
|
-
|
|
13501
|
-
|
|
13502
|
-
|
|
13503
|
-
|
|
13504
|
-
|
|
13505
|
-
|
|
13506
|
-
|
|
13507
|
-
|
|
13508
|
-
|
|
13509
|
-
|
|
13510
|
-
|
|
13573
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
13574
|
+
className: "flex h-full min-h-0 flex-col bg-background",
|
|
13575
|
+
children: [isMarkdownFile ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
13576
|
+
className: "flex shrink-0 items-center justify-between gap-3 border-b border-border/70 px-3 py-2",
|
|
13577
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
13578
|
+
className: "truncate text-xs font-medium text-muted-foreground",
|
|
13579
|
+
children: "Markdown"
|
|
13580
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(ToggleGroup$1, {
|
|
13581
|
+
variant: "outline",
|
|
13582
|
+
value: [markdownViewMode],
|
|
13583
|
+
onValueChange: (values) => {
|
|
13584
|
+
const value = values[0];
|
|
13585
|
+
if (value === "preview" || value === "source") setMarkdownViewModes((current) => ({
|
|
13586
|
+
...current,
|
|
13587
|
+
[path]: value
|
|
13588
|
+
}));
|
|
13589
|
+
},
|
|
13590
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToggleGroupItem, {
|
|
13591
|
+
value: "preview",
|
|
13592
|
+
children: "Preview"
|
|
13593
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToggleGroupItem, {
|
|
13594
|
+
value: "source",
|
|
13595
|
+
children: "Source"
|
|
13596
|
+
})]
|
|
13597
|
+
})]
|
|
13598
|
+
}) : null, /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
13599
|
+
className: "min-h-0 flex-1 overflow-auto",
|
|
13600
|
+
children: fileQuery.isPending && !fileQuery.data ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
13601
|
+
className: "p-4",
|
|
13602
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(GitSectionNote, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Spinner, {}), " Loading file…"] })
|
|
13603
|
+
}) : fileQuery.error ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
13604
|
+
className: "p-4",
|
|
13605
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(GitSectionNote, {
|
|
13606
|
+
tone: "destructive",
|
|
13607
|
+
children: getErrorMessage(fileQuery.error, "Failed to load file")
|
|
13608
|
+
})
|
|
13609
|
+
}) : showMarkdownPreview ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
13610
|
+
className: "min-h-full p-4 text-foreground",
|
|
13611
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(MarkdownBlock, { text: content })
|
|
13612
|
+
}) : hasHighlightHtml(highlighted) ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("pre", {
|
|
13613
|
+
className: "m-0 min-h-full p-4 font-mono text-[13px] leading-5 whitespace-pre-wrap text-foreground",
|
|
13614
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("code", {
|
|
13615
|
+
className: cn(language && `language-${language}`),
|
|
13616
|
+
dangerouslySetInnerHTML: { __html: highlighted.html }
|
|
13617
|
+
})
|
|
13618
|
+
}) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)("pre", {
|
|
13619
|
+
className: "m-0 min-h-full p-4 font-mono text-[13px] leading-5 whitespace-pre-wrap text-foreground",
|
|
13620
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("code", { children: content })
|
|
13511
13621
|
})
|
|
13512
|
-
})
|
|
13513
|
-
className: "m-0 min-h-full p-4 font-mono text-[13px] leading-5 whitespace-pre-wrap text-foreground",
|
|
13514
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("code", { children: content })
|
|
13515
|
-
})
|
|
13622
|
+
})]
|
|
13516
13623
|
});
|
|
13517
13624
|
}
|
|
13518
13625
|
function FileViewerTabContent({ active, dragging = false, dragListeners, dragAttributes, index, onActiveFileChange, onActiveTabChange, onCloseAllFiles, onCloseFile, onCloseFilesToRight, onCloseOtherFiles, path, preview, tabCount }) {
|
|
@@ -14455,65 +14562,6 @@ function GitPanelToolbar({ viewerContextId, cwd, active }) {
|
|
|
14455
14562
|
]
|
|
14456
14563
|
});
|
|
14457
14564
|
}
|
|
14458
|
-
var toggleVariants = cva("group/toggle inline-flex items-center justify-center gap-1 rounded-lg text-sm font-medium whitespace-nowrap transition-all outline-none hover:bg-muted hover:text-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 aria-pressed:bg-muted data-[state=on]:bg-muted dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", {
|
|
14459
|
-
variants: {
|
|
14460
|
-
variant: {
|
|
14461
|
-
default: "bg-transparent",
|
|
14462
|
-
outline: "border border-input bg-transparent hover:bg-muted"
|
|
14463
|
-
},
|
|
14464
|
-
size: {
|
|
14465
|
-
default: "h-8 min-w-8 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
|
|
14466
|
-
sm: "h-7 min-w-7 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5",
|
|
14467
|
-
lg: "h-9 min-w-9 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2"
|
|
14468
|
-
}
|
|
14469
|
-
},
|
|
14470
|
-
defaultVariants: {
|
|
14471
|
-
variant: "default",
|
|
14472
|
-
size: "default"
|
|
14473
|
-
}
|
|
14474
|
-
});
|
|
14475
|
-
var ToggleGroupContext = import_react.createContext({
|
|
14476
|
-
size: "default",
|
|
14477
|
-
variant: "default",
|
|
14478
|
-
spacing: 0,
|
|
14479
|
-
orientation: "horizontal"
|
|
14480
|
-
});
|
|
14481
|
-
function ToggleGroup$1({ className, variant, size, spacing = 0, orientation = "horizontal", children, ...props }) {
|
|
14482
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToggleGroup, {
|
|
14483
|
-
"data-slot": "toggle-group",
|
|
14484
|
-
"data-variant": variant,
|
|
14485
|
-
"data-size": size,
|
|
14486
|
-
"data-spacing": spacing,
|
|
14487
|
-
"data-orientation": orientation,
|
|
14488
|
-
style: { "--gap": spacing },
|
|
14489
|
-
className: cn("group/toggle-group flex w-fit flex-row items-center gap-[--spacing(var(--gap))] rounded-lg data-[size=sm]:rounded-[min(var(--radius-md),10px)] data-vertical:flex-col data-vertical:items-stretch", className),
|
|
14490
|
-
...props,
|
|
14491
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToggleGroupContext.Provider, {
|
|
14492
|
-
value: {
|
|
14493
|
-
variant,
|
|
14494
|
-
size,
|
|
14495
|
-
spacing,
|
|
14496
|
-
orientation
|
|
14497
|
-
},
|
|
14498
|
-
children
|
|
14499
|
-
})
|
|
14500
|
-
});
|
|
14501
|
-
}
|
|
14502
|
-
function ToggleGroupItem({ className, children, variant = "default", size = "default", ...props }) {
|
|
14503
|
-
const context = import_react.useContext(ToggleGroupContext);
|
|
14504
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Toggle, {
|
|
14505
|
-
"data-slot": "toggle-group-item",
|
|
14506
|
-
"data-variant": context.variant || variant,
|
|
14507
|
-
"data-size": context.size || size,
|
|
14508
|
-
"data-spacing": context.spacing,
|
|
14509
|
-
className: cn("shrink-0 group-data-[spacing=0]/toggle-group:rounded-none group-data-[spacing=0]/toggle-group:px-2 focus:z-10 focus-visible:z-10 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-end]:pr-1.5 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-start]:pl-1.5 group-data-horizontal/toggle-group:data-[spacing=0]:first:rounded-l-lg group-data-vertical/toggle-group:data-[spacing=0]:first:rounded-t-lg group-data-horizontal/toggle-group:data-[spacing=0]:last:rounded-r-lg group-data-vertical/toggle-group:data-[spacing=0]:last:rounded-b-lg group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:border-l-0 group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:border-t-0 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-l group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-t", toggleVariants({
|
|
14510
|
-
variant: context.variant || variant,
|
|
14511
|
-
size: context.size || size
|
|
14512
|
-
}), className),
|
|
14513
|
-
...props,
|
|
14514
|
-
children
|
|
14515
|
-
});
|
|
14516
|
-
}
|
|
14517
14565
|
function GitSection({ title, meta, controls, className, bodyClassName, children }) {
|
|
14518
14566
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("section", {
|
|
14519
14567
|
className: cn("overflow-hidden rounded-xl border border-border/80 bg-card/50", className),
|
|
@@ -15501,21 +15549,18 @@ function ReviewFileAccordionItem({ viewerContextId, cwd, active, diffStyle, file
|
|
|
15501
15549
|
className: "pointer-events-none hidden size-4 shrink-0 group-aria-expanded/review-file-trigger:inline"
|
|
15502
15550
|
})
|
|
15503
15551
|
]
|
|
15504
|
-
}), onOpenFile ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
15552
|
+
}), onOpenFile ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Button$1, {
|
|
15553
|
+
type: "button",
|
|
15554
|
+
variant: "ghost",
|
|
15555
|
+
size: "icon-xs",
|
|
15556
|
+
"aria-label": `Open ${file.path}`,
|
|
15505
15557
|
title: "Open file",
|
|
15506
|
-
|
|
15507
|
-
|
|
15508
|
-
|
|
15509
|
-
|
|
15510
|
-
|
|
15511
|
-
|
|
15512
|
-
className: "mr-2 self-center",
|
|
15513
|
-
onClick: (event) => {
|
|
15514
|
-
event.stopPropagation();
|
|
15515
|
-
onOpenFile(file.path, { pin: true });
|
|
15516
|
-
},
|
|
15517
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SquareArrowOutUpRight, { className: "size-3.5" })
|
|
15518
|
-
})
|
|
15558
|
+
className: "mr-2 self-center",
|
|
15559
|
+
onClick: (event) => {
|
|
15560
|
+
event.stopPropagation();
|
|
15561
|
+
onOpenFile(file.path, { pin: true });
|
|
15562
|
+
},
|
|
15563
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SquareArrowOutUpRight, { className: "size-3.5" })
|
|
15519
15564
|
}) : null]
|
|
15520
15565
|
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AccordionContent, {
|
|
15521
15566
|
className: "bg-background p-0",
|
|
@@ -5,7 +5,7 @@ import { n as clsx } from "../_libs/class-variance-authority+clsx.mjs";
|
|
|
5
5
|
import { t as twMerge } from "../_libs/tailwind-merge.mjs";
|
|
6
6
|
import { B as ArrowDown, I as ArrowUp, M as ChevronUp, O as Command, R as ArrowRight, V as ArrowBigUp, m as Option, z as ArrowLeft } from "../_libs/lucide-react.mjs";
|
|
7
7
|
import { n as string, t as object } from "../_libs/zod.mjs";
|
|
8
|
-
//#region node_modules/.nitro/vite/services/ssr/assets/routes-
|
|
8
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/routes-D2MVUd_A.js
|
|
9
9
|
var import_react = /* @__PURE__ */ __toESM(require_react());
|
|
10
10
|
var import_jsx_runtime = require_jsx_runtime();
|
|
11
11
|
function cn(...inputs) {
|
|
@@ -1279,7 +1279,7 @@ function getSessionTitle(summary) {
|
|
|
1279
1279
|
if (summary?.name?.trim()) return summary.name.trim();
|
|
1280
1280
|
return "New session";
|
|
1281
1281
|
}
|
|
1282
|
-
var $$splitComponentImporter = () => import("./routes-
|
|
1282
|
+
var $$splitComponentImporter = () => import("./routes-CmLc8G9G.mjs");
|
|
1283
1283
|
var indexSearchSchema = object({ session: string().optional() });
|
|
1284
1284
|
var Route = createFileRoute("/")({
|
|
1285
1285
|
validateSearch: indexSearchSchema,
|
|
@@ -3813,7 +3813,7 @@ var defaultSerovalPlugins = [
|
|
|
3813
3813
|
* the dev styles URL for route-scoped CSS collection.
|
|
3814
3814
|
*/
|
|
3815
3815
|
async function getStartManifest(matchedRoutes) {
|
|
3816
|
-
const { tsrStartManifest } = await import("../_tanstack-start-manifest_v-
|
|
3816
|
+
const { tsrStartManifest } = await import("../_tanstack-start-manifest_v-BSXP2b2T.mjs");
|
|
3817
3817
|
const startManifest = tsrStartManifest();
|
|
3818
3818
|
const rootRoute = startManifest.routes[rootRouteId] = startManifest.routes["__root__"] || {};
|
|
3819
3819
|
rootRoute.assets = rootRoute.assets || [];
|
|
@@ -4799,7 +4799,7 @@ var baseManifestPromise;
|
|
|
4799
4799
|
var cachedFinalManifestPromise;
|
|
4800
4800
|
async function loadEntries() {
|
|
4801
4801
|
const [routerEntry, startEntry, pluginAdapters] = await Promise.all([
|
|
4802
|
-
import("./router-
|
|
4802
|
+
import("./router-CgnX-Js0.mjs"),
|
|
4803
4803
|
import("./start-Captdpmb.mjs"),
|
|
4804
4804
|
import("../__23tanstack-start-plugin-adapters-y_fshQDY.mjs")
|
|
4805
4805
|
]);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
//#region node_modules/.nitro/vite/services/ssr/assets/_tanstack-start-manifest_v-
|
|
1
|
+
//#region node_modules/.nitro/vite/services/ssr/assets/_tanstack-start-manifest_v-BSXP2b2T.js
|
|
2
2
|
var tsrStartManifest = () => ({
|
|
3
3
|
routes: {
|
|
4
4
|
__root__: {
|
|
@@ -50,16 +50,16 @@ var tsrStartManifest = () => ({
|
|
|
50
50
|
"/api/ui/$id"
|
|
51
51
|
],
|
|
52
52
|
assets: void 0,
|
|
53
|
-
preloads: ["/assets/index-
|
|
53
|
+
preloads: ["/assets/index-BiaOlsw0.js", "/assets/rolldown-runtime-S-ySWqyJ.js"]
|
|
54
54
|
},
|
|
55
55
|
"/": {
|
|
56
56
|
filePath: "/home/runner/work/pico/pico/src/routes/index.tsx",
|
|
57
57
|
children: void 0,
|
|
58
58
|
assets: void 0,
|
|
59
|
-
preloads: ["/assets/routes-
|
|
59
|
+
preloads: ["/assets/routes-C7eqqi44.js"]
|
|
60
60
|
}
|
|
61
61
|
},
|
|
62
|
-
clientEntry: "/assets/index-
|
|
62
|
+
clientEntry: "/assets/index-BiaOlsw0.js"
|
|
63
63
|
});
|
|
64
64
|
//#endregion
|
|
65
65
|
export { tsrStartManifest };
|