mirror of
https://github.com/4gray/iptvnator.git
synced 2026-10-15 05:36:17 -08:00
refactor(portal): move the header Back registry to shared data-access
WorkspaceBackNavigationService is root-provided signal state, which the Nx ownership contract assigns to type:data-access; type:util takes new pure helpers and contracts only. The service and its spec move to @iptvnator/portal/shared/data-access, and the pure WorkspaceBackTarget contract stays in @iptvnator/portal/shared/util. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
c031a150d8
commit
930ef5e6c1
10 files changed
+30
-31
No files matched your search
@@ -25,12 +25,13 @@ catalog scroll positions retain the existing navigation contract below.
|
||||
|
||||
The shell owns the page's Back action, but the workspace header renders it.
|
||||
While `backAvailable()` is true, the shell registers a target with
|
||||
`WorkspaceBackNavigationService` (`@iptvnator/portal/shared/util`): a label (the
|
||||
host's `backLabel`, else the translated "Back"), whether Escape currently runs
|
||||
it, and `run()`, which emits `backClicked`. The service keeps a stack in which
|
||||
the newest registration wins, and each release removes only its own target. A
|
||||
loading shell replaced by the loaded one therefore cannot clear its successor,
|
||||
whichever is destroyed first. The header shows the target as an `arrow_back`
|
||||
`WorkspaceBackNavigationService` (`@iptvnator/portal/shared/data-access`). The
|
||||
target, the `WorkspaceBackTarget` contract in `@iptvnator/portal/shared/util`,
|
||||
carries a label (the host's `backLabel`, else the translated "Back"), whether
|
||||
Escape currently runs it, and `run()`, which emits `backClicked`. The service
|
||||
keeps a stack in which the newest registration wins, and each release removes
|
||||
only its own target. A loading shell replaced by the loaded one therefore
|
||||
cannot clear its successor, whichever is destroyed first. The header shows the target as an `arrow_back`
|
||||
icon button in its leading slot (`data-test-id="workspace-header-back"`), to
|
||||
the right of the macOS traffic lights. That is where desktop apps and Material's
|
||||
top app bar keep navigation. The header never scrolls, so the control stays
|
||||
|
||||
Reference in new issue
Block a user