dsh-tidy-display 0.4.0 → 0.4.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/scripts/hosts.mjs CHANGED
@@ -8,6 +8,9 @@
8
8
  * 与 0.1.6-alpha.1/2 为未成线 alpha,不入列),由本地隔离矩阵逐格验证后**删红留绿**;
9
9
  * 矩阵结论落 `.compat-results/`。
10
10
  * 升级流程:本数组加版本 → `node scripts/sync-hosts.mjs --write` → 矩阵绿 → 发版。
11
+ * 2026-10-17 补票:追加 0.2.1-rc.1(七仓缺口补票批次,同串精确枚举纪律)。
12
+ * 2026-10-18 补票:追加 0.2.1-rc.2(12 个 host peer 包逐一 npm 实测 rc.2 均在版;
13
+ * 声明面支持,断裂面未做整矩阵实机——见 CHANGELOG 0.4.2 注记)。
11
14
  *
12
15
  * 本数组与由它生成的声明写点(package.json peerDependencies 的 12 个 dsh-* 项 /
13
16
  * package.json engines.dsh / 各 README 的 host-compat 管理块)**禁止手改**,
@@ -37,13 +40,16 @@ export const supportedHosts = Object.freeze([
37
40
  // 0.2.0 线(2 个 rc)
38
41
  '0.2.0-rc.1',
39
42
  '0.2.0-rc.2',
43
+ // 0.2.1 线(2 个 rc)
44
+ '0.2.1-rc.1',
45
+ '0.2.1-rc.2',
40
46
  ])
41
47
 
42
48
  /** peerDependencies / engines.dsh 共用的枚举串(精确枚举无暗坑,INDEX §B)。 */
43
49
  export const peerRange = supportedHosts.join(' || ')
44
50
 
45
51
  /** 本地开发与矩阵默认宿主(devDependencies 若引入宿主包一律钉这里)。 */
46
- export const developmentHost = '0.2.0-rc.2'
52
+ export const developmentHost = '0.2.1-rc.1'
47
53
 
