dsh-browser-cdp 1.9.6 → 1.9.8

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 CHANGED
@@ -1,3 +1,25 @@
1
+ ## 1.9.8 (2026-11-10)
2
+
3
+ **登录/验证横幅:说明文字按比例收缩,不截断、不隐藏。**
4
+
5
+ - 撤回 1.9.7 的“超长省略 + 窄宽度隐藏 note”做法;`loginSelfPersist` 恢复完整文案(中/英)。
6
+ - 比例:主文案 `flex: 2 1 11~12em`,说明 `flex: 1 1 9~10em`,两边都 `min-width: 0` + `white-space: normal` + `overflow-wrap: anywhere` → 两者按 2:1 分享行宽,放不下就各自换行,绝不出 1 字一列、也不省略。
7
+ - `@container (max-width: 260px)` 只保留“隐藏 captcha kind 胶囊”这一项装饰降级。
8
+ - **测试**:1021 passed / 13 skipped(纯样式)。
9
+
10
+ ## 1.9.7 (2026-11-10)
11
+
12
+ **窄宽度下登录/验证横幅不再被挤成一列字。**
13
+
14
+ - **根因**:横幅是单行 flex,右侧 `note`(“登录态由该浏览器自身保存”)写了 `flex: none; white-space: nowrap`,不收缩;窄侧栏下它把主文案的可用宽压到 ~1 字,就变成竖排一列。
15
+ - **修法(两处横幅同步)**:
16
+ - 容器 `flex-wrap: wrap; row-gap` → 放不下时按钮/note 换行,而不是挤压正文;
17
+ - 正文 `flex: 1 1 11~12em; min-width: 0; overflow-wrap: anywhere`;
18
+ - `note` 改 `flex: 0 1 auto; min-width: 0; max-width: 100%; overflow: hidden; text-overflow: ellipsis`(超长就省略);
19
+ - 横幅设为 `container-type: inline-size`,`@container (max-width: 260px)` 时直接隐藏 `note` 与 captcha 的 kind 胶囊。
20
+ - **文案缩短**:`loginSelfPersist` 改为“登录态由该浏览器自身保存” / “Saved by the browser profile itself.”。
21
+ - **测试**:1021 passed / 13 skipped(纯样式改动)。
22
+
1
23
  ## 1.9.6 (2026-11-10)
2
24
 
3
25
  **修掉两次捕获之间的画面缺口(1s 缓冲重播导致的重渲染回退)。**
package/dsh-plugin.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://dsh.community/schemas/dsh-plugin-0.15.json",
3
3
  "id": "dsh-browser-cdp",
4
4
  "name": "dsh-browser-cdp",
5
- "version": "1.9.6",
5
+ "version": "1.9.8",
6
6
  "manifestVersion": "0.15",
7
7
  "facets": {
8
8
  "host": {
package/lib/client.js CHANGED
@@ -1258,15 +1258,20 @@ const PANEL_CSS = `
1258
1258
 
1259
1259
  /* ---- login guide strip (top of the panel body) ---- */
1260
1260
  #dsh-ego-login { display:none; align-items:center; gap:8px; margin:0 14px 9px; padding:7px 10px;
1261
- border-radius:9px; border:1px solid rgba(255,214,10,.28); background: rgba(255,214,10,.09); }
1261
+ border-radius:9px; border:1px solid rgba(255,214,10,.28); background: rgba(255,214,10,.09);
1262
+ /* Narrow panel: let the action row fall to its own line instead of squeezing
1263
+ the sentence into a one-character column. */
1264
+ flex-wrap: wrap; row-gap:6px; container-type: inline-size; }
1262
1265
  #dsh-ego-login.show { display:flex; }
1263
- #dsh-ego-login .dsh-ego-login-txt { flex:1; min-width:0; font-size:11px; line-height:1.45; color:#f5f5f7; }
1266
+ #dsh-ego-login .dsh-ego-login-txt { flex:2 1 12em; min-width:0; font-size:11px; line-height:1.45; color:#f5f5f7;
1267
+ overflow-wrap: anywhere; }
1264
1268
  #dsh-ego-login .dsh-ego-login-txt b { color:#ffd60a; }
1265
1269
  #dsh-ego-login .dsh-ego-login-btn { flex:none; background:#0a84ff; color:#fff; border:none; border-radius:8px;
1266
1270
  font-size:11px; padding:4px 10px; cursor:pointer; white-space:nowrap; transition: background .15s ease; }
1267
1271
  #dsh-ego-login .dsh-ego-login-btn:hover { background:#338cff; }
1268
1272
  #dsh-ego-login .dsh-ego-login-btn.saving { opacity:.55; pointer-events:none; }
1269
- #dsh-ego-login .dsh-ego-login-note { flex:none; font-size:10.5px; color:#6e6e73; white-space:nowrap; }
1273
+ #dsh-ego-login .dsh-ego-login-note { flex:1 1 10em; min-width:0; max-width:100%; font-size:10.5px; color:#6e6e73;
1274
+ white-space:normal; overflow-wrap:anywhere; }
1270
1275
  /* dismiss (×) on guide strips so the user can close them and reclaim the space */
1271
1276
  .dsh-ego-dismiss { flex:none; width:18px; height:18px; line-height:1; border-radius:50%; border:none;
1272
1277
  background: rgba(255,255,255,.12); color:inherit; font-size:13px; cursor:pointer; opacity:.75;
@@ -1277,9 +1282,16 @@ const PANEL_CSS = `
1277
1282
 
1278
1283
  /* ---- human-verification (CAPTCHA) reminder strip ---- */
1279
1284
  #dsh-ego-captcha { display:none; align-items:center; gap:8px; margin:0 14px 9px; padding:8px 11px;
1280
- border-radius:9px; border:1px solid rgba(255,69,58,.4); background: rgba(255,69,58,.13); color:#ffe1de; }
1285
+ border-radius:9px; border:1px solid rgba(255,69,58,.4); background: rgba(255,69,58,.13); color:#ffe1de;
1286
+ flex-wrap: wrap; row-gap:6px; container-type: inline-size; }
1287
+ @container (max-width: 260px) {
1288
+ /* The kind pill is pure decoration — it is the only thing that steps aside.
1289
+ Text never truncates or hides: both lines shrink proportionally and wrap. */
1290
+ #dsh-ego-captcha .dsh-ego-captcha-kind { display:none; }
1291
+ }
1281
1292
  #dsh-ego-captcha.show { display:flex; }
1282
- #dsh-ego-captcha .dsh-ego-captcha-txt { flex:1; min-width:0; font-size:11.5px; line-height:1.5; }
1293
+ #dsh-ego-captcha .dsh-ego-captcha-txt { flex:2 1 12em; min-width:0; font-size:11.5px; line-height:1.5;
1294
+ overflow-wrap: anywhere; }
1283
1295
  #dsh-ego-captcha .dsh-ego-captcha-txt b { color:#ff6961; }
