Commit cfdaeca
authored
* ci(docs): drift, built-link, and diagnostics-coverage gates for the docsite; pin docs.yml actions; Dependabot scans composite actions (#590 lane E)
website/scripts (plain Node >= 22, no dependencies), wired into the website
`check` script that `pnpm docs:site:build` and docs.yml run:
- check-locale-drift.mjs: every authored en/ page needs a zh/ twin with the
same fenced-code count, the same code per fence (comments stripped in
sh/bash/ts/tsx/js/json fences, trailing `# note` in text tree listings),
the same ABnnnn code set, the same table-row count, and an h2/h3 count
within 2; _meta.json/_nav.json must match in entries, order, and link
targets modulo the /zh prefix. Rspress's languageParity compares only the
set of page paths.
- check-built-links.mjs: post-build walk of doc_build/**/*.html (+ sitemap
<loc>s) resolving every site-internal href/src/og:url honouring cleanUrls
and requiring each #fragment to name an id in the target. Rspress's own
checks see only mdast links, so frontmatter hero/feature links, _nav.json,
raw <a href>, and every generated page were unchecked, and a warm
persistent cache let dead anchors into unchanged pages pass.
- check-diagnostics-coverage.mjs: every ABnnnn cited in website/docs
{en,zh}/**/*.mdx and (strict, `--no-src` to skip) every ABnnnn literal in
packages/agent-bundle/src must have an explicit row, range row, or code
heading in docs/diagnostics.md; family catch-all rows do not count.
website `check` builds with RSPRESS_PERSISTENT_CACHE=false (the variable
@rspress/core reads to disable Rsbuild buildCache) so the anchor checks run
against a cold compile. Drops the two website devDependencies nothing
imports (@types/react-dom, agent-bundle); lockfile regenerated with
`pnpm install --lockfile-only`.
The root `typecheck` now also runs the website tsconfig (config, plugins,
theme), which only `docs:site:build` compiled before.
docs.yml pins actions/checkout, upload-pages-artifact, configure-pages, and
deploy-pages to full commit SHAs (job name unchanged; it is a required
check). dependabot.yml scans /.github/actions/* so the composite
setup-workspace action's pnpm/setup pin is updated too.
* docs(site): feed twoslash from tsconfig.typedoc.json paths, SSG worker, sidebar/nav tidy-ups (#590 lane A2)
- rspress.config.ts reads `compilerOptions.paths` from tsconfig.typedoc.json
(JSONC, via ts.readConfigFile), makes the targets absolute, and merges them
with the four `agent-bundle*` entries for pluginTwoslash, so
`@agent-bundle/runtime*` and `rsc-markdown-stream` resolve to workspace
sources without `pnpm build`. The 12 `: any` hovers on
guide/development/testing (en + zh) are gone; the tsconfig comment now
states that this file is the single source of the map.
- ssg.experimentalWorker: true; builderConfig.performance.printFileSize.detail: false.
- head: static theme-color meta. Per-route canonical/og:url functions are
left out: renderPages passes config.head to the SSG worker threads through
workerData, and a function fails structured cloning (DataCloneError).
- themeConfig.footer: Apache-2.0 message (home layout).
- Remove transformerNotationDiff/Focus (no [!code ++/--/focus] in docs) and
search.codeBlocks (restates the default); TypeDoc index title template
drops the empty {version} placeholder.
- api/_meta.json: collapsed: true on the six dir groups, both locales.
- _nav.json: "Type API" links to the hand-written /reference/api overview;
activeMatch covers /api/ and /reference/api, both locales.
- mirror-api-locale: per-target `notice`, inserted as an :::info container
directly under the title of every mirrored zh/api page.
- docs/public/robots.txt with the sitemap URL.
* docs(diagnostics): document every emitted AB0000–AB5999 code explicitly
Add explicit rows for the 103 emitted codes in AB3000–AB4716 that were
covered only by a family catch-all (AB30xx, AB40xx–AB46xx, AB470x/AB471x),
plus dedicated sections for AB4500 and AB5000, whose only mention was the
Code families summary row. New sections sit after the Code families table.
Adds the missing AB4204 and AB5000 rows; gives AB4716 a table row in its
Declaration generation section; folds the AB4834 recovery text into its
Trigger cell so the row matches its three-column header (GFM was dropping
the fourth cell). Every emitted code in AB0000–AB5999 now has an explicit
row; no ragged table rows remain in the file.
Refs #590
* docs(en): accuracy fixes, description lengths, and fence reflow for #590 (lane C)
- reference/cli: exit-code rows 1/2 state which option validators throw
Commander InvalidArgumentError (exit 2) versus a plain TypeError reported
as one AB5000 diagnostic (exit 1), per src/cli.ts and runCli.
- guide/authoring/hooks: result-contract table and per-event bullets match
hook-handler.ts / hook-contract.ts — no event admits outcome 'stop',
Cursor alone tolerates a denying agentStart, only Claude carries
additionalContext from agentStop.
- reference/configuration: targets defaults to ['portable'], marketplace to
false; evals and routes ride the AgentBundleConfig index signature, evals
rules fire as EVAL_* errors when an eval or the Workbench loads the config.
- Tighten 13 en frontmatter descriptions to <=160 code points.
- Reflow every fenced code line over 90 columns in en (36 -> 0) and mirror
the identical reflow in the zh twin fences (28 -> 0); zh prose untouched.
* docs(zh): mirror #590 accuracy fixes — CLI exit code 2 scope, hook result contract, config defaults and untyped evals/routes
Chinese twins of the lane-C English corrections for the docsite audit:
- reference/cli.mdx: exit code 2 is only a Commander error (unknown option,
missing argument, InvalidArgumentError from --profile/--allow/doctor --host);
the install <host>/--scope/--mode/--port/--trials validators throw a plain
TypeError that runCli reports as one AB5000 diagnostic with exit 1.
- guide/authoring/hooks.mdx: outcome is continue or deny (no event accepts
stop); agentStop additionalContext is rejected on Codex and Cursor, only
Claude Code carries it; the typed contract rejects an agentStart denial
while Cursor's wrapper tolerates one with a reason.
- reference/configuration.mdx: targets defaults to ['portable'] (--target
overrides), marketplace defaults to false; evals and routes ride the
index signature so tsc does not check them — evals rules fire at eval time
(EVAL_CONFIG_INVALID), routes overrides are validated during route
discovery and reported through validateSource.
Prose only; no fenced code block, heading, table row, or AB code set changed.
* docs(website): nav matcher excludes reference/api; drift check normalises regex alternatives
* docs(diagnostics): document every emitted AB6000–AB9999 code (#590, lane B2)
Add explicit rows or explicit ranges for the 121 agent-bundle codes in
AB6000–AB9999 that only a family row covered: built-artifact validation
(AB6000–AB6004, AB6006–AB6018, AB6023–AB6025), Workbench artifact
inspection (AB6200–AB6202), install/uninstall and project-preparation
codes (AB7000–AB7004), the AB7103 package-build warning, the whole
AB80xx development-server surface grouped by route module, the
route-manifest client code AB8123, and the eval API refusals
AB9001–AB9005/AB9007–AB9011. Refine the AB6xxx–AB9xxx family rows.
AB6005 is left untouched for PR #588.
* fix(website): patch @rspress/core LocalProvider.init to await FlexSearch indexing (#590)
LocalProvider.init() fired addAsync() for every document without awaiting,
so SearchPanel flipped initStatus to 'inited' while FlexSearch was still
indexing and an early query rendered 'No matching results' for documents
that had not been added yet (8/8 trials with a late-indexed query on the
971-document en index). Collect the three addAsync promises per item and
await them before init() resolves; PageSearcher hard-codes the provider, so
a pnpm patch is the smallest fix. Upstream main still has the bug.
* fix(website): edit links, llms rows, 404 trailing slash, and code width in the docsite theme (#590)
- EditLink: return null on TypeDoc pages (<lang>/api/**), point the
generated reference pages at their sources (capabilities JSON directory
for hosts/events/notices, docs/diagnostics.md for diagnostics), and defer
to the original everywhere else. The patterns track .gitignore lines 20-27.
- LlmsCopyRow / LlmsOpenRow / LlmsHint: render nothing when the route path
includes /api/, mirroring the pluginLlms exclude, so the outline no longer
offers Copy Markdown / Open in chat for the 1,832 routes that have no
Markdown twin.
- NotFoundLayout: cleanUrls emits quick-start.html, so a trailing-slash URL
is a 404 on GitHub Pages; retry without the slash (query and hash kept).
- Desktop layout tokens (>= 1280px): sidebar 320 -> 280, outline 268 -> 240,
content padding 80 -> 48. At 1440x900 the code scroller grows from 686 to
818 px, so 92 monospace columns fit (was 76 once Shiki's line padding is
paid) and a 90-column line no longer scrolls; overflowing fences on the 33
authored en pages drop from 59/169 to 23/169, all of them >= 93 columns.
* docs(diagnostics): explicit AB6005 row (restates #588) so every emitted code has a row
* changeset: diagnostics contract rows (#599)
* docs(diagnostics): shorten the install-receipt placeholder so the fence fits 90 columns
* chore(patches): cite upstream rspress#3658 beside the @rspress/core patch
* review: built-link check rejects targets outside doc_build; changeset says recovery where the diagnostic carries one
1 parent 1fb100f commit cfdaeca
51 files changed
Lines changed: 1716 additions & 197 deletions
File tree
- .changeset
- .github
- workflows
- docs
- patches
- website
- docs
- en
- api
- examples
- guide
- authoring
- development
- distribution
- start
- reference
- public
- zh
- api
- guide
- authoring
- development
- distribution
- start
- reference
- plugins
- scripts
- styles
- theme
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
9 | 13 | | |
10 | 14 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
47 | 50 | | |
48 | | - | |
| 51 | + | |
49 | 52 | | |
50 | 53 | | |
51 | 54 | | |
52 | 55 | | |
53 | 56 | | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
58 | 63 | | |
59 | 64 | | |
60 | 65 | | |
61 | | - | |
| 66 | + | |
62 | 67 | | |
63 | 68 | | |
64 | 69 | | |
| |||
96 | 101 | | |
97 | 102 | | |
98 | 103 | | |
99 | | - | |
| 104 | + | |
100 | 105 | | |
101 | 106 | | |
102 | | - | |
| 107 | + | |
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
25 | | - | |
| 25 | + | |
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
24 | | - | |
25 | | - | |
| 24 | + | |
| 25 | + | |
26 | 26 | | |
27 | 27 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
| 7 | + | |
7 | 8 | | |
8 | 9 | | |
9 | 10 | | |
10 | 11 | | |
11 | | - | |
| 12 | + | |
| 13 | + | |
12 | 14 | | |
13 | 15 | | |
14 | 16 | | |
15 | 17 | | |
16 | | - | |
| 18 | + | |
| 19 | + | |
17 | 20 | | |
18 | 21 | | |
19 | 22 | | |
20 | 23 | | |
21 | | - | |
| 24 | + | |
| 25 | + | |
22 | 26 | | |
23 | 27 | | |
24 | 28 | | |
25 | 29 | | |
26 | | - | |
| 30 | + | |
| 31 | + | |
27 | 32 | | |
28 | 33 | | |
29 | 34 | | |
30 | 35 | | |
31 | | - | |
| 36 | + | |
| 37 | + | |
32 | 38 | | |
33 | 39 | | |
0 commit comments