@morlay/ui-conversation-manager 0.1.4 → 0.1.5

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/client.cjs CHANGED
@@ -6,6 +6,9 @@ window.__ModuleLoader__.load({
6
6
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
7
7
  //#region \0rolldown/runtime.js
8
8
  var __defProp = Object.defineProperty;
9
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
10
+ var __getOwnPropNames = Object.getOwnPropertyNames;
11
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
9
12
  var __exportAll = (all, no_symbols) => {
10
13
  let target = {};
11
14
  for (var name in all) __defProp(target, name, {
@@ -15,6 +18,17 @@ window.__ModuleLoader__.load({
15
18
  if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
16
19
  return target;
17
20
  };
21
+ var __copyProps = (to, from, except, desc) => {
22
+ if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
23
+ key = keys[i];
24
+ if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
25
+ get: ((k) => from[k]).bind(null, key),
26
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
27
+ });
28
+ }
29
+ return to;
30
+ };
31
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
18
32
  //#endregion
19
33
  let _deepseek_ai_dsh_client_store = require("@deepseek-ai/dsh-client-store");
20
34
  let _deepseek_ai_cordis = require("@deepseek-ai/cordis");
@@ -938,7 +952,7 @@ window.__ModuleLoader__.load({
938
952
  return this.#ns;
939
953
  }
940
954
  refresh() {
941
- this.#store.set(this.#project());
955
+ this.#sync();
942
956
  }
943
957
  dispose() {
944
958
  for (const dispose of this.#disposers.splice(0)) dispose();
@@ -1458,1212 +1472,37 @@ window.__ModuleLoader__.load({
1458
1472
  return prefix.every((segment, index) => path[index] === segment);
1459
1473
  }
1460
1474
  //#endregion
1461
- //#region ../../client/ui-primitives/src/client/styling/toolkit.ts
1462
- function isUndefined(value) {
1463
- return value === void 0;
1464
- }
1465
- function isNull(value) {
1466
- return value === null;
1467
- }
1468
- function isString(value) {
1469
- return typeof value === "string";
1470
- }
1471
- function isFunction(value) {
1472
- return typeof value === "function";
1473
- }
1474
- function isPlainObject(value) {
1475
- return typeof value === "object" && value !== null && !Array.isArray(value);
1476
- }
1477
- function toMerged(target, source) {
1478
- if (!isPlainObject(target) || !isPlainObject(source)) return source;
1479
- const result = { ...target };
1480
- for (const [key, value] of Object.entries(source)) result[key] = key in result ? toMerged(result[key], value) : value;
1481
- return result;
1482
- }
1483
- function mapKeys(source, map) {
1484
- const result = {};
1485
- for (const [key, value] of Object.entries(source)) result[map(key, value)] = value;
1486
- return result;
1487
- }
1488
- //#endregion
1489
- //#region ../../client/ui-primitives/src/client/styling/token.ts
1490
- const cssVarSymbol = Symbol("cssVar");
1491
- const tokensSymbol = Symbol("tokens");
1492
- const tokenInstSymbol = Symbol("tokenInst");
1493
- const SELF = "$";
1494
- function tokenVars(token, tokens, path) {
1495
- const reserved = /* @__PURE__ */ new Set([
1496
- "constructor",
1497
- "toJSON",
1498
- "__proto__"
1499
- ]);
1500
- return new Proxy(() => {}, {
1501
- apply() {
1502
- return Token.fallbackVar(token.cssVar(path));
1503
- },
1504
- get(_target, property) {
1505
- if (property === Symbol.toPrimitive || property === Symbol.toStringTag || property === "toString") return () => `var(${token.cssVar(path)})`;
1506
- if (property === "valueOf") return () => Token.fallbackVar(token.cssVar(path));
1507
- if (property === tokenInstSymbol) return token;
1508
- if (property === tokensSymbol) return tokens;
1509
- if (property === cssVarSymbol) return token.cssVar(path);
1510
- if (!isString(property) || reserved.has(property)) return void 0;
1511
- const next = tokens[property];
1512
- if (isUndefined(next)) return void 0;
1513
- return tokenVars(token, next, [...path, property]);
1514
- }
1515
- });
1516
- }
1517
- var Token = class Token {
1518
- prefix;
1519
- static vars(tokens, options = {}) {
1520
- return tokenVars(new Token(options.prefix ?? ""), tokens, []);
1521
- }
1522
- static extendsVars(vars, extra) {
1523
- const tokens = vars[tokensSymbol] ?? {};
1524
- return Token.vars(toMerged(tokens, extra));
1525
- }
1526
- static assignVars(vars, overwrites) {
1527
- const tokens = overwrites ?? vars[tokensSymbol] ?? {};
1528
- const token = vars[tokenInstSymbol] ?? new Token("");
1529
- const result = {};
1530
- for (const [name, value] of flattenTokens(token, tokens, [])) result[name] = token.normalize(value);
1531
- return result;
1532
- }
1533
- static variants(variants) {
1534
- return mapKeys(variants, (key) => `&[data-variant="${key}"]`);
1535
- }
1536
- static val(strings, ...values) {
1537
- return function* () {
1538
- for (let index = 0; index < strings.length; index += 1) {
1539
- const literal = strings[index];
1540
- if (literal) yield literal;
1541
- if (index >= values.length) continue;
1542
- const value = values[index];
1543
- yield* isFunction(value) ? value() : [value];
1544
- }
1545
- };
1546
- }
1547
- static calc(strings, ...values) {
1548
- return combinator("calc(", ")", strings, values);
1549
- }
1550
- static min(strings, ...values) {
1551
- return combinator("min(", ")", strings, values);
1552
- }
1553
- static max(strings, ...values) {
1554
- return combinator("max(", ")", strings, values);
1555
- }
1556
- static url(strings, ...values) {
1557
- return combinator("url(", ")", strings, values);
1558
- }
1559
- static colorMix(strings, ...values) {
1560
- return combinator("color-mix(", ")", strings, values);
1561
- }
1562
- static colorScale(color, options = {}) {
1563
- const channel = (name, amount, max) => Token.calc`${name} + (${String(max)} - ${name}) * max(${amount}, 0) + ${name} * min(${amount}, 0)`;
1564
- const mix = (from, to, amount) => Token.colorMix`in srgb, ${from}, ${to} ${Token.calc`${amount} * 100%`}`;
1565
- let result = color;
1566
- if (!isUndefined(options.alpha) || !isUndefined(options.lightness) || !isUndefined(options.saturation)) result = Token.val`hsl(from ${result} h ${isUndefined(options.saturation) ? "s" : channel("s", options.saturation, 100)} ${isUndefined(options.lightness) ? "l" : channel("l", options.lightness, 100)} / ${isUndefined(options.alpha) ? "alpha" : channel("alpha", options.alpha, 1)})`;
1567
- if (!isUndefined(options.whiteness)) result = mix(result, "white", options.whiteness);
1568
- if (!isUndefined(options.blackness)) result = mix(result, "black", options.blackness);
1569
- return result;
1570
- }
1571
- static fallbackVar(value, ...fallbacks) {
1572
- return Object.assign(function* () {
1573
- yield "var(";
1574
- for (const [index, item] of [value, ...fallbacks].entries()) {
1575
- if (index > 0) yield ", ";
1576
- yield* asIterable(item);
1577
- }
1578
- yield ")";
1579
- }, { [cssVarSymbol]: value });
1580
- }
1581
- static collect(value) {
1582
- const iterable = isFunction(value) ? value() : value;
1583
- let result = "";
1584
- for (const item of iterable) result += `${item}`;
1585
- return result;
1586
- }
1587
- constructor(prefix = "") {
1588
- this.prefix = prefix;
1589
- }
1590
- prop = (key) => key.startsWith("--") ? key : kebabCase(key);
1591
- normalize = (input) => {
1592
- const value = isFunction(input) ? input() : input;
1593
- if (typeof value === "number") return `${value}`;
1594
- if (typeof value === "string") return value;
1595
- if (isUndefined(value) || isNull(value)) return "";
1596
- if (isFunction(value)) return Token.collect(value);
1597
- if (isPlainObject(value) && Symbol.iterator in value) return Token.collect(value);
1598
- return "";
1599
- };
1600
- cssVar = (paths) => `--${[this.prefix, ...paths].filter(Boolean).join("-")}`;
1601
- };
1602
- function combinator(open, close, strings, values) {
1603
- return function* () {
1604
- yield open;
1605
- yield* Token.val(strings, ...values)();
1606
- yield close;
1607
- };
1608
- }
1609
- function* asIterable(value) {
1610
- const resolved = isFunction(value) ? value() : value;
1611
- const variable = resolved?.[cssVarSymbol];
1612
- if (!isUndefined(variable)) {
1613
- yield variable;
1614
- return;
1615
- }
1616
- if (typeof resolved === "object" && resolved !== null && Symbol.iterator in resolved) {
1617
- yield* resolved;
1618
- return;
1619
- }
1620
- yield resolved;
1621
- }
1622
- function* flattenTokens(token, value, parents) {
1623
- for (const [property, child] of Object.entries(value)) {
1624
- if (property === SELF) continue;
1625
- if (isPlainObject(child)) {
1626
- yield* flattenTokens(token, child, [...parents, property]);
1627
- continue;
1628
- }
1629
- yield [token.cssVar([...parents, property]), child];
1630
- }
1631
- }
1632
- function kebabCase(value) {
1633
- return value.replace(/([A-Z])/g, "-$1").toLowerCase();
1634
- }
1635
- //#endregion
1636
- //#region ../../client/ui-primitives/src/client/styling/styling.ts
1637
- var Styling = class Styling {
1638
- static create() {
1639
- return new Styling();
1640
- }
1641
- static toRule(sheet) {
1642
- return sheet.selector === void 0 ? sheet.contents.join("") : `${sheet.selector} {${sheet.contents.join("")} }`;
1643
- }
1644
- #token = new Token();
1645
- #sheets = /* @__PURE__ */ new Map();
1646
- #injected = /* @__PURE__ */ new Set();
1647
- props = (...styles) => {
1648
- const merged = mergeStyles(styles);
1649
- if (Object.keys(merged).length === 0) return {};
1650
- const sheet = this.#sheet(2, this.#rules(merged));
1651
- return sheet === void 0 ? {} : { [`data-css-${sheet.id}`]: "" };
1652
- };
1653
- keyframes = (frames = {}) => {
1654
- return this.#sheet(1, this.#rules(frames))?.id ?? "anim-none";
1655
- };
1656
- injectGlobals = (styles = {}) => {
1657
- for (const [name, style] of Object.entries(styles)) this.#sheet(0, this.#rules(style), name);
1658
- };
1659
- className = (...styles) => {
1660
- const merged = mergeStyles(styles);
1661
- if (Object.keys(merged).length === 0) return "";
1662
- const sheet = this.#sheet(3, this.#rules(merged));
1663
- return sheet === void 0 ? "" : `cls-${sheet.id}`;
1664
- };
1665
- sheets = () => [...this.#sheets.values()].map((sheet) => Styling.toRule(sheet));
1666
- #sheet(type, rules, selector) {
1667
- let hash = 0;
1668
- const contents = [];
1669
- for (const rule of rules) {
1670
- contents.push(rule);
1671
- hash = incrementalHash(rule, hash);
1672
- }
1673
- if (selector !== void 0) hash = incrementalHash(selector, hash);
1674
- if (hash === 0) return void 0;
1675
- let id = selector ?? "";
1676
- if (type === 2) id = `s${hash.toString(36)}`;
1677
- if (type === 3) id = `c${hash.toString(36)}`;
1678
- if (type === 0) id = `g${hash.toString(36)}`;
1679
- if (type === 1) id = `a${hash.toString(36)}`;
1680
- let resolvedSelector = selector;
1681
- if (resolvedSelector === void 0) {
1682
- if (type === 1) resolvedSelector = `@keyframes ${id}`;
1683
- if (type === 2) resolvedSelector = `[data-css-${id}]`;
1684
- if (type === 3) resolvedSelector = `.cls-${id}`;
1685
- }
1686
- const sheet = {
1687
- id,
1688
- contents,
1689
- selector: resolvedSelector
1690
- };
1691
- const existing = this.#sheets.get(id);
1692
- if (existing !== void 0 && existing.contents.join("") === contents.join("")) return existing;
1693
- this.#sheets.set(id, sheet);
1694
- this.#inject(sheet);
1695
- return sheet;
1696
- }
1697
- #inject(sheet) {
1698
- if (this.#injected.has(sheet.id)) return;
1699
- this.#injected.add(sheet.id);
1700
- if (typeof document === "undefined") return;
1701
- const element = document.createElement("style");
1702
- element.setAttribute("data-css", sheet.id);
1703
- element.textContent = Styling.toRule(sheet);
1704
- document.head.appendChild(element);
1705
- }
1706
- *#rules(styles) {
1707
- const nested = /* @__PURE__ */ new Map();
1708
- for (const [key, value] of Object.entries(styles)) {
1709
- if (isNull(value) || isUndefined(value)) continue;
1710
- if (isPlainObject(value)) {
1711
- nested.set(key, value);
1712
- continue;
1713
- }
1714
- yield ` ${this.#token.prop(key)}: ${this.#token.normalize(value)};`;
1715
- }
1716
- for (const [key, value] of nested.entries()) {
1717
- yield ` ${key} {`;
1718
- yield* this.#rules(value);
1719
- yield " }";
1720
- }
1721
- }
1475
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/schema-form/schema-form.module.css.mjs
1476
+ const css$16 = ".B1Faoa_editorRoot{width:100%;color:var(--dsw-alias-label-primary);flex-direction:column;font-family:ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,monospace;font-size:14px;line-height:22px;display:flex}.B1Faoa_lineRow{white-space:nowrap;align-items:flex-start;gap:6px;min-height:22px;padding-right:8px;display:flex}.B1Faoa_lineRow:hover{background:var(--dsw-alias-bg-layer-2)}.B1Faoa_lineRow[data-selected=true]{background:var(--dsw-alias-bg-layer-3)}.B1Faoa_lineRow[data-dirty=true]{box-shadow:inset 2px 0 0 var(--dsw-alias-brand-primary)}.B1Faoa_lineRow[data-overridden=true]{box-shadow:inset 2px 0 0 var(--dsw-elevation-stroke-color)}.B1Faoa_lineRow[data-dirty=true] [data-role=key],.B1Faoa_lineRow[data-overridden=true] [data-role=key]{color:var(--dsw-alias-brand-primary)}.B1Faoa_lineRow[data-invalid=true]{background:color-mix(in srgb, var(--dsw-alias-state-error-secondary) 12%, transparent);box-shadow:inset 2px 0 0 var(--dsw-alias-state-error-primary)}.B1Faoa_lineRow[data-invalid=true] [data-role=key]{color:var(--dsw-alias-state-error-primary)}.B1Faoa_lineRow:hover [data-role=actions]{opacity:1}.B1Faoa_lineBody{flex:1;align-items:center;gap:6px;min-width:0;min-height:22px;display:flex}.B1Faoa_lineNumber{text-align:right;width:32px;color:var(--dsw-alias-label-caption);user-select:none;cursor:pointer;flex:none;line-height:22px}.B1Faoa_lineFold{width:14px;height:22px;color:var(--dsw-alias-label-caption);cursor:pointer;background:0 0;border:0;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.B1Faoa_lineFold:hover{color:var(--dsw-alias-label-secondary)}.B1Faoa_lineFoldSpacer{flex:none;width:14px}.B1Faoa_lineKey{color:var(--dsw-alias-label-primary);flex:none}.B1Faoa_lineKey[data-index=true]{color:var(--dsw-alias-label-caption)}.B1Faoa_lineToken{color:var(--dsw-alias-label-caption);flex:none}.B1Faoa_lineValue{text-overflow:ellipsis;cursor:text;min-width:0;color:var(--dsw-alias-state-business-primary);display:block;overflow:hidden}.B1Faoa_lineValue[data-tone=number]{color:var(--dsw-alias-state-warn-primary)}.B1Faoa_lineValue[data-tone=boolean]{color:var(--dsw-alias-state-success-primary)}.B1Faoa_lineValue[data-tone=empty]{color:var(--dsw-alias-label-caption)}.B1Faoa_valueSlot{flex:0 auto;min-width:0;display:block;overflow:hidden}.B1Faoa_valueTrigger{min-width:0;font:inherit;text-align:left;cursor:pointer;color:var(--dsw-alias-label-caption);background:0 0;border:0;align-items:center;gap:2px;padding:0;display:inline-flex}.B1Faoa_valueTrigger:disabled{cursor:default}.B1Faoa_valueTrigger:focus-visible{outline:none}.B1Faoa_compactInput{flex:auto;min-width:0;display:inline-flex}.B1Faoa_compactInput>span{border-radius:4px;width:100%;height:22px;padding:0 6px}.B1Faoa_compactInput input{font-size:14px;line-height:22px}.B1Faoa_compactTextField{background:var(--dsw-alias-bg-layer-1);min-width:0;box-shadow:0 0 0 .5px var(--dsw-elevation-stroke-color);border:0;border-radius:4px;flex:auto;padding:0 6px;display:inline-flex}.B1Faoa_compactTextField:focus-within{--dsw-elevation-stroke-color:var(--dsw-alias-brand-primary)}.B1Faoa_compactTextField>textarea{resize:none;field-sizing:content;width:100%;min-height:20px;max-height:240px;color:var(--dsw-alias-label-primary);background:0 0;border:0;outline:none;flex:1;padding:0;font-family:inherit;font-size:14px;line-height:22px}.B1Faoa_lineComment{text-overflow:ellipsis;min-width:0;color:var(--dsw-alias-label-tertiary);flex:auto;font-family:inherit;font-size:12px;overflow:hidden}.B1Faoa_lineInvalid{text-overflow:ellipsis;min-width:0;color:var(--dsw-alias-state-error-primary);flex:0 auto;font-family:inherit;font-size:12px;overflow:hidden}.B1Faoa_lineActions{opacity:0;flex:none;align-items:center;gap:4px;display:inline-flex}.B1Faoa_lineActions>button{width:20px;height:20px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:0;border-radius:4px;justify-content:center;align-items:center;padding:0;display:inline-flex}.B1Faoa_lineActions>button:hover{background:var(--dsw-alias-bg-layer-3);color:var(--dsw-alias-label-primary)}.B1Faoa_lineActions>button:disabled{cursor:not-allowed;color:var(--dsw-alias-label-dimmed)}.B1Faoa_hoverActions[data-editing=true]{opacity:1;gap:6px}.B1Faoa_hoverActions[data-editing=true]>button{box-shadow:0 0 0 .5px var(--dsw-elevation-stroke-color);background:var(--dsw-alias-bg-layer-1);color:var(--dsw-alias-label-primary)}.B1Faoa_hoverActions[data-editing=true]>button:first-of-type{color:var(--dsw-alias-state-success-primary)}.B1Faoa_addWrap{flex:auto;align-items:center;gap:6px;min-width:0;margin-left:6px;display:inline-flex;position:relative}.B1Faoa_addWrap[data-invalid=true] input{border-color:var(--dsw-alias-state-error-primary)}.B1Faoa_hint{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:1.5}";
1477
+ const tagId$16 = "@morlay/ui-conversation-manager/schema-form.module.css";
1478
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/schema-form.module.css\"]") === null) {
1479
+ const tag = document.createElement("style");
1480
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
1481
+ tag.dataset.pluginCss = tagId$16;
1482
+ tag.textContent = css$16;
1483
+ document.head.appendChild(tag);
1484
+ }
1485
+ var schema_form_module_css_default = {
1486
+ "lineInvalid": "B1Faoa_lineInvalid",
1487
+ "editorRoot": "B1Faoa_editorRoot",
1488
+ "lineNumber": "B1Faoa_lineNumber",
1489
+ "lineToken": "B1Faoa_lineToken",
1490
+ "lineKey": "B1Faoa_lineKey",
1491
+ "lineFold": "B1Faoa_lineFold",
1492
+ "hoverActions": "B1Faoa_hoverActions",
1493
+ "lineFoldSpacer": "B1Faoa_lineFoldSpacer",
1494
+ "valueSlot": "B1Faoa_valueSlot",
1495
+ "compactInput": "B1Faoa_compactInput",
1496
+ "compactTextField": "B1Faoa_compactTextField",
1497
+ "lineComment": "B1Faoa_lineComment",
1498
+ "lineRow": "B1Faoa_lineRow",
1499
+ "lineValue": "B1Faoa_lineValue",
1500
+ "lineActions": "B1Faoa_lineActions",
1501
+ "lineBody": "B1Faoa_lineBody",
1502
+ "valueTrigger": "B1Faoa_valueTrigger",
1503
+ "addWrap": "B1Faoa_addWrap",
1504
+ "hint": "B1Faoa_hint"
1722
1505
  };
1723
- function mergeStyles(styles) {
1724
- return styles.reduce((accumulated, style) => style ? toMerged(accumulated, style) : accumulated, {});
1725
- }
1726
- function incrementalHash(value, previous = 0) {
1727
- let hash = previous;
1728
- for (let index = 0; index < value.length; index += 1) {
1729
- hash = (hash << 5) - hash + value.charCodeAt(index);
1730
- hash &= 2147483647;
1731
- }
1732
- return hash;
1733
- }
1734
- const STYLING_SINGLETON = Symbol.for("@morlay/dsh-client-ui-primitives/styling");
1735
- const globalScope = globalThis;
1736
- const styling = globalScope[STYLING_SINGLETON] ??= Styling.create();
1737
- //#endregion
1738
- //#region ../../client/ui-primitives/src/client/styling/styled.tsx
1739
- const sxSymbol = Symbol("styled.sx");
1740
- function styled(Component, defaultProps = {}) {
1741
- return (...styles) => {
1742
- const sx = styles.reduce((merged, style) => toMerged(merged, style), {});
1743
- const Styled = (0, react.forwardRef)((props, ref) => {
1744
- const styleProps = (0, react.useMemo)(() => styling.props(sx), []);
1745
- return (0, react.createElement)(Component, {
1746
- ...defaultProps,
1747
- ...props,
1748
- ...styleProps,
1749
- ref
1750
- });
1751
- });
1752
- Styled.displayName = `styled(${typeof Component === "string" ? Component : Component.displayName ?? Component.name ?? "Component"})`;
1753
- return Object.assign(Styled, { [sxSymbol]: sx });
1754
- };
1755
- }
1756
- //#endregion
1757
- //#region ../../client/ui-primitives/src/client/theme.ts
1758
- const dsw = Token.vars({
1759
- alias: {
1760
- bg: {
1761
- base: "var(--dsw-static-neutral-bluish-00)",
1762
- document: {
1763
- preview: "var(--dsw-static-neutral-bluish-100)",
1764
- selection: "color-mix(in srgb, var(--dsw-static-blue-500) 40%, transparent)"
1765
- },
1766
- layer: {
1767
- "1": "var(--dsw-static-neutral-bluish-00)",
1768
- "2": "var(--dsw-static-neutral-bluish-00)",
1769
- "3": "var(--dsw-static-neutral-bluish-00)"
1770
- },
1771
- mask: {
1772
- "1": "rgba(0, 0, 0, 0.24)",
1773
- "2": "rgba(0, 0, 0, 0.12)",
1774
- "3": "rgba(0, 0, 0, 0.48)",
1775
- drop: "rgba(255, 255, 255, 0.7)",
1776
- photo: "rgba(0, 0, 0, 0.88)"
1777
- },
1778
- module: { platform: "var(--dsw-static-neutral-bluish-60)" },
1779
- multi: { select: "var(--dsw-static-neutral-bluish-60)" },
1780
- overlay: "var(--dsw-static-neutral-bluish-150)",
1781
- skeleton: "rgba(0, 0, 0, 0.04)"
1782
- },
1783
- border: {
1784
- inverted: "rgba(0, 0, 0, 0)",
1785
- inverted2: "rgba(0, 0, 0, 0)",
1786
- l1: "rgba(0, 0, 0, 0.04)",
1787
- l2: {
1788
- $: "rgba(0, 0, 0, 0.1)",
1789
- darkmode: { thin: "rgba(0, 0, 0, 0.1)" }
1790
- },
1791
- l3: "rgba(0, 0, 0, 0.12)",
1792
- l4: "rgba(0, 0, 0, 0.16)"
1793
- },
1794
- brand: {
1795
- primary: {
1796
- $: "var(--dsw-static-neutral-bluish-1000)",
1797
- invert: "var(--dsw-static-neutral-bluish-1000)",
1798
- new: { colorprimary: { new: { color: "rgb(65, 118, 230)" } } }
1799
- },
1800
- text: "var(--dsw-static-neutral-bluish-1000)"
1801
- },
1802
- button: {
1803
- contrast: { fill: "var(--dsw-static-neutral-bluish-700)" },
1804
- elevated: { fill: "var(--dsw-static-neutral-bluish-00)" },
1805
- floating: {
1806
- fill: "var(--dsw-static-neutral-bluish-00)",
1807
- hover: "var(--dsw-static-neutral-bluish-75)"
1808
- },
1809
- ghost: { active: {
1810
- border: "var(--dsw-static-neutral-bluish-500)",
1811
- fill: "var(--dsw-static-neutral-bluish-100)",
1812
- hover: "var(--dsw-static-neutral-bluish-150)"
1813
- } },
1814
- info: {
1815
- fill: "var(--dsw-static-deepseek-500)",
1816
- hover: "var(--dsw-static-deepseek-400)"
1817
- },
1818
- primary: {
1819
- dimmed: "var(--dsw-static-neutral-bluish-100)",
1820
- fill: "var(--dsw-alias-brand-primary)",
1821
- hover: "var(--dsw-static-neutral-bluish-750)"
1822
- },
1823
- tool: { bar: {
1824
- fill: {
1825
- $: "rgba(84, 85, 87, 0.5)",
1826
- invisible: "rgba(31, 31, 31, 0.36)"
1827
- },
1828
- hover: "rgba(84, 85, 87, 0.6)"
1829
- } }
1830
- },
1831
- code: { diff: {
1832
- added: "var(--dsw-static-green-500-a08)",
1833
- deleted: "var(--dsw-static-red-600-a08)"
1834
- } },
1835
- file: { diff: {
1836
- added: {
1837
- bg: "rgb(230, 244, 231)",
1838
- gutter: "rgb(237, 247, 237)",
1839
- marker: "rgb(1, 162, 65)"
1840
- },
1841
- deleted: {
1842
- bg: "rgb(252, 230, 226)",
1843
- gutter: "rgb(253, 236, 233)",
1844
- marker: "rgb(186, 39, 35)"
1845
- }
1846
- } },
1847
- interactive: { bg: {
1848
- active: "rgba(38, 49, 72, 0.1)",
1849
- hover: {
1850
- $: "rgba(38, 49, 72, 0.06)",
1851
- accent: "rgba(38, 49, 72, 0.14)",
1852
- danger: "rgba(236, 19, 19, 0.05)",
1853
- solid: "var(--dsw-static-neutral-bluish-75)"
1854
- }
1855
- } },
1856
- label: {
1857
- caption: "var(--dsw-static-neutral-bluish-400)",
1858
- deep: { diving: {
1859
- $: "color-mix(in srgb, var(--dsw-static-deepseek-500) 70%, var(--dsw-static-blue-950))",
1860
- shimmer: "color-mix(in srgb, var(--dsw-static-deepseek-500) 30%, var(--dsw-static-blue-950))"
1861
- } },
1862
- dimmed: "var(--dsw-static-neutral-bluish-200)",
1863
- document: { preview: "var(--dsw-static-neutral-bluish-700)" },
1864
- primary: {
1865
- $: "var(--dsw-static-neutral-bluish-1000)",
1866
- bluish: "var(--dsw-static-blue-900)",
1867
- dimmed: "var(--dsw-static-neutral-bluish-950)",
1868
- foreground: "var(--dsw-static-neutral-bluish-00)",
1869
- inverted: "var(--dsw-static-neutral-bluish-00)"
1870
- },
1871
- secondary: "var(--dsw-static-neutral-bluish-700)",
1872
- shimmer: "color-mix(in srgb, var(--dsw-static-neutral-1000) 30%, transparent)",
1873
- tertiary: "var(--dsw-static-neutral-bluish-600)"
1874
- },
1875
- link: "var(--dsw-static-deepseek-500)",
1876
- markdown: {
1877
- citation: "var(--dsw-static-neutral-bluish-100)",
1878
- code: {
1879
- block: {
1880
- $: "var(--dsw-static-neutral-bluish-50)",
1881
- banner: "var(--dsw-static-neutral-bluish-50)"
1882
- },
1883
- segment: {
1884
- selected: "var(--dsw-static-neutral-bluish-00)",
1885
- unselected: "var(--dsw-static-neutral-bluish-75)"
1886
- }
1887
- },
1888
- inline: { code: "var(--dsw-static-neutral-50)" },
1889
- placeholder: "var(--dsw-static-neutral-bluish-60)",
1890
- tag: "var(--dsw-static-neutral-bluish-75)"
1891
- },
1892
- menu: {
1893
- group: { header: { fill: "rgba(248, 249, 250, 0.94)" } },
1894
- icon: "var(--dsw-static-neutral-bluish-800)"
1895
- },
1896
- onboarding: {
1897
- accent: "rgb(57, 100, 254)",
1898
- card: { fill: "color-mix(in srgb, var(--dsw-static-neutral-bluish-00) 80%, transparent)" },
1899
- checkbox: { border: "color-mix(in srgb, var(--dsw-static-neutral-bluish-1000) 20%, transparent)" },
1900
- secondary: { fill: "var(--dsw-static-neutral-bluish-00)" }
1901
- },
1902
- scrollbar: {
1903
- bg: {
1904
- l1: "var(--dsw-static-neutral-200)",
1905
- l2: "var(--dsw-static-neutral-200)"
1906
- },
1907
- hover: {
1908
- l1: "var(--dsw-static-neutral-300)",
1909
- l2: "var(--dsw-static-neutral-300)"
1910
- }
1911
- },
1912
- settings: { card: {
1913
- fill: "var(--dsw-alias-bg-layer-2)",
1914
- stroke: "var(--dsw-alias-border-l4)"
1915
- } },
1916
- state: {
1917
- business: {
1918
- primary: "var(--dsw-static-deepseek-500)",
1919
- tertiary: "var(--dsw-static-deepseek-100)"
1920
- },
1921
- error: {
1922
- primary: "var(--dsw-static-red-600)",
1923
- secondary: "var(--dsw-static-red-400)"
1924
- },
1925
- idle: { primary: "var(--dsw-static-neutral-300)" },
1926
- success: {
1927
- primary: "var(--dsw-static-green-500)",
1928
- secondary: "var(--dsw-static-green-400)",
1929
- tertiary: "var(--dsw-static-green-100)"
1930
- },
1931
- warn: {
1932
- label: "var(--dsw-static-amber-600)",
1933
- primary: "var(--dsw-static-amber-500)",
1934
- secondary: "var(--dsw-static-amber-400)",
1935
- tertiary: "var(--dsw-static-amber-100)"
1936
- }
1937
- },
1938
- switch: { thumb: "var(--dsw-static-neutral-bluish-00)" },
1939
- toast: {
1940
- bg: "var(--dsw-static-neutral-bluish-800)",
1941
- label: "var(--dsw-static-neutral-bluish-00)"
1942
- },
1943
- tooltip: {
1944
- bg: "var(--dsw-static-neutral-bluish-850)",
1945
- key: { bg: "color-mix(in srgb, var(--dsw-alias-tooltip-bg), white 18%)" }
1946
- },
1947
- turn: { trigger: { bg: {
1948
- $: "var(--dsw-alias-markdown-code-block)",
1949
- hover: "var(--dsw-alias-interactive-bg-hover)"
1950
- } } }
1951
- },
1952
- corner: { shape: "superellipse(1.5)" },
1953
- elevation: {
1954
- panel: "var(--dsw-elevation-stroke), 0 3px 8px 0 rgba(0, 0, 0, 0.03), 0 0 16px 0 rgba(0, 0, 0, 0.02)",
1955
- prominent: "var(--dsw-elevation-stroke), 0 3px 8px 0 rgba(0, 0, 0, 0.04), 0 0 20px 0 rgba(0, 0, 0, 0.05)",
1956
- soft: "var(--dsw-elevation-stroke), 0 4px 16px 0 rgba(0, 0, 0, 0.03), 0 0 24px 0 rgba(0, 0, 0, 0.03)",
1957
- stroke: {
1958
- $: "0 0 0 0.5px var(--dsw-elevation-stroke-color)",
1959
- color: "var(--dsw-alias-border-l4)"
1960
- }
1961
- },
1962
- focus: { ring: {
1963
- color: "transparent",
1964
- width: "2px"
1965
- } },
1966
- font: {
1967
- base: {
1968
- "16": {
1969
- $: "16px/24px var(--dsw-font-family)",
1970
- font: {
1971
- family: "var(--dsw-font-family)",
1972
- size: "16px",
1973
- style: "normal",
1974
- weight: "400"
1975
- },
1976
- line: { height: "24px" }
1977
- },
1978
- strong: { "16": {
1979
- $: "500 16px/24px var(--dsw-font-family)",
1980
- font: {
1981
- family: "var(--dsw-font-family)",
1982
- size: "16px",
1983
- style: "normal",
1984
- weight: "500"
1985
- },
1986
- line: { height: "24px" }
1987
- } }
1988
- },
1989
- family: {
1990
- $: "-apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC',\n 'Hiragino Sans GB', 'Microsoft YaHei', 'Helvetica Neue', Helvetica, Arial, sans-serif",
1991
- brand: "'Montserrat', var(--dsw-font-family)"
1992
- },
1993
- l: { "20": {
1994
- $: "500 20px/28px var(--dsw-font-family)",
1995
- font: {
1996
- family: "var(--dsw-font-family)",
1997
- size: "20px",
1998
- style: "normal",
1999
- weight: "500"
2000
- },
2001
- line: { height: "28px" }
2002
- } },
2003
- m: { "18": {
2004
- $: "500 16px/28px var(--dsw-font-family)",
2005
- font: {
2006
- family: "var(--dsw-font-family)",
2007
- size: "16px",
2008
- style: "normal",
2009
- weight: "500"
2010
- },
2011
- line: { height: "28px" }
2012
- } },
2013
- markdown: {
2014
- base: {
2015
- $: "var(--dsh-content-font-size, 14px) / calc(24px + var(--dsh-content-font-delta)) var(--dsw-font-family)",
2016
- font: {
2017
- family: "var(--dsw-font-family)",
2018
- size: "var(--dsh-content-font-size, 14px)",
2019
- style: "normal",
2020
- weight: "400"
2021
- },
2022
- italic: {
2023
- $: "italic var(--dsh-content-font-size, 14px) / calc(24px + var(--dsh-content-font-delta)) var(--dsw-font-family)",
2024
- font: {
2025
- family: "var(--dsw-font-family)",
2026
- size: "var(--dsh-content-font-size, 14px)",
2027
- style: "italic",
2028
- weight: "400"
2029
- },
2030
- line: { height: "calc(24px + var(--dsh-content-font-delta))" }
2031
- },
2032
- line: { height: "calc(24px + var(--dsh-content-font-delta))" },
2033
- strong: {
2034
- $: "600 var(--dsh-content-font-size, 14px) / calc(24px + var(--dsh-content-font-delta)) var(--dsw-font-family)",
2035
- font: {
2036
- family: "var(--dsw-font-family)",
2037
- size: "var(--dsh-content-font-size, 14px)",
2038
- style: "normal",
2039
- weight: "600"
2040
- },
2041
- italic: {
2042
- $: "italic 600 var(--dsh-content-font-size, 14px) / calc(24px + var(--dsh-content-font-delta)) var(--dsw-font-family)",
2043
- font: {
2044
- family: "var(--dsw-font-family)",
2045
- size: "var(--dsh-content-font-size, 14px)",
2046
- style: "italic",
2047
- weight: "600"
2048
- },
2049
- line: { height: "calc(24px + var(--dsh-content-font-delta))" }
2050
- },
2051
- line: { height: "calc(24px + var(--dsh-content-font-delta))" }
2052
- }
2053
- },
2054
- code: {
2055
- $: "12px/19px var(--ds-font-family-code)",
2056
- block: {
2057
- $: "11px/19px var(--ds-font-family-code)",
2058
- font: {
2059
- family: "var(--ds-font-family-code)",
2060
- size: "11px",
2061
- style: "normal",
2062
- weight: "400"
2063
- },
2064
- line: { height: "19px" },
2065
- small: {
2066
- $: "11px/16px var(--ds-font-family-code)",
2067
- font: {
2068
- family: "var(--ds-font-family-code)",
2069
- size: "11px",
2070
- style: "normal",
2071
- weight: "400"
2072
- },
2073
- line: { height: "16px" }
2074
- }
2075
- },
2076
- font: {
2077
- family: "var(--ds-font-family-code)",
2078
- size: "12px",
2079
- style: "normal",
2080
- weight: "400"
2081
- },
2082
- line: { height: "19px" }
2083
- },
2084
- h1: {
2085
- $: "700 calc(21px + var(--dsh-content-font-delta)) / calc(30px + var(--dsh-content-font-delta)) var(--dsw-font-family)",
2086
- font: {
2087
- family: "var(--dsw-font-family)",
2088
- size: "calc(21px + var(--dsh-content-font-delta))",
2089
- style: "normal",
2090
- weight: "700"
2091
- },
2092
- line: { height: "calc(30px + var(--dsh-content-font-delta))" }
2093
- },
2094
- h2: {
2095
- $: "700 calc(19px + var(--dsh-content-font-delta)) / calc(28px + var(--dsh-content-font-delta)) var(--dsw-font-family)",
2096
- font: {
2097
- family: "var(--dsw-font-family)",
2098
- size: "calc(19px + var(--dsh-content-font-delta))",
2099
- style: "normal",
2100
- weight: "700"
2101
- },
2102
- line: { height: "calc(28px + var(--dsh-content-font-delta))" }
2103
- },
2104
- h3: {
2105
- $: "700 calc(18px + var(--dsh-content-font-delta)) / calc(26px + var(--dsh-content-font-delta)) var(--dsw-font-family)",
2106
- font: {
2107
- family: "var(--dsw-font-family)",
2108
- size: "calc(18px + var(--dsh-content-font-delta))",
2109
- style: "normal",
2110
- weight: "700"
2111
- },
2112
- line: { height: "calc(26px + var(--dsh-content-font-delta))" }
2113
- },
2114
- h4: {
2115
- $: "600 var(--dsh-content-font-size, 14px) / calc(24px + var(--dsh-content-font-delta)) var(--dsw-font-family)",
2116
- font: {
2117
- family: "var(--dsw-font-family)",
2118
- size: "var(--dsh-content-font-size, 14px)",
2119
- style: "normal",
2120
- weight: "600"
2121
- },
2122
- line: { height: "calc(24px + var(--dsh-content-font-delta))" }
2123
- },
2124
- small: {
2125
- $: "12px/20px var(--dsw-font-family)",
2126
- font: {
2127
- family: "var(--dsw-font-family)",
2128
- size: "12px",
2129
- style: "normal",
2130
- weight: "400"
2131
- },
2132
- italic: {
2133
- $: "italic 12px/20px var(--dsw-font-family)",
2134
- font: {
2135
- family: "var(--dsw-font-family)",
2136
- size: "12px",
2137
- style: "italic",
2138
- weight: "400"
2139
- },
2140
- line: { height: "20px" }
2141
- },
2142
- line: { height: "20px" },
2143
- strong: {
2144
- $: "600 12px/20px var(--dsw-font-family)",
2145
- font: {
2146
- family: "var(--dsw-font-family)",
2147
- size: "12px",
2148
- style: "normal",
2149
- weight: "600"
2150
- },
2151
- italic: {
2152
- $: "italic 600 12px/20px var(--dsw-font-family)",
2153
- font: {
2154
- family: "var(--dsw-font-family)",
2155
- size: "12px",
2156
- style: "italic",
2157
- weight: "600"
2158
- },
2159
- line: { height: "20px" }
2160
- },
2161
- line: { height: "20px" }
2162
- }
2163
- },
2164
- table: {
2165
- $: "var(--dsh-content-font-size-secondary, 13px)/calc(22px + var(--dsh-content-font-delta-secondary, 0px)) var(--dsw-font-family)",
2166
- font: {
2167
- family: "var(--dsw-font-family)",
2168
- size: "var(--dsh-content-font-size-secondary, 13px)",
2169
- style: "normal",
2170
- weight: "400"
2171
- },
2172
- head: {
2173
- $: "500 var(--dsh-content-font-size-secondary, 13px)/calc(22px + var(--dsh-content-font-delta-secondary, 0px)) var(--dsw-font-family)",
2174
- font: {
2175
- family: "var(--dsw-font-family)",
2176
- size: "var(--dsh-content-font-size-secondary, 13px)",
2177
- style: "normal",
2178
- weight: "500"
2179
- },
2180
- line: { height: "calc(22px + var(--dsh-content-font-delta-secondary, 0px))" }
2181
- },
2182
- line: { height: "calc(22px + var(--dsh-content-font-delta-secondary, 0px))" }
2183
- }
2184
- },
2185
- s: {
2186
- "14": {
2187
- $: "14px/22px var(--dsw-font-family)",
2188
- font: {
2189
- family: "var(--dsw-font-family)",
2190
- size: "14px",
2191
- style: "normal",
2192
- weight: "400"
2193
- },
2194
- line: { height: "22px" }
2195
- },
2196
- strong: { "14": {
2197
- $: "500 14px/22px var(--dsw-font-family)",
2198
- font: {
2199
- family: "var(--dsw-font-family)",
2200
- size: "14px",
2201
- style: "normal",
2202
- weight: "500"
2203
- },
2204
- line: { height: "22px" }
2205
- } }
2206
- },
2207
- xl: { "24": {
2208
- $: "600 24px/32px var(--dsw-font-family)",
2209
- font: {
2210
- family: "var(--dsw-font-family)",
2211
- size: "24px",
2212
- style: "normal",
2213
- weight: "600"
2214
- },
2215
- line: { height: "32px" }
2216
- } },
2217
- xs: {
2218
- "13": {
2219
- $: "13px/20px var(--dsw-font-family)",
2220
- font: {
2221
- family: "var(--dsw-font-family)",
2222
- size: "13px",
2223
- style: "normal",
2224
- weight: "400"
2225
- },
2226
- line: { height: "20px" }
2227
- },
2228
- strong: { "13": {
2229
- $: "500 13px/20px var(--dsw-font-family)",
2230
- font: {
2231
- family: "var(--dsw-font-family)",
2232
- size: "13px",
2233
- style: "normal",
2234
- weight: "500"
2235
- },
2236
- line: { height: "20px" }
2237
- } }
2238
- },
2239
- xxs: {
2240
- "12": {
2241
- $: "12px/18px var(--dsw-font-family)",
2242
- font: {
2243
- family: "var(--dsw-font-family)",
2244
- size: "12px",
2245
- style: "normal",
2246
- weight: "400"
2247
- },
2248
- line: { height: "18px" }
2249
- },
2250
- strong: { "12": {
2251
- $: "500 12px/18px var(--dsw-font-family)",
2252
- font: {
2253
- family: "var(--dsw-font-family)",
2254
- size: "12px",
2255
- style: "normal",
2256
- weight: "500"
2257
- },
2258
- line: { height: "18px" }
2259
- } }
2260
- },
2261
- xxxs: {
2262
- "11": {
2263
- $: "11px/14px var(--dsw-font-family)",
2264
- font: {
2265
- family: "var(--dsw-font-family)",
2266
- size: "11px",
2267
- style: "normal",
2268
- weight: "400"
2269
- },
2270
- line: { height: "14px" }
2271
- },
2272
- strong: { "11": {
2273
- $: "500 11px/14px var(--dsw-font-family)",
2274
- font: {
2275
- family: "var(--dsw-font-family)",
2276
- size: "11px",
2277
- style: "normal",
2278
- weight: "500"
2279
- },
2280
- line: { height: "14px" }
2281
- } }
2282
- }
2283
- },
2284
- gradient: { onboarding: {
2285
- blue: { stops: "#3964fe 18.75%, #398efe 51.78%, #6dccff 86.252%, #3964fe" },
2286
- cyan: { stops: "#0293b4 21.154%, #2dc8eb 50.954%, #aff0ff 85.326%, #0293b4" },
2287
- violet: { stops: "#2a2fb6 33.102%, #8b76f6 50.954%, #c5c0ff 85.326%, #2a2fb6" }
2288
- } },
2289
- linear: {
2290
- gradient: { think: "linear-gradient(180deg, #fff 20.19%, rgba(255, 255, 255, 0) 100%)" },
2291
- think: { select: "linear-gradient(180deg, #f5f6f7 20.19%, rgba(245, 246, 247, 0) 100%)" }
2292
- },
2293
- mask: { blur: "none" },
2294
- menu: {
2295
- backdrop: { filter: "blur(40px) saturate(150%)" },
2296
- surface: { fill: "rgba(248, 249, 250, 0.58)" }
2297
- },
2298
- radius: {
2299
- lg: "16px",
2300
- md: "12px",
2301
- panel: "28px",
2302
- sm: "8px",
2303
- xl: "20px",
2304
- xs: "4px"
2305
- },
2306
- shadow: {
2307
- lv1: {
2308
- $: "0 2px 4px 0 rgba(0, 0, 0, 0.05)",
2309
- blur: "0 4px 12px 0 rgba(0, 0, 0, 0.02)"
2310
- },
2311
- lv2: "0 4px 12px 0 rgba(0, 0, 0, 0.02), 0 2px 8px 0 rgba(0, 0, 0, 0.04)",
2312
- lv3: "0 0 1px 0 rgba(0, 0, 0, 0.2), 0 0 4px 0 rgba(0, 0, 0, 0.02), 0 12px 32px 0 rgba(0, 0, 0, 0.08)"
2313
- },
2314
- specific: {
2315
- bubble: {
2316
- $: "var(--dsw-static-deepseek-50)",
2317
- highlight: "var(--dsw-static-deepseek-200)"
2318
- },
2319
- input: { major: "var(--dsw-static-neutral-bluish-00)" },
2320
- login: { input: "var(--dsw-static-neutral-bluish-50)" },
2321
- menu: "var(--dsw-menu-surface-fill)",
2322
- selector: "var(--dsw-static-neutral-bluish-60)",
2323
- sidebar: {
2324
- fill: "var(--dsw-static-neutral-bluish-50)",
2325
- nav: { item: {
2326
- active: {
2327
- $: "var(--dsw-static-neutral-bluish-100)",
2328
- accent: "var(--dsw-static-deepseek-100)"
2329
- },
2330
- hover: "var(--dsw-static-neutral-bluish-75)"
2331
- } }
2332
- },
2333
- tip: "var(--dsw-static-neutral-bluish-60)"
2334
- },
2335
- static: {
2336
- amber: {
2337
- "100": "rgb(254, 245, 231)",
2338
- "400": "rgb(247, 173, 49)",
2339
- "500": "rgb(245, 158, 11)",
2340
- "600": "rgb(221, 134, 41)",
2341
- "900": "rgb(39, 36, 31)"
2342
- },
2343
- blue: {
2344
- "50": "rgb(239, 246, 255)",
2345
- "75": "rgb(229, 240, 255)",
2346
- "100": "rgb(219, 234, 254)",
2347
- "300": "rgb(147, 197, 253)",
2348
- "400": "rgb(96, 165, 250)",
2349
- "450": "rgb(77, 147, 248)",
2350
- "500": "rgb(59, 130, 246)",
2351
- "600": "rgb(37, 99, 235)",
2352
- "800": "rgb(30, 64, 175)",
2353
- "900": "rgb(14, 48, 116)",
2354
- "950": "rgb(23, 37, 84)",
2355
- "50p": "rgb(234, 243, 255)"
2356
- },
2357
- deepseek: {
2358
- "50": "rgb(237, 243, 254)",
2359
- "100": "rgb(228, 237, 253)",
2360
- "200": "rgb(211, 226, 255)",
2361
- "300": "rgb(183, 200, 254)",
2362
- "400": "rgb(122, 170, 255)",
2363
- "450": "rgb(86, 134, 254)",
2364
- "500": "rgb(65, 118, 230)",
2365
- "600": "rgb(72, 104, 178)",
2366
- "700": { delete: "rgb(47, 76, 143)" },
2367
- "800": "rgb(52, 65, 91)",
2368
- "900": "rgb(40, 49, 66)"
2369
- },
2370
- green: {
2371
- "100": "rgb(230, 250, 237)",
2372
- "400": "rgb(78, 209, 126)",
2373
- "500": {
2374
- $: "rgb(34, 197, 94)",
2375
- a08: "rgb(34 197 94 / 8%)",
2376
- a12: "rgb(34 197 94 / 12%)"
2377
- },
2378
- "900": "rgb(35, 60, 44)"
2379
- },
2380
- neutral: {
2381
- "50": "rgb(250, 250, 250)",
2382
- "100": "rgb(245, 245, 245)",
2383
- "150": "rgb(237, 237, 237)",
2384
- "200": "rgb(229, 229, 229)",
2385
- "250": "rgb(220, 220, 220)",
2386
- "300": "rgb(212, 212, 212)",
2387
- "400": "rgb(162, 164, 166)",
2388
- "500": "rgb(127, 130, 135)",
2389
- "550": "rgb(101, 103, 107)",
2390
- "600": "rgb(84, 85, 87)",
2391
- "700": "rgb(60, 60, 61)",
2392
- "800": "rgb(41, 41, 41)",
2393
- "850": "rgb(33, 33, 35)",
2394
- "900": "rgb(15, 15, 15)",
2395
- "1000": "rgb(0, 0, 0)",
2396
- "00": "rgb(255, 255, 255)",
2397
- bluish: {
2398
- "50": "rgb(249, 250, 251)",
2399
- "60": "rgb(245, 246, 247)",
2400
- "75": "rgb(241, 243, 245)",
2401
- "100": "rgb(235, 238, 242)",
2402
- "150": "rgb(233, 236, 242)",
2403
- "200": "rgb(225, 229, 238)",
2404
- "300": "rgb(207, 211, 214)",
2405
- "400": "rgb(173, 178, 184)",
2406
- "500": "rgb(151, 157, 166)",
2407
- "600": "rgb(129, 133, 140)",
2408
- "700": "rgb(97, 102, 107)",
2409
- "750": "rgb(67, 69, 74)",
2410
- "800": "rgb(53, 54, 56)",
2411
- "850": "rgb(44, 44, 46)",
2412
- "875": "rgb(35, 35, 36)",
2413
- "900": "rgb(27, 27, 28)",
2414
- "950": "rgb(21, 21, 23)",
2415
- "1000": "rgb(15, 17, 21)",
2416
- "00": "rgb(255, 255, 255)"
2417
- }
2418
- },
2419
- red: {
2420
- "50": "rgb(254, 242, 242)",
2421
- "100": "rgb(254, 226, 226)",
2422
- "400": {
2423
- $: "rgb(242, 90, 90)",
2424
- a12: "rgb(242 90 90 / 12%)"
2425
- },
2426
- "500": "rgb(239, 68, 68)",
2427
- "600": {
2428
- $: "rgb(236, 19, 19)",
2429
- a08: "rgb(236 19 19 / 8%)"
2430
- },
2431
- "900": "rgb(87, 12, 12)"
2432
- }
2433
- }
2434
- }, { prefix: "dsw" });
2435
- //#endregion
2436
- //#region ../../client/ui-primitives/src/client/schema-form/styles.ts
2437
- const MONO = "ui-monospace, SFMono-Regular, \"SF Mono\", Menlo, Consolas, monospace";
2438
- const ROW = "22px";
2439
- const GAP = "6px";
2440
- const ACTION = "20px";
2441
- const ACTION_GAP = "4px";
2442
- const FOLD = "14px";
2443
- const NUMBER = "32px";
2444
- const PAD = "8px";
2445
- const HAIRLINE = dsw.elevation.stroke;
2446
- const LINE = dsw.elevation.stroke.color;
2447
- const EDGE = "2px";
2448
- const ERROR_WASH = `color-mix(in srgb, ${String(dsw.alias.state.error.secondary)} 12%, transparent)`;
2449
- const EditorRoot = styled("div")({
2450
- display: "flex",
2451
- flexDirection: "column",
2452
- width: "100%",
2453
- fontFamily: MONO,
2454
- fontSize: "14px",
2455
- lineHeight: ROW,
2456
- color: dsw.alias.label.primary
2457
- });
2458
- const LineRow = styled("div")({
2459
- display: "flex",
2460
- alignItems: "flex-start",
2461
- gap: GAP,
2462
- minHeight: ROW,
2463
- paddingRight: PAD,
2464
- whiteSpace: "nowrap",
2465
- "&:hover": { background: dsw.alias.bg.layer["2"] },
2466
- "&[data-selected='true']": { background: dsw.alias.bg.layer["3"] },
2467
- "&[data-dirty='true']": { boxShadow: `inset ${EDGE} 0 0 ${String(dsw.alias.brand.primary)}` },
2468
- "&[data-overridden='true']": { boxShadow: `inset ${EDGE} 0 0 ${String(LINE)}` },
2469
- "&[data-dirty='true'] [data-role='key']": { color: dsw.alias.brand.primary },
2470
- "&[data-overridden='true'] [data-role='key']": { color: dsw.alias.brand.primary },
2471
- "&[data-invalid='true']": {
2472
- background: ERROR_WASH,
2473
- boxShadow: `inset ${EDGE} 0 0 ${String(dsw.alias.state.error.primary)}`
2474
- },
2475
- "&[data-invalid='true'] [data-role='key']": { color: dsw.alias.state.error.primary },
2476
- "&:hover [data-role='actions']": { opacity: 1 }
2477
- });
2478
- const LineBody = styled("div")({
2479
- display: "flex",
2480
- alignItems: "center",
2481
- gap: GAP,
2482
- flex: 1,
2483
- minWidth: 0,
2484
- minHeight: ROW
2485
- });
2486
- const LineNumber = styled("span")({
2487
- flex: "none",
2488
- width: NUMBER,
2489
- lineHeight: ROW,
2490
- textAlign: "right",
2491
- color: dsw.alias.label.caption,
2492
- userSelect: "none",
2493
- cursor: "pointer"
2494
- });
2495
- const LineFold = styled("button")({
2496
- display: "inline-flex",
2497
- alignItems: "center",
2498
- justifyContent: "center",
2499
- flex: "none",
2500
- width: FOLD,
2501
- height: ROW,
2502
- padding: 0,
2503
- border: 0,
2504
- background: "none",
2505
- color: dsw.alias.label.caption,
2506
- cursor: "pointer",
2507
- "&:hover": { color: dsw.alias.label.secondary }
2508
- });
2509
- const LineFoldSpacer = styled("span")({
2510
- flex: "none",
2511
- width: FOLD
2512
- });
2513
- const LineKey = styled("span")({
2514
- flex: "none",
2515
- color: dsw.alias.label.primary,
2516
- "&[data-index='true']": { color: dsw.alias.label.caption }
2517
- });
2518
- const LineToken = styled("span")({
2519
- flex: "none",
2520
- color: dsw.alias.label.caption
2521
- });
2522
- const LineValue = styled("span")({
2523
- display: "block",
2524
- minWidth: 0,
2525
- overflow: "hidden",
2526
- textOverflow: "ellipsis",
2527
- cursor: "text",
2528
- color: dsw.alias.state.business.primary,
2529
- "&[data-tone='number']": { color: dsw.alias.state.warn.primary },
2530
- "&[data-tone='boolean']": { color: dsw.alias.state.success.primary },
2531
- "&[data-tone='empty']": { color: dsw.alias.label.caption }
2532
- });
2533
- const ValueSlot = styled("span")({
2534
- display: "block",
2535
- flex: "0 1 auto",
2536
- minWidth: 0,
2537
- overflow: "hidden"
2538
- });
2539
- const ValueTrigger = styled("button")({
2540
- display: "inline-flex",
2541
- alignItems: "center",
2542
- gap: "2px",
2543
- minWidth: 0,
2544
- padding: 0,
2545
- border: 0,
2546
- background: "none",
2547
- font: "inherit",
2548
- textAlign: "left",
2549
- cursor: "pointer",
2550
- color: dsw.alias.label.caption,
2551
- "&:disabled": { cursor: "default" },
2552
- "&:focus-visible": { outline: "none" }
2553
- });
2554
- const CompactInput = styled("span")({
2555
- display: "inline-flex",
2556
- flex: "1 1 auto",
2557
- minWidth: 0,
2558
- "& > span": {
2559
- width: "100%",
2560
- height: ROW,
2561
- padding: "0 6px",
2562
- borderRadius: "4px"
2563
- },
2564
- "& input": {
2565
- fontSize: "14px",
2566
- lineHeight: ROW
2567
- }
2568
- });
2569
- const CompactTextField = styled("span")({
2570
- display: "inline-flex",
2571
- flex: "1 1 auto",
2572
- minWidth: 0,
2573
- padding: "0 6px",
2574
- borderRadius: "4px",
2575
- background: dsw.alias.bg.layer["1"],
2576
- border: 0,
2577
- boxShadow: HAIRLINE,
2578
- "&:focus-within": { "--dsw-elevation-stroke-color": dsw.alias.brand.primary },
2579
- "& > textarea": {
2580
- flex: 1,
2581
- width: "100%",
2582
- minHeight: ACTION,
2583
- maxHeight: "240px",
2584
- padding: 0,
2585
- border: 0,
2586
- outline: "none",
2587
- background: "transparent",
2588
- resize: "none",
2589
- fieldSizing: "content",
2590
- fontFamily: "inherit",
2591
- fontSize: "14px",
2592
- lineHeight: ROW,
2593
- color: dsw.alias.label.primary
2594
- }
2595
- });
2596
- const LineComment = styled("span")({
2597
- flex: "1 1 auto",
2598
- minWidth: 0,
2599
- overflow: "hidden",
2600
- textOverflow: "ellipsis",
2601
- color: dsw.alias.label.tertiary,
2602
- fontFamily: "inherit",
2603
- fontSize: "12px"
2604
- });
2605
- const LineInvalid = styled("span")({
2606
- flex: "0 1 auto",
2607
- minWidth: 0,
2608
- overflow: "hidden",
2609
- textOverflow: "ellipsis",
2610
- color: dsw.alias.state.error.primary,
2611
- fontFamily: "inherit",
2612
- fontSize: "12px"
2613
- });
2614
- const HoverActions = styled(styled("span")({
2615
- display: "inline-flex",
2616
- alignItems: "center",
2617
- gap: ACTION_GAP,
2618
- flex: "none",
2619
- opacity: 0,
2620
- "& > button": {
2621
- display: "inline-flex",
2622
- alignItems: "center",
2623
- justifyContent: "center",
2624
- width: ACTION,
2625
- height: ACTION,
2626
- padding: 0,
2627
- border: 0,
2628
- borderRadius: "4px",
2629
- background: "none",
2630
- color: dsw.alias.label.secondary,
2631
- cursor: "pointer",
2632
- "&:hover": {
2633
- background: dsw.alias.bg.layer["3"],
2634
- color: dsw.alias.label.primary
2635
- },
2636
- "&:disabled": {
2637
- cursor: "not-allowed",
2638
- color: dsw.alias.label.dimmed
2639
- }
2640
- }
2641
- }))({ "&[data-editing='true']": {
2642
- opacity: 1,
2643
- gap: GAP,
2644
- "& > button": {
2645
- boxShadow: HAIRLINE,
2646
- background: dsw.alias.bg.layer["1"],
2647
- color: dsw.alias.label.primary,
2648
- "&:first-of-type": { color: dsw.alias.state.success.primary }
2649
- }
2650
- } });
2651
- const AddWrap = styled("span")({
2652
- position: "relative",
2653
- display: "inline-flex",
2654
- alignItems: "center",
2655
- gap: GAP,
2656
- flex: "1 1 auto",
2657
- minWidth: 0,
2658
- marginLeft: GAP,
2659
- "&[data-invalid='true'] input": { borderColor: dsw.alias.state.error.primary }
2660
- });
2661
- const Hint$1 = styled("p")({
2662
- margin: 0,
2663
- fontSize: "12px",
2664
- lineHeight: 1.5,
2665
- color: dsw.alias.label.tertiary
2666
- });
2667
1506
  //#endregion
2668
1507
  //#region ../../client/ui-primitives/src/client/schema-form/TruncatedTooltip.tsx
2669
1508
  function TruncatedTooltip({ label, children }) {
@@ -2721,7 +1560,8 @@ window.__ModuleLoader__.load({
2721
1560
  owner,
2722
1561
  options: owner.options
2723
1562
  });
2724
- if (owner.node.meta.secret) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineValue, {
1563
+ if (owner.node.meta.secret) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1564
+ className: schema_form_module_css_default.lineValue,
2725
1565
  "data-tone": "empty",
2726
1566
  title: owner.hint,
2727
1567
  children: owner.secretConfigured ? "••••••" : ""
@@ -2729,7 +1569,8 @@ window.__ModuleLoader__.load({
2729
1569
  const text = tokenText(owner.value);
2730
1570
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TruncatedTooltip, {
2731
1571
  label: text,
2732
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineValue, {
1572
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1573
+ className: schema_form_module_css_default.lineValue,
2733
1574
  "data-tone": owner.node.readOnly === null ? tokenTone(owner.value) : "empty",
2734
1575
  children: text
2735
1576
  })
@@ -2759,14 +1600,16 @@ window.__ModuleLoader__.load({
2759
1600
  onClose: () => {
2760
1601
  setOpen(false);
2761
1602
  },
2762
- anchor: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(ValueTrigger, {
1603
+ anchor: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
1604
+ className: schema_form_module_css_default.valueTrigger,
2763
1605
  type: "button",
2764
1606
  disabled: owner.disabled,
2765
1607
  "aria-label": owner.label,
2766
1608
  onClick: () => {
2767
1609
  setOpen(true);
2768
1610
  },
2769
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineValue, {
1611
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1612
+ className: schema_form_module_css_default.lineValue,
2770
1613
  "data-tone": current === void 0 ? tokenTone(owner.value) : tokenTone(current.value),
2771
1614
  children: label
2772
1615
  }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconChevronDownOutlineRegular, { size: 14 })]
@@ -2895,6 +1738,11 @@ window.__ModuleLoader__.load({
2895
1738
  }
2896
1739
  }
2897
1740
  //#endregion
1741
+ //#region ../../client/ui-primitives/src/client/controls/classes.ts
1742
+ function classes(...names) {
1743
+ return names.filter((name) => typeof name === "string" && name !== "").join(" ");
1744
+ }
1745
+ //#endregion
2898
1746
  //#region ../../client/ui-primitives/src/client/schema-form/Editor.tsx
2899
1747
  function Editor(props) {
2900
1748
  const { ns, state, face, t, resolveText, renderField } = props;
@@ -2910,9 +1758,10 @@ window.__ModuleLoader__.load({
2910
1758
  t
2911
1759
  ]);
2912
1760
  const disabled = !state.writable || !state.available;
2913
- return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EditorRoot, {
1761
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
1762
+ className: schema_form_module_css_default.editorRoot,
2914
1763
  "data-editor": "schema-form",
2915
- children: lines.map((line, index) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Row, {
1764
+ children: lines.map((line, index) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Row$1, {
2916
1765
  line,
2917
1766
  n: index + 1,
2918
1767
  ns,
@@ -2973,20 +1822,26 @@ window.__ModuleLoader__.load({
2973
1822
  toggled
2974
1823
  ]);
2975
1824
  }
2976
- function Row({ line, n, ns, state, face, fold, t, resolveText, disabled, editing, selected, dismissed, onEdit, onAdded, onDismiss, onSelect, renderField }) {
1825
+ function Row$1({ line, n, ns, state, face, fold, t, resolveText, disabled, editing, selected, dismissed, onEdit, onAdded, onDismiss, onSelect, renderField }) {
2977
1826
  const key = fieldKey(line.path);
2978
1827
  const indent = { paddingLeft: `${String(line.depth * 14)}px` };
2979
- const body = line.kind === "comment" ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineFoldSpacer, { "data-role": "fold" }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TruncatedTooltip, {
1828
+ const body = line.kind === "comment" ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1829
+ className: schema_form_module_css_default.lineFoldSpacer,
1830
+ "data-role": "fold"
1831
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TruncatedTooltip, {
2980
1832
  label: line.text,
2981
- children: line.invalid ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineInvalid, {
1833
+ children: line.invalid ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1834
+ className: schema_form_module_css_default.lineInvalid,
2982
1835
  "data-role": "comment",
2983
1836
  children: `// ${line.text}`
2984
- }) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineComment, {
1837
+ }) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1838
+ className: schema_form_module_css_default.lineComment,
2985
1839
  "data-role": "comment",
2986
1840
  children: `// ${line.text}`
2987
1841
  })
2988
1842
  })] }) : line.kind === "open" ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [
2989
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineFold, {
1843
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
1844
+ className: schema_form_module_css_default.lineFold,
2990
1845
  "data-role": "fold",
2991
1846
  type: "button",
2992
1847
  "aria-expanded": !line.collapsed,
@@ -3002,7 +1857,10 @@ window.__ModuleLoader__.load({
3002
1857
  t,
3003
1858
  disabled
3004
1859
  }),
3005
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineToken, { children: line.shape === "object" ? line.collapsed ? "{…}" : "{" : line.collapsed ? "[…]" : "[" }),
1860
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1861
+ className: schema_form_module_css_default.lineToken,
1862
+ children: line.shape === "object" ? line.collapsed ? "{…}" : "{" : line.collapsed ? "[…]" : "["
1863
+ }),
3006
1864
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)(VariantSelect, {
3007
1865
  control: line.variants,
3008
1866
  path: line.path,
@@ -3011,8 +1869,14 @@ window.__ModuleLoader__.load({
3011
1869
  t
3012
1870
  })
3013
1871
  ] }) : line.kind === "close" ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [
3014
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineFoldSpacer, { "data-role": "fold" }),
3015
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineToken, { children: line.shape === "object" ? "}" : "]" }),
1872
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1873
+ className: schema_form_module_css_default.lineFoldSpacer,
1874
+ "data-role": "fold"
1875
+ }),
1876
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1877
+ className: schema_form_module_css_default.lineToken,
1878
+ children: line.shape === "object" ? "}" : "]"
1879
+ }),
3016
1880
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)(AddLine, {
3017
1881
  line,
3018
1882
  state,
@@ -3035,20 +1899,23 @@ window.__ModuleLoader__.load({
3035
1899
  onDismiss,
3036
1900
  renderField
3037
1901
  });
3038
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(LineRow, {
1902
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1903
+ className: schema_form_module_css_default.lineRow,
3039
1904
  "data-line": line.kind,
3040
1905
  "data-field-path": line.path.join("."),
3041
1906
  "data-selected": selected === key ? "true" : void 0,
3042
1907
  "data-dirty": line.kind === "field" && line.field.staged ? "true" : void 0,
3043
1908
  "data-overridden": line.kind === "field" && line.field.overridden && !line.field.staged ? "true" : void 0,
3044
1909
  "data-invalid": line.kind === "field" && (line.field.invalid !== void 0 || state.invalidAt.has(key)) ? "true" : void 0,
3045
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineNumber, {
1910
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1911
+ className: schema_form_module_css_default.lineNumber,
3046
1912
  "data-role": "number",
3047
1913
  onClick: () => {
3048
1914
  onSelect(line.path);
3049
1915
  },
3050
1916
  children: n
3051
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineBody, {
1917
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
1918
+ className: schema_form_module_css_default.lineBody,
3052
1919
  "data-role": "body",
3053
1920
  style: indent,
3054
1921
  children: body
@@ -3093,49 +1960,63 @@ window.__ModuleLoader__.load({
3093
1960
  const text = line.field.text ?? valueText(line.field.value);
3094
1961
  const multiline = isMultiline(line.field.value) || /[\r\n]/.test(text);
3095
1962
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [
3096
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineFoldSpacer, { "data-role": "fold" }),
3097
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineKey, {
1963
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1964
+ className: schema_form_module_css_default.lineFoldSpacer,
1965
+ "data-role": "fold"
1966
+ }),
1967
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1968
+ className: schema_form_module_css_default.lineKey,
3098
1969
  "data-role": "key",
3099
1970
  "data-index": member?.index === void 0 ? void 0 : "true",
3100
1971
  title: member?.key ?? line.node.key,
3101
1972
  children: member?.key ?? line.node.key
3102
1973
  }),
3103
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineToken, { children: member?.index === void 0 ? ": " : " " }),
3104
- isEditing ? multiline ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(CompactTextField, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("textarea", {
3105
- autoFocus: !missing,
3106
- rows: 1,
3107
- "aria-label": owner.label,
3108
- value: text,
3109
- onChange: (event) => {
3110
- owner.onEditText(event.target.value);
3111
- },
3112
- onKeyDown: (event) => {
3113
- if (event.key === "Escape") {
3114
- face.revert(line.path);
3115
- onEdit(void 0);
1974
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1975
+ className: schema_form_module_css_default.lineToken,
1976
+ children: member?.index === void 0 ? ": " : " "
1977
+ }),
1978
+ isEditing ? multiline ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1979
+ className: schema_form_module_css_default.compactTextField,
1980
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("textarea", {
1981
+ autoFocus: !missing,
1982
+ rows: 1,
1983
+ "aria-label": owner.label,
1984
+ value: text,
1985
+ onChange: (event) => {
1986
+ owner.onEditText(event.target.value);
1987
+ },
1988
+ onKeyDown: (event) => {
1989
+ if (event.key === "Escape") {
1990
+ face.revert(line.path);
1991
+ onEdit(void 0);
1992
+ }
3116
1993
  }
3117
- }
3118
- }) }) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(CompactInput, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Input, {
3119
- autoFocus: !missing,
3120
- type: "text",
3121
- "aria-label": owner.label,
3122
- placeholder: missing ? t("empty") : "",
3123
- value: text,
3124
- onBlur: () => {
3125
- if (!missing) onEdit(void 0);
3126
- },
3127
- onChange: (event) => {
3128
- owner.onEditText(event.target.value);
3129
- },
3130
- onKeyDown: (event) => {
3131
- if (event.key === "Enter" && !missing) onEdit(void 0);
3132
- if (event.key === "Escape") {
3133
- face.revert(line.path);
3134
- onEdit(void 0);
1994
+ })
1995
+ }) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1996
+ className: schema_form_module_css_default.compactInput,
1997
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Input, {
1998
+ autoFocus: !missing,
1999
+ type: "text",
2000
+ "aria-label": owner.label,
2001
+ placeholder: missing ? t("empty") : "",
2002
+ value: text,
2003
+ onBlur: () => {
2004
+ if (!missing) onEdit(void 0);
2005
+ },
2006
+ onChange: (event) => {
2007
+ owner.onEditText(event.target.value);
2008
+ },
2009
+ onKeyDown: (event) => {
2010
+ if (event.key === "Enter" && !missing) onEdit(void 0);
2011
+ if (event.key === "Escape") {
2012
+ face.revert(line.path);
2013
+ onEdit(void 0);
2014
+ }
3135
2015
  }
3136
- }
3137
- }) }) : null,
3138
- isEditing || line.variantsStandIn ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ValueSlot, {
2016
+ })
2017
+ }) : null,
2018
+ isEditing || line.variantsStandIn ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2019
+ className: schema_form_module_css_default.valueSlot,
3139
2020
  "data-role": "value",
