dsh-session-relocate 0.3.0 → 0.3.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/lib/client.js +20 -9
- package/package.json +1 -1
package/lib/client.js
CHANGED
|
@@ -107,10 +107,11 @@ window.__ModuleLoader__.load({
|
|
|
107
107
|
'.dshsm-light .dshsm-picker-btn:hover:not(:disabled){background:rgba(0,0,0,.06)}',
|
|
108
108
|
'.dshsm-picker-btn:disabled{opacity:.45;cursor:default}',
|
|
109
109
|
// 插件设置页:连同子对话开关
|
|
110
|
-
'.dshsm-setting{display:flex;align-items:flex-start;gap:16px;padding:12px 0;width:100%}',
|
|
110
|
+
'.dshsm-setting{position:relative;display:flex;align-items:flex-start;gap:16px;padding:12px 0;width:100%}',
|
|
111
111
|
'.dshsm-setting-text{flex:1;min-width:0}',
|
|
112
112
|
'.dshsm-setting-title{font-size:13px;font-weight:600;line-height:20px}',
|
|
113
|
-
'.dshsm-setting-desc{font-size:12px;line-height:18px;opacity
|
|
113
|
+
'.dshsm-setting-desc{position:absolute;left:0;top:100%;z-index:6;max-width:min(560px,100%);margin-top:6px;padding:8px 10px;border-radius:8px;border:1px solid rgba(0,0,0,.08);background:var(--dsw-alias-bg-layer-2,#fff);box-shadow:0 6px 20px rgba(0,0,0,.10);font-size:12px;line-height:18px;color:var(--dsw-alias-label-primary,#111);opacity:0;pointer-events:none;transition:opacity .12s}',
|
|
114
|
+
'.dshsm-setting:hover .dshsm-setting-desc{opacity:1}',
|
|
114
115
|
'.dshsm-seg{display:inline-flex;align-items:center;gap:2px;padding:2px;border-radius:8px;background:var(--dsw-alias-interactive-bg-hover,rgba(127,127,127,.12));flex:none}',
|
|
115
116
|
'.dshsm-segBtn{border:0;background:0 0;color:var(--dsw-alias-label-secondary,inherit);font:inherit;font-size:12px;line-height:18px;padding:3px 8px;border-radius:6px;cursor:pointer;white-space:nowrap}',
|
|
116
117
|
'.dshsm-segBtn[data-on="true"]{background:var(--dsw-alias-bg-layer-2,#fff);color:var(--dsw-alias-label-primary,inherit)}',
|
|
@@ -138,8 +139,13 @@ window.__ModuleLoader__.load({
|
|
|
138
139
|
'.dshsm-menu-disambig{display:flex;align-items:center;gap:4px;min-width:0}',
|
|
139
140
|
'.dshsm-menu-title{text-overflow:ellipsis;min-width:0;overflow:hidden}',
|
|
140
141
|
'.dshsm-menu-suffix{flex:none;max-width:75%;text-overflow:ellipsis;min-width:0;overflow:hidden;color:var(--dsw-alias-label-secondary,inherit)}',
|
|
142
|
+
// hover → 整行悬浮显形(盯 .dshsm-dock)
|
|
143
|
+
// hover-self → 只有指针落进胶囊自己那一小块才显形(最早的做法)。
|
|
144
|
+
// 两种都只是 opacity:0,仍然占位、仍然收得到指针事件,所以不会跳、也好点。
|
|
141
145
|
'.dshsm-chip[data-mode="hover"]{opacity:0;transition:opacity .12s ease}',
|
|
142
146
|
'.dshsm-dock:hover .dshsm-chip[data-mode="hover"]{opacity:1}',
|
|
147
|
+
'.dshsm-chip[data-mode="hover-self"]{opacity:0;transition:opacity .12s ease}',
|
|
148
|
+
'.dshsm-chip[data-mode="hover-self"]:hover,.dshsm-chip[data-mode="hover-self"]:focus-visible{opacity:1}',
|
|
143
149
|
'.dshsm-dock--hidden{justify-content:flex-end}',
|
|
144
150
|
// 皮肤插件(@linxin666/dsh-client-ui-skin-center)把 input.dock 的每个直接子元素都当
|
|
145
151
|
// 「小配件」刷底板:
|
|
@@ -274,11 +280,12 @@ window.__ModuleLoader__.load({
|
|
|
274
280
|
noteReleaseRetries: '(释放重试 {n} 次)',
|
|
275
281
|
noteSampled: '(大会话:抽样校验)',
|
|
276
282
|
childrenSettingTitle: '连同子对话一起移动',
|
|
277
|
-
childrenSettingDesc: '
|
|
283
|
+
childrenSettingDesc: '默认开。移动父对话时,它的子会话一起搬到目标工作区;关掉后只搬父对话。',
|
|
278
284
|
chipModeTitle: '工作区 chip 什么时候出现',
|
|
279
|
-
chipModeDesc: '
|
|
285
|
+
chipModeDesc: '「一直出现」常驻在输入框上方;「悬浮在那一行才出现」鼠标移到整行才显示;「只悬浮胶囊才出现」鼠标要正好落在胶囊那一小块;两者都保留占位,不会跳。「不出现」完全不渲染。',
|
|
280
286
|
chipModeAlways: '一直出现',
|
|
281
|
-
chipModeHover: '
|
|
287
|
+
chipModeHover: '悬浮在那一行才出现',
|
|
288
|
+
chipModeHoverSelf: '只悬浮胶囊才出现',
|
|
282
289
|
chipModeNever: '不出现',
|
|
283
290
|
starPrompt: '顺手留颗 Star,作者能高兴一整天',
|
|
284
291
|
starCta: '行,给你一颗 Star',
|
|
@@ -329,11 +336,12 @@ window.__ModuleLoader__.load({
|
|
|
329
336
|
noteReleaseRetries: ' (release retried {n}×)',
|
|
330
337
|
noteSampled: ' (large session: sampled verify)',
|
|
331
338
|
childrenSettingTitle: 'Move child conversations too',
|
|
332
|
-
childrenSettingDesc: 'On by default. Moving a conversation also moves its
|
|
339
|
+
childrenSettingDesc: 'On by default. Moving a conversation also moves its child sessions to the target workspace; turn it off to move only the parent conversation.',
|
|
333
340
|
chipModeTitle: 'When to show the workspace chip',
|
|
334
|
-
chipModeDesc: '"Always" keeps it above the composer; "On hover" reveals it when the pointer enters that row
|
|
341
|
+
chipModeDesc: '"Always" keeps it above the composer; "On row hover" reveals it when the pointer enters that row; "Only when hovering the chip" needs the pointer on the chip itself. Both keep their space, so nothing jumps. "Never" hides it.',
|
|
335
342
|
chipModeAlways: 'Always',
|
|
336
|
-
chipModeHover: 'On hover',
|
|
343
|
+
chipModeHover: 'On row hover',
|
|
344
|
+
chipModeHoverSelf: 'Only when hovering the chip',
|
|
337
345
|
chipModeNever: 'Never',
|
|
338
346
|
starPrompt: 'Leave a star — it makes the author’s day',
|
|
339
347
|
starCta: 'Give a star',
|
|
@@ -368,7 +376,9 @@ window.__ModuleLoader__.load({
|
|
|
368
376
|
|
|
369
377
|
// ── 工作区 chip 的出现方式:一直出现 / 悬浮才出现 / 不出现 ────────────────
|
|
370
378
|
var CHIP_MODE_KEY = 'dsh-session-relocate.chipMode';
|
|
371
|
-
|
|
379
|
+
// always = 常驻;hover = 整行悬浮显形;hover-self = 只悬浮胶囊那一小块才显形;
|
|
380
|
+
// never = 完全不渲染。(和预设工作台的四种模式同名同义)
|
|
381
|
+
var CHIP_MODES = ['always', 'hover', 'hover-self', 'never'];
|
|
372
382
|
var chipModeListeners = [];
|
|
373
383
|
|
|
374
384
|
function chipMode() {
|
|
@@ -443,6 +453,7 @@ window.__ModuleLoader__.load({
|
|
|
443
453
|
react.createElement('div', { className: 'dshsm-seg', key: 'seg' }, [
|
|
444
454
|
modeButton('always', strings.chipModeAlways),
|
|
445
455
|
modeButton('hover', strings.chipModeHover),
|
|
456
|
+
modeButton('hover-self', strings.chipModeHoverSelf),
|
|
446
457
|
modeButton('never', strings.chipModeNever),
|
|
447
458
|
]),
|
|
448
459
|
]),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-session-relocate",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.5",
|
|
4
4
|
"description": "跨工作区移动 DSH 对话:把某个 Session 的日志文件与工作区归属整体搬到另一个工作区(可自动注册新工作区)。带日志级崩溃恢复的安全事务,并且会先安全释放「已打开但空闲」的会话 —— 所以正在打开的对话也能直接搬,不需要重启 DSH。",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "src/plugin.js",
|