Skip to content

T-5: Introduce WindowFeature reducer per window #198

@kirich1409

Description

@kirich1409

Part of EPIC #193. Depends on #194, #197.

Description

Create a new WindowFeature reducer with @ObservableState State { windowID, route: Welcome | Main, closeAlert, serverList?, cloudNavigation? }. Move the Route enum and the per-window sheets out of AppFeature into WindowFeature. MainFeature and WelcomeFeature become children under WindowFeature. Refactor AppFeature.State to hold windows: IdentifiedArrayOf<WindowFeature.State> (MVP ships with one element — enables multi-window without regressing single-window flow). Composition: AppFeature → ForEach(\.windows, action: \.windows) { WindowFeature() }. AppFeature retains only global concerns: projectRegistry (lookup ProjectID → WindowID).

Acceptance Criteria

  • WindowFeature.State has a stable windowID: UUID
  • AppFeature.State.windows is an IdentifiedArrayOf with an initial count of 1
  • Reducer composition compiles, passes build + lint
  • Existing single-window flow works identically — no user-visible regressions
  • Unit tests for WindowFeature.Action (set route, show alert, close)
  • Integration test: one-window flow end-to-end (Welcome → OpenProject → Close → Welcome)

Module / Layer

Relay / AppFeature (new child: WindowFeature)

Complexity

Large

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions