Description list
DescriptionList::make() lays out label/value pairs for a single subject — the read-only counterpart
to a form. Give it a record and each entry reads its own value from it:
Card::make('Account')->schema([ DescriptionList::make()->bleed()->record($user)->schema([ TextEntry::make('name'), TextEntry::make('email')->copyable(), DateEntry::make('joined_at', 'Joined')->style(DateTimeStyle::Long), BooleanEntry::make('is_active', 'Active'), ]),]);- description:null
- headerActions:[]
- title:"Account"
- tooltip:null
- bleed:true
- divided:true
- emptyLabel:null
- semantic:"description-list"
- copyable:false
- description:null
- label:"Name"
- name:"name"
- placeholder:null
- value:"Ada Lovelace"
- copyable:true
- description:null
- label:"Email"
- name:"email"
- placeholder:null
- value:"[email protected]"
- description:null
- format:{"dateStyle":"long","kind":"date","month":null,"timeStyle":null,"year":null}
- label:"Joined"
- name:"joined_at"
- value:"1843-07-01"
- description:null
- falseIcon:"x"
- label:"Active"
- name:"is_active"
- trueIcon:"check"
- value:true
An entry’s label defaults to its name in headline case (joined_at → Joined at); pass a second
argument to override it. The record may be an associative array, a keyed Collection, a model, or
another object. Entry names use Laravel’s data_get(), so dotted paths such as profile.email work
across those record types.
When the list has no record, it treats its entries as a row template and binds each value to the
entry name through Lattice’s dataBindings. This lets the same list work inside a client-materialised
schema. Use ->dataKey('value', 'profile.email') when the row path differs from the entry name.
Entries
Section titled “Entries”| Entry | Renders |
|---|---|
TextEntry |
The value as text. ->copyable() adds a copy affordance, ->placeholder('—') covers an empty value. |
DateEntry |
A localised date. ->style(DateTimeStyle::…) or ->dateTime(). |
BooleanEntry |
A check or cross icon. ->icons($true, $false) swaps them. |
BadgeEntry |
The value as a badge; ->color(…) tints it. |
ComponentEntry |
Any component as the value — a stack, a segmented control, whatever the schema can express. |
ComponentEntry is the escape hatch when a value is not a formatted scalar:
ComponentEntry::make('appearance', __('Theme')) ->value(SegmentedControl::make('appearance')->options([...])),Dividers and bleed
Section titled “Dividers and bleed”Rows are separated by hairlines; ->divided(false) turns them off. Inside a padded panel such as a
Card the lines stop at the gutter — ->bleed() runs them to the panel
edge while the rows stay aligned with the rest of its content.
Disclosure
Section titled “Disclosure”An entry with ->disclosure([...]) turns its row into a toggle that reveals the content beneath it.
The typical body is the form that edits the value the row displays:
Card::make('Login')->schema([ DescriptionList::make()->bleed()->schema([ TextEntry::make('password') ->value('••••••••') ->disclosure([Form::use(PasswordForm::class)]), ]),]);- description:null
- headerActions:[]
- title:"Login"
- tooltip:null
- bleed:true
- divided:true
- emptyLabel:null
- semantic:"list"
- copyable:false
- description:null
- label:"Email"
- name:"email"
- placeholder:null
- value:"[email protected]"
- copyable:false
- description:null
- label:"Password"
- name:"password"
- placeholder:null
- value:"••••••••"
- align:null
- color:null
- copyable:false
- size:"md"
- text:"A form to change the password goes here."
Empty state
Section titled “Empty state”->emptyLabel('No memberships yet') covers a list whose entries all resolved to nothing — building
rows from a collection that turned out empty, for instance.