Release 2.3.0
Intent UI v2.3.0 adds dropdown description components, removes DropdownItemDetails, and updates Choicebox, Table, Sidebar, and Navbar.
Checkbox icon
The checkbox icon now uses size-3.5 instead of size-4. The indicator element also has a data-slot="checkbox-indicator" attribute.
Choicebox
Previously, Choicebox items used the title prop:
<Choicebox.Item title="Basic" description="Just the essentials to get started." />The title prop is now called label to avoid conflicts with the HTML title attribute, which can display a browser tooltip. Update your items as follows:
<Choicebox.Item label="Basic" description="Just the essentials to get started." /> // ✅Use Choicebox.Label and Choicebox.Description children to compose the item content:
<Choicebox.Item textValue={item.id}>
<Choicebox.Label>{item.label}</Choicebox.Label>
<Choicebox.Description>{item.description}</Choicebox.Description>
</Choicebox.Item>The label and description props are also supported. Use children when you need to include an avatar or icon:
<Choicebox.Item textValue={item.id}>
<Avatar src={item.image_url} />
<Choicebox.Label>{item.label}</Choicebox.Label>
<Choicebox.Description>{item.description}</Choicebox.Description>
</Choicebox.Item>Choicebox now uses grid-cols-subgrid to align content when columns={1}.
Dropdown descriptions
Use the new DropdownDescription child component to compose descriptions with icons or other elements.
import { IconMinus } from "@intentui/icons"
<DropdownItem>
<IconMinus />
<DropdownLabel>Item</DropdownLabel>
<DropdownDescription>Item description</DropdownDescription>
</DropdownItem>Removing DropdownItemDetails
DropdownItemDetails has been removed. Use separate label and description elements to customize dropdown item content.
Menu and Select items also support description children:
// Menu
<MenuItem textValue="Admin">
<MenuLabel>Admin</MenuLabel>
<MenuDescription>Has full access to all resources</MenuDescription>
</MenuItem>
// Select
<Select.Item textValue="Admin">
<Select.Label>Admin</Select.Label>
<Select.Description>Has full access to all resources</Select.Description>
</Select.Item>ComboBox descriptions
Use DropdownDescription to add descriptions to ComboBox items:
<ComboBoxItem textValue="Admin">
<ComboBoxLabel>Admin</ComboBoxLabel>
<ComboBoxDescription>Has full access to all resources</ComboBoxDescription>
</ComboBoxItem>Migrate from DropdownItemDetails
Replace DropdownItemDetails:
<Dropdown.ItemDetails />Use DropdownLabel and DropdownDescription instead:
<DropdownItem>
<IconMinus />
<DropdownLabel>Item</DropdownLabel>
<DropdownDescription>Item description</DropdownDescription>
</DropdownItem>Table
Table now supports a bleed prop, which defaults to false. See Sidebar 15 for an example and the Table documentation for usage.
Sidebar
Sidebar layouts now handle tables with many columns without breaking the surrounding layout. See Sidebar 15 for an example.
Navbar
Rename the Navbar intent value floating to float.