Commit afc26a2
fix(plugins): refresh UI registry after install/update/uninstall + replace window.confirm with modal
Two related UX bugs Davidson hit on the v0.1.3 install:
(1) Stale UI registry — sidebar + page bundles pointed at the pre-update
manifest. After installing v0.1.3 over v0.1.2, the sidebar still showed
old labels (Anthropometry, Foods) and the browser fetched
patients.js?v=0.1.2 (404). Cause: hydratePluginUiRegistry runs once on
login and is never refreshed; install/update/uninstall handlers only
re-fetch the plugin list, not the UI registry. Added explicit
hydratePluginUiRegistry(true) calls to:
- PluginInstallModal onInstalled (Plugins.tsx)
- UpdatePreviewModal onApplied (PluginDetail.tsx)
- PluginUninstall onUninstalled (PluginDetail.tsx)
- simple uninstall path after api.delete completes (PluginDetail.tsx)
(2) Native browser confirm popup — uninstall of plugins without
safe_uninstall used window.confirm(), which is unbranded, ugly, and
blocks the page. Replaced with an in-app dark-themed confirm modal that
matches the rest of the app (same styling as the safe_uninstall wizard
header).
Both fixes are frontend-only; no backend or schema change. Direct push
to develop per Davidson's earlier instruction (small UX polish, no PR
overhead needed).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 8b8b88c commit afc26a2
2 files changed
Lines changed: 81 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
14 | 24 | | |
15 | 25 | | |
16 | 26 | | |
| |||
150 | 160 | | |
151 | 161 | | |
152 | 162 | | |
| 163 | + | |
| 164 | + | |
153 | 165 | | |
154 | 166 | | |
155 | 167 | | |
| |||
204 | 216 | | |
205 | 217 | | |
206 | 218 | | |
207 | | - | |
208 | | - | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
209 | 225 | | |
210 | | - | |
211 | | - | |
212 | | - | |
213 | | - | |
214 | | - | |
215 | | - | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
216 | 234 | | |
217 | 235 | | |
218 | 236 | | |
| |||
449 | 467 | | |
450 | 468 | | |
451 | 469 | | |
452 | | - | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
453 | 474 | | |
454 | 475 | | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
455 | 513 | | |
456 | 514 | | |
457 | 515 | | |
| |||
692 | 750 | | |
693 | 751 | | |
694 | 752 | | |
| 753 | + | |
| 754 | + | |
| 755 | + | |
| 756 | + | |
695 | 757 | | |
696 | 758 | | |
697 | 759 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| 9 | + | |
9 | 10 | | |
10 | 11 | | |
11 | 12 | | |
| |||
313 | 314 | | |
314 | 315 | | |
315 | 316 | | |
316 | | - | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
317 | 326 | | |
318 | 327 | | |
319 | 328 | | |
| |||
0 commit comments