Skip to content

Make the docs VersionHistory component self-contained so it renders - #112183

Merged
Blargian merged 6 commits into
masterfrom
docs-version-history-self-contained
Jul 27, 2026
Merged

Blargian merged 6 commits into
masterfrom
docs-version-history-self-contained

Conversation

@alexey-milovidov

@alexey-milovidov alexey-milovidov commented Jul 27, 2026 •

Copy link
Copy Markdown
Member

Related: #112177

The version history of a setting is not published anywhere on the documentation site. The autogenerated settings pages emit <VersionHistory rows={...}/> for every setting whose default value changed, but on the deployed pages the component is never defined, so MDX drops it as an unknown component: there is no version-history table in the DOM of any session, MergeTree or format settings page, in any language.

This is visible from the deployed pages themselves. Fetching the raw source of a page and comparing the usages of a component against its inlined definition:

Component <Name usages export const Name
ExperimentalBadge 2 1
SettingsInfoBlock 13 1
VersionHistory 8 0

(https://clickhouse.com/docs/reference/settings/merge-tree-settings/allow.md, checked 2026-07-27; the session and format settings pages behave the same.)

The compiled page confirms it: the components that work appear as _MdxComponentBoundary,{name:'SettingsInfoBlock'} in the payload, whereas the string VersionHistory does not occur anywhere in the page, and neither do Version history or Default value. Between a setting's heading and its description there are only two empty React placeholders.

The only structural difference left between this component and the ones that do get inlined is that it wraps its table in Mintlify's <Accordion>, an identifier it neither imports nor defines. This renders a <details>/<summary> disclosure instead, so the component references nothing outside itself, styled with neutral greys and opacity only — the way SettingsInfoBlock does — so that it reads correctly in both the light and the dark theme. The rows prop keeps its shape, so no page needs to change. The translated copies carry the same fix with the translated headers and title of each locale, and cell alignment is start rather than left so the table also reads correctly in the right-to-left locale.

Things I could not establish, and that are worth confirming on a preview deploy:

  • Why the build rejects this one file is not proven. Three plausible causes were tested against the components that are inlined and ruled out: referencing an undefined Mintlify built-in (Image.jsx references <Frame> the same way and is inlined), a missing trailing newline (11 other components lack one, including Video.jsx), and modern syntax such as ??/?./.map (KBExplorer.jsx uses all three). <Accordion> is what is left. Removing the external reference makes the component robust whatever the cause, but please check a preview build actually shows the table before merging.
  • The appearance is unverified. Each file compiles with esbuild and every element it emits is an intrinsic tag, but I could not run a Mintlify build to look at the result.

Changelog category (leave one):

  • Documentation (changelog entry is not required)

Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):

...

Documentation entry for user-facing changes

  • Documentation is written (mandatory for new features)

Version info

  • Merged into: 26.8.1.240 (included in 26.8 and later)

The version history of a setting is not published anywhere on the
documentation site. The autogenerated settings pages emit
`<VersionHistory rows={...}/>` for every setting whose default value
changed, but on the deployed pages the component is never defined: the
build inlines the other components imported by the same page (for the
MergeTree settings, `ExperimentalBadge` and `SettingsInfoBlock`) as an
`export const`, and does not inline `VersionHistory`. MDX then drops it as
an unknown component, so the compiled page contains no reference to it at
all and no version-history table reaches the DOM. This affects every
session, MergeTree and format settings page, in every language.

The only structural difference left between this component and the ones
that do get inlined is that it wraps its table in Mintlify's `<Accordion>`,
an identifier it neither imports nor defines. Render a `<details>`/
`<summary>` disclosure instead, so the component references nothing outside
itself, and style it with neutral greys and opacity only, the way
`SettingsInfoBlock` does, so that it reads correctly in both the light and
the dark theme. The `rows` prop keeps its shape, so no page needs to change.

The translated copies of the component carry the same fix, keeping the
translated column headers and title of each locale. Cell alignment is
`start` rather than `left` so that the table also reads correctly in the
right-to-left locale.

Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
@clickhouse-gh

clickhouse-gh Bot commented Jul 27, 2026 •

Copy link
Copy Markdown
Contributor

Workflow [PR], commit [ec7be67]

Summary: ✅


AI Review

Summary

This PR makes VersionHistory self-contained and rewrites the English autogenerated settings pages to import it via the named export, which is enough for the English Mintlify preview to start emitting VersionHistory boundaries again. The localized settings trees are still on the old default-import path, and the Arabic preview page still compiles with no VersionHistory boundaries at all, so the PR does not yet satisfy its stated contract of restoring version history "in any language."

Findings

⚠️ Majors

  • [ci/jobs/scripts/docs/autogenerate/autogenerate_docs.py:991] [dismissed by author -- https://github.com/Make the docs VersionHistory component self-contained so it renders #112183#discussion_r3660882763] The fix is only applied to the default-locale settings pages. The repo still contains 1,792 localized settings pages that import VersionHistory via import VersionHistory from "/snippets/<locale>/components/VersionHistory/VersionHistory.jsx";, and the current Mintlify preview for /ar/reference/settings/merge-tree-settings/allow compiles without any _MdxComponentBoundary for VersionHistory while the English preview for /reference/settings/merge-tree-settings/allow has eight of them. That means the version-history tables are still missing on localized settings pages even though the PR body promises the fix "in any language."
    Suggested fix: regenerate or rewrite the localized settings trees in the same change so they use the same import shape as the English pages, then re-check one localized preview page to confirm the VersionHistory boundaries are present.
Final Verdict
  • Status: ⚠️ Request changes

@clickhouse-gh clickhouse-gh Bot added the pr-documentation Documentation PRs for the specific code PR label Jul 27, 2026
@mintlify

mintlify Bot commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
ClickHouse-docs 🟢 Ready View Preview Jul 27, 2026, 8:34 PM

@Blargian

Copy link
Copy Markdown
Member

Checked locally and it's not showing with this change:
image

I'll push a fix now

@mintlify

mintlify Bot commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
ClickHouse-docs 🟡 Building – Jul 27, 2026, 8:09 PM

@Blargian

Copy link
Copy Markdown
Member
image Confirmed working

@Blargian
Blargian enabled auto-merge July 27, 2026 21:08
@Blargian Blargian added the pr-autogenerated-docs PR that regenerates docs artifacts from source; exempt from the autogenerated-region edit guard label Jul 27, 2026
@Blargian
Blargian added this pull request to the merge queue Jul 27, 2026
Merged via the queue into master with commit a342cf7 Jul 27, 2026
178 checks passed
@Blargian
Blargian deleted the docs-version-history-self-contained branch July 27, 2026 22:40
@robot-ch-test-poll4 robot-ch-test-poll4 added the pr-synced-to-cloud The PR is synced to the cloud repo label Jul 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-autogenerated-docs PR that regenerates docs artifacts from source; exempt from the autogenerated-region edit guard pr-documentation Documentation PRs for the specific code PR pr-synced-to-cloud The PR is synced to the cloud repo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants