orbital-ds 0.48.0 → 0.50.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/AGENTS.md +13 -4
- package/CHANGELOG.md +31 -0
- package/README.md +1 -1
- package/components.manifest.json +383 -37
- package/dist/auth-form-B1hgbXkI.d.ts +144 -0
- package/dist/hooks/use-ds-messages.d.ts +598 -0
- package/dist/hooks/use-ds-motion.d.ts +17 -0
- package/dist/hooks/use-esc-close-stack.d.ts +3 -0
- package/dist/hooks/use-in-view.d.ts +9 -0
- package/dist/hooks/use-mobile.d.ts +3 -0
- package/dist/hooks/use-simulated-progress.d.ts +11 -0
- package/dist/lib/a2ui-catalog.d.ts +42 -0
- package/dist/lib/a2ui.d.ts +289 -0
- package/dist/lib/ai-events.d.ts +15 -0
- package/dist/lib/auth-better-auth.d.ts +29 -0
- package/dist/lib/auth-flow.d.ts +85 -0
- package/dist/lib/auth-providers.d.ts +194 -0
- package/dist/lib/auth.d.ts +68 -0
- package/dist/lib/brand-allowlist.d.ts +3 -0
- package/dist/lib/brand-allowlist.js +16 -0
- package/dist/lib/brand-runtime.d.ts +52 -0
- package/dist/lib/echarts-presets.d.ts +307 -0
- package/dist/lib/echarts-server.d.ts +15 -0
- package/dist/lib/echarts-setup.d.ts +8 -0
- package/dist/lib/echarts-theme.d.ts +36 -0
- package/dist/lib/format.d.ts +57 -0
- package/dist/lib/header-control.d.ts +4 -0
- package/dist/lib/i18n.d.ts +611 -0
- package/dist/lib/i18n.js +162 -3
- package/dist/lib/image-upload.d.ts +41 -0
- package/dist/lib/locales/de.d.ts +7 -0
- package/dist/lib/locales/de.js +54 -1
- package/dist/lib/locales/fr.d.ts +7 -0
- package/dist/lib/locales/fr.js +54 -1
- package/dist/lib/locales/he.d.ts +7 -0
- package/dist/lib/locales/he.js +54 -1
- package/dist/lib/locales/it.d.ts +7 -0
- package/dist/lib/locales/it.js +54 -1
- package/dist/lib/motion.d.ts +74 -0
- package/dist/lib/presets.d.ts +8 -0
- package/dist/lib/template-syntax.d.ts +22 -0
- package/dist/lib/utils.d.ts +5 -0
- package/dist/motion.css +146 -0
- package/dist/styles.css +1819 -0
- package/dist/themes/chocolate.css +259 -0
- package/dist/themes/chocolate.fonts.css +2 -0
- package/dist/themes/chocolate.guide.md +30 -0
- package/dist/themes/chocolate.meta.json +61 -0
- package/dist/themes/chocolate.scoped.css +259 -0
- package/dist/themes/chocolate.tokens.json +49 -0
- package/dist/themes/fractalia.css +556 -0
- package/dist/themes/fractalia.fonts.css +3 -0
- package/dist/themes/fractalia.guide.md +86 -0
- package/dist/themes/fractalia.meta.json +112 -0
- package/dist/themes/fractalia.scoped.css +556 -0
- package/dist/themes/fractalia.tokens.json +39 -0
- package/dist/themes/friendly.css +375 -0
- package/dist/themes/friendly.fonts.css +2 -0
- package/dist/themes/friendly.guide.md +38 -0
- package/dist/themes/friendly.meta.json +82 -0
- package/dist/themes/friendly.scoped.css +375 -0
- package/dist/themes/friendly.tokens.json +45 -0
- package/dist/themes/lagoon.css +362 -0
- package/dist/themes/lagoon.fonts.css +2 -0
- package/dist/themes/lagoon.guide.md +47 -0
- package/dist/themes/lagoon.meta.json +85 -0
- package/dist/themes/lagoon.scoped.css +362 -0
- package/dist/themes/lagoon.tokens.json +49 -0
- package/dist/themes/liquid.css +510 -0
- package/dist/themes/liquid.fonts.css +7 -0
- package/dist/themes/liquid.guide.md +82 -0
- package/dist/themes/liquid.meta.json +134 -0
- package/dist/themes/liquid.scoped.css +510 -0
- package/dist/themes/liquid.tokens.json +47 -0
- package/dist/themes/matcha.css +259 -0
- package/dist/themes/matcha.fonts.css +2 -0
- package/dist/themes/matcha.guide.md +30 -0
- package/dist/themes/matcha.meta.json +61 -0
- package/dist/themes/matcha.scoped.css +259 -0
- package/dist/themes/matcha.tokens.json +49 -0
- package/dist/themes/qratia.css +264 -0
- package/dist/themes/qratia.fonts.css +2 -0
- package/dist/themes/qratia.guide.md +34 -0
- package/dist/themes/qratia.meta.json +49 -0
- package/dist/themes/qratia.scoped.css +264 -0
- package/dist/themes/qratia.tokens.json +49 -0
- package/dist/themes/stone.css +263 -0
- package/dist/themes/stone.fonts.css +2 -0
- package/dist/themes/stone.guide.md +30 -0
- package/dist/themes/stone.meta.json +47 -0
- package/dist/themes/stone.scoped.css +263 -0
- package/dist/themes/stone.tokens.json +49 -0
- package/dist/themes/tactile.css +591 -0
- package/dist/themes/tactile.fonts.css +3 -0
- package/dist/themes/tactile.guide.md +82 -0
- package/dist/themes/tactile.meta.json +182 -0
- package/dist/themes/tactile.scoped.css +591 -0
- package/dist/themes/tactile.tokens.json +42 -0
- package/dist/themes/twitter.css +364 -0
- package/dist/themes/twitter.fonts.css +6 -0
- package/dist/themes/twitter.guide.md +35 -0
- package/dist/themes/twitter.meta.json +90 -0
- package/dist/themes/twitter.scoped.css +364 -0
- package/dist/themes/twitter.tokens.json +45 -0
- package/dist/themes/y2k.css +259 -0
- package/dist/themes/y2k.fonts.css +2 -0
- package/dist/themes/y2k.guide.md +30 -0
- package/dist/themes/y2k.meta.json +59 -0
- package/dist/themes/y2k.scoped.css +259 -0
- package/dist/themes/y2k.tokens.json +49 -0
- package/dist/themes/zyro.css +442 -0
- package/dist/themes/zyro.fonts.css +2 -0
- package/dist/themes/zyro.guide.md +33 -0
- package/dist/themes/zyro.meta.json +74 -0
- package/dist/themes/zyro.scoped.css +442 -0
- package/dist/themes/zyro.tokens.json +46 -0
- package/dist/ui/a2ui-renderer.d.ts +44 -0
- package/dist/ui/accordion.d.ts +9 -0
- package/dist/ui/agent-events.d.ts +49 -0
- package/dist/ui/ai-tag.d.ts +24 -0
- package/dist/ui/alert-dialog.d.ts +60 -0
- package/dist/ui/alert.d.ts +13 -0
- package/dist/ui/animated-number.d.ts +20 -0
- package/dist/ui/api-key-list.d.ts +40 -0
- package/dist/ui/api-key-list.js +89 -0
- package/dist/ui/app-bar.d.ts +32 -0
- package/dist/ui/aspect-ratio.d.ts +7 -0
- package/dist/ui/attachment.d.ts +26 -0
- package/dist/ui/audit-log.d.ts +53 -0
- package/dist/ui/audit-log.js +102 -0
- package/dist/ui/auth-backdrop.d.ts +37 -0
- package/dist/ui/auth-form.d.ts +4 -0
- package/dist/ui/auth-layout.d.ts +110 -0
- package/dist/ui/auth-parts.d.ts +43 -0
- package/dist/ui/auth-status.d.ts +23 -0
- package/dist/ui/avatar.d.ts +43 -0
- package/dist/ui/ayuda.d.ts +22 -0
- package/dist/ui/badge.d.ts +15 -0
- package/dist/ui/banner.d.ts +14 -0
- package/dist/ui/bottom-nav.d.ts +37 -0
- package/dist/ui/breadcrumb.d.ts +34 -0
- package/dist/ui/bubble.d.ts +19 -0
- package/dist/ui/button-group.d.ts +15 -0
- package/dist/ui/button.d.ts +14 -0
- package/dist/ui/calendar.d.ts +28 -0
- package/dist/ui/card-stack.d.ts +36 -0
- package/dist/ui/card.d.ts +61 -0
- package/dist/ui/carousel.d.ts +68 -0
- package/dist/ui/chain-of-thought.d.ts +34 -0
- package/dist/ui/chart-card.d.ts +46 -0
- package/dist/ui/chat-composer.d.ts +58 -0
- package/dist/ui/checkbox.d.ts +6 -0
- package/dist/ui/choice-card.d.ts +49 -0
- package/dist/ui/code-block.d.ts +29 -0
- package/dist/ui/collapsible.d.ts +8 -0
- package/dist/ui/combobox.d.ts +74 -0
- package/dist/ui/command-palette.d.ts +54 -0
- package/dist/ui/command.d.ts +56 -0
- package/dist/ui/confirm-action.d.ts +48 -0
- package/dist/ui/confirm-dialog.d.ts +44 -0
- package/dist/ui/connected-accounts.d.ts +25 -0
- package/dist/ui/content-card.d.ts +66 -0
- package/dist/ui/context-menu.d.ts +66 -0
- package/dist/ui/conversation-list.d.ts +44 -0
- package/dist/ui/copy-button.d.ts +25 -0
- package/dist/ui/cta-banner.d.ts +30 -0
- package/dist/ui/data-table.d.ts +198 -0
- package/dist/ui/date-picker.d.ts +65 -0
- package/dist/ui/date-time.d.ts +40 -0
- package/dist/ui/description-list.d.ts +49 -0
- package/dist/ui/detail-panel.d.ts +40 -0
- package/dist/ui/dialog.d.ts +54 -0
- package/dist/ui/direction.d.ts +1 -0
- package/dist/ui/dock.d.ts +30 -0
- package/dist/ui/drawer.d.ts +59 -0
- package/dist/ui/dropdown-menu.d.ts +63 -0
- package/dist/ui/dropzone.d.ts +44 -0
- package/dist/ui/echart.d.ts +46 -0
- package/dist/ui/empty-state.d.ts +26 -0
- package/dist/ui/empty.d.ts +15 -0
- package/dist/ui/entity-list.d.ts +57 -0
- package/dist/ui/error-page.d.ts +28 -0
- package/dist/ui/error-state.d.ts +16 -0
- package/dist/ui/eyebrow.d.ts +7 -0
- package/dist/ui/faq.d.ts +34 -0
- package/dist/ui/feature-grid.d.ts +40 -0
- package/dist/ui/field.d.ts +28 -0
- package/dist/ui/file-upload.d.ts +42 -0
- package/dist/ui/filter-bar.d.ts +38 -0
- package/dist/ui/form-layout.d.ts +43 -0
- package/dist/ui/gauge.d.ts +66 -0
- package/dist/ui/generated-image.d.ts +33 -0
- package/dist/ui/generated-table.d.ts +29 -0
- package/dist/ui/heatmap-grid.d.ts +59 -0
- package/dist/ui/hero.d.ts +58 -0
- package/dist/ui/hover-card.d.ts +8 -0
- package/dist/ui/i18n-provider.d.ts +27 -0
- package/dist/ui/icon-tile.d.ts +11 -0
- package/dist/ui/input-group.d.ts +22 -0
- package/dist/ui/input-otp.d.ts +36 -0
- package/dist/ui/input.d.ts +21 -0
- package/dist/ui/instruction-editor.d.ts +81 -0
- package/dist/ui/item.d.ts +26 -0
- package/dist/ui/kbd.d.ts +6 -0
- package/dist/ui/label.d.ts +22 -0
- package/dist/ui/landing-section.d.ts +34 -0
- package/dist/ui/legend.d.ts +57 -0
- package/dist/ui/level-meter.d.ts +28 -0
- package/dist/ui/load-more.d.ts +36 -0
- package/dist/ui/loading-state.d.ts +26 -0
- package/dist/ui/locale-switcher.d.ts +19 -0
- package/dist/ui/markdown.d.ts +29 -0
- package/dist/ui/marker.d.ts +13 -0
- package/dist/ui/media-card.d.ts +29 -0
- package/dist/ui/member-list.d.ts +43 -0
- package/dist/ui/member-list.js +107 -0
- package/dist/ui/menubar.d.ts +70 -0
- package/dist/ui/message-actions.d.ts +21 -0
- package/dist/ui/message-scroller.d.ts +46 -0
- package/dist/ui/message.d.ts +45 -0
- package/dist/ui/mfa-challenge.d.ts +4 -0
- package/dist/ui/mfa-setup.d.ts +29 -0
- package/dist/ui/mosaic.d.ts +38 -0
- package/dist/ui/motion-provider.d.ts +28 -0
- package/dist/ui/native-select.d.ts +32 -0
- package/dist/ui/navigation-menu.d.ts +15 -0
- package/dist/ui/next-step-card.d.ts +55 -0
- package/dist/ui/notice-review.d.ts +64 -0
- package/dist/ui/notifications.d.ts +81 -0
- package/dist/ui/oauth-consent.d.ts +54 -0
- package/dist/ui/onboarding-checklist.d.ts +38 -0
- package/dist/ui/onboarding-checklist.js +132 -0
- package/dist/ui/page-header.d.ts +64 -0
- package/dist/ui/page-loader.d.ts +40 -0
- package/dist/ui/page-shell.d.ts +25 -0
- package/dist/ui/pagination.d.ts +42 -0
- package/dist/ui/panel.d.ts +12 -0
- package/dist/ui/passkey-list.d.ts +17 -0
- package/dist/ui/password-input.d.ts +5 -0
- package/dist/ui/password-strength.d.ts +28 -0
- package/dist/ui/permission-matrix.d.ts +35 -0
- package/dist/ui/permission-matrix.js +89 -0
- package/dist/ui/plan-summary.d.ts +59 -0
- package/dist/ui/plan-summary.js +92 -0
- package/dist/ui/popover.d.ts +44 -0
- package/dist/ui/pricing-table.d.ts +29 -0
- package/dist/ui/progress.d.ts +9 -0
- package/dist/ui/proportion-bar.d.ts +52 -0
- package/dist/ui/quantity.d.ts +25 -0
- package/dist/ui/questionnaire.d.ts +62 -0
- package/dist/ui/radio-group.d.ts +8 -0
- package/dist/ui/reasoning.d.ts +24 -0
- package/dist/ui/resizable.d.ts +10 -0
- package/dist/ui/reveal.d.ts +28 -0
- package/dist/ui/scroll-area.d.ts +7 -0
- package/dist/ui/search-box.d.ts +32 -0
- package/dist/ui/select.d.ts +19 -0
- package/dist/ui/separator.d.ts +6 -0
- package/dist/ui/session-list.d.ts +19 -0
- package/dist/ui/session-timeout.d.ts +13 -0
- package/dist/ui/sheet.d.ts +53 -0
- package/dist/ui/shield.d.ts +35 -0
- package/dist/ui/show-more.d.ts +26 -0
- package/dist/ui/sidebar.d.ts +92 -0
- package/dist/ui/sign-out-dialog.d.ts +17 -0
- package/dist/ui/skeleton.d.ts +10 -0
- package/dist/ui/slider.d.ts +23 -0
- package/dist/ui/sparkline.d.ts +26 -0
- package/dist/ui/spinner.d.ts +5 -0
- package/dist/ui/stat-group.d.ts +40 -0
- package/dist/ui/stat.d.ts +90 -0
- package/dist/ui/status-badge.d.ts +39 -0
- package/dist/ui/status-hero.d.ts +30 -0
- package/dist/ui/step-dots.d.ts +22 -0
- package/dist/ui/step-flow.d.ts +48 -0
- package/dist/ui/step-ring.d.ts +26 -0
- package/dist/ui/stepper.d.ts +20 -0
- package/dist/ui/suggestions.d.ts +17 -0
- package/dist/ui/switch.d.ts +8 -0
- package/dist/ui/table.d.ts +38 -0
- package/dist/ui/tabs.d.ts +14 -0
- package/dist/ui/tag-input.d.ts +21 -0
- package/dist/ui/task-loader.d.ts +29 -0
- package/dist/ui/task-progress.d.ts +32 -0
- package/dist/ui/testimonial.d.ts +37 -0
- package/dist/ui/textarea.d.ts +32 -0
- package/dist/ui/theme-toggle.d.ts +14 -0
- package/dist/ui/timeline.d.ts +55 -0
- package/dist/ui/toast.d.ts +19 -0
- package/dist/ui/toggle-group.d.ts +38 -0
- package/dist/ui/toggle.d.ts +12 -0
- package/dist/ui/tool-call.d.ts +27 -0
- package/dist/ui/tooltip.d.ts +9 -0
- package/dist/ui/upgrade-prompt.d.ts +24 -0
- package/dist/ui/upgrade-prompt.js +85 -0
- package/dist/ui/usage-meter.d.ts +42 -0
- package/dist/ui/week-strip.d.ts +23 -0
- package/dist/ui/workflow-run.d.ts +51 -0
- package/dist/ui/workspace-switcher.d.ts +28 -0
- package/dist/ui/workspace-switcher.js +92 -0
- package/docs/GRAFICOS.md +1 -1
- package/docs/designer/patrones.md +29 -1
- package/manifest/actions.json +1 -1
- package/manifest/agents.json +1 -1
- package/manifest/ai.json +1 -1
- package/manifest/auth.json +1 -1
- package/manifest/chat.json +1 -1
- package/manifest/content.json +1 -1
- package/manifest/data.json +498 -1
- package/manifest/feedback.json +230 -43
- package/manifest/forms.json +1 -1
- package/manifest/motion.json +1 -1
- package/manifest/navigation.json +102 -1
- package/manifest/overlays.json +2 -2
- package/package.json +1 -11
- package/scripts/cli.mjs +63 -5
- package/scripts/doctor.mjs +5 -3
- package/scripts/skill.mjs +85 -0
- package/skill/SKILL.md +5 -2
- package/dist/ui/sonner.js +0 -60
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @group agents
|
|
5
|
+
* @summary Ejecución de un workflow o automatización ya definida: nodos en orden con estado y duración, ramas en paralelo, progreso y Cancelar o Reintentar.
|
|
6
|
+
* @see chain-of-thought — pasos que decide el agente sobre la marcha, dentro de un mensaje
|
|
7
|
+
* @see agent-events — traza con tiempos de un agente
|
|
8
|
+
* @see stepper — pasos de un proceso que recorre la persona
|
|
9
|
+
* @example Ejecución con una rama en paralelo
|
|
10
|
+
* <WorkflowRun
|
|
11
|
+
* name="Resumir incidencias"
|
|
12
|
+
* status="running"
|
|
13
|
+
* nodes={[
|
|
14
|
+
* { id: "fetch", title: "Leer incidencias", status: "done", duration: "1,2 s" },
|
|
15
|
+
* {
|
|
16
|
+
* id: "classify",
|
|
17
|
+
* title: "Clasificar",
|
|
18
|
+
* status: "running",
|
|
19
|
+
* branches: [
|
|
20
|
+
* { id: "client", title: "Por cliente", status: "done" },
|
|
21
|
+
* { id: "severity", title: "Por gravedad", status: "running" },
|
|
22
|
+
* ],
|
|
23
|
+
* },
|
|
24
|
+
* { id: "send", title: "Enviar resumen", status: "pending" },
|
|
25
|
+
* ]}
|
|
26
|
+
* onCancel={cancel}
|
|
27
|
+
* onRetry={retry}
|
|
28
|
+
* />
|
|
29
|
+
*/
|
|
30
|
+
|
|
31
|
+
type WorkflowNodeStatus = "pending" | "running" | "done" | "error" | "skipped";
|
|
32
|
+
type WorkflowRunStatus = "running" | "succeeded" | "failed" | "cancelled";
|
|
33
|
+
interface WorkflowNode {
|
|
34
|
+
id: string;
|
|
35
|
+
title: React.ReactNode;
|
|
36
|
+
description?: React.ReactNode;
|
|
37
|
+
status?: WorkflowNodeStatus;
|
|
38
|
+
/** Duración ya formateada («1,2 s»); la pone la app. */
|
|
39
|
+
duration?: string;
|
|
40
|
+
/** Ramas que corren a la vez bajo este nodo. */
|
|
41
|
+
branches?: WorkflowNode[];
|
|
42
|
+
}
|
|
43
|
+
declare function WorkflowRun({ name, status, nodes, onCancel, onRetry, className, ...props }: Omit<React.ComponentProps<"section">, "children"> & {
|
|
44
|
+
name: React.ReactNode;
|
|
45
|
+
status?: WorkflowRunStatus;
|
|
46
|
+
nodes: WorkflowNode[];
|
|
47
|
+
onCancel?: () => void;
|
|
48
|
+
onRetry?: () => void;
|
|
49
|
+
}): React.JSX.Element;
|
|
50
|
+
|
|
51
|
+
export { type WorkflowNode, type WorkflowNodeStatus, WorkflowRun, type WorkflowRunStatus };
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
type WorkspaceSwitcherPreset = "sidebar" | "menu" | "compact";
|
|
4
|
+
type WorkspaceInfo = {
|
|
5
|
+
id: string;
|
|
6
|
+
name: string;
|
|
7
|
+
/** Plan o rol, como texto de apoyo («Pro», «Administración»). */
|
|
8
|
+
plan?: React.ReactNode;
|
|
9
|
+
/** URL del logo. */
|
|
10
|
+
logo?: string;
|
|
11
|
+
disabled?: boolean;
|
|
12
|
+
};
|
|
13
|
+
type WorkspaceSwitcherProps = {
|
|
14
|
+
preset?: WorkspaceSwitcherPreset;
|
|
15
|
+
workspaces: WorkspaceInfo[];
|
|
16
|
+
value: string;
|
|
17
|
+
onValueChange: (id: string) => void;
|
|
18
|
+
/** Añade «Crear espacio de trabajo» al final. */
|
|
19
|
+
onCreate?: () => void;
|
|
20
|
+
/** Elementos propios al final del menú (DropdownMenuItem: ajustes del espacio…). */
|
|
21
|
+
footer?: React.ReactNode;
|
|
22
|
+
/** Lado del menú respecto al disparador. */
|
|
23
|
+
align?: "start" | "center" | "end";
|
|
24
|
+
className?: string;
|
|
25
|
+
};
|
|
26
|
+
declare function WorkspaceSwitcher({ preset, workspaces, value, onValueChange, onCreate, footer, align, className }: WorkspaceSwitcherProps): React.JSX.Element;
|
|
27
|
+
|
|
28
|
+
export { type WorkspaceInfo, WorkspaceSwitcher, type WorkspaceSwitcherPreset, type WorkspaceSwitcherProps };
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { ChevronsUpDownIcon, PlusIcon } from "lucide-react";
|
|
4
|
+
import { useDsMessages } from "../hooks/use-ds-messages.js";
|
|
5
|
+
import { dsFormat } from "../lib/i18n.js";
|
|
6
|
+
import { cn } from "../lib/utils.js";
|
|
7
|
+
import {
|
|
8
|
+
DropdownMenu,
|
|
9
|
+
DropdownMenuContent,
|
|
10
|
+
DropdownMenuGroup,
|
|
11
|
+
DropdownMenuItem,
|
|
12
|
+
DropdownMenuLabel,
|
|
13
|
+
DropdownMenuRadioGroup,
|
|
14
|
+
DropdownMenuRadioItem,
|
|
15
|
+
DropdownMenuSeparator,
|
|
16
|
+
DropdownMenuTrigger
|
|
17
|
+
} from "./dropdown-menu.js";
|
|
18
|
+
function WorkspaceLogo({ workspace, className }) {
|
|
19
|
+
return /* @__PURE__ */ jsx(
|
|
20
|
+
"span",
|
|
21
|
+
{
|
|
22
|
+
"data-slot": "workspace-switcher-logo",
|
|
23
|
+
"aria-hidden": "true",
|
|
24
|
+
className: cn(
|
|
25
|
+
"flex size-(--ds-workspace-logo) shrink-0 items-center justify-center overflow-hidden rounded-control bg-primary text-xs font-(--ds-medium-weight) text-primary-foreground [&_img]:size-full [&_img]:object-cover",
|
|
26
|
+
className
|
|
27
|
+
),
|
|
28
|
+
children: workspace?.logo ? /* @__PURE__ */ jsx("img", { src: workspace.logo, alt: "" }) : workspace?.name.trim()[0]?.toUpperCase() ?? ""
|
|
29
|
+
}
|
|
30
|
+
);
|
|
31
|
+
}
|
|
32
|
+
function WorkspaceSwitcher({ preset = "sidebar", workspaces, value, onValueChange, onCreate, footer, align, className }) {
|
|
33
|
+
const t = useDsMessages();
|
|
34
|
+
const current = workspaces.find((w) => w.id === value);
|
|
35
|
+
const label = current ? dsFormat(t.workspaceCurrent, { name: current.name }) : t.workspaceSwitch;
|
|
36
|
+
const trigger = preset === "compact" ? /* @__PURE__ */ jsx(
|
|
37
|
+
"button",
|
|
38
|
+
{
|
|
39
|
+
type: "button",
|
|
40
|
+
"aria-label": label,
|
|
41
|
+
title: current?.name,
|
|
42
|
+
className: cn(
|
|
43
|
+
"flex items-center justify-center rounded-control p-1 outline-none hover:bg-(--ds-hover-bg) focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-(--ds-ring-color) data-popup-open:bg-(--ds-active-bg)",
|
|
44
|
+
className
|
|
45
|
+
)
|
|
46
|
+
}
|
|
47
|
+
) : /* @__PURE__ */ jsx(
|
|
48
|
+
"button",
|
|
49
|
+
{
|
|
50
|
+
type: "button",
|
|
51
|
+
"aria-label": label,
|
|
52
|
+
className: cn(
|
|
53
|
+
"flex min-w-0 items-center gap-2 rounded-control text-start outline-none hover:bg-(--ds-hover-bg) focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-(--ds-ring-color) data-popup-open:bg-(--ds-active-bg)",
|
|
54
|
+
preset === "sidebar" ? "w-full p-2" : "h-(--ds-control-h-md) px-2",
|
|
55
|
+
className
|
|
56
|
+
)
|
|
57
|
+
}
|
|
58
|
+
);
|
|
59
|
+
return /* @__PURE__ */ jsxs(DropdownMenu, { children: [
|
|
60
|
+
/* @__PURE__ */ jsxs(DropdownMenuTrigger, { "data-slot": "workspace-switcher", "data-preset": preset, render: trigger, children: [
|
|
61
|
+
/* @__PURE__ */ jsx(WorkspaceLogo, { workspace: current, className: preset === "menu" ? "size-(--ds-avatar-sm)" : void 0 }),
|
|
62
|
+
preset !== "compact" && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
63
|
+
/* @__PURE__ */ jsxs("span", { "data-slot": "workspace-switcher-trigger", className: "flex min-w-0 flex-1 flex-col", children: [
|
|
64
|
+
/* @__PURE__ */ jsx("span", { className: "truncate text-sm font-(--ds-medium-weight) text-foreground", children: current?.name }),
|
|
65
|
+
preset === "sidebar" && current?.plan != null ? /* @__PURE__ */ jsx("span", { className: "truncate text-xs text-muted-foreground", children: current.plan }) : null
|
|
66
|
+
] }),
|
|
67
|
+
/* @__PURE__ */ jsx(ChevronsUpDownIcon, { "aria-hidden": "true", className: "size-4 shrink-0 text-muted-foreground" })
|
|
68
|
+
] })
|
|
69
|
+
] }),
|
|
70
|
+
/* @__PURE__ */ jsxs(DropdownMenuContent, { align: align ?? "start", side: preset === "compact" ? "inline-end" : "bottom", className: "w-(--ds-workspace-menu-w)", children: [
|
|
71
|
+
/* @__PURE__ */ jsxs(DropdownMenuGroup, { children: [
|
|
72
|
+
/* @__PURE__ */ jsx(DropdownMenuLabel, { children: t.workspaceList }),
|
|
73
|
+
/* @__PURE__ */ jsx(DropdownMenuRadioGroup, { value, onValueChange: (v) => onValueChange(String(v)), children: workspaces.map((w) => /* @__PURE__ */ jsxs(DropdownMenuRadioItem, { value: w.id, disabled: w.disabled, "data-slot": "workspace-switcher-item", children: [
|
|
74
|
+
/* @__PURE__ */ jsx(WorkspaceLogo, { workspace: w, className: "size-(--ds-avatar-sm)" }),
|
|
75
|
+
/* @__PURE__ */ jsxs("span", { className: "flex min-w-0 flex-1 flex-col", children: [
|
|
76
|
+
/* @__PURE__ */ jsx("span", { className: "truncate", children: w.name }),
|
|
77
|
+
w.plan != null ? /* @__PURE__ */ jsx("span", { className: "truncate text-xs text-muted-foreground", children: w.plan }) : null
|
|
78
|
+
] })
|
|
79
|
+
] }, w.id)) })
|
|
80
|
+
] }),
|
|
81
|
+
(onCreate || footer) && /* @__PURE__ */ jsx(DropdownMenuSeparator, {}),
|
|
82
|
+
footer,
|
|
83
|
+
onCreate ? /* @__PURE__ */ jsxs(DropdownMenuItem, { onClick: onCreate, "data-slot": "workspace-switcher-create", children: [
|
|
84
|
+
/* @__PURE__ */ jsx(PlusIcon, { "aria-hidden": "true" }),
|
|
85
|
+
t.workspaceCreate
|
|
86
|
+
] }) : null
|
|
87
|
+
] })
|
|
88
|
+
] });
|
|
89
|
+
}
|
|
90
|
+
export {
|
|
91
|
+
WorkspaceSwitcher
|
|
92
|
+
};
|
package/docs/GRAFICOS.md
CHANGED
|
@@ -9,7 +9,7 @@ automáticamente.
|
|
|
9
9
|
| Pieza | Import | Para qué |
|
|
10
10
|
|---|---|---|
|
|
11
11
|
| `<EChart>` | `orbital-ds/ui/echart` | Gráfico en pantalla, con el tema activo; SVG por defecto; `exportable` descarga SVG o PNG |
|
|
12
|
-
| Presets | `orbital-ds/lib/echarts-presets` | `lineOption`, `barOption`, `comboOption`, `heatmapOption`, `sankeyOption`, `gaugeOption`, `pieOption`, `referenceLine`, `referenceArea` |
|
|
12
|
+
| Presets | `orbital-ds/lib/echarts-presets` | `lineOption`, `barOption`, `comboOption`, `heatmapOption`, `sankeyOption`, `gaugeOption`, `pieOption`, `waterfallOption`, `cohortOption`, `calendarOption`, `graphOption`, `referenceLine`, `referenceArea` |
|
|
13
13
|
| SVG en servidor | `orbital-ds/lib/echarts-server` | `renderEChartToSvg(option, { width, height, tokens })`. Sin DOM: vale en Node, TanStack Start y Cloudflare Workers |
|
|
14
14
|
| Valores del tema | `orbital-ds/themes/<tema>.tokens.json` | Paleta, textos, bordes, superficie, fuentes y ritmo, con los colores ya resueltos. Piel `light` y `dark` |
|
|
15
15
|
| Tema de ECharts | `orbital-ds/lib/echarts-theme` | `dsEchartsThemeFromTokens(tokens)` en el servidor; `dsEchartsTheme()` en el navegador |
|
|
@@ -100,7 +100,8 @@ Formato: **cuándo** · **piezas** · **reglas** · **evita**.
|
|
|
100
100
|
|
|
101
101
|
## P12 · Ajustes
|
|
102
102
|
- **Piezas:** `Tabs` o navegación lateral por secciones; cada sección un `FieldGroup`; `Switch` para lo que se
|
|
103
|
-
aplica al momento y botón «Guardar cambios» para lo que no (nunca mezclados en la misma sección).
|
|
103
|
+
aplica al momento y botón «Guardar cambios» para lo que no (nunca mezclados en la misma sección). En una
|
|
104
|
+
cuenta multiusuario, sus secciones de equipo, permisos, plan, API y actividad siguen P16.
|
|
104
105
|
|
|
105
106
|
## P13 · Acceso (entrar, verificar, sesiones)
|
|
106
107
|
- **Cuándo:** iniciar sesión, registro, recuperar contraseña, segundo factor, consentimiento OAuth/MCP, y la
|
|
@@ -175,6 +176,33 @@ Formato: **cuándo** · **piezas** · **reglas** · **evita**.
|
|
|
175
176
|
- **Evita:** carruseles en la portada, más de dos botones, texto directamente sobre una foto sin placa, títulos con
|
|
176
177
|
degradado y alturas a pantalla completa que esconden el contenido.
|
|
177
178
|
|
|
179
|
+
## P16 · Cuenta y organización (SaaS)
|
|
180
|
+
- **Cuándo:** las vistas de administración de una cuenta multiusuario: primeros pasos, equipo, roles y permisos,
|
|
181
|
+
facturación y plan, claves de API y webhooks, registro de actividad y cambio de espacio de trabajo.
|
|
182
|
+
- **Piezas (una por problema):**
|
|
183
|
+
- Primeros pasos → `OnboardingChecklist` (`card` en el inicio · `sidebar` en el lateral · `page` como vista propia).
|
|
184
|
+
Desaparece al terminar (`onDismiss`); los pasos opcionales no cuentan para el progreso.
|
|
185
|
+
- Equipo → `MemberList` (`team` · `workspace` con actividad e invitaciones aparte · `compact` de solo lectura); el
|
|
186
|
+
rol se cambia en la fila con su `Select`, y quitar a alguien pasa por `ConfirmAction`.
|
|
187
|
+
- Roles y permisos → `PermissionMatrix` (`roles` editable · `review` de solo lectura · `scopes` de un rol o un token);
|
|
188
|
+
el rol propietario va en `lockedRoles`.
|
|
189
|
+
- Plan y facturación → `PlanSummary` (`overview` en la página de facturación · `compact` en ajustes o en el lateral
|
|
190
|
+
· `trial` en la prueba); para elegir otro plan, `PricingTable`; para un solo medidor suelto, `UsageMeter`.
|
|
191
|
+
- Función fuera del plan → `UpgradePrompt` (`inline` junto al control · `card` en una sección · `banner` arriba
|
|
192
|
+
de la página · `overlay` encima de lo bloqueado, que queda inerte).
|
|
193
|
+
- Claves, tokens y webhooks → `ApiKeyList` (`keys` · `tokens` con permisos y caducidad · `webhooks` con salud); el
|
|
194
|
+
secreto recién creado se enseña **una vez** con `revealed`, nunca después.
|
|
195
|
+
- Actividad → `AuditLog` (`full` en la página de auditoría · `compact` en un panel · `entity` en el detalle de un
|
|
196
|
+
recurso); con miles de eventos y filtros, `DataTable`.
|
|
197
|
+
- Espacio de trabajo → `WorkspaceSwitcher` en el `SidebarHeader` (`sidebar`), en la cabecera (`menu`) o en el raíl
|
|
198
|
+
de iconos (`compact`).
|
|
199
|
+
- **Página de ajustes de la cuenta:** P12 con estas piezas, una sección por tema (General · Equipo · Permisos ·
|
|
200
|
+
Facturación · API · Actividad), cada una con `SectionHeader title description actions`.
|
|
201
|
+
- **Reglas:** el texto (nombres de roles, planes, acciones) lo pone la app con su i18n; fechas y cantidades por
|
|
202
|
+
`DateTime`, `RelativeTime` y `Quantity` (ya dentro de las piezas); una acción principal por sección.
|
|
203
|
+
- **Evita:** tablas hechas a mano para miembros o permisos, secretos visibles en la lista, avisos de mejora con
|
|
204
|
+
colores propios o repetidos en cada control, y un selector de espacio hecho con `Select` suelto.
|
|
205
|
+
|
|
178
206
|
---
|
|
179
207
|
|
|
180
208
|
## Patrones de movimiento
|
package/manifest/actions.json
CHANGED
package/manifest/agents.json
CHANGED
package/manifest/ai.json
CHANGED
package/manifest/auth.json
CHANGED
package/manifest/chat.json
CHANGED