@mars-sea/dsh-commandcode-provider 0.6.2 → 0.7.1

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
@@ -4,6 +4,26 @@ All notable changes to this project will be documented in this file.
4
4
 
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [0.7.1] - 2026-08-22
8
+
9
+ ### Fixed
10
+
11
+ - **The active-account dropdown now aligns with the other settings fields.** The browser draws native `<select>` controls with its own box model and internal text metrics, so the picker under "Active account" rendered two pixels shorter than every input on the page, with its value sitting at a slightly different height. It now matches the inputs exactly (same height, same text position) and carries a custom chevron that stays legible in both themes.
12
+ - **The usage card's two timestamps share one line.** The billing period end ("Period ends …") and the fetch time ("Updated …") used to occupy two stacked rows; the fetch time now sits on the same row, pushed to the right edge, so the account card ends one line shorter.
13
+ - **README: the documented update command is now `dsh plugin --profile web update @mars-sea/dsh-commandcode-provider@latest`** (the `plugin` command forwards to pnpm, whose `update` verb is what refreshes an installed plugin).
14
+
15
+ ## [0.7.0] - 2026-08-22
16
+
17
+ ### Added
18
+
19
+ - **New model: DeepSeek V4 Flash Vision (exp) (`deepseek/deepseek-v4-flash-vision-exp`, command-code@1.32.0).** An experimental Go-tier vision reasoning model with a 1M context: it appears in the picker under the Go tier with `Image` · `1M` markers, is whitelisted as vision-capable, offers `high`/`max` effort levels, and shares V4 Flash's peak/off-peak hourly pricing — the picker's `Peak`/`Half` marker reflects the current UTC hour.
20
+
21
+ ### Changed
22
+
23
+ - **Ox Alpha now has selectable reasoning-effort levels** (`low` / `high` / `max`, command-code@1.32.1) — the picker offers an effort selector for it instead of letting Command Code choose the depth silently. It accordingly left the auto-thinking set.
24
+ - **Synced with the official command-code@1.32.1 CLI** (upstream moved 1.31.0 → 1.32.0 → 1.32.1; both releases only added model capabilities and touch nothing in the Provider API). `COMMAND_CODE_CLI_VERSION` is now `1.32.1`. Re-verified against the official sources with no other changes: wire protocol, endpoints, auth flow, subscription plan maps, deals, and peak windows are identical; plan tiers gained only the new Vision model above.
25
+ - **The remaining network and timeout errors are now bilingual (English + 中文).** The connect timeout, connection failure, mid-stream drop, stream idle watchdog, and empty-response errors — the ones that repeat in the retry chrome during transient network trouble — now carry both readings in one string, each with an actionable hint (check the network/proxy; long-thinking models can raise the stream idle timeout). Like the 0.6.2 credential and rate-limit messages, the English reading leads and the Chinese reading follows.
26
+
7
27
  ## [0.6.2] - 2026-08-21
8
28
 
9
29
  ### Added
package/README.md CHANGED
@@ -36,7 +36,7 @@ dsh plugin --profile web add @mars-sea/dsh-commandcode-provider@latest
36
36
  ## Updating
37
37
 
38
38
  ```sh
39
- dsh plugin --profile web add @mars-sea/dsh-commandcode-provider@latest
39
+ dsh plugin --profile web update @mars-sea/dsh-commandcode-provider@latest
40
40
  ```
41
41
 
42
42
  Then restart the web app.
@@ -50,7 +50,7 @@ npm i -g command-code@latest
50
50
  cmd login # macOS/Linux; native Windows: cmdc login
