@philomelcc/dsh-workbench 0.1.13 → 0.1.15

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.
Files changed (2) hide show
  1. package/client.js +224 -64
  2. package/package.json +1 -1
package/client.js CHANGED
@@ -4000,69 +4000,219 @@ var module = { exports: {} };
4000
4000
  const SCHEME_KEY = 'dsh-workbench:scheme';
4001
4001
  const LEGACY_PAPER_KEY = 'dsh-workbench:paper';
4002
4002
  const PAPER_TOKENS = {
4003
- '--dsw-alias-bg-base': '#f7f3ea',
4004
- '--dsw-alias-bg-layer-1': '#f2ece0',
4005
- '--dsw-alias-bg-layer-2': '#ece5d6',
4006
- '--dsw-alias-bg-overlay': '#faf5e9',
4007
- '--dsw-alias-border-l1': '#d8cfba',
4008
- '--dsw-alias-border-l2': '#c6bba2',
4009
- '--dsw-alias-brand-primary': '#8a6a45',
4010
- '--dsw-alias-label-primary': '#3b342a',
4011
- '--dsw-alias-label-secondary': '#6f6557',
4012
- // The HARNESS wordmark badge paints its block with `currentColor` and its
4013
- // letters with this inverted token. Under paper the block turned dark
4014
- // (paper label-primary) while the token stayed light-theme dark, so the
4015
- // badge read as black-on-black.
4016
- '--dsw-alias-label-primary-inverted': '#f7f3ea',
4017
- '--dsw-alias-state-error-primary': '#a34a3c',
4018
- '--dsw-alias-state-warn-primary': '#a8792c',
4019
- '--dsw-alias-state-success-primary': '#4f7a5a',
4020
- '--dsw-alias-state-idle-primary': '#a49a89',
4021
- '--dsw-specific-sidebar-fill': '#f2ece0',
4022
- // Chat bubbles: the light base uses a pale DeepSeek blue, which looks
4023
- // wrong on paper. These two are outside the alias layer.
4024
- '--dsw-specific-bubble': '#f2ecdf',
4025
- '--dsw-specific-bubble-highlight': '#e9dfcb',
4026
- // Pale blue surfaces the alias list does not cover: command chips,
4027
- // reference pills, selected file tabs, "load earlier", tool cards.
4028
- '--dsw-alias-state-business-tertiary': '#f1e9da',
4029
- '--dsw-alias-state-business-primary': '#8a6a45',
4030
- '--dsw-specific-sidebar-nav-item-active-accent': '#f1e9da',
4031
- '--dsw-specific-sidebar-nav-item-active': '#efe9db',
4032
- '--dsw-specific-selector': '#f1e9da',
4033
- '--dsw-specific-input-major': '#f2ece0',
4034
- '--dsw-specific-tip': '#f7f2e7',
4035
- '--dsw-specific-menu': '#fcf9f3',
4036
- // Scrollbars read their own alias pair and default to neutral grey.
4037
- '--dsw-alias-scrollbar-bg-l1': '#d8cfba',
4038
- '--dsw-alias-scrollbar-bg-l2': '#d8cfba',
4039
- '--dsw-alias-scrollbar-hover-l1': '#c6bba2',
4040
- '--dsw-alias-scrollbar-hover-l2': '#c6bba2',
4041
- // The neutral greys are blue-tinted. Buttons ("load earlier"), inputs,
4042
- // chips and cards read their pale surfaces from this ramp, so warm it up
4043
- // too; deep steps stay untouched because they are text/borders.
4044
- '--dsw-static-neutral-bluish-00': '#fbf6ea',
4045
- '--dsw-static-neutral-bluish-50': '#faf6ee',
4046
- '--dsw-static-neutral-bluish-55': '#f8f4ea',
4047
- '--dsw-static-neutral-bluish-60': '#f7f3ea',
4048
- '--dsw-static-neutral-bluish-75': '#f4eee1',
4049
- '--dsw-static-neutral-bluish-90': '#f2ecdf',
4050
- '--dsw-static-neutral-bluish-100': '#efe9db',
4051
- '--dsw-static-neutral-bluish-150': '#ece6d7',
4052
- '--dsw-static-neutral-bluish-200': '#e7dfcd',
4053
- // Mid and deep steps carry secondary text and icons (task rows read
4054
- // #adb2b8 = bluish-400). Paper never covered them, so those rows kept a
4055
- // cool grey on a warm sheet; warm the whole ramp in the same order.
4056
- '--dsw-static-neutral-bluish-300': '#d8cfba',
4057
- '--dsw-static-neutral-bluish-310': '#d3c8b2',
4058
- '--dsw-static-neutral-bluish-400': '#a49a89',
4059
- '--dsw-static-neutral-bluish-500': '#8a7f6e',
4060
- '--dsw-static-neutral-bluish-600': '#7d7262',
4061
- '--dsw-static-neutral-bluish-700': '#6f6557',
4062
- '--dsw-static-neutral-bluish-750': '#4f473a',
4063
- '--dsw-static-neutral-bluish-800': '#3b342a',
4003
+ // Full light-palette -> paper mapping (generated by tools/gen-paper-tokens.cjs).
4004
+ // Every surface/overlay/line token the light palette uses is remapped so
4005
+ // no light-theme grey leaks through on the paper sheet; brand/status
4006
+ // colours and dark-on-dark text stay untouched.
4007
+ '--dsw-alias-bg-base': '#f7f3ea',
4008
+ '--dsw-alias-bg-document-preview': '#f2ece0',
4009
+ '--dsw-alias-bg-layer-1': '#f7f3ea',
4010
+ '--dsw-alias-bg-layer-2': '#f7f3ea',
4011
+ '--dsw-alias-bg-layer-3': '#f7f3ea',
4012
+ '--dsw-alias-bg-mask-1': '#0000003d',
4013
+ '--dsw-alias-bg-mask-2': '#0000001f',
4014
+ '--dsw-alias-bg-mask-3': '#0000007a',
4015
+ '--dsw-alias-bg-mask-drop': '#faf5e9b3',
4016
+ '--dsw-alias-bg-mask-photo': '#000000e0',
4017
+ '--dsw-alias-bg-module-platform': '#f2ece0',
4018
+ '--dsw-alias-bg-multi-select': '#f2ece0',
4019
+ '--dsw-alias-bg-overlay': '#ece5d6',
4020
+ '--dsw-alias-bg-skeleton': '#3b342a0a',
4021
+ '--dsw-alias-border-inverted': '#0000',
4022
+ '--dsw-alias-border-inverted2': '#0000',
4023
+ '--dsw-alias-border-l1': '#d8cfba',
4024
+ '--dsw-alias-border-l2': '#c6bba2',
4025
+ '--dsw-alias-border-l3': '#3b342a1f',
4026
+ '--dsw-alias-border-l4': '#3b342a29',
4027
+ '--dsw-alias-border-selected': '#c6bba2',
4028
+ '--dsw-alias-brand-primary': '#3b342a',
4029
+ '--dsw-alias-brand-primary-invert': '#3b342a',
4030
+ '--dsw-alias-brand-text': '#3b342a',
4031
+ '--dsw-alias-button-contrast-fill': '#6f6557',
4032
+ '--dsw-alias-button-elevated-fill': '#f7f3ea',
4033
+ '--dsw-alias-button-floating-fill': '#f7f3ea',
4034
+ '--dsw-alias-button-floating-hover': '#f2ece0',
4035
+ '--dsw-alias-button-ghost-active-border': '#c6bba2',
4036
+ '--dsw-alias-button-ghost-active-fill': '#f2ece0',
4037
+ '--dsw-alias-button-ghost-active-hover': '#ece5d6',
4038
+ '--dsw-alias-button-primary-dimmed': '#f2ece0',
4039
+ '--dsw-alias-button-primary-fill': '#3b342a',
4040
+ '--dsw-alias-button-primary-hover': '#4f473a',
4041
+ '--dsw-alias-card-fill': '#f7f3ea',
4042
+ '--dsw-alias-card-fill-hover': '#f2ece0',
4043
+ '--dsw-alias-card-tile-fill': '#f7f3ea',
4044
+ '--dsw-alias-chart-system': '#ece5d6',
4045
+ '--dsw-alias-file-diff-added-bg': '#e6f1e0',
4046
+ '--dsw-alias-file-diff-added-gutter': '#eef6e6',
4047
+ '--dsw-alias-file-diff-deleted-bg': '#f6e3d9',
4048
+ '--dsw-alias-file-diff-deleted-gutter': '#fbf0ea',
4049
+ '--dsw-alias-hovercard-label-primary': '#ffffff',
4050
+ '--dsw-alias-hovercard-label-secondary': '#cfd3d6',
4051
+ '--dsw-alias-hovercard-label-tertiary': '#adb2b8',
4052
+ '--dsw-alias-illustration-background': '#f7f3ea',
4053
+ '--dsw-alias-illustration-backing': '#c6bba2',
4054
+ '--dsw-alias-illustration-detail': '#c6bba2',
4055
+ '--dsw-alias-illustration-inset': '#f2ece0',
4056
+ '--dsw-alias-illustration-shadow': '#f2ece0',
4057
+ '--dsw-alias-illustration-surface': '#f2ece0',
4058
+ '--dsw-alias-interactive-bg-active': '#3b342a1a',
4059
+ '--dsw-alias-interactive-bg-hover': '#3b342a0f',
4060
+ '--dsw-alias-interactive-bg-hover-accent': '#8a6a4524',
4061
+ '--dsw-alias-interactive-bg-hover-danger': '#a34a3c0d',
4062
+ '--dsw-alias-interactive-bg-hover-solid': '#f2ece0',
4063
+ '--dsw-alias-json-tree-icon': '#a49a89',
4064
+ '--dsw-alias-label-caption': '#a49a89',
4065
+ '--dsw-alias-label-dimmed': '#d8cfba',
4066
+ '--dsw-alias-label-document-preview': '#a49a89',
4067
+ '--dsw-alias-label-on-color': '#ffffff',
4068
+ '--dsw-alias-label-primary': '#3b342a',
4069
+ '--dsw-alias-label-primary-bluish': '#4f473a',
4070
+ '--dsw-alias-label-primary-dimmed': '#3b342a',
4071
+ '--dsw-alias-label-primary-foreground': '#ffffff',
4072
+ '--dsw-alias-label-primary-inverted': '#f7f3ea',
4073
+ '--dsw-alias-label-secondary': '#6f6557',
4074
+ '--dsw-alias-label-shimmer': '#3b342a',
4075
+ '--dsw-alias-label-tertiary': '#8a7f6e',
4076
+ '--dsw-alias-markdown-citation': '#f4eee1',
4077
+ '--dsw-alias-markdown-code-block': '#f4eee1',
4078
+ '--dsw-alias-markdown-code-block-banner': '#f4eee1',
4079
+ '--dsw-alias-markdown-code-segment-selected': '#f7f3ea',
4080
+ '--dsw-alias-markdown-code-segment-unselected': '#f2ece0',
4081
+ '--dsw-alias-markdown-inline-code': '#f4eee1',
4082
+ '--dsw-alias-markdown-placeholder': '#f7f3ea',
4083
+ '--dsw-alias-markdown-tag': '#f7f3ea',
4084
+ '--dsw-alias-menu-group-header-fill': '#f2ece0f0',
4085
+ '--dsw-alias-menu-icon': '#4f473a',
4086
+ '--dsw-alias-onboarding-card-fill': '#fbf6ec',
4087
+ '--dsw-alias-onboarding-secondary-fill': '#fbf6ec',
4088
+ '--dsw-alias-scrollbar-bg-l1': '#d8cfba',
4089
+ '--dsw-alias-scrollbar-bg-l2': '#d8cfba',
4090
+ '--dsw-alias-scrollbar-hover-l1': '#c6bba2',
4091
+ '--dsw-alias-scrollbar-hover-l2': '#c6bba2',
4092
+ '--dsw-alias-settings-card-fill': '#f7f3ea',
4093
+ '--dsw-alias-settings-card-stroke': '#c6bba2',
4094
+ '--dsw-alias-state-business-tertiary': '#f1e9da',
4095
+ '--dsw-alias-state-idle-primary': '#d8cfba',
4096
+ '--dsw-alias-state-success-tertiary': '#e9f1e2',
4097
+ '--dsw-alias-state-warn-tertiary': '#f5ecdd',
4098
+ '--dsw-alias-switch-thumb': '#fbf6ec',
4099
+ '--dsw-alias-toast-label': '#ffffff',
4100
+ '--dsw-alias-tooltip-label': '#ffffff',
4101
+ '--dsw-alias-turn-trigger-bg': '#f7f3ea',
4102
+ '--dsw-alias-turn-trigger-bg-hover': '#3b342a0f',
4103
+ '--dsw-specific-bubble': '#f2ecdf',
4104
+ '--dsw-specific-bubble-highlight': '#e9dfcb',
4105
+ '--dsw-specific-guide-hero': '#ece5d6',
4106
+ '--dsw-specific-input-major': '#f7f3ea',
4107
+ '--dsw-specific-login-input': '#f7f3ea',
4108
+ '--dsw-specific-menu': '#f8f3e8b3',
4109
+ '--dsw-specific-selector': '#f2ece0',
4110
+ '--dsw-specific-sidebar-fill': '#f7f3ea',
4111
+ '--dsw-menu-surface-fill': '#f7f3eab3',
4112
+ '--dsw-specific-sidebar-glass-fill': '#fbf6ec8c',
4113
+ '--dsw-specific-sidebar-glass-hover': '#fbf6ec4d',
4114
+ '--dsw-specific-sidebar-nav-item-active': '#efe9db',
4115
+ '--dsw-specific-sidebar-nav-item-active-accent': '#f1e9da',
4116
+ '--dsw-specific-sidebar-tint': '#f7f3ea',
4117
+ '--dsw-specific-tip': '#f2ece0',
4118
+ '--dsw-static-amber-100': '#f5ecdd',
4119
+ '--dsw-static-blue-100': '#efe6d4',
4120
+ '--dsw-static-blue-300': '#c6bba2',
4121
+ '--dsw-static-blue-50': '#f7f2e7',
4122
+ '--dsw-static-blue-50p': '#f5efdf',
4123
+ '--dsw-static-blue-75': '#f4edde',
4124
+ '--dsw-static-deepseek-100': '#efe6d4',
4125
+ '--dsw-static-deepseek-200': '#e9dfcb',
4126
+ '--dsw-static-deepseek-300': '#d8cfba',
4127
+ '--dsw-static-deepseek-400': '#8a6a45',
4128
+ '--dsw-static-deepseek-50': '#f1e9da',
4129
+ '--dsw-static-green-100': '#e9f1e2',
4130
+ '--dsw-static-neutral-00': '#f7f3ea',
4131
+ '--dsw-static-neutral-100': '#f7f3ea',
4132
+ '--dsw-static-neutral-150': '#f7f3ea',
4133
+ '--dsw-static-neutral-200': '#ece5d6',
4134
+ '--dsw-static-neutral-250': '#d8cfba',
4135
+ '--dsw-static-neutral-300': '#d8cfba',
4136
+ '--dsw-static-neutral-400': '#a49a89',
4137
+ '--dsw-static-neutral-50': '#f7f3ea',
4138
+ '--dsw-static-neutral-500': '#8a7f6e',
4139
+ '--dsw-static-neutral-550': '#8a7f6e',
4140
+ '--dsw-static-neutral-600': '#7d7262',
4141
+ '--dsw-static-neutral-700': '#6f6557',
4142
+ '--dsw-static-neutral-bluish-00': '#f7f3ea',
4143
+ '--dsw-static-neutral-bluish-100': '#f7f3ea',
4144
+ '--dsw-static-neutral-bluish-150': '#ece5d6',
4145
+ '--dsw-static-neutral-bluish-200': '#ece5d6',
4146
+ '--dsw-static-neutral-bluish-300': '#d8cfba',
4147
+ '--dsw-static-neutral-bluish-310': '#d8cfba',
4148
+ '--dsw-static-neutral-bluish-400': '#a49a89',
4149
+ '--dsw-static-neutral-bluish-50': '#f7f3ea',
4150
+ '--dsw-static-neutral-bluish-500': '#8a7f6e',
4151
+ '--dsw-static-neutral-bluish-55': '#f7f3ea',
4152
+ '--dsw-static-neutral-bluish-60': '#f7f3ea',
4153
+ '--dsw-static-neutral-bluish-600': '#7d7262',
4154
+ '--dsw-static-neutral-bluish-700': '#6f6557',
4155
+ '--dsw-static-neutral-bluish-75': '#f7f3ea',
4156
+ '--dsw-static-neutral-bluish-750': '#4f473a',
4157
+ '--dsw-static-neutral-bluish-800': '#3b342a',
4158
+ '--dsw-static-neutral-bluish-90': '#f7f3ea',
4159
+ '--dsw-static-red-100': '#f6e3d9',
4160
+ '--dsw-static-red-50': '#faf0e9',
4161
+ '--dsw-static-violet-400': '#a8875c',
4064
4162
  };
