Skip to content

Rework documentation#2550

Open
git-nandor wants to merge 4 commits into
masterfrom
rework-documentation
Open

Rework documentation#2550
git-nandor wants to merge 4 commits into
masterfrom
rework-documentation

Conversation

@git-nandor

@git-nandor git-nandor commented May 11, 2026

Copy link
Copy Markdown
Contributor

INSTUI-4997

Summary

  • Restructure and extend the documentation site with new theming and upgrade guide pages, fix broken interactive examples and removed outdated pages.
  • Added canvas, canvas-high-contrast, and shared-tokens pages to the theme sidebar
  • Restored color cards on legacy theme pages: rewrote Theme/renderSection() which had a broken early return, now renders four grouped sections (primitives, contrasts, ui, data visualization)
  • Updated ThemeColors grouping to handle both primitive-style names (grey11) and camelCase semantic names (surfacePagePrimary)
  • Added version-aware warning alerts to pages whose examples only work correctly on a specific minor version (with links to switch)
  • Fixed "Default Theme Variables" not rendering for v11.7 components: new theme component tokens are pre-computed at build time (resolveComponents()) since functions are silently dropped by JSON.stringify
  • Fixed "Default Theme Variables" not rendering for props-free child components (e.g. Menu.Separator): renderDetails now falls back to renderTheme when a component has no props/params/returns
  • Fix theme page usage examples not updating on navigation: The Description component compiled its markdown content only in the constructor, causing code examples (e.g. import { light } from '@instructure/ui-themes') to stay stale when navigating between theme pages. Moved compilation to render() so it always reflects the current props.

Co-Authored-By: 🤖 Claude

@git-nandor git-nandor self-assigned this May 11, 2026
@git-nandor git-nandor force-pushed the rework-documentation branch from 5d2192b to add5121 Compare May 11, 2026 14:20
github-actions Bot pushed a commit that referenced this pull request May 11, 2026
@github-actions

github-actions Bot commented May 11, 2026

Copy link
Copy Markdown

Visual regression report

No changes.

Status Count
Unchanged 32
Changed 0
New 0
Removed 0

📊 View full report

Baselines come from the visual-baselines branch. They refresh on every merge to master.

@github-actions

github-actions Bot commented May 11, 2026

Copy link
Copy Markdown
PR Preview Action v1.8.1

QR code for preview link

🚀 View preview at
https://instructure.design/pr-preview/pr-2550/

Built to branch gh-pages at 2026-06-11 17:45 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

@git-nandor git-nandor marked this pull request as ready for review May 12, 2026 07:27
@git-nandor git-nandor force-pushed the rework-documentation branch 2 times, most recently from 408073b to a8a412c Compare May 12, 2026 13:06
github-actions Bot pushed a commit that referenced this pull request May 12, 2026
@git-nandor git-nandor force-pushed the rework-documentation branch from a8a412c to d128181 Compare May 14, 2026 08:12
@git-nandor git-nandor requested a review from hajnaldo May 14, 2026 08:15
hajnaldo

This comment was marked as outdated.

@git-nandor git-nandor force-pushed the rework-documentation branch from d128181 to a65c973 Compare May 14, 2026 12:27
@git-nandor git-nandor force-pushed the rework-documentation branch 2 times, most recently from 1959e8e to 59b7ab8 Compare May 14, 2026 14:00
@git-nandor git-nandor marked this pull request as draft May 15, 2026 09:07
@git-nandor git-nandor marked this pull request as ready for review May 15, 2026 11:32
@git-nandor git-nandor force-pushed the rework-documentation branch from 59b7ab8 to ba6ede5 Compare May 15, 2026 11:36
@git-nandor

This comment was marked as outdated.

@git-nandor git-nandor requested a review from hajnaldo May 15, 2026 12:01
Comment thread docs/guides/using-icons.md Outdated
@joyenjoyer

This comment was marked as outdated.

@joyenjoyer

This comment was marked as resolved.

Comment thread packages/__docs__/buildScripts/DataTypes.mts Outdated
matyasf

This comment was marked as resolved.

@HerrTopi

This comment was marked as resolved.

@HerrTopi

This comment was marked as resolved.

matyasf

This comment was marked as resolved.

@git-nandor git-nandor force-pushed the rework-documentation branch from 66a57b5 to dfad812 Compare May 26, 2026 17:27
@git-nandor git-nandor requested review from joyenjoyer and matyasf May 27, 2026 06:12
@git-nandor git-nandor force-pushed the rework-documentation branch 2 times, most recently from 1f6033a to cdd775d Compare May 27, 2026 12:29

@matyasf matyasf left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, nice work!

@git-nandor git-nandor force-pushed the rework-documentation branch 3 times, most recently from e713885 to ced0fb5 Compare June 2, 2026 12:37
Comment thread packages/__docs__/src/Theme/index.tsx Outdated


> You can read more about how our theming system works and how to use it [here](/#using-theme-overrides)
> You can read more about how our theming system works and how to use it [here](/#legacy-theme-overrides)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This renames the page id using-theme-overrideslegacy-theme-overrides, but the anchor was only updated in a few in-app files. These still point at the now-dead #using-theme-overrides and will render as broken links:

  • packages/ui-themes/README.md
  • packages/emotion/src/withStyleNew.tsx
  • packages/emotion/src/InstUISettingsProvider/README.md
  • packages/ui-link/src/Link/v2/README.md

Same risk for the usageguides-getting-started rename. Could we grep the repo for every renamed page id and fix all inbound links (incl. package READMEs/JSDoc) before merge? A link check over the built docs would catch the rest.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

Comment thread packages/__docs__/src/Theme/index.tsx Outdated
componentDidMount() {
this.props.makeStyles?.()
// Defer color card rendering so the initial page paint is not blocked
requestAnimationFrame(() => this.setState({ showColors: true }))

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This rAF (and the one in componentDidUpdate) is never cancelled. On fast navigation the component can unmount before the frame fires, triggering a setState-on-unmounted warning. Storing the handle and calling cancelAnimationFrame in componentWillUnmount would close that.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

@git-nandor git-nandor requested review from balzss and joyenjoyer and removed request for HerrTopi, ToMESSKa, hajnaldo and joyenjoyer June 10, 2026 12:42
…s, JSDocs and fix for fast theme switch and fix Link theme override example

fix outdated JSDocs. Add the new-theme-overrides entry to LLM summaries. Fix Link v2 themeOverride
example. Fix outdated theme override links. Cancel pending rAF in Theme on unmount/theme switch
@git-nandor git-nandor force-pushed the rework-documentation branch from 1c6da87 to 01baa9e Compare June 11, 2026 14:06
@git-nandor git-nandor requested a review from hajnaldo June 11, 2026 15:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants