dsh-maoying 0.1.1 → 0.1.3

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 (3) hide show
  1. package/README.md +8 -1
  2. package/lib/base.css +22 -13
  3. package/package.json +6 -1
package/README.md CHANGED
@@ -35,6 +35,13 @@ git clone https://github.com/lifangjin/dsh-maoying.git
35
35
  dsh plugin --profile web add link:"$PWD/dsh-maoying"
36
36
  ```
37
37
 
38
+ 只要命令行工具、不装插件的读者:零依赖 CLI 单独可用,`npx` 即跑,或装成全局命令(均为 npm 通道,与插件互不相干):
39
+
40
+ ```bash
41
+ npx maoying init # 免安装直接跑
42
+ npm install -g dsh-maoying # 或装成全局 maoying 命令
43
+ ```
44
+
38
45
  ## 怎么用
39
46
 
40
47
  选好预设后,对主编说话即可,它按工作流自己路由:
@@ -116,7 +123,7 @@ maoying export novel --format epub --out ~/Downloads # 换输出目录
116
123
 
117
124
  输出目录默认 `<dir>/exports/`,文件名 `<书名>-<YYYYMMDD>.<扩展名>`(书名取 project.yml 的 title);章节解析与 stats/index 同一套逻辑,frontmatter 不会混进正文。
118
125
 
119
- 零依赖(node:fs/path/url/crypto),任意 cwd 可用;npm 全局安装或 `pnpm link` 后可直接 `maoying` 调用,否则 `node <插件目录>/bin/maoying.mjs` 等价。日常写作中 index.yml 由设定管理员直接重建,CLI 主要给人用。
126
+ 零依赖(node:fs/path/url/crypto),任意 cwd 可用。装法三选一:`npm install -g dsh-maoying`、随用随取的 `npx maoying <命令>`、或开发机的 `npm link`(仓库检出即改即生效)。三样都没有时 `node <插件目录>/bin/maoying.mjs` 等价(dsh 插件安装也会把包落进 profile,可直接指过去)。日常写作中 index.yml 由设定管理员直接重建,CLI 主要给人用。
120
127
 
121
128
  ## 卸载
122
129
 
package/lib/base.css CHANGED
@@ -7,22 +7,22 @@
7
7
  /* ── 侧栏底部入口(sidebar.footer.action 键控槽)────────────────────────
8
8
  宽栏 42px 圆角行(图标 + 文案)/ 窄栏 36px 圆钮,观感照设置壳动作条。 */
9
9
  .myt-footerBtn {
10
- display: flex;
10
+ display: inline-flex;
11
11
  align-items: center;
12
12
  gap: 8px;
13
- width: 42px;
13
+ width: calc(100% + 4px);
14
14
  height: 42px;
15
- flex: none;
16
- padding: 0;
15
+ margin: 0 -2px;
16
+ padding: 0 10px 0 8px;
17
17
  box-sizing: border-box;
18
- border: 1px solid transparent;
18
+ border: none;
19
19
  border-radius: 12px;
20
- background: transparent;
21
- color: var(--dsw-alias-label-secondary);
20
+ background: 0 0;
21
+ color: var(--dsw-alias-label-primary);
22
22
  cursor: pointer;
23
- justify-content: center;
24
23
  overflow: hidden;
25
- font: inherit;
24
+ font-family: inherit;
25
+ font-size: 14px;
26
26
  transition: background 0.12s ease, color 0.12s ease;
27
27
  }
28
28
  .myt-footerBtn:hover {
@@ -38,14 +38,23 @@
38
38
  overflow: hidden;
39
39
  white-space: nowrap;
40
40
  text-overflow: ellipsis;
41
- font-size: 12px;
42
- line-height: 16px;
43
- font-weight: 500;
44
41
  }
45
42
  .myt-footerBtn.myt-footerRail {
43
+ border-radius: 50%;
44
+ justify-content: center;
45
+ gap: 0;
46
46
  width: 36px;
47
47
  height: 36px;
48
- border-radius: 50%;
48
+ margin: 8px 0 10px;
49
+ padding: 0;
50
+ }
51
+
52
+ /* 宿主 footerActions 默认横向 flex,多个插件动作会挤成一行;改一行一个。
53
+ 层级:footerActions > div[data-slot="sidebar.footer.action"](SlotOutlet
54
+ 锚点,display: contents 不生成盒)> 各家按钮——flex-direction 必须落在
55
+ 锚点的父容器上。:has() 不支持的老浏览器回落并排,不破坏功能。 */
56
+ div:has(> div[data-slot="sidebar.footer.action"]) {
57
+ flex-direction: column;
49
58
  }
50
59
 
51
60
  /* ── 全页 overlay(data-dsh-maoying-view / html[data-dsh-maoying-active])──
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-maoying",
3
- "version": "0.1.1",
3
+ "version": "0.1.3",
4
4
  "description": "毛颖 — DSH 网文创作辅助插件:主编 + 五帮手编排(大纲/写手/审校/设定/考据),novel/ 结构化文件为数据库",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -57,5 +57,10 @@
57
57
  "@deepseek-ai/dsh-client-connection"
58
58
  ]
59
59
  }
60
+ },
61
+ "peerDependenciesMeta": {
62
+ "@deepseek-ai/dsh": {
63
+ "optional": true
64
+ }
60
65
  }
61
66
  }