4065
4163
 
4164
+ // Paper-only rules the token layer cannot express. The light palette's
4165
+ // ordering is: page (darker sheet) -> cards brighter on top -> controls
4166
+ // and selected states one step darker. Every rule below keeps that order
4167
+ // and re-declares :hover so the !important backgrounds don't eat the
4168
+ // hover feedback.
4169
+ // Paper-only rules. Light palette facts (measured): page #fff, layer
4170
+ // fills #fff (== page), card fill #fafafa (near page), selected/controls
4171
+ // #f5f6f7. Paper keeps the same order: page #f7f3ea, cards fill with the
4172
+ // page colour, hover/selected go one step darker (#f2ece0).
4173
+ const PAPER_RULES = `
4174
+ body[data-wb-paper="1"] .VOzbGW_panel { background: #f7f3ea !important; }
4175
+ body[data-wb-paper="1"] .rtSEdW_card { border-width: 1px; background: #f7f3ea !important; }
4176
+ body[data-wb-paper="1"] .rtSEdW_card:hover { background: #f2ece0 !important; }
4177
+ body[data-wb-paper="1"] .rtSEdW_cardActive,
4178
+ body[data-wb-paper="1"] .rtSEdW_cardActive:hover { border-color: #c6bba2 !important; background: #f2ece0 !important; }
4179
+ body[data-wb-paper="1"] .rtSEdW_cardMain,
4180
+ body[data-wb-paper="1"] .rtSEdW_cardHead,
4181
+ body[data-wb-paper="1"] .rtSEdW_cardIdentity,
4182
+ body[data-wb-paper="1"] .rtSEdW_cardId,
4183
+ body[data-wb-paper="1"] .rtSEdW_cardDesc,
4184
+ body[data-wb-paper="1"] .rtSEdW_cardHelp,
4185
+ body[data-wb-paper="1"] .rtSEdW_cardFoot { background: transparent !important; }
4186
+ body[data-wb-paper="1"] .uV2eYG_card { background: #f7f3ea !important; }
4187
+ body[data-wb-paper="1"] ._8HJdBW_themeCube { border-width: 1px; background: #f7f3ea !important; }
4188
+ body[data-wb-paper="1"] ._8HJdBW_themeCube:hover { background: #f2ece0 !important; }
4189
+ body[data-wb-paper="1"] ._8HJdBW_themeCube._8HJdBW_selected,
4190
+ body[data-wb-paper="1"] ._8HJdBW_themeCube._8HJdBW_selected:hover { background: #f2ece0 !important; }
4191
+ body[data-wb-paper="1"] .qSYn7G_card { background: #f7f3ea !important; }
4192
+ body[data-wb-paper="1"] .qSYn7G_cards,
4193
+ body[data-wb-paper="1"] .qSYn7G_cardDescription,
4194
+ body[data-wb-paper="1"] .qSYn7G_cardMeta,
4195
+ body[data-wb-paper="1"] .qSYn7G_cardMainRow,
4196
+ body[data-wb-paper="1"] .qSYn7G_cardTitle,
4197
+ body[data-wb-paper="1"] .qSYn7G_cardTrailing { background: transparent !important; }
4198
+
4199
+ body[data-wb-paper="1"] .qSYn7G_cardContent { background: transparent !important; }
4200
+ body[data-wb-paper="1"] .qSYn7G_card:hover,
4201
+ body[data-wb-paper="1"] .qSYn7G_card:hover .qSYn7G_cardContent { background: #f2ece0 !important; }
4202
+ body[data-wb-paper="1"] .X_2TxG_card,
4203
+ body[data-wb-paper="1"] .X_2TxG_cardHead,
4204
+ body[data-wb-paper="1"] .X_2TxG_cardMain,
4205
+ body[data-wb-paper="1"] .X_2TxG_cards,
4206
+ body[data-wb-paper="1"] .X_2TxG_cardDesc,
4207
+ body[data-wb-paper="1"] .X_2TxG_cardIcon,
4208
+ body[data-wb-paper="1"] .X_2TxG_cardEnd,
4209
+ body[data-wb-paper="1"] .X_2TxG_cardTitle,
4210
+ body[data-wb-paper="1"] .X_2TxG_cardOpen { background: transparent !important; }
4211
+ body[data-wb-paper="1"] .X_2TxG_card:hover { background: #f2ece0 !important; }
4212
+ `;
4213
+
4214
+
4215
+
4066
4216
  // Swatches double as both the current-state indicator and the toggle.
