Commit 79bc27a
committed
fix(jupyter): replace manual index.html patching with config-based plugin (#114)
The postMessage signal AnalySim relies on to detect when JupyterLite is
ready was injected by patching a manually copied index.html file. Every
jupyter lite build regenerates that file, silently wiping the patch out.
This is why upgrading JupyterLite has historically required manual work.
Changes in this commit:
- analysim_notifier plugin: the postMessage logic now lives in a proper
JupyterLite plugin using app.started, which is the stable API for this.
The plugin survives version upgrades without any manual steps.
- jupyter_lite_config.json: explicit build config so output directory is
always dist/ and no manual steps are needed after building.
- jupyter-lite.json: runtime config for app name and extension settings,
previously absent entirely.
- overrides.json: UI defaults (theme) in one declarative place.
- Consolidated JupyterLiteStorageService: the service existed in two
near-identical copies in admin and project folders. Moved to
app/shared/services/ with old files re-exporting for compatibility.
- Fixed event listener leak in ProjectNotebookItemDisplayComponent:
the window message listener added in ngOnInit was never removed in
ngOnDestroy, causing listeners to accumulate on repeated opens.
Fixes #1141 parent e5e49b3 commit 79bc27a
File tree
9 files changed
+274
-354
lines changed- src/Analysim.Web/ClientApp/src
- app
- admin/components/notebooks/admin-notebook-item/admin-notebook-item-display
- projects/project-overview/project-overview-view/project-content/project-notebook-item/project-notebook-item-display
- assets/jupyter
- analysim_notifier
9 files changed
+274
-354
lines changedLines changed: 3 additions & 49 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | | - | |
3 | | - | |
4 | | - | |
5 | | - | |
6 | | - | |
7 | | - | |
8 | | - | |
9 | | - | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
| 1 | + | |
| 2 | + | |
| 3 | + | |
0 commit comments