3140
2021
  onClick: () => {
3141
2022
  if (editable) onEdit(key);
@@ -3149,7 +2030,8 @@ window.__ModuleLoader__.load({
3149
2030
  disabled,
3150
2031
  t
3151
2032
  }),
3152
- isEditing ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HoverActions, {
2033
+ isEditing ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
2034
+ className: classes(schema_form_module_css_default.lineActions, schema_form_module_css_default.hoverActions),
3153
2035
  "data-role": "actions",
3154
2036
  "data-editing": "true",
3155
2037
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
@@ -3172,7 +2054,8 @@ window.__ModuleLoader__.load({
3172
2054
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconCloseOutlineRegular, { size: 14 })
3173
2055
  })]
3174
2056
  }) : null,
3175
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HoverActions, {
2057
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
2058
+ className: classes(schema_form_module_css_default.lineActions, schema_form_module_css_default.hoverActions),
3176
2059
  "data-role": "actions",
3177
2060
  children: [
3178
2061
  line.field.staged && !disabled ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
@@ -3238,7 +2121,8 @@ window.__ModuleLoader__.load({
3238
2121
  onClose: () => {
3239
2122
  setOpen(false);
3240
2123
  },
3241
- anchor: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(ValueTrigger, {
2124
+ anchor: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
2125
+ className: schema_form_module_css_default.valueTrigger,
3242
2126
  type: "button",
3243
2127
  "data-role": "variant",
3244
2128
  disabled,
@@ -3246,7 +2130,8 @@ window.__ModuleLoader__.load({
3246
2130
  onClick: () => {
3247
2131
  setOpen(true);
3248
2132
  },
3249
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineValue, {
2133
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2134
+ className: schema_form_module_css_default.lineValue,
3250
2135
  "data-tone": "empty",
3251
2136
  children: current?.label ?? ""
3252
2137
  }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconChevronDownOutlineRegular, { size: 14 })]
@@ -3259,14 +2144,19 @@ window.__ModuleLoader__.load({
3259
2144
  if (key === "") return null;
3260
2145
  const indexed = member !== void 0 && member.index !== void 0;
3261
2146
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [
3262
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineKey, {
2147
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2148
+ className: schema_form_module_css_default.lineKey,
3263
2149
  "data-role": "key",
3264
2150
  "data-index": indexed ? "true" : void 0,
3265
2151
  title: key,
3266
2152
  children: key
3267
2153
  }),
3268
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineToken, { children: indexed ? " " : ": " }),
3269
- member === void 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(HoverActions, {
2154
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2155
+ className: schema_form_module_css_default.lineToken,
2156
+ children: indexed ? " " : ": "
2157
+ }),
2158
+ member === void 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2159
+ className: classes(schema_form_module_css_default.lineActions, schema_form_module_css_default.hoverActions),
3270
2160
  "data-role": "actions",
3271
2161
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RemoveLineButton, {
3272
2162
  member,
@@ -3329,7 +2219,8 @@ window.__ModuleLoader__.load({
3329
2219
  setText("");
3330
2220
  setOpen(false);
3331
2221
  };
3332
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(AddWrap, {
2222
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
2223
+ className: schema_form_module_css_default.addWrap,
3333
2224
  "data-add": spec.kind,
3334
2225
  "data-invalid": invalid ? "true" : void 0,
3335
2226
  children: [
@@ -3349,35 +2240,44 @@ window.__ModuleLoader__.load({
3349
2240
  onClose: () => {
3350
2241
  setOpen(false);
3351
2242
  },
3352
- anchor: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(CompactInput, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Input, {
3353
- value: text,
3354
- placeholder: label,
3355
- "aria-label": label,
3356
- disabled,
3357
- onFocus: () => {
3358
- setOpen(true);
3359
- },
3360
- onChange: (event) => {
3361
- setText(event.target.value);
3362
- setInvalid(false);
3363
- setOpen(true);
3364
- },
3365
- onKeyDown: (event) => {
3366
- if (event.key === "Enter") {
3367
- event.preventDefault();
3368
- commit(matched.length === 1 && spec.kind === "prop" ? matched[0]?.key : void 0);
3369
- }
3370
- if (event.key === "Escape") {
3371
- setText("");
3372
- setOpen(false);
2243
+ anchor: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2244
+ className: schema_form_module_css_default.compactInput,
2245
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Input, {
2246
+ value: text,
2247
+ placeholder: label,
2248
+ "aria-label": label,
2249
+ disabled,
2250
+ onFocus: () => {
2251
+ setOpen(true);
2252
+ },
2253
+ onChange: (event) => {
2254
+ setText(event.target.value);
2255
+ setInvalid(false);
2256
+ setOpen(true);
2257
+ },
2258
+ onKeyDown: (event) => {
2259
+ if (event.key === "Enter") {
2260
+ event.preventDefault();
2261
+ commit(matched.length === 1 && spec.kind === "prop" ? matched[0]?.key : void 0);
2262
+ }
2263
+ if (event.key === "Escape") {
2264
+ setText("");
2265
+ setOpen(false);
2266
+ }
3373
2267
  }
3374
- }
3375
- }) })
2268
+ })
2269
+ })
3376
2270
  }),
3377
- invalid ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineInvalid, { children: t("unknownProperty") }) : null,
2271
+ invalid ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2272
+ className: schema_form_module_css_default.lineInvalid,
2273
+ children: t("unknownProperty")
2274
+ }) : null,
3378
2275
  !invalid && matched.length === 1 && matched[0]?.description !== void 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TruncatedTooltip, {
3379
2276
  label: resolveText(matched[0].description),
3380
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LineComment, { children: resolveText(matched[0].description) })
2277
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2278
+ className: schema_form_module_css_default.lineComment,
2279
+ children: resolveText(matched[0].description)
2280
+ })
3381
2281
  }) : null
3382
2282
  ]
