Skip to content

Redesign artifacts page as full-width table with drawer - #15233

Merged
AmethystLiang merged 3 commits into
mainfrom
improve-artifacts-page-visual
Aug 18, 2026
Merged

AmethystLiang merged 3 commits into
mainfrom
improve-artifacts-page-visual

Conversation

@AmethystLiang

@AmethystLiang AmethystLiang commented Aug 18, 2026 •

Copy link
Copy Markdown
Contributor
Files Added Deleted Net
Test 5 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​219 $\color{#cf222e}{\Huge{\mathbf{−}}}$​76 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​143
Prod 31 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​1061 $\color{#cf222e}{\Huge{\mathbf{−}}}$​573 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​488

Problem

Artifacts page had a split sidebar layout that didn't scale visually and wasn't composable with Orca's table patterns. Window-control positioning only worked inline, breaking portaled surfaces (sheets, dialogs). List-table styling wasn't shared with automations, causing maintenance drift.

Solution

Redesigned artifacts as a full-width table with a right-side detail drawer for previews. Extracted shared list-table chrome to @/lib/list-table-layout so both artifacts and automations use consistent styling. Exported window-controls dimensions as constants so portaled surfaces can inset correctly without hardcoding pixels.

What Changed

  • Artifacts page: split pane → full-width table with detail drawer
  • New components: ArtifactDetailDrawer, ArtifactListRows, ArtifactListToolbar, ArtifactListTableHeader, ArtifactListSearchField
  • Removed: ArtifactListPane
  • Extracted: @/lib/list-table-layout (shared container, header, row styles), @/lib/list-row-interaction (moved from automations)
  • Added: artifact list search with query clamping and multi-MB paste protection
  • Updated automations to use shared list-table layout
  • Fixed: window-controls positioning for portaled surfaces via CSS custom properties

Why

Separating preview from list enables better space use and matches how automations work. Shared layout prevents visual drift. Window-control constants work both inline and for portaled surfaces.

Linked Issue

Fixes #

Visual Proof

N/A — Layout refactor tested via component tests; visual consistency verified through test snapshots. Automations table renders identically after extraction.

Testing

  • I manually tested these changes locally
  • Updated ArtifactCollection tests: changed from listbox/option to button/table semantics
  • Updated ArtifactsPage tests: drawer opens on row click, closes on Escape, actions in dropdown
  • Added artifact-display-labels and artifact-list-search unit tests
  • Automations tests pass; table interaction unchanged

AI Disclosure

N/A — internal contributor

Review

Agent skill upstream boundary

  • Not applicable, or this change follows docs/reference/agent-skill-sharing-upstream-boundary.md and copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.

Notes

Ensure no issues in: Security, Cross-platform support (Linux, Windows, Mac), Remote SSH, Mobile, general backwards compatibility, performance

Checklist

  • This PR is small and focused
  • I explained what changed and why (including ELI5)
  • Before/after screenshots or videos attached for UI changes, or N/A with reason
  • Self-reviewed for correctness, security, and performance
  • Cross-platform, SSH/remote, and path/shortcut impact considered (or N/A)
  • pnpm lint, pnpm typecheck, pnpm test, and pnpm build pass (or CI will cover; local preferred)

- Artifacts list displays as a compact data table with columns (Name, Type, Size, Updated, Expires)
- Selected artifact opens in a right-side drawer instead of inline preview
- Search and refresh consolidated in top toolbar
- Better space utilization for browsing the artifact list
- Extract common list-table styles (container, header, row) to @/lib for
  consistency across artifacts and automations tables
- Move row interaction utilities to @/lib/list-row-interaction for reuse
- Fix drawer width to calc(100vw-80px) to avoid macOS traffic-light controls
- Extract WINDOW_CONTROLS_WIDTH/HEIGHT constants so portaled surfaces avoid
  the Windows/Linux overlay without hardcoding pixels
- Clamp artifact search query to 2KB to prevent multi-MB pastes from pinning
  renderer memory
- Remove unused artifact list visual mock
@coderabbitai

coderabbitai Bot commented Aug 18, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 5fc85b6b-c8eb-44ac-816a-e610e707a60a

📥 Commits

Reviewing files that changed from the base of the PR and between 472ab6f and 246a825.

📒 Files selected for processing (7)
  • src/renderer/src/App.tsx
  • src/renderer/src/app-shell/app-window-chrome.ts
  • src/renderer/src/components/artifacts/ArtifactDetailDrawer.tsx
  • src/renderer/src/components/artifacts/ArtifactListRows.tsx
  • src/renderer/src/components/artifacts/ArtifactsPage.test.tsx
  • src/renderer/src/components/artifacts/ArtifactsPageSkeleton.tsx
  • src/renderer/src/components/artifacts/artifact-display-labels.test.ts

📝 Walkthrough

Walkthrough

The artifacts page now uses a searchable, refreshable table with compact metadata and row action menus. Selecting a row opens an independent detail drawer with preview and deletion controls. Loading, authentication, error, empty, and skeleton states are extracted into dedicated components. Shared list-table styling now supports both artifacts and automations. Window-control dimensions are centralized and applied to app and portaled surfaces. Tests and localization strings were updated.

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description explains the implementation and testing, but it lacks a linked issue and uses N/A for required visual proof despite major UI changes. Add a valid issue reference and attach before-and-after screenshots or videos; complete the ELI5 and review sections if required.
Docstring Coverage ⚠️ Warning Docstring coverage is 12.20% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the primary change: redesigning the artifacts page as a full-width table with a detail drawer.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (4)
src/renderer/src/components/artifacts/ArtifactListRows.tsx (1)

97-136: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Extract the duplicated menu actions into a shared list.

The DropdownMenuContent block and the ContextMenuContent block define the same three actions (copy link, open in browser, delete artifact) with identical icons, labels, and handlers. A future change to one of these actions requires editing both blocks, and it is easy to let them drift.

Extract the action definitions into a single array (label, icon, onSelect, optional variant/disabled) and map it into both DropdownMenuItem and ContextMenuItem lists.

♻️ Proposed refactor sketch
const rowActions = [
  {
    key: 'copy',
    label: translate('auto.components.artifacts.copyLink', 'Copy link'),
    icon: Copy,
    onSelect: () => void copyArtifactLink(item.shareUrl)
  },
  {
    key: 'open',
    label: translate('auto.components.artifacts.openInBrowser', 'Open in browser'),
    icon: ExternalLink,
    onSelect: () => openArtifactInBrowser(item.shareUrl)
  }
] as const

// ...
<DropdownMenuContent align="end" className="w-48">
  {rowActions.map(({ key, label, icon: Icon, onSelect }) => (
    <DropdownMenuItem key={key} onSelect={onSelect}>
      <Icon className="size-3.5" />
      {label}
    </DropdownMenuItem>
  ))}
  <DropdownMenuSeparator />
  <DropdownMenuItem variant="destructive" disabled={deleting} onSelect={() => deleteArtifact(item)}>
    <Trash2 className="size-3.5" />
    {translate('auto.components.artifacts.ArtifactsPage.deleteArtifact', 'Delete artifact')}
  </DropdownMenuItem>
</DropdownMenuContent>

Apply the same rowActions.map(...) pattern inside ContextMenuContent.

Also applies to: 138-160

src/renderer/src/components/artifacts/ArtifactsPageSkeleton.tsx (1)

21-28: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Add a role so the loading label is announced.

The root element is a plain div. Screen readers do not expose aria-label on a generic element without a role. Add role="status" so the "Loading artifacts" label reaches assistive technology.

♻️ Proposed change
     <div
       className="flex min-h-0 flex-1 flex-col gap-4 overflow-hidden px-3 pb-4 md:px-5"
+      role="status"
       aria-busy="true"
       aria-label={translate(
         'auto.components.artifacts.ArtifactsPageSkeleton.loading',
         'Loading artifacts'
       )}
     >
src/renderer/src/components/artifacts/ArtifactDetailDrawer.tsx (1)

22-30: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Drive the reserved edge width from a platform-aware value instead of a hardcoded 80px.

The comment states the inset keeps the macOS traffic-light area uncovered. macOS paints the traffic lights on the left edge. Windows and Linux paint the window controls on the right edge, where this drawer is anchored. So the 80px left gap applies a macOS-only reservation on every platform, and Windows and Linux get an unnecessary gap.

This PR already centralizes window-control dimensions and exposes --window-controls-width, which ArtifactDetailHeader.tsx consumes. Reuse the same custom property here so the reserved space follows the host platform.

♻️ Proposed direction
-        className="h-full w-[min(96rem,calc(100vw-80px))] max-w-none translate-x-0 p-0 sm:max-w-[min(96rem,calc(100vw-80px))] data-[state=closed]:translate-x-0 data-[state=open]:translate-x-0"
+        className="h-full w-[min(96rem,calc(100vw-var(--window-controls-inset,80px)))] max-w-none translate-x-0 p-0 sm:max-w-[min(96rem,calc(100vw-var(--window-controls-inset,80px)))] data-[state=closed]:translate-x-0 data-[state=open]:translate-x-0"

Set --window-controls-inset next to the existing window-control dimension constants, and resolve it to 0px when the platform places no controls on the uncovered edge.

As per coding guidelines: "Keep platform-dependent behavior behind runtime checks for macOS, Linux, and Windows."

Source: Coding guidelines

src/renderer/src/components/artifacts/ArtifactsPage.test.tsx (1)

570-578: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Rename the helper to match what it does.

The helper does not act on a selected artifact. It picks the first context-menu-trigger in the document, left-clicks it to open the drawer, and then deletes through the drawer action menu. It also does not use the row context menu. In tests that render more than one row, the first row is always the target.

Rename it to deleteFirstArtifactRowFromDrawerMenu, or accept a row name and query by that name, so the call sites at Line 464, Line 501, Line 521, and Line 537 state which artifact they delete.


ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: c599aaec-66c4-46f5-a6a7-8d47d4931927

📥 Commits

Reviewing files that changed from the base of the PR and between 598ba5d and 472ab6f.

📒 Files selected for processing (36)
  • src/renderer/src/App.tsx
  • src/renderer/src/app-shell/AppWorkspaceShell.tsx
  • src/renderer/src/app-shell/app-window-chrome.ts
  • src/renderer/src/components/artifacts/ArtifactActions.tsx
  • src/renderer/src/components/artifacts/ArtifactCollection.test.tsx
  • src/renderer/src/components/artifacts/ArtifactCollection.tsx
  • src/renderer/src/components/artifacts/ArtifactDetailDrawer.tsx
  • src/renderer/src/components/artifacts/ArtifactDetailHeader.tsx
  • src/renderer/src/components/artifacts/ArtifactListPane.tsx
  • src/renderer/src/components/artifacts/ArtifactListRows.tsx
  • src/renderer/src/components/artifacts/ArtifactListSearchField.tsx
  • src/renderer/src/components/artifacts/ArtifactListTableHeader.tsx
  • src/renderer/src/components/artifacts/ArtifactListToolbar.tsx
  • src/renderer/src/components/artifacts/ArtifactsPage.test.tsx
  • src/renderer/src/components/artifacts/ArtifactsPage.tsx
  • src/renderer/src/components/artifacts/ArtifactsPageSkeleton.tsx
  • src/renderer/src/components/artifacts/ArtifactsPageStates.tsx
  • src/renderer/src/components/artifacts/artifact-display-labels.test.ts
  • src/renderer/src/components/artifacts/artifact-display-labels.ts
  • src/renderer/src/components/artifacts/artifact-list-search.test.ts
  • src/renderer/src/components/artifacts/artifact-list-search.ts
  • src/renderer/src/components/artifacts/artifacts-table-layout.ts
  • src/renderer/src/components/automations/AutomationListExternalRows.tsx
  • src/renderer/src/components/automations/AutomationListLocalRows.tsx
  • src/renderer/src/components/automations/AutomationListTableHeader.tsx
  • src/renderer/src/components/automations/AutomationsListPanel.tsx
  • src/renderer/src/components/automations/AutomationsPageSkeleton.tsx
  • src/renderer/src/components/automations/automations-table-layout.ts
  • src/renderer/src/i18n/locales/en.json
  • src/renderer/src/i18n/locales/es.json
  • src/renderer/src/i18n/locales/ja.json
  • src/renderer/src/i18n/locales/ko.json
  • src/renderer/src/i18n/locales/zh.json
  • src/renderer/src/lib/list-row-interaction.test.ts
  • src/renderer/src/lib/list-row-interaction.ts
  • src/renderer/src/lib/list-table-layout.ts
💤 Files with no reviewable changes (1)
  • src/renderer/src/components/artifacts/ArtifactListPane.tsx

Included review availability: Your plan includes up to 10 reviews per rolling hour; 5 remain after this review.

@AmethystLiang

Copy link
Copy Markdown
Contributor Author

@coderabbitai Fixing. Will be in the next commit

@coderabbitai

coderabbitai Bot commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

Tip

For best results, initiate chat on the files or code changes.

@AmethystLiang Acknowledged. I will verify the fix after the next commit.

You are interacting with an AI system.

- Unify dropdown and context menu actions via artifactRowActions() to prevent
  them from diverging during future maintenance.
- Replace hardcoded 80px with platform-aware CSS variable
  (--mac-traffic-lights-width) so only macOS reserves space for traffic lights;
  Windows and Linux controls sit on the right edge instead.
@AmethystLiang
AmethystLiang merged commit 314b02b into main Aug 18, 2026
2 of 46 checks passed
zz1996zz added a commit to zz1996zz/orca that referenced this pull request Aug 20, 2026
Resolve ko.json artifacts conflict: keep the shipped wording from the
artifacts page redesign (stablyai#15233), drop keys it removed, translate the ones
it added.

# Conflicts:
#	src/renderer/src/i18n/locales/ko.json
paidaxingyo666 pushed a commit to paidaxingyo666/Manta that referenced this pull request Aug 21, 2026
* refactor(artifacts): redesign as full-width table with detail drawer

- Artifacts list displays as a compact data table with columns (Name, Type, Size, Updated, Expires)
- Selected artifact opens in a right-side drawer instead of inline preview
- Search and refresh consolidated in top toolbar
- Better space utilization for browsing the artifact list

* refactor(artifacts,automations): extract shared list-table layout

- Extract common list-table styles (container, header, row) to @/lib for
  consistency across artifacts and automations tables
- Move row interaction utilities to @/lib/list-row-interaction for reuse
- Fix drawer width to calc(100vw-80px) to avoid macOS traffic-light controls
- Extract WINDOW_CONTROLS_WIDTH/HEIGHT constants so portaled surfaces avoid
  the Windows/Linux overlay without hardcoding pixels
- Clamp artifact search query to 2KB to prevent multi-MB pastes from pinning
  renderer memory
- Remove unused artifact list visual mock

* Extract shared artifact row actions and use CSS var for traffic lights

- Unify dropdown and context menu actions via artifactRowActions() to prevent
  them from diverging during future maintenance.
- Replace hardcoded 80px with platform-aware CSS variable
  (--mac-traffic-lights-width) so only macOS reserves space for traffic lights;
  Windows and Linux controls sit on the right edge instead.
dallascrilley pushed a commit to dallascrilley/orca that referenced this pull request Aug 27, 2026
* refactor(artifacts): redesign as full-width table with detail drawer

- Artifacts list displays as a compact data table with columns (Name, Type, Size, Updated, Expires)
- Selected artifact opens in a right-side drawer instead of inline preview
- Search and refresh consolidated in top toolbar
- Better space utilization for browsing the artifact list

* refactor(artifacts,automations): extract shared list-table layout

- Extract common list-table styles (container, header, row) to @/lib for
  consistency across artifacts and automations tables
- Move row interaction utilities to @/lib/list-row-interaction for reuse
- Fix drawer width to calc(100vw-80px) to avoid macOS traffic-light controls
- Extract WINDOW_CONTROLS_WIDTH/HEIGHT constants so portaled surfaces avoid
  the Windows/Linux overlay without hardcoding pixels
- Clamp artifact search query to 2KB to prevent multi-MB pastes from pinning
  renderer memory
- Remove unused artifact list visual mock

* Extract shared artifact row actions and use CSS var for traffic lights

- Unify dropdown and context menu actions via artifactRowActions() to prevent
  them from diverging during future maintenance.
- Replace hardcoded 80px with platform-aware CSS variable
  (--mac-traffic-lights-width) so only macOS reserves space for traffic lights;
  Windows and Linux controls sit on the right edge instead.
enrick-dev pushed a commit to enrick-dev/orca that referenced this pull request Oct 15, 2026
* refactor(artifacts): redesign as full-width table with detail drawer

- Artifacts list displays as a compact data table with columns (Name, Type, Size, Updated, Expires)
- Selected artifact opens in a right-side drawer instead of inline preview
- Search and refresh consolidated in top toolbar
- Better space utilization for browsing the artifact list

* refactor(artifacts,automations): extract shared list-table layout

- Extract common list-table styles (container, header, row) to @/lib for
  consistency across artifacts and automations tables
- Move row interaction utilities to @/lib/list-row-interaction for reuse
- Fix drawer width to calc(100vw-80px) to avoid macOS traffic-light controls
- Extract WINDOW_CONTROLS_WIDTH/HEIGHT constants so portaled surfaces avoid
  the Windows/Linux overlay without hardcoding pixels
- Clamp artifact search query to 2KB to prevent multi-MB pastes from pinning
  renderer memory
- Remove unused artifact list visual mock

* Extract shared artifact row actions and use CSS var for traffic lights

- Unify dropdown and context menu actions via artifactRowActions() to prevent
  them from diverging during future maintenance.
- Replace hardcoded 80px with platform-aware CSS variable
  (--mac-traffic-lights-width) so only macOS reserves space for traffic lights;
  Windows and Linux controls sit on the right edge instead.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant