Skip to content

Commit d3638d7

Browse files
authored
Portal home: cut the mock blocks, wire the rest to real data (Stirling-Tools#6931)
## What this changes Cleaning up the portal home page. Most of what was under the plan card was mock — it hit endpoints that don't exist on any backend, so on SaaS it just showed a wall of "—" and "Nothing here yet". I removed the fake stuff and wired the bits worth keeping to real data. **Scrapped (all mock, no backend anywhere — self-hosted included):** - The "No usage yet" usage chart - The KPI strip (Docs/30d, Pipelines, Agents active, Eval pass rate) - The "Build a pipeline in seconds" fork wizard (fake build animation, deploy was a TODO) - The Sources/Pipelines/Agents product cards - The "Popular use cases" marketing cards - Enterprise region health - The "Try a PDF operation" runner Deleted their component/api/mock/MSW/story files too, plus the now-dead i18n keys and CSS. **Wired to real data (finished, not removed):** - The plan strip and the sidebar footer now show the **real** 30-day processed-PDF count from `/api/v1/usage/fleet-stats` (was a mock KPI). Shows "—" honestly when the backend can't compute it, never a fake number. - **Recent activity** now reads the **real audit log** — the same endpoint the Infrastructure → Audit tab uses. **Result:** one simple layout for all tiers — plan strip → recent activity + quick actions → "What runs on your PDFs" (the real policy summary). Every block is backed by data that actually exists. Net: **−3,221 / +89 lines**, 17 files removed. ## Testing typecheck (all variants), full test suite (1211), saas + proprietary builds, lint, format, storybook build, toml-sort — all green. The `unusedTranslations` test guarantees no orphaned i18n keys were left behind.
1 parent e5a258a commit d3638d7

27 files changed

Lines changed: 89 additions & 3221 deletions

frontend/editor/public/locales/en-US/translation.toml

Lines changed: 1 addition & 150 deletions
Original file line numberDiff line numberDiff line change
@@ -6791,23 +6791,6 @@ description = "This view hit an unexpected error. Try again, or pick another sec
67916791
retry = "Try again"
67926792
title = "Something went wrong on this page"
67936793

6794-
[portal.forkWizard]
6795-
subtitle = "Clone a proven workflow and tune it — every template ships the same four-stage backbone."
6796-
title = "Fork a starter pipeline"
6797-
6798-
[portal.forkWizard.action]
6799-
cancel = "Cancel"
6800-
deploy = "Deploy pipeline"
6801-
pickAnother = "Pick another"
6802-
6803-
[portal.forkWizard.status]
6804-
building = "Building…"
6805-
ready = "Ready to deploy"
6806-
6807-
[portal.home.chart.empty]
6808-
description = "Once documents are processed, your 30-day usage appears here."
6809-
title = "No usage yet"
6810-
68116794
[portal.home.editor]
68126795
activeUsers = "{{n}} active"
68136796
invite = "Invite teammates"
@@ -6825,25 +6808,6 @@ afternoon = "Good afternoon"
68256808
evening = "Good evening"
68266809
morning = "Good morning"
68276810

6828-
[portal.home.kpis.enterprise]
6829-
docs30d = "Docs / 30d"
6830-
evalPassRate = "Eval pass rate"
6831-
p95Latency = "P95 latency"
6832-
slaUptime = "SLA uptime (30d)"
6833-
6834-
[portal.home.kpis.free]
6835-
agents = "Agents"
6836-
docsProcessed = "Docs processed"
6837-
docsProcessedDescription = "Free plan cap"
6838-
operations = "Operations"
6839-
pipelines = "Pipelines"
6840-
6841-
[portal.home.kpis.pro]
6842-
agentsActive = "Agents active"
6843-
docs30d = "Docs / 30d"
6844-
evalPassRate = "Eval pass rate"
6845-
pipelines = "Pipelines"
6846-
68476811
[portal.home.onboarding]
68486812
dismiss = "Dismiss setup"
68496813
notStarted = "Not started"
@@ -6871,25 +6835,6 @@ blurb = "{{connected}} connected · every PDF governed where it lands"
68716835
chip = "{{connected}} connected"
68726836
title = "Connect your sources"
68736837

6874-
[portal.home.productGrid]
6875-
ariaLabel = "Process PDFs at scale"
6876-
6877-
[portal.home.productGrid.agents]
6878-
blurb = "Wire your agent via MCP, REST, or tool definitions. Deterministic operations, scenarios, evals."
6879-
cta = "Connect an agent"
6880-
title = "Agents"
6881-
6882-
[portal.home.productGrid.pipelines]
6883-
badge = "Hero"
6884-
blurb = "Compose document workflows from typed operations. Upload a sample to get suggestions or start blank."
6885-
cta = "Build a pipeline"
6886-
title = "Pipelines"
6887-
6888-
[portal.home.productGrid.sources]
6889-
blurb = "Attach pipelines where PDFs already live — S3, agents, SharePoint, webhooks, batch, email."
6890-
cta = "Connect a source"
6891-
title = "Sources"
6892-
68936838
[portal.home.quickActions]
68946839
subtitle = "Top tasks for today"
68956840
title = "Quick actions"
@@ -6906,18 +6851,6 @@ title = "Connect a source"
69066851
blurb = "Scoped key with rate limits and IP allowlist"
69076852
title = "Issue an API key"
69086853

6909-
[portal.home.quickActions.tryOp]
6910-
blurb = "Drop a sample, pick an op, see the JSON"
6911-
title = "Try a PDF operation"
6912-
6913-
[portal.home.regions]
6914-
subtitle = "Real-time status for every deployed Stirling region."
6915-
title = "Region health"
6916-
6917-
[portal.home.regions.empty]
6918-
description = "Once a region is deployed, its health appears here."
6919-
title = "No regions yet"
6920-
69216854
[portal.infrastructure]
69226855
manageEditorDeployment = "Manage Editor deployment"
69236856
sectionsAriaLabel = "Infrastructure sections"
@@ -7270,51 +7203,6 @@ new_other = "{{count}} new"
72707203
description = "No new notifications."
72717204
title = "You're all caught up"
72727205

7273-
[portal.opRunner]
7274-
durationMs = "{{ms}} ms"
7275-
featuredOps = "Featured ops"
7276-
subtitle = "Drop a sample, pick an op, see what Stirling returns."
7277-
title = "Try a PDF operation"
7278-
7279-
[portal.opRunner.action]
7280-
close = "Close"
7281-
openBuilder = "Open the pipeline builder"
7282-
run = "Run operation"
7283-
runAgain = "Run again"
7284-
running = "Running…"
7285-
7286-
[portal.opRunner.drop]
7287-
hint = "or use a sample document."
7288-
pickAnother = "Pick another sample"
7289-
replaceHint = "Drop again or pick another sample to replace."
7290-
title = "Drop a PDF here"
7291-
useSample = "Use a sample"
7292-
7293-
[portal.opRunner.empty]
7294-
description = "Once operations are published, they'll show up here."
7295-
title = "No featured ops yet"
7296-
7297-
[portal.opRunner.error]
7298-
title = "The operation didn't complete"
7299-
unknown = "Unknown error"
7300-
7301-
[portal.opRunner.hint]
7302-
aSample = "a sample"
7303-
press = "Press"
7304-
ready = "Ready"
7305-
toInvoke = "to invoke"
7306-
7307-
[portal.opRunner.hint.runOn]
7308-
before = "Run"
7309-
middle = "on"
7310-
7311-
[portal.opRunner.running]
7312-
title = "Running {{label}}…"
7313-
7314-
[portal.opRunner.status]
7315-
completed = "Completed"
7316-
failed = "Failed"
7317-
73187206
[portal.pipelines]
73197207
subtitle = "Every automated document pipeline on the backend: an ordered chain of operations over a set of sources, run on a trigger. Click a row for its steps and sources."
73207208
title = "Pipelines"
@@ -7573,9 +7461,6 @@ soon = "Soon"
75737461

75747462
[portal.processingStatus]
75757463
managePlan = "Manage plan"
7576-
pdfsThisMonth = "PDFs this month"
7577-
progressLabel = "{{used}} of {{cap}} PDFs used this month"
7578-
upgrade = "Upgrade"
75797464
volumeSuffix = "PDFs processed · last 30 days"
75807465

75817466
[portal.procurement]
@@ -7944,8 +7829,8 @@ appEditor = "Editor"
79447829
appProcessor = "Processor"
79457830
brandSuffix = "Stirling Processor"
79467831
docsCount = "{{docs}} docs"
7947-
docsProcessed = "Docs processed"
79487832
linkAccount = "Link Stirling account"
7833+
planEditor = "Editor plan"
79497834
planEnterprise = "Enterprise plan"
79507835
planProcessor = "Processor plan"
79517836
primaryNav = "Primary navigation"
@@ -8053,40 +7938,6 @@ action = "Sign in again"
80537938
body = "Your Stirling account session has expired. Sign in again to view billing — your instance stays linked."
80547939
title = "Session expired"
80557940

8056-
[portal.usageChart]
8057-
defaultLabel = "Docs processed · last 30 days"
8058-
delta = "{{pct}}% vs prior 30d"
8059-
docsValue = "{{value}} docs"
8060-
srAnnounce = "{{date}}: {{value}} docs"
8061-
8062-
[portal.useCases]
8063-
title = "Popular use cases"
8064-
viewAll = "View all pipelines"
8065-
8066-
[portal.useCases.items.authenticity]
8067-
blurb = "Cryptographic checks at the document boundary — signature validation, tamper detection, signing flows for outbound documents. Trust decisions in the pipeline, not your app code."
8068-
cta = "Try authenticity check"
8069-
eyebrow = "AUTHENTICITY"
8070-
title = "Verify signatures and detect tampering"
8071-
8072-
[portal.useCases.items.autoRouting]
8073-
blurb = "One classifier reads what arrived — KYC form, invoice, contract, COI — and routes to the right downstream pipeline. No manual triage, no docs in the wrong workflow."
8074-
cta = "Build a classifier pipeline"
8075-
eyebrow = "AUTO-ROUTING"
8076-
title = "Auto-classify and route incoming documents"
8077-
8078-
[portal.useCases.items.piiRedaction]
8079-
blurb = "Strip sensitive fields before storage, indexing, or LLM processing. Schema-aware, per-field audit, BYOK or HYOK keys. Compliance at the document boundary, not per pipeline."
8080-
cta = "See redaction pipelines"
8081-
eyebrow = "PII REDACTION"
8082-
title = "Redact PII before it leaves your stack"
8083-
8084-
[portal.useCases.items.trainingData]
8085-
blurb = "Batch-import an archive, redact PII, classify, chunk, and emit ready-to-load JSON for fine-tuning, eval sets, or RAG. Self-completing and replayable."
8086-
cta = "Build a training-data pipeline"
8087-
eyebrow = "TRAINING DATA"
8088-
title = "Turn PDFs into training data"
8089-
80907941
[portal.users]
80917942
title = "Users"
80927943

frontend/editor/src/portal/api/home.ts

Lines changed: 0 additions & 44 deletions
This file was deleted.

frontend/editor/src/portal/api/ops.ts

Lines changed: 0 additions & 37 deletions
This file was deleted.

0 commit comments

Comments
 (0)