Skip to content

Commit d474150

Browse files
authored
feat(docs): guided adoption IA — theme, hubs, section folders, and redirects (#121)
Switch the docs theme to sphinx-immaterial with Databricks styling, landing/quick-start IA, and native version dropdown. Restructure sources into section folders (get-started, architecture, build, deploy, features, contributors, samples) with redirect stubs so legacy URLs keep working; unify Deploy and refresh Build/Features navigation (job-based Features hub, Patterns catalog, spec-before-patterns ordering). Replace static pattern PNGs with lf-arch Mermaid flowcharts and client-side rendering; standardize feature-page chrome, US English spelling, and guided-adoption content (Quick Start, CI/CD layout, architecture diagram, config-inheritance callout). Fix multiversion builds: per-tag conf cutover at v0.21.0, shared versions.json back to v0.12, immaterial version_json resolution, search on flat builds, CI lockfile/spelling, header logo, version-selector stacking, and dark-mode link colors.
1 parent 0413086 commit d474150

165 files changed

Lines changed: 14294 additions & 5057 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
.databricks/
2-
build/
2+
/build/
3+
docs/build/
34
dist/
45
__pycache__/
56
*.egg-info

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
v0.20.0
1+
v0.21.0

docs/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ spelling:
3535
html-multiversion:
3636
@./scripts/build_versioned_docs.sh
3737

38-
# Local preview build including all local branches.
38+
# Local preview build: current branch as local-branch-preview (current stays main).
3939
html-multiversion-preview:
4040
@./scripts/build_versioned_docs.sh --preview
4141

docs/README.md

Lines changed: 34 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ This folder contains the Sphinx documentation source and build tooling for local
99
- [Multiversion Implementation (No sphinx-multiversion)](#multiversion-implementation-no-sphinx-multiversion)
1010
- [What Gets Built](#what-gets-built)
1111
- [Version Selection Rules](#version-selection-rules)
12-
- [How the Sidebar Switcher Works](#how-the-sidebar-switcher-works)
12+
- [How the Version Dropdown Works](#how-the-version-dropdown-works)
1313
- [Purge and Rebuild Behavior](#purge-and-rebuild-behavior)
1414
- [Local Build and Testing](#local-build-and-testing)
1515
- [GitHub Pages Deployment](#github-pages-deployment)
@@ -40,7 +40,7 @@ The `docs/Makefile` supports these explicit targets:
4040
- `make html-multiversion`
4141
- Builds versioned docs without `sphinx-multiversion` using `scripts/build_versioned_docs.sh`.
4242
- `make html-multiversion-preview`
43-
- Same as above, plus local branches for preview/testing.
43+
- Same as above, plus the current git branch as `local-branch-preview`.
4444

4545
Catch-all behavior is enabled:
4646

@@ -59,6 +59,10 @@ Versioned docs are generated by:
5959

6060
- `main` branch is always built and published as `current`.
6161
- Selected release tags are built from git tags.
62+
- **Docs IA cutover at v0.21.0:**
63+
- **`current` and tags `>= v0.21.0`** use **main's** `docs/conf.py` with that ref's `docs/source` (sphinx-immaterial / section-folder IA).
64+
- **Tags `<= v0.20.x`** use **`v0.20.0`'s** `docs/conf.py` (RTD / flat layout) with each tag's own `docs/source`.
65+
- **`local-branch-preview`** (optional) uses the current branch's own conf + source (pre-merge validation).
6266
- Output layout:
6367
- `docs/build/html/current/index.html`
6468
- `docs/build/html/vX.Y.Z/index.html`
@@ -70,9 +74,10 @@ Versioned docs are generated by:
7074
`scripts/select_versions.py` applies these rules:
7175

7276
1. Identify the highest major version present in tags.
73-
2. Include the latest patch release for the last 5 minor series in that major.
74-
3. Include the latest available release for each of the last 3 majors.
75-
4. De-duplicate and sort descending (newest first).
77+
2. For major `0`, include the latest patch release for every minor from the current minor down to `0.12` (inclusive).
78+
3. For other majors, include the latest patch release for the last 5 minor series in that major.
79+
4. Include the latest available release for each of the last 3 majors.
80+
5. De-duplicate and sort descending (newest first).
7681

7782
Example ordering:
7883

@@ -82,13 +87,27 @@ Example ordering:
8287
- `v0.14.0`
8388
- `v0.13.0`
8489
- `v0.12.1`
90+
- … through `v0.12.x` when older minors exist
8591

86-
### How the Sidebar Switcher Works
92+
### How the Version Dropdown Works
8793

88-
- `scripts/build_versioned_docs.py` writes `versions.json` with `name`, `url`, and `is_latest`.
89-
- `docs/conf.py` loads this manifest via `DOCS_VERSIONS_FILE`.
90-
- `docs/_templates/versions.html` renders the version list in the RTD sidebar.
91-
- Links target `.../index.html` explicitly to avoid directory-listing behavior in local `file://` browsing.
94+
- `scripts/build_versioned_docs.py` writes a **superset** `versions.json` with:
95+
- mike / sphinx-immaterial fields: `version`, `title`, `aliases`
96+
- legacy RTD fields: `name`, `display_version`, `url`, `status`, `is_latest`, `release_date`
97+
- RTD-era refs load the manifest at build time via `DOCS_VERSIONS_FILE` into `versions.html`.
98+
- Immaterial refs enable `version_dropdown` and fetch the parent `../versions.json` over HTTP (`version_json` in `conf.py`).
99+
- Use a local HTTP server to test the immaterial switcher (see below).
100+
101+
### Preview builds
102+
103+
```bash
104+
make -C docs html-multiversion-preview
105+
```
106+
107+
- Still publishes `current` from `main`.
108+
- Also builds the **current git branch** once as `local-branch-preview` (skipped if you are on `main` or detached HEAD).
109+
- To review a feature branch before merge, check it out, run preview, then select `local-branch-preview` in the version menu.
110+
- Preview builds from the **working tree** (uncommitted conf/theme/source edits are included).
92111

93112
## Purge and Rebuild Behavior
94113

@@ -122,7 +141,7 @@ make -C docs spelling
122141
make -C docs html-multiversion
123142
```
124143

125-
1. If you need to test branch previews in the version menu:
144+
1. If you need to preview the current branch against `main` / release tags:
126145

127146
```bash
128147
make -C docs html-multiversion-preview
@@ -132,7 +151,7 @@ Practical rule of thumb:
132151

133152
- Doc text/layout change only: `html` + `spelling`
134153
- Versioning/switcher/build-script change: `html` + `spelling` + `html-multiversion`
135-
- Branch preview verification: add `html-multiversion-preview`
154+
- Branch theme/IA preview: `html-multiversion-preview`, then select `local-branch-preview`
136155

137156
### Open docs
138157

@@ -145,7 +164,9 @@ cd docs/build/html
145164
python3 -m http.server 8000
146165
```
147166

148-
Then open [http://localhost:8000](http://localhost:8000).
167+
Then open [http://localhost:8000/current/index.html](http://localhost:8000/current/index.html) to exercise the version dropdown.
168+
169+
Note: `make html` builds a single-version tree without a parent-level `versions.json`; use `html-multiversion` to test version switching.
149170

150171
## GitHub Pages Deployment
151172

0 commit comments

Comments
 (0)