48
54
  /**
49
55
  * peer 闸指向的宿主子包(本插件消费的全部宿主面:peerDependencies 里的 12 个
@@ -67,10 +67,10 @@ if (hasManifest) {
67
67
  const BEGIN = '<!-- host-compat:begin — generated by scripts/sync-hosts.mjs from scripts/hosts.mjs; DO NOT EDIT -->'
68
68
  const END = '<!-- host-compat:end -->'
69
69
  const versionList = supportedHosts.map((v) => `\`${v}\``).join(' ')
70
- const LINES = '0.1.0 / 0.1.1 / 0.1.2 / 0.1.5 / 0.1.7 / 0.2.0'
70
+ const LINES = '0.1.0 / 0.1.1 / 0.1.2 / 0.1.5 / 0.1.7 / 0.2.0 / 0.2.1'
71
71
  const linesPerLang = {
72
72
  'README.md': [
73
- `- **支持的 DSH 宿主:** ${versionList}(覆盖 ${LINES} 六条线共 ${supportedHosts.length} 个 rc)`,
73
+ `- **支持的 DSH 宿主:** ${versionList}(覆盖 ${LINES} 七条线共 ${supportedHosts.length} 个 rc)`,
74
74
  ],
75
75
  'README.en.md': [
76
76
  `- **Supported DSH hosts:** ${versionList} (${supportedHosts.length} rc releases across lines ${LINES})`,
@@ -1,5 +1,6 @@
1
1
  import { useCallback, useState, useSyncExternalStore, type ReactNode } from 'react';
2
2
  import type { ChatConversationViewNode, ChatNodeOwnerProps, TurnTailOwnerProps, UseDisclosure } from '@deepseek-ai/dsh-client-ui-chat/client';
3
+ import type { MessageImagesOwnerProps } from '@deepseek-ai/dsh-client-ui-conversation/client';
3
4
  import { createSnapshotStore } from './store-face.js';
4
5
  import type { ToolCallBlock } from '@deepseek-ai/dsh-client-ui-conversation/client';
5
6
  import type { AssistantActionOwnerProps } from '@deepseek-ai/dsh-client-ui-chat/client';
@@ -41,18 +42,21 @@ export function OfficialNode({ node, fallback, ...render }: BlockRenderProps & {
41
42
  const official = render.official;
42
43
  const [disclosureReset] = useState(() => createSnapshotStore(0));
43
44
  if (!official) return fallback;
44
- const owner: ChatNodeOwnerProps = {
45
+ // rc.1 起 ChatNodeOwnerProps 移除了 openSkill/renderMessageImages(消息图改走
46
+ // conversation.chat.message.images 子槽);旧线宿主仍要求这两字段,继续供给,
47
+ // 类型对开发线(rc.1)编译,旧线字段经 cast 逃逸。
48
+ const owner = {
45
49
  cwd: render.cwd,
46
50
  openFile: render.openFile ?? (() => {}),
47
51
  openSkill: () => {},
48
52
  forkAt: render.forkAt ?? (() => {}),
49
- inspectCall: callId => official.openView('trajectory', callId),
53
+ inspectCall: (callId: Parameters<NonNullable<ChatNodeOwnerProps['inspectCall']>>[0]) => official.openView('trajectory', callId),
50
54
  loadImage: official.officialImageLoader,
51
- renderMessageImages: images => official.renderSlot(OFFICIAL_SEATS.images, {
55
+ renderMessageImages: (images: MessageImagesOwnerProps) => official.renderSlot(OFFICIAL_SEATS.images, {
52
56
  ...images, loadImage: official.officialImageLoader,
53
57
  }),
54
58
  fileMentions: official.officialFileMentions,
55
- };
59
+ } as unknown as ChatNodeOwnerProps;
56
60
  const turn = node.location.kind === 'turn' || node.location.kind === 'step' ? node.location.turn : undefined;
57
61
  // The runtime node domain is open; the public SlotMap enumerates the known kinds.
58
62
  const renderNode = official.renderSlot as unknown as (key: string, owner: object, options: object) => ReactNode;
@@ -570,6 +570,11 @@
570
570
  decorative chrome (border, 16px radius, floating shadow) is dropped, so the
571
571
  skin stays visible across the whole reading view. Off keeps the pre-#14 /
572
572
  current-main opaque chrome. */
573
+ /* One plate knob for the whole glass branch: the frosted switch IS the
574
+ translucent switch, so On washes every reader-painted plate at 35%. Off
575
+ paints no wash at all — the reader falls back to opaque host-derived
576
+ surfaces, which clear the "no less than 45% solid" floor by construction. */
577
+ .root[data-reader-glass] { --reader-plate-wash: 35%; }
573
578
  .root[data-reader-glass] .toolbar,
574
579
  .root[data-reader-glass] .turnProcessSticky,
575
580
  .root[data-reader-glass] .liveFoldContainer {
@@ -594,9 +599,12 @@
594
599
  padding-left: 10px;
595
600
  border-radius: 0;
596
601
  }
597
- /* User bubble becomes a sleek translucent frosted pill in skin mode */
602
+ /* User bubble becomes a sleek translucent frosted pill in skin mode, riding
603
+ the shared --reader-plate-wash knob. The bubble token is a dark low-alpha
604
+ color, so its wash stays a lighter touch than the content plates'; the
605
+ blur layer carries contrast against busy wallpapers. */
598
606
  .root[data-reader-glass] .user {
599
- background: color-mix(in srgb, var(--dsw-specific-bubble, rgba(0,0,0,.08)) 25%, transparent);
607
+ background: color-mix(in srgb, var(--dsw-specific-bubble, rgba(0,0,0,.14)) var(--reader-plate-wash), transparent);
600
608
  backdrop-filter: blur(12px);
601
609
  -webkit-backdrop-filter: blur(12px);
602
610
  border: 1px solid color-mix(in srgb, var(--dsw-alias-border-l1, rgba(128,128,128,.3)) 30%, transparent);
@@ -607,6 +615,16 @@
607
615
  background: transparent;
608
616
  border-color: color-mix(in srgb, var(--dsw-alias-border-l1, rgba(128,128,128,.35)) 65%, transparent);
609
617
  }