3383
2283
  });
@@ -3395,7 +2295,8 @@ window.__ModuleLoader__.load({
3395
2295
  save: t("save"),
3396
2296
  saving: t("saving")
3397
2297
  };
3398
- if (!state.configured) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Hint$1, {
2298
+ if (!state.configured) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
2299
+ className: schema_form_module_css_default.hint,
3399
2300
  role: "status",
3400
2301
  children: t("noSchema")
3401
2302
  });
@@ -3418,7 +2319,8 @@ window.__ModuleLoader__.load({
3418
2319
  ...owner,
3419
2320
  onEditText: withParse(owner, t)
3420
2321
  } }) })
3421
- }), state.violation === void 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Hint$1, {
2322
+ }), state.violation === void 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
2323
+ className: schema_form_module_css_default.hint,
3422
2324
  role: "alert",
3423
2325
  "data-violation": "true",
3424
2326
  children: t("notSaved", { message: state.violation.message })
@@ -3432,6 +2334,29 @@ window.__ModuleLoader__.load({
3432
2334
  }
3433
2335
  //#endregion
3434
2336
  //#region ../../client/ui-primitives/src/client/schema-form/index.ts
2337
+ var schema_form_exports = /* @__PURE__ */ __exportAll({
2338
+ InlineValue: () => InlineValue,
2339
+ NS: () => NS$1,
2340
+ SchemaFieldDefault: () => SchemaFieldDefault,
2341
+ SchemaFormController: () => SchemaFormController,
2342
+ SchemaFormHints: () => SchemaFormHints,
2343
+ apply: () => apply$2,
2344
+ canRender: () => canRender,
2345
+ containerShape: () => containerShape,
2346
+ editorLines: () => editorLines,
2347
+ failureOf: () => failureOf,
2348
+ inject: () => inject$2,
2349
+ optionsFor: () => optionsFor,
2350
+ parseFor: () => parseFor,
2351
+ projectNode: () => projectNode,
2352
+ projectRoot: () => projectRoot,
2353
+ rowRegistrations: () => rowRegistrations,
2354
+ tokenText: () => tokenText,
2355
+ tokenTone: () => tokenTone,
2356
+ valueText: () => valueText,
2357
+ visibleFields: () => visibleFields,
2358
+ walkFields: () => walkFields
2359
+ });
3435
2360
  const NS$1 = "settings.schema-form";
3436
2361
  const inject$2 = [
3437
2362
  "slots",
@@ -3543,205 +2468,835 @@ window.__ModuleLoader__.load({
3543
2468
  }, "ui-schema-form: row registrations");
3544
2469
  }
3545
2470
  //#endregion
3546
- //#region ../../client/ui-primitives/src/client/styling/focus.ts
3547
- const focusRing = `${String(dsw.focus.ring.width)} solid ${Token.collect(Token.fallbackVar(dsw.focus.ring.color, String(dsw.alias.state.business.primary)))}`;
3548
- //#endregion
3549
- //#region ../../client/ui-primitives/src/client/settings-form/fields.styles.ts
3550
- const helpButtonHoverBackground = "var(--dsw-alias-bg-layer-4)";
3551
- const styles$2 = {
3552
- field: {
3553
- display: "flex",
3554
- flexDirection: "column",
3555
- gap: "6px",
3556
- padding: "12px 0",
3557
- "& + &": { borderTop: `0.5px solid ${String(dsw.alias.border.l2)}` }
3558
- },
3559
- head: {
3560
- display: "flex",
3561
- alignItems: "center",
3562
- gap: "8px"
3563
- },
3564
- label: {
3565
- flex: 1,
3566
- minWidth: 0,
3567
- fontSize: "13px",
3568
- fontWeight: 500,
3569
- lineHeight: 1.5,
3570
- color: dsw.alias.label.primary
3571
- },
3572
- groupLabel: { flex: "0 1 auto" },
3573
- labelGroup: {
3574
- display: "flex",
3575
- alignItems: "center",
3576
- gap: "4px",
3577
- flex: 1,
3578
- minWidth: 0
3579
- },
3580
- helpButton: {
3581
- display: "inline-flex",
3582
- alignItems: "center",
3583
- justifyContent: "center",
3584
- flex: "none",
3585
- width: "24px",
3586
- height: "24px",
3587
- padding: 0,
3588
- border: 0,
3589
- borderRadius: "6px",
3590
- background: "none",
3591
- color: dsw.alias.label.tertiary,
3592
- cursor: "pointer",
3593
- "&:hover": {
3594
- background: helpButtonHoverBackground,
3595
- color: dsw.alias.label.secondary
3596
- },
3597
- "&[aria-expanded='true']": {
3598
- background: helpButtonHoverBackground,
3599
- color: dsw.alias.label.secondary
3600
- },
3601
- "&:focus-visible": {
3602
- outline: focusRing,
3603
- outlineOffset: "1px"
3604
- }
3605
- },
3606
- help: {
3607
- padding: "10px 0 0",
3608
- fontSize: "12px",
3609
- lineHeight: 1.6,
3610
- color: dsw.alias.label.secondary,
3611
- "& > p": { margin: 0 },
3612
- "& > p + p": { marginTop: "8px" }
3613
- },
3614
- badges: {
3615
- display: "inline-flex",
3616
- alignItems: "center",
3617
- gap: "8px"
3618
- },
3619
- badge: {
3620
- display: "inline-flex",
3621
- alignItems: "center",
3622
- borderRadius: "999px",
3623
- cornerShape: "round",
3624
- padding: "1px 8px",
3625
- fontSize: "11px",
3626
- lineHeight: "17px",
3627
- fontWeight: 500,
3628
- whiteSpace: "nowrap"
3629
- },
3630
- badgeNeutral: {
3631
- background: dsw.alias.bg.module.platform,
3632
- color: dsw.alias.label.secondary
3633
- },
3634
- badgeQuiet: { color: dsw.alias.label.tertiary },
3635
- reset: {
3636
- border: "none",
3637
- background: "none",
3638
- padding: 0,
3639
- font: "inherit",
3640
- fontSize: "12px",
3641
- lineHeight: 1.5,
3642
- color: dsw.alias.label.secondary,
3643
- cursor: "pointer",
3644
- "&:hover:not(:disabled)": { color: dsw.alias.label.primary },
3645
- "&:disabled": { cursor: "default" }
3646
- },
3647
- input: {
3648
- height: "34px",
3649
- padding: "0 12px",
3650
- border: `0.5px solid ${String(dsw.alias.border.l4)}`,
3651
- borderRadius: "8px",
3652
- background: dsw.alias.bg.layer["3"],
3653
- font: "inherit",
3654
- fontSize: "13px",
3655
- lineHeight: 1.5,
3656
- color: dsw.alias.label.primary,
3657
- "&:focus-visible": {
3658
- outline: "none",
3659
- borderColor: dsw.alias.state.business.primary
3660
- },
3661
- "&:disabled": {
3662
- color: dsw.alias.label.tertiary,
3663
- cursor: "default"
2471
+ //#region ../../client/ui-primitives/src/client/markdown-labels.ts
2472
+ function markdownLabels(t) {
2473
+ return {
2474
+ code: {
2475
+ copyLabel: t("copy"),
2476
+ copiedLabel: t("copied")
3664
2477
  },
3665
- "&[aria-invalid='true']": { borderColor: dsw.alias.state.error.primary }
3666
- },
3667
- invalid: {
3668
- margin: 0,
3669
- fontSize: "12px",
3670
- lineHeight: 1.5,
3671
- color: dsw.alias.state.error.primary
3672
- },
3673
- hint: {
3674
- margin: 0,
3675
- fontSize: "12px",
3676
- lineHeight: 1.5,
3677
- color: dsw.alias.label.tertiary
3678
- }
2478
+ footnotes: t("markdown.footnotes")
2479
+ };
2480
+ }
2481
+ //#endregion
2482
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/layout/layout.module.css.mjs
2483
+ const css$15 = ".e_G4ZW_stack{flex-direction:column;min-width:0;display:flex}.e_G4ZW_row{flex-direction:row;align-items:center;min-width:0;display:flex}.e_G4ZW_gap0{gap:0}.e_G4ZW_gap2{gap:2px}.e_G4ZW_gap4{gap:4px}.e_G4ZW_gap6{gap:6px}.e_G4ZW_gap8{gap:8px}.e_G4ZW_gap10{gap:10px}.e_G4ZW_gap12{gap:12px}.e_G4ZW_gap14{gap:14px}.e_G4ZW_gap16{gap:16px}.e_G4ZW_alignStart{align-items:flex-start}.e_G4ZW_alignCenter{align-items:center}.e_G4ZW_alignEnd{align-items:flex-end}.e_G4ZW_justifyBetween{justify-content:space-between}.e_G4ZW_justifyEnd{justify-content:flex-end}.e_G4ZW_justifyCenter{justify-content:center}.e_G4ZW_wrap{flex-wrap:wrap}.e_G4ZW_grow{flex:auto;min-width:0}.e_G4ZW_push{margin-left:auto}.e_G4ZW_fill{box-sizing:border-box;width:100%;height:100%;overflow:hidden}.e_G4ZW_scroll{flex:auto;min-height:0;overflow-y:auto}.e_G4ZW_plain{margin:0;padding:0;list-style:none}.e_G4ZW_padNone{padding:0}.e_G4ZW_padCard{padding:8px 12px}.e_G4ZW_padBody{padding:8px 0}.e_G4ZW_padPage{padding:24px 28px}.e_G4ZW_padRow{padding:10px 12px}.e_G4ZW_padBlocking{padding:32px 40px}.e_G4ZW_text{margin:0}.e_G4ZW_sizeXs{font-size:11px;line-height:1.5}.e_G4ZW_sizeSm{font-size:12px;line-height:18px}.e_G4ZW_sizeMd{font-size:13px;line-height:20px}.e_G4ZW_sizeBase{font-size:14px;line-height:24px}.e_G4ZW_sizeLg{font-size:16px;line-height:24px}.e_G4ZW_tonePrimary{color:var(--dsw-alias-label-primary)}.e_G4ZW_toneSecondary{color:var(--dsw-alias-label-secondary)}.e_G4ZW_toneTertiary{color:var(--dsw-alias-label-tertiary)}.e_G4ZW_toneDanger{color:var(--dsw-alias-label-error,var(--dsw-alias-label-primary))}.e_G4ZW_weightMedium{font-weight:500}.e_G4ZW_strong{font-weight:600}.e_G4ZW_mono{word-break:break-all;font-family:ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,monospace}.e_G4ZW_truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.e_G4ZW_tabular{font-variant-numeric:tabular-nums}.e_G4ZW_boxed{border:1px solid var(--dsw-alias-border-l1);background:var(--dsw-alias-bg-base);border-radius:10px}.e_G4ZW_fixed{flex:none}.e_G4ZW_gapWide{gap:6px 20px}.e_G4ZW_narrow{min-width:0;max-width:min(calc(var(--dsh-chat-content-width,748px) * .702), 82%)}.e_G4ZW_wSearch{flex:none;width:360px;max-width:100%}";
2484
+ const tagId$15 = "@morlay/ui-conversation-manager/layout.module.css";
2485
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/layout.module.css\"]") === null) {
2486
+ const tag = document.createElement("style");
2487
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2488
+ tag.dataset.pluginCss = tagId$15;
2489
+ tag.textContent = css$15;
2490
+ document.head.appendChild(tag);
2491
+ }
2492
+ var layout_module_css_default = {
2493
+ "stack": "e_G4ZW_stack",
2494
+ "boxed": "e_G4ZW_boxed",
2495
+ "justifyEnd": "e_G4ZW_justifyEnd",
2496
+ "fill": "e_G4ZW_fill",
2497
+ "mono": "e_G4ZW_mono",
2498
+ "weightMedium": "e_G4ZW_weightMedium",
2499
+ "padNone": "e_G4ZW_padNone",
2500
+ "tabular": "e_G4ZW_tabular",
2501
+ "padCard": "e_G4ZW_padCard",
2502
+ "fixed": "e_G4ZW_fixed",
2503
+ "justifyCenter": "e_G4ZW_justifyCenter",
2504
+ "gap12": "e_G4ZW_gap12",
2505
+ "alignEnd": "e_G4ZW_alignEnd",
2506
+ "gap4": "e_G4ZW_gap4",
2507
+ "padRow": "e_G4ZW_padRow",
2508
+ "gap8": "e_G4ZW_gap8",
2509
+ "gap6": "e_G4ZW_gap6",
2510
+ "padBody": "e_G4ZW_padBody",
2511
+ "sizeSm": "e_G4ZW_sizeSm",
2512
+ "padPage": "e_G4ZW_padPage",
2513
+ "gap10": "e_G4ZW_gap10",
2514
+ "alignStart": "e_G4ZW_alignStart",
2515
+ "push": "e_G4ZW_push",
2516
+ "sizeLg": "e_G4ZW_sizeLg",
2517
+ "toneDanger": "e_G4ZW_toneDanger",
2518
+ "gapWide": "e_G4ZW_gapWide",
2519
+ "sizeMd": "e_G4ZW_sizeMd",
2520
+ "gap2": "e_G4ZW_gap2",
2521
+ "wrap": "e_G4ZW_wrap",
2522
+ "justifyBetween": "e_G4ZW_justifyBetween",
2523
+ "toneSecondary": "e_G4ZW_toneSecondary",
2524
+ "scroll": "e_G4ZW_scroll",
2525
+ "toneTertiary": "e_G4ZW_toneTertiary",
2526
+ "text": "e_G4ZW_text",
2527
+ "sizeBase": "e_G4ZW_sizeBase",
2528
+ "strong": "e_G4ZW_strong",
2529
+ "gap0": "e_G4ZW_gap0",
2530
+ "sizeXs": "e_G4ZW_sizeXs",
2531
+ "truncate": "e_G4ZW_truncate",
2532
+ "grow": "e_G4ZW_grow",
2533
+ "narrow": "e_G4ZW_narrow",
2534
+ "gap14": "e_G4ZW_gap14",
2535
+ "wSearch": "e_G4ZW_wSearch",
2536
+ "tonePrimary": "e_G4ZW_tonePrimary",
2537
+ "row": "e_G4ZW_row",
2538
+ "gap16": "e_G4ZW_gap16",
2539
+ "padBlocking": "e_G4ZW_padBlocking",
2540
+ "alignCenter": "e_G4ZW_alignCenter",
2541
+ "plain": "e_G4ZW_plain"
3679
2542
  };
3680
- styled("div")(styles$2.field);
3681
- styled("div")(styles$2.head);
3682
- styled("div")(styles$2.labelGroup);
3683
- styled("label")(styles$2.label, styles$2.groupLabel);
3684
- styled("label")(styles$2.label);
3685
- styled("button")(styles$2.helpButton);
3686
- styled("div")(styles$2.help);
3687
- styled("span")(styles$2.badges);
3688
- styled("span")(styles$2.badge, styles$2.badgeNeutral);
3689
- styled("span")(styles$2.badge, styles$2.badgeQuiet);
3690
- styled("button")(styles$2.reset);
3691
- styled("input")(styles$2.input);
3692
- styled("p")(styles$2.invalid);
3693
- styled("p")(styles$2.hint);
3694
- const styles$1 = {
3695
- form: {
3696
- display: "flex",
3697
- flexDirection: "column"
3698
- },
3699
- notice: {
3700
- margin: "0 0 12px",
3701
- fontSize: "12px",
3702
- lineHeight: 1.5,
3703
- color: dsw.alias.label.tertiary
3704
- },
3705
- footer: {
3706
- display: "flex",
3707
- alignItems: "center",
3708
- gap: "8px",
3709
- paddingTop: "16px"
3710
- },
3711
- failed: {
3712
- flex: 1,
3713
- minWidth: 0,
3714
- margin: 0,
3715
- fontSize: "12px",
3716
- lineHeight: 1.5,
3717
- color: "var(--dsw-alias-label-error)"
3718
- },
3719
- save: {
3720
- appearance: "none",
3721
- border: "1px solid transparent",
3722
- borderRadius: "8px",
3723
- padding: "5px 14px",
3724
- font: "inherit",
3725
- fontSize: "13px",
3726
- lineHeight: 1.5,
3727
- cursor: "pointer",
3728
- background: dsw.alias.label.primary,
3729
- color: dsw.alias.bg.layer["3"],
3730
- "&:disabled": {
3731
- opacity: .4,
3732
- cursor: "default"
3733
- },
3734
- "&:focus-visible": {
3735
- outline: focusRing,
3736
- outlineOffset: "1px"
3737
- }
2543
+ //#endregion
2544
+ //#region ../../client/ui-primitives/src/client/layout/scales.ts
2545
+ function gapClass(css, gap) {
2546
+ if (gap === void 0) return void 0;
2547
+ return gap === "wide" ? css.gapWide : css[`gap${gap}`];
2548
+ }
2549
+ function alignClass(css, align) {
2550
+ if (align === void 0 || align === "stretch") return void 0;
2551
+ if (align === "start") return css.alignStart;
2552
+ return align === "center" ? css.alignCenter : css.alignEnd;
2553
+ }
2554
+ function justifyClass(css, justify) {
2555
+ if (justify === void 0) return void 0;
2556
+ if (justify === "between") return css.justifyBetween;
2557
+ if (justify === "end") return css.justifyEnd;
2558
+ return justify === "center" ? css.justifyCenter : void 0;
2559
+ }
2560
+ function padClass(css, pad) {
2561
+ if (pad === void 0 || pad === "none") return void 0;
2562
+ if (pad === "card") return css.padCard;
2563
+ if (pad === "body") return css.padBody;
2564
+ if (pad === "page") return css.padPage;
2565
+ return pad === "row" ? css.padRow : css.padBlocking;
2566
+ }
2567
+ function sizeClass(css, size) {
2568
+ if (size === void 0) return void 0;
2569
+ if (size === "xs") return css.sizeXs;
2570
+ if (size === "sm") return css.sizeSm;
2571
+ if (size === "md") return css.sizeMd;
2572
+ return size === "base" ? css.sizeBase : css.sizeLg;
2573
+ }
2574
+ function toneClass(css, tone) {
2575
+ if (tone === void 0) return void 0;
2576
+ if (tone === "primary") return css.tonePrimary;
2577
+ if (tone === "secondary") return css.toneSecondary;
2578
+ return tone === "tertiary" ? css.toneTertiary : css.toneDanger;
2579
+ }
2580
+ function weightClass(css, weight) {
2581
+ if (weight === void 0) return void 0;
2582
+ return weight === "medium" ? css.weightMedium : css.strong;
2583
+ }
2584
+ //#endregion
2585
+ //#region ../../client/ui-primitives/src/client/layout/Row.tsx
2586
+ const Row = (0, react.forwardRef)(function Row({ as: Element = "div", gap, align, justify, wrap = false, grow = false, boxed = false, fixed = false, narrow = false, push = false, plain = false, pad, className, children, ...rest }, ref) {
2587
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Element, {
2588
+ ref,
2589
+ className: classes(layout_module_css_default.row, gapClass(layout_module_css_default, gap), alignClass(layout_module_css_default, align), justifyClass(layout_module_css_default, justify), padClass(layout_module_css_default, pad), wrap ? layout_module_css_default.wrap : void 0, grow ? layout_module_css_default.grow : void 0, boxed ? layout_module_css_default.boxed : void 0, fixed ? layout_module_css_default.fixed : void 0, narrow ? layout_module_css_default.narrow : void 0, push ? layout_module_css_default.push : void 0, boxed ? layout_module_css_default.boxed : void 0, fixed ? layout_module_css_default.fixed : void 0, plain ? layout_module_css_default.plain : void 0, className),
2590
+ ...rest,
2591
+ children
2592
+ });
2593
+ });
2594
+ //#endregion
2595
+ //#region ../../client/ui-primitives/src/client/layout/Stack.tsx
2596
+ const Stack = (0, react.forwardRef)(function Stack({ as: Element = "div", gap, align, pad, grow = false, boxed = false, fixed = false, narrow = false, fill = false, scroll = false, plain = false, className, children, ...rest }, ref) {
2597
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Element, {
2598
+ ref,
2599
+ className: classes(layout_module_css_default.stack, gapClass(layout_module_css_default, gap), alignClass(layout_module_css_default, align), padClass(layout_module_css_default, pad), grow ? layout_module_css_default.grow : void 0, boxed ? layout_module_css_default.boxed : void 0, fixed ? layout_module_css_default.fixed : void 0, narrow ? layout_module_css_default.narrow : void 0, fill ? layout_module_css_default.fill : void 0, scroll ? layout_module_css_default.scroll : void 0, plain ? layout_module_css_default.plain : void 0, className),
2600
+ ...rest,
2601
+ children
2602
+ });
2603
+ });
2604
+ //#endregion
2605
+ //#region ../../client/ui-primitives/src/client/layout/Text.tsx
2606
+ function Text({ as: Element = "span", size, tone, weight, mono = false, truncate = false, tabular = false, className, children }) {
2607
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Element, {
2608
+ className: classes(layout_module_css_default.text, sizeClass(layout_module_css_default, size), toneClass(layout_module_css_default, tone), weightClass(layout_module_css_default, weight), mono ? layout_module_css_default.mono : void 0, truncate ? layout_module_css_default.truncate : void 0, tabular ? layout_module_css_default.tabular : void 0, className),
2609
+ children
2610
+ });
2611
+ }
2612
+ //#endregion
2613
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/settings-form/SettingsFieldRow.module.css.mjs
2614
+ const css$14 = "._72UBVa_row{flex-direction:column;display:flex}._72UBVa_row[data-divider=true]{border-top:.5px solid var(--dsw-alias-border-l2)}._72UBVa_body{flex-direction:column;gap:6px;padding:12px 0;display:flex}._72UBVa_inline{flex-direction:row;justify-content:space-between;align-items:center;gap:16px;padding:12px 0;display:flex}._72UBVa_text{flex-direction:column;gap:2px;min-width:0;display:flex}._72UBVa_label{color:var(--dsw-alias-label-primary);align-items:center;gap:8px;font-size:13px;font-weight:500;line-height:1.5;display:flex}._72UBVa_badge{corner-shape:round;color:var(--dsw-alias-label-secondary);background:var(--dsw-alias-bg-module-platform);border-radius:999px;align-items:center;padding:1px 8px;font-size:11px;font-weight:500;line-height:17px;display:inline-flex}._72UBVa_reset{font:inherit;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:none;padding:0;font-size:12px;line-height:1.5}._72UBVa_reset:hover:not(:disabled){color:var(--dsw-alias-label-primary)}._72UBVa_reset:disabled{cursor:default}._72UBVa_hint{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:1.5}._72UBVa_invalid{color:var(--dsw-alias-state-error-primary);margin:0;font-size:12px;line-height:1.5}";
2615
+ const tagId$14 = "@morlay/ui-conversation-manager/SettingsFieldRow.module.css";
2616
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/SettingsFieldRow.module.css\"]") === null) {
2617
+ const tag = document.createElement("style");
2618
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2619
+ tag.dataset.pluginCss = tagId$14;
2620
+ tag.textContent = css$14;
2621
+ document.head.appendChild(tag);
2622
+ }
2623
+ var SettingsFieldRow_module_css_default = {
2624
+ "invalid": "_72UBVa_invalid",
2625
+ "inline": "_72UBVa_inline",
2626
+ "body": "_72UBVa_body",
2627
+ "label": "_72UBVa_label",
2628
+ "row": "_72UBVa_row",
2629
+ "text": "_72UBVa_text",
2630
+ "badge": "_72UBVa_badge",
2631
+ "reset": "_72UBVa_reset",
2632
+ "hint": "_72UBVa_hint"
2633
+ };
2634
+ //#endregion
2635
+ //#region ../../client/ui-primitives/src/client/settings-form/SettingsFieldRow.tsx
2636
+ function SettingsFieldRow({ label, hint, layout = "stack", divider = false, overriddenLabel, resetLabel, onReset, invalid, children, className, ...rest }) {
2637
+ const labelNode = /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
2638
+ className: SettingsFieldRow_module_css_default.label,
2639
+ children: [label, overriddenLabel === void 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2640
+ className: SettingsFieldRow_module_css_default.badge,
2641
+ children: overriddenLabel
2642
+ }), resetLabel === void 0 || onReset === void 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
2643
+ type: "button",
2644
+ className: SettingsFieldRow_module_css_default.reset,
2645
+ onClick: () => {
2646
+ onReset();
2647
+ },
2648
+ children: resetLabel
2649
+ })] })]
2650
+ });
2651
+ const invalidNode = invalid === void 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
2652
+ className: SettingsFieldRow_module_css_default.invalid,
2653
+ role: "alert",
2654
+ children: invalid
2655
+ });
2656
+ if (layout === "inline") return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
2657
+ className: classes(SettingsFieldRow_module_css_default.row, className),
2658
+ "data-role": "field-row",
2659
+ "data-divider": divider ? "true" : "false",
2660
+ ...rest,
2661
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
2662
+ className: SettingsFieldRow_module_css_default.inline,
2663
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
2664
+ className: SettingsFieldRow_module_css_default.text,
2665
+ children: [labelNode, /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
2666
+ className: SettingsFieldRow_module_css_default.hint,
2667
+ children: hint
2668
+ })]
2669
+ }), children]
2670
+ }), invalidNode]
2671
+ });
2672
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
2673
+ className: classes(SettingsFieldRow_module_css_default.row, className),
2674
+ "data-role": "field-row",
2675
+ "data-divider": divider ? "true" : "false",
2676
+ ...rest,
2677
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
2678
+ className: SettingsFieldRow_module_css_default.body,
2679
+ children: [
2680
+ labelNode,
2681
+ children,
2682
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
2683
+ className: SettingsFieldRow_module_css_default.hint,
2684
+ children: hint
2685
+ })
2686
+ ]
2687
+ }), invalidNode]
2688
+ });
2689
+ }
2690
+ //#endregion
2691
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/Bubble.module.css.mjs
2692
+ const css$13 = ".dtkLCG_bubble{background:var(--dsw-specific-bubble);border-radius:var(--dsw-radius-xl);max-width:100%;font-size:var(--dsh-content-font-size,14px);line-height:calc(22px + var(--dsh-content-font-delta,0px));color:var(--dsw-alias-label-primary);white-space:pre-wrap;word-break:break-word;padding:10px 16px}";
2693
+ const tagId$13 = "@morlay/ui-conversation-manager/Bubble.module.css";
2694
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/Bubble.module.css\"]") === null) {
2695
+ const tag = document.createElement("style");
2696
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2697
+ tag.dataset.pluginCss = tagId$13;
2698
+ tag.textContent = css$13;
2699
+ document.head.appendChild(tag);
2700
+ }
2701
+ var Bubble_module_css_default = { "bubble": "dtkLCG_bubble" };
2702
+ //#endregion
2703
+ //#region ../../client/ui-primitives/src/client/controls/Bubble.tsx
2704
+ function Bubble({ className, children, ...rest }) {
2705
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
2706
+ className: classes(Bubble_module_css_default.bubble, className),
2707
+ ...rest,
2708
+ children
2709
+ });
2710
+ }
2711
+ //#endregion
2712
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/Button.module.css.mjs
2713
+ const css$12 = ".WFViLq_label{white-space:nowrap}.WFViLq_danger{--dsw-alias-button-primary-fill:var(--dsw-alias-state-error-primary)}";
2714
+ const tagId$12 = "@morlay/ui-conversation-manager/Button.module.css";
2715
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/Button.module.css\"]") === null) {
2716
+ const tag = document.createElement("style");
2717
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2718
+ tag.dataset.pluginCss = tagId$12;
2719
+ tag.textContent = css$12;
2720
+ document.head.appendChild(tag);
2721
+ }
2722
+ var Button_module_css_default = {
2723
+ "label": "WFViLq_label",
2724
+ "danger": "WFViLq_danger"
2725
+ };
2726
+ //#endregion
2727
+ //#region ../../client/ui-primitives/src/client/controls/Button.tsx
2728
+ const Button$1 = (0, react.forwardRef)(function Button({ className, tone, ...rest }, ref) {
2729
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
2730
+ ref,
2731
+ "data-role": "button",
2732
+ className: classes(className, Button_module_css_default.label, tone === "danger" ? Button_module_css_default.danger : void 0),
2733
+ ...rest
2734
+ });
2735
+ });
2736
+ //#endregion
2737
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/DisclosureRow.module.css.mjs
2738
+ const css$11 = ".MBWCEG_content{flex:auto;min-width:0}.MBWCEG_contentLayout{align-items:center;gap:8px;width:100%;min-width:0;display:flex}";
2739
+ const tagId$11 = "@morlay/ui-conversation-manager/DisclosureRow.module.css";
2740
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/DisclosureRow.module.css\"]") === null) {
2741
+ const tag = document.createElement("style");
2742
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2743
+ tag.dataset.pluginCss = tagId$11;
2744
+ tag.textContent = css$11;
2745
+ document.head.appendChild(tag);
2746
+ }
2747
+ var DisclosureRow_module_css_default = {
2748
+ "contentLayout": "MBWCEG_contentLayout",
2749
+ "content": "MBWCEG_content"
2750
+ };
2751
+ //#endregion
2752
+ //#region ../../client/ui-primitives/src/client/controls/DisclosureRow.tsx
2753
+ function DisclosureRow(props) {
2754
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.DisclosureRow, {
2755
+ contentClassName: DisclosureRow_module_css_default.content,
2756
+ contentLayoutClassName: DisclosureRow_module_css_default.contentLayout,
2757
+ ...props
2758
+ });
2759
+ }
2760
+ //#endregion
2761
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/SearchInput.module.css.mjs
2762
+ const css$10 = ".KiR4MG_search{flex:none;width:360px;max-width:100%}.KiR4MG_full{flex:none;width:100%}";
2763
+ const tagId$10 = "@morlay/ui-conversation-manager/SearchInput.module.css";
2764
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/SearchInput.module.css\"]") === null) {
2765
+ const tag = document.createElement("style");
2766
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2767
+ tag.dataset.pluginCss = tagId$10;
2768
+ tag.textContent = css$10;
2769
+ document.head.appendChild(tag);
2770
+ }
2771
+ var SearchInput_module_css_default = {
2772
+ "full": "KiR4MG_full",
2773
+ "search": "KiR4MG_search"
2774
+ };
2775
+ //#endregion
2776
+ //#region ../../client/ui-primitives/src/client/controls/SearchInput.tsx
2777
+ function SearchInput({ width = "search", className, ...rest }) {
2778
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Input, {
2779
+ className: classes(className, width === "search" ? SearchInput_module_css_default.search : SearchInput_module_css_default.full),
2780
+ ...rest
2781
+ });
2782
+ }
2783
+ //#endregion
2784
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/SeatButton.module.css.mjs
2785
+ const css$9 = ".HcNbhG_seat{border-radius:var(--dsw-radius-sm);min-width:0;max-width:min(100%,240px);min-height:28px;color:var(--dsw-alias-label-primary);white-space:nowrap;cursor:pointer;background:0 0;border:none;align-items:center;gap:4px;padding:0 8px;font-size:13px;font-weight:500;line-height:20px;display:inline-flex}.HcNbhG_seat:not(:disabled):hover,.HcNbhG_seat[aria-expanded=true],.HcNbhG_expanded{background:var(--dsw-alias-interactive-bg-hover)}.HcNbhG_seat:disabled{cursor:default;color:var(--dsw-alias-label-quaternary)}.HcNbhG_icon{color:var(--dsw-alias-label-primary);flex:none;align-items:center;display:inline-flex}.HcNbhG_label{text-overflow:ellipsis;white-space:nowrap;min-width:0;overflow:hidden}.HcNbhG_chevron{color:var(--dsw-alias-label-caption);flex:none;display:inline-flex}";
2786
+ const tagId$9 = "@morlay/ui-conversation-manager/SeatButton.module.css";
2787
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/SeatButton.module.css\"]") === null) {
2788
+ const tag = document.createElement("style");
2789
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2790
+ tag.dataset.pluginCss = tagId$9;
2791
+ tag.textContent = css$9;
2792
+ document.head.appendChild(tag);
2793
+ }
2794
+ var SeatButton_module_css_default = {
2795
+ "seat": "HcNbhG_seat",
2796
+ "expanded": "HcNbhG_expanded",
2797
+ "icon": "HcNbhG_icon",
2798
+ "label": "HcNbhG_label",
2799
+ "chevron": "HcNbhG_chevron"
2800
+ };
2801
+ //#endregion
2802
+ //#region ../../client/ui-primitives/src/client/controls/SeatButton.tsx
2803
+ function SeatButton({ icon, label, expanded = false, chevron, type = "button", className, ...rest }) {
2804
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
2805
+ type,
2806
+ className: classes(SeatButton_module_css_default.seat, expanded ? SeatButton_module_css_default.expanded : void 0, className),
2807
+ ...rest,
2808
+ children: [
2809
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2810
+ className: SeatButton_module_css_default.icon,
2811
+ children: icon
2812
+ }),
2813
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2814
+ className: SeatButton_module_css_default.label,
2815
+ children: label
2816
+ }),
2817
+ chevron === void 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2818
+ className: SeatButton_module_css_default.chevron,
2819
+ children: chevron
2820
+ })
2821
+ ]
2822
+ });
2823
+ }
2824
+ //#endregion
2825
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/Spinner.module.css.mjs
2826
+ const css$8 = ".HGVDmW_spinner{border:2px solid var(--dsw-alias-border-l2);border-top-color:var(--dsw-alias-label-primary);border-radius:50%;width:28px;height:28px;animation:.9s linear infinite HGVDmW_spin}@keyframes HGVDmW_spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}";
2827
+ const tagId$8 = "@morlay/ui-conversation-manager/Spinner.module.css";
2828
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/Spinner.module.css\"]") === null) {
2829
+ const tag = document.createElement("style");
2830
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2831
+ tag.dataset.pluginCss = tagId$8;
2832
+ tag.textContent = css$8;
2833
+ document.head.appendChild(tag);
2834
+ }
2835
+ var Spinner_module_css_default = {
2836
+ "spinner": "HGVDmW_spinner",
2837
+ "spin": "HGVDmW_spin"
2838
+ };
2839
+ //#endregion
2840
+ //#region ../../client/ui-primitives/src/client/controls/Spinner.tsx
2841
+ function Spinner({ label }) {
2842
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2843
+ className: Spinner_module_css_default.spinner,
2844
+ role: "status",
2845
+ "aria-label": label
2846
+ });
2847
+ }
2848
+ //#endregion
2849
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/Tabs.module.css.mjs
2850
+ const css$7 = ".GO-36q_tabs{z-index:1;flex:none;gap:36px;margin-top:10px;padding-left:8px;display:flex;position:relative}.GO-36q_tab{color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:none;padding:0 0 9px;font-size:13px;font-weight:500;line-height:16px;position:relative}.GO-36q_tab:after{content:\"\";background:0 0;border-radius:2px;height:2px;position:absolute;bottom:-1px;left:0;right:0}.GO-36q_tabActive{color:var(--dsw-alias-state-business-primary)}.GO-36q_tabActive:after{background:var(--dsw-alias-state-business-primary)}.GO-36q_tab:disabled{cursor:not-allowed;opacity:.4}";
2851
+ const tagId$7 = "@morlay/ui-conversation-manager/Tabs.module.css";
2852
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/Tabs.module.css\"]") === null) {
2853
+ const tag = document.createElement("style");
2854
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2855
+ tag.dataset.pluginCss = tagId$7;
2856
+ tag.textContent = css$7;
2857
+ document.head.appendChild(tag);
2858
+ }
2859
+ var Tabs_module_css_default = {
2860
+ "tab": "GO-36q_tab",
2861
+ "tabs": "GO-36q_tabs",
2862
+ "tabActive": "GO-36q_tabActive"
2863
+ };
2864
+ //#endregion
2865
+ //#region ../../client/ui-primitives/src/client/controls/Tabs.tsx
2866
+ function Tabs({ label, items, value, onChange, role = "tablist", disabled = false }) {
2867
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
2868
+ className: Tabs_module_css_default.tabs,
2869
+ role,
2870
+ "aria-label": label,
2871
+ children: items.map((item) => {
2872
+ const active = item.value === value;
2873
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
2874
+ type: "button",
2875
+ role: role === "tablist" ? "tab" : "radio",
2876
+ "data-tab": item.value,
2877
+ "aria-selected": role === "tablist" ? active : void 0,
2878
+ "aria-checked": role === "tablist" ? void 0 : active,
2879
+ disabled,
2880
+ className: classes(Tabs_module_css_default.tab, active ? Tabs_module_css_default.tabActive : void 0),
2881
+ onClick: () => {
2882
+ onChange(item.value);
2883
+ },
2884
+ children: item.label
2885
+ }, item.value);
2886
+ })
2887
+ });
2888
+ }
2889
+ //#endregion
2890
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/TimeLabel.module.css.mjs
2891
+ const css$6 = "._3IuWPG_label{color:var(--dsw-alias-label-tertiary);white-space:nowrap;opacity:0;padding:0;font-size:14px;line-height:24px;transition:opacity 80ms}[data-time-hover-root]:hover ._3IuWPG_label,[data-time-hover-root]:focus-within ._3IuWPG_label{opacity:1}";
2892
+ const tagId$6 = "@morlay/ui-conversation-manager/TimeLabel.module.css";
2893
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/TimeLabel.module.css\"]") === null) {
2894
+ const tag = document.createElement("style");
2895
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2896
+ tag.dataset.pluginCss = tagId$6;
2897
+ tag.textContent = css$6;
2898
+ document.head.appendChild(tag);
2899
+ }
2900
+ var TimeLabel_module_css_default = { "label": "_3IuWPG_label" };
2901
+ //#endregion
2902
+ //#region ../../client/ui-primitives/src/client/controls/TimeLabel.tsx
2903
+ function TimeLabel({ className, children, ...rest }) {
2904
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2905
+ className: classes(TimeLabel_module_css_default.label, className),
2906
+ ...rest,
2907
+ children
2908
+ });
2909
+ }
2910
+ //#endregion
2911
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/VisuallyHidden.module.css.mjs
2912
+ const css$5 = ".YAvv4W_hidden{clip-path:inset(50%);white-space:nowrap;width:1px;height:1px;position:absolute;overflow:hidden}";
2913
+ const tagId$5 = "@morlay/ui-conversation-manager/VisuallyHidden.module.css";
2914
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/VisuallyHidden.module.css\"]") === null) {
2915
+ const tag = document.createElement("style");
2916
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2917
+ tag.dataset.pluginCss = tagId$5;
2918
+ tag.textContent = css$5;
2919
+ document.head.appendChild(tag);
2920
+ }
2921
+ var VisuallyHidden_module_css_default = { "hidden": "YAvv4W_hidden" };
2922
+ //#endregion
2923
+ //#region ../../client/ui-primitives/src/client/controls/VisuallyHidden.tsx
2924
+ function VisuallyHidden({ children, ...rest }) {
2925
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2926
+ className: VisuallyHidden_module_css_default.hidden,
2927
+ ...rest,
2928
+ children
2929
+ });
2930
+ }
2931
+ //#endregion
2932
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/IconButton.module.css.mjs
2933
+ const css$4 = ".I3t6Ga_iconButton{box-sizing:border-box;width:28px;height:28px;color:var(--dsw-alias-label-secondary);border-radius:var(--dsw-radius-sm);cursor:pointer;background:0 0;border:none;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.I3t6Ga_iconButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover)}.I3t6Ga_iconButton:disabled{cursor:not-allowed;opacity:.4}.I3t6Ga_iconButton:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:-2px}.I3t6Ga_sm{width:20px;height:20px;padding:0}.I3t6Ga_circle{color:var(--dsw-alias-label-tertiary);border-radius:28px;padding:6px}.I3t6Ga_circle:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-secondary)}";
2934
+ const tagId$4 = "@morlay/ui-conversation-manager/IconButton.module.css";
2935
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/IconButton.module.css\"]") === null) {
2936
+ const tag = document.createElement("style");
2937
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2938
+ tag.dataset.pluginCss = tagId$4;
2939
+ tag.textContent = css$4;
2940
+ document.head.appendChild(tag);
2941
+ }
2942
+ var IconButton_module_css_default = {
2943
+ "sm": "I3t6Ga_sm",
2944
+ "circle": "I3t6Ga_circle",
2945
+ "iconButton": "I3t6Ga_iconButton"
2946
+ };
2947
+ //#endregion
2948
+ //#region ../../client/ui-primitives/src/client/controls/IconButton.tsx
2949
+ function IconButton({ label, children, type = "button", shape = "square", size = "md", className, ...rest }) {
2950
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
2951
+ type,
2952
+ "data-role": "icon-button",
2953
+ "aria-label": label,
2954
+ className: classes(IconButton_module_css_default.iconButton, size === "sm" ? IconButton_module_css_default.sm : void 0, shape === "circle" ? IconButton_module_css_default.circle : void 0, className),
2955
+ ...rest,
2956
+ children
2957
+ });
2958
+ }
2959
+ //#endregion
2960
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/ModelRouteList.module.css.mjs
2961
+ const css$3 = "._2eBkWq_list{border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-lg);gap:6px;min-width:0;max-height:280px;margin:0;padding:10px;display:grid;overflow:auto}._2eBkWq_group{gap:6px;display:grid}._2eBkWq_group+._2eBkWq_group{border-top:.5px solid var(--dsw-alias-border-l3);margin-top:4px;padding-top:10px}._2eBkWq_provider{color:var(--dsw-alias-label-tertiary);padding:0 6px;font-size:11px;font-weight:500}._2eBkWq_item{border-radius:var(--dsw-radius-md);cursor:pointer;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:8px;min-width:0;padding:6px;display:grid}._2eBkWq_item:hover{background:var(--dsw-alias-bg-layer-4)}._2eBkWq_item:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:-2px}._2eBkWq_item[aria-disabled=true]{cursor:not-allowed;opacity:.4}._2eBkWq_picked{background:var(--dsw-alias-interactive-bg-hover)}._2eBkWq_text{min-width:0}._2eBkWq_name{text-overflow:ellipsis;white-space:nowrap;color:var(--dsw-alias-label-primary);font-size:13px;display:block;overflow:hidden}._2eBkWq_id{text-overflow:ellipsis;white-space:nowrap;color:var(--dsw-alias-label-tertiary);margin-top:2px;font-size:11px;display:block;overflow:hidden}._2eBkWq_notice{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:1.5}._2eBkWq_error{color:var(--dsw-alias-state-error-primary);margin:0;font-size:12px;line-height:1.5}";
2962
+ const tagId$3 = "@morlay/ui-conversation-manager/ModelRouteList.module.css";
2963
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/ModelRouteList.module.css\"]") === null) {
2964
+ const tag = document.createElement("style");
2965
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
2966
+ tag.dataset.pluginCss = tagId$3;
2967
+ tag.textContent = css$3;
2968
+ document.head.appendChild(tag);
2969
+ }
2970
+ var ModelRouteList_module_css_default = {
2971
+ "picked": "_2eBkWq_picked",
2972
+ "notice": "_2eBkWq_notice",
2973
+ "text": "_2eBkWq_text",
2974
+ "item": "_2eBkWq_item",
2975
+ "id": "_2eBkWq_id",
2976
+ "group": "_2eBkWq_group",
2977
+ "name": "_2eBkWq_name",
2978
+ "error": "_2eBkWq_error",
2979
+ "list": "_2eBkWq_list",
2980
+ "provider": "_2eBkWq_provider"
2981
+ };
2982
+ //#endregion
2983
+ //#region ../../client/ui-primitives/src/client/controls/ModelRouteList.tsx
2984
+ function ModelRouteList({ label, candidates, selectedKey, disabled = false, status, loadingLabel, errorLabel, emptyLabel, onSelect }) {
2985
+ if (status === "loading") return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
2986
+ className: ModelRouteList_module_css_default.notice,
2987
+ role: "status",
2988
+ children: loadingLabel
2989
+ });
2990
+ if (status === "error") return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
2991
+ className: ModelRouteList_module_css_default.error,
2992
+ role: "alert",
2993
+ children: errorLabel
2994
+ });
2995
+ if (candidates.length === 0) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
2996
+ className: ModelRouteList_module_css_default.notice,
2997
+ children: emptyLabel
2998
+ });
2999
+ const groups = /* @__PURE__ */ new Map();
3000
+ for (const candidate of candidates) {
3001
+ const group = groups.get(candidate.provider);
3002
+ if (group === void 0) groups.set(candidate.provider, {
3003
+ name: candidate.providerName,
3004
+ items: [candidate]
3005
+ });
3006
+ else group.items.push(candidate);
3007
+ }
3008
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
3009
+ className: ModelRouteList_module_css_default.list,
3010
+ "data-role": "model-route-list",
3011
+ role: "radiogroup",
3012
+ "aria-label": label,
3013
+ "data-control": "model-routes",
3014
+ children: [...groups].map(([provider, group]) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
3015
+ className: ModelRouteList_module_css_default.group,
3016
+ "data-route-group": provider,
3017
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
3018
+ className: ModelRouteList_module_css_default.provider,
3019
+ children: group.name
3020
+ }), group.items.map((candidate) => {
3021
+ const picked = candidate.key === selectedKey;
3022
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
3023
+ className: classes(ModelRouteList_module_css_default.item, picked ? ModelRouteList_module_css_default.picked : void 0),
3024
+ role: "radio",
3025
+ "aria-checked": picked,
3026
+ "aria-label": `${candidate.modelName} ${candidate.provider}/${candidate.model}`,
3027
+ "aria-disabled": disabled ? true : void 0,
3028
+ tabIndex: disabled ? -1 : 0,
3029
+ "data-route": candidate.key,
3030
+ onClick: () => {
3031
+ if (!disabled) onSelect(candidate);
3032
+ },
3033
+ onKeyDown: (event) => {
3034
+ if (event.key !== "Enter" && event.key !== " ") return;
3035
+ event.preventDefault();
3036
+ if (!disabled) onSelect(candidate);
3037
+ },
3038
+ children: [picked ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconCheckOutlineRegular, {}) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { "aria-hidden": "true" }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
3039
+ className: ModelRouteList_module_css_default.text,
3040
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
3041
+ className: ModelRouteList_module_css_default.name,
3042
+ children: candidate.modelName
3043
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
3044
+ className: ModelRouteList_module_css_default.id,
3045
+ children: `${candidate.providerName} · ${candidate.provider}/${candidate.model}`
3046
+ })]
3047
+ })]
3048
+ }, candidate.key);
3049
+ })]
3050
+ }, provider))
3051
+ });
3052
+ }
3053
+ //#endregion
3054
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/MultilineField.module.css.mjs
3055
+ const css$2 = "._stHfW_multiline{box-sizing:border-box;width:100%;min-height:64px;color:var(--dsw-alias-label-primary);background:var(--dsw-alias-bg-layer-3);border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-md);resize:vertical;padding:6px 12px;font-family:inherit;font-size:13px;line-height:1.5}._stHfW_multiline:disabled{cursor:not-allowed;opacity:.4}._stHfW_multiline:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:-2px}";
3056
+ const tagId$2 = "@morlay/ui-conversation-manager/MultilineField.module.css";
3057
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/MultilineField.module.css\"]") === null) {
3058
+ const tag = document.createElement("style");
3059
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
3060
+ tag.dataset.pluginCss = tagId$2;
3061
+ tag.textContent = css$2;
3062
+ document.head.appendChild(tag);
3063
+ }
3064
+ var MultilineField_module_css_default = { "multiline": "_stHfW_multiline" };
3065
+ //#endregion
3066
+ //#region ../../client/ui-primitives/src/client/controls/MultilineField.tsx
3067
+ function MultilineField({ rows = 3, className, ...rest }) {
3068
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("textarea", {
3069
+ rows,
3070
+ "data-role": "multiline-field",
3071
+ className: classes(MultilineField_module_css_default.multiline, className),
3072
+ ...rest
3073
+ });
3074
+ }
3075
+ //#endregion
3076
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/SearchSelect.module.css.mjs
3077
+ const css$1 = ".BtUTmW_trigger{white-space:nowrap;height:32px}.BtUTmW_searchRow{border-bottom:.5px solid var(--dsw-alias-border-l2);align-items:center;padding:4px 8px 8px;display:flex}.BtUTmW_searchInput{width:100%;color:var(--dsw-alias-label-primary);background:0 0;border:none;outline:none;padding:2px 0;font-family:inherit;font-size:13px;line-height:1.5}.BtUTmW_empty{color:var(--dsw-alias-label-tertiary);margin:0;padding:8px;font-size:12px;line-height:1.5}";
3078
+ const tagId$1 = "@morlay/ui-conversation-manager/SearchSelect.module.css";
3079
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/SearchSelect.module.css\"]") === null) {
3080
+ const tag = document.createElement("style");
3081
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
3082
+ tag.dataset.pluginCss = tagId$1;
3083
+ tag.textContent = css$1;
3084
+ document.head.appendChild(tag);
3085
+ }
3086
+ var SearchSelect_module_css_default = {
3087
+ "trigger": "BtUTmW_trigger",
3088
+ "searchInput": "BtUTmW_searchInput",
3089
+ "empty": "BtUTmW_empty",
3090
+ "searchRow": "BtUTmW_searchRow"
3091
+ };
3092
+ //#endregion
3093
+ //#region ../../client/ui-primitives/src/client/controls/SearchSelect.tsx
3094
+ function SearchSelect({ label, value, emptyLabel, options, disabled = false, searchLabel, noMatchLabel, onSelect }) {
3095
+ const [open, setOpen] = (0, react.useState)(false);
3096
+ const [query, setQuery] = (0, react.useState)("");
3097
+ const searchRef = (0, react.useRef)(null);
3098
+ (0, react.useEffect)(() => {
3099
+ if (open) searchRef.current?.focus();
3100
+ }, [open]);
3101
+ const matches = (0, react.useMemo)(() => (0, _deepseek_ai_dsh_client_ui_primitives.rankByName)(options.map((option) => ({
3102
+ value: option.value,
3103
+ name: option.label ?? option.value,
3104
+ label: option.value
3105
+ })), query), [options, query]);
3106
+ const current = options.find((option) => option.value === value);
3107
+ const close = () => {
3108
+ setOpen(false);
3109
+ setQuery("");
3110
+ };
3111
+ const pick = (next) => {
3112
+ close();
3113
+ onSelect(next);
3114
+ };
3115
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_deepseek_ai_dsh_client_ui_primitives.Menu, {
3116
+ open,
3117
+ anchor: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
3118
+ variant: "outline",
3119
+ size: "sm",
3120
+ "data-role": "search-select",
3121
+ className: classes(SearchSelect_module_css_default.trigger),
3122
+ "data-action": "pick",
3123
+ disabled,
3124
+ "aria-haspopup": "menu",
3125
+ "aria-label": label,
3126
+ onClick: () => {
3127
+ if (open) close();
3128
+ else setOpen(true);
3129
+ },
3130
+ children: value === "" ? emptyLabel : current?.label ?? value
3131
+ }),
3132
+ selectedId: value,
3133
+ onSelect: pick,
3134
+ onClose: close,
3135
+ children: [
3136
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
3137
+ className: SearchSelect_module_css_default.searchRow,
3138
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
3139
+ className: SearchSelect_module_css_default.searchInput,
3140
+ ref: searchRef,
3141
+ value: query,
3142
+ "aria-label": searchLabel,
3143
+ placeholder: searchLabel,
3144
+ onChange: (event) => {
3145
+ setQuery(event.currentTarget.value);
3146
+ }
3147
+ })
3148
+ }),
3149
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.MenuItemButton, {
3150
+ icon: value === "" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconCheckOutlineRegular, {}) : void 0,
3151
+ onSelect: () => {
3152
+ pick("");
3153
+ },
3154
+ children: emptyLabel
3155
+ }),
3156
+ matches.map((option) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.MenuItemButton, {
3157
+ icon: option.value === value ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconCheckOutlineRegular, {}) : void 0,
3158
+ onSelect: () => {
3159
+ pick(option.value);
3160
+ },
3161
+ children: option.name
3162
+ }, option.value)),
3163
+ matches.length === 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
3164
+ className: SearchSelect_module_css_default.empty,
3165
+ children: noMatchLabel
3166
+ }) : null
3167
+ ]
3168
+ });
3169
+ }
3170
+ //#endregion
3171
+ //#region ../../client/ui-primitives/src/client/controls/tags.ts
3172
+ function parseTagList(text) {
3173
+ const seen = /* @__PURE__ */ new Set();
3174
+ const names = [];
3175
+ for (const raw of text.split(/[,,;;\t\n\r]+/u)) {
3176
+ const name = raw.trim();
3177
+ if (name === "" || seen.has(name)) continue;
3178
+ seen.add(name);
3179
+ names.push(name);
3180
+ }
3181
+ return names;
3182
+ }
3183
+ function mergeTags(current, incoming) {
3184
+ const merged = [...current];
3185
+ for (const name of incoming) {
3186
+ if (name === "" || merged.includes(name)) continue;
3187
+ merged.push(name);
3738
3188
  }
3189
+ return merged;
3190
+ }
3191
+ //#endregion
3192
+ //#region \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin/packages/client/ui-primitives/src/client/controls/TagInput.module.css.mjs
3193
+ const css = ".Is5kta_row{align-items:flex-start;gap:8px;width:100%;display:flex}.Is5kta_anchor{flex:auto;width:100%;min-width:0;display:flex}.Is5kta_box{box-sizing:border-box;background:var(--dsw-alias-bg-layer-3);border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-md);flex-flow:wrap;align-items:center;gap:4px 6px;width:100%;min-height:32px;padding:4px 8px;display:flex}.Is5kta_input{min-width:120px;color:var(--dsw-alias-label-primary);background:0 0;border:none;outline:none;flex:120px;padding:2px 0;font-family:inherit;font-size:13px;line-height:1.5}.Is5kta_chip{corner-shape:round;white-space:nowrap;color:var(--dsw-alias-label-secondary);background:var(--dsw-alias-bg-module-platform);border-radius:999px;align-items:center;gap:2px;padding:1px 4px 1px 8px;font-size:11px;font-weight:500;line-height:17px;display:inline-flex}.Is5kta_chipRemove{box-sizing:border-box;width:14px;height:14px;color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:none;border-radius:999px;flex:none;justify-content:center;align-items:center;padding:0;line-height:1;display:inline-flex}.Is5kta_chipRemove:hover:not(:disabled){color:var(--dsw-alias-label-primary);background:var(--dsw-alias-interactive-bg-hover)}.Is5kta_chipRemove:disabled{cursor:not-allowed;opacity:.4}.Is5kta_chipRemove:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:0}.Is5kta_empty{color:var(--dsw-alias-label-tertiary);margin:0;padding:8px;font-size:12px;line-height:1.5}";
3194
+ const tagId = "@morlay/ui-conversation-manager/TagInput.module.css";
3195
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/ui-conversation-manager/TagInput.module.css\"]") === null) {
3196
+ const tag = document.createElement("style");
3197
+ tag.dataset.plugin = "@morlay/ui-conversation-manager";
3198
+ tag.dataset.pluginCss = tagId;
3199
+ tag.textContent = css;
3200
+ document.head.appendChild(tag);
3201
+ }
3202
+ var TagInput_module_css_default = {
3203
+ "chipRemove": "Is5kta_chipRemove",
3204
+ "row": "Is5kta_row",
3205
+ "input": "Is5kta_input",
3206
+ "chip": "Is5kta_chip",
3207
+ "empty": "Is5kta_empty",
3208
+ "box": "Is5kta_box",
3209
+ "anchor": "Is5kta_anchor"
3739
3210
  };