4067
4217
  const THEME_SWATCHES = [
4068
4218
  { id: 'dark', label: '深色', color: '#15171a', ring: 'rgba(255,255,255,0.28)' },
@@ -5020,10 +5170,13 @@ body[data-wb-paper="1"] [class*="_hoverPath"] {
5020
5170
  // style tag used to be injected with the plugin, so turning the switch off
5021
5171
  // left the spinner hidden with nothing drawing in its place.
5022
5172
  var HIDDEN_SPINNER_STYLE = `
5173
+ /* Only the session rows swap their spinner for the flowing glow. The
5174
+ background-task button keeps its own ring: hiding it left an empty slot on
5175
+ the left of the pill and the label drifted out of place. */
5023
5176
  div[data-row-key^="session:"]:has(svg[data-state="ongoing"]) svg[data-state="ongoing"],
5024
- .dsh-glow-on svg[data-state="ongoing"],
5025
- .dsh-glow-on [data-state="ongoing"],
5026
- .dsh-glow-on > span:first-child > svg {
5177
+ div[data-row-key^="session:"].dsh-glow-on > span:first-child > svg,
5178
+ .dsh-glow-on svg[data-state="ongoing"]:not(button[aria-label*="后台任务"] *):not(button[aria-label*="background task"] *),
5179
+ .dsh-glow-on [data-state="ongoing"]:not(button[aria-label*="后台任务"] *):not(button[aria-label*="background task"] *) {
5027
5180
  display: none !important;
5028
5181
  }
5029
5182
  `;
@@ -5279,6 +5432,13 @@ div[data-row-key^="session:"]:has(svg[data-state="ongoing"]) svg[data-state="ong
5279
5432
  inject: ['slots', 'remote', 'remote.account', 'jobs'],
5280
5433
  apply(ctx) {
5281
5434
  try {
5435
+ // Paper-only rules get their own style appended to <body>.
5436
+ ctx.effect(() => {
5437
+ const tag = document.createElement('style');
5438
+ tag.textContent = PAPER_RULES;
5439
+ document.body.appendChild(tag);
5440
+ return () => tag.remove();
5441
+ });
5282
5442
  if (typeof document !== 'undefined') {
5283
5443
  ctx.effect(() => {
5284
5444
  const tag = document.createElement('style');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@philomelcc/dsh-workbench",
3
- "version": "0.1.13",
3
+ "version": "0.1.15",
4
4
  "type": "module",
5
5
  "description": "Workbench shell for DeepSeek Harness: a view/page module API, shared UI primitives and a top-bar switcher.",
6
6
  "license": "MIT",