@jboltai/tokui 0.1.0 → 0.1.2
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 +20 -0
- package/README.md +1 -1
- package/README_EN.md +2 -2
- package/dist/tokui.cjs +6 -6
- package/dist/tokui.cjs.map +1 -1
- package/dist/tokui.css +1 -1
- package/dist/tokui.mjs +1021 -463
- package/dist/tokui.mjs.map +1 -1
- package/dist/tokui.umd.js +6 -6
- package/dist/tokui.umd.js.map +1 -1
- package/package.json +4 -3
- package/src/server/tokui-builder.js +2 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,25 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
|
|
5
|
+
## [0.1.1] - 2026-06-26
|
|
6
|
+
|
|
7
|
+
文档站主题交互与指南完善,附带一处多实例主题装配的 bug 修复。
|
|
8
|
+
|
|
9
|
+
### 修复
|
|
10
|
+
|
|
11
|
+
- **多实例主题装配**:`new TokUI({ theme })` 现在对 `'default'` 也调用 `setTheme`,修复连续构造 `dark` → `default` 实例时后者容器残留 `data-tokui-theme="dark"` 的问题。根因:主题管理是单例,`init()` 会把「上一次实例残留的 `currentTheme`」写到新容器,而构造器原先对 `'default'` 跳过了 `setTheme`。`ThemeShowcase` 切回 default 不生效即此因。新增 `test-theme.js` 多实例回归用例。
|
|
12
|
+
- **DSL 语法示例**:动态更新章节的 Playground 原为无关的 `stat` 示例,改为 `[progress]` + `[upd]` 序列,并提示 ⚡ 流式可重放 0% → 50% → 100% 跳动。
|
|
13
|
+
|
|
14
|
+
### 新增
|
|
15
|
+
|
|
16
|
+
- **主题切换演示器**(`ThemeShowcase`):theming 页可实时切换风格族(default / modern)× 明暗(light / dark),驱动同一份 DSL 在四套主题下的渲染对比。Playground 新增 `theme` prop。
|
|
17
|
+
|
|
18
|
+
### 变更
|
|
19
|
+
|
|
20
|
+
- **Playground 跟随站点明暗**:渲染主题默认跟随 VitePress header 的 light/dark 切换(站点 dark → `'dark'`,light → `'default'`);显式传 `theme` 则覆盖、不再跟随。
|
|
21
|
+
- **快速开始指南重写**:补全 npm 安装 / CDN / 浏览器示例 / 三种渲染方式 / React · Vue · Svelte · Next.js(Nuxt) SSR 集成 / 服务端 Builder 命名导出 `{ TokUIBuilder }` / 引入与样式路径。
|
|
22
|
+
- **主题指南重写**:4 套内置主题(default / dark / modern / modern-dark)、三层令牌体系、运行时 `setSeedColor` 自定义色板、构建期 `generateThemeTokens`、自定义主题步骤与三个坑(`color-scheme` / 二级语义变量 / `--danger` 别名)。
|
|
23
|
+
|
|
5
24
|
## [0.1.0] - 2026-06-25
|
|
6
25
|
|
|
7
26
|
首个公开 npm 发布版本(开源就绪)。零依赖流式 UI 描述与渲染框架。
|
|
@@ -32,4 +51,5 @@ All notable changes to this project will be documented in this file.
|
|
|
32
51
|
- `test-layout.js` 的 `item content + nested list` 断言改为符合真实 DOM 聚合语义。
|
|
33
52
|
- `src/index.js` 与 `src/components/index.js` 的模块求值期裸读 `window.TokUI._internal` 改为运行期懒解析,SSR 导入不再依赖 bundler 保留 `require` 的怪癖。
|
|
34
53
|
|
|
54
|
+
[0.1.1]: https://github.com/jboltai/tokui/releases/tag/v0.1.1
|
|
35
55
|
[0.1.0]: https://github.com/jboltai/tokui/releases/tag/v0.1.0
|
package/README.md
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
[](#)
|
|
11
11
|
[](https://bundlephobia.com/package/@jboltai/tokui)
|
|
12
12
|
|
|
13
|
-
[
|
|
13
|
+
[官网文档站](https://tokui.jboltai.com/) · [组件画廊演示](https://tokui_demo.jboltai.com/) · [DSL 完整参考](./demo/TOKUI_DSL_REFERENCE.md) · [在线体验(StackBlitz)](https://stackblitz.com/github/jboltai/tokui)
|
|
14
14
|
|
|
15
15
|
---
|
|
16
16
|
|
package/README_EN.md
CHANGED
|
@@ -10,7 +10,7 @@ English | **[简体中文](./README.md)**
|
|
|
10
10
|
[](#)
|
|
11
11
|
[](https://bundlephobia.com/package/@jboltai/tokui)
|
|
12
12
|
|
|
13
|
-
[
|
|
13
|
+
[Official Docs site](https://tokui.jboltai.com/) · [Component gallery demo](https://tokui_demo.jboltai.com/) · [DSL reference](./demo/TOKUI_DSL_REFERENCE.md) · [Try on StackBlitz](https://stackblitz.com/github/jboltai/tokui)
|
|
14
14
|
|
|
15
15
|
---
|
|
16
16
|
|
|
@@ -339,7 +339,7 @@ Adding a new component takes four steps:
|
|
|
339
339
|
|
|
340
340
|
4. **Add styles** (`src/styles/tokui.css`): class `.tokui-mycard`; variants use `.tokui-mycard--{variant}` and must be added to the `VARIANTS` whitelist in `renderer.js`.
|
|
341
341
|
|
|
342
|
-
Finally, add a test in `tests/`, and optionally a demo in the `DEMOS` array of `
|
|
342
|
+
Finally, add a test in `tests/`, and optionally a demo in the `DEMOS` array of `demo/server/sse-server.js`.
|
|
343
343
|
|
|
344
344
|
---
|
|
345
345
|
|