51
51
  ```
52
52
 
53
- Alternatively, create a key in the browser ([Command Code Studio](https://commandcode.ai/studio/auth/cli)) and paste it into **Settings → Command Code**, or `export COMMANDCODE_API_KEY="user_..."`.
53
+ Alternatively, create a key on the [Keys settings page](https://commandcode.ai/mars-sea/settings/keys) and paste it into **Settings → Command Code**, or `export COMMANDCODE_API_KEY="user_..."`.
54
54
 
55
55
  ## Verify it works
56
56
 
@@ -155,11 +155,11 @@ MIT — see [LICENSE](./LICENSE). Portions ported from [pi-commandcode-provider]
155
155
 
156
156
  **Model picker** — plan tier, deal/FREE, peak/off-peak, Image and context annotations:
157
157
 
158
- <img src="assets/screenshots/model-picker.png" alt="Model picker with plan, deal, image and context annotations" width="420">
158
+ <img src="assets/screenshots/model-picker.png" alt="Model picker with plan, deal, image and context annotations" width="320">
159
159
 
160
160
  **Usage dashboard** — `/commandcode` per-account report:
161
161
 
162
- ![Usage dashboard](assets/screenshots/usage-dashboard.png)
162
+ <img src="assets/screenshots/usage-dashboard.png" alt="Usage dashboard" width="520">
163
163
 
164
164
  **Settings page** — API key, connection knobs, account rotation and the live account-usage card:
165
165
 
package/README.zh-CN.md CHANGED
@@ -34,7 +34,7 @@ dsh plugin --profile web add @mars-sea/dsh-commandcode-provider@latest
34
34
  ## 更新
35
35
 
36
36
  ```sh
37
- dsh plugin --profile web add @mars-sea/dsh-commandcode-provider@latest
37
+ dsh plugin --profile web update @mars-sea/dsh-commandcode-provider@latest
38
38
  ```
39
39
 
40
40
  然后重启 Web 应用。
@@ -48,7 +48,7 @@ npm i -g command-code@latest
48
48
  cmd login # macOS/Linux;Windows 原生版:cmdc login
49
49
  ```
50
50
 
51
- 也可以在 [Command Code Studio](https://commandcode.ai/studio/auth/cli) 创建 key 后粘贴到 **设置 → Command Code**,或 `export COMMANDCODE_API_KEY="user_..."`。
51
+ 也可以在 [Keys 设置页](https://commandcode.ai/mars-sea/settings/keys) 创建 key 后粘贴到 **设置 → Command Code**,或 `export COMMANDCODE_API_KEY="user_..."`。
52
52
 
53
53
  ## 验证是否生效
54
54
 
@@ -153,11 +153,11 @@ MIT —— 见 [LICENSE](./LICENSE)。部分内容移植自 [pi-commandcode-prov
153
153
 
154
154
  **模型选择器** —— 套餐档位、折扣/FREE、峰谷时段、Image 与上下文标注:
155
155
 
156
- <img src="assets/screenshots/model-picker.png" alt="带套餐、折扣、图片与上下文标注的模型选择器" width="420">
156
+ <img src="assets/screenshots/model-picker.png" alt="带套餐、折扣、图片与上下文标注的模型选择器" width="320">
157
157
 
158
158
  **用量面板** —— `/commandcode` 的分账户报告:
159
159
 
160
- ![用量面板](assets/screenshots/usage-dashboard.png)
160
+ <img src="assets/screenshots/usage-dashboard.png" alt="用量面板" width="520">
161
161
 
162
162
  **设置页** —— API 密钥、连接参数、多账户轮换与实时账户用量卡片:
163
163
 
package/lib/client.js CHANGED
@@ -902,7 +902,7 @@ window.__ModuleLoader__.load({
902
902
  * @module dsh-commandcode-provider/client/version
903
903
  */
904
904
  /** The published package version (e.g. `'0.6.0'`). */
905
- const PLUGIN_VERSION = "0.6.2";
905
+ const PLUGIN_VERSION = "0.7.1";
906
906
  //#endregion
907
907
  //#region src/client/section.tsx
908
908
  /**
@@ -1168,7 +1168,7 @@ window.__ModuleLoader__.load({
1168
1168
  * One pool account's facts (identity, totals, credits, window limits)
1169
1169
  * rendered inside the account-usage card.
1170
1170
  */
1171
- function AccountReport({ entry, t, onRemove }) {
1171
+ function AccountReport({ entry, fetchedAt, t, onRemove }) {
1172
1172
  const report = entry.report;
1173
1173
  const account = report.account;
1174
1174
  const accountName = account === void 0 ? "" : account.userName || account.name;
@@ -1176,6 +1176,8 @@ window.__ModuleLoader__.load({
1176
1176
  const plan = report.plan;
1177
1177
  const planName = plan?.name ?? "";
1178
1178
  const planStatus = plan !== void 0 && plan.status !== "" && plan.status !== "active" ? plan.status : "";
1179
+ const showPeriod = plan !== void 0 && plan.currentPeriodEnd > 0;
1180
+ const showPartial = report.failures.length > 0 && report.blocked === void 0;
1179
1181
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1180
1182
  className: "cc-accountReport",
1181
1183
  children: [
@@ -1279,31 +1281,32 @@ window.__ModuleLoader__.load({
1279
1281
  t
1280
1282
  })]
1281
1283
  }) : null,
1282
- plan !== void 0 && plan.currentPeriodEnd > 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1284
+ showPeriod || showPartial || fetchedAt !== void 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1283
1285
  className: "cc-usageMeta",
1284
1286
  children: [
1285
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("p", {
1287
+ showPeriod ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("p", {
1286
1288
  className: "cc-usageUpdated",
1287
1289
  children: [
1288
1290
  t("usagePeriodEnd"),
1289
1291
  " ",
1290
1292
  new Date(plan.currentPeriodEnd).toLocaleDateString()
1291
1293
  ]
1292
- }),
1293
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { className: "cc-usageMetaSpacer" }),
1294
- report.failures.length > 0 && report.blocked === void 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
1294
+ }) : null,
1295
+ showPartial ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
1295
1296
  className: "cc-usagePartial",
1296
1297
  title: report.failures.join("; "),
1297
1298
  children: t("usagePartial")
1299
+ }) : null,
1300
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { className: "cc-usageMetaSpacer" }),
1301
+ fetchedAt !== void 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("p", {
1302
+ className: "cc-usageUpdated",
1303
+ children: [
1304
+ t("usageUpdated"),
1305
+ " ",
1306
+ new Date(fetchedAt).toLocaleTimeString()
1307
+ ]
1298
1308
  }) : null
1299
1309
  ]
1300
- }) : report.failures.length > 0 && report.blocked === void 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1301
- className: "cc-usageMeta",
1302
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { className: "cc-usageMetaSpacer" }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
1303
- className: "cc-usagePartial",
1304
- title: report.failures.join("; "),
1305
- children: t("usagePartial")
1306
- })]
1307
1310
  }) : null