3740
- styled("div")(styles$1.form);
3741
- styled("p")(styles$1.notice);
3742
- styled("div")(styles$1.footer);
3743
- styled("p")(styles$1.failed);
3744
- styled("button")(styles$1.save);
3211
+ //#endregion
3212
+ //#region ../../client/ui-primitives/src/client/controls/TagInput.tsx
3213
+ function TagInput({ value, onChange, options, placeholder, label, disabled = false, noMatchLabel = "", removeLabel }) {
3214
+ const [draft, setDraft] = (0, react.useState)("");
3215
+ const [open, setOpen] = (0, react.useState)(false);
3216
+ const commit = (text) => {
3217
+ const names = parseTagList(text);
3218
+ if (names.length === 0) return;
3219
+ onChange(mergeTags(value, names));
3220
+ setDraft("");
3221
+ };
3222
+ const remaining = (0, react.useMemo)(() => (options ?? []).filter((option) => !value.includes(option.value)).map((option) => ({
3223
+ value: option.value,
3224
+ name: option.label ?? option.value,
3225
+ label: option.value
3226
+ })), [options, value]);
3227
+ const matches = (0, react.useMemo)(() => (0, _deepseek_ai_dsh_client_ui_primitives.rankByName)(remaining, draft), [remaining, draft]);
3228
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
3229
+ className: TagInput_module_css_default.row,
3230
+ "data-role": "tag-input",
3231
+ "data-control": "tags",
3232
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_deepseek_ai_dsh_client_ui_primitives.Menu, {
3233
+ open: open && remaining.length > 0,
3234
+ className: TagInput_module_css_default.anchor,
3235
+ anchor: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
3236
+ className: TagInput_module_css_default.box,
3237
+ children: [value.map((name) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
3238
+ className: TagInput_module_css_default.chip,
3239
+ "data-tag": name,
3240
+ children: [name, /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
3241
+ type: "button",
3242
+ className: TagInput_module_css_default.chipRemove,
3243
+ "data-action": "remove-tag",
3244
+ disabled,
3245
+ "aria-label": removeLabel(name),
3246
+ onClick: () => {
3247
+ onChange(value.filter((candidate) => candidate !== name));
3248
+ },
3249
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconCloseOutlineRegular, { size: 10 })
3250
+ })]
3251
+ }, name)), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
3252
+ className: TagInput_module_css_default.input,
3253
+ value: draft,
3254
+ placeholder: value.length === 0 ? placeholder : "",
3255
+ "aria-label": label,
3256
+ disabled,
3257
+ onFocus: () => {
3258
+ setOpen(true);
3259
+ },
3260
+ onBlur: () => {
3261
+ setOpen(false);
3262
+ },
3263
+ onChange: (event) => {
3264
+ setDraft(event.currentTarget.value);
3265
+ },
3266
+ onKeyDown: (event) => {
3267
+ if (event.key !== "Enter") return;
3268
+ event.preventDefault();
3269
+ commit(draft);
3270
+ },
3271
+ onPaste: (event) => {
3272
+ const text = event.clipboardData.getData("text");
3273
+ if (parseTagList(text).length < 2) return;
3274
+ event.preventDefault();
3275
+ commit(text);
3276
+ }
3277
+ })]
3278
+ }),
3279
+ onClose: () => {
3280
+ setOpen(false);
3281
+ },
3282
+ children: [matches.map((candidate) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
3283
+ onMouseDown: (event) => {
3284
+ event.preventDefault();
3285
+ },
3286
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.MenuItemButton, {
3287
+ onSelect: () => {
3288
+ commit(candidate.value);
3289
+ },
3290
+ children: candidate.name
3291
+ })
3292
+ }, candidate.value)), matches.length === 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
3293
+ className: TagInput_module_css_default.empty,
3294
+ "data-role": "tag-input-empty",
3295
+ children: noMatchLabel
3296
+ }) : null]
3297
+ })
3298
+ });
3299
+ }
3745
3300
  //#endregion
