@tangle-network/sandbox-ui 0.132.2 → 0.132.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.
|
@@ -2761,6 +2761,26 @@ const HIDE_BELOW_CLASS = {
|
|
|
2761
2761
|
md: "max-md:hidden",
|
|
2762
2762
|
lg: "max-lg:hidden"
|
|
2763
2763
|
};
|
|
2764
|
+
/** The width at which each `hideBelow` breakpoint shows the rail again. */
|
|
2765
|
+
const DESKTOP_QUERY = {
|
|
2766
|
+
md: "(min-width: 48rem)",
|
|
2767
|
+
lg: "(min-width: 64rem)"
|
|
2768
|
+
};
|
|
2769
|
+
/**
|
|
2770
|
+
* Whether the rail is showing. A host without matchMedia (jsdom, an old
|
|
2771
|
+
* embedded webview) and the server both count as desktop.
|
|
2772
|
+
*/
|
|
2773
|
+
function useRailVisible(hideBelow) {
|
|
2774
|
+
const query = hideBelow ? DESKTOP_QUERY[hideBelow] : void 0;
|
|
2775
|
+
const subscribe = React$1.useCallback((onChange) => {
|
|
2776
|
+
if (!query || typeof window.matchMedia !== "function") return () => {};
|
|
2777
|
+
const media = window.matchMedia(query);
|
|
2778
|
+
media.addEventListener("change", onChange);
|
|
2779
|
+
return () => media.removeEventListener("change", onChange);
|
|
2780
|
+
}, [query]);
|
|
2781
|
+
const read = () => !query || typeof window.matchMedia !== "function" || window.matchMedia(query).matches;
|
|
2782
|
+
return React$1.useSyncExternalStore(subscribe, read, () => true);
|
|
2783
|
+
}
|
|
2764
2784
|
/** Inverse of {@link HIDE_BELOW_CLASS} — the mobile surfaces that stand in for
|
|
2765
2785
|
* the hidden rail show exactly where the rail does not. */
|
|
2766
2786
|
const SHOW_BELOW_CLASS = {
|
|
@@ -2818,7 +2838,7 @@ function SidebarLayoutInner({ children, navItems, activeId, panel, logo, logoHre
|
|
|
2818
2838
|
return;
|
|
2819
2839
|
}
|
|
2820
2840
|
if (typeof window.matchMedia !== "function") return;
|
|
2821
|
-
const desktop = window.matchMedia(hideBelow
|
|
2841
|
+
const desktop = window.matchMedia(DESKTOP_QUERY[hideBelow]);
|
|
2822
2842
|
const closeOnDesktop = () => {
|
|
2823
2843
|
if (desktop.matches) setMobileNavOpen(false);
|
|
2824
2844
|
};
|
|
@@ -2826,6 +2846,8 @@ function SidebarLayoutInner({ children, navItems, activeId, panel, logo, logoHre
|
|
|
2826
2846
|
desktop.addEventListener("change", closeOnDesktop);
|
|
2827
2847
|
return () => desktop.removeEventListener("change", closeOnDesktop);
|
|
2828
2848
|
}, [hideBelow, mobileNavOpen]);
|
|
2849
|
+
const railVisible = useRailVisible(hideBelow);
|
|
2850
|
+
const headerSlot = mobileNavOpen ? "drawer" : railVisible ? "rail" : "bar";
|
|
2829
2851
|
/**
|
|
2830
2852
|
* One nav list, rendered twice — once in the desktop rail, once in the mobile
|
|
2831
2853
|
* drawer. Sharing the renderer is the point: a product adds a destination to
|
|
@@ -2933,7 +2955,7 @@ function SidebarLayoutInner({ children, navItems, activeId, panel, logo, logoHre
|
|
|
2933
2955
|
onToggle: toggleRail,
|
|
2934
2956
|
collapsible: railLabels,
|
|
2935
2957
|
LinkComponent,
|
|
2936
|
-
children: railHeaderContent
|
|
2958
|
+
children: headerSlot === "rail" ? railHeaderContent : void 0
|
|
2937
2959
|
}),
|
|
2938
2960
|
/* @__PURE__ */ jsx(SidebarRailNav, {
|
|
2939
2961
|
className: cn$1(showLabels ? "px-2" : void 0, expandOnEmptyClick && "cursor-pointer"),
|
|
@@ -2979,7 +3001,7 @@ function SidebarLayoutInner({ children, navItems, activeId, panel, logo, logoHre
|
|
|
2979
3001
|
}),
|
|
2980
3002
|
/* @__PURE__ */ jsx("div", {
|
|
2981
3003
|
className: "flex min-w-0 flex-1 items-center",
|
|
2982
|
-
children: railHeaderContent ?? (logo !== void 0 ? /* @__PURE__ */ jsx(Link, {
|
|
3004
|
+
children: (headerSlot === "bar" ? railHeaderContent : void 0) ?? (logo !== void 0 ? /* @__PURE__ */ jsx(Link, {
|
|
2983
3005
|
href: logoHref,
|
|
2984
3006
|
to: logoHref,
|
|
2985
3007
|
className: "flex min-w-0 items-center",
|
package/dist/dashboard.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as useSidebar, A as parseInsufficientBalance, B as SidebarPanel, C as SandboxStatusPill, D as ResourceMeter, E as ResourceSnapshot, F as RailHeader, G as SidebarRailNav, H as SidebarPanelHeader, I as RailModeButton, J as SIDEBAR_PANEL_WIDTH, K as RailTooltip, L as RailSeparator, M as RailButton, N as RailExpandable, O as INSUFFICIENT_BALANCE_CODE, P as RailFlyout, Q as SidebarProvider, R as Sidebar, S as SANDBOX_STATUS, T as ActivityFeed, U as SidebarRail, V as SidebarPanelContent, W as SidebarRailFooter, X as SIDEBAR_RAIL_WIDTH, Y as SIDEBAR_RAIL_LABELED_WIDTH, Z as SIDEBAR_TOTAL_WIDTH, _ as BackendSelector, a as PortsList, b as SandboxCard, c as SystemLogsViewer, d as DashboardLayout, f as HARNESS_OPTIONS, g as HarnessLogo, h as HARNESS_BRAND, i as TemplateCard, j as ProfileAvatar, k as OutOfCreditsModal, l as MetricAreaChart, m as chatCapableHarnesses, n as SnapshotList, o as GitPanel, p as HarnessPicker, q as SIDEBAR_MOBILE_WIDTH, r as ProcessList, s as UsageSummary, t as PromoBanner, u as SidebarLayout, v as SandboxTable, w as sandboxStatus, x as canAdminSandbox, y as NewSandboxCard, z as SidebarContent } from "./dashboard-
|
|
1
|
+
import { $ as useSidebar, A as parseInsufficientBalance, B as SidebarPanel, C as SandboxStatusPill, D as ResourceMeter, E as ResourceSnapshot, F as RailHeader, G as SidebarRailNav, H as SidebarPanelHeader, I as RailModeButton, J as SIDEBAR_PANEL_WIDTH, K as RailTooltip, L as RailSeparator, M as RailButton, N as RailExpandable, O as INSUFFICIENT_BALANCE_CODE, P as RailFlyout, Q as SidebarProvider, R as Sidebar, S as SANDBOX_STATUS, T as ActivityFeed, U as SidebarRail, V as SidebarPanelContent, W as SidebarRailFooter, X as SIDEBAR_RAIL_WIDTH, Y as SIDEBAR_RAIL_LABELED_WIDTH, Z as SIDEBAR_TOTAL_WIDTH, _ as BackendSelector, a as PortsList, b as SandboxCard, c as SystemLogsViewer, d as DashboardLayout, f as HARNESS_OPTIONS, g as HarnessLogo, h as HARNESS_BRAND, i as TemplateCard, j as ProfileAvatar, k as OutOfCreditsModal, l as MetricAreaChart, m as chatCapableHarnesses, n as SnapshotList, o as GitPanel, p as HarnessPicker, q as SIDEBAR_MOBILE_WIDTH, r as ProcessList, s as UsageSummary, t as PromoBanner, u as SidebarLayout, v as SandboxTable, w as sandboxStatus, x as canAdminSandbox, y as NewSandboxCard, z as SidebarContent } from "./dashboard-CGtJ8Q_h.js";
|
|
2
2
|
import { n as canonicalModelId, r as modelBrandFor, t as ModelBrandStack } from "./model-brand-hMyDTUqB.js";
|
|
3
3
|
import { a as formatPrice, i as PricingPage, n as SandboxPageShell, o as BillingDashboard, r as UsageChart, t as DashboardPageHeader } from "./page-layout-2IRtfx51.js";
|
|
4
4
|
export { ActivityFeed, BackendSelector, BillingDashboard, DashboardLayout, DashboardPageHeader, GitPanel, HARNESS_BRAND, HARNESS_OPTIONS, HarnessLogo, HarnessPicker, INSUFFICIENT_BALANCE_CODE, MetricAreaChart, ModelBrandStack, NewSandboxCard, OutOfCreditsModal, PortsList, PricingPage, ProcessList, ProfileAvatar, PromoBanner, RailButton, RailExpandable, RailFlyout, RailHeader, RailModeButton, RailSeparator, RailTooltip, ResourceMeter, ResourceSnapshot, SANDBOX_STATUS, SIDEBAR_MOBILE_WIDTH, SIDEBAR_PANEL_WIDTH, SIDEBAR_RAIL_LABELED_WIDTH, SIDEBAR_RAIL_WIDTH, SIDEBAR_TOTAL_WIDTH, SandboxCard, SandboxPageShell, SandboxStatusPill, SandboxTable, Sidebar, SidebarContent, SidebarLayout, SidebarPanel, SidebarPanelContent, SidebarPanelHeader, SidebarProvider, SidebarRail, SidebarRailFooter, SidebarRailNav, SnapshotList, SystemLogsViewer, TemplateCard, UsageChart, UsageSummary, canAdminSandbox, canonicalModelId, chatCapableHarnesses, formatPrice, modelBrandFor, parseInsufficientBalance, sandboxStatus, useSidebar };
|
package/dist/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { a as computeDiffStats, c as BRAND_PRISM_THEME, d as DiffStatsBadge, f as GitStatusBadge, i as buildUnifiedPatch, l as CodeSurface, m as PillTabs, n as SandboxArtifactPane, o as CodeView, p as PanelHeader, r as DiffView, s as FileBreadcrumb, t as ChangesPane, u as resolveLanguage } from "./workbench-
|
|
1
|
+
import { a as computeDiffStats, c as BRAND_PRISM_THEME, d as DiffStatsBadge, f as GitStatusBadge, i as buildUnifiedPatch, l as CodeSurface, m as PillTabs, n as SandboxArtifactPane, o as CodeView, p as PanelHeader, r as DiffView, s as FileBreadcrumb, t as ChangesPane, u as resolveLanguage } from "./workbench-C6h_DkVv.js";
|
|
2
2
|
import { $ as DialogClose, $n as formatCalendarDate, $t as SelectSeparator, A as Chip, An as Tabs, At as Input, B as ContextMenuLabel, Bn as Textarea, Bt as PopoverContent, C as Card, Cn as TableBody, Ct as DropdownMenuTrigger, D as CardHeader, Dn as TableHead, Dt as HelpText, E as CardFooter, En as TableFooter, Et as Heading, F as ContextMenu, Ft as PageShell, G as ContextMenuShortcut, Gn as Toolbar, Gt as SegmentedControl, H as ContextMenuRadioGroup, Hn as TimeSelect, Ht as Progress, I as ContextMenuCheckboxItem, In as TerminalDisplay, It as Pagination, J as ContextMenuSubTrigger, Jn as TooltipProvider, Jt as SelectGroup, K as ContextMenuSub, Kn as Tooltip, Kt as Select, L as ContextMenuContent, Lt as Popover, M as Collapsible, Mn as TabsList, Mt as Metric, N as CollapsibleContent, Nn as TabsTrigger, Nt as MetricStrip, O as CardTitle, On as TableHeader, Ot as IconTile, P as CollapsibleTrigger, Pn as Tag, Pt as PageHeader, Q as Dialog, Qn as buttonVariants, Qt as SelectScrollUpButton, R as ContextMenuGroup, Rt as PopoverAnchor, S as Calendar, Sn as Table, St as DropdownMenuSubTrigger, T as CardDescription, Tn as TableCell, Tt as FilterField, U as ContextMenuRadioItem, Un as ToastContainer, Ut as RadioGroup, V as ContextMenuPortal, Vn as ThemeToggle, Vt as PopoverTrigger, W as ContextMenuSeparator, Wn as ToastProvider, Wt as RadioGroupItem, X as CopyButton, Xn as UploadProgress, Xt as SelectLabel, Y as ContextMenuTrigger, Yn as TooltipTrigger, Yt as SelectItem, Z as DatePicker, Zn as badgeVariants, Zt as SelectScrollDownButton, _ as AvatarFallback, _n as Slider, _t as DropdownMenuRadioItem, a as AlertDialogCancel, an as SheetContent, ar as useToast, at as DialogPortal, b as Button, bn as Switch, bt as DropdownMenuSub, c as AlertDialogFooter, cn as SheetHeader, cr as TangleKnot, ct as DropZone, d as AlertDialogPortal, dn as SheetTitle, dt as DropdownMenuContent, en as SelectTrigger, er as initialsOf, et as DialogContent, f as AlertDialogTitle, fn as SheetTrigger, ft as DropdownMenuGroup, g as Avatar, gn as SkeletonTable, gt as DropdownMenuRadioGroup, hn as SkeletonCard, ht as DropdownMenuPortal, i as AlertDialogAction, in as SheetClose, ir as useTheme, it as DialogOverlay, j as CodeBlock, jn as TabsContent, jt as Label, k as Checkbox, kn as TableRow, kt as InlineCode, l as AlertDialogHeader, ln as SheetOverlay, lt as DropdownMenu, m as AlertTitle, mn as Skeleton, mt as DropdownMenuLabel, n as AlertDescription, nn as Separator, nr as parseCalendarDate, nt as DialogFooter, o as AlertDialogContent, on as SheetDescription, or as SectionTitle, ot as DialogTitle, p as AlertDialogTrigger, pn as SidebarDropZone, pt as DropdownMenuItem, q as ContextMenuSubContent, qn as TooltipContent, qt as SelectContent, r as AlertDialog, rn as Sheet, rr as toneFor, rt as DialogHeader, s as AlertDialogDescription, sn as SheetFooter, sr as Logo, st as DialogTrigger, t as Alert, tn as SelectValue, tr as localToday, tt as DialogDescription, u as AlertDialogOverlay, un as SheetPortal, ut as DropdownMenuCheckboxItem, v as AvatarImage, vn as StatCard, vt as DropdownMenuSeparator, w as CardContent, wn as TableCaption, wt as EmptyState, x as CATEGORY_TONES, xn as TONE_CLASSES, xt as DropdownMenuSubContent, y as Badge, yn as StatusPill, yt as DropdownMenuShortcut, z as ContextMenuItem, zn as TextShimmer, zt as PopoverClose } from "./primitives-KFAPbGBD.js";
|
|
3
3
|
import { t as WorkspacePaneHeader } from "./workspace-pane-header-Bg1cCcHX.js";
|
|
4
4
|
import { _ as StatusBar, a as TaskBoard, b as WorkspaceLayout, c as createShellShouldRevalidate, d as SESSION_CREATED_EVENT, f as dispatchSessionCreated, g as TerminalPanel, h as RuntimePane, i as CalendarView, l as shellShouldRevalidate, m as formatRelativeAge, n as WorkspaceFilesPane, o as SandboxWorkbench, p as useOptimisticSessionItems, r as ApprovalQueue, s as WorkspaceArtifactView, t as ArtifactPane, u as SessionSidebar, v as StatusBanner, y as DirectoryPane } from "./workspace-DLlilck6.js";
|
|
5
5
|
import { i as VaultTree, n as filterFileNodes, r as VAULT_TREE_CHILD_PAGE, t as fileTreeFromPaths } from "./tree-data-DtoCNNBJ.js";
|
|
6
|
-
import { $ as useSidebar, A as parseInsufficientBalance, B as SidebarPanel, C as SandboxStatusPill, D as ResourceMeter, E as ResourceSnapshot, F as RailHeader, G as SidebarRailNav, H as SidebarPanelHeader, I as RailModeButton, J as SIDEBAR_PANEL_WIDTH, K as RailTooltip, L as RailSeparator, M as RailButton, N as RailExpandable, O as INSUFFICIENT_BALANCE_CODE, P as RailFlyout, Q as SidebarProvider, R as Sidebar, S as SANDBOX_STATUS, T as ActivityFeed, U as SidebarRail, V as SidebarPanelContent, W as SidebarRailFooter, X as SIDEBAR_RAIL_WIDTH, Y as SIDEBAR_RAIL_LABELED_WIDTH, Z as SIDEBAR_TOTAL_WIDTH, _ as BackendSelector, a as PortsList, b as SandboxCard, c as SystemLogsViewer, d as DashboardLayout, f as HARNESS_OPTIONS, g as HarnessLogo, h as HARNESS_BRAND, i as TemplateCard, j as ProfileAvatar, k as OutOfCreditsModal, l as MetricAreaChart, m as chatCapableHarnesses, n as SnapshotList, o as GitPanel, p as HarnessPicker, q as SIDEBAR_MOBILE_WIDTH, r as ProcessList, s as UsageSummary, t as PromoBanner, u as SidebarLayout, v as SandboxTable, w as sandboxStatus, x as canAdminSandbox, y as NewSandboxCard, z as SidebarContent } from "./dashboard-
|
|
6
|
+
import { $ as useSidebar, A as parseInsufficientBalance, B as SidebarPanel, C as SandboxStatusPill, D as ResourceMeter, E as ResourceSnapshot, F as RailHeader, G as SidebarRailNav, H as SidebarPanelHeader, I as RailModeButton, J as SIDEBAR_PANEL_WIDTH, K as RailTooltip, L as RailSeparator, M as RailButton, N as RailExpandable, O as INSUFFICIENT_BALANCE_CODE, P as RailFlyout, Q as SidebarProvider, R as Sidebar, S as SANDBOX_STATUS, T as ActivityFeed, U as SidebarRail, V as SidebarPanelContent, W as SidebarRailFooter, X as SIDEBAR_RAIL_WIDTH, Y as SIDEBAR_RAIL_LABELED_WIDTH, Z as SIDEBAR_TOTAL_WIDTH, _ as BackendSelector, a as PortsList, b as SandboxCard, c as SystemLogsViewer, d as DashboardLayout, f as HARNESS_OPTIONS, g as HarnessLogo, h as HARNESS_BRAND, i as TemplateCard, j as ProfileAvatar, k as OutOfCreditsModal, l as MetricAreaChart, m as chatCapableHarnesses, n as SnapshotList, o as GitPanel, p as HarnessPicker, q as SIDEBAR_MOBILE_WIDTH, r as ProcessList, s as UsageSummary, t as PromoBanner, u as SidebarLayout, v as SandboxTable, w as sandboxStatus, x as canAdminSandbox, y as NewSandboxCard, z as SidebarContent } from "./dashboard-CGtJ8Q_h.js";
|
|
7
7
|
import { n as canonicalModelId, r as modelBrandFor, t as ModelBrandStack } from "./model-brand-hMyDTUqB.js";
|
|
8
8
|
import { a as formatPrice, i as PricingPage, n as SandboxPageShell, o as BillingDashboard, r as UsageChart, t as DashboardPageHeader } from "./page-layout-2IRtfx51.js";
|
|
9
9
|
import { t as usePtySession } from "./use-pty-session-Bf4hBLXJ.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as cn$1 } from "./utils-DzWbktWG.js";
|
|
2
|
-
import { a as PortsList } from "./dashboard-
|
|
2
|
+
import { a as PortsList } from "./dashboard-CGtJ8Q_h.js";
|
|
3
3
|
import { n as TerminalView } from "./terminal-DmSUfGha.js";
|
|
4
4
|
import { RichFileTree } from "./files.js";
|
|
5
5
|
import { n as PreviewView } from "./embedded-app-view-CMRPEvon.js";
|
package/dist/workbench.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { a as computeDiffStats, c as BRAND_PRISM_THEME, d as DiffStatsBadge, f as GitStatusBadge, i as buildUnifiedPatch, l as CodeSurface, m as PillTabs, n as SandboxArtifactPane, o as CodeView, p as PanelHeader, r as DiffView, s as FileBreadcrumb, t as ChangesPane, u as resolveLanguage } from "./workbench-
|
|
1
|
+
import { a as computeDiffStats, c as BRAND_PRISM_THEME, d as DiffStatsBadge, f as GitStatusBadge, i as buildUnifiedPatch, l as CodeSurface, m as PillTabs, n as SandboxArtifactPane, o as CodeView, p as PanelHeader, r as DiffView, s as FileBreadcrumb, t as ChangesPane, u as resolveLanguage } from "./workbench-C6h_DkVv.js";
|
|
2
2
|
import { n as PreviewView, t as EmbeddedAppView } from "./embedded-app-view-CMRPEvon.js";
|
|
3
3
|
export { BRAND_PRISM_THEME, ChangesPane, CodeSurface, CodeView, DiffStatsBadge, DiffView, EmbeddedAppView, FileBreadcrumb, GitStatusBadge, PanelHeader, PillTabs, PreviewView, SandboxArtifactPane, buildUnifiedPatch, computeDiffStats, resolveLanguage };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tangle-network/sandbox-ui",
|
|
3
|
-
"version": "0.132.
|
|
3
|
+
"version": "0.132.3",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Unified UI component library for Tangle Sandbox — primitives, chat, dashboard, terminal, editor, and workspace components",
|
|
6
6
|
"repository": {
|