diff --git a/CHANGELOG.md b/CHANGELOG.md index a4a3188..30d6fe7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,11 @@ versioning follows [SemVer](https://semver.org/). ## [Unreleased] +## [0.0.2-beta.2] — 2026-09-05 + +Ships the portable renderer, and corrects what the registry and the site were +saying about this project. + ### Added - **Window frames for a portable block**, via `renderPortable(…, { frame })`. `header` is jsray-wp's own title bar — bold filename on the left, language on the right — so a block copied from the site and a block the plugin rendered read as the same product; `macos` is the three dots; `minimal` is a hairline strip. `title` and `label` fill them, and the chrome's colours are computed from the palette with the same arithmetic the plugin's stylesheet does in `color-mix()`, rather than a second set of colours that would drift. A frame costs 490 bytes for the hairline, 750 for the title bar and 1,060 for the dots. @@ -25,6 +30,9 @@ versioning follows [SemVer](https://semver.org/). - **The palette fallback chain has one implementation.** `applyThemeToRoot` carried the only copy of it; `resolveToken` is now shared with the portable renderer, because two renderers resolving the same palette by two implementations is how they come to disagree about a palette that predates a token key. - The site build ships `themes/` and the new page. The paste page fetches every palette at runtime for the same reason the Studio does — a second copy of the colours is a second thing to drift. +- **The README says what the integrations are, because npm shows this file.** The published page for `@jsray/core@0.0.2-beta.1` still lists all three as "Coming soon"; all three are public with releases, and the table now links each one and says where it can actually be installed from — which is GitHub rather than its host's directory in every case. npm freezes a package page per version, so a correction only reaches the registry by publishing. +- **`repository` and `bugs` point at the organisation's current name.** They were published as `github.com/JSRayCore/JSRay`, which still redirects — but the frozen metadata is what every tool reads, and the org name it names no longer exists. +- **The versioning doc says why Core counts its betas.** It justified the counter mechanically — `check:versions` wants it, `version_compare()` orders it — which is true and is not the reason. Core is the kernel every integration renders through, so it earns more revision rounds before `0.1.0` than anything built on it, and those land inside one patch. The integrations bump the patch each time, so a counter would say nothing. ## [0.0.2-beta.1] — 2026-08-24 diff --git a/README.md b/README.md index 956174a..64e4b1e 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ [![npm](https://img.shields.io/npm/v/@jsray/core/beta?label=npm)](https://www.npmjs.com/package/@jsray/core) [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE) -[![Version](https://img.shields.io/badge/version-0.0.2--beta.1-lightgrey)](CHANGELOG.md) +[![Version](https://img.shields.io/badge/version-0.0.2--beta.2-lightgrey)](CHANGELOG.md) [![Channel](https://img.shields.io/badge/channel-beta-blue)](docs/versioning.md) [![Zero deps](https://img.shields.io/badge/dependencies-0-success)](package.json) [![Size](https://img.shields.io/badge/dist-core%20js%20%2B%20css-lightgrey)](dist/) @@ -46,7 +46,7 @@ Or drop it into a page with no build step at all: watching, pin the version instead** — every release is frozen at its own path: ```html - + ``` ### Verifying what you loaded @@ -56,7 +56,7 @@ A pinned URL says which release you asked for, not which bytes you got. Add a hash and the browser refuses to run the file if it is not the one published: ```html - ``` @@ -64,7 +64,7 @@ hash and the browser refuses to run the file if it is not the one published: The hashes live next to the files they describe, in the same format SRI uses: ``` -https://jsray.org/v/0.0.2-beta.1/integrity.json +https://jsray.org/v/0.0.2-beta.2/integrity.json ``` `crossorigin="anonymous"` is required, not optional — SRI on a cross-origin @@ -107,15 +107,25 @@ JSRay is intended to be a fully open-source code rendering ecosystem: one small > One renderer. Many places for code to shine. -Official integrations live in their own repositories, use JSRay Core by default, and stay fully usable without paid feature locks. Planned integrations: +Official integrations live in their own repositories, use JSRay Core by default, and stay fully usable without paid feature locks. The integrations: | Integration | Repository | Status | |---|---|---| -| WordPress plugin | `jsray-wp` | Coming soon | -| VS Code extension | `jsray-vscode` | Coming soon | -| Terminal CLI | `jsray-terminal` | Coming soon | +| WordPress plugin | [`jsray-wp`](https://github.com/jsrayorg/jsray-wp) | Public beta · not on WordPress.org yet | +| VS Code extension | [`jsray-vscode`](https://github.com/jsrayorg/jsray-vscode) | Public beta · not on the Marketplace yet | +| Terminal CLI | [`jsray-terminal`](https://github.com/jsrayorg/jsray-terminal) | Public beta · not on npm yet | | …and more | — | Community & official adapters welcome | +Each is installable today, from GitHub rather than from its host's directory: + +```sh +# Terminal CLI +npm i -g github:jsrayorg/jsray-terminal +``` + +- **VS Code** — download the `.vsix` from [its latest release](https://github.com/jsrayorg/jsray-vscode/releases/latest), then `code --install-extension jsray-vscode-.vsix`, or **Extensions** → `…` → **Install from VSIX…** +- **WordPress** — download the `.zip` from [its latest release](https://github.com/jsrayorg/jsray-wp/releases/latest), then **Plugins → Add New → Upload Plugin** + Each repository is published as it reaches its own beta. Every integration exposes renderer adapter hooks, so a host project can swap in another renderer when it needs to. --- diff --git a/README.zh-CN.md b/README.zh-CN.md index 57a7288..0424a79 100644 --- a/README.zh-CN.md +++ b/README.zh-CN.md @@ -9,7 +9,7 @@ [![npm](https://img.shields.io/npm/v/@jsray/core/beta?label=npm)](https://www.npmjs.com/package/@jsray/core) [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE) -[![Version](https://img.shields.io/badge/version-0.0.2--beta.1-lightgrey)](CHANGELOG.md) +[![Version](https://img.shields.io/badge/version-0.0.2--beta.2-lightgrey)](CHANGELOG.md) [![Channel](https://img.shields.io/badge/channel-beta-blue)](docs/versioning.md) [![Zero deps](https://img.shields.io/badge/dependencies-0-success)](package.json) [![Size](https://img.shields.io/badge/dist-core%20js%20%2B%20css-lightgrey)](dist/) @@ -45,7 +45,7 @@ JSRay.highlight('const x = 42;', 'js'); `jsray.org/dist/` 始终提供当前发布版本。**线上站点如果你不会持续盯着,请改用锁定版本的地址** —— 每个发布版本都固化在自己的路径下,永不变动: ```html - + ``` ### 校验你加载到的东西 @@ -55,7 +55,7 @@ JSRay.highlight('const x = 42;', 'js'); 哈希,浏览器在文件与发布内容不符时会直接拒绝执行: ```html - ``` @@ -63,7 +63,7 @@ JSRay.highlight('const x = 42;', 'js'); 哈希就放在它所描述的文件旁边,格式与 SRI 完全一致: ``` -https://jsray.org/v/0.0.2-beta.1/integrity.json +https://jsray.org/v/0.0.2-beta.2/integrity.json ``` `crossorigin="anonymous"` 是必需的,不是可选:跨源脚本的 SRI 只有在加载走 @@ -86,15 +86,25 @@ JSRay 的目标是成为完整开源的代码渲染生态:一个轻量 Core > 一个渲染核心,让代码在不同平台中发光。 -官方集成各自独立仓库,默认使用 JSRay Core,并保持完整可用,不以付费锁定基础能力。规划中的集成: +官方集成各自独立仓库,默认使用 JSRay Core,并保持完整可用,不以付费锁定基础能力。集成一览: | 集成 | 仓库 | 状态 | |---|---|---| -| WordPress 插件 | `jsray-wp` | 即将推出 | -| VS Code 扩展 | `jsray-vscode` | 即将推出 | -| 终端 CLI | `jsray-terminal` | 即将推出 | +| WordPress 插件 | [`jsray-wp`](https://github.com/jsrayorg/jsray-wp) | 公开测试版 · 尚未上架 WordPress.org | +| VS Code 扩展 | [`jsray-vscode`](https://github.com/jsrayorg/jsray-vscode) | 公开测试版 · 尚未上架 Marketplace | +| 终端 CLI | [`jsray-terminal`](https://github.com/jsrayorg/jsray-terminal) | 公开测试版 · 尚未发布到 npm | | …以及更多 | — | 欢迎官方与社区适配器 | +三个集成现在都能装,只是要从 GitHub 拿,而不是各自平台的市场: + +```sh +# 终端 CLI +npm i -g github:jsrayorg/jsray-terminal +``` + +- **VS Code** —— 从[最新 Release](https://github.com/jsrayorg/jsray-vscode/releases/latest) 下载 `.vsix`,执行 `code --install-extension jsray-vscode-<版本>.vsix`,或在 **扩展** → `…` → **从 VSIX 安装…** +- **WordPress** —— 从[最新 Release](https://github.com/jsrayorg/jsray-wp/releases/latest) 下载 `.zip`,在后台 **插件 → 安装插件 → 上传插件** + 各仓库在其到达 beta 时对外公开。每个集成都开放 renderer adapter / hook,宿主项目需要时可接入其它渲染器。 --- diff --git a/SECURITY.md b/SECURITY.md index 5c4765c..92a44f0 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -43,7 +43,7 @@ one. | Version | Security updates | |---|---| -| 0.0.2-beta.1 | ✅ Current public beta | +| 0.0.2-beta.2 | ✅ Current public beta | | Earlier betas | ❌ Superseded — upgrade to the current beta | | 0.0.1-internal.∗ | ❌ Superseded by the public beta | | Stable | Not yet released | diff --git a/demo/index.html b/demo/index.html index c78d26a..7fde8b5 100644 --- a/demo/index.html +++ b/demo/index.html @@ -336,11 +336,11 @@

Documentation

Ecosystem

@@ -357,7 +357,7 @@

Project

diff --git a/demo/studio.html b/demo/studio.html index aa82ea5..56f7734 100644 --- a/demo/studio.html +++ b/demo/studio.html @@ -94,8 +94,8 @@

Ecosystem

  • WordPress · jsray-wpbeta
  • - - +
  • VS Code · jsray-vscodebeta
  • +
  • Terminal · jsray-terminalbeta
  • How integrations work
  • @@ -112,7 +112,7 @@

    Project

    diff --git a/dist/jsray.js b/dist/jsray.js index 454124d..d795c05 100644 --- a/dist/jsray.js +++ b/dist/jsray.js @@ -1865,7 +1865,7 @@ * Runtime version, for shell/core compatibility negotiation. * Must match version.json — tools/check-versions.mjs asserts it. */ - version: '0.0.2-beta.1', + version: '0.0.2-beta.2', languages: G, normalizeLanguage, detectLanguage, diff --git a/docs/projects.md b/docs/projects.md index 9b9f7b3..8bacd38 100644 --- a/docs/projects.md +++ b/docs/projects.md @@ -61,12 +61,15 @@ Core changes flow into plugin repositories by copying or packaging `dist/` asset ## Repository Split -| Repository | Ships as | Licence | State | +| Repository | Intended channel | Licence | Available from today | |---|---|---|---| -| `jsray` | npm `@jsray/core` | MIT | public | -| `jsray-wp` | WordPress.org plugin | GPLv2 or later | public | -| `jsray-terminal` | npm CLI | MIT | not published yet | -| `jsray-vscode` | VS Code Marketplace | MIT | not published yet | +| `jsray` | npm `@jsray/core` | MIT | npm — `@jsray/core@0.0.2-beta.2` | +| `jsray-wp` | WordPress.org plugin | GPLv2 or later | GitHub release zip · not on WordPress.org yet | +| `jsray-terminal` | npm CLI | MIT | GitHub — `npm i -g github:jsrayorg/jsray-terminal` · not on npm yet | +| `jsray-vscode` | VS Code Marketplace | MIT | GitHub release `.vsix` · not on the Marketplace yet | + +A public repository is not a listing. The last column is where a user can +actually get the thing today; the second is where it is headed. Future platform repositories such as `jsray-react`, `jsray-astro`, or `jsray-mdx` if needed. @@ -91,7 +94,7 @@ The public website keeps the brand concentrated under `jsray.org`: moves on every release, which is right for the demo and wrong for a site nobody is watching. - `https://jsray.org/v//`: the same files frozen per release - (`jsray.org/v/0.0.2-beta.1/jsray.js`). A page that pins here keeps rendering + (`jsray.org/v/0.0.2-beta.2/jsray.js`). A page that pins here keeps rendering the way it did the day it was written. `tools/build-site.sh` emits both. Cloudflare replaces the whole asset bundle on diff --git a/docs/projects.zh-CN.md b/docs/projects.zh-CN.md index c6b847e..6e7b20d 100644 --- a/docs/projects.zh-CN.md +++ b/docs/projects.zh-CN.md @@ -64,9 +64,11 @@ Core 的变更通过拷贝或打包 `dist/` 资产流向插件仓库。插件的 | 仓库 | 交付形态 | 许可 | 状态 | |---|---|---|---| | `jsray` | npm `@jsray/core` | MIT | 已公开 | -| `jsray-wp` | WordPress.org 插件 | GPLv2 or later | 已公开 | -| `jsray-terminal` | npm CLI | MIT | 尚未发布 | -| `jsray-vscode` | VS Code Marketplace | MIT | 尚未发布 | +| `jsray-wp` | WordPress.org 插件 | GPLv2 or later | GitHub Release 的 zip · 尚未上架 WordPress.org | +| `jsray-terminal` | npm CLI | MIT | GitHub —— `npm i -g github:jsrayorg/jsray-terminal` · 尚未发布到 npm | +| `jsray-vscode` | VS Code Marketplace | MIT | GitHub Release 的 `.vsix` · 尚未上架 Marketplace | + +仓库公开不等于已上架。最后一列是**今天用户实际能从哪里拿到**,第二列是它将来要去的地方。 未来按需增加的平台仓库,例如 `jsray-react`、`jsray-astro`、`jsray-mdx`。 @@ -87,7 +89,7 @@ GPLv2 or later,因为 WordPress.org 的第一条指南接受任何 GPL 兼容许 (`jsray.org/dist/jsray.js`、`jsray.org/dist/themes/.css`)。这个路径每次 发版都会变 —— 对演示页是对的,对没人盯着的站点是错的。 - `https://jsray.org/v//`:同样的文件按版本固化 - (`jsray.org/v/0.0.2-beta.1/jsray.js`)。锁定到这里的页面,今天怎么渲染, + (`jsray.org/v/0.0.2-beta.2/jsray.js`)。锁定到这里的页面,今天怎么渲染, 以后还怎么渲染。 `tools/build-site.sh` 两者都生成。Cloudflare 每次部署都会整体替换资产包,因此 diff --git a/docs/versioning.md b/docs/versioning.md index 1db299d..a49a553 100644 --- a/docs/versioning.md +++ b/docs/versioning.md @@ -4,7 +4,7 @@ JSRay Core uses single-project versioning. Platform plugins keep their own version files in their own repositories. -Current version: `0.0.2-beta.1` +Current version: `0.0.2-beta.2` Current channel: `beta` Public beta released: yes @@ -22,12 +22,18 @@ Internal test builds may be shared privately, but they should not be described a ### The ladder -Each beta bumps the **patch**; the counter after it exists because -`check:versions` requires it and because `version_compare()` is what orders -these — string order would put `0.0.10` before `0.0.2`. +Each beta bumps the **patch**, and Core alone keeps a counter after it. That is +not a notation preference: Core is the kernel every integration renders through, +so it earns more revision rounds before `0.1.0` than anything built on top of it, +and those rounds land within a single patch. The integrations do not iterate that +way, so they carry no counter. + +The mechanics follow from that: `check:versions` requires the counter here, and +`version_compare()` is what orders these — string order would put `0.0.10` before +`0.0.2`. ``` -0.0.1-beta.1 … 0.0.1-beta.5 → 0.0.2-beta.1 → 0.0.3-beta.1 → … → 0.1.0 +0.0.1-beta.1 … 0.0.1-beta.5 → 0.0.2-beta.1 → 0.0.2-beta.2 → 0.0.3-beta.1 → … → 0.1.0 ``` The `0.0.1` line closed at beta.5. `0.1.0` is where the beta label comes off, diff --git a/docs/versioning.zh-CN.md b/docs/versioning.zh-CN.md index ec7531c..d382a4f 100644 --- a/docs/versioning.zh-CN.md +++ b/docs/versioning.zh-CN.md @@ -4,7 +4,7 @@ JSRay Core 采用单项目版本号。平台插件在各自仓库里维护自己的版本文件。 -当前版本:`0.0.2-beta.1` +当前版本:`0.0.2-beta.2` 当前通道:`beta` 公开测试版已发布:是 @@ -22,11 +22,15 @@ JSRay Core 是独立的 JavaScript 原生代码渲染内核。平台插件(包 ### 版本阶梯 -每个 beta 递增**补丁号**;后面那个计数器保留,一是 `check:versions` 强制要求, -二是排序用的是 `version_compare()` —— 字符串排序会把 `0.0.10` 排在 `0.0.2` 前面。 +每个 beta 递增**补丁号**,而计数器只有 Core 保留。这不是记法偏好:Core 是所有集成 +共同依赖的内核,进入 `0.1.0` 之前理应比任何建在它之上的东西经历更多轮修订,而那些 +轮次落在同一个补丁号之内。各集成不这样迭代,所以不带计数器。 + +机制上的理由随之而来:`check:versions` 在这里强制要求它,排序用的是 +`version_compare()` —— 字符串排序会把 `0.0.10` 排在 `0.0.2` 前面。 ``` -0.0.1-beta.1 … 0.0.1-beta.5 → 0.0.2-beta.1 → 0.0.3-beta.1 → …… → 0.1.0 +0.0.1-beta.1 … 0.0.1-beta.5 → 0.0.2-beta.1 → 0.0.2-beta.2 → 0.0.3-beta.1 → …… → 0.1.0 ``` `0.0.1` 这条线在 beta.5 结束。`0.1.0` 才是脱掉 beta 标签的地方,因此 `0.0.1` diff --git a/integrity.json b/integrity.json index 1711f91..d46d0d0 100644 --- a/integrity.json +++ b/integrity.json @@ -1,10 +1,10 @@ { "project": "jsray", - "version": "0.0.2-beta.1", + "version": "0.0.2-beta.2", "algorithm": "sha256", "note": "Base64 SHA-256 digests of the released Core assets. Integrations copy the relevant digest at sync time and verify their bundled snapshot against it.", "files": { - "dist/jsray.js": "sha256-x180Gx5SNG9mcOdUrW8pyDkuoGV6MY4VB2caqu1Jd44=", + "dist/jsray.js": "sha256-FAodgz8GT5uEr//Gd7lY6pbSBtbIZzzYHIitDfEqkVg=", "dist/jsray.css": "sha256-6Fuva+aZwCcmltNi2oN+1yWIJoKE+1rLpUxZvD9iutc=", "dist/themes/aurora.css": "sha256-S8X+R8XZNC8WRdHOen839zMkPxVFol6PPTrpZibbeJA=", "dist/themes/default.css": "sha256-vENOigRjwn1hW6wPjdM4tbZ58Ja44FMsa+akavPiMSI=", diff --git a/package.json b/package.json index 654983a..623ec14 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@jsray/core", - "version": "0.0.2-beta.1", + "version": "0.0.2-beta.2", "description": "JavaScript-native code rendering kernel with 23-class token semantics and pluggable themes.", "author": "Jie ", "license": "MIT", diff --git a/src/jsray.js b/src/jsray.js index 454124d..d795c05 100644 --- a/src/jsray.js +++ b/src/jsray.js @@ -1865,7 +1865,7 @@ * Runtime version, for shell/core compatibility negotiation. * Must match version.json — tools/check-versions.mjs asserts it. */ - version: '0.0.2-beta.1', + version: '0.0.2-beta.2', languages: G, normalizeLanguage, detectLanguage, diff --git a/tests/contract.test.mjs b/tests/contract.test.mjs index 277d3e2..8219abc 100644 --- a/tests/contract.test.mjs +++ b/tests/contract.test.mjs @@ -393,8 +393,8 @@ test('site: the footer links the integrations that exist and only names the rest // // Both lists move as integrations ship. Moving a name from one to the other // is the deliberate act that publishing it should be. - const PUBLIC = ['jsray-wp']; - const UNPUBLISHED = ['jsray-vscode', 'jsray-terminal']; + const PUBLIC = ['jsray-wp', 'jsray-vscode', 'jsray-terminal']; + const UNPUBLISHED = []; for (const page of ['demo/index.html', 'demo/studio.html']) { const footer = read(page).match(/