3746
3301
  //#region ../../../node_modules/.pnpm/mdast-util-to-string@4.0.0/node_modules/mdast-util-to-string/lib/index.js
3747
3302
  /**
@@ -16210,6 +15765,7 @@ window.__ModuleLoader__.load({
16210
15765
  const LINE_FRAGMENT = /^L(\d+)(?:C(\d+))?(?:-L(\d+))?$/u;
16211
15766
  const SCHEME = /^([A-Za-z][A-Za-z0-9+.-]*):/u;
16212
15767
  const BARE_PATH = /^([^:]+):(\d+)(?::(\d+))?$/u;
15768
+ const MENTION_WHITESPACE = /\s/u;
16213
15769
  const URI_UNSAFE = /[%#()\s<>"`]/gu;
16214
15770
  const PATH_PUNCTUATION = [
16215
15771
  codes.slash,
@@ -16266,6 +15822,10 @@ window.__ModuleLoader__.load({
16266
15822
  function isLocalReference(reference) {
16267
15823
  return !EXTERNAL_PROTOCOLS.includes(reference.protocol);
16268
15824
  }
15825
+ function formatReferenceMention(reference) {
15826
+ const path = reference.path ?? "";
15827
+ return MENTION_WHITESPACE.test(path) ? `@"${path}"` : `@${path}`;
15828
+ }
16269
15829
  function findReferences(text) {
16270
15830
  const spans = [];
16271
15831
  if (text === "" || !TRIGGERS.some((trigger) => text.includes(trigger))) return spans;
@@ -16650,7 +16210,7 @@ window.__ModuleLoader__.load({
16650
16210
  };
16651
16211
  } };
16652
16212
  }
16653
- (0, react.memo)(function ReferenceMarkdown({ text, labels, actions, streaming = false, pathImages }) {
16213
+ const ReferenceMarkdown = (0, react.memo)(function ReferenceMarkdown({ text, labels, actions, streaming = false, pathImages }) {
16654
16214
  const { source, tokens } = (0, react.useMemo)(() => tokenizeReferences(text), [text]);
16655
16215
  const mentions = (0, react.useMemo)(() => referenceMentions(actions, tokens), [actions, tokens]);
16656
16216
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.MarkdownText, {
@@ -16694,7 +16254,51 @@ window.__ModuleLoader__.load({
16694
16254
  }
16695
16255
  if (reference.protocol === "file") actions.openFile(path);
16696
16256
  }
16697
- [...inject$2];
16257
+ //#endregion
16258
+ //#region ../../client/ui-primitives/src/client/index.ts
16259
+ var client_exports = /* @__PURE__ */ __exportAll({
16260
+ Bubble: () => Bubble,
16261
+ Button: () => Button$1,
16262
+ DisclosureRow: () => DisclosureRow,
16263
+ IconButton: () => IconButton,
16264
+ ModelRouteList: () => ModelRouteList,
16265
+ MultilineField: () => MultilineField,
16266
+ ReferenceMarkdown: () => ReferenceMarkdown,
16267
+ Row: () => Row,
16268
+ SCHEMA_FORM_NS: () => NS$1,
16269
+ SchemaFormController: () => SchemaFormController,
16270
+ SchemaFormHints: () => SchemaFormHints,
16271
+ SearchInput: () => SearchInput,
16272
+ SearchSelect: () => SearchSelect,
16273
+ SeatButton: () => SeatButton,
16274
+ SettingsFieldRow: () => SettingsFieldRow,
16275
+ Spinner: () => Spinner,
16276
+ Stack: () => Stack,
16277
+ Tabs: () => Tabs,
16278
+ TagInput: () => TagInput,
16279
+ Text: () => Text,
16280
+ TimeLabel: () => TimeLabel,
16281
+ VisuallyHidden: () => VisuallyHidden,
16282
+ apply: () => apply$1,
16283
+ failureOf: () => failureOf,
16284
+ findReferences: () => findReferences,
16285
+ formatReference: () => formatReference,
16286
+ formatReferenceMention: () => formatReferenceMention,
16287
+ inject: () => inject$1,
16288
+ isLocalReference: () => isLocalReference,
16289
+ markdownLabels: () => markdownLabels,
16290
+ mergeTags: () => mergeTags,
16291
+ parseReference: () => parseReference,
16292
+ parseReferenceToken: () => parseReferenceToken,
16293
+ parseTagList: () => parseTagList,
16294
+ projectRoot: () => projectRoot,
16295
+ referenceMentions: () => referenceMentions,
16296
+ rowRegistrations: () => rowRegistrations,
16297
+ schemaForm: () => schema_form_exports,
16298
+ walkFields: () => walkFields
16299
+ });
16300
+ __reExport(client_exports, require("@deepseek-ai/dsh-client-ui-primitives"));
16301
+ const inject$1 = [...inject$2];
16698
16302
  function apply$1(ctx) {
16699
16303
  apply$2(ctx);
16700
16304
  }