1308
1311
  ]
1309
1312
  });
@@ -1412,20 +1415,10 @@ window.__ModuleLoader__.load({
1412
1415
  }) : null,
1413
1416
  selected !== void 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(AccountReport, {
1414
1417
  entry: selected,
1418
+ fetchedAt: usage.fetchedAt,
1415
1419
  t,
1416
1420
  onRemove: removeSelected
1417
- }, selected.id) : null,
1418
- report !== void 0 && usage.fetchedAt !== void 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1419
- className: "cc-usageMeta",
1420
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { className: "cc-usageMetaSpacer" }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("p", {
1421
- className: "cc-usageUpdated",
1422
- children: [
1423
- t("usageUpdated"),
1424
- " ",
1425
- new Date(usage.fetchedAt).toLocaleTimeString()
1426
- ]
1427
- })]
1428
- }) : null
1421
+ }, selected.id) : null
1429
1422
  ]
1430
1423
  });
1431
1424
  }
@@ -1973,6 +1966,13 @@ window.__ModuleLoader__.load({
1973
1966
  .cc-input{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-1);height:34px;font:inherit;color:var(--dsw-alias-label-primary);border-radius:8px;padding:0 12px;font-size:13px;line-height:1.5}
1974
1967
  .cc-input:focus-visible{border-color:var(--dsw-alias-brand-primary);outline:none}
1975
1968
  .cc-input:disabled{color:var(--dsw-alias-label-tertiary);cursor:default}
1969
+ /* Selects need their own treatment to sit flush with the text inputs:
1970
+ * the UA stylesheet renders <select> border-box (34px total vs the inputs'
1971
+ * 36px) and forces its own menulist text metrics, so drop the native
1972
+ * chrome entirely (appearance:none), restore content-box so the outer box
1973
+ * matches the inputs again, and draw the chevron ourselves. Longhand
1974
+ * background-* only — the shorthand would reset .cc-input's background. */
1975
+ select.cc-input{appearance:none;-webkit-appearance:none;-moz-appearance:none;box-sizing:content-box;padding-right:32px;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='7' viewBox='0 0 12 7'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23888f98' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 11px center}
1976
1976
  .cc-inputInvalid{border-color:var(--dsw-alias-label-error)}
1977
1977
  .cc-invalid{color:var(--dsw-alias-label-error);margin:0;font-size:12px;line-height:1.5}
1978
1978
  .cc-hint{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:1.5}