refactor(theme): move BusinessTheme out of the engine into examples-support#279
Merged
Merged
Conversation
…upport BusinessTheme and its token bundle (DocumentPalette / SpacingScale / TextScale / TablePreset) are a Gen-2 design-token surface no template takes anymore — only ~17 examples and 3 visual demo tests used it, as a standalone styling source. Move the whole subsystem into examples.support.theme so the engine's public API sheds it; behaviour is unchanged (same code and values, so example renders are identical). git-mv the 5 types + their 2 unit tests into examples.support.theme and repoint the 17 example imports. The 3 engine visual tests cannot import an examples type, so repoint them onto a small engine-test DemoStyles helper (these tests assert a valid render, not a pixel baseline). Drop document.theme from PublicApiNoEngineLeakTest's scan list and the document.api package-info public-API list, and reword the stale BusinessTheme mentions in the chart, layout, and template-api javadoc. Tests: ./mvnw verify javadoc:javadoc -pl . — 1378 tests, 0 failures, javadoc clean; examples compile + the moved unit tests pass; benchmarks + perf-smoke + examples-generation smoke (85) green.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
BusinessTheme+ its token bundle (DocumentPalette/SpacingScale/TextScale/TablePreset) is a Gen-2 design-token surface that no template takes anymore — only ~17 examples + 3 visual demo tests used it, as a standalone styling source. Move it intoexamples.support.themeso the engine's public API sheds it. Behaviour is unchanged (same code + values → example renders identical), so no baselines shift.What (36 files: 7 renames, 2 adds, 1 delete, 26 edits)
examples.support.theme; repoint the 17 example imports. Delete the enginedocument.themepackage-info; add an examples one.testing/visual/DemoStyleshelper (they assert a valid render, not a pixel baseline).document/themefromPublicApiNoEngineLeakTest's scan list and from thedocument.apipackage-info public-API{@link}list (was reference-not-found); reword the stale{@code BusinessTheme}javadoc inchart/ChartDefaults,chart/ChartTheme,layout/package-info,templates/api/DocumentTemplate.The README's
BusinessThemehello-world snippet +DocumentationCoverageTest'scontains("BusinessTheme")are gate-safe (string check passes) and are part of the deferred 3-13 docs pass.Tests
./mvnw verify javadoc:javadoc -pl .— 1378 tests, 0 failures, javadoc clean.examplescompile + the 2 moved unit tests pass; benchmarkstest+ perf-smoke + examples-generation smoke (85) green. japicmp report-only.Note: one local examples layout-snapshot (
EngineDeckLayoutSnapshotTest) fails on Windows — but EngineDeck is untouched by this PR, uses no moved type, and CI doesn't run examples tests (compile + exec only). Pre-existing Windows/Linux drift, unrelated.Follow-ups: (a) the 2 moved unit tests now live in
examples, whose tests CI doesn't run — a CI gap to close (or fold into the render coverage); (b) READMEBusinessThemehello-world rework → 3-13 docs pass.