reactive-md 0.5.1 → 0.5.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.
- package/CHANGELOG-ch.md +29 -0
- package/CHANGELOG.md +29 -0
- package/README-ch.md +7 -6
- package/README-en.md +8 -6
- package/README.md +8 -6
- package/cli/build.mjs +1 -1
- package/cli/package.mjs +1 -0
- package/dist-library/authoring-DJJjKYg9.js +842 -0
- package/dist-library/{runtime-CXBdLQ3A.js → compiler-UyPwGzJZ.js} +4374 -3730
- package/dist-library/react-fizgU3i8.js +12764 -0
- package/dist-library/reactive-md-authoring.js +1514 -0
- package/dist-library/reactive-md-editor.js +577 -571
- package/dist-library/reactive-md-print.css +284 -0
- package/dist-library/reactive-md-react-unstyled.js +1 -0
- package/dist-library/reactive-md-react.js +1 -13177
- package/dist-library/reactive-md.css +1 -1
- package/dist-library/reactive-md.js +260 -1062
- package/dist-library/runtime-DXtle_6c.js +498 -0
- package/dist-library/types/authoring/index.d.ts +24 -0
- package/dist-library/types/editor/command-types.d.ts +10 -0
- package/dist-library/types/editor/editor-commands.d.ts +2 -2
- package/dist-library/types/editor/editor-i18n.d.ts +1 -1
- package/dist-library/types/editor/native-components.d.ts +1 -1
- package/dist-library/types/editor/source-authoring.d.ts +5 -3
- package/dist-library/types/editor/types.d.ts +5 -10
- package/dist-library/types/local/LocalDocumentView.d.ts +14 -4
- package/dist-library/types/local/authoring.d.ts +9 -5
- package/dist-library/types/local/diagnostics.d.ts +80 -0
- package/dist-library/types/local/html-names.d.ts +6 -0
- package/dist-library/types/local/index.d.ts +2 -1
- package/dist-library/types/local/limits.d.ts +8 -0
- package/dist-library/types/local/math-display.d.ts +72 -0
- package/dist-library/types/local/math-view.d.ts +2 -0
- package/dist-library/types/local/options.d.ts +9 -2
- package/dist-library/types/local/render-types.d.ts +11 -0
- package/dist-library/types/local/types.d.ts +28 -0
- package/dist-library/types/local/worker.d.ts +5 -1
- package/dist-library/types/react/index.d.ts +1 -1
- package/dist-standalone/reactive-md-standalone.js +54 -50
- package/docs/author-tools-ch.md +11 -5
- package/docs/author-tools-en.md +11 -5
- package/docs/compatibility-ch.md +7 -5
- package/docs/compatibility-en.md +7 -5
- package/docs/component-development-ch.md +4 -4
- package/docs/component-development-en.md +3 -3
- package/docs/component-protocol-ch.md +48 -11
- package/docs/component-protocol-en.md +48 -11
- package/docs/editor-ch.md +237 -235
- package/docs/editor-en.md +237 -235
- package/docs/local-integration-ch.md +392 -366
- package/docs/local-integration-en.md +392 -366
- package/docs/release-0.5.2-ch.md +35 -0
- package/docs/release-0.5.2-en.md +35 -0
- package/docs/release-0.5.3-ch.md +25 -0
- package/docs/release-0.5.3-en.md +25 -0
- package/docs/releasing-ch.md +7 -7
- package/docs/releasing-en.md +8 -8
- package/examples/conformance/README.md +1 -1
- package/package.json +12 -2
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# 0.5.2 预览版发布
|
|
2
|
+
|
|
3
|
+
`reactive-md@0.5.2` 是面向 `next` 渠道的 0.x 预览版。语法修订仍为 `local-draft-2`,主题协议仍为 `reactive-md-theme-1`;因新增宿主组件扩展轴,组块协议提升到 `component-protocol-2`。现有 0.5.x 导入和文档无需迁移。`latest` 仍为 `0.4.0`。
|
|
4
|
+
|
|
5
|
+
```sh
|
|
6
|
+
npm install reactive-md@next
|
|
7
|
+
# 或固定预览版
|
|
8
|
+
npm install reactive-md@0.5.2
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
离线安装可使用 [npm tarball](https://registry.npmjs.org/reactive-md/-/reactive-md-0.5.2.tgz)。
|
|
12
|
+
|
|
13
|
+
## 宿主组件
|
|
14
|
+
|
|
15
|
+
`compileLocal(source, { hostComponents })` 增加一条可选的宿主叶子标签扩展轴。Schema 是普通数据:名称、`form: 'leaf'`,以及声明 `kind`、`required`、`static`、`enum` 和 `pattern` 的属性表。名称必须是唯一的小写 kebab-case,不能复用 48 个作者标签名、P0 HTML 标签名或主题名;单次编译最多接受 32 个 Schema。
|
|
16
|
+
|
|
17
|
+
不传 `hostComponents` 时行为不变:标签仍是未知标签并按原文降级。传入后,解析器生成 `hostComponent` 叶子节点,编译器校验其属性。属性失败使用 `local.host.attribute`,Schema 非法使用 `local.options.invalid`。合法宿主节点计为一个语法节点,宿主属性同样受共享字符串长度预算约束。`pattern` 限制在线性时间安全子集内,拒绝反向引用、环视、命名组、嵌套量词和被量词修饰的分支。
|
|
18
|
+
|
|
19
|
+
`LocalDocumentView` 和 `LocalReactiveDocument` 接受 `hostData`(按 `${kind}:${ref}` 索引的 JSON 安全数据)与仅客户端的 `hostRenderer(node, data, ctx)`。缺少 renderer、缺少数据或 renderer 抛错时显示可见占位,不会让文档失败。`mode="static"` 走同一分派。Schema 会随编译请求进入 worker;renderer 和宿主数据不会。
|
|
20
|
+
|
|
21
|
+
完整契约见[本地模式集成](local-integration-ch.md#宿主组件)与[组块协议](component-protocol-ch.md)。
|
|
22
|
+
|
|
23
|
+
## 协议修订
|
|
24
|
+
|
|
25
|
+
组块协议现为 `component-protocol-2`。语法修订仍为 `local-draft-2`,机器验收基线 `component-protocol-1.json` 继续冻结,用于 48 个作者组块。宿主组件不提供可移植机器用例,因为渲染由宿主拥有。
|
|
26
|
+
|
|
27
|
+
## 兼容性
|
|
28
|
+
|
|
29
|
+
现有 `reactive-md`、`reactive-md/react`、`reactive-md/editor`、`reactive-md/styles.css` 和 `reactive-md/editor/styles.css` 导入继续有效。为 `0.5.x` 编写的文档无需修改;宿主扩展为可选能力。核心入口仍不依赖 React。详见[变更日志](../CHANGELOG-ch.md)与[版本与兼容性](compatibility-ch.md)。
|
|
30
|
+
|
|
31
|
+
## 验证与限制
|
|
32
|
+
|
|
33
|
+
发布门槛覆盖类型检查、完整测试套件、文档链接、包构建和打包安装冒烟检查。单文件导出之外的通用 SSR 水合、Firefox 和 WebKit 仍未验证。
|
|
34
|
+
|
|
35
|
+
项目仍是 0.x 预览版。安全边界与宿主责任见[SECURITY-ch.md](../SECURITY-ch.md)。
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# 0.5.2 preview release
|
|
2
|
+
|
|
3
|
+
`reactive-md@0.5.2` is a 0.x preview that targets the `next` channel. It keeps syntax revision `local-draft-2` and theme protocol `reactive-md-theme-1`, and raises the component protocol to `component-protocol-2` for the host component extension axis. Existing 0.5.x imports and documents need no migration. `latest` remains `0.4.0`.
|
|
4
|
+
|
|
5
|
+
```sh
|
|
6
|
+
npm install reactive-md@next
|
|
7
|
+
# or pin the preview
|
|
8
|
+
npm install reactive-md@0.5.2
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
For offline installation, use the [npm tarball](https://registry.npmjs.org/reactive-md/-/reactive-md-0.5.2.tgz).
|
|
12
|
+
|
|
13
|
+
## Host components
|
|
14
|
+
|
|
15
|
+
`compileLocal(source, { hostComponents })` adds an opt-in extension axis for host-defined leaf tags. A schema is plain data: a name, `form: 'leaf'` and a property table declaring `kind`, `required`, `static`, `enum` and `pattern`. Names must be unique lowercase kebab-case and cannot reuse the 48 author tag names, P0 HTML tag names or the theme name; one compilation accepts at most 32 schemas.
|
|
16
|
+
|
|
17
|
+
Without `hostComponents`, behavior is unchanged: the tag remains unknown and falls back to source. With the option, the parser produces a `hostComponent` leaf node and the compiler validates its attributes. Attribute failures use `local.host.attribute`; invalid schemas use `local.options.invalid`. A valid host node counts as one syntax node, and host attributes obey the shared string-length budget. `pattern` is restricted to a linear-time-safe regex subset that rejects backreferences, lookarounds, named groups, nested quantifiers and quantified alternation.
|
|
18
|
+
|
|
19
|
+
`LocalDocumentView` and `LocalReactiveDocument` accept `hostData`, JSON-safe data keyed `${kind}:${ref}`, and a client-only `hostRenderer(node, data, ctx)`. A missing renderer, missing data or a throwing renderer renders a visible placeholder instead of failing the document. `mode="static"` uses the same dispatch. Schemas travel through the compile worker; the renderer and host data never do.
|
|
20
|
+
|
|
21
|
+
See [Local mode integration](local-integration-en.md#host-components) and [Component protocol](component-protocol-en.md) for the full contract.
|
|
22
|
+
|
|
23
|
+
## Protocol revision
|
|
24
|
+
|
|
25
|
+
The component protocol is now `component-protocol-2`. The syntax revision remains `local-draft-2`, and the machine conformance baseline `component-protocol-1.json` stays frozen for the 48 author components. Host components have no portable machine cases because rendering is host-owned.
|
|
26
|
+
|
|
27
|
+
## Compatibility
|
|
28
|
+
|
|
29
|
+
Existing `reactive-md`, `reactive-md/react`, `reactive-md/editor`, `reactive-md/styles.css` and `reactive-md/editor/styles.css` imports keep working. Documents written for `0.5.x` need no edit; the host extension is opt-in. The core entry still does not depend on React. See the [changelog](../CHANGELOG.md) and [Versions and compatibility](compatibility-en.md).
|
|
30
|
+
|
|
31
|
+
## Validation and limits
|
|
32
|
+
|
|
33
|
+
The release gate covers type checking, the full test suite, documentation links, the package build and a packed-package smoke check. General SSR hydration outside exported HTML, Firefox and WebKit remain unverified.
|
|
34
|
+
|
|
35
|
+
The project remains a 0.x preview. Security boundaries and host responsibilities are documented in [SECURITY.md](../SECURITY.md).
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# 0.5.3 预览版
|
|
2
|
+
|
|
3
|
+
使用 `npm install reactive-md@0.5.3` 或 `npm install reactive-md@next` 安装。语法修订保持 `local-draft-2`,组块协议保持 `component-protocol-2`,主题协议保持 `reactive-md-theme-1`。`latest` 渠道仍为 `0.4.0`。
|
|
4
|
+
|
|
5
|
+
## 宿主集成
|
|
6
|
+
|
|
7
|
+
- 在 `LocalCompileOptions` 中设置 `markdownBreaks: true`,把 Markdown 软换行显示为换行。配置贯通编译、React 预览、worker 与缓存键,源码 UTF-16 偏移保持不变;默认值为 `false`。
|
|
8
|
+
- 用 `reactive-md/react/unstyled` 加载无样式依赖的 React 渲染器。按需引入 `reactive-md/screen.css`(也可用原有 `reactive-md/styles.css`),打印时再引入 `reactive-md/print.css`。屏幕样式不再设置全局 `@page`;独立 HTML 保留自身的打印样式。
|
|
9
|
+
- 从 `reactive-md` 导入 `localCompileOptionsKey`,从任一 React 入口导入 `LocalRenderContext` 类型。
|
|
10
|
+
|
|
11
|
+
## 作者工具
|
|
12
|
+
|
|
13
|
+
新增 `reactive-md/authoring` 纯函数入口,提供 schema、组件目录、模板辅助函数、插入命令和类型,无需加载 React 或 CSS,可供 CM6 等宿主编辑器使用。
|
|
14
|
+
|
|
15
|
+
`analyzeLocalSource(source, options)`、`completeLocalSource(source, offset, options)`、`renameLocalBinding(source, oldName, newName, options)` 和 `formatLocalSource(source, options)` 接受可选 `LocalCompileOptions`。传入与预览相同的配置,即可统一宿主组件、原生 HTML 分流和资源预算的判断。
|
|
16
|
+
|
|
17
|
+
## 数学诊断
|
|
18
|
+
|
|
19
|
+
不支持的显示命令、环境及渲染预算降级会产生带源码范围的警告。降级时仍以转义文本保留公式内容;显示支持与计算支持分别判断。
|
|
20
|
+
|
|
21
|
+
## 兼容性
|
|
22
|
+
|
|
23
|
+
已有入口继续可用。需要文档打印布局的宿主须显式导入可选打印样式,无需迁移文档语法或协议。
|
|
24
|
+
|
|
25
|
+
参见[更新日志](../CHANGELOG-ch.md)、[作者工具](author-tools-ch.md)和[集成指南](local-integration-ch.md)。
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# 0.5.3 preview release
|
|
2
|
+
|
|
3
|
+
Install with `npm install reactive-md@0.5.3` or `npm install reactive-md@next`. This preview keeps syntax revision `local-draft-2`, component protocol `component-protocol-2` and theme protocol `reactive-md-theme-1`. The `latest` channel remains `0.4.0`.
|
|
4
|
+
|
|
5
|
+
## Host integration
|
|
6
|
+
|
|
7
|
+
- Set `markdownBreaks: true` in `LocalCompileOptions` to render Markdown soft line breaks as line breaks. The option travels through compilation, React preview, workers and cache keys. Source offsets retain their original UTF-16 positions; the default is `false`.
|
|
8
|
+
- Use `reactive-md/react/unstyled` for the React renderer with no stylesheet dependency. Import `reactive-md/screen.css` (also available as `reactive-md/styles.css`) for document styles, and opt into `reactive-md/print.css` for print layout and page margins. Screen styles no longer set global `@page` rules. Standalone HTML retains its own print styling.
|
|
9
|
+
- Import `localCompileOptionsKey` from `reactive-md` and `LocalRenderContext` from either React entry.
|
|
10
|
+
|
|
11
|
+
## Author tools
|
|
12
|
+
|
|
13
|
+
The `reactive-md/authoring` entry provides the schema, component catalog, template helpers, insertion commands and their types without loading React or CSS. CM6 and other host editors can use these functions independently of the built-in editor.
|
|
14
|
+
|
|
15
|
+
Pass the same optional `LocalCompileOptions` to `analyzeLocalSource(source, options)`, `completeLocalSource(source, offset, options)`, `renameLocalBinding(source, oldName, newName, options)` and `formatLocalSource(source, options)` as to preview compilation. Host schemas, native HTML routing and resource limits then use the same rules.
|
|
16
|
+
|
|
17
|
+
## Math diagnostics
|
|
18
|
+
|
|
19
|
+
Display math reports source-ranged warnings for unsupported commands or environments and rendering-budget fallbacks. Formulas remain readable as escaped text when rendering falls back. Computation support and display support are checked separately.
|
|
20
|
+
|
|
21
|
+
## Compatibility
|
|
22
|
+
|
|
23
|
+
Existing package entries remain available. Hosts that need document print layout should explicitly import the optional print stylesheet. No source syntax or protocol migration is required.
|
|
24
|
+
|
|
25
|
+
See the [changelog](../CHANGELOG.md), [author tools](author-tools-en.md) and [integration guide](local-integration-en.md).
|
package/docs/releasing-ch.md
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
# 发布清单
|
|
2
2
|
|
|
3
|
-
本文件是维护者的手动发布流程。本清单覆盖 `0.5.
|
|
3
|
+
本文件是维护者的手动发布流程。本清单覆盖 `0.5.2` 预览版,目标渠道为 `next`,`latest` 仍为 `0.4.0`。版本规则见[版本与兼容性](compatibility-ch.md),面向使用者的说明见[0.5.2 发布说明](release-0.5.2-ch.md)。
|
|
4
4
|
|
|
5
5
|
## 发布前确认
|
|
6
6
|
|
|
7
7
|
### 包身份与元数据
|
|
8
8
|
|
|
9
|
-
非 scope 名称 `reactive-md` 已由已发布的 `0.3.0`、`0.3.1` 建立,`reactive-md/react` 和 `reactive-md/styles.css` 子路径也随这些版本生效。`0.5.0` 新增 `reactive-md/editor` 和 `reactive-md/editor/styles.css`,`0.5.1` 保持这些入口。不要把改名当作常规发布准备:改名会破坏导入、状态工具和文档。
|
|
9
|
+
非 scope 名称 `reactive-md` 已由已发布的 `0.3.0`、`0.3.1` 建立,`reactive-md/react` 和 `reactive-md/styles.css` 子路径也随这些版本生效。`0.5.0` 新增 `reactive-md/editor` 和 `reactive-md/editor/styles.css`,`0.5.1` 与 `0.5.2` 保持这些入口。不要把改名当作常规发布准备:改名会破坏导入、状态工具和文档。
|
|
10
10
|
|
|
11
11
|
1. 除非维护者明确决定改用 scope,否则保持 `reactive-md`。scope 需要对应的 npm 账号或组织权限。
|
|
12
12
|
2. 如果改名,同时更新 `package.json` 的 `name`、文档中的导入语句、tarball 文件名说明、示例和相关子路径,并在变更记录中按破坏性变更说明。
|
|
13
13
|
3. 核对 `package.json` 的 `repository`、`homepage`、`bugs`、`license`、`engines` 等发布元数据;当前已设置,发布前确认 URL 和最低 Node 版本仍然正确,并确认 `private` 保持移除状态。
|
|
14
14
|
4. 确认 `files` 覆盖发布所需内容。当前包含 `dist-library`、`dist-standalone`、`bin`、`cli`、README(`README.md`、`README-en.md`、`README-ch.md`)、中英文贡献指南、变更记录与安全策略、`THIRD_PARTY_NOTICES.md`、`docs` 和 `examples`;新增文档或 notice 时同步加入 `files`。
|
|
15
15
|
|
|
16
|
-
包名和版本决定 tarball 名称。当前 `0.5.
|
|
16
|
+
包名和版本决定 tarball 名称。当前 `0.5.2` 的预期文件名是 `reactive-md-0.5.2.tgz`;改名或改版本后以 `npm pack` 的实际输出为准。
|
|
17
17
|
|
|
18
18
|
### 第三方 notice
|
|
19
19
|
|
|
@@ -51,7 +51,7 @@ npm pack
|
|
|
51
51
|
mkdir /tmp/reactive-md-consumer
|
|
52
52
|
cd /tmp/reactive-md-consumer
|
|
53
53
|
npm init -y
|
|
54
|
-
npm install /path/to/reactive-md-0.5.
|
|
54
|
+
npm install /path/to/reactive-md-0.5.2.tgz
|
|
55
55
|
```
|
|
56
56
|
|
|
57
57
|
核心入口可在 Node 中直接检查:
|
|
@@ -96,12 +96,12 @@ import 'reactive-md/editor/styles.css';
|
|
|
96
96
|
|
|
97
97
|
1. 确认工作区干净,变更已审查;`npm ci` 从锁文件安装成功。
|
|
98
98
|
2. 在 Node 22.12 和受支持的较新 LTS(当前为 24)上运行 `npm run verify:release`。这是维护者和 CI 共用的完整门禁,不要用一组自行挑选的命令代替。
|
|
99
|
-
3. 确认版本号、`CHANGELOG-ch.md` 和发布说明一致。`0.5.
|
|
99
|
+
3. 确认版本号、`CHANGELOG-ch.md` 和发布说明一致。`0.5.2` 新增宿主组件,并把组块协议提升到 `component-protocol-2`;`LOCAL_SYNTAX_VERSION` 和主题协议不变。仅在某条版本轴自身的契约变化时更新它。
|
|
100
100
|
4. 检查门禁保留的安装包,包括文件列表、大小和许可文件。手动重新运行 `npm pack` 会产生新候选包,需要单独完成安装验证。
|
|
101
101
|
5. 核对安装包的 SHA256 与 `artifacts/release-package/package-verification.json` 一致,并记录到发布说明或内部发布记录。
|
|
102
102
|
6. 合并发布提交,等待 `main` 上的 CI 全部通过。
|
|
103
|
-
7. 手动创建并推送 tag,例如 `v0.5.
|
|
104
|
-
8. 在维护者本机完成 npm 登录和双因素认证后,手动发布已经验证的预览版安装包:`npm publish artifacts/release-package/reactive-md-0.5.
|
|
103
|
+
7. 手动创建并推送 tag,例如 `v0.5.2`。不要在自动发布工作流中保存 npm token。
|
|
104
|
+
8. 在维护者本机完成 npm 登录和双因素认证后,手动发布已经验证的预览版安装包:`npm publish artifacts/release-package/reactive-md-0.5.2.tgz --access public --tag next`。预览版先发布到 `next`,本次 `latest` 保持 `0.4.0`。提升 `0.5.2` 需要单独决定:`npm dist-tag add reactive-md@0.5.2 latest`。
|
|
105
105
|
9. 在 npm 和 GitHub Releases 上核对包内容、版本、README、许可与发布说明;从公开 registry 重新安装一次。
|
|
106
106
|
10. 从 registry 验证 README 中的安装命令可用,核对 registry 的完整性摘要与发布 tarball 一致。
|
|
107
107
|
|
package/docs/releasing-en.md
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
# Release checklist
|
|
2
2
|
|
|
3
|
-
This file is the maintainers' manual release process. This checklist covers the `0.5.
|
|
3
|
+
This file is the maintainers' manual release process. This checklist covers the `0.5.2` preview release, which targets the `next` channel; `latest` remains `0.4.0`. See [Versions and compatibility](compatibility-en.md) for version rules and [0.5.2 release notes](release-0.5.2-en.md) for the user-facing summary.
|
|
4
4
|
|
|
5
5
|
## Before release
|
|
6
6
|
|
|
7
7
|
### Package identity and metadata
|
|
8
8
|
|
|
9
|
-
The unscoped name `reactive-md` is already established by the published `0.3.0` and `0.3.1` releases, together with the `reactive-md/react` and `reactive-md/styles.css` subpaths. `0.5.0` adds `reactive-md/editor` and `reactive-md/editor/styles.css`; `0.5.1`
|
|
9
|
+
The unscoped name `reactive-md` is already established by the published `0.3.0` and `0.3.1` releases, together with the `reactive-md/react` and `reactive-md/styles.css` subpaths. `0.5.0` adds `reactive-md/editor` and `reactive-md/editor/styles.css`; `0.5.1` and `0.5.2` keep those entries. Do not treat a rename as routine release preparation: changing the name is a breaking change for imports, state tooling and documentation.
|
|
10
10
|
|
|
11
11
|
1. Keep `reactive-md` unless maintainers explicitly decide on a scoped rename. A scope requires the corresponding npm account or organization permissions.
|
|
12
12
|
2. If renaming, update `name` in `package.json`, import statements in the documentation, tarball filename references, examples and the relevant subpaths, then record the change as breaking in the changelog.
|
|
13
13
|
3. Check release metadata in `package.json`: `repository`, `homepage`, `bugs`, `license`, `engines` and similar fields. They are currently set; before releasing, confirm the URLs and minimum Node version are still correct and that `private` remains removed.
|
|
14
14
|
4. Confirm `files` covers what needs to be published. It currently includes `dist-library`, `dist-standalone`, `bin`, `cli`, the READMEs (`README.md`, `README-en.md`, `README-ch.md`), the contributing, changelog and security guides in both languages, `THIRD_PARTY_NOTICES.md`, `docs` and `examples`; add any new documentation or notices to `files` as well.
|
|
15
15
|
|
|
16
|
-
The package name and version determine the tarball name. The expected filename for `0.5.
|
|
16
|
+
The package name and version determine the tarball name. The expected filename for `0.5.2` is `reactive-md-0.5.2.tgz`; after renaming or changing the version, use the actual output of `npm pack`.
|
|
17
17
|
|
|
18
18
|
### Third-party notices
|
|
19
19
|
|
|
@@ -51,7 +51,7 @@ npm pack
|
|
|
51
51
|
mkdir /tmp/reactive-md-consumer
|
|
52
52
|
cd /tmp/reactive-md-consumer
|
|
53
53
|
npm init -y
|
|
54
|
-
npm install /path/to/reactive-md-0.5.
|
|
54
|
+
npm install /path/to/reactive-md-0.5.2.tgz
|
|
55
55
|
```
|
|
56
56
|
|
|
57
57
|
The core entry can be checked directly in Node:
|
|
@@ -86,7 +86,7 @@ Release notes are for users and must include at least:
|
|
|
86
86
|
|
|
87
87
|
- The package version, `LOCAL_SYNTAX_VERSION`, component protocol revision and theme protocol revision; these are different version numbers.
|
|
88
88
|
- The install command `npm install reactive-md@next`, or `npm install reactive-md@<version>` to pin the release, with a downloadable tarball as an offline installation option.
|
|
89
|
-
- User-visible changes, breaking changes and migration steps; link directly to the [changelog](../CHANGELOG.md) and the [0.5.
|
|
89
|
+
- User-visible changes, breaking changes and migration steps; link directly to the [changelog](../CHANGELOG.md) and the [0.5.2 release notes](release-0.5.2-en.md) for this cycle.
|
|
90
90
|
- Verified platforms, plus unverified browsers, general SSR hydration and other scope.
|
|
91
91
|
- Known limitations and a link to [SECURITY.md](../SECURITY.md).
|
|
92
92
|
|
|
@@ -96,12 +96,12 @@ Do not write results for checks that have not run, and do not present the existe
|
|
|
96
96
|
|
|
97
97
|
1. Confirm the working tree is clean, changes have been reviewed, and `npm ci` installs successfully from the lockfile.
|
|
98
98
|
2. On Node 22.12 and a supported newer LTS (currently 24), run `npm run verify:release`. This is the same complete gate local maintainers and CI use; do not replace it with a list of hand-picked commands.
|
|
99
|
-
3. Confirm the version number, `CHANGELOG.md` and the release notes agree. `0.5.
|
|
99
|
+
3. Confirm the version number, `CHANGELOG.md` and the release notes agree. `0.5.2` adds host components and raises the component protocol to `component-protocol-2`; `LOCAL_SYNTAX_VERSION` and the theme protocol are unchanged. Update a version axis only when its own contract changes.
|
|
100
100
|
4. Inspect the verified archive retained by the gate, including its file list, size and license files. A fresh manual `npm pack` produces a new candidate that needs its own installation verification.
|
|
101
101
|
5. Compare the archive's SHA256 with `artifacts/release-package/package-verification.json` and record it in the release notes or an internal release record.
|
|
102
102
|
6. Merge the release commit and wait for all CI on `main` to pass.
|
|
103
|
-
7. Create and push the tag manually, for example `v0.5.
|
|
104
|
-
8. After signing in to npm and completing two-factor authentication on the maintainer's machine, publish the verified preview tarball manually: `npm publish artifacts/release-package/reactive-md-0.5.
|
|
103
|
+
7. Create and push the tag manually, for example `v0.5.2`. Do not store npm tokens in an automated release workflow.
|
|
104
|
+
8. After signing in to npm and completing two-factor authentication on the maintainer's machine, publish the verified preview tarball manually: `npm publish artifacts/release-package/reactive-md-0.5.2.tgz --access public --tag next`. Preview releases start on `next`, and this release keeps `latest` on `0.4.0`. Promoting `0.5.2` requires a separate decision: `npm dist-tag add reactive-md@0.5.2 latest`.
|
|
105
105
|
9. Verify the package contents, version, README, license and release notes on npm and GitHub Releases; reinstall once from the public registry.
|
|
106
106
|
10. Verify that the install command in the README works from the registry, and that the registry integrity digest matches the released tarball.
|
|
107
107
|
|
|
@@ -14,7 +14,7 @@ The conformance sources are unversioned and use the current `local-draft-2` revi
|
|
|
14
14
|
|
|
15
15
|
## Component protocol conformance
|
|
16
16
|
|
|
17
|
-
[component-protocol-1.json](component-protocol-1.json) provides representative cases for the [component protocol](../../docs/component-protocol-en.md), covering `slider`, `tabs`, `plot` and lazy degradation of unknown components. The [JSON Schema](component-protocol-1.schema.json) defines the conformance file format so tools from other implementations can read it. This JSON is test input and expected results; see the [development guide](../../docs/component-development-en.md) for the declaration template of a component proposal.
|
|
17
|
+
[component-protocol-1.json](component-protocol-1.json) provides representative cases for the [component protocol](../../docs/component-protocol-en.md), covering `slider`, `tabs`, `plot` and lazy degradation of unknown components. The existing `component-protocol-1.json` remains the frozen author-component baseline now that the protocol revision is `component-protocol-2`. The [JSON Schema](component-protocol-1.schema.json) defines the conformance file format so tools from other implementations can read it. This JSON is test input and expected results; see the [development guide](../../docs/component-development-en.md) for the declaration template of a component proposal.
|
|
18
18
|
|
|
19
19
|
```sh
|
|
20
20
|
npm run test:components
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "reactive-md",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.3",
|
|
4
4
|
"description": "Author interactive local documents in Markdown, with expression-bound inputs, charts and diagrams.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"markdown",
|
|
@@ -103,7 +103,17 @@
|
|
|
103
103
|
"types": "./dist-library/types/editor/index.d.ts",
|
|
104
104
|
"import": "./dist-library/reactive-md-editor.js"
|
|
105
105
|
},
|
|
106
|
-
"./editor/styles.css": "./dist-library/reactive-md-editor.css"
|
|
106
|
+
"./editor/styles.css": "./dist-library/reactive-md-editor.css",
|
|
107
|
+
"./react/unstyled": {
|
|
108
|
+
"types": "./dist-library/types/react/index.d.ts",
|
|
109
|
+
"import": "./dist-library/reactive-md-react-unstyled.js"
|
|
110
|
+
},
|
|
111
|
+
"./screen.css": "./dist-library/reactive-md.css",
|
|
112
|
+
"./print.css": "./dist-library/reactive-md-print.css",
|
|
113
|
+
"./authoring": {
|
|
114
|
+
"types": "./dist-library/types/authoring/index.d.ts",
|
|
115
|
+
"import": "./dist-library/reactive-md-authoring.js"
|
|
116
|
+
}
|
|
107
117
|
},
|
|
108
118
|
"peerDependencies": {
|
|
109
119
|
"react": "^19.0.0",
|