dsh-m 0.9.53 → 0.9.55
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/CHANGELOG.md +24 -0
- package/lib/client.js +57 -15
- package/package.json +1 -1
- package/registry.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -8,6 +8,18 @@ The full release history of dsh-m, maintained bilingually: **Chinese first, Engl
|
|
|
8
8
|
|
|
9
9
|
## 中文
|
|
10
10
|
|
|
11
|
+
### 0.9.55 变更:ZoneChips 折叠/展开切换钮内联化(对齐 dsh-market 参考设计)+ overlay 叠涂 scrim 强化对比度
|
|
12
|
+
|
|
13
|
+
- **切换钮内联化(主人提出,dsh-market v1.66.11 参考设计)**:`+N` 从右侧 overlay 组改为**绝对定位内联**——钉在「末可见分类 chip 右侧 +6px」(即末可见行剩余空位),与展开态 `⌃`(列表末尾 in-flow)构成统一位置语义「紧跟当前列表末尾」,只翻方向不挪位;窄宽度放不下时贴内容右缘收口(不侵入筛选槽)。gutter 随 `+N` 移出由 132px 瘦身至 96px(仅承载钉住筛选),同宽度可多显示约 1 颗分类。overlay 组内 `+N` 移除后仅剩钉住筛选,第④类碰撞(R2-N1)自然消解。
|
|
14
|
+
- **overlay 叠涂 scrim(主人提出:浅色主题对比度偏低)**:根因是 `--dsw-alias-bg-base` token 本身 0.55 半透明;overlay 底衬改同 token **三层叠涂**(background-color + 双 linear-gradient 层),有效不透明度 ≈ 1−0.45³ ≈ 91%,深浅主题自适应(深色 rgba(12,26,38,·) / 浅色 rgba(247,250,252,·) 均显著强化),不引入硬编码色值。
|
|
15
|
+
- **测试**:全量 1221 例零失败、typecheck 零错误;无头探针实证:折叠态 `+N` 左缘 = 末可见 chip 右缘 +6px 同行对齐、scrim 双梯度、筛选单钮零碰撞、收起/展开往复位置稳定、Q1 回归(长文案 hidden>0);真机截图见发版记录。
|
|
16
|
+
|
|
17
|
+
### 0.9.54 变更:评审修复随版(ZoneChips 重测盲区/⌃ 弹回/overlay 居中)+ dsh-skip-browser-auth 收录文案对账
|
|
18
|
+
|
|
19
|
+
- **ZoneChips 三处评审修复(执行结果评审 R1,`b2aab5f`)**:① 测量 deps 以 `chips` 引用替代 `chips.length` 并叠加 `active`——同长度内容变化(计数刷新/激活加粗变宽)确定性重测,消除 RO 因 max-height 钳制失聪导致的陈旧 geom 盲区(被裁 chip 保持可聚焦/激活分类越界不自动展开的失效窗口,D4 违背态);② `⌃` 手动收起无条件记录 autoRef——手动收起全路径被尊重,消除展开态 geom 陈旧时收起被决策 effect 弹回的边缘漂移;③ overlay 组按 rowHeight 垂直居中(bottom 补偿偏移)。
|
|
20
|
+
- **收录文案对账(回应评审 Q5/Q7)**:dsh-skip-browser-auth 描述两轮更新随版生效(`ed6043a` 判别修复说明 + 缺陷警示、`23da0fd` 警示期结束瘦身保留保持最新版提示);自本版起发版前执行 tag↔CHANGELOG 对账,提交弃用 `git add -A` 改显式定点添加。
|
|
21
|
+
- **测试**:全量 1221 例零失败、typecheck 零错误;定向探针实证 Q1(同长度文案变化 hidden 0→5 即时重算)与 Q6(⌃ 收起后 +500ms 不弹回);真机 e2e(V1 冷存储/V4 吸顶/V6 筛选/V7 深色)见 0.9.53 证据链。
|
|
22
|
+
|
|
11
23
|
### 0.9.53 变更:ZoneChips 方案A「隐身全量测量」——冷挂载分类行错误折叠根除 + 行容量即时重测
|
|
12
24
|
|
|
13
25
|
- **动机(0.9.52 端到端验证发现)**:新浏览器 profile(无 localStorage 快照)首开面板时,市场数据未到 → `fit` 在空列表上测量 → 数据到达后重测面对的是按陈旧预算折叠的 DOM(只渲染 1 颗 + 「+N」)→ 棘轮式冻结在「3 颗 + +20」单行折叠。暖会话(快照命中)首挂载即全量数据、一次测准,故 0.7.0 以来从未暴露。姊妹问题:测量 effect 不监听宽度变化,窗口缩放后 `+N` 与实际容量脱节。完整根因链与无头实证见 `docs/plans/2026-10-08-zonechips-visual-clip-requirements.md`。
|
|
@@ -400,6 +412,18 @@ The full release history of dsh-m, maintained bilingually: **Chinese first, Engl
|
|
|
400
412
|
|
|
401
413
|
## English
|
|
402
414
|
|
|
415
|
+
### Changed in 0.9.55 — ZoneChips expand/collapse toggle inline (aligned with the dsh-market reference design) + overlay stacked scrim for contrast
|
|
416
|
+
|
|
417
|
+
- **Inline toggle (owner-requested, reference: dsh-market v1.66.11)**: `+N` moves out of the right-side overlay group into an **absolutely-positioned inline slot** pinned at "last visible category chip's right edge + 6px" (the leftover of the last visible row), sharing one position semantic with the expanded `⌃` (in-flow at list end): "hug the current end of the list", flipping direction without relocating; when the leftover is too narrow it clamps to the content right edge without entering the filter gutter. The gutter slims from 132px to 96px (hosting only the pinned filter), showing ~1 more category per width. With `+N` removed, the overlay group hosts only the pinned filter and the R2-N1 4th collision class dissolves naturally.
|
|
418
|
+
- **Overlay stacked scrim (owner-requested: low contrast in light theme)**: root cause is that the `--dsw-alias-bg-base` token itself is 0.55-translucent; the overlay scrim now paints the same token in a **three-layer stack** (background-color + two linear-gradient layers), effective opacity ≈ 1−0.45³ ≈ 91%, theme-adaptive (dark rgba(12,26,38,·) / light rgba(247,250,252,·) both significantly strengthened) with zero hard-coded colors.
|
|
419
|
+
- **Tests**: full suite 1221 cases zero failures, typecheck clean; headless probe verified collapsed-state `+N` left edge = last visible chip right edge + 6px on the same row, double scrim gradients, single-button zero-collision filter, stable toggle position across collapse/expand cycles, and the Q1 regression (long labels: hidden > 0); real-panel screenshots in the release record.
|
|
420
|
+
|
|
421
|
+
### Changed in 0.9.54 — review fixes ship (ZoneChips stale-geom / ⌃ bounce / overlay centering) + dsh-skip-browser-auth catalog copy reconciliation
|
|
422
|
+
|
|
423
|
+
- **ZoneChips review fixes (execution-review R1, `b2aab5f`)**: ① measure deps use the `chips` reference instead of `chips.length` plus `active` — same-length content changes (count refresh / active bold reflow) now deterministically re-measure, closing the stale-geom blind window where RO is deafened by the max-height clamp (clipped-but-focusable chips / missed auto-expand, a D4 violation); ② manual `⌃` collapse unconditionally records autoRef — manual collapse is respected on every path, removing the edge drift where a stale-geom decision effect bounced the collapse back; ③ the overlay group is vertically centered per measured row-height (compensated bottom offset).
|
|
424
|
+
- **Catalog copy reconciliation (review Q5/Q7)**: two rounds of dsh-skip-browser-auth description updates ship with this release (`ed6043a` fixed-branch note + defect warning, `23da0fd` warning-period ended, slimmed to keep-latest hint); from this release onward a tag↔CHANGELOG reconciliation runs before publishing, and commits use explicit `git add <files>` instead of `-A`.
|
|
425
|
+
- **Tests**: full suite 1221 cases zero failures, typecheck clean; directed probes verified Q1 (same-length label change: hidden 0→5 live recompute) and Q6 (post-⌃ +500ms stays collapsed); real-panel e2e (V1 cold storage / V4 sticky / V6 filter / V7 dark theme) in the 0.9.53 evidence chain.
|
|
426
|
+
|
|
403
427
|
### Changed in 0.9.53 — ZoneChips Plan A "invisible full-list measurement": cold-mount mis-collapse eradicated + live row-capacity re-measurement
|
|
404
428
|
|
|
405
429
|
- **Motivation (found during 0.9.52 end-to-end verification)**: with a fresh browser profile (no localStorage snapshot), the market data had not arrived when the panel first mounted, so the old `fit` measurement ran on an EMPTY list; when data arrived the re-measure faced a DOM already collapsed by the stale budget (1 chip + "+N") and ratcheted to a frozen "3 chips + +20" single row. Warm sessions hit the snapshot on first mount and measured correctly — which is why this 0.7.0-era defect never surfaced. Sister issue: the measure effect ignores width changes, so `+N` drifts from real capacity after window resizes. Full causal chain with headless evidence: `docs/plans/2026-10-08-zonechips-visual-clip-requirements.md`.
|
package/lib/client.js
CHANGED
|
@@ -2188,8 +2188,9 @@ var CSS = `
|
|
|
2188
2188
|
.dshm-input:focus{border-color:var(--dsw-alias-interactive-bg-selected,#4f46e5)}
|
|
2189
2189
|
.dshm-chips{display:flex;flex-wrap:wrap;gap:6px;position:relative}
|
|
2190
2190
|
.dshm-chips-clip{overflow:hidden}
|
|
2191
|
-
.dshm-chips-gutter{padding-right:var(--dshm-clip-gutter,
|
|
2192
|
-
.dsvm-chipmore{position:absolute;right:8px;
|
|
2191
|
+
.dshm-chips-gutter{padding-right:var(--dshm-clip-gutter,96px)}
|
|
2192
|
+
.dsvm-chipmore{position:absolute;right:8px;display:flex;align-items:center;gap:8px;min-height:28px;background-color:var(--dsw-alias-bg-base,#fff);background-image:linear-gradient(var(--dsw-alias-bg-base,#fff),var(--dsw-alias-bg-base,#fff)),linear-gradient(var(--dsw-alias-bg-base,#fff),var(--dsw-alias-bg-base,#fff));border:1px solid var(--dsw-alias-border-l1,rgba(127,127,127,.18));border-radius:999px;padding:2px 8px;box-sizing:border-box}
|
|
2193
|
+
.dsvm-chipmore-plus{position:absolute;z-index:2;background-color:var(--dsw-alias-bg-base,#fff);background-image:linear-gradient(var(--dsw-alias-bg-base,#fff),var(--dsw-alias-bg-base,#fff)),linear-gradient(var(--dsw-alias-bg-base,#fff),var(--dsw-alias-bg-base,#fff))}
|
|
2193
2194
|
.dsvm-searchrow{display:flex;align-items:center;gap:8px}
|
|
2194
2195
|
.dsvm-searchrow .dshm-search{flex:1;display:flex}
|
|
2195
2196
|
.dshm-search{position:relative}
|
|
@@ -2731,8 +2732,30 @@ function ZoneChips({ zone, counts, labels, active, onPick, trailing, wrapTitle }
|
|
|
2731
2732
|
if (!rh && k.offsetHeight) rh = k.offsetHeight;
|
|
2732
2733
|
}
|
|
2733
2734
|
if (!tops.length) return;
|
|
2734
|
-
const
|
|
2735
|
-
|
|
2735
|
+
const clipTop2 = clipTopOf2(tops, maxRows);
|
|
2736
|
+
let lastVisRight = 0;
|
|
2737
|
+
let lastVisTop = 0;
|
|
2738
|
+
let idx = -1;
|
|
2739
|
+
for (const k of el.children) {
|
|
2740
|
+
if (!(k instanceof HTMLElement) || k.getAttribute("data-chip") !== "1") continue;
|
|
2741
|
+
idx += 1;
|
|
2742
|
+
if (idx === 0) continue;
|
|
2743
|
+
if (k.offsetTop < clipTop2) {
|
|
2744
|
+
lastVisRight = k.offsetLeft + k.offsetWidth;
|
|
2745
|
+
lastVisTop = k.offsetTop;
|
|
2746
|
+
}
|
|
2747
|
+
}
|
|
2748
|
+
const cs = getComputedStyle(el);
|
|
2749
|
+
const contentW = el.clientWidth - (parseFloat(cs.paddingRight) || 0);
|
|
2750
|
+
const plusLeft = Math.max(0, Math.min(lastVisRight + 6, contentW - 48));
|
|
2751
|
+
const next = {
|
|
2752
|
+
tops,
|
|
2753
|
+
clipTop: clipTop2,
|
|
2754
|
+
hiddenCount: countBeyondRows2(tops.slice(1), maxRows),
|
|
2755
|
+
plusLeft,
|
|
2756
|
+
plusTop: lastVisTop
|
|
2757
|
+
};
|
|
2758
|
+
setGeom((prev) => prev && prev.tops.length === next.tops.length && prev.clipTop === next.clipTop && prev.hiddenCount === next.hiddenCount && prev.plusLeft === next.plusLeft && prev.plusTop === next.plusTop ? prev : next);
|
|
2736
2759
|
setRowHeight((prev) => Math.abs(prev - rh) <= 0.5 ? prev : rh);
|
|
2737
2760
|
}, [expanded, maxRows]);
|
|
2738
2761
|
useEffect(() => {
|
|
@@ -2750,7 +2773,7 @@ function ZoneChips({ zone, counts, labels, active, onPick, trailing, wrapTitle }
|
|
|
2750
2773
|
}, [active, activeIdx, expanded, geom]);
|
|
2751
2774
|
useLayoutEffect(() => {
|
|
2752
2775
|
if (!expanded) measure();
|
|
2753
|
-
}, [chips
|
|
2776
|
+
}, [chips, active, expanded, zone, stuck, rowHeight, measure]);
|
|
2754
2777
|
useEffect(() => {
|
|
2755
2778
|
const el = wrapRef.current;
|
|
2756
2779
|
if (!el || expanded || typeof ResizeObserver === "undefined") return;
|
|
@@ -2783,7 +2806,7 @@ function ZoneChips({ zone, counts, labels, active, onPick, trailing, wrapTitle }
|
|
|
2783
2806
|
return () => io.disconnect();
|
|
2784
2807
|
}, []);
|
|
2785
2808
|
const clip = !expanded;
|
|
2786
|
-
const
|
|
2809
|
+
const filterPinned = clip && trailing != null;
|
|
2787
2810
|
const clipTop = geom ? geom.clipTop : Infinity;
|
|
2788
2811
|
const hiddenCount = geom ? geom.hiddenCount : 0;
|
|
2789
2812
|
const btn = (c, i) => {
|
|
@@ -2818,25 +2841,44 @@ function ZoneChips({ zone, counts, labels, active, onPick, trailing, wrapTitle }
|
|
|
2818
2841
|
"div",
|
|
2819
2842
|
{
|
|
2820
2843
|
ref: wrapRef,
|
|
2821
|
-
className: `dshm-chips${clip ? " dshm-chips-clip" : ""}${
|
|
2844
|
+
className: `dshm-chips${clip ? " dshm-chips-clip" : ""}${filterPinned ? " dshm-chips-gutter" : ""}`,
|
|
2822
2845
|
title: wrapTitle || void 0,
|
|
2823
2846
|
style: { maxHeight: clip ? `${maxH}px` : "none" }
|
|
2824
2847
|
},
|
|
2825
2848
|
h("button", { "data-chip": "1", className: `dshm-chip${active == null ? " on" : ""}`, onClick: () => onPick(null) }, lookup("cat.all")),
|
|
2826
2849
|
...chips.map((c, i) => btn(c, i)),
|
|
2850
|
+
// 折叠态 +N(0.9.55 对齐 dsh-market 参考设计):绝对定位内联钉在「末可见分类 chip 右侧 +6px」,
|
|
2851
|
+
// 与展开态 ⌃(列表末尾 in-flow)构成同一位置语义——「紧跟当前列表末尾」,只翻方向不挪位。
|
|
2852
|
+
// 不带 data-chip(不参与行分组测量);位于可见行区内,不受 overflow 裁剪。
|
|
2853
|
+
clip && geom && hiddenCount > 0 ? h("button", {
|
|
2854
|
+
key: "more",
|
|
2855
|
+
className: "dshm-chip dsvm-chipmore-plus",
|
|
2856
|
+
style: { left: `${geom.plusLeft}px`, top: `${geom.plusTop}px` },
|
|
2857
|
+
onClick: () => setExpanded(true)
|
|
2858
|
+
}, `+${hiddenCount}`) : null,
|
|
2827
2859
|
expanded ? [
|
|
2828
|
-
h("button", {
|
|
2860
|
+
h("button", {
|
|
2861
|
+
key: "collapse",
|
|
2862
|
+
"data-chip": "1",
|
|
2863
|
+
className: "dshm-chip",
|
|
2864
|
+
// 评审 R1-Q6:手动收起即记录 autoRef——展开态下激活的分类若真实越界(geom 陈旧或
|
|
2865
|
+
// 收起重测后越界),决策 effect 不得立即弹回,「手动收起」无条件被尊重。
|
|
2866
|
+
onClick: () => {
|
|
2867
|
+
if (active) autoRef.current = active;
|
|
2868
|
+
setExpanded(false);
|
|
2869
|
+
}
|
|
2870
|
+
}, "\u2303"),
|
|
2829
2871
|
trailing || null
|
|
2830
2872
|
] : null
|
|
2831
2873
|
),
|
|
2832
|
-
//
|
|
2833
|
-
|
|
2834
|
-
// ⚠️ 展开态不用 overlay(⌃/筛选 in-flow,与现状一致);弹层锚点 .dsvm-filterwrap 随组定位。
|
|
2835
|
-
clip && overlay ? h(
|
|
2874
|
+
// 折叠态钉住的筛选触发器(gutter 几何保证与 chip 零相交;叠涂 scrim 强化浅色对比度,评审 R1 后主人优化②)
|
|
2875
|
+
filterPinned ? h(
|
|
2836
2876
|
"div",
|
|
2837
|
-
{
|
|
2838
|
-
|
|
2839
|
-
|
|
2877
|
+
{
|
|
2878
|
+
className: "dsvm-chipmore",
|
|
2879
|
+
style: { bottom: `${8 + ((rowHeight || 22) - 28) / 2}px` }
|
|
2880
|
+
},
|
|
2881
|
+
trailing || null
|
|
2840
2882
|
) : null
|
|
2841
2883
|
)
|
|
2842
2884
|
);
|
package/package.json
CHANGED
package/registry.json
CHANGED
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
{
|
|
88
88
|
"id": "dsh-skip-browser-auth",
|
|
89
89
|
"name": "DSH Skip Browser Auth",
|
|
90
|
-
"description": "替换官方 Connection 跳过 BrowserAuth,免 Token;已适配七个已审计精确版本对,详见仓库。仅支持 web profile;desktop
|
|
90
|
+
"description": "替换官方 Connection 跳过 BrowserAuth,免 Token;已适配七个已审计精确版本对,详见仓库。仅支持 web profile;desktop 宿主一律自动休眠(多进程树判别),desktop 用户请保持最新版。",
|
|
91
91
|
"category": "self-dev",
|
|
92
92
|
"tags": ["BrowserAuth", "连接", "安全", "工具"],
|
|
93
93
|
"verified": ["0.1.2-rc.1", "0.1.5-rc.1", "0.1.5-rc.2", "0.1.7-rc.1", "0.1.7-rc.2", "0.2.0-rc.1", "0.2.0-rc.2"],
|