Skip to content

Rewrite v2 history#2486

Draft
balzss wants to merge 58 commits intomasterfrom
rewrite-v2-history
Draft

Rewrite v2 history#2486
balzss wants to merge 58 commits intomasterfrom
rewrite-v2-history

Conversation

@balzss
Copy link
Contributor

@balzss balzss commented Mar 23, 2026

No description provided.

matyasf and others added 30 commits February 3, 2026 15:11
For now it only parses V1 components. It also does not parse components that use the new structure
and there are several CSS errors
INSTUI-4789

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
…ustom/brand icon components and migration codemod
GitHub Pages only supports a single 404.html at the repo root. When
navigating to sub-routes in PR previews (e.g. /pr-preview/pr-123/Button),
the root 404.html was serving the production app instead of the PR
preview build.

A redirect script in index.html detects PR preview paths and redirects
to the PR preview's index.html with the route encoded as a query
parameter. The app entry point restores the original clean URL via
history.replaceState before rendering.
matyasf and others added 25 commits March 16, 2026 13:01
The issue was that wrapLucudeIcon/styles.ts uses px() which uses getFontSize() which uses
document.documentElement.style.fontSize to determine font size, but this is "" by default in
jest-dom, resulting in NaN icon sizes
GitHub Pages only supports a single 404.html at the repo root. Deep
links under subdirectory deployments (/pr-preview/pr-N/ and /latest/)
would serve the root 404.html which loaded the wrong app bundle.

Changes:
- Add redirect script in index.html that detects PR preview and /latest/
  sub-routes and redirects to the subdirectory root with the route
  encoded as a query parameter (__spa_route)
- Restore the original clean URL via history.replaceState on app load
- Add <base href="/"> so relative paths in 404.html resolve from root
- Support PUBLIC_PATH env var in webpack config for subdirectory builds
- Set PUBLIC_PATH=/latest/ for the deploy-latest workflow job
- Add /latest/ as a recognized URL prefix in navigationUtils
getPathInfo() has its own URL parsing separate from navigationUtils'
parseCurrentUrl(). It was missing the /latest/ prefix skip, causing
/latest/v11_7/Menu to be parsed as page="latest" instead of
page="Menu".
…d docs

The version map stored a single componentVersion per package per library
version, determined by the first import found in the export file. This
excluded components that haven't been migrated to v2 (e.g. DateInput2)
from v11_7 docs, because the export file also imports DateInput/v2 and
only that first match was recorded.

Changed to collect all component versions referenced in each export file
so packages with mixed v1/v2 components are correctly included.
… simplify TextInput afterElement

Add condensedSmall and condensedMedium size options to IconButton,
matching Button's existing condensed size support. These are intended
for use inside compact layouts like TextInput.

Remove temporary workarounds from TextInput that were needed to make
the old IconButton work inside the afterElement slot:
- Remove adjustAfterElementHeight DOM hack
- Remove sizeVariants spread on afterElement container
- Remove afterElementHasWidth state machinery
- Simplify afterElement to a basic flex container with padding

Update documentation examples in both IconButton and TextInput READMEs
with a password visibility toggle use case and current icon names.
…s inheritance issues in DateInput and Menu from View
@balzss balzss self-assigned this Mar 23, 2026
@github-actions
Copy link

github-actions bot commented Mar 23, 2026

PR Preview Action v1.8.1

QR code for preview link

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

Built to branch gh-pages at 2026-03-23 18:59 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

@balzss balzss force-pushed the rewrite-v2-history branch from 745a266 to 8ecad37 Compare March 23, 2026 18:54
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.

7 participants