Commit 543e5b8
committed
feat(side-panel): persist per-tab UI state and restore on tab switch
Introduce per-tab state management for the side-panel. Each browser tab now maintains its own UI state and switching tabs restores the appropriate view. New storage keys scope by tab id and are cleared on close to reset the view for subsequent openings.
Key changes:
- Add tab-scoped storage with keys like sidepanel_state_<tabId>
- Track active tab id alongside URL and use GET_ACTIVE_TAB_INFO fallbacks
- Load saved state on mount/tab switch, defaulting to the plugin grid
- Persist state snapshots on showControlPanel, selectedPlugin, and panelView
- Remove previous URL-derived state logic
- Defensive logging for tabs without IDs and unavailable plugins1 parent ffce83a commit 543e5b8
30 files changed
Lines changed: 239 additions & 123 deletions
File tree
- chrome-extension
- public
- pyodide
- side-panel
- assets
- src/background
- packages
- dev-utils
- env
- hmr
- i18n
- module-manager
- storage
- tailwindcss-config
- tsconfig
- ui
- vite-config
- zipper
- pages
- content-runtime
- content-ui
- content
- devtools
- new-tab
- options
- side-panel
- src
- platform-core/public/pyodide
- public/pyodide
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
Lines changed: 50 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 0 additions & 50 deletions
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
0 commit comments