Plans 01–11, CONTEXT, PATTERNS, RESEARCH, REVIEW-FIX, and updated
SUMMARY and CONTEXT for the virtual-local-cloud-operations phase.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Shared queue dialogs and authorized content action surfaces.
from
to
via
pattern
upload and content client helpers
shared browser events
CloudFolderView thin handlers
upload
Wire the shared browser to the completed backend upload and content endpoints so cloud queue handling, binary-only preview, and authorized fallback download behave exactly like the new Phase 13 contracts require.
Purpose: Complete the frontend half of CLOUD-02 and CLOUD-03 without violating the shared-browser architecture.
Output: Passing queue, preview, and CloudFolderView frontend suites.
Task 1: Implement the sequential shared upload queue with typed pause and resume behavior
frontend/src/api/cloud.js, frontend/src/views/CloudFolderView.vue, frontend/src/components/storage/StorageBrowser.vue, frontend/src/components/storage/__tests__/StorageBrowser.cloud-queue.test.js, frontend/src/views/__tests__/CloudFolderView.test.js
- frontend/src/views/FileManagerView.vue
- frontend/src/components/storage/StorageBrowser.vue
- frontend/src/views/CloudFolderView.vue
- frontend/src/components/storage/__tests__/StorageBrowser.cloud-queue.test.js
- Test 1: the queue runs one file at a time and pauses on typed conflict or error results
- Test 2: Keep both, Replace, Skip, Retry, and Cancel all resume or stop the queue exactly where required
- Test 3: CloudFolderView remains thin and delegates queue UI to the shared browser
Replace the placeholder cloud upload flow with sequential queue orchestration that calls the new upload helper in `frontend/src/api/cloud.js`, feeds typed conflict and error bodies into shared browser dialogs, and preserves remaining items while paused. Keep queue state in the thin-view plus shared-browser boundary only; do not create a cloud-only queue component and do not infer replace semantics client-side.
- queue and view tests pass using the shared browser rather than a parallel cloud UI
- typed backend conflict/error bodies drive pause and resume behavior directly
- Cancel all stops remaining uploads without recording a false overwrite success
cd frontend && npm run test -- --run src/components/storage/__tests__/StorageBrowser.cloud-queue.test.js src/views/__tests__/CloudFolderView.test.js
The shared browser now owns the sequential cloud upload experience without architectural drift.
Task 2: Wire binary-only preview and authorized download fallback through shared actions
frontend/src/api/cloud.js, frontend/src/views/CloudFolderView.vue, frontend/src/components/storage/StorageBrowser.vue, frontend/src/views/__tests__/CloudFolderOpenPreview.test.js
- frontend/src/api/cloud.js
- frontend/src/views/__tests__/CloudFolderOpenPreview.test.js
- .planning/phases/13-virtual-local-cloud-operations/13-CONTEXT.md
- Test 1: preview stays in-app for supported binary files
- Test 2: unsupported formats use authorized download fallback rather than Office-native or Google Workspace preview
- Test 3: no provider URL or credential is stored or opened directly in Vue
Implement the cloud open and preview handlers through centralized client helpers only. Keep the preview path limited to the backend-declared binary matrix and route unsupported formats to the authorized download fallback. Reuse the shared browser’s action surface for all user interactions so the cloud path feels local while still respecting the stricter backend content contract.
- preview suite passes with binary-only in-app preview and authorized fallback download
- CloudFolderView remains a thin data provider
- no frontend code opens raw provider URLs or stores provider credentials
cd frontend && npm run test -- --run src/views/__tests__/CloudFolderOpenPreview.test.js
The cloud browser now consumes the authorized preview and download contract through the same shared actions users already know.
<threat_model>
Trust Boundaries
Boundary
Description
typed backend result → shared queue UI
The client must consume authoritative conflict/error typing instead of inventing semantics.
content helper → preview surface
Preview must stay behind DocuVault authorization.
STRIDE Threat Register
Threat ID
Category
Component
Disposition
Mitigation Plan
T-13-22
T
queue resume flow
mitigate
Shared-browser tests require explicit resume and cancel semantics for every pause reason.
T-13-23
I
preview/download UI
mitigate
Preview tests forbid raw provider URLs and require binary-only in-app preview plus authorized fallback.
</threat_model>
- Pass the new queue and preview frontend suites.
- Confirm the cloud path still uses `StorageBrowser.vue` as the single browser.
- Confirm preview remains binary-only and credential-safe.
<success_criteria>
Users can upload to cloud storage through the same shared browser interaction path as local files.
Cloud preview and download fallback stay within the authorized backend contract.
The frontend now satisfies CLOUD-02 and CLOUD-03 without architectural duplication.
</success_criteria>
Create `.planning/phases/13-virtual-local-cloud-operations/13-07-SUMMARY.md` when done