@deepseek-ai/dsh-client-ui-sidebar-right 0.2.0-rc.2 → 0.2.1-alpha.2

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/README.i18n.yaml CHANGED
@@ -51,5 +51,5 @@
51
51
  en: 76a763b4dd71babd
52
52
  zh: fdc966dd427a82fb
53
53
  /deepseek-ai-dsh-client-ui-sidebar-right/known-limitations-and-deferred-work/dev-note:
54
- en: 9fcbcccf09b43c5d
55
- zh: 224b8a0881ab6890
54
+ en: e67f633dc6fe7773
55
+ zh: e88aeb617ffb74ea
package/README.md CHANGED
@@ -155,5 +155,3 @@ None; this package neither assembles nor sends a provider request.
155
155
  None.
156
156
 
157
157
  </details>
158
-
159
- **Runtime invariant:** No companion is published. The two services (`sidebarRight`, `sidebarRightTabs`) are provided through `ctx.reflect.provide` inside one effect and torn down with it; the on-screen Session and the Tab domain's occurrence lifetimes are asserted directly by this package's specs, and no independent observation exists to diverge from them.
package/README.zh.md CHANGED
@@ -155,5 +155,3 @@ Tab 域按(Session,Tab id)保留品牌化 occurrence id、导航、中止
155
155
  无。
156
156
 
157
157
  </details>
158
-
159
- **运行时不变量:** 不发布 companion。两个服务(`sidebarRight`、`sidebarRightTabs`)在同一个 effect 内经 `ctx.reflect.provide` 提供并随之拆除;屏幕上的会话与 Tab 域 occurrence 的生命周期由本包的 spec 直接断言,不存在会与之分歧的独立观察。
package/lib/client.js CHANGED
@@ -5557,12 +5557,12 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
5557
5557
  "data-sidebar-right-tab": tab.id,
5558
5558
  "data-sidebar-right-occurrence": id,
5559
5559
  children: content
5560
- }) : (0, react_jsx_runtime.jsx)("div", {
5560
+ }, id) : (0, react_jsx_runtime.jsx)("div", {
5561
5561
  className: SidebarRight_module_css_default.tabBody,
5562
5562
  "data-sidebar-right-tab": tab.id,
5563
5563
  "data-sidebar-right-occurrence": id,
5564
5564
  children: content
5565
- });
5565
+ }, id);
5566
5566
  }
5567
5567
  /**
5568
5568
  * Dispatch a tab's body to its registered type.
@@ -5680,7 +5680,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
5680
5680
  "data-sidebar-right-session": sessionId,
5681
5681
  "data-sidebar-right-panel": fullscreen ? "fullscreen" : "push",
5682
5682
  "data-sidebar-right-open": expanded || void 0,
5683
- "aria-hidden": !expanded || void 0,
5683
+ "aria-hidden": !expanded && surface.layout.floats.length === 0 || void 0,
5684
5684
  children: (0, react_jsx_runtime.jsx)("div", {
5685
5685
  className: SidebarRight_module_css_default.panelBody,
5686
5686
  children: (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_dockkit.DockLayout, {
@@ -6480,7 +6480,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
6480
6480
  };
6481
6481
  const layout = surface?.layout;
6482
6482
  const replaced = placement.replaceTab === void 0 ? void 0 : layout?.tabs[placement.replaceTab];
6483
- const revealed = layout === void 0 || placement.revealIfOpened === false ? void 0 : (0, _deepseek_ai_dsh_client_ui_dockkit.findContentTab)(layout, claim.contentId, claim.kind);
6483
+ const replacementPane = replaced === void 0 || layout === void 0 ? void 0 : (0, _deepseek_ai_dsh_client_ui_dockkit.findTabPane)(layout, replaced.id);
6484
+ const revealed = layout === void 0 ? void 0 : claim.contentId === pageAddress(claim.kind) ? (0, _deepseek_ai_dsh_client_ui_dockkit.findPaneContentTab)(layout, replacementPane?.host === "dock" ? replacementPane.id : placement.paneId ?? (0, _deepseek_ai_dsh_client_ui_dockkit.activeDockPaneId)(layout), claim.contentId, claim.kind) : placement.revealIfOpened === false ? void 0 : (0, _deepseek_ai_dsh_client_ui_dockkit.findContentTab)(layout, claim.contentId, claim.kind);
6484
6485
  if (replaced === void 0 || replaced.id === revealed) {
6485
6486
  commit();
6486
6487
  return;
@@ -6752,7 +6753,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
6752
6753
  }
6753
6754
  };
6754
6755
  //#endregion
6755
- //#region ../../../node_modules/.pnpm/picomatch@4.0.4/node_modules/picomatch/lib/constants.js
6756
+ //#region ../../../node_modules/.pnpm/picomatch@4.0.7/node_modules/picomatch/lib/constants.js
6756
6757
  var require_constants = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6757
6758
  const WIN_SLASH = "\\\\/";
6758
6759
  const WIN_NO_SLASH = `[^${WIN_SLASH}]`;
@@ -6921,7 +6922,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
6921
6922
  };
6922
6923
  }));
6923
6924
  //#endregion
6924
- //#region ../../../node_modules/.pnpm/picomatch@4.0.4/node_modules/picomatch/lib/utils.js
6925
+ //#region ../../../node_modules/.pnpm/picomatch@4.0.7/node_modules/picomatch/lib/utils.js
6925
6926
  var require_utils = /* @__PURE__ */ __commonJSMin(((exports) => {
6926
6927
  const { REGEX_BACKSLASH, REGEX_REMOVE_BACKSLASH, REGEX_SPECIAL_CHARS, REGEX_SPECIAL_CHARS_GLOBAL } = require_constants();
6927
6928
  exports.isObject = (val) => val !== null && typeof val === "object" && !Array.isArray(val);
@@ -6969,7 +6970,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
6969
6970
  };
6970
6971
  }));
