Milestone 24: Collection Workspace (3-region info-dense layout) - #44
Merged
Exonical merged 1 commit intoMay 29, 2026
Merged
Conversation
New /collections/:cid/workspace route. Loosely modeled after the
upstream stig-manager Manage Collection view: Manage panel on the
left (name + description + Grants/Users/Settings/Metadata/Labels
tab strip), Assets metrics table top right, STIGs metrics table
bottom right.
Both tables drive off the M10 /metrics/summary/{asset,stig}
endpoints, so the same Assessed/Submitted/Accepted/Rejected
percentages surface here that the Metrics tab uses. Percentage
formulas mirror upstream's collectionManager.js (assessed/
assessments * 100 etc).
Tables include bulk-select checkboxes, sortable columns, name
filter, and a toolbar. Wired actions: Create asset (opens
NewAssetDialog), bulk Delete assets (Manage role required), and
Refresh. Toolbar buttons for Import/Transfer/Modify/Assign STIG/
Unassign STIG are surfaced as disabled placeholders pointing at
their current home (Reviews tab / Asset detail page).
Collections list now links to the workspace by default; the
collection id column still links to the legacy tabbed detail page.
No API changes.
Co-Authored-By: Bryce Anglin <brycemanglin@gmail.com>
Contributor
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a new
/collections/:collectionId/workspaceroute — a one-screen, information-dense "Manage Collection" view loosely modeled after the upstream stig-manager UI. Goal: eliminate the click-into-tabs cycle when an operator just wants to see "where is this collection at?" — assets, STIGs, and roll-up status all on one page.Layout (1 column on mobile, 2 columns on
lg+):GrantsTabfrom M18f). The other four are intentional placeholders pointing to where their content lives or will land.NewAssetDialog, gated on Full+), Import (disabled — file-based imports live on the Reviews tab from M22), Delete (n) (bulk delete, gated on Manage+), Refresh.Data source — both tables drive off
GET /collections/{cid}/metrics/summary/assetand/metrics/summary/stig(shipped in M10). No API changes in this PR. Percentage formulas mirror upstream'scollectionManager.js:assessed / assessments × 100(submitted + accepted + rejected) / assessments × 100accepted / assessments × 100rejected / assessments × 100Routing decision — new route alongside the existing
/collections/:cidtabbed detail page. The Collections list row link now defaults to/workspace; the collection-id column on that list still links to the legacy detail page so deep links and existing tests stay green. The workspace header also has an explicit "open detail" affordance.Code reuse —
GrantsTab,NewAssetDialog, the metrics hooks (useMetricsByAsset/useMetricsByStig), and the role helpers all reused without modification. The one tiny change inweb/src/lib/api/hooks.tsis exposing the existingMetricsSummaryshared type so the new file can type the innermetrics: {...}object.Tests — 1 new Playwright e2e (35/35 total, all green locally against the compose stack) that:
/collections/{cid}/workspace./collectionsand asserts the row link now points to/workspacewhile the legacy detail link is still present.Review & Testing Checklist for Human
/collections, click any collection row → lands on the new workspace. Confirm the 3-region layout (Manage / Assets / STIGs) renders side-by-side at viewport ≥ 1280px and stacks on narrow widths./collections/{cid}page is reachable from the "open detail" link in the workspace header and from the collection-id column on the Collections list. Direct links to that route still work./metrics/summaryendpoints).Notes
Users,Settings,Metadata, andLabelsManage tabs are deliberately stubs in M24 — pointing at where their content will live so the layout is visible end-to-end without me building five new screens in one PR. TheLabelsstub specifically links back to the legacy detail page where Labels already lives./collections/{cid}detail page at all. If the workspace becomes the canonical entry point we can later strip the now-redundant tabs (Overview / Grants) from the legacy page, but that's a follow-up after we know operators are happy with the workspace.Link to Devin session: https://app.devin.ai/sessions/022810763c4643c0848ba894c1512b92
Requested by: @Exonical