Skip to content

YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context

Simplify workflow cards with visible previews and one clear action (#7198)

Louis Beaumont41e66a4599a7
diff --git a/.github/pr-assets/workflow-card-disclosure/after-compact.png b/.github/pr-assets/workflow-card-disclosure/after-compact.png
new file mode 100644
index 000000000..e435656ce
Binary files /dev/null and b/.github/pr-assets/workflow-card-disclosure/after-compact.png differ
diff --git a/.github/pr-assets/workflow-card-disclosure/after-hover.png b/.github/pr-assets/workflow-card-disclosure/after-hover.png
new file mode 100644
index 000000000..f035279b1
Binary files /dev/null and b/.github/pr-assets/workflow-card-disclosure/after-hover.png differ
diff --git a/.github/pr-assets/workflow-card-disclosure/after-idle.png b/.github/pr-assets/workflow-card-disclosure/after-idle.png
new file mode 100644
index 000000000..a46c75dd2
Binary files /dev/null and b/.github/pr-assets/workflow-card-disclosure/after-idle.png differ
diff --git a/.github/pr-assets/workflow-card-disclosure/after-keyboard.png b/.github/pr-assets/workflow-card-disclosure/after-keyboard.png
new file mode 100644
index 000000000..be738f745
Binary files /dev/null and b/.github/pr-assets/workflow-card-disclosure/after-keyboard.png differ
diff --git a/.github/pr-assets/workflow-card-disclosure/after-long-title.png b/.github/pr-assets/workflow-card-disclosure/after-long-title.png
new file mode 100644
index 000000000..f9f6c3a3e
Binary files /dev/null and b/.github/pr-assets/workflow-card-disclosure/after-long-title.png differ
diff --git a/.github/pr-assets/workflow-card-disclosure/after-touch.png b/.github/pr-assets/workflow-card-disclosure/after-touch.png
new file mode 100644
index 000000000..a7845eb61
Binary files /dev/null and b/.github/pr-assets/workflow-card-disclosure/after-touch.png differ
diff --git a/.github/pr-assets/workflow-card-disclosure/before-collapsed.png b/.github/pr-assets/workflow-card-disclosure/before-collapsed.png
new file mode 100644
index 000000000..a97fc701e
Binary files /dev/null and b/.github/pr-assets/workflow-card-disclosure/before-collapsed.png differ
diff --git a/.github/pr-assets/workflow-card-disclosure/loading.png b/.github/pr-assets/workflow-card-disclosure/loading.png
new file mode 100644
index 000000000..acf533a00
Binary files /dev/null and b/.github/pr-assets/workflow-card-disclosure/loading.png differ
diff --git a/.github/pr-assets/workflow-card-disclosure/opened-workflow.png b/.github/pr-assets/workflow-card-disclosure/opened-workflow.png
new file mode 100644
index 000000000..c5afe2c20
Binary files /dev/null and b/.github/pr-assets/workflow-card-disclosure/opened-workflow.png differ
diff --git a/apps/screenpipe-app-tauri/components/workflows/workflow-timing.test.tsx b/apps/screenpipe-app-tauri/components/workflows/workflow-timing.test.tsx
index 513ebc3fb..8d788bdac 100644
--- a/apps/screenpipe-app-tauri/components/workflows/workflow-timing.test.tsx
+++ b/apps/screenpipe-app-tauri/components/workflows/workflow-timing.test.tsx
@@ -34,15 +34,13 @@ describe("workflow elapsed timing", () => {
await act(async () => { render(<WorkflowsApp platform={platform} initialAnalysis={fixtureWorkflowAnalysis} storageKey={null} />); });
const card = screen.getByRole("heading", { name: "Research synthesis" }).closest("article")!;
expect(within(card).getByText(/~24m \/ run · estimated/)).toBeVisible();
- fireEvent.click(within(card).getByText("Workflow details"));
- for (const title of ["Partner meeting preparation", "Website release check"]) {
- fireEvent.click(within(screen.getByRole("heading", { name: title }).closest("article")!).getByText("Workflow details"));
- }
- expect(within(card).getByText("Avg. time / run")).toBeVisible();
- expect(within(card).getByText("~24m")).toBeVisible();
- expect(within(card).getByText("3 runs · estimated")).toBeVisible();
- expect(within(screen.getByRole("heading", { name: "Partner meeting preparation" }).closest("article")!).getByText("Time for one run")).toBeVisible();
- expect(within(screen.getByRole("heading", { name: "Website release check" }).closest("article")!).getByText("—")).toBeVisible();
+ expect(within(card).getByText(workflow.description)).toBeVisible();
+ expect(card.querySelector("details")).toBeNull();
+ expect(within(card).getAllByRole("button")).toHaveLength(1);
+ const single = screen.getByRole("heading", { name: "Partner meeting preparation" }).closest("article")!;
+ expect(within(single).getByText(/~12m \/ run · estimated/)).toBeVisible();
+ const unknown = screen.getByRole("heading", { name: "Website release check" }).closest("article")!;
+ expect(within(unknown).queryByText(/\/ run/)).not.toBeInTheDocument();
fireEvent.click(within(card).getByRole("button", { name: "Open map" }));
expect(screen.queryByText("Correct this workflow")).not.toBeInTheDocument();
fireEvent.click(screen.getByText("Evidence and limitations"));
diff --git a/packages/workflows-ui/src/workflows-app.module.css b/packages/workflows-ui/src/workflows-app.module.css
index 48dd0b447..b139aff03 100644
--- a/packages/workflows-ui/src/workflows-app.module.css
+++ b/packages/workflows-ui/src/workflows-app.module.css
@@ -438,7 +438,7 @@
.timeLensEmpty h2 { margin: 13px 0 6px; color: #363a32; font-size: 15px; }
.timeLensEmpty p { max-width: 550px; margin: 0; color: #7b8076; font-size: 9px; line-height: 1.55; }
-.workflowGrid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 13px; }
+.workflowGrid { display: grid; align-items: start; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 13px; }
.filterBar { min-height: 53px; display: flex; align-items: center; gap: 10px; margin: -22px 0 13px; padding: 9px 10px 9px 15px; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
.filterBar > div { display: flex; flex-direction: column; gap: 3px; margin-right: auto; }
.filterBar > div strong { font-size: 10px; }
@@ -454,30 +454,22 @@
.filterPanel select:focus { border-color: #a8b47e; box-shadow: 0 0 0 2px #e7edda; }
.filterPanel > button { height: 32px; padding: 0 10px; border: 0; background: transparent; color: #73776e; font-size: 9px; cursor: pointer; }
.filterPanel > button:disabled { opacity: .4; cursor: default; }
-.workflowCard { position: relative; min-width: 0; display: flex; flex-direction: column; min-height: 250px; padding: 22px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); color: inherit; text-align: left; transition: border-color .15s ease; }
+.workflowCard { position: relative; min-width: 0; display: flex; flex-direction: column; padding: 20px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); color: inherit; text-align: left; cursor: pointer; transition: border-color .15s ease; }
.workflowCard:hover { border-color: var(--muted); }
-.workflowCardTop { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
-.workflowCardTop > span { color: var(--muted); font-size: 10px; font-variant-numeric: tabular-nums; }
-.workflowCardTop > div { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: 5px; min-width: 0; }
-.workflowCardTop .pill { white-space: normal; }
-.workflowCard h2 { margin: 16px 0 8px; font-size: 21px; font-weight: 600; letter-spacing: -.035em; }
-.workflowCard > p { min-height: 42px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
-.cardPath { display: grid; grid-template-columns: minmax(0,1fr) 16px minmax(0,1fr); gap: 7px; align-items: center; margin: 18px 0; padding: 12px; border-radius: 7px; background: #f5f6f1; color: #696d63; font-size: 8px; line-height: 1.4; }
-.cardPath svg { color: #969990; }
-.cardMetrics { display: grid; grid-template-columns: repeat(4,1fr); border-top: 1px solid #e6e7e1; border-bottom: 1px solid #e6e7e1; }
-.cardMetrics > div { padding: 13px 8px 13px 0; }
-.cardMetrics span { display: block; color: #989b93; font-size: 7.5px; }
-.cardMetrics strong { display: block; margin-top: 5px; font-size: 11px; }
-.cardMetrics small { display: block; margin-top: 3px; color: #78786f; font-size: 9px; }
-.cardFooter { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin-top: auto; padding-top: 17px; }
-.cardFooter span { color: var(--muted); font-size: 11px; }
-.cardActions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
-.cardActions button { display: inline-flex; align-items: center; justify-content: center; gap: 5px; min-height: 32px; padding: 6px 8px; border: 0; border-radius: 5px; background: transparent; color: var(--ink); font: inherit; font-size: 11px; font-weight: 550; white-space: nowrap; cursor: pointer; }
-.cardActions button:hover { background: var(--soft); }
-.cardActions button:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
-.cardOpen::after { content: ""; position: absolute; inset: 0; border-radius: 10px; }
+.workflowCard h2 { margin: 0 0 8px; font-size: 19px; line-height: 1.4; font-weight: 600; letter-spacing: -.035em; overflow-wrap: anywhere; }
+.cardDescription { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; min-height: 40px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; overflow-wrap: anywhere; }
+.cardFooter { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; margin-top: 18px; }
+.cardSummary { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; }
+.cardSummary span { opacity: .5; }
+.cardActions { display: flex; align-items: center; margin-left: auto; }
+.cardOpen { display: inline-flex; align-items: center; justify-content: center; gap: 5px; min-height: 28px; padding: 4px 0 4px 8px; border: 0; border-radius: 4px; background: transparent; color: var(--ink); font: inherit; font-size: 11px; font-weight: 550; white-space: nowrap; cursor: pointer; }
+.cardOpen::after { content: ""; position: absolute; inset: 0; border-radius: 8px; }
+.cardOpen:focus-visible { outline: none; }
.cardOpen:focus-visible::after { outline: 2px solid var(--ink); outline-offset: 2px; }
-.workflowCard h2, .workflowCard > p, .cardPath { overflow-wrap: anywhere; }
+.cardOpenLabel { opacity: 0; transition: opacity 180ms ease; }
+.workflowCard:hover .cardOpenLabel, .workflowCard:focus-within .cardOpenLabel { opacity: 1; }
+@media (hover: none) { .cardOpenLabel { opacity: 1; } }
+@media (prefers-reduced-motion: reduce) { .cardOpenLabel { transition: none; } }
.detailHeader { display: grid; grid-template-columns: minmax(0,1fr) 245px; gap: 60px; align-items: end; margin-bottom: 29px; }
.detailHeader h1 { margin: 16px 0 9px; font-size: clamp(32px,4vw,49px); letter-spacing: -.052em; }
@@ -964,7 +956,6 @@
.procedureDetails blockquote { max-height: 160px; overflow-y: auto; }
@media (max-width: 640px) { .refreshControls { flex-wrap: wrap; justify-content: flex-end; } }
-.cardMetrics { grid-template-columns: repeat(auto-fit, minmax(70px, 1fr)); }
/* Catalog controls remain compact in both empty and populated states. */
.catalogHeader { align-items: center; margin: 0 0 24px; gap: 20px; }
@@ -1034,10 +1025,10 @@
/* Loading follows the catalog geometry without pretending the catalog is empty. */
.skeletonBar { display: block; max-width: 100%; flex-shrink: 0; border-radius: 4px; background: var(--line); animation: catalogPulse 1.8s ease-in-out infinite; }
.skeletonCard { pointer-events: none; cursor: default; }
-.skeletonTitle { margin: 16px 0 8px; }
-.skeletonLines { display: grid; gap: 7px; min-height: 42px; }
+.skeletonTitle { margin: 0 0 12px; }
+.skeletonLines { display: grid; align-content: start; gap: 7px; min-height: 40px; }
.skeletonDetail { display: grid; gap: 16px; }
-.skeletonCard .cardMetrics .skeletonBar + .skeletonBar { margin-top: 9px; }
+.skeletonDetail .skeletonCard { display: flex; flex-direction: column; gap: 12px; }
.catalogLoadStatus, .catalogRefreshNotice { color: var(--muted); font-size: 12px; }
.catalogRefreshNotice { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; }
.catalogRefreshNotice button { color: inherit; background: none; border: 0; text-decoration: underline; cursor: pointer; }
@@ -1048,14 +1039,6 @@
.catalogLoadError button { margin: auto; }
@keyframes catalogPulse { 0%, 100% { opacity: .5; } 50% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .skeletonBar { animation: none; } }
-/* Details stay above the stretched open target and remain independently accessible. */
-.cardDetails { position: relative; z-index: 1; order: 4; margin-top: 12px; border-top: 1px solid var(--line); padding-top: 10px; }
-.cardDetails summary { width: fit-content; cursor: pointer; color: var(--muted); font-size: 11px; }
-.cardDetails summary:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
-.cardDetails .cardPath { margin: 12px 0; font-size: 11px; }
-.cardDetails .cardMetrics span { font-size: 10px; }
-.cardSummary { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; margin: 16px 0; }
-.cardSummary span { opacity: .5; }
.filterBar { border: 0; padding-left: 0; background: transparent; }
.filterBar > div strong { font-size: 12px; font-weight: 500; }
.filterBar > div span { font-size: 11px; }
diff --git a/packages/workflows-ui/src/workflows-app.tsx b/packages/workflows-ui/src/workflows-app.tsx
index e5b18a78b..cfa6e8a57 100644
--- a/packages/workflows-ui/src/workflows-app.tsx
+++ b/packages/workflows-ui/src/workflows-app.tsx
@@ -748,20 +748,20 @@ function WorkflowsView({ workflows, knownWorkflowCount, activityPeriod, filters,
</section>}
{visible.length ? <div className={styles.workflowGrid}>{visible.map((workflow) => {
const originalIndex = workflows.indexOf(workflow);
- const actionableCount = workflow.bottlenecks.filter(isActionableBottleneck).length;
- const constraintCount = workflow.bottlenecks.length - actionableCount;
const timing = workflowTiming(workflow.timing);
return (
<article key={workflow.id || workflow.title} className={styles.workflowCard}>
- <div className={styles.workflowCardTop}><span>{String(workflow.rank).padStart(2, "0")}</span><div><Pill>{workflow.catalogStatus === "not-reobserved" ? ui("Kept from earlier scan") : workflow.evidenceStatus === "supported-steps" ? ui("Steps have sources") : ui("Candidate · needs review")}</Pill>{actionableCount > 0 && <Pill tone="warm">{actionableCount} possible improvement{actionableCount === 1 ? "" : "s"}</Pill>}{constraintCount > 0 && <Pill>{ui("{count, plural, one {# constraint} other {# constraints}}", { count: constraintCount })}</Pill>}</div></div>
- <h2>{workflow.title}</h2><p>{workflow.description}</p>
- <details className={styles.cardDetails}><summary>Workflow details</summary><div className={styles.cardPath}><span>{workflow.trigger}</span><ArrowRight size={12} /><span>{workflow.outcome}</span></div>
- <div className={styles.cardMetrics}><div title={timing ? ui("Estimated elapsed time from source-backed start and finish moments. Includes pauses; not active work time. Open the map to inspect the runs.") : ui("Not enough evidence of complete workflow runs to estimate an average.")}><span>{timing?.sampleCount === 1 ? ui("Time for one run") : !timing && hasMeasuredDuration(workflow) ? ui("Meeting duration") : ui("Avg. time / run")}</span><strong>{timing ? formatEstimatedMinutes(timing.averageMinutes) : hasMeasuredDuration(workflow) ? formatMinutes(workflow.totalMinutes) : "—"}</strong>{timing && <small>{ui("{count, plural, one {# run} other {# runs}}", { count: timing.sampleCount })} · estimated</small>}</div><div><span>Stages</span><strong>{workflow.stages.length}</strong></div><div><span>Evidence</span><strong>{workflow.quality.evidenceCount}</strong></div><div><span>Screenshots</span><strong>{workflow.quality.screenshotCount}/{workflow.stages.length}</strong></div></div>
- </details>
- <div className={styles.cardSummary}>{workflow.stages.length} steps <span>·</span> {workflow.quality.screenshotCount}/{workflow.stages.length} screenshots <span>·</span> {timing ? `${formatEstimatedMinutes(timing.averageMinutes)} / run · estimated` : "Run time not measured"}</div>
- <div className={styles.cardFooter}><span>{workflow.frequency}</span><div className={styles.cardActions}>
- <button type="button" className={styles.cardOpen} onClick={() => openWorkflow(originalIndex)}>Open map <ChevronRight size={14} /></button>
- </div></div>
+ <h2>{workflow.title}</h2>
+ <p className={styles.cardDescription}>{workflow.description}</p>
+ <div className={styles.cardFooter}>
+ <div className={styles.cardSummary}>
+ {workflow.stages.length} steps
+ {timing && <><span aria-hidden="true">·</span>{`${formatEstimatedMinutes(timing.averageMinutes)} / run · estimated`}</>}
+ </div>
+ <div className={styles.cardActions}>
+ <button type="button" className={styles.cardOpen} onClick={() => openWorkflow(originalIndex)}><span className={styles.cardOpenLabel}>{ui("Open map")}</span><ChevronRight size={14} /></button>
+ </div>
+ </div>
</article>
);
})}</div> : <section className={styles.emptyState}><Search size={23} /><h2>No workflows match these filters</h2><p>Broaden the filters or clear the search to see the rest of your mapped work.</p><button className={styles.primaryButton} onClick={() => setFilters(defaultWorkflowFilters)}>Clear filters</button></section>}
@@ -779,12 +779,9 @@ function CatalogPlaceholder({ detail = false }: { detail?: boolean }) {
{!detail && <div className={styles.filterBar}><div>{bar("100px")}{bar("140px", 8)}</div>{bar("85px", 28)}</div>}
<div className={detail ? styles.skeletonDetail : styles.workflowGrid}>
{Array.from({ length: detail ? 3 : 4 }, (_, i) => <div key={i} className={`${styles.workflowCard} ${styles.skeletonCard}`}>
- <div className={styles.workflowCardTop}>{bar("20px")}{bar("120px", 18)}</div>
<div className={styles.skeletonTitle}>{bar("78%", 20)}</div>
- <div className={styles.skeletonLines}>{bar("100%")}{bar("91%")}{bar("64%")}</div>
- <div className={styles.cardSummary}>{bar("64%", 12)}</div>
- <div className={styles.cardDetails}>{bar("90px", 11)}</div>
- <div className={styles.cardFooter}>{bar("45%", 8)}{bar("55px", 8)}</div>
+ <div className={styles.skeletonLines}>{bar("95%")}{bar("72%")}{detail && bar("64%")}</div>
+ <div className={styles.cardFooter}>{bar("140px", 10)}{bar("16px", 10)}</div>
</div>)}
</div>
</div>