6971
6972
  //#endregion
6972
- //#region ../../../node_modules/.pnpm/picomatch@4.0.4/node_modules/picomatch/lib/scan.js
6973
+ //#region ../../../node_modules/.pnpm/picomatch@4.0.7/node_modules/picomatch/lib/scan.js
6973
6974
  var require_scan = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6974
6975
  const utils = require_utils();
6975
6976
  const { CHAR_ASTERISK, CHAR_AT, CHAR_BACKWARD_SLASH, CHAR_COMMA, CHAR_DOT, CHAR_EXCLAMATION_MARK, CHAR_FORWARD_SLASH, CHAR_LEFT_CURLY_BRACE, CHAR_LEFT_PARENTHESES, CHAR_LEFT_SQUARE_BRACKET, CHAR_PLUS, CHAR_QUESTION_MARK, CHAR_RIGHT_CURLY_BRACE, CHAR_RIGHT_PARENTHESES, CHAR_RIGHT_SQUARE_BRACKET } = require_constants();
@@ -6998,7 +6999,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
6998
6999
  const scan = (input, options) => {
6999
7000
  const opts = options || {};
7000
7001
  const length = input.length - 1;
7001
- const scanToEnd = opts.parts === true || opts.scanToEnd === true;
7002
+ const scanToEnd = opts.parts === true || opts.tokens === true || opts.scanToEnd === true;
7002
7003
  const slashes = [];
7003
7004
  const tokens = [];
7004
7005
  const parts = [];
@@ -7101,14 +7102,18 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
7101
7102
  finished = true;
7102
7103
  if (code === CHAR_EXCLAMATION_MARK && index === start) negatedExtglob = true;
7103
7104
  if (scanToEnd === true) {
7105
+ let parens = 0;
7104
7106
  while (eos() !== true && (code = advance())) {
7105
7107
  if (code === CHAR_BACKWARD_SLASH) {
7106
7108
  backslashes = token.backslashes = true;
7107
- code = advance();
7109
+ advance();
7110
+ continue;
7111
+ }
7112
+ if (code === CHAR_LEFT_PARENTHESES) {
7113
+ parens++;
7108
7114
  continue;
7109
7115
  }
7110
- if (code === CHAR_RIGHT_PARENTHESES) {
7111
- isGlob = token.isGlob = true;
7116
+ if (code === CHAR_RIGHT_PARENTHESES && --parens === 0) {
7112
7117
  finished = true;
7113
7118
  break;
7114
7119
  }
@@ -7156,13 +7161,18 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
7156
7161
  if (opts.noparen !== true && code === CHAR_LEFT_PARENTHESES) {
7157
7162
  isGlob = token.isGlob = true;
7158
7163
  if (scanToEnd === true) {
7164
+ let parens = 1;
7159
7165
  while (eos() !== true && (code = advance())) {
7160
- if (code === CHAR_LEFT_PARENTHESES) {
7166
+ if (code === CHAR_BACKWARD_SLASH) {
7161
7167
  backslashes = token.backslashes = true;
7162
- code = advance();
7168
+ advance();
7163
7169
  continue;
7164
7170
  }
7165
- if (code === CHAR_RIGHT_PARENTHESES) {
7171
+ if (code === CHAR_LEFT_PARENTHESES) {
7172
+ parens++;
7173
+ continue;
7174
+ }
7175
+ if (code === CHAR_RIGHT_PARENTHESES && --parens === 0) {
7166
7176
  finished = true;
7167
7177
  break;
7168
7178
  }
@@ -7225,7 +7235,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
7225
7235
  if (opts.parts === true || opts.tokens === true) {
7226
7236
  let prevIndex;
7227
7237
  for (let idx = 0; idx < slashes.length; idx++) {
7228
- const n = prevIndex ? prevIndex + 1 : start;
7238
+ const n = prevIndex !== void 0 ? prevIndex + 1 : start;
7229
7239
  const i = slashes[idx];
7230
7240
  const value = input.slice(n, i);
7231
7241
  if (opts.tokens) {
@@ -7236,18 +7246,19 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
7236
7246
  depth(tokens[idx]);
7237
7247
  state.maxDepth += tokens[idx].depth;
7238
7248
  }
7239
- if (idx !== 0 || value !== "") parts.push(value);
7240
- prevIndex = i;
7241
- }
7242
- if (prevIndex && prevIndex + 1 < input.length) {
7243
- const value = input.slice(prevIndex + 1);
7244
- parts.push(value);
7245
- if (opts.tokens) {
7246
- tokens[tokens.length - 1].value = value;
7247
- depth(tokens[tokens.length - 1]);
7248
- state.maxDepth += tokens[tokens.length - 1].depth;
7249
+ if (i >= start) {
7250
+ parts.push(value);
7251
+ prevIndex = i;
7249
7252
  }
7250
7253
  }
7254
+ const n = prevIndex !== void 0 ? prevIndex + 1 : start;
7255
+ const value = input.slice(n);
7256
+ parts.push(value);
7257
+ if (opts.tokens && prevIndex && prevIndex + 1 < input.length) {
7258
+ tokens[tokens.length - 1].value = value;
7259
+ depth(tokens[tokens.length - 1]);
7260
+ state.maxDepth += tokens[tokens.length - 1].depth;
7261
+ }
7251
7262
  state.slashes = slashes;
7252
7263
  state.parts = parts;
7253
7264
  }
@@ -7256,7 +7267,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
7256
7267
  module.exports = scan;
7257
7268
  }));
7258
7269
  //#endregion
7259
- //#region ../../../node_modules/.pnpm/picomatch@4.0.4/node_modules/picomatch/lib/parse.js
7270
+ //#region ../../../node_modules/.pnpm/picomatch@4.0.7/node_modules/picomatch/lib/parse.js
7260
7271
  var require_parse = /* @__PURE__ */ __commonJSMin(((exports, module) => {
7261
7272
  const constants = require_constants();
7262
7273
  const utils = require_utils();
@@ -7411,7 +7422,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
7411
7422
  }
7412
7423
  }
7413
7424
  };
7414
- const getStarExtglobSequenceOutput = (pattern) => {
7425
+ const buildCharClassStar = (chars) => {
7426
+ return `${chars.length === 1 ? utils.escapeRegex(chars[0]) : `[${chars.map((ch) => utils.escapeRegex(ch)).join("")}]`}*`;
7427
+ };
7428
+ const getStarExtglobSequenceChars = (pattern) => {
7415
7429
  let index = 0;
7416
7430
  const chars = [];
7417
7431
  while (index < pattern.length) {
@@ -7425,7 +7439,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
7425
7439
  index += match.end + 1;
7426
7440
  }
7427
7441
  if (chars.length < 1) return;
7428
- return `${chars.length === 1 ? utils.escapeRegex(chars[0]) : `[${chars.map((ch) => utils.escapeRegex(ch)).join("")}]`}*`;
7442
+ return chars;
7429
7443
  };
7430
7444
  const repeatedExtglobRecursion = (pattern) => {
7431
7445
  let depth = 0;
@@ -7445,14 +7459,28 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
7445
7459
  if (branches.length > 1) {
7446
7460
  if (branches.some((branch) => branch === "") || branches.some((branch) => /^[*?]+$/.test(branch)) || hasRepeatedCharPrefixOverlap(branches)) return { risky: true };
7447
7461
  }
7462
+ const safeChars = [];
7463
+ let sawStarSequence = false;
7464
+ let combinable = true;
7448
7465
  for (const branch of branches) {
7449
- const safeOutput = getStarExtglobSequenceOutput(branch);
7450
- if (safeOutput) return {
7451
- risky: true,
7452
- safeOutput
7453
- };
7466
+ const chars = getStarExtglobSequenceChars(branch);
7467
+ if (chars) {
7468
+ sawStarSequence = true;
7469
+ safeChars.push(...chars);
7470
+ continue;
7471
+ }
7472
+ const literal = normalizeSimpleBranch(branch);
7473
+ if (literal && literal.length === 1) {
7474
+ safeChars.push(literal);
7475
+ continue;
7476
+ }
7477
+ combinable = false;
7454
7478
  if (repeatedExtglobRecursion(branch) > max) return { risky: true };
7455
7479
  }
7480
+ if (sawStarSequence) return combinable ? {
7481
+ risky: true,
7482
+ safeOutput: buildCharClassStar([...new Set(safeChars)])
7483
+ } : { risky: true };
7456
7484
  return { risky: false };
7457
7485
  };
7458
7486
  /**
@@ -8137,6 +8165,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
8137
8165
  rest = rest.slice(3);
8138
8166
  consume("/**", 3);
8139
8167
  }
8168
+ const isEnd = eos() || state.parens > 0 && rest === ")".repeat(state.parens) && !extglobs.some((extglob) => extglob.type === "negate");
8140
8169
  if (prior.type === "bos" && eos()) {
8141
8170
  prev.type = "globstar";
8142
8171
  prev.value += value;
@@ -8146,7 +8175,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
8146
8175
  consume(value);
8147
8176
  continue;
8148
8177
  }
8149
- if (prior.type === "slash" && prior.prev.type !== "bos" && !afterStar && eos()) {
8178
+ if (prior.type === "slash" && prior.prev.type !== "bos" && !afterStar && isEnd) {
8150
8179
  state.output = state.output.slice(0, -(prior.output + prev.output).length);
8151
8180
  prior.output = `(?:${prior.output}`;
8152
8181
  prev.type = "globstar";
@@ -8311,7 +8340,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
8311
8340
  module.exports = parse;
8312
8341
  }));
8313
8342
  //#endregion
8314
- //#region ../../../node_modules/.pnpm/picomatch@4.0.4/node_modules/picomatch/lib/picomatch.js
8343
+ //#region ../../../node_modules/.pnpm/picomatch@4.0.7/node_modules/picomatch/lib/picomatch.js
8315
8344
  var require_picomatch = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8316
8345
  const scan = require_scan();
8317
8346
  const parse = require_parse();
@@ -8332,6 +8361,18 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
8332
8361
  * const isMatch = picomatch('*.!(*a)');
8333
8362
  * console.log(isMatch('a.a')); //=> false
8334
8363
  * console.log(isMatch('a.b')); //=> true
8364
+ *
8365
+ * // For environments without `node.js`, `picomatch/posix` provides you a dependency-free matcher, without automatic OS detection.
8366
+ * const picomatch = require('picomatch/posix');
8367
+ * // the same API, defaulting to posix paths
8368
+ * const isMatch = picomatch('a/*');
8369
+ * console.log(isMatch('a\\b')); //=> false
8370
+ * console.log(isMatch('a/b')); //=> true
8371
+ *
8372
+ * // you can still configure the matcher function to accept windows paths
8373
+ * const isMatch = picomatch('a/*', { options: windows });
8374
+ * console.log(isMatch('a\\b')); //=> true
8375
+ * console.log(isMatch('a/b')); //=> true
8335
8376
  * ```
8336
8377
  * @name picomatch
8337
8378
  * @param {String|Array} `globs` One or more glob patterns.
@@ -8450,8 +8491,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
8450
8491
  * @return {Boolean}
8451
8492
  * @api public
8452
8493
  */
8453
- picomatch.matchBase = (input, glob, options) => {
8454
- return (glob instanceof RegExp ? glob : picomatch.makeRe(glob, options)).test(utils.basename(input));
8494
+ picomatch.matchBase = (input, glob, options, posix = options && options.windows) => {
8495
+ return (glob instanceof RegExp ? glob : picomatch.makeRe(glob, options)).test(utils.basename(input, { windows: posix }));
8455
8496
  };
8456
8497
  /**
8457
8498
  * Returns true if **any** of the given glob `patterns` match the specified `string`.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@deepseek-ai/dsh-client-ui-sidebar-right",
3
3
  "description": "Right Sidebar: the docking surface's session-bound state, its panel and header expand control, and the navigation service over it",
4
- "version": "0.2.0-rc.2",
4
+ "version": "0.2.1-alpha.2",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -40,35 +40,35 @@
40
40
  },
41
41
  "license": "MIT",
42
42
  "peerDependencies": {
43
- "@deepseek-ai/cordis": "~4.0.4"
43
+ "@deepseek-ai/cordis": "~4.0.5-alpha.1"
44
44
  },
45
45
  "devDependencies": {
46
- "@testing-library/react": "^16.1.0",
47
- "@types/picomatch": "^4.0.2",
46
+ "@deepseek-ai/cordis": "~4.0.5-alpha.1",
47
+ "@deepseek-ai/dsh-api-session-controller": "0.2.1-alpha.2",
48
+ "@deepseek-ai/dsh-client-locale": "0.2.1-alpha.2",
49
+ "@deepseek-ai/dsh-client-resources": "0.2.1-alpha.2",
50
+ "@deepseek-ai/dsh-client-store": "0.2.1-alpha.2",
51
+ "@deepseek-ai/dsh-client-test-runtime": "0.2.1-alpha.2",
52
+ "@deepseek-ai/dsh-client-ui-conversation": "0.2.1-alpha.2",
53
+ "@deepseek-ai/dsh-client-ui-dockkit": "0.2.1-alpha.2",
54
+ "@deepseek-ai/dsh-client-ui-layout": "0.2.1-alpha.2",
55
+ "@deepseek-ai/dsh-client-ui-primitives": "0.2.1-alpha.2",
56
+ "@deepseek-ai/dsh-client-ui-renderer": "0.2.1-alpha.2",
57
+ "@deepseek-ai/dsh-client-ui-session": "0.2.1-alpha.2",
58
+ "@deepseek-ai/dsh-client-ui-slots": "0.2.1-alpha.2",
59
+ "@deepseek-ai/dsh-session": "0.2.1-alpha.2",
60
+ "@testing-library/react": "^16.3.3",
61
+ "@types/picomatch": "^4.0.3",
48
62
  "@types/react": "~18.3.1",
49
63
  "@types/react-dom": "~18.3.0",
50
64
  "react": "^18.2.0",
51
65
  "react-dom": "^18.2.0",
52
- "picomatch": "^4.0.4",
66
+ "picomatch": "^4.0.7",
53
67
  "clsx": "^2.0.0",
68
+ "@deepseek-ai/dsh-util-crypto": "0.2.1-alpha.2",
54
69
  "zod": "^4.4.3",
55
- "@deepseek-ai/dsh-api-session-controller": "0.2.0-rc.2",
56
- "@deepseek-ai/dsh-client-locale": "0.2.0-rc.2",
57
- "@deepseek-ai/dsh-client-resources": "0.2.0-rc.2",
58
- "@deepseek-ai/dsh-client-test-runtime": "0.2.0-rc.2",
59
- "@deepseek-ai/dsh-client-ui-conversation": "0.2.0-rc.2",
60
- "@deepseek-ai/dsh-client-store": "0.2.0-rc.2",
61
- "@deepseek-ai/dsh-client-ui-dockkit": "0.2.0-rc.2",
62
- "@deepseek-ai/dsh-client-ui-primitives": "0.2.0-rc.2",
63
- "@deepseek-ai/dsh-client-ui-renderer": "0.2.0-rc.2",
64
- "@deepseek-ai/dsh-client-ui-session": "0.2.0-rc.2",
65
- "@deepseek-ai/dsh-session": "0.2.0-rc.2",
66
- "@deepseek-ai/dsh-util-crypto": "0.2.0-rc.2",
67
- "@deepseek-ai/dsh-client-shortcuts": "0.2.0-rc.2",
68
- "@deepseek-ai/dsh-brand": "0.2.0-rc.2",
69
- "@deepseek-ai/cordis": "~4.0.4",
70
- "@deepseek-ai/dsh-client-ui-layout": "0.2.0-rc.2",
71
- "@deepseek-ai/dsh-client-ui-slots": "0.2.0-rc.2"
70
+ "@deepseek-ai/dsh-client-shortcuts": "0.2.1-alpha.2",
71
+ "@deepseek-ai/dsh-brand": "0.2.1-alpha.2"
72
72
  },
73
73
  "files": [
74
74
  "lib/index.js",