Skip to content

fix: re-mount canvas CanvasProvider on breadcrumb navigation so custom themes apply#9137

Open
ericokuma wants to merge 1 commit intomainfrom
ericokuma/app-813-fix-custom-theme-breadcrumb-navigation
Open

fix: re-mount canvas CanvasProvider on breadcrumb navigation so custom themes apply#9137
ericokuma wants to merge 1 commit intomainfrom
ericokuma/app-813-fix-custom-theme-breadcrumb-navigation

Conversation

@ericokuma
Copy link
Copy Markdown
Contributor

  • Canvas pages keyed only on instanceId, so breadcrumb navigation between canvases never re-mounted the provider tree — the destination canvas's theme was never initialised
  • Include canvasName in the {#key} expression (matching explore pages' {#key exploreName} pattern) across cloud, local, and embed canvas routes
  • Clear themeManager CSS-variable cache in ThemeProvider whenever theme CSS changes, preventing stale colour lookups in chart specs

Closes APP-813

Checklist

  • Tested on cloud
  • Tested on local (Rill Developer)
  • Tested embedded canvas
  • Verified no theme bleed between differently-themed canvases
  • Verified direct URL access still works

Developed in collaboration with Claude Code

…tom themes apply

Canvas pages keyed their component tree only on `runtimeClient.instanceId`, which
doesn't change when navigating between canvases in the same project. This meant
breadcrumb navigation reused the old `CanvasProvider` tree and the destination
canvas's theme was never initialised.

Include `canvasName` in the `{#key}` expression (matching the pattern explore pages
already use with `{#key exploreName}`) so the entire provider tree re-mounts on
every canvas switch. Also clear the `themeManager` CSS-variable cache inside
`ThemeProvider` whenever theme CSS changes, preventing stale colour lookups in
chart specs.

Closes [APP-813](https://linear.app/rilldata/issue/APP-813)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@ericokuma ericokuma force-pushed the ericokuma/app-813-fix-custom-theme-breadcrumb-navigation branch from 043885d to d5c46e4 Compare March 28, 2026 00:16
@ericokuma ericokuma requested a review from djbarnwal March 28, 2026 01:12
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.

1 participant