editor and lsp
This commit is contained in:
@@ -0,0 +1,115 @@
|
||||
---
|
||||
id: PLN-0019
|
||||
ticket: studio-editor-write-wave-supported-non-frontend-files
|
||||
title: Propagate DEC-0010 into Studio editor and VFS specs
|
||||
status: review
|
||||
created: 2026-03-31
|
||||
completed:
|
||||
tags: [studio, editor, vfs, specs, write-wave]
|
||||
---
|
||||
|
||||
## Objective
|
||||
|
||||
Make the controlled non-frontend write wave normative across the Studio and VFS spec corpus before code changes begin.
|
||||
|
||||
## Background
|
||||
|
||||
DEC-0010 locks a new first write wave for non-frontend textual documents, keeps frontend files hard `read-only`, moves access policy and save ownership into `prometeu-vfs`, and requires a local editor command bar rather than the global shell save surface.
|
||||
|
||||
The current Studio/VFS specs still describe the first editor wave as read-only and do not yet express:
|
||||
|
||||
- canonical frontend classification through `FrontendSpec.allowedExtensions`,
|
||||
- VFS-owned access policy,
|
||||
- hard frontend `read-only`,
|
||||
- editor-local `Save` and `Save All`,
|
||||
- or the non-build editorial boundary for in-memory write snapshots.
|
||||
|
||||
## Scope
|
||||
|
||||
### Included
|
||||
- update Studio specs to reflect the controlled write wave
|
||||
- update VFS specification text for canonical frontend scope and access policy
|
||||
- update spec index/read order if document ordering changes
|
||||
|
||||
### Excluded
|
||||
- code implementation
|
||||
- LSP semantic-read phase wording from DEC-0011
|
||||
- any frontend edit-right release
|
||||
|
||||
## Execution Steps
|
||||
|
||||
### Step 1 - Update the Code Editor Workspace Specification
|
||||
|
||||
**What:**
|
||||
Replace the current read-only-first-wave wording with the DEC-0010 controlled write-wave contract.
|
||||
|
||||
**How:**
|
||||
Amend the editor spec so it states:
|
||||
|
||||
- non-frontend supported text classes may be editable,
|
||||
- frontend files remain hard `read-only`,
|
||||
- save actions live in an editor-local command bar,
|
||||
- mixed editable and `read-only` tabs are allowed,
|
||||
- frontend warnings and status-bar presentation are explicit.
|
||||
|
||||
**File(s):**
|
||||
- `docs/specs/studio/5. Code Editor Workspace Specification.md`
|
||||
|
||||
### Step 2 - Update the Project Document VFS Specification
|
||||
|
||||
**What:**
|
||||
Make the VFS spec the normative home for access policy and canonical frontend scope.
|
||||
|
||||
**How:**
|
||||
Amend the VFS spec to state:
|
||||
|
||||
- `FrontendSpec.allowedExtensions` is the source of truth,
|
||||
- VFS must expose a canonical frontend-compatible `typeId` or equivalent scope marker,
|
||||
- VFS owns access policy and save for editable non-frontend documents,
|
||||
- editorial snapshots stay out of build-facing state.
|
||||
|
||||
**File(s):**
|
||||
- `docs/specs/studio/6. Project Document VFS Specification.md`
|
||||
|
||||
### Step 3 - Update Shell-Level and Index Documentation
|
||||
|
||||
**What:**
|
||||
Keep the Studio spec corpus navigable after the write-wave decision lands.
|
||||
|
||||
**How:**
|
||||
Update any shell-level wording and read-order/index docs that still imply the editor is fully read-only.
|
||||
|
||||
**File(s):**
|
||||
- `docs/specs/studio/1. Studio Shell and Workspace Layout Specification.md`
|
||||
- `docs/specs/studio/README.md`
|
||||
|
||||
## Test Requirements
|
||||
|
||||
### Unit Tests
|
||||
- none
|
||||
|
||||
### Integration Tests
|
||||
- none
|
||||
|
||||
### Manual Verification
|
||||
- verify the spec set no longer contradicts DEC-0010 on read-only versus editable scope
|
||||
- verify frontend hard `read-only` and editor-local save surfaces are both explicit
|
||||
- verify build separation for editorial snapshots is stated unambiguously
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- [ ] Studio specs reflect the controlled non-frontend write wave
|
||||
- [ ] VFS specs state `FrontendSpec.allowedExtensions` as source of truth for frontend scope
|
||||
- [ ] editor-local `Save` and `Save All` are normatively placed in the editor, not the shell menu
|
||||
- [ ] hard frontend `read-only` is stated consistently across Studio and VFS specs
|
||||
- [ ] editorial in-memory snapshots are explicitly separated from build-facing state
|
||||
|
||||
## Dependencies
|
||||
|
||||
- DEC-0010 accepted
|
||||
|
||||
## Risks
|
||||
|
||||
- stale read-only wording may remain in sibling specs and confuse implementation
|
||||
- weak wording around canonical frontend scope could reintroduce contract ambiguity
|
||||
- editor-local save surfaces may be described inconsistently if shell docs are not updated
|
||||
@@ -0,0 +1,128 @@
|
||||
---
|
||||
id: PLN-0020
|
||||
ticket: studio-editor-write-wave-supported-non-frontend-files
|
||||
title: Build DEC-0010 VFS access policy and save core
|
||||
status: review
|
||||
created: 2026-03-31
|
||||
completed:
|
||||
tags: [studio, editor, vfs, write-wave, save, access-policy]
|
||||
---
|
||||
|
||||
## Objective
|
||||
|
||||
Implement the VFS-side contract required by DEC-0010: canonical frontend scope, access policy classification, editable snapshots, and save-to-disk ownership.
|
||||
|
||||
## Background
|
||||
|
||||
DEC-0010 makes `prometeu-vfs` the owner of:
|
||||
|
||||
- frontend scope classification from `FrontendSpec.allowedExtensions`,
|
||||
- canonical access policy per supported document,
|
||||
- editable in-memory document snapshots for non-frontend supported text classes,
|
||||
- and save persistence for those documents.
|
||||
|
||||
That work must land before editor UI code can consume the new write-wave behavior safely.
|
||||
|
||||
## Scope
|
||||
|
||||
### Included
|
||||
- add VFS access-policy models
|
||||
- evolve VFS document/type contract so frontend scope is canonical
|
||||
- add snapshot mutation and save operations for editable non-frontend docs
|
||||
- add the document-access context entity reserved by the decision
|
||||
- update and expand VFS tests
|
||||
|
||||
### Excluded
|
||||
- editor command-bar UI
|
||||
- LSP API or semantic-read behavior
|
||||
- frontend editing
|
||||
|
||||
## Execution Steps
|
||||
|
||||
### Step 1 - Extend the Public VFS API
|
||||
|
||||
**What:**
|
||||
Add the public contract needed for access policy, editable snapshots, and save.
|
||||
|
||||
**How:**
|
||||
Extend `prometeu-vfs-api` with:
|
||||
|
||||
- an explicit access-mode model,
|
||||
- canonical frontend scope exposure through `typeId` or equivalent scope marker,
|
||||
- document mutation/update operations for editable docs,
|
||||
- save and save-all oriented commands,
|
||||
- a document-access context entity that can be read and mutated now and persisted later.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-vfs/prometeu-vfs-api/src/main/java/p/studio/vfs/**`
|
||||
|
||||
### Step 2 - Implement the Filesystem-Backed VFS Behavior
|
||||
|
||||
**What:**
|
||||
Teach the filesystem-backed VFS to enforce DEC-0010 semantics.
|
||||
|
||||
**How:**
|
||||
Update the VFS implementation so it:
|
||||
|
||||
- derives frontend scope from `FrontendSpec.allowedExtensions`,
|
||||
- exposes canonical scope information through the VFS contract,
|
||||
- rejects local mutation for hard `read-only` frontend docs,
|
||||
- keeps editable non-frontend session snapshots in memory,
|
||||
- persists those snapshots to disk on save.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-vfs/prometeu-vfs-v1/src/main/java/p/studio/vfs/FilesystemProjectDocumentVfs.java`
|
||||
- `prometeu-vfs/prometeu-vfs-v1/src/main/java/p/studio/vfs/FilesystemProjectDocumentVfsFactory.java`
|
||||
|
||||
### Step 3 - Add Conformance Tests
|
||||
|
||||
**What:**
|
||||
Prove the VFS now owns the right boundary.
|
||||
|
||||
**How:**
|
||||
Add tests that cover:
|
||||
|
||||
- frontend scope classification from `allowedExtensions`,
|
||||
- hard `read-only` refusal for frontend docs,
|
||||
- editable snapshots for non-frontend supported docs,
|
||||
- save persistence,
|
||||
- separation between editorial snapshots and fresh filesystem state where applicable,
|
||||
- access-context lookup and mutation.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-vfs/prometeu-vfs-v1/src/test/java/p/studio/vfs/FilesystemProjectDocumentVfsTest.java`
|
||||
- new `prometeu-vfs/**` test files as needed
|
||||
|
||||
## Test Requirements
|
||||
|
||||
### Unit Tests
|
||||
- access-policy classification
|
||||
- frontend hard `read-only` behavior
|
||||
- editable snapshot update/save behavior
|
||||
- access-context read/mutate behavior
|
||||
|
||||
### Integration Tests
|
||||
- filesystem-backed save roundtrip for editable non-frontend docs
|
||||
|
||||
### Manual Verification
|
||||
- confirm editable non-frontend docs roundtrip through save
|
||||
- confirm frontend docs stay non-mutable at the VFS boundary
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- [ ] VFS exposes canonical access policy for supported documents
|
||||
- [ ] frontend scope derives from `FrontendSpec.allowedExtensions`
|
||||
- [ ] frontend docs are hard `read-only` at the VFS boundary
|
||||
- [ ] editable non-frontend docs have in-memory snapshots and save through VFS
|
||||
- [ ] a single access-context entity exists for current read/mutate demand
|
||||
|
||||
## Dependencies
|
||||
|
||||
- DEC-0010 accepted
|
||||
- PLN-0019 review completed or otherwise stable enough for implementation
|
||||
|
||||
## Risks
|
||||
|
||||
- overloading `typeId` incorrectly could break existing presentation routing
|
||||
- save semantics could leak into frontend scope if access policy is not enforced centrally
|
||||
- snapshot/context modeling could become too broad if it starts anticipating future LSP needs prematurely
|
||||
+136
@@ -0,0 +1,136 @@
|
||||
---
|
||||
id: PLN-0021
|
||||
ticket: studio-editor-write-wave-supported-non-frontend-files
|
||||
title: Integrate DEC-0010 editor write UI and workflow in Studio
|
||||
status: review
|
||||
created: 2026-03-31
|
||||
completed:
|
||||
tags: [studio, editor, ui, save, read-only, write-wave]
|
||||
---
|
||||
|
||||
## Objective
|
||||
|
||||
Make the Studio editor consume the DEC-0010 VFS write contract and expose the intended UI workflow for editable non-frontend documents and hard frontend `read-only` documents.
|
||||
|
||||
## Background
|
||||
|
||||
Once VFS access policy and save behavior exist, the editor still needs to:
|
||||
|
||||
- stop being globally read-only,
|
||||
- surface mixed editable and frontend hard `read-only` tabs correctly,
|
||||
- expose editor-local save commands,
|
||||
- and keep frontend warnings/status consistent with the decision.
|
||||
|
||||
## Scope
|
||||
|
||||
### Included
|
||||
- wire editor UI to new VFS access policy and save commands
|
||||
- add editor-local `Save` and `Save All` command bar
|
||||
- keep frontend docs hard `read-only`
|
||||
- show frontend top warning and status-bar state
|
||||
- update editor tests
|
||||
|
||||
### Excluded
|
||||
- LSP integration
|
||||
- frontend editing
|
||||
- shell-global menu save behavior beyond remaining unused for this flow
|
||||
|
||||
## Execution Steps
|
||||
|
||||
### Step 1 - Rewire Editor Session State Around Access Policy
|
||||
|
||||
**What:**
|
||||
Make the editor session aware of document access mode and save capability.
|
||||
|
||||
**How:**
|
||||
Update open-file/session models so they track:
|
||||
|
||||
- document access mode,
|
||||
- save eligibility,
|
||||
- frontend hard `read-only` state,
|
||||
- and editor-local command enablement.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-studio/src/main/java/p/studio/workspaces/editor/EditorOpenFileBuffer.java`
|
||||
- `prometeu-studio/src/main/java/p/studio/workspaces/editor/EditorOpenFileSession.java`
|
||||
|
||||
### Step 2 - Add the Editor Command Bar and Save Flow
|
||||
|
||||
**What:**
|
||||
Expose the write commands in the editor itself.
|
||||
|
||||
**How:**
|
||||
Add a top command bar or equivalent editor-local surface with `Save` and `Save All`, wired to VFS save operations for editable non-frontend docs only.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-studio/src/main/java/p/studio/workspaces/editor/EditorWorkspace.java`
|
||||
- new `prometeu-studio/src/main/java/p/studio/workspaces/editor/**` command-bar surface as needed
|
||||
- `prometeu-studio/src/main/resources/themes/default-prometeu.css`
|
||||
|
||||
### Step 3 - Enforce Hard Frontend Read-Only in the Editor UX
|
||||
|
||||
**What:**
|
||||
Make frontend files visibly hard `read-only`.
|
||||
|
||||
**How:**
|
||||
Ensure FE files:
|
||||
|
||||
- cannot be mutated in the editor UI,
|
||||
- show `read-only` in the status bar,
|
||||
- show the required top warning,
|
||||
- and can coexist with editable non-frontend tabs without ambiguity.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-studio/src/main/java/p/studio/workspaces/editor/EditorWorkspace.java`
|
||||
- `prometeu-studio/src/main/java/p/studio/workspaces/editor/EditorStatusBar.java`
|
||||
- `prometeu-studio/src/main/java/p/studio/workspaces/editor/EditorTabStrip.java`
|
||||
|
||||
### Step 4 - Update Editor Tests
|
||||
|
||||
**What:**
|
||||
Keep editor tests focused on editor-owned behavior under the new mixed access-mode workflow.
|
||||
|
||||
**How:**
|
||||
Add or adjust tests for:
|
||||
|
||||
- editable non-frontend save command routing,
|
||||
- FE hard `read-only` UI state,
|
||||
- mixed tab behavior,
|
||||
- command enablement.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-studio/src/test/java/p/studio/workspaces/editor/**`
|
||||
|
||||
## Test Requirements
|
||||
|
||||
### Unit Tests
|
||||
- mixed access-mode tab/session behavior
|
||||
- save command enablement
|
||||
- FE hard `read-only` presentation state
|
||||
|
||||
### Integration Tests
|
||||
- editor workspace integration against a VFS test double exposing editable and hard `read-only` docs
|
||||
|
||||
### Manual Verification
|
||||
- open editable `json`/`bash`/`text` docs and confirm save works
|
||||
- open FE docs and confirm they cannot be edited
|
||||
- confirm FE warning and status-bar state are visible
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- [ ] editor consumes VFS access policy instead of local editability inference
|
||||
- [ ] `Save` and `Save All` live in the editor UI
|
||||
- [ ] FE docs are hard `read-only` in actual editor interaction
|
||||
- [ ] mixed editable and FE `read-only` tabs behave coherently
|
||||
- [ ] editor tests cover the new workflow
|
||||
|
||||
## Dependencies
|
||||
|
||||
- DEC-0010 accepted
|
||||
- PLN-0020 review completed or otherwise stable enough for UI integration
|
||||
|
||||
## Risks
|
||||
|
||||
- UI may accidentally permit FE mutation if command enablement and editor mutability diverge
|
||||
- save flow could become split-brained if some callsites bypass editor-local commands
|
||||
- warning/status surfaces may drift if they are implemented independently
|
||||
+102
@@ -0,0 +1,102 @@
|
||||
---
|
||||
id: PLN-0022
|
||||
ticket: studio-editor-write-wave-supported-non-frontend-files
|
||||
title: Propagate DEC-0011 into Studio, VFS, and LSP specs
|
||||
status: review
|
||||
created: 2026-03-31
|
||||
completed:
|
||||
tags: [studio, lsp, vfs, specs, frontend-boundary]
|
||||
---
|
||||
|
||||
## Objective
|
||||
|
||||
Make the frontend read-only minimum LSP phase normative in the Studio/VFS spec corpus and establish the intended LSP contract shape before implementation.
|
||||
|
||||
## Background
|
||||
|
||||
DEC-0011 introduces a dedicated phase:
|
||||
|
||||
- FE remains hard `read-only`,
|
||||
- `prometeu-lsp` consumes VFS snapshots,
|
||||
- the minimum feature set is diagnostics, symbols/outline, definition, and frontend highlight,
|
||||
- non-frontend highlight may remain Studio-local,
|
||||
- and the API should follow flat packaging similar to `prometeu-packer-api`.
|
||||
|
||||
## Scope
|
||||
|
||||
### Included
|
||||
- propagate DEC-0011 into Studio and VFS specs
|
||||
- introduce or update LSP-facing specification text
|
||||
- document flat packaging and minimum LSP scope
|
||||
|
||||
### Excluded
|
||||
- code implementation
|
||||
- frontend edit-right release
|
||||
- completion
|
||||
|
||||
## Execution Steps
|
||||
|
||||
### Step 1 - Update Studio Editor and VFS Specifications
|
||||
|
||||
**What:**
|
||||
Add the new frontend semantic-read phase to the existing Studio/VFS spec set.
|
||||
|
||||
**How:**
|
||||
Amend the relevant specs so they explicitly state:
|
||||
|
||||
- FE remains hard `read-only`,
|
||||
- LSP consumes VFS snapshots,
|
||||
- non-frontend highlight remains local for now,
|
||||
- frontend highlight comes from LSP semantics.
|
||||
|
||||
**File(s):**
|
||||
- `docs/specs/studio/5. Code Editor Workspace Specification.md`
|
||||
- `docs/specs/studio/6. Project Document VFS Specification.md`
|
||||
|
||||
### Step 2 - Introduce an LSP-Focused Studio Specification
|
||||
|
||||
**What:**
|
||||
Create a normative home for the integrated LSP phase.
|
||||
|
||||
**How:**
|
||||
Add a Studio spec that defines:
|
||||
|
||||
- integrated `prometeu-lsp` role,
|
||||
- read-only FE semantic phase,
|
||||
- minimum capability set,
|
||||
- flat packaging expectation,
|
||||
- and explicit non-goals such as completion and frontend editing.
|
||||
|
||||
**File(s):**
|
||||
- new `docs/specs/studio/7. Integrated LSP Semantic Read Phase Specification.md`
|
||||
- `docs/specs/studio/README.md`
|
||||
|
||||
## Test Requirements
|
||||
|
||||
### Unit Tests
|
||||
- none
|
||||
|
||||
### Integration Tests
|
||||
- none
|
||||
|
||||
### Manual Verification
|
||||
- verify no contradiction exists between DEC-0010 and DEC-0011 in the specs
|
||||
- verify the new spec makes the minimum LSP scope and exclusions explicit
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- [ ] the Studio spec set reflects the FE read-only minimum LSP phase
|
||||
- [ ] frontend highlight ownership is clearly separated from Studio-local non-frontend highlight
|
||||
- [ ] LSP flat packaging is stated normatively enough to guide implementation
|
||||
- [ ] completion and frontend edit rights remain explicitly out of scope
|
||||
|
||||
## Dependencies
|
||||
|
||||
- DEC-0011 accepted
|
||||
- DEC-0010 stable enough to provide the underlying VFS/write boundary
|
||||
|
||||
## Risks
|
||||
|
||||
- spec propagation may accidentally imply frontend editing
|
||||
- lack of a dedicated LSP spec could bury too much behavior in editor/VFS docs
|
||||
- packaging guidance may stay too vague if not stated explicitly
|
||||
+110
@@ -0,0 +1,110 @@
|
||||
---
|
||||
id: PLN-0023
|
||||
ticket: studio-editor-write-wave-supported-non-frontend-files
|
||||
title: Scaffold flat-packed prometeu-lsp API and Studio session seams
|
||||
status: review
|
||||
created: 2026-03-31
|
||||
completed:
|
||||
tags: [studio, lsp, api, packaging, session]
|
||||
---
|
||||
|
||||
## Objective
|
||||
|
||||
Create the flat-packed `prometeu-lsp` module surfaces and the Studio/VFS session seams required by DEC-0011 before semantic capabilities are implemented.
|
||||
|
||||
## Background
|
||||
|
||||
`prometeu-lsp` currently exists only as empty Gradle modules.
|
||||
DEC-0011 requires:
|
||||
|
||||
- flat packaging in the style of `prometeu-packer-api`,
|
||||
- a Studio-integrated semantic consumer above VFS,
|
||||
- and a clean session-level seam for opened-document snapshots and closed-document filesystem fallback.
|
||||
|
||||
## Scope
|
||||
|
||||
### Included
|
||||
- scaffold public LSP API packages and contract types
|
||||
- scaffold runtime/v1 module shape
|
||||
- add Studio-side integration seam for a project-session-owned LSP consumer
|
||||
|
||||
### Excluded
|
||||
- actual diagnostics/symbol/definition/highlight logic
|
||||
- frontend editing
|
||||
- completion
|
||||
|
||||
## Execution Steps
|
||||
|
||||
### Step 1 - Create Flat API Surfaces
|
||||
|
||||
**What:**
|
||||
Set up `prometeu-lsp-api` with explicit public package surfaces.
|
||||
|
||||
**How:**
|
||||
Create shallow public packages such as:
|
||||
|
||||
- `dtos`
|
||||
- `messages`
|
||||
- `events`
|
||||
|
||||
along with the top-level service/factory/context contracts needed by Studio.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-lsp/prometeu-lsp-api/src/main/java/**`
|
||||
|
||||
### Step 2 - Create Runtime/V1 Wiring
|
||||
|
||||
**What:**
|
||||
Set up the first concrete implementation module.
|
||||
|
||||
**How:**
|
||||
Add the initial runtime package layout in `prometeu-lsp-v1`, including factory and internal service skeletons that consume `prometeu-vfs` state rather than raw filesystem reads.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-lsp/prometeu-lsp-v1/src/main/java/**`
|
||||
- `prometeu-lsp/prometeu-lsp-v1/build.gradle.kts`
|
||||
|
||||
### Step 3 - Add Studio Session Integration Seams
|
||||
|
||||
**What:**
|
||||
Make room for a project-session-owned LSP consumer in Studio.
|
||||
|
||||
**How:**
|
||||
Introduce or extend Studio project-session types so an integrated LSP consumer can later be constructed from project context and VFS access without changing the architectural owner.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-studio/src/main/java/p/studio/projectsessions/**`
|
||||
- `prometeu-studio/src/main/java/p/studio/window/MainView.java`
|
||||
- `prometeu-studio/src/main/java/p/studio/window/StudioWindowCoordinator.java`
|
||||
|
||||
## Test Requirements
|
||||
|
||||
### Unit Tests
|
||||
- API contract smoke tests where useful
|
||||
- session-seam construction tests
|
||||
|
||||
### Integration Tests
|
||||
- project-session integration test proving Studio can construct LSP scaffold without semantic behavior yet
|
||||
|
||||
### Manual Verification
|
||||
- confirm package layout is shallow and public surfaces are legible
|
||||
- confirm no direct filesystem ownership leaks into Studio UI code
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- [ ] `prometeu-lsp-api` exposes flat public package surfaces
|
||||
- [ ] `prometeu-lsp-v1` contains concrete scaffold wiring above VFS
|
||||
- [ ] Studio has a session seam ready for an integrated LSP consumer
|
||||
- [ ] no semantic feature implementation is required yet for the scaffold to compile
|
||||
|
||||
## Dependencies
|
||||
|
||||
- DEC-0011 accepted
|
||||
- PLN-0022 review completed or otherwise stable enough for contract shape
|
||||
- DEC-0010 major VFS contract direction already stable
|
||||
|
||||
## Risks
|
||||
|
||||
- public API may accidentally mirror internal implementation packages too closely
|
||||
- Studio session ownership could drift if LSP is wired too low in the editor UI
|
||||
- premature semantic helpers may leak into the scaffold plan if scope is not kept tight
|
||||
+120
@@ -0,0 +1,120 @@
|
||||
---
|
||||
id: PLN-0024
|
||||
ticket: studio-editor-write-wave-supported-non-frontend-files
|
||||
title: Implement read-only FE diagnostics, symbols, and definition over VFS snapshots
|
||||
status: review
|
||||
created: 2026-03-31
|
||||
completed:
|
||||
tags: [studio, lsp, diagnostics, symbols, definition, frontend]
|
||||
---
|
||||
|
||||
## Objective
|
||||
|
||||
Implement the non-highlight semantic capabilities of DEC-0011 for read-only frontend documents by consuming VFS snapshots through the integrated LSP seam.
|
||||
|
||||
## Background
|
||||
|
||||
DEC-0011 defines a minimum semantic-read phase for FE documents.
|
||||
This plan focuses on the analysis-driven capabilities that do not depend on frontend highlight/color delivery:
|
||||
|
||||
- diagnostics,
|
||||
- symbols/outline,
|
||||
- and definition.
|
||||
|
||||
The compiler pipeline already exposes `analyze` as a no-write semantic entrypoint suitable for tooling.
|
||||
|
||||
## Scope
|
||||
|
||||
### Included
|
||||
- diagnostics for FE documents
|
||||
- symbol/outline data for FE documents
|
||||
- definition for FE documents
|
||||
- VFS-snapshot-backed analysis for open docs and filesystem fallback for closed docs
|
||||
|
||||
### Excluded
|
||||
- frontend highlight
|
||||
- completion
|
||||
- frontend editing
|
||||
|
||||
## Execution Steps
|
||||
|
||||
### Step 1 - Build Analysis Snapshot Ingestion
|
||||
|
||||
**What:**
|
||||
Connect the integrated LSP runtime to the compiler `analyze` pipeline over VFS-provided document state.
|
||||
|
||||
**How:**
|
||||
Implement the runtime path that:
|
||||
|
||||
- reads open-document snapshot state from VFS,
|
||||
- falls back to filesystem-backed state for closed docs,
|
||||
- produces analysis snapshots,
|
||||
- and keeps build-side persistence out of scope.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-lsp/prometeu-lsp-v1/src/main/java/**`
|
||||
- `prometeu-compiler/prometeu-build-pipeline/**` callsites as needed
|
||||
|
||||
### Step 2 - Expose Diagnostics
|
||||
|
||||
**What:**
|
||||
Surface FE diagnostics through the integrated LSP contracts.
|
||||
|
||||
**How:**
|
||||
Map analysis results into LSP-facing DTOs/messages and ensure Studio consumers can receive them without requiring frontend editing.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-lsp/prometeu-lsp-api/src/main/java/**`
|
||||
- `prometeu-lsp/prometeu-lsp-v1/src/main/java/**`
|
||||
|
||||
### Step 3 - Expose Symbols, Outline, and Definition
|
||||
|
||||
**What:**
|
||||
Provide enough semantic structure for FE read-only navigation.
|
||||
|
||||
**How:**
|
||||
Use analysis facts to expose:
|
||||
|
||||
- document symbols,
|
||||
- workspace symbols,
|
||||
- outline-facing structure,
|
||||
- go-to-definition.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-lsp/prometeu-lsp-api/src/main/java/**`
|
||||
- `prometeu-lsp/prometeu-lsp-v1/src/main/java/**`
|
||||
- `prometeu-studio/src/main/java/p/studio/workspaces/editor/EditorOutlinePanel.java`
|
||||
|
||||
## Test Requirements
|
||||
|
||||
### Unit Tests
|
||||
- analysis snapshot ingestion from open and closed document sources
|
||||
- diagnostics mapping
|
||||
- symbol/definition mapping
|
||||
|
||||
### Integration Tests
|
||||
- end-to-end FE semantic-read test over a project-session VFS snapshot
|
||||
|
||||
### Manual Verification
|
||||
- open FE docs and confirm diagnostics appear
|
||||
- confirm outline/symbol navigation works without unlocking editing
|
||||
- confirm definition resolves from open in-memory docs
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- [ ] FE diagnostics work from VFS-backed analysis
|
||||
- [ ] FE symbols and outline data are available in read-only mode
|
||||
- [ ] go-to-definition works against the same semantic substrate
|
||||
- [ ] open docs use in-memory snapshot state while closed docs can use filesystem fallback
|
||||
|
||||
## Dependencies
|
||||
|
||||
- DEC-0011 accepted
|
||||
- PLN-0023 review completed or otherwise stable enough to provide runtime seams
|
||||
- DEC-0010/editor-session substrate major pieces sufficiently stable
|
||||
|
||||
## Risks
|
||||
|
||||
- analysis ingestion may accidentally bypass VFS and read files directly
|
||||
- outline/symbol shape may drift if not modeled cleanly in API contracts
|
||||
- definition support may require compiler facts not yet surfaced cleanly
|
||||
@@ -0,0 +1,108 @@
|
||||
---
|
||||
id: PLN-0025
|
||||
ticket: studio-editor-write-wave-supported-non-frontend-files
|
||||
title: Implement FE semantic highlight and editor consumption for the read-only LSP phase
|
||||
status: review
|
||||
created: 2026-03-31
|
||||
completed:
|
||||
tags: [studio, lsp, highlight, frontend, editor]
|
||||
---
|
||||
|
||||
## Objective
|
||||
|
||||
Implement frontend highlight delivery through `prometeu-lsp` semantics while leaving non-frontend highlighting Studio-local as DEC-0011 requires.
|
||||
|
||||
## Background
|
||||
|
||||
DEC-0011 explicitly separates highlight ownership:
|
||||
|
||||
- non-frontend highlight may remain local to the Studio editor,
|
||||
- frontend highlight must come from the integrated LSP semantic layer and frontend-owned color semantics.
|
||||
|
||||
This deserves its own plan because it crosses API, runtime, and editor presentation boundaries.
|
||||
|
||||
## Scope
|
||||
|
||||
### Included
|
||||
- FE semantic highlight contracts in LSP
|
||||
- FE semantic highlight production in runtime
|
||||
- editor consumption path for FE highlight
|
||||
- frontend-owned color semantics integration
|
||||
|
||||
### Excluded
|
||||
- non-frontend highlight rewrite
|
||||
- completion
|
||||
- frontend editing
|
||||
|
||||
## Execution Steps
|
||||
|
||||
### Step 1 - Define FE Highlight Contracts
|
||||
|
||||
**What:**
|
||||
Add LSP-facing contracts for semantic highlight delivery.
|
||||
|
||||
**How:**
|
||||
Define DTOs/messages that carry FE semantic highlight spans and any required theme/color semantics without forcing Studio-local token rules onto FE documents.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-lsp/prometeu-lsp-api/src/main/java/**`
|
||||
|
||||
### Step 2 - Implement Runtime Highlight Production
|
||||
|
||||
**What:**
|
||||
Produce FE highlight data from the integrated LSP runtime.
|
||||
|
||||
**How:**
|
||||
Implement the runtime path that derives semantic highlight facts for FE docs from the same read-only analysis substrate used by diagnostics and symbols.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-lsp/prometeu-lsp-v1/src/main/java/**`
|
||||
|
||||
### Step 3 - Consume FE Highlight in the Editor
|
||||
|
||||
**What:**
|
||||
Make the editor choose FE highlight from LSP while leaving other document types on the existing local path.
|
||||
|
||||
**How:**
|
||||
Update editor presentation routing so:
|
||||
|
||||
- FE docs use LSP semantic highlight results and frontend-owned color semantics,
|
||||
- non-FE docs continue using Studio-local highlighting.
|
||||
|
||||
**File(s):**
|
||||
- `prometeu-studio/src/main/java/p/studio/workspaces/editor/EditorDocumentPresentationRegistry.java`
|
||||
- `prometeu-studio/src/main/java/p/studio/workspaces/editor/EditorWorkspace.java`
|
||||
- `prometeu-studio/src/main/java/p/studio/workspaces/editor/syntaxhighlight/**`
|
||||
- `prometeu-studio/src/main/resources/themes/editor/**`
|
||||
|
||||
## Test Requirements
|
||||
|
||||
### Unit Tests
|
||||
- FE highlight DTO/runtime mapping
|
||||
- editor routing between FE LSP highlight and non-FE local highlight
|
||||
|
||||
### Integration Tests
|
||||
- FE document read-only semantic highlight test through Studio + VFS + LSP path
|
||||
|
||||
### Manual Verification
|
||||
- open FE docs and confirm semantic highlight comes from LSP-driven data
|
||||
- open non-FE docs and confirm existing local highlighting still works
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- [ ] FE highlight is produced by the integrated LSP runtime
|
||||
- [ ] FE highlight uses frontend-owned color semantics rather than Studio-local fallback token rules
|
||||
- [ ] non-FE highlighting remains on the existing local Studio path
|
||||
- [ ] editor presentation routing clearly separates FE and non-FE highlight ownership
|
||||
|
||||
## Dependencies
|
||||
|
||||
- DEC-0011 accepted
|
||||
- PLN-0023 review completed or otherwise stable enough for LSP contracts/runtime
|
||||
- PLN-0024 review completed or otherwise stable enough to provide shared FE semantic facts
|
||||
|
||||
## Risks
|
||||
|
||||
- FE highlight could accidentally duplicate or conflict with local Studio token rules
|
||||
- color-semantics contracts may become too UI-coupled if not modeled carefully
|
||||
- editor routing may become fragile if FE and non-FE ownership boundaries are not explicit
|
||||
Reference in New Issue
Block a user