Enums reference
Lattice uses backed enums for the fixed vocabularies that appear in builders — alignments, gaps, variants, operators, and so on. Each is generated to a TypeScript union too, so the PHP value and the client type can’t drift. The string value in parentheses is what ends up on the wire.
The case lists below are generated by reflecting over the real enums, so this page can never fall behind the code.
Layout & spacing
Section titled “Layout & spacing”Lattice\Ui\Enums — the vocabulary for arranging components, used by Stack and the other
layout primitives.
| Enum | Cases (value) |
|---|---|
Align | Center (center), Left (left), Start (start), Stretch (stretch) |
Breakpoint | Default (default), Sm (sm), Md (md), Lg (lg), Xl (xl), Xxl (2xl) |
Justify | Start (start), Center (center), End (end), Between (between), Around (around), Evenly (evenly) |
Gap | None (none), ExtraSmall (xs), Small (sm), Medium (md), Large (lg), ExtraLarge (xl) |
Width | Full (full), Auto (auto), Small (sm), Medium (md), Large (lg), ExtraLarge (xl), Fill (fill) |
Height | Full (full), Screen (screen) |
ColumnWidth | Xs (xs), Sm (sm), Md (md), Lg (lg), Xl (xl) |
ModalWidth | Sm (sm), Md (md), Lg (lg), Xl (xl), Xl2 (2xl), Xl3 (3xl) |
ModalHeight | Sm (sm), Md (md), Lg (lg), Xl (xl), Xl2 (2xl), Xl3 (3xl) |
Orientation | Horizontal (horizontal), Vertical (vertical) |
StackDirection | Row (row), Column (column) |
Placement | Top (top), Bottom (bottom), Right (right) |
FloatingPlacement | BottomEnd (bottom-end), BottomStart (bottom-start), TopEnd (top-end), TopStart (top-start) |
PopoverSide | Top (top), Right (right), Bottom (bottom), Left (left) |
PopoverAlign | Start (start), Center (center), End (end) |
Side | Start (start), End (end) |
TabsAlignment | Start (start), Center (center), End (end), Stretch (stretch) |
Lattice\Core\Enums — how a page frames itself and which
layout it renders into.
| Enum | Cases (value) |
|---|---|
PageLayout | App (app), Auth (auth), None (none) |
PageWidth | Full (full), ExtraLarge (xl), Large (lg), Medium (md), Small (sm) |
Text & sizing
Section titled “Text & sizing”Sizing lives in Lattice\Ui\Enums; the color vocabulary lives in
Lattice\Core\Enums and backs the Color value object.
| Enum | Namespace | Cases (value) |
|---|---|---|
Size | Ui\Enums | Xs (xs), Sm (sm), Md (md), Lg (lg), Xl (xl), Xl2 (2xl), Xl3 (3xl), Xl4 (4xl) |
ColorName | Core\Enums | Default (default), Muted (muted), Primary (primary), Success (success), Info (info), Warning (warning), Danger (danger), Gray (gray), Red (red), Orange (orange), Yellow (yellow), Green (green), Blue (blue), Purple (purple) |
ColorKind | Core\Enums | Named (named), Css (css) |
The icon names a Lattice\Ui\Enums\Icon accepts are the enum’s own cases — one per bundled
SVG. The Icons page covers where they come from and how to add your own.
Code blocks
Section titled “Code blocks”Lattice\Ui\Enums\CodeBlockLanguage — the built-in syntax languages accepted by a
CodeBlock component.
| Enum | Cases (value) |
|---|---|
CodeBlockLanguage | Text (text), Json (json), JavaScript (javascript), Shell (shell), Php (php) |
Buttons & feedback
Section titled “Buttons & feedback”Lattice\Ui\Enums
| Enum | Cases (value) |
|---|---|
Variant | Primary (primary), Secondary (secondary), Success (success), Info (info), Warning (warning), Danger (danger) |
Emphasis | Solid (solid), Outline (outline), Ghost (ghost), Link (link) |
ButtonType | Button (button), Submit (submit), Reset (reset) |
Variant is used by toasts and callouts.
Lattice\Ui\Enums\HttpMethod — the request method used by links, forms, and actions.
| Enum | Cases (value) |
|---|---|
HttpMethod | Get (get), Post (post), Put (put), Patch (patch), Delete (delete) |
Operators
Section titled “Operators”Lattice\Core\Enums\Op — the shared comparison vocabulary used by both
form conditions and table filters.
| Enum | Cases (value) |
|---|---|
Op | Contains (contains), StartsWith (starts_with), EndsWith (ends_with), Equals (eq), NotEquals (neq), GreaterThan (gt), GreaterThanOrEqual (gte), LessThan (lt), LessThanOrEqual (lte), In (in), NotIn (not_in), Before (before), After (after), Empty (empty), Filled (filled) |
Tables
Section titled “Tables”Lattice\Table\Enums — column types, alignment, width, filtering, and pagination for
tables.
| Enum | Cases (value) |
|---|---|
ColumnType | Text (column.text), Boolean (column.boolean), Number (column.number), Money (column.money), Stack (column.stack), Badge (column.badge), Icon (column.icon), Image (column.image) |
ColumnAlign | Start (start), Center (center), End (end) |
ColumnPin | Left (left), Right (right) |
FilterType | Text (text), Number (number), Date (date), Boolean (boolean) |
FilterControl | Select (filter.select), Ternary (filter.ternary), DateRange (filter.date-range), Toggle (filter.toggle) |
PaginationType | None (none), Simple (simple), Table (table), Infinite (infinite) |
SortDirection | Asc (asc), Desc (desc) |
The row layout and built-in row actions used by the repeater and builder fields, plus the field-type vocabulary.
| Enum | Namespace | Cases (value) |
|---|---|---|
FieldType | Form\Enums | Builder (field.builder), Checkbox (field.checkbox), Choice (field.choice), ColorPicker (field.color-picker), DateInput (field.date-input), DateTimeInput (field.date-time-input), FileUpload (field.file-upload), HiddenInput (field.hidden-input), NumberInput (field.number-input), Otp (field.otp), PasswordInput (field.password-input), PatternInput (field.pattern-input), Repeater (field.repeater), RichEditor (field.rich-editor), Select (field.select), Textarea (field.textarea), TextInput (field.text-input), TimeInput (field.time-input), Toggle (field.toggle) |
RowActionType | Form\Enums | Duplicate (duplicate), Remove (remove) |
RowLayout | Form\Enums | Stack (stack), Table (table) |
Description lists
Section titled “Description lists”Lattice\Ui\Enums — the entry-type vocabulary of the
description list.
| Enum | Cases (value) |
|---|---|
EntryType | Badge (entry.badge), Boolean (entry.boolean), Component (entry.component), Date (entry.date), Text (entry.text) |
Formatting
Section titled “Formatting”Lattice\Ui\Enums — date/time and number formatting options shared by UI components and
tables.
| Enum | Cases (value) |
|---|---|
DateTimeStyle | Full (full), Long (long), Medium (medium), Short (short) |
NumberFormatUnit | Percent (percent), Kilogram (kilogram), Gram (gram), Kilometer (kilometer), Meter (meter), Byte (byte), Kilobyte (kilobyte), Megabyte (megabyte), Gigabyte (gigabyte), Millisecond (millisecond), Second (second), Minute (minute), Hour (hour), Celsius (celsius), Fahrenheit (fahrenheit) |
Charts
Section titled “Charts”Lattice\Ui\Enums — the series shapes a Chart component can render.
| Enum | Cases (value) |
|---|---|
ChartSeriesType | Area (area), Bar (bar), Distribution (distribution), Gauge (gauge), Line (line), Pie (pie) |
Progress
Section titled “Progress”Lattice\Ui\Enums — the bar and circle variants of the
progress component.
| Enum | Cases (value) |
|---|---|
ProgressShape | Bar (bar), Circle (circle) |
Avatar
Section titled “Avatar”Lattice\Ui\Enums — the outline an avatar is clipped to.
| Enum | Cases (value) |
|---|---|
AvatarShape | Circle (circle), Rounded (rounded) |
Lattice\Chat\Enums — the message roles and part kinds used by the chat components.
| Enum | Cases (value) |
|---|---|
ChatRole | User (user), Assistant (assistant), System (system) |
ChatPartType | Text (chat.part.text), ToolCall (chat.part.tool-call) |
Realtime
Section titled “Realtime”Lattice\Realtime\Enums — the broadcast channel visibility a page listener subscribes to.
| Enum | Cases (value) |
|---|---|
ChannelVisibility | Public (public), Private (private), Presence (presence) |