618
+ /* Content surfaces are the exception to "paint no plates": full transparency
619
+ put tool results, notices and raw blocks straight onto the wallpaper and
620
+ the text smeared against the picture. They get a translucent wash of the
621
+ theme-aware page base (bg-base: near-white in light, near-dark in dark, so
622
+ a dark skin does not get white boxes) plus the always-on neutral tint as a
623
+ background-image — the same defense as the answer bubble: a skin zeroing
624
+ the token cannot erase the image layer and collapse the card back to a
625
+ floorless frame. The modal once rode a firmer 80% tier; it now shares the
626
+ single knob — if it reads too thin over the photo mask backdrop, give
627
+ .imageDialog its own higher --reader-plate-wash override. */
610
628
  .root[data-reader-glass] .toolDetails,
611
629
  .root[data-reader-glass] .notice,
612
630
  .root[data-reader-glass] .unknown,
@@ -616,7 +634,23 @@
616
634
  .root[data-reader-glass] .attention,
617
635
  .root[data-reader-glass] .imageFrame,
618
636
  .root[data-reader-glass] .imageDialog {
619
- background: transparent;
637
+ background: color-mix(in srgb, var(--dsw-alias-bg-base, #fff) var(--reader-plate-wash), transparent);
638
+ background-image: linear-gradient(rgba(127, 127, 127, .08), rgba(127, 127, 127, .08));
639
+ backdrop-filter: blur(12px);
640
+ -webkit-backdrop-filter: blur(12px);
641
+ }
642
+ /* Process commentary is real prose riding the rail, not chrome: under a skin
643
+ its paragraphs smeared over the wallpaper just like the tool cards did.
644
+ It takes the same plate knob; the block/end padding keeps the wash off the
645
+ text edges while the start side keeps the shared rail gutter untouched. */
646
+ .root[data-reader-glass] .processCommentary {
647
+ background: color-mix(in srgb, var(--dsw-alias-bg-base, #fff) var(--reader-plate-wash), transparent);
648
+ background-image: linear-gradient(rgba(127, 127, 127, .08), rgba(127, 127, 127, .08));
649
+ backdrop-filter: blur(12px);
650
+ -webkit-backdrop-filter: blur(12px);
651
+ padding-block: 6px;
652
+ padding-right: 10px;
653
+ border-radius: 8px;
620
654
  }
621
655
  /* Diff overlay in skin mode */
622
656
  .root[data-reader-glass] .diffOverlay {
@@ -743,7 +743,7 @@ export function Reader(props: ReaderProps) {
743
743
 
744
744
  // ChatView publishes data-chat-flow="" on its column. Skins treat a
745
745
  // scrollport without that hook as inspect-only and hide [data-composer-seat].
746
- return <StreamMotionContext.Provider value={streamMotion}><div ref={root} className={css.root} data-reader-build="0.4.0" data-dsh-tidy-display="0.4.0" data-reader-wait-clock-version="input-v1" data-reader-wait-start={waitAnchor.time ?? undefined} data-motion={motion ? 'on' : 'off'} data-reader-glass={frostedGlass || undefined} data-reader-bubbles={bubbles ? 'on' : 'off'} data-reader-auto-fold={autoFold ? 'on' : 'off'}>
746
+ return <StreamMotionContext.Provider value={streamMotion}><div ref={root} className={css.root} data-reader-build="0.4.2" data-dsh-tidy-display="0.4.2" data-reader-wait-clock-version="input-v1" data-reader-wait-start={waitAnchor.time ?? undefined} data-motion={motion ? 'on' : 'off'} data-reader-glass={frostedGlass || undefined} data-reader-bubbles={bubbles ? 'on' : 'off'} data-reader-auto-fold={autoFold ? 'on' : 'off'}>
747
747
  <RailView enabled={railEnabled} side={railSide} style={railStyle} ring={railRing} hideOfficialNav={hideOfficialNav} hasMore={hasMore} loadOlder={props.loadOlder} />
748
748
  <div className={css.column} data-chat-flow="">
749
749
  <StickyLane kind="toolbar" className={css.toolbar}>
@@ -18,7 +18,7 @@ export const OFFICIAL_SLOTS = {
18
18
  tools: 'tool.call.toolview',
19
19
  tail: 'conversation.chat.turnTail',
20
20
  nodes: 'conversation.chat.node',
21
- images: 'conversation.message.images',
21
+ images: 'conversation.chat.message.images',
22
22
  } as const;
23
23
  export type OfficialFamily = keyof typeof OFFICIAL_SLOTS;
24
24
  export const OFFICIAL_SEATS = {
@@ -26,7 +26,7 @@ export const OFFICIAL_SEATS = {
26
26
  tools: 'dsh-tidy-display.official.tools/tool.call.toolview',
27
27
  tail: 'dsh-tidy-display.official.tail/conversation.chat.turnTail',
28
28
  nodes: 'dsh-tidy-display.official.nodes/conversation.chat.node',
29
- images: 'dsh-tidy-display.official.images/conversation.message.images',
29
+ images: 'dsh-tidy-display.official.images/conversation.chat.message.images',
30
30
  } as const;
31
31
  export type OfficialSeat = typeof OFFICIAL_SEATS[OfficialFamily];
32
32
  export const officialSeat = (family: OfficialFamily, source: string = OFFICIAL_SLOTS[family]) =>
@@ -52,7 +52,7 @@ declare module '@deepseek-ai/dsh-client-ui-slots' {
52
52
  'dsh-tidy-display.official.tools/tool.call.toolview': SlotMap['tool.call.toolview'];
53
53
  'dsh-tidy-display.official.tail/conversation.chat.turnTail': SlotMap['conversation.chat.turnTail'];
54
54
  'dsh-tidy-display.official.nodes/conversation.chat.node': SlotMap['conversation.chat.node'];
55
- 'dsh-tidy-display.official.images/conversation.message.images': SlotMap['conversation.message.images'];
55
+ 'dsh-tidy-display.official.images/conversation.chat.message.images': SlotMap['conversation.chat.message.images'];
56
56
  }
57
57
  }
58
58
 
@@ -21,6 +21,8 @@ export const readBlockLabels: ReadBlockLabels = {
21
21
  };
22
22
 
23
23
  export const terminalBlockLabels: TerminalBlockLabels = {
24
+ // rc.1 起必填:多行命令逐行渲染时给溢出行的可访问名(官方 zh 文案同串)。
25
+ commandLine: line => `命令第 ${line} 行`,
24
26
  signal: signal => `信号 ${signal}`, exitCode: code => `退出码 ${code}`, noExitCode: '无退出码',
25
27
  running: '执行中', failed: '失败', done: '已完成', copy: '复制', copied: '已复制',
26
28
  noOutput: '没有输出', collapseAria: '收起命令输出', collapse: '收起',
@@ -78,7 +78,7 @@ slots.register({ name: 'root', children: {
78
78
  'tool.call.toolview': { kind: 'keyed', scope: 'session' },
79
79
  'conversation.chat.turnTail': { kind: 'list', scope: 'session' },
80
80
  'conversation.chat.node': { kind: 'keyed', scope: 'session', inject: { hooks: { turnData: (_s: any, value: any) => () => value } } },
81
- 'conversation.message.images': { kind: 'single', scope: 'session' },
81
+ 'conversation.chat.message.images': { kind: 'single', scope: 'session' },
82
82
  'conversation.input.overlay': { kind: 'list', scope: 'session' },
83
83
  'fixture.reader': { kind: 'single', scope: 'session' },
84
84
  } }, ({ SessionProvider, renderSlot }: any) => <SessionProvider>