1284
1296
  #dsh-ego-captcha .dsh-ego-captcha-kind { flex:none; font-size:10px; padding:2px 8px; border-radius:999px;
1285
1297
  background: rgba(255,255,255,.12); color:#ffd8d5; text-transform:uppercase; letter-spacing:.4px; }
@@ -4204,6 +4216,16 @@ var TAB_CSS = `
4204
4216
  .dsh-ego-side-login, .dsh-ego-side-captcha {
4205
4217
  display: flex; align-items: center; gap: 7px; margin: 0 10px 7px; padding: 6px 9px;
4206
4218
  border-radius: 8px; font-size: 11px; line-height: 1.4;
4219
+ /* Narrow sidebar: wrap instead of squeezing the sentence to one character. */
4220
+ flex-wrap: wrap; row-gap: 5px;
4221
+ /* The strip is a query container so the secondary bits can step aside when the
4222
+ sidebar gets too narrow for them (see @container below). */
4223
+ container-type: inline-size;
4224
+ }
4225
+ @container (max-width: 260px) {
4226
+ /* Decoration only: the captcha kind pill steps aside. Every text line keeps
4227
+ rendering — it just shrinks proportionally and wraps. */
4228
+ .dsh-ego-side-captcha-kind { display: none; }
4207
4229
  }
4208
4230
  .dsh-ego-side-login {
4209
4231
  border: 1px solid rgba(255,214,10,.3); background: rgba(255,214,10,.1);
@@ -4211,7 +4233,7 @@ var TAB_CSS = `
4211
4233
  .dsh-ego-side-captcha {
4212
4234
  border: 1px solid rgba(255,69,58,.4); background: rgba(255,69,58,.13);
4213
4235
  }
4214
- .dsh-ego-side-login .dsh-ego-side-login-txt { flex: 1; min-width: 0; }
4236
+ .dsh-ego-side-login .dsh-ego-side-login-txt { flex: 2 1 11em; min-width: 0; overflow-wrap: anywhere; }
4215
4237
  .dsh-ego-side-login .dsh-ego-side-login-txt b { color: #ffd60a; }
4216
4238
  .dsh-ego-side-login-btn {
4217
4239
  flex: none; background: #0a84ff; color: #fff; border: none; border-radius: 7px;
@@ -4220,8 +4242,9 @@ var TAB_CSS = `
4220
4242
  }
4221
4243
  .dsh-ego-side-login-btn:hover { background: #338cff; }
4222
4244
  .dsh-ego-side-login-btn.saving { opacity: .55; pointer-events: none; }
4223
- .dsh-ego-side-login-note { flex: none; font-size: 10px; opacity: .6; white-space: nowrap; }
4224
- .dsh-ego-side-captcha-txt { flex: 1; min-width: 0; }
4245
+ .dsh-ego-side-login-note { flex: 1 1 9em; min-width: 0; max-width: 100%; font-size: 10px; opacity: .6;
4246
+ white-space: normal; overflow-wrap: anywhere; }
4247
+ .dsh-ego-side-captcha-txt { flex: 2 1 11em; min-width: 0; overflow-wrap: anywhere; }
4225
4248
  .dsh-ego-side-captcha-txt b { color: #ff6961; }
4226
4249
  .dsh-ego-side-captcha-kind {
4227
4250
  flex: none; font-size: 9.5px; padding: 2px 7px; border-radius: 999px;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-browser-cdp",
3
- "version": "1.9.6",
3
+ "version": "1.9.8",
4
4
  "description": "dsh-browser-cdp: visible agent browser for DSH — drives the vendored ego-compatible Chromium over CDP, and can also attach to a running Chrome/Edge/Brave or route through egolite, Tabbit and Lightpanda backends. 35 structured bcdp_* tools; only bcdp_status stays resident by default (lazy injection, −91.9% schema per turn for non-browser sessions). Realtime watch panel with direct click/scroll/IME input, element picks quoted into the composer, human-verification notices; non-CDP channels sync frames by 3s polling. Web shell: floating watch ball without dsh-better-sidebar, sidebar tab with it. Headless/TUI hosts: tools-only. [DSH 0.1.7-rc.1 ~ 0.2.2-rc.1 (exact rc enumeration): declarative settings via Config .volatile() fields; for DSH 0.1.2-rc.1 ~ 0.1.5-rc.3 use the 0.17.x line]",
5
5
  "type": "module",
6
6
  "main": "./lib/index.js",