dsh-fonttune 0.1.5 → 0.1.6
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.en.md +5 -0
- package/CHANGELOG.md +5 -0
- package/README.en.md +1 -1
- package/README.md +1 -1
- package/lib/client.js +36 -4
- package/package.json +1 -1
package/CHANGELOG.en.md
CHANGED
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to **dsh-fonttune** are documented here. Chinese version: [CHANGELOG.md](CHANGELOG.md).
|
|
4
4
|
|
|
5
|
+
## [0.1.6] - 2026-09-15
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
- **The configuration card's expand/collapse chevron matches the host now**: it used to be the text character `⌄`, rendered at text weight so it looked **thinner** than every other card's arrow, and the rotation sat on the text line box — the glyph's ink is off-centre inside that box (it rides the baseline), so `rotate(180deg)` swung the character sideways instead of turning it around its own centre. The chevron is now the host PluginCard's own 14×14 inline SVG (path extracted byte for byte from DSH's frontend bundle, same fix dsh-quick-toc shipped in 0.6.3); the rotation class goes on the `<svg>` itself, so it turns around the icon's own centre. Verified in a real browser: byte-identical path to the 11 host-rendered chevrons on the same page, same 14×14 size.
|
|
9
|
+
|
|
5
10
|
## [0.1.5] - 2026-09-15
|
|
6
11
|
|
|
7
12
|
### Added
|
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
**dsh-fonttune** 的重要变更都记录在这里。英文版见 [CHANGELOG.en.md](CHANGELOG.en.md)。
|
|
4
4
|
|
|
5
|
+
## [0.1.6] - 2026-09-15
|
|
6
|
+
|
|
7
|
+
### 修复
|
|
8
|
+
- **配置卡片的展开/收起箭头与宿主不一致**:原为文本字符 `⌄`——按文字字重渲染,比宿主其它卡片的箭头**更细**;且旋转写在文本行盒上,字符墨迹在行盒内不居中(落在基线上),`rotate(180deg)` 绕盒心转时字符被甩开,看起来「不是以自己为中心转」。现改为宿主 PluginCard 同款 14×14 内联 SVG(path 从 DSH 前端 bundle 逐字节提取,与 dsh-quick-toc 0.6.3 的修法同构);旋转类挂在 `<svg>` 本体上,绕图标自身中心转。真机验证:与同页 11 个宿主自家箭头 path **逐字节一致**,尺寸同为 14×14。
|
|
9
|
+
|
|
5
10
|
## [0.1.5] - 2026-09-15
|
|
6
11
|
|
|
7
12
|
### 新增
|
package/README.en.md
CHANGED
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
|
|
21
21
|
| Plugin version | Supported DSH versions |
|
|
22
22
|
| --- | --- |
|
|
23
|
-
| **0.1.
|
|
23
|
+
| **0.1.6** (latest) | 0.1.5-rc.2 |
|
|
24
24
|
|
|
25
25
|
`engines.dsh` requires **0.1.5-rc.2** or newer, and the compatibility declaration lists only the **latest release of the 0.1.5 line**: it carries every fix in that line, which makes it the most stable build of the major version, while older builds of the same major version stay compatible per semantic versioning. Earlier or newer DSH versions are untested and not declared. On install or update, the DSH market runs a host-compatibility preflight against `engines.dsh`, `dsh.compatibility.dshReleases` and `peerDependencies` in `package.json`.
|
|
26
26
|
|
package/README.md
CHANGED
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
|
|
21
21
|
| 插件版本 | 支持的 DSH 版本 |
|
|
22
22
|
| --- | --- |
|
|
23
|
-
| **0.1.
|
|
23
|
+
| **0.1.6**(最新) | 0.1.5-rc.2 |
|
|
24
24
|
|
|
25
25
|
`engines.dsh` 下限为 **0.1.5-rc.2**,兼容声明只列 **0.1.5 线的最新版本**:它包含这条线的全部修复,是同一大版本里最稳的一版,而同一大版本内的旧版本按语义化版本约定向上兼容。更早或更新的 DSH 未经验证,不作声明。安装或更新时,DSH 市场会依据 `package.json` 里的 `engines.dsh`、`dsh.compatibility.dshReleases` 与 `peerDependencies` 做宿主兼容预检。
|
|
26
26
|
|
package/lib/client.js
CHANGED
|
@@ -996,6 +996,24 @@ var NEUTRAL_WEIGHT = 400;
|
|
|
996
996
|
/** Panel width, kept in one place because positioning reads it too. */
|
|
997
997
|
var PANEL_WIDTH = 320;
|
|
998
998
|
|
|
999
|
+
/**
|
|
1000
|
+
* The host PluginCard's chevron, copied byte for byte from DSH's own frontend
|
|
1001
|
+
* bundle (dsh-quick-toc extracted it first and verified the match on the page;
|
|
1002
|
+
* their copy is archived in Temp\dqt-chevron-path.txt). A `⌄` character is the
|
|
1003
|
+
* wrong icon twice over: at text weight it is thinner than every other card's
|
|
1004
|
+
* arrow, and rotating the text span turns it around the text box centre — the
|
|
1005
|
+
* glyph sits off-centre on its baseline — so the rotation swings it sideways.
|
|
1006
|
+
* An `<svg>` rotates around its own box centre.
|
|
1007
|
+
*/
|
|
1008
|
+
var CHEVRON_PATH =
|
|
1009
|
+
"M11.8486 5.5L11.4238 5.92383L8.69727 8.65137C8.44157 8.90706 8.21562 9.13382 8.01172 9.29785" +
|
|
1010
|
+
"C7.79912 9.46883 7.55595 9.61756 7.25 9.66602C7.08435 9.69222 6.91565 9.69222 6.75 9.66602" +
|
|
1011
|
+
"C6.44405 9.61756 6.20088 9.46883 5.98828 9.29785C5.78438 9.13382 5.55843 8.90706 5.30273 8.65137" +
|
|
1012
|
+
"L2.57617 5.92383L2.15137 5.5L3 4.65137L3.42383 5.07617L6.15137 7.80273C6.42595 8.07732 6.59876 8.24849 6.74023 8.3623" +
|
|
1013
|
+
"C6.87291 8.46904 6.92272 8.47813 6.9375 8.48047C6.97895 8.48703 7.02105 8.48703 7.0625 8.48047" +
|
|
1014
|
+
"C7.07728 8.47813 7.12709 8.46904 7.25977 8.3623C7.40124 8.24849 7.57405 8.07732 7.84863 7.80273" +
|
|
1015
|
+
"L10.5762 5.07617L11 4.65137L11.8486 5.5Z";
|
|
1016
|
+
|
|
999
1017
|
/** Panel height cap, used to decide whether it opens up or down. */
|
|
1000
1018
|
var PANEL_HEIGHT = 380;
|
|
1001
1019
|
|
|
@@ -1207,7 +1225,14 @@ var CARD_CSS = [
|
|
|
1207
1225
|
".dfp-headText{flex-direction:column;flex:1;gap:4px;min-width:0;display:flex}",
|
|
1208
1226
|
".dfp-name{color:var(--dsw-alias-label-primary);font-size:15px;font-weight:600;line-height:1.4}",
|
|
1209
1227
|
".dfp-description{color:var(--dsw-alias-label-tertiary);font-size:13px;line-height:1.5}",
|
|
1210
|
-
|
|
1228
|
+
// The chevron is the host PluginCard's own 14×14 SVG icon, not a text glyph:
|
|
1229
|
+
// a `⌄` character rendered at text weight looked thinner than every other
|
|
1230
|
+
// card's arrow, and rotating the TEXT SPAN swung it around the text box
|
|
1231
|
+
// centre (the glyph sits off-centre on its baseline) instead of turning in
|
|
1232
|
+
// place. As an `<svg>` the class goes on the icon itself and
|
|
1233
|
+
// `transform:rotate(180deg)` rotates around the icon's own box centre —
|
|
1234
|
+
// exactly what dsh-quick-toc's card does.
|
|
1235
|
+
".dfp-chevron{color:var(--dsw-alias-label-tertiary);flex:none;display:block;transition:transform .16s}",
|
|
1211
1236
|
".dfp-chevronOpen{transform:rotate(180deg)}",
|
|
1212
1237
|
".dfp-body{border-top:.5px solid var(--dsw-alias-border-l2);margin:0 16px;padding-bottom:8px}",
|
|
1213
1238
|
".dfp-readOnly{color:var(--dsw-alias-label-tertiary);margin:12px 0 0;font-size:12px;line-height:1.5}",
|
|
@@ -2452,9 +2477,16 @@ function FontCard(props) {
|
|
|
2452
2477
|
h("span", { className: "dfp-description" }, t("card.description"))
|
|
2453
2478
|
),
|
|
2454
2479
|
h(
|
|
2455
|
-
"
|
|
2456
|
-
{
|
|
2457
|
-
|
|
2480
|
+
"svg",
|
|
2481
|
+
{
|
|
2482
|
+
className: "dfp-chevron" + (open ? " dfp-chevronOpen" : ""),
|
|
2483
|
+
width: 14,
|
|
2484
|
+
height: 14,
|
|
2485
|
+
viewBox: "0 0 14 14",
|
|
2486
|
+
fill: "none",
|
|
2487
|
+
"aria-hidden": "true",
|
|
2488
|
+
},
|
|
2489
|
+
h("path", { d: CHEVRON_PATH, fill: "currentColor" })
|
|
2458
2490
|
)
|
|
2459
2491
|
),
|
|
2460
2492
|
open
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-fonttune",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.6",
|
|
4
4
|
"description": "Font plugin for the DeepSeek Harness Web GUI: body and code font families, a separate font size and weight for each, and a West/CJK split picker.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "lib/index.js",
|