@@ -16844,254 +16448,12 @@ window.__ModuleLoader__.load({
16844
16448
  if (!Number.isFinite(value) || value <= 0) return "0%";
16845
16449
  return `${value >= 100 ? Math.round(value) : Math.round(value * 10) / 10}%`;
16846
16450
  }
16847
- const styles = {
16848
- page: {
16849
- display: "flex",
16850
- flexDirection: "column",
16851
- gap: "12px",
16852
- boxSizing: "border-box",
16853
- width: "100%",
16854
- height: "100%",
16855
- padding: "24px 28px",
16856
- overflow: "hidden",
16857
- color: "var(--dsw-alias-label-primary)"
16858
- },
16859
- scroll: {
16860
- display: "flex",
16861
- flexDirection: "column",
16862
- gap: "12px",
16863
- flex: "1 1 auto",
16864
- minHeight: "0",
16865
- overflowY: "auto"
16866
- },
16867
- header: {
16868
- display: "flex",
16869
- alignItems: "center",
16870
- justifyContent: "space-between",
16871
- gap: "12px",
16872
- flex: "none"
16873
- },
16874
- headerActions: {
16875
- display: "flex",
16876
- alignItems: "center",
16877
- gap: "8px",
16878
- flex: "none"
16879
- },
16880
- title: {
16881
- margin: "0",
16882
- fontSize: "16px",
16883
- lineHeight: "24px",
16884
- fontWeight: "500"
16885
- },
16886
- tabs: {
16887
- position: "relative",
16888
- zIndex: "1",
16889
- display: "flex",
16890
- gap: "36px",
16891
- marginTop: "10px",
16892
- paddingLeft: "8px",
16893
- flex: "none"
16894
- },
16895
- tab: {
16896
- position: "relative",
16897
- padding: "0 0 9px",
16898
- border: "none",
16899
- background: "transparent",
16900
- fontSize: "13px",
16901
- lineHeight: "16px",
16902
- fontWeight: "500",
16903
- color: "var(--dsw-alias-label-tertiary)",
16904
- cursor: "pointer",
16905
- "&::after": {
16906
- content: "''",
16907
- position: "absolute",
16908
- right: "0",
16909
- bottom: "-1px",
16910
- left: "0",
16911
- height: "2px",
16912
- borderRadius: "2px",
16913
- background: "transparent"
16914
- }
16915
- },
16916
- tabActive: {
16917
- color: "var(--dsw-alias-state-business-primary)",
16918
- "&::after": { background: "var(--dsw-alias-state-business-primary)" }
16919
- },
16920
- usage: {
16921
- display: "flex",
16922
- flexDirection: "column",
16923
- gap: "12px",
16924
- flex: "none"
16925
- },
16926
- usageRow: {
16927
- display: "flex",
16928
- flexDirection: "column",
16929
- gap: "6px",
16930
- padding: "10px 12px",
16931
- border: "1px solid var(--dsw-alias-border-l1)",
16932
- borderRadius: "10px",
16933
- background: "var(--dsw-alias-bg-base)",
16934
- flex: "none"
16935
- },
16936
- usageRowLabel: {
16937
- overflow: "hidden",
16938
- fontSize: "12px",
16939
- lineHeight: "18px",
16940
- color: "var(--dsw-alias-label-tertiary)",
16941
- textOverflow: "ellipsis",
16942
- whiteSpace: "nowrap"
16943
- },
16944
- usageMetrics: {
16945
- display: "flex",
16946
- flexDirection: "row",
16947
- flexWrap: "wrap",
16948
- gap: "6px 20px"
16949
- },
16950
- usageMetric: {
16951
- display: "flex",
16952
- flexDirection: "column",
16953
- gap: "2px"
16954
- },
16955
- usageMetricLabel: {
16956
- fontSize: "12px",
16957
- lineHeight: "18px",
16958
- color: "var(--dsw-alias-label-tertiary)"
16959
- },
16960
- usageMetricValue: {
16961
- fontSize: "16px",
16962
- lineHeight: "24px",
16963
- fontWeight: "500",
16964
- fontVariantNumeric: "tabular-nums"
16965
- },
16966
- usageList: {
16967
- display: "flex",
16968
- flexDirection: "column",
16969
- gap: "4px",
16970
- margin: "0",
16971
- padding: "0",
16972
- listStyle: "none",
16973
- flex: "none"
16974
- },
16975
- filters: {
16976
- display: "flex",
16977
- alignItems: "center",
16978
- gap: "16px",
16979
- flex: "none"
16980
- },
16981
- search: {
16982
- width: "360px",
16983
- maxWidth: "100%",
16984
- flex: "none"
16985
- },
16986
- list: {
16987
- display: "flex",
16988
- flexDirection: "column",
16989
- gap: "4px",
16990
- margin: "0",
16991
- padding: "0",
16992
- listStyle: "none",
16993
- flex: "none"
16994
- },
16995
- row: {
16996
- display: "flex",
16997
- alignItems: "center",
16998
- justifyContent: "space-between",
16999
- gap: "16px",
17000
- padding: "10px 12px",
17001
- border: "1px solid var(--dsw-alias-border-l1)",
17002
- borderRadius: "10px",
17003
- background: "var(--dsw-alias-bg-base)",
17004
- flex: "none"
17005
- },
17006
- identity: {
17007
- display: "flex",
17008
- flexDirection: "column",
17009
- gap: "2px",
17010
- minWidth: "0"
17011
- },
17012
- titleLine: {
17013
- display: "flex",
17014
- alignItems: "center",
17015
- gap: "8px",
17016
- minWidth: "0"
17017
- },
17018
- rowTitle: {
17019
- overflow: "hidden",
17020
- fontSize: "13px",
17021
- lineHeight: "20px",
17022
- textOverflow: "ellipsis",
17023
- whiteSpace: "nowrap"
17024
- },
17025
- meta: {
17026
- fontSize: "12px",
17027
- lineHeight: "18px",
17028
- color: "var(--dsw-alias-label-tertiary)"
17029
- },
17030
- actions: {
17031
- display: "flex",
17032
- alignItems: "center",
17033
- gap: "8px",
17034
- flex: "none"
17035
- },
17036
- pagination: {
17037
- display: "flex",
17038
- alignItems: "center",
17039
- justifyContent: "flex-end",
17040
- gap: "8px",
17041
- marginTop: "4px",
17042
- flex: "none"
17043
- },
17044
- paginationLabel: {
17045
- fontSize: "12px",
17046
- lineHeight: "18px",
17047
- color: "var(--dsw-alias-label-tertiary)",
17048
- fontVariantNumeric: "tabular-nums"
17049
- },
17050
- status: {
17051
- margin: "0",
17052
- fontSize: "13px",
17053
- lineHeight: "20px",
17054
- color: "var(--dsw-alias-label-tertiary)",
17055
- flex: "none"
17056
- },
17057
- failure: {
17058
- margin: "0",
17059
- fontSize: "13px",
17060
- lineHeight: "20px",
17061
- color: "var(--dsw-alias-label-error, var(--dsw-alias-label-primary))",
17062
- flex: "none"
17063
- },
17064
- blocking: {
17065
- display: "flex",
17066
- flexDirection: "column",
17067
- alignItems: "center",
17068
- gap: "14px",
17069
- padding: "32px 40px",
17070
- color: "var(--dsw-alias-label-primary)"
17071
- },
17072
- spinner: {
17073
- width: "28px",
17074
- height: "28px",
17075
- border: "2px solid var(--dsw-alias-border-l2)",
17076
- borderTopColor: "var(--dsw-alias-label-primary)",
17077
- borderRadius: "50%",
17078
- animation: `${styling.keyframes({
17079
- from: { transform: "rotate(0deg)" },
17080
- to: { transform: "rotate(360deg)" }
17081
- })} 900ms linear infinite`
17082
- },
17083
- blockingText: {
17084
- margin: "0",
17085
- fontSize: "13px",
17086
- lineHeight: "20px"
17087
- }
17088
- };
17089
16451
  //#endregion
17090
16452
  //#region src/client/ConversationManagerPage.tsx
17091
16453
  const PAGE_SIZE = 20;
17092
16454
  const USAGE_SESSION_ROWS = 20;
17093
16455
  function timeLabel(updatedAt, now, t) {
17094
- const { unit, n } = (0, _deepseek_ai_dsh_client_ui_primitives.relativeTime)(updatedAt, now);
16456
+ const { unit, n } = (0, client_exports.relativeTime)(updatedAt, now);
17095
16457
  return unit === "now" ? t("time.now") : t(`time.${unit}`, { n });
17096
16458
  }
17097
16459
  function failureText(error, t) {
@@ -17111,6 +16473,7 @@ window.__ModuleLoader__.load({
17111
16473
  const [view, setView] = (0, react.useState)("sessions");
17112
16474
  const [usageTab, setUsageTab] = (0, react.useState)("overview");
17113
16475
  const [usageRange, setUsageRange] = (0, react.useState)("day");
16476
+ const [usageOnlySubagents, setUsageOnlySubagents] = (0, react.useState)(false);
17114
16477
  const [usage, setUsage] = (0, react.useState)(null);
17115
16478
  const [usageLoading, setUsageLoading] = (0, react.useState)(false);
17116
16479
  const [usageError, setUsageError] = (0, react.useState)(null);
@@ -17204,8 +16567,10 @@ window.__ModuleLoader__.load({
17204
16567
  setView("usage");
17205
16568
  if (usage === null && !usageLoading) requestUsage(usageRange);
17206
16569
  };
17207
- if (rowsPage === null) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
17208
- ...styling.props(styles.status),
16570
+ if (rowsPage === null) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
16571
+ as: "p",
16572
+ size: "md",
16573
+ tone: "tertiary",
17209
16574
  children: rowsFailure ?? t("loading")
17210
16575
  });
17211
16576
  const now = Date.now();
@@ -17215,43 +16580,42 @@ window.__ModuleLoader__.load({
17215
16580
  const currentPage = Math.min(page, pageCount);
17216
16581
  const matched = rows;
17217
16582
  const confirmed = confirming;
17218
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
17219
- ...styling.props(styles.page),
16583
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Stack, {
17220
16584
  "data-view": view,
16585
+ fill: true,
16586
+ pad: "page",
16587
+ gap: 12,
17221
16588
  children: [
17222
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
17223
- ...styling.props(styles.header),
16589
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Row, {
16590
+ gap: 12,
16591
+ justify: "between",
16592
+ fixed: true,
17224
16593
  children: [
17225
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("h1", {
17226
- ...styling.props(styles.title),
16594
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
16595
+ as: "h1",
16596
+ size: "lg",
16597
+ weight: "medium",
17227
16598
  children: t("title")
17228
16599
  }),
17229
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
17230
- ...styling.props(styles.tabs),
17231
- role: "tablist",
17232
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
17233
- type: "button",
17234
- role: "tab",
17235
- "data-tab": "sessions",
17236
- "aria-selected": view === "sessions",
17237
- className: styling.className(styles.tab, view === "sessions" && styles.tabActive),
17238
- onClick: () => {
17239
- setView("sessions");
17240
- },
17241
- children: t("view.sessions")
17242
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
17243
- type: "button",
17244
- role: "tab",
17245
- "data-tab": "usage",
17246
- "aria-selected": view === "usage",
17247
- className: styling.className(styles.tab, view === "usage" && styles.tabActive),
17248
- onClick: openUsage,
17249
- children: t("view.usage")
17250
- })]
16600
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Tabs, {
16601
+ label: t("title"),
16602
+ items: [{
16603
+ value: "sessions",
16604
+ label: t("view.sessions")
16605
+ }, {
16606
+ value: "usage",
16607
+ label: t("view.usage")
16608
+ }],
16609
+ value: view,
16610
+ onChange: (next) => {
16611
+ if (next === "usage") openUsage();
16612
+ else setView("sessions");
16613
+ }
17251
16614
  }),
17252
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
17253
- ...styling.props(styles.headerActions),
17254
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
16615
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Row, {
16616
+ gap: 8,
16617
+ fixed: true,
16618
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
17255
16619
  variant: "outline",
17256
16620
  size: "sm",
17257
16621
  "data-action": "import",
@@ -17262,7 +16626,7 @@ window.__ModuleLoader__.load({
17262
16626
  fileRef.current?.click();
17263
16627
  },
17264
16628
  children: importing ? t("importing") : t("import")
17265
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
16629
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
17266
16630
  variant: "outline",
17267
16631
  size: "sm",
17268
16632
  "data-action": "gc",
@@ -17299,9 +16663,10 @@ window.__ModuleLoader__.load({
17299
16663
  })
17300
16664
  ]
17301
16665
  }),
17302
- view === "usage" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
17303
- ...styling.props(styles.scroll),
16666
+ view === "usage" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Stack, {
17304
16667
  "data-scroll": "page",
16668
+ gap: 12,
16669
+ scroll: true,
17305
16670
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(UsageView, {
17306
16671
  report: usage,
17307
16672
  loading: usageLoading,
@@ -17310,15 +16675,18 @@ window.__ModuleLoader__.load({
17310
16675
  onTab: setUsageTab,
17311
16676
  range: usageRange,
17312
16677
  onRange: requestUsage,
16678
+ onlySubagents: usageOnlySubagents,
16679
+ onOnlySubagents: setUsageOnlySubagents,
17313
16680
  t
17314
16681
  })
17315
- }) : /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
17316
- ...styling.props(styles.filters),
17317
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Input, {
17318
- className: styling.className(styles.search),
16682
+ }) : /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Row, {
16683
+ gap: 16,
16684
+ fixed: true,
16685
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(SearchInput, {
16686
+ width: "search",
17319
16687
  "data-filter": "search",
17320
16688
  type: "search",
17321
- icon: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconSearchOutlineRegular, {}),
16689
+ icon: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(client_exports.IconSearchOutlineRegular, {}),
17322
16690
  value: query,
17323
16691
  placeholder: t("search"),
17324
16692
  "aria-label": t("search"),
@@ -17328,7 +16696,7 @@ window.__ModuleLoader__.load({
17328
16696
  }
17329
16697
  }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
17330
16698
  "data-filter": "subagents",
17331
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Checkbox, {
16699
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(client_exports.Checkbox, {
17332
16700
  checked: showSubagents,
17333
16701
  label: t("showSubagents"),
17334
16702
  onChange: (next) => {
@@ -17337,59 +16705,78 @@ window.__ModuleLoader__.load({
17337
16705
  }
17338
16706
  })
17339
16707
  })]
17340
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
17341
- ...styling.props(styles.scroll),
16708
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Stack, {
17342
16709
  "data-scroll": "page",
16710
+ gap: 12,
16711
+ scroll: true,
17343
16712
  children: [
17344
- notice === null ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
17345
- ...styling.props(styles.status),
16713
+ notice === null ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
17346
16714
  "data-notice": "result",
16715
+ as: "p",
16716
+ size: "md",
16717
+ tone: "tertiary",
17347
16718
  children: notice
17348
16719
  }),
17349
- failure === null ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
17350
- ...styling.props(styles.failure),
16720
+ failure === null ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
17351
16721
  "data-failure": "result",
17352
16722
  role: "alert",
16723
+ as: "p",
16724
+ size: "md",
16725
+ tone: "danger",
17353
16726
  children: failure
17354
16727
  }),
17355
- total === 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
17356
- ...styling.props(styles.status),
16728
+ total === 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
17357
16729
  "data-status": "empty",
16730
+ as: "p",
16731
+ size: "md",
16732
+ tone: "tertiary",
17358
16733
  children: t(settledQuery === "" ? "empty" : "emptySearch")
17359
16734
  }) : null,
17360
- visible.length > 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("ul", {
17361
- ...styling.props(styles.list),
17362
- children: visible.map((row) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("li", {
17363
- ...styling.props(styles.row),
16735
+ visible.length > 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Stack, {
16736
+ as: "ul",
16737
+ gap: 4,
16738
+ plain: true,
16739
+ children: visible.map((row) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Row, {
16740
+ as: "li",
16741
+ gap: 16,
16742
+ justify: "between",
16743
+ boxed: true,
16744
+ pad: "row",
16745
+ fixed: true,
17364
16746
  "data-session-id": String(row.id),
17365
16747
  "data-archived": row.archived ? "true" : "false",
17366
16748
  "data-subagent": row.subagent ? "true" : "false",
17367
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
17368
- ...styling.props(styles.identity),
17369
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
17370
- ...styling.props(styles.titleLine),
16749
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Stack, {
16750
+ gap: 2,
16751
+ grow: true,
16752
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Row, {
16753
+ gap: 8,
16754
+ grow: true,
17371
16755
  children: [
17372
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
17373
- ...styling.props(styles.rowTitle),
16756
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
16757
+ size: "md",
16758
+ truncate: true,
17374
16759
  children: row.title
17375
16760
  }),
17376
- row.archived ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Tag, {
16761
+ row.archived ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(client_exports.Tag, {
17377
16762
  tone: "neutral",
17378
16763
  children: t("archived")
17379
16764
  }) : null,
17380
- row.subagent ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Tag, {
16765
+ row.subagent ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(client_exports.Tag, {
17381
16766
  tone: "quiet",
17382
16767
  children: t("subagent")
17383
16768
  }) : null
17384
16769
  ]
17385
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
17386
- ...styling.props(styles.meta),
16770
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
16771
+ size: "sm",
16772
+ tone: "tertiary",
17387
16773
  children: [row.workspace, timeLabel(row.updatedAt, now, t)].join(" · ")
17388
16774
  })]
17389
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
17390
- ...styling.props(styles.actions),
16775
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Row, {
16776
+ gap: 8,
16777
+ fixed: true,
17391
16778
  children: [
17392
- row.archived ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
16779
+ row.archived ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
17393
16780
  variant: "outline",
17394
16781
  size: "sm",
17395
16782
  "data-action": "unarchive",
@@ -17398,7 +16785,7 @@ window.__ModuleLoader__.load({
17398
16785
  run(unarchive(row.id));
17399
16786
  },
17400
16787
  children: t("unarchive")
17401
- }) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
16788
+ }) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
17402
16789
  variant: "outline",
17403
16790
  size: "sm",
17404
16791
  "data-action": "archive",
@@ -17408,7 +16795,7 @@ window.__ModuleLoader__.load({
17408
16795
  },
17409
16796
  children: t("archive")
17410
16797
  }),
17411
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
16798
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
17412
16799
  variant: "outline",
17413
16800
  size: "sm",
17414
16801
  "data-action": "export",
@@ -17418,7 +16805,7 @@ window.__ModuleLoader__.load({
17418
16805
  },
17419
16806
  children: t("export")
17420
16807
  }),
17421
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
16808
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
17422
16809
  variant: "outline",
17423
16810
  size: "sm",
17424
16811
  disabled: !row.archived,
@@ -17435,13 +16822,15 @@ window.__ModuleLoader__.load({
17435
16822
  })]
17436
16823
  }, row.id))
17437
16824
  }) : null,
