Skip to content

Split Studio into testable stores and service modules #6

Description

@DennisWayo

Problem Statement

The Studio architecture document calls for separate Workspace, Canvas, Inspector, Execution, Governance, Audit, and infrastructure boundaries. The current implementation is functional but heavily concentrated in StudioStore.swift and StudioViews.swift, which makes it harder to evolve SchroSIM from simulator UI into a design tool without regressions.

Proposed Solution

Refactor Studio into explicit modules that match the design-tool architecture:

  • WorkspaceStore
  • CanvasStore
  • InspectorStore
  • ExecutionStore
  • GovernanceStore
  • AuditStore
  • SharedDesignSystem
  • service protocols for compilation, runtime execution, foundry registry, policy checks, audit, and telemetry.

Keep behavior stable while moving logic behind protocols so each area has focused unit tests.

Acceptance Criteria

  • StudioStore becomes an orchestration layer or is replaced by composable stores.
  • Existing Studio behavior still passes tests.
  • New unit tests cover store transitions without launching the full app.
  • The architecture doc is updated with the implemented module paths.
  • No public CLI or runtime JSON schema changes are introduced by the refactor.

Validation

bash scripts/swift-test.sh
swift build --product schrosim-studio

Evidence

  • studio/docs/SWIFTUI_STUDIO_UI_ARCHITECTURE.md
  • core-swift/Sources/schrosim-studio/StudioStore.swift
  • core-swift/Sources/schrosim-studio/StudioViews.swift

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions