@dsh-workbench/module-tools 1.2.8-beta.1 → 1.2.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dsh-workbench/module-tools",
3
- "version": "1.2.8-beta.1",
3
+ "version": "1.2.8",
4
4
  "description": "模块包的构建与门禁工具:build(单文件 ESM 宿主侧 + 套 loader 壳的浏览器侧)、check(契约/产物边界/源码边界/卡片渲染)。模块包不再各带一份构建脚本。",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -33,7 +33,7 @@
33
33
  "semver": "^7.8.5",
34
34
  "typescript": "5.9.3",
35
35
  "typescript-eslint": "^8.71.0",
36
- "@dsh-workbench/shared": "1.2.8-beta.1"
36
+ "@dsh-workbench/shared": "1.2.8"
37
37
  },
38
38
  "repository": {
39
39
  "type": "git",
package/src/design.mjs CHANGED
@@ -466,14 +466,15 @@ export function renderUserReadme(source) {
466
466
  ? '在市场「已安装」里装或卸。装完在当前项目的面板里勾选这个模块,卡片才会出现;卸掉后卡片消失。'
467
467
  : source?.install;
468
468
  const shots = shotsOf(source);
469
+ const shotsHeading = text(source?.shotsTitle) || '长这样';
469
470
  const shotLines = shots.length === 0
470
471
  ? []
471
472
  : [
472
- '## 卡片长这样',
473
+ `## ${shotsHeading}`,
473
474
  '',
474
475
  ...shots.flatMap((one) => [
475
476
  ...(one.caption === '' ? [] : [`**${one.caption}**`, '']),
476
- '```text',
477
+ '```',
477
478
  one.drawing,
478
479
  '```',
479
480
  '',
@@ -535,6 +536,7 @@ export function userSourceSkeleton(manifest, design) {
535
536
  return {
536
537
  title: manifestTitleOf(manifest) || text(design?.name) || '模块',
537
538
  summary: text(design?.oneLine) || text(manifest?.description),
539
+ shotsTitle: '',
538
540
  shots: [
539
541
  {
540
542
  caption: '(可选:图注,比如「卡片」「设置面」「审批」)',
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "title": "__UNIT__ 模块",
3
3
  "summary": "__DESC__",
4
+ "shotsTitle": "",
4
5
  "shots": [
5
6
  {
6
7
  "caption": "卡片",