17438
- matched.length > 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
17439
- ...styling.props(styles.pagination),
16825
+ matched.length > 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Row, {
17440
16826
  "data-pagination": "",
17441
16827
  "data-page-current": currentPage,
17442
16828
  "data-page-total": pageCount,
16829
+ gap: 8,
16830
+ justify: "end",
16831
+ fixed: true,
17443
16832
  children: [
17444
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
16833
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
17445
16834
  variant: "ghost",
17446
16835
  size: "sm",
17447
16836
  disabled: currentPage <= 1,
@@ -17450,14 +16839,16 @@ window.__ModuleLoader__.load({
17450
16839
  },
17451
16840
  children: t("page.previous")
17452
16841
  }),
17453
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
17454
- ...styling.props(styles.paginationLabel),
16842
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
16843
+ size: "sm",
16844
+ tone: "tertiary",
16845
+ tabular: true,
17455
16846
  children: t("page.label", {
17456
16847
  page: currentPage,
17457
16848
  total: pageCount
17458
16849
  })
17459
16850
  }),
17460
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
16851
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
17461
16852
  variant: "ghost",
17462
16853
  size: "sm",
17463
16854
  disabled: currentPage >= pageCount,
@@ -17470,7 +16861,7 @@ window.__ModuleLoader__.load({
17470
16861
  }) : null
