Open-source manufacturing ERP, MES and QMS. Quoting, MRP, inventory, shop floor, quality and lot/serial traceability on one Postgres schema, with a REST API and MCP server. Self-host or use Carbon Cloud.
TypeScript ai-agentsbill-of-materialserpinventory-managementleanmanufacturingmanufacturing-execution-systemmcp-servermesmrpopen-source-erppostgresqlproduction-planningqmsquality-management-systemreact-routerself-hostedsupabasetraceabilitytypescript
Record header catalogue (mobile redesign)
Read-only survey of every call site of RecordChrome / RecordAction in the
working tree (2026-10-07). It is input to .ai/specs/2026-10-07-mobile-chrome-structure.md.
Building blocks
RecordChrome(apps/erp/app/components/Layout/RecordChrome.tsx)- Props:
hero {title, subtitle, status},menu,copyValue,bleed(-mx-4 -mt-4). - It writes
--header-heightand--hero-heightfrom the hero element. - The app bar ⋯ shows "Copy ID" plus
menu. - The bottom bar has a primary cell, a secondary cell, and a ⋯ button. The ⋯ button opens the "Actions" BottomSheet when the overflow count is above 0.
- Props:
RecordAction({slot})- Desktop: renders its children in place.
- Phones: portals the children into the slot's zustand-held target and counts them.
- The overflow sheet closes when a
buttonorais clicked, unless the click is inside[aria-haspopup]. - Sheet rows get their look from
[&_button]/[&_a]overrides, plus[&_.bg-destructive]:text-destructiveand[&>*_button+button]:w-11for the split-button chevron.
DocumentHeader- Props:
{title: string, subtitle?, status?, menuItems?, actions?, className?}. It rendersCardHeaderwith an h3 heading,Copy, a ⋯ menu when there are items, the status, the subtitle and an actions HStack. - This branch only added
className.
- Props:
- The common desktop ⋯ trigger is
IconButton aria-label=t\More options` icon=LuEllipsisVertical variant="secondary" size="sm"`.
Call sites (38)
Shell A (11): SalesOrder, Quote, SalesRFQ, SalesReturnOrder, PurchaseOrder, PurchaseReturnOrder, PurchasingRFQ, SupplierQuote, PurchaseInvoice, SalesInvoice, Job.
- Class:
flex flex-shrink-0 items-center justify-between gap-x-4 p-2 bg-card border-b h-[var(--header-height)] overflow-x-auto scrollbar-hide compact:hidden. - Left side: explorer toggle, Link > Heading h4 > id (plus
RevisionSuffixin Quote and PO), Copy, ⋯, status. - Right side: actions, then the properties toggle.
- Job has no
HStack w-fullwrapper.
Shell B (14):
- Members:
- 5 item headers: Material, Part, Tool, Service, Consumable.
- ChangeNotice, Issue, MaintenanceDispatch, PickingList, StockTransfer, Procedure, Training, QualityDocument, AssemblyInstruction.
- Class:
flex flex-shrink-0 items-center justify-between gap-x-4 px-4 py-2 bg-card border-b border-border h-[var(--header-height)] overflow-x-auto scrollbar-hide compact:hidden. - Item headers:
- Order: Link, Copy, status, ⋯. The right side holds
<DetailsTopbar links>. - They have 0 actions.
- On phones, DetailsTopbar registers the record tabs from inside the hidden shell.
- Order: Link, Copy, status, ⋯. The right side holds
- Status-first order (status, Copy, ⋯): ChangeNotice, Issue, Maintenance.
- Plain heading with no Link: PickingList, StockTransfer, Procedure, Training, QualityDocument.
- Badges inside the Heading: Procedure, Training, QualityDocument.
- Assembly:
- The title is a controlled
Input, guarded by{!isCompact && nameInput}. - It has no Copy.
- It has an "edited by" meta span.
- The title is a controlled
Other topbar headers:
- InspectionView:
- Raw
h1, status, and ametaLinesubtitle. - No Copy and no ⋯.
- Raw
- BuilderHeader:
- A
<header>withh-[var(--topbar-height)]. - The
WorkflowTitleis stateful, guarded by{!isCompact && …}, with aninHerovariant. - It also has a lock indicator and a SaveMarker.
- A
Company cards: Customer, Supplier.
CardTitlewith name, ⋯, thenCopy label icon.- No hero. Supplier also has
CardActionactions.
Card headers (7):
- Receipt, Shipment, WarehouseTransfer, Payment, Memo and FixedAsset use
DocumentHeader className="compact:hidden". - JournalEntryForm hand-rolls the same CardHeader.
bleedis set everywhere except WarehouseTransfer, which mounts RecordChrome inside the Card.- Payment and Memo mount RecordChrome inside the
ValidatedForm.
Actions-only:
- InventoryCount:
- The actions live in the table header's
primaryAction. - The Notes action is an icon-only IconButton.
- The actions live in the table header's
- Reimbursement:
<RecordChrome />with no props.
Facts that drive the design
menuandcopyValuealways equal the desktop ⋯ andCopy text. I found no mismatch.hero.titleis used only by Assembly and Builder.hero.subtitleis used only by Quote and PO (RevisionSubtitle) and by Inspection (metaLine).- Slot and variant duplicate each other: 9 files compute a slot and then restate the same condition as the Button's
variant. - About 14 action pairs disagree: the phone bar would show two filled buttons, or a primary-slot button styled secondary. The pairs:
- SO Invoice; Quote Lost; SalesRFQ No Quote.
- PI/SI Payment.
- Job Complete and Resume.
- Issue Complete; Maintenance Complete.
- PickingList Finish; StockTransfer Complete.
- WarehouseTransfer Shipments and Receive.
- Receipt Invoice and Post; Shipment Packing Slip.
- Builder Unpublish; Inspection Add Sample.
- PO alone patches its mismatch with
isCompact. - Non-Button action children:
- DropdownMenu triggers.
fetcher.Form,<form>,<Form>.- SplitButton (PO Finalize, Job Release).
- PrintButton, which owns its own Modal.
- Tooltip wrappers.
- Suspense/Await, including VersionMenu with
fallback={null}. - Assignee, a raw
<button>built frombuttonVariants. - An icon-only IconButton.
- Hazards:
- The item headers' DetailsTopbar must stay mounted on phones.
- Modals sit inside the hidden shell in 12 files.
- PrintButton sits in the overflow slot, so its Modal unmounts when the sheet closes.
- RecordAction counts children that render null, which can open an empty sheet.
- Button
- It reads no context itself; it gets OperatingSystem context indirectly through
useShortcutKeys. IconButtonwraps Button.bg-destructiveonly comes frombuttonVariants.variant.destructive.
- It reads no context itself; it gets OperatingSystem context indirectly through
- SplitButton
- It is a
div.flexholding two Buttons, and the chevron is a Radix trigger witharia-haspopup. - Its
disabledprop is declared but never used.
- It is a