Some checks failed
PR Fast Feedback / fast-feedback (pull_request) Failing after 3m42s
Implemented the output resolution guidance for the customer review workspace and internal views. Added ReviewPackOutputResolutionGuidance, updated CustomerReviewWorkspace and EnvironmentReviewResource, and added related blade views and tests.
14 KiB
14 KiB
Implementation Plan: Spec 349 - Customer Review Workspace Output Resolution Guidance
Branch: 349-customer-review-workspace-output-resolution-guidance | Date: 2026-06-03 | Spec: specs/349-customer-review-workspace-output-resolution-guidance/spec.md
Input: User-provided Spec 349 draft + repo truth from current Spec 347 readiness work, current Customer Review Workspace runtime, and current Environment Review detail surface.
Summary
Translate existing Review Pack output-readiness truth into calmer operator guidance without changing the underlying workflow model.
This slice should:
- reuse current
ReviewPackOutputReadinesstruth - convert the highest-priority limitation into one dominant blocker and one dominant next action
- group remaining limitations into compact disclosure
- qualify download wording honestly
- surface PII/internal-only boundaries explicitly
- separate review publication/completeness from output readiness on Environment Review detail
This slice must not:
- create persistence
- create a new workflow engine or state machine
- reopen Review Pack generation semantics beyond the already-completed Spec 347 contract
- build a portal or renderer
- weaken current authorization, workspace isolation, or signed-download safety
Technical Context
- Language/Version: PHP 8.4.15, Laravel 12.52.x
- Primary Dependencies: Filament 5.2.x, Livewire 4.1.x, Pest 4, Tailwind CSS 4
- Storage: PostgreSQL; no schema change expected
- Testing: Pest Feature/Livewire tests plus one bounded Pest Browser smoke file
- Validation Lanes: confidence + browser
- Target Platform:
apps/platformLaravel monolith; Sail-first locally; Dokploy posture unchanged - Project Type: web application with server-rendered Filament/Blade surfaces
- Performance Goals: no new remote calls during render, no new queue family, and no duplicate read-model layer beyond a bounded derived guidance adapter
- Constraints: no false customer-safe wording, no warning wall, no hidden shell-scope behavior, no new route family, no new persisted guidance state, and no detail-surface redesign outside the output-guidance slice
- Scale/Scope: one strategic workspace surface, one review detail surface, existing review-pack proof/download path, focused Feature coverage, and one Browser smoke
UI / Surface Guardrail Plan
- Guardrail scope: material change to an existing strategic customer-safe review surface plus an existing review detail surface
- Affected routes/pages/actions/states/navigation/panel/provider surfaces:
/admin/reviews/workspaceapps/platform/app/Filament/Pages/Reviews/CustomerReviewWorkspace.phpapps/platform/resources/views/filament/pages/reviews/customer-review-workspace.blade.phpapps/platform/app/Filament/Resources/EnvironmentReviewResource.phpapps/platform/app/Filament/Resources/EnvironmentReviewResource/Pages/ViewEnvironmentReview.php- existing review-pack download wording as reached from those surfaces
- No-impact class, if applicable: N/A
- Native vs custom classification summary: native Filament page/resource plus existing Blade/infolist composition; no new route or panel/provider
- Shared-family relevance: status messaging, next-action guidance, disclosure, proof links, qualified download wording
- State layers in scope: page payload, detail payload, URL-query filter on workspace, derived output-guidance payload only
- Audience modes in scope: operator-MSP, customer-safe review consumer, support where authorized
- Decision/diagnostic/raw hierarchy plan: one output verdict first, grouped limitations second, technical details third
- Raw/support gating plan: keep technical details collapsed or clearly secondary; keep support/raw detail capability-gated where already applicable
- One-primary-action / duplicate-truth control: preserve one dominant next action and remove repeated blocker summaries from lower panels
- Handling modes by drift class or surface: review-mandatory
- Repository-signal treatment: review-mandatory because this is a strategic trust surface
- Special surface test profiles:
global-context-shell+shared-detail-family - Required tests or manual smoke: functional-core + browser smoke
- Exception path and spread control: one bounded guidance adapter is allowed; no cross-domain framework
- Active feature PR close-out entry: Guardrail / Smoke Coverage
- UI/Productization coverage decision: update
docs/ui-ux-enterprise-audit/page-reports/ui-006-customer-review-workspace.md; add a second report only if implementation proves the existing identity cannot absorb the detail-surface notes cleanly - Coverage artifacts to update: existing workspace page report only unless repo truth later proves more is required
- Navigation / Filament provider-panel handling: N/A; no panel/provider change expected
- Screenshot or page-report need: yes, because this is a strategic customer-safe surface and one bounded browser smoke will produce proof artifacts
Shared Pattern & System Fit
- Cross-cutting feature marker: yes
- Systems touched:
App\Support\ReviewPacks\ReviewPackOutputReadinessApp\Filament\Pages\Reviews\CustomerReviewWorkspaceApp\Filament\Resources\EnvironmentReviewResourceApp\Filament\Resources\EnvironmentReviewResource\Pages\ViewEnvironmentReview- existing review-pack and evidence link helpers
- Shared abstractions reused:
- current limitation codes and readiness fields from
ReviewPackOutputReadiness - current workspace link/action helper paths
- current Environment Review artifact-truth and summary presentation
- current limitation codes and readiness fields from
- New abstraction introduced? why?: maybe one narrow
ReviewPackOutputResolutionGuidance-style adapter if direct extension ofReviewPackOutputReadinesswould blur raw output truth and UI guidance responsibilities - Why the existing abstraction was sufficient or insufficient: current readiness truth is sufficient as the source, but it is not yet shaped for grouped operator guidance across multiple surfaces
- Bounded deviation / spread control: any new guidance adapter must remain local to review output guidance and must not become a generic workflow-resolution framework
OperationRun UX Impact
- Touches OperationRun start/completion/link UX?: existing proof-link usage only
- Central contract reused: existing Review Pack / Environment Review proof links
- Delegated UX behaviors: unchanged
- Surface-owned behavior kept local: one-blocker ranking, grouped limitation copy, and qualified next-action wording
- Queued DB-notification policy: unchanged
- Terminal notification path: unchanged
- Exception path: none
Provider Boundary & Portability Fit
- Shared provider/platform boundary touched?: no new provider seam
- Provider-owned seams: N/A
- Platform-core seams: output readiness, customer-safe/internal-only/blocked guidance vocabulary
- Neutral platform terms / contracts preserved: review pack, evidence basis, limitation, customer-safe, internal-only, next action
- Retained provider-specific semantics and why: only where current review/evidence text already carries provider-backed content
- Bounded extraction or follow-up path: none
Current Repo Truth Summary
App\Support\ReviewPacks\ReviewPackOutputReadinessalready derives:readiness_statecustomer_safe_stateprimary_reasonprimary_actionlimitationssection_summary
CustomerReviewWorkspacealready folds that truth into:effectiveWorkspaceReadinessState()workspaceReadinessLabel()workspaceReadinessReason()workspaceReadinessImpact()workspaceReadinessActions()- current decision card and proof-panel payloads
- Current workspace gaps:
- no grouped limitation list tied to one dominant blocker
- no explicit technical-details disclosure contract for output guidance
- existing primary/secondary action mapping is still spread across multiple helper methods
EnvironmentReviewResource/ViewEnvironmentReviewalready own the detail surface:- infolist sections for outcome summary, review, executive posture, and sections
- customer-workspace mode that narrows header actions
- no explicit summary block separating review publication/completeness from output-readiness/sharing state
- Route truth is already stable and workspace/environment scoped; no new route family is needed
- Existing page audit identity is
ui-006-customer-review-workspace.md
Implementation Approach
Phase 0 - Repo Truth Gate
- Re-read the prepared
spec.md,plan.md,tasks.md,repo-truth-map.md, andchecklists/requirements.mdbefore runtime edits. - Re-check current runtime truth in:
apps/platform/app/Support/ReviewPacks/ReviewPackOutputReadiness.phpapps/platform/app/Filament/Pages/Reviews/CustomerReviewWorkspace.phpapps/platform/resources/views/filament/pages/reviews/customer-review-workspace.blade.phpapps/platform/app/Filament/Resources/EnvironmentReviewResource.phpapps/platform/app/Filament/Resources/EnvironmentReviewResource/Pages/ViewEnvironmentReview.php
- Keep
specs/349-customer-review-workspace-output-resolution-guidance/repo-truth-map.mdcurrent if runtime inspection reveals additional bounded truth.
Phase 1 - Tests First
- Add focused guidance tests before runtime refactor:
apps/platform/tests/Feature/ReviewPack/Spec349ReviewPackResolutionGuidanceTest.phpapps/platform/tests/Feature/Filament/Spec349CustomerReviewWorkspaceOutputGuidanceTest.phpapps/platform/tests/Feature/EnvironmentReview/Spec349EnvironmentReviewOutputGuidanceTest.phpapps/platform/tests/Browser/Spec349OutputResolutionGuidanceSmokeTest.php
- Lock the following before runtime changes:
- one primary output state
- one primary next action
- grouped limitation disclosure
- qualified download wording
- explicit PII/internal-only warning
- collapsed technical details by default
- review detail separation of status dimensions
- Reuse current review/evidence/review-pack fixtures; do not widen default helper cost.
Phase 2 - Bounded Guidance Adapter
- Choose the narrowest implementation home:
- extend
ReviewPackOutputReadinesswith derived presentation fields only if raw truth remains legible, or - add a small
ReviewPackOutputResolutionGuidancecompanion underapp/Support/ReviewPacks/
- extend
- Keep the guidance layer derived-only:
- display state
- label
- severity
- primary reason
- impact
- primary action
- grouped limitations
- secondary actions
- technical-details payload
- If additional display states such as
publication_blockedare needed, keep them presentation-only and map them from current limitation codes or publish-blocker truth.
Phase 3 - Action Mapping And Copy
- Map limitation codes to plain-language guidance:
- evidence basis incomplete -> open evidence basis
- required sections incomplete -> review section limitations
- mapping/control limitations -> review unmapped evidence or control interpretation
- publish blockers -> resolve review blockers
- contains PII -> review package contents / PII state
- export not ready -> review output limitations
- Prefer existing route helpers and scoped resource URLs.
- Keep button and notification vocabulary aligned to current localization patterns:
Verb + Object, conservative sharing language, no false-ready wording.
Phase 4 - Customer Review Workspace Update
- Update
CustomerReviewWorkspacepayload building to consume the bounded guidance object instead of scattered reason/action logic. - Update the Blade view to show:
- one output-guidance label
- one primary reason
- one impact statement
- one primary action
- compact grouped limitations
- qualified secondary download/action wording
- collapsed technical details
- Preserve current acknowledgement, accepted-risk, findings, and proof sections unless a minimal copy/order change is required to support the one-blocker hierarchy.
Phase 5 - Environment Review Detail Update
- Update
EnvironmentReviewResource/ViewEnvironmentReviewso the detail surface clearly separates:- review status
- output readiness
- publication/sharing state
- Keep fingerprint and raw proof detail secondary or hidden in customer-workspace mode.
- Preserve customer-workspace-mode access, download safety, and current lifecycle-action behavior outside that mode.
Phase 6 - Localization, Audit, And Browser Proof
- Update only the required output-guidance keys in:
apps/platform/lang/en/localization.phpapps/platform/lang/de/localization.php
- Update
docs/ui-ux-enterprise-audit/page-reports/ui-006-customer-review-workspace.mdwith the new guidance model, one-primary-action rule, grouped limitation behavior, and repo-truth note about the missingui-009-review-pack-output-contract.md. - Capture screenshots under
specs/349-customer-review-workspace-output-resolution-guidance/artifacts/screenshots/.
Phase 7 - Validation And Close-Out
- Run focused Feature tests for the new guidance layer and the current Spec 347 regressions.
- Run the bounded Browser smoke for representative states.
- Run
pint --dirtyandgit diff --check. - Record any unrelated failures separately without widening scope.
Validation Plan
cd apps/platform
./vendor/bin/sail artisan test tests/Feature/ReviewPack/Spec349ReviewPackResolutionGuidanceTest.php tests/Feature/Filament/Spec349CustomerReviewWorkspaceOutputGuidanceTest.php tests/Feature/EnvironmentReview/Spec349EnvironmentReviewOutputGuidanceTest.php --compact
./vendor/bin/sail php vendor/bin/pest tests/Browser/Spec349OutputResolutionGuidanceSmokeTest.php --compact
./vendor/bin/sail artisan test --compact --filter=Spec347
./vendor/bin/sail artisan test --compact --filter=CustomerReviewWorkspace
./vendor/bin/sail artisan test --compact --filter=ReviewPack
./vendor/bin/sail pint --dirty
git diff --check
Deployment Impact
- Env vars: none expected
- Migrations: none
- Queues / scheduler: none
- Storage: none
- Assets: no new Filament asset registration expected;
filament:assetsis not newly required by this change