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
style: make it feel better
Brad Barbin099ff087c2c6
diff --git a/.claude/settings.json b/.claude/settings.jsonnew file mode 100644index 0000000000..0f243d7ad0--- /dev/null+++ b/.claude/settings.json@@ -0,0 +1,5 @@+{+ "enabledPlugins": {+ "superpowers@claude-plugins-official": true+ }+}diff --git a/.claude/skills/forms/SKILL.md b/.claude/skills/forms/SKILL.mdnew file mode 100644index 0000000000..2bd9327909--- /dev/null+++ b/.claude/skills/forms/SKILL.md@@ -0,0 +1,248 @@+---+name: forms+description: Use when building, editing, or adding forms in the Carbon ERP/MES codebase - covers ValidatedForm, zod validators, form components, and action handlers+---++# Carbon Forms++Forms in Carbon follow a three-part pattern: **zod validator** in the module's `.models.ts`, **form component** in the module's `ui/` directory, and **action handler** in the route file.++## File Locations++| Piece | ERP Location | MES Location |+|-------|-------------|-------------|+| Validator | `app/modules/{module}/{module}.models.ts` | `app/services/models.ts` |+| Form UI | `app/modules/{module}/ui/{Feature}/{Feature}Form.tsx` | Inline in route or `app/components/` |+| Route action | `app/routes/x+/{module}+/{resource}.new.tsx` | `app/routes/x+/{resource}.tsx` |+| Form components | `~/components/Form` (re-exports `@carbon/form` + domain selectors) | `@carbon/form` directly |++## 1. Validator (zod schema)++Define in the module's `.models.ts`. Use `z` from `zod` and `zfd` from `zod-form-data`.++```typescript+import { z } from "zod";+import { zfd } from "zod-form-data";++export const thingValidator = z.object({+ id: zfd.text(z.string().optional()), // optional ID for create/edit+ name: z.string().min(1, { message: "Name is required" }),+ type: z.enum(thingTypes, { // enum with custom error+ errorMap: () => ({ message: "Type is required" })+ }),+ quantity: zfd.numeric(z.number().min(0)), // numeric from FormData+ isActive: zfd.checkbox(), // checkbox boolean+ notes: zfd.text(z.string().optional()), // optional text+ items: z.array(z.string().min(1)).min(1, { // required array+ message: "At least one item is required"+ }),+});+```++**Key rules:**++- Use `zfd.text()` for optional strings from FormData+- Use `zfd.numeric()` for numbers from FormData+- Use `zfd.checkbox()` for boolean checkboxes+- Use `z.enum()` with `errorMap` for enum fields+- Use `.refine()` for cross-field validation++## 2. Form Component++The core of any form is `ValidatedForm` wrapping your fields. The surrounding container varies by context — Drawers, Cards, inline sections, modals, etc. Look at neighboring routes to match the existing pattern.++Import form fields from `~/components/Form` (ERP) or `@carbon/form` (MES).++```typescript+import { ValidatedForm } from "@carbon/form";+import { Button, HStack, VStack } from "@carbon/react";+import { useNavigate } from "react-router";+import type { z } from "zod";+import { Hidden, Input, Select, Submit } from "~/components/Form";+import { usePermissions } from "~/hooks";+import { thingValidator } from "~/modules/things";+import { path } from "~/utils/path";++type ThingFormProps = {+ initialValues: z.infer<typeof thingValidator>;+};++const ThingForm = ({ initialValues }: ThingFormProps) => {+ const permissions = usePermissions();+ const navigate = useNavigate();+ const onClose = () => navigate(-1);++ const isEditing = !!initialValues.id;+ const isDisabled = isEditing+ ? !permissions.can("update", "things")+ : !permissions.can("create", "things");++ return (+ <ValidatedForm+ validator={thingValidator}+ method="post"+ action={isEditing ? path.to.thing(initialValues.id!) : path.to.newThing}+ defaultValues={initialValues}+ >+ <Hidden name="id" />+ <VStack spacing={4}>+ <Input name="name" label="Name" />+ <Select name="type" label="Type" options={typeOptions} />+ </VStack>+ <HStack>+ <Submit isDisabled={isDisabled}>Save</Submit>+ <Button size="md" variant="solid" onClick={onClose}>Cancel</Button>+ </HStack>+ </ValidatedForm>+ );+};+```++**Key rules:**++- Always include `<Hidden name="id" />` for edit support+- Use `VStack spacing={4}` for vertical field layout+- Use `grid grid-cols-1 lg:grid-cols-3 gap-x-8 gap-y-4` for multi-column layouts+- Permission check determines `isDisabled` on Submit+- Type props with `z.infer<typeof validator>`++## 3. Route Action++```typescript+import { assertIsPost, error, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import { validationError, validator } from "@carbon/form";+import type { ActionFunctionArgs } from "react-router";+import { data, redirect } from "react-router";+import { thingValidator, insertThing } from "~/modules/things";+import { path } from "~/utils/path";++export async function action({ request }: ActionFunctionArgs) {+ assertIsPost(request);+ const { client, companyId, userId } = await requirePermissions(request, {+ create: "things"+ });++ const validation = await validator(thingValidator).validate(+ await request.formData()+ );++ if (validation.error) {+ return validationError(validation.error);+ }++ const result = await insertThing(client, {+ ...validation.data,+ companyId,+ createdBy: userId+ });++ if (result.error) {+ return data({}, await flash(request, error(result.error, "Failed to create thing")));+ }++ throw redirect(path.to.things, await flash(request, success("Thing created")));+}+```++**Key rules:**+- `assertIsPost(request)` first+- `requirePermissions` with appropriate module/action+- `validator(schema).validate(formData)` - NOT `schema.parse()`+- Return `validationError(validation.error)` on failure (422 status)+- `throw redirect()` on success (not `return redirect()`)+- Return plain objects from actions, never `Response.json()`++## 4. Route Default Export++```typescript+export default function NewThingRoute() {+ const initialValues = {+ id: "",+ name: "",+ type: "Default" as const,+ };+ return <ThingForm initialValues={initialValues} />;+}+```++For edit routes, load data in the loader and pass to the form:++```typescript+export default function EditThingRoute() {+ const { thing } = useLoaderData<typeof loader>();+ return <ThingForm initialValues={thing} />;+}+```++## Available Form Components++**From `@carbon/form` (base):**++| Component | Props | Use for |+|-----------|-------|---------|+| `Input` | `name, label, prefix?, suffix?, helperText?` | Text fields |+| `Number` | `name, label, formatOptions?` | Numeric fields with steppers |+| `TextArea` | `name, label, characterLimit?` | Multi-line text |+| `Select` | `name, label, options: {label, value}[]` | Dropdown |+| `Combobox` | `name, label, options: {label, value}[]` | Searchable dropdown |+| `CreatableCombobox` | `name, label, options, onCreateOption?` | Searchable + create new |+| `MultiSelect` | `name, label, options` | Multi-select |+| `Boolean` | `name, label, description?` | Switch/toggle |+| `DatePicker` | `name, label, minValue?, maxValue?` | Date selection |+| `DateTimePicker` | `name, label` | Date + time |+| `TimePicker` | `name, label` | Time only |+| `Hidden` | `name, value?` | Hidden fields |+| `Password` | `name, label` | Password with toggle |+| `Radios` | `name, label, options, orientation?` | Radio buttons |+| `Submit` | `isDisabled?, withBlocker?` | Submit with unsaved changes warning |+| `Array` | `name, label` | Dynamic list fields |++**From `~/components/Form` (ERP domain selectors):**++`Customer`, `Supplier`, `Employee`, `Employees`, `Users`, `Item`, `Part`, `Location`, `Account`, `AccountCategory`, `AccountSubcategory`, `Currency`, `Department`, `WorkCenter`, `UnitOfMeasure`, `PaymentTerm`, `ShippingMethod`, `Shift`, `Sequence`, `Process`, `Procedure`, `Tool`, `Tags`, `CustomFormFields`++These are `Combobox`/`CreatableCombobox` wrappers that auto-load options from stores. Use them instead of raw Combobox when the entity type matches.++## Common Patterns++**Dependent fields** (value of one field changes options of another):+```typescript+const [categoryId, setCategoryId] = useState(initialValues.categoryId ?? "");++<AccountCategory name="categoryId" onChange={(cat) => setCategoryId(cat?.id ?? "")} />+<AccountSubcategory name="subcategoryId" accountCategoryId={categoryId} />+```++**Enum options from const array:**+```typescript+const typeOptions = thingTypes.map((t) => ({ label: t, value: t }));+<Select name="type" label="Type" options={typeOptions} />+```++**Client action for cache invalidation:**+```typescript+export async function clientAction({ serverAction }: ClientActionFunctionArgs) {+ const companyId = getCompanyId();+ window.clientCache?.invalidateQueries({+ predicate: (query) => {+ const queryKey = query.queryKey as string[];+ return queryKey[0] === "things" && queryKey[1] === companyId;+ }+ });+ return await serverAction();+}+```++## Checklist++When building a new form:++1. Define zod validator in `{module}.models.ts`+2. Export validator from module index+3. Create form component in `ui/{Feature}/{Feature}Form.tsx`+4. Create route file with action + default export+5. Add `clientAction` if the entity is cached client-side+6. Add path helpers in `~/utils/path` if needed+7. Check neighboring routes to match the container pattern (Drawer, Card, inline, etc.)diff --git a/llm/tasks/todo.md b/llm/tasks/todo.mdindex 7625648bd1..5544d52ec5 100644--- a/llm/tasks/todo.md+++ b/llm/tasks/todo.md@@ -1,40 +1,28 @@-# Shelf → StorageUnit leftover rename sweep+# MRP Refactoring — Level-by-Level Processing with Inventory Netting-Scope: red + yellow audit items except activity-log strings in `post-stock-transfer/index.ts` (kept for historical consistency) and `companySettings.shelfLabelSize` (kept as physical label concept).+Spawn subtasks to query the cache folder any time I need to learn something about the codebase. NEVER update the cache with plans or information about code that is not yet committed.-Note: Spawn subtasks to query the cache folder any time I need to learn something about the codebase. NEVER update the cache with plans or information about code that is not yet committed.+## Phase 1: Bulk Data Pre-loading+- [x] 1.1 Bulk-load item metadata (replenishmentSystem, leadTime) — replace per-item fetchItemMetadata+- [x] 1.2 Bulk-load inventory (itemLedger SUM by itemId+locationId)+- [x] 1.3 Bulk-load all BOMs (activeMakeMethods view + methodMaterial filtered to active methods)+- [x] 1.4 Build supply maps from already-fetched production/purchase order data-## Plan+## Phase 2: Level-by-Level Processing with Inventory Netting+- [x] 2.1 Compute Low Level Codes from pre-loaded BOM structure+- [x] 2.2 Collect all independent demands into grossDemand map (no BOM explosion yet)+- [x] 2.3 Implement level-by-level processor: aggregate → net against on-hand → propagate net requirement to children+- [x] 2.4 Track BOM-derived demand separately; write only BOM-derived to demandForecast+- [x] 2.5 Keep demandActual and supplyActual writes unchanged-- [x] 1. `apps/erp/app/modules/items/types.ts` — renamed `ItemShelfQuantities` → `ItemStorageUnitQuantities`-- [x] 2. `apps/erp/app/stores/stock-transfer.ts` — renamed store exports (selectedToItemStorageUnitIds, toggleToItemStorageUnitSelection, isToItemStorageUnitSelected, hasTransferLinesToItemStorageUnit, clearSelectedToItemStorageUnits)-- [x] 3. `StockTransferWizard.tsx` — imports + `transferLinesToThisItemStorageUnit`-- [x] 4. `StockTransferLines.tsx` — `toStorageUnitComparison`-- [x] 5. `InventoryStorageUnits.tsx` — `selectedStorageUnitId` / `setSelectedStorageUnitId` + type import + `InventoryStorageUnitsProps`-- [x] 6. `InventoryDetails.tsx` — type import-- [x] 7. `KanbanForm.tsx` — `setStorageUnitId`-- [x] 8. `ShipmentLines.tsx` — `getStorageUnitFromBatchNumber`-- [x] 9. `ReceiptLines.tsx` — `newStorageUnitModal`-- [x] 10. `JobHeader.tsx` — `setDefaultStorageUnitId`-- [x] 11. `JobMaterialsTable.tsx` — `hasStorageUnitQuantityFlag`-- [x] 12. `stock-transfer+/$id.scan.$lineId.tsx` — error strings + `currentStorageUnitId`-- [x] 13. `supabase/functions/issue/index.ts` — `proposedStorageUnitId`, `currentStorageUnitQuantity`, `allStorageUnitQuantities`, `finalStorageUnitId`, `bestStorageUnit`-- [x] 14. `JobOperation.tsx:1119` — `Default Storage Unit`-- [x] 15. `KanbanLabelPDF.tsx:183` — comment updated+## Phase 3: Performance+- [x] 3.1 Chunked batch writes (500 rows per batch)+- [x] 3.2 Removed per-item RPC calls (get_method_tree), per-item metadata fetches-## Review--All 13 red/yellow action items landed mechanically. Kept out of scope per user decision:-- Activity-log strings `"From Shelf"` / `"To Shelf"` / `"Shelf"` in `post-stock-transfer/index.ts` (kept for historical audit-trail consistency)-- `companySettings.shelfLabelSize` column (kept as physical label concept)+## Phase 4: Cleanup+- [x] 4.1 Removed dead code (fetchItemMetadata, fetchBomRequirements, processRequirement, traverseBomTree, BomNode, ItemRequirement types)+- [x] 4.2 Removed unused variables (parentItemByMethodId, productionSupplyByLocationItem, purchaseSupplyByLocationItem)+- [ ] 4.3 Verify planning views still produce correct results (requires deployment)-Follow-ups for the user:-1. Run `lingui:extract` + `lingui:compile` to pick up the `Default Shelf` → `Default Storage Unit` msgid change in MES.-2. After DB migrations fully apply, regenerate Supabase types (`types.ts` / `swagger-docs-schema.ts` / `functions/lib/types.ts`) — stale references to `purchaseInvoiceLine.shelfId` and `warehouseTransferLine_*ShelfId_fkey` will drop out.--Verified with grep: no remaining `shelf`/`Shelf`/`shelves` identifiers in `apps/` or `packages/` outside of:-- `apps/erp/app/routes/api+/data/quality.ts` (legit "shelf-life" material domain)-- `packages/database/supabase/functions/post-stock-transfer/index.ts` (audit-log strings — intentionally kept)-- Historical SQL migrations (immutable)-- Generated `types.ts` / `swagger-docs-schema.ts` (regeneration pending)-- `llm/cache/*` and `llm/recommendations/*` (stale doc cache)+## Review+(to be filled after verification)diff --git a/packages/react/src/Accordion.tsx b/packages/react/src/Accordion.tsxindex 6bfdcd144d..20e5659410 100644--- a/packages/react/src/Accordion.tsx+++ b/packages/react/src/Accordion.tsx@@ -29,7 +29,7 @@ const AccordionTrigger = forwardRef<<AccordionPrimitive.Triggerref={ref}className={cn(- "flex flex-1 items-center justify-between py-4 font-medium transition-all text-muted-foreground hover:text-foreground [&[data-state=open]>svg]:rotate-180",+ "flex flex-1 items-center justify-between py-4 font-medium transition-colors text-muted-foreground hover:text-foreground [&[data-state=open]>svg]:rotate-180",className)}{...props}diff --git a/packages/react/src/Badge.tsx b/packages/react/src/Badge.tsxindex 445bf7fe40..1678cc29e2 100644--- a/packages/react/src/Badge.tsx+++ b/packages/react/src/Badge.tsx@@ -64,12 +64,12 @@ const BadgeCloseButton = forwardRef<>(({ className, ...props }, ref) => (<buttonclassName={cn(- "ml-1 ring-offset-background rounded-full outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 text-muted-foreground hover:text-foreground flex-shrink-0",+ "relative ml-1 ring-offset-background rounded-full outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 text-muted-foreground hover:text-foreground flex-shrink-0 before:absolute before:-inset-2 before:content-['']",className)}{...props}>- <LuX className="h-3 w-3 " />+ <LuX className="h-3 w-3" /></button>));BadgeCloseButton.displayName = "BadgeCloseButton";diff --git a/packages/react/src/BarProgress.tsx b/packages/react/src/BarProgress.tsxindex f80fbedbd3..7d65a954fd 100644--- a/packages/react/src/BarProgress.tsx+++ b/packages/react/src/BarProgress.tsx@@ -126,7 +126,7 @@ export function BarProgress({<div />)}{value && (- <span className="text-xs font-mono text-muted-foreground">+ <span className="text-xs font-mono tabular-nums text-muted-foreground">{value}</span>)}diff --git a/packages/react/src/Button.tsx b/packages/react/src/Button.tsxindex a1be118903..8f0a828c94 100644--- a/packages/react/src/Button.tsx+++ b/packages/react/src/Button.tsx@@ -14,7 +14,7 @@ export const buttonVariants = cva(// Transition: background/colors use 'ease' (150ms), transform uses 'ease-out' for responsive press feel"transform-gpu transition-[background-color,color,transform,box-shadow] duration-150 ease",// Active state: subtle scale down for tactile press feedback- "active:scale-[0.97] active:duration-75 active:ease-out",+ "active:scale-[0.96] active:duration-75 active:ease-out",// Accessibility: respect reduced motion preferences"motion-reduce:transform-none motion-reduce:transition-[background-color,color,box-shadow] corner-squircle"],diff --git a/packages/react/src/Card.tsx b/packages/react/src/Card.tsxindex 6b7ca32a3e..7b96f5e314 100644--- a/packages/react/src/Card.tsx+++ b/packages/react/src/Card.tsx@@ -168,7 +168,7 @@ const CardTitle = forwardRef<<h3ref={ref}className={cn(- "text-base font-medium font-headline leading-none tracking-tight text-foreground/90 line-clamp-2",+ "text-base font-medium font-headline leading-none tracking-tight text-foreground/90 text-pretty line-clamp-2",className)}{...props}diff --git a/packages/react/src/Command.tsx b/packages/react/src/Command.tsxindex dd43c34647..bcbd8d0e12 100644--- a/packages/react/src/Command.tsx+++ b/packages/react/src/Command.tsx@@ -263,7 +263,7 @@ const CommandShortcut = ({CommandShortcut.displayName = "CommandShortcut";const commandTriggerVariants = cva(- "items-center justify-between [&>span]:line-clamp-1 overflow-hidden hover:scale-100 focus-visible:scale-100 transition-all duration-150 ease-in-out",+ "items-center justify-between [&>span]:line-clamp-1 overflow-hidden hover:scale-100 focus-visible:scale-100 transition-[background-color,color,transform] duration-150 ease-in-out",{variants: {size: {@@ -274,7 +274,7 @@ const commandTriggerVariants = cva(asButton: {false:"text-foreground flex w-full whitespace-nowrap rounded-md border border-input ring-offset-background data-[placeholder]:text-muted-foreground ring-offset-background focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1 overflow-hidden",- true: "text-foreground relative font-medium shrink-0 group inline-flex select-none transform-gpu initial:border-none disabled:opacity-50 focus:!outline-none focus:!ring-0 active:!outline-none active:!ring-0 after:pointer-events-none after:absolute after:-inset-[3px] after:rounded-lg after:border after:border-blue-500 after:opacity-0 after:ring-2 after:ring-blue-500/20 after:transition-opacity focus-visible:after:opacity-100 active:after:opacity-0 before:pointer-events-none before:bg-gradient-to-b before:transition-opacity before:from-white/[0.12] before:absolute before:inset-0 before:z-[1] before:rounded before:opacity-0 bg-background hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50 shadow-button-base hover:scale-95 focus-visible:scale-95 transition-all duration-150 ease-in-out"+ true: "text-foreground relative font-medium shrink-0 group inline-flex select-none transform-gpu initial:border-none disabled:opacity-50 focus:!outline-none focus:!ring-0 active:!outline-none active:!ring-0 after:pointer-events-none after:absolute after:-inset-[3px] after:rounded-lg after:border after:border-blue-500 after:opacity-0 after:ring-2 after:ring-blue-500/20 after:transition-opacity focus-visible:after:opacity-100 active:after:opacity-0 before:pointer-events-none before:bg-gradient-to-b before:transition-opacity before:from-white/[0.12] before:absolute before:inset-0 before:z-[1] before:rounded before:opacity-0 bg-background hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50 shadow-button-base hover:scale-95 focus-visible:scale-95 transition-[background-color,color,transform,box-shadow] duration-150 ease-in-out"}},defaultVariants: {diff --git a/packages/react/src/Count.tsx b/packages/react/src/Count.tsxindex ac79c29962..7eb77d35a6 100644--- a/packages/react/src/Count.tsx+++ b/packages/react/src/Count.tsx@@ -6,7 +6,13 @@ export interface CountProps extends ComponentProps<typeof Badge> {const Count = ({ count, ...props }: CountProps) => {const c = count > 99 ? "99+" : count;- return <Badge variant="secondary" {...props}>{`${c}`}</Badge>;+ return (+ <Badge+ variant="secondary"+ className="tabular-nums"+ {...props}+ >{`${c}`}</Badge>+ );};export { Count };diff --git a/packages/react/src/Drawer.tsx b/packages/react/src/Drawer.tsxindex 988043bd71..b09930e69b 100644--- a/packages/react/src/Drawer.tsx+++ b/packages/react/src/Drawer.tsx@@ -64,7 +64,7 @@ const DrawerBody = ({}: HTMLAttributes<HTMLDivElement>) => (<divclassName={cn(- "flex flex-col flex-1 items-start justify-start overflow-y-auto scrollbar-thin scrollbar-track-transparent scrollbar-thumb-accent w-full p-6 bg-card dark:bg-muted/40 rounded-2xl border border-border",+ "flex flex-col flex-1 items-start justify-start overflow-y-auto scrollbar-thin scrollbar-track-transparent scrollbar-thumb-accent w-full p-6 bg-card dark:bg-muted/40 rounded-xl border border-border",className)}{...props}@@ -73,7 +73,7 @@ const DrawerBody = ({DrawerBody.displayName = "DrawerBody";const sheetVariants = cva(- "flex flex-col z-50 scale-100 bg-accent dark:bg-card opacity-100 shadow-button-base dark:shadow-[inset_0_0.5px_0_rgb(255_255_255_/_0.08),_inset_0_0_1px_rgb(255_255_255_/_0.24),_0_0_0_0.5px_rgb(0,0,0,1),0px_0px_4px_rgba(0,_0,_0,_0.08)] border border-border transition-all duration-100 focus-visible:outline-none focus-visible:ring-0 rounded-2xl",+ "flex flex-col z-50 scale-100 bg-accent dark:bg-card opacity-100 shadow-button-base dark:shadow-[inset_0_0.5px_0_rgb(255_255_255_/_0.08),_inset_0_0_1px_rgb(255_255_255_/_0.24),_0_0_0_0.5px_rgb(0,0,0,1),0px_0px_4px_rgba(0,_0,_0,_0.08)] border border-border transition-[background-color,box-shadow,border-color] duration-100 focus-visible:outline-none focus-visible:ring-0 rounded-2xl",{variants: {position: {@@ -195,9 +195,9 @@ const DrawerContent = forwardRef<{children}<DialogPrimitive.Closetype="button"- className="absolute right-4 top-3 rounded-full opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary"+ className="absolute right-4 top-3 rounded-full p-2 opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary">- <LuX className="h-6 w-6" />+ <LuX className="h-5 w-5" /><span className="sr-only">Close</span></DialogPrimitive.Close></DialogPrimitive.Content>@@ -243,7 +243,7 @@ const DrawerTitle = forwardRef<<DialogPrimitive.Titleref={ref}className={cn(- "text-base font-medium font-headline leading-none tracking-tight text-foreground/90 line-clamp-1",+ "text-base font-medium font-headline leading-none tracking-tight text-foreground/90 text-balance line-clamp-1",className)}{...props}diff --git a/packages/react/src/Editor/Editor.tsx b/packages/react/src/Editor/Editor.tsxindex 71a788531b..1a7b6b0d21 100644--- a/packages/react/src/Editor/Editor.tsx+++ b/packages/react/src/Editor/Editor.tsx@@ -162,7 +162,7 @@ const Editor = ({}}slotAfter={<ImageResizer />}>- <EditorCommand className="z-50 h-auto max-h-[330px] overflow-y-auto rounded-md border border-muted bg-background px-1 py-2 shadow-md transition-all">+ <EditorCommand className="z-50 h-auto max-h-[330px] overflow-y-auto rounded-md border border-muted bg-background px-1 py-2 shadow-md transition-[opacity,transform]"><EditorCommandEmpty className="px-2 text-muted-foreground">No results</EditorCommandEmpty>diff --git a/packages/react/src/Editor/components/LinkSelector.tsx b/packages/react/src/Editor/components/LinkSelector.tsxindex a8aec4327b..20555b592c 100644--- a/packages/react/src/Editor/components/LinkSelector.tsx+++ b/packages/react/src/Editor/components/LinkSelector.tsx@@ -68,7 +68,7 @@ export const LinkSelector = ({ open, onOpenChange }: LinkSelectorProps) => {icon={<LuTrash className="h-4 w-4" />}variant="secondary"type="button"- className="flex h-8 items-center rounded-sm p-1 text-red-600 transition-all hover:bg-red-100 dark:hover:bg-red-800"+ className="flex h-8 items-center rounded-sm p-1 text-red-600 transition-colors hover:bg-red-100 dark:hover:bg-red-800"onClick={() => {editor.chain().focus().unsetLink().run();}}diff --git a/packages/react/src/Heading.tsx b/packages/react/src/Heading.tsxindex 11773ef834..dc2c1b096d 100644--- a/packages/react/src/Heading.tsx+++ b/packages/react/src/Heading.tsx@@ -6,7 +6,7 @@ import { forwardRef } from "react";import { cn } from "./utils/cn";const headingVariants = cva(- "font-semibold font-headline leading-none tracking-tight text-foreground",+ "font-semibold font-headline leading-none tracking-tight text-foreground text-balance",{variants: {size: {diff --git a/packages/react/src/Modal.tsx b/packages/react/src/Modal.tsxindex 010449aaa0..74b84797de 100644--- a/packages/react/src/Modal.tsx+++ b/packages/react/src/Modal.tsx@@ -91,7 +91,7 @@ const ModalContent = forwardRef<{withCloseButton && (<DialogPrimitive.Closetype="button"- className="absolute right-4 top-4 rounded-full opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-foreground-muted p-2 hover:bg-accent/80"+ className="absolute right-4 top-4 rounded-full opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-foreground-muted p-3 hover:bg-accent/80"><LuX className="h-4 w-4" /><span className="sr-only">Close</span>@@ -145,7 +145,7 @@ const ModalTitle = forwardRef<<DialogPrimitive.Titleref={ref}className={cn(- "text-base font-medium font-headline leading-none tracking-tight text-foreground",+ "text-base font-medium font-headline leading-none tracking-tight text-foreground text-balance",className)}{...props}diff --git a/packages/react/src/Paragraph.tsx b/packages/react/src/Paragraph.tsxindex 833e8a4297..99818c6da8 100644--- a/packages/react/src/Paragraph.tsx+++ b/packages/react/src/Paragraph.tsx@@ -2,7 +2,7 @@ import { cn } from "@carbon/react";const paragraphVariants = {base: {- text: "font-sans text-base font-normal text-muted-foreground",+ text: "font-sans text-base font-normal text-muted-foreground text-pretty",spacing: "mb-3"},"base/bright": {diff --git a/packages/react/src/Progress.tsx b/packages/react/src/Progress.tsxindex c07c7ad7f1..78213b53ab 100644--- a/packages/react/src/Progress.tsx+++ b/packages/react/src/Progress.tsx@@ -30,13 +30,13 @@ const Progress = forwardRef<><ProgressPrimitive.IndicatorclassName={cn(- "h-full w-full flex-1 bg-emerald-500 transition-all",+ "h-full w-full flex-1 bg-emerald-500 transition-transform",indicatorClassName)}style={{ transform: `translateX(-${100 - (value || 0)}%)` }}/>{numerator !== undefined && denominator !== undefined && (- <span className="absolute text-[9px] text-foreground right-2 top-1/2 transform -translate-y-1/2">+ <span className="absolute text-[9px] tabular-nums text-foreground right-2 top-1/2 transform -translate-y-1/2">{numerator} of {denominator}</span>)}diff --git a/packages/react/src/Sidebar.tsx b/packages/react/src/Sidebar.tsxindex b56a5784a9..475701757f 100644--- a/packages/react/src/Sidebar.tsx+++ b/packages/react/src/Sidebar.tsx@@ -302,7 +302,7 @@ const SidebarRail = React.forwardRef<onClick={toggleSidebar}title="Toggle Sidebar"className={cn(- "absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all duration-150 ease-out motion-reduce:transition-none after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex",+ "absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-opacity duration-150 ease-out motion-reduce:transition-none after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex","[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-sidebar",diff --git a/packages/react/src/Tabs.tsx b/packages/react/src/Tabs.tsxindex 3d3bf4aa06..8fc21f3529 100644--- a/packages/react/src/Tabs.tsx+++ b/packages/react/src/Tabs.tsx@@ -32,7 +32,7 @@ const TabsTrigger = forwardRef<<TabsPrimitive.Triggerref={ref}className={cn(- "inline-flex items-center justify-center whitespace-nowrap rounded-[6px] px-3 py-1 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",+ "inline-flex items-center justify-center whitespace-nowrap rounded-[6px] px-3 py-1 text-sm font-medium ring-offset-background transition-[background-color,color,box-shadow] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50","data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-button-base",className