17471
16862
  ]
17472
16863
  })] }),
17473
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Modal, {
16864
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(client_exports.Modal, {
17474
16865
  open: confirmed !== null,
17475
16866
  onClose: () => {
17476
16867
  setConfirming(null);
@@ -17478,13 +16869,13 @@ window.__ModuleLoader__.load({
17478
16869
  title: t("confirmTitle"),
17479
16870
  closeLabel: t("close"),
17480
16871
  description: t("confirmDescription"),
17481
- footer: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
16872
+ footer: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
17482
16873
  variant: "ghost",
17483
16874
  onClick: () => {
17484
16875
  setConfirming(null);
17485
16876
  },
17486
16877
  children: t("confirmCancel")
17487
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
16878
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
17488
16879
  variant: "primary",
17489
16880
  onClick: () => {
17490
16881
  if (confirmed === null) return;
@@ -17495,7 +16886,7 @@ window.__ModuleLoader__.load({
17495
16886
  children: t("confirmAccept")
17496
16887
  })] })
17497
16888
  }),
17498
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Modal, {
16889
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(client_exports.Modal, {
17499
16890
  open: gcPhase === "confirm",
17500
16891
  onClose: () => {
17501
16892
  setGcPhase("idle");
@@ -17503,30 +16894,30 @@ window.__ModuleLoader__.load({
17503
16894
  title: t("gc.title"),
17504
16895
  closeLabel: t("close"),
17505
16896
  description: t("gc.description"),
17506
- footer: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
16897
+ footer: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
17507
16898
  variant: "ghost",
17508
16899
  onClick: () => {
17509
16900
  setGcPhase("idle");
17510
16901
  },
17511
16902
  children: t("gc.cancel")
17512
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
16903
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
17513
16904
  variant: "primary",
17514
16905
  onClick: startGc,
17515
16906
  children: t("gc.confirm")
17516
16907
  })] })
17517
16908
  }),
17518
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Modal, {
16909
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(client_exports.Modal, {
17519
16910
  open: gcPhase === "running",
17520
16911
  onClose: () => {},
17521
16912
  headless: true,
17522
16913
  title: t("gc.title"),
17523
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
17524
- ...styling.props(styles.blocking),
17525
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
17526
- ...styling.props(styles.spinner),
17527
- "aria-hidden": "true"
17528
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
17529
- ...styling.props(styles.blockingText),
16914
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Stack, {
16915
+ align: "center",
16916
+ gap: 14,
16917
+ pad: "blocking",
16918
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Spinner, { label: t("gc.running") }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
16919
+ as: "p",
16920
+ size: "md",
17530
16921
  children: t("gc.running")
17531
16922
  })]
17532
16923
  })
@@ -17651,24 +17042,42 @@ window.__ModuleLoader__.load({
17651
17042
  }
17652
17043
  return [...folded.values()].sort((left, right) => sortWeight(right.totals) - sortWeight(left.totals));
17653
17044
  }
17654
- function UsageRow({ rowKey, label, totals, t, withActivity = true }) {
17655
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("li", {
17656
- ...styling.props(styles.usageRow),
17045
+ function UsageRow({ rowKey, label, totals, t, subagent, withActivity = true }) {
17046
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Stack, {
17047
+ as: "li",
17048
+ gap: 6,
17049
+ boxed: true,
17050
+ pad: "row",
17051
+ fixed: true,
17657
17052
  "data-usage-key": rowKey,
17658
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
17659
- ...styling.props(styles.usageRowLabel),
17660
- children: label
17661
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
17662
- ...styling.props(styles.usageMetrics),
17663
- children: usageMetrics(totals, t, { withActivity }).map((metric) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
17664
- ...styling.props(styles.usageMetric),
17053
+ ...subagent === void 0 ? {} : { "data-subagent": subagent ? "true" : "false" },
17054
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Row, {
17055
+ gap: 8,
17056
+ grow: true,
17057
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
17058
+ size: "sm",
17059
+ tone: "tertiary",
17060
+ truncate: true,
17061
+ children: label
17062
+ }), subagent === true ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(client_exports.Tag, {
17063
+ tone: "quiet",
17064
+ children: t("subagent")
17065
+ }) : null]
17066
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Row, {
17067
+ gap: "wide",
17068
+ wrap: true,
17069
+ children: usageMetrics(totals, t, { withActivity }).map((metric) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Stack, {
17665
17070
  "data-usage-cell": metric.key,
17666
17071
  "data-usage-value": metric.value,
17667
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
17668
- ...styling.props(styles.usageMetricLabel),
17072
+ gap: 2,
17073
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
17074
+ size: "sm",
17075
+ tone: "tertiary",
17669
17076
  children: metric.label
17670
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
17671
- ...styling.props(styles.usageMetricValue),
17077
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
17078
+ size: "lg",
17079
+ weight: "medium",
17080
+ tabular: true,
17672
17081
  children: metric.kind === "percent" ? formatPercent(metric.value) : metric.kind === "count" ? formatCount(metric.value) : formatTokens(metric.value)
17673
17082
  })]
17674
17083
  }, metric.key))
@@ -17676,25 +17085,32 @@ window.__ModuleLoader__.load({
17676
17085
  });
17677
17086
  }
17678
17087
  function UsageList({ rows, t, withActivity = true }) {
17679
- if (rows.length === 0) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
17680
- ...styling.props(styles.status),
17088
+ if (rows.length === 0) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
17681
17089
  "data-usage-status": "empty",
17090
+ as: "p",
17091
+ size: "md",
17092
+ tone: "tertiary",
17682
17093
  children: t("usage.empty")
17683
17094
  });
17684
- return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("ul", {
17685
- ...styling.props(styles.usageList),
17095
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Stack, {
17096
+ as: "ul",
17097
+ gap: 4,
17098
+ plain: true,
17686
17099
  children: rows.map((row) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(UsageRow, {
17687
17100
  rowKey: row.key,
17688
17101
  label: row.label,
17689
17102
  totals: row.totals,
17690
17103
  t,
17104
+ ...row.subagent === void 0 ? {} : { subagent: row.subagent },
17691
17105
  withActivity
17692
17106
  }, row.key))
17693
17107
  });
17694
17108
  }
17695
17109
  function UsageOverview({ report, t }) {
17696
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("ul", {
17697
- ...styling.props(styles.usageList),
17110
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Stack, {
17111
+ as: "ul",
17112
+ gap: 4,
17113
+ plain: true,
17698
17114
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(UsageRow, {
17699
17115
  rowKey: "all",
17700
17116
  label: t("usage.all"),
@@ -17708,7 +17124,7 @@ window.__ModuleLoader__.load({
17708
17124
  })]
17709
17125
  });
17710
17126
  }
17711
- function UsageView({ report, loading, error, tab, onTab, range, onRange, t }) {
17127
+ function UsageView({ report, loading, error, tab, onTab, range, onRange, onlySubagents, onOnlySubagents, t }) {
17712
17128
  const items = [
17713
17129
  "overview",
17714
17130
  "models",
@@ -17719,56 +17135,64 @@ window.__ModuleLoader__.load({
17719
17135
  models: t("usage.models"),
17720
17136
  sessions: t("usage.sessions")
17721
17137
  };
17722
- const rows = report === null || tab === "overview" ? [] : tab === "models" ? foldBuckets(report.buckets, (bucket) => `${bucket.provider ?? t("usage.unknownModel")} / ${bucket.model ?? t("usage.unknownModel")}`) : report.sessions.map((row) => ({
17138
+ const rows = report === null || tab === "overview" ? [] : tab === "models" ? foldBuckets(report.buckets, (bucket) => `${bucket.provider ?? t("usage.unknownModel")} / ${bucket.model ?? t("usage.unknownModel")}`) : report.sessions.filter((row) => !onlySubagents || row.subagent).map((row) => ({
17723
17139
  key: row.sessionId,
17724
17140
  label: row.title ?? row.sessionId,
17725
- totals: row
17141
+ totals: row,
17142
+ subagent: row.subagent
17726
17143
  })).sort((left, right) => sortWeight(right.totals) - sortWeight(left.totals)).slice(0, USAGE_SESSION_ROWS);
17727
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
17728
- ...styling.props(styles.usage),
17144
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Stack, {
17729
17145
  "data-usage-view": tab,
17730
17146
  "data-usage-range": range,
17147
+ gap: 12,
17148
+ fixed: true,
17731
17149
  children: [
17732
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
17733
- ...styling.props(styles.tabs),
17150
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Tabs, {
17734
17151
  role: "radiogroup",
17735
- "aria-label": t("usage.range"),
17736
- children: USAGE_RANGES.map((option) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
17737
- type: "button",
17738
- role: "radio",
17739
- "aria-checked": range === option,
17740
- "data-range": option,
17741
- className: styling.className(styles.tab, range === option && styles.tabActive),
17742
- onClick: () => {
17743
- onRange(option);
17744
- },
17745
- children: rangeLabel(option, t)
17746
- }, option))
17152
+ label: t("usage.range"),
17153
+ items: USAGE_RANGES.map((option) => ({
17154
+ value: option,
17155
+ label: rangeLabel(option, t)
17156
+ })),
17157
+ value: range,
17158
+ onChange: (next) => {
17159
+ onRange(next);
17160
+ }
17747
17161
  }),
17748
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
17749
- ...styling.props(styles.tabs),
17750
- role: "tablist",
17751
- children: items.map((item) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
17752
- type: "button",
17753
- role: "tab",
17754
- "data-usage-tab": item,
17755
- "aria-selected": tab === item,
17756
- className: styling.className(styles.tab, tab === item && styles.tabActive),
17757
- onClick: () => {
17758
- onTab(item);
17759
- },
17760
- children: labels[item]
17761
- }, item))
17162
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Tabs, {
17163
+ label: t("usage.range"),
17164
+ items: items.map((item) => ({
17165
+ value: item,
17166
+ label: labels[item]
17167
+ })),
17168
+ value: tab,
17169
+ onChange: (next) => {
17170
+ onTab(next);
17171
+ }
17762
17172
  }),
17763
- loading ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
17764
- ...styling.props(styles.status),
17173
+ tab === "sessions" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Row, {
17174
+ "data-filter": "usage-subagents",
17175
+ gap: 16,
17176
+ fixed: true,
17177
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(client_exports.Checkbox, {
17178
+ checked: onlySubagents,
17179
+ label: t("usage.onlySubagents"),
17180
+ onChange: onOnlySubagents
17181
+ })
17182
+ }) : null,
17183
+ loading ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
17765
17184
  "data-usage-status": "loading",
17185
+ as: "p",
17186
+ size: "md",
17187
+ tone: "tertiary",
17766
17188
  children: t("usage.loading")
17767
17189
  }) : null,
17768
- error === null ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
17769
- ...styling.props(styles.failure),
17190
+ error === null ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
17770
17191
  "data-usage-status": "error",
17771
17192
  role: "alert",
17193
+ as: "p",
17194
+ size: "md",
17195
+ tone: "danger",
17772
17196
  children: error
17773
17197
  }),
17774
17198
  report === null ? null : tab === "overview" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(UsageOverview, {
@@ -17824,6 +17248,7 @@ window.__ModuleLoader__.load({
17824
17248
  "usage.userInputs": "用户输入",
17825
17249
  "usage.toolCalls": "工具调用",
17826
17250
  "usage.subagentOnly": "其中子代理",
17251
+ "usage.onlySubagents": "只看子代理会话",
17827
17252
  "usage.unknownModel": "未知模型",
17828
17253
  archive: "归档",
17829
17254
  archiveNamed: "归档 {title}",
@@ -17898,6 +17323,7 @@ window.__ModuleLoader__.load({
17898
17323
  "usage.userInputs": "User inputs",
17899
17324
  "usage.toolCalls": "Tool calls",
17900
17325
  "usage.subagentOnly": "Subagent share",
17326
+ "usage.onlySubagents": "Subagent sessions only",
17901
17327
  "usage.unknownModel": "Unknown model",
17902
17328
  archive: "Archive",
17903
17329
  archiveNamed: "Archive {title}",