Mixins / foldkit-mixins-ui
Finding a widget
| I need... | Use |
|---|---|
| a button, toggle button or icon button; a row of them | Button, ButtonGroup, Toolbar |
| a command palette | Command in a Dialog |
| a text field, a textarea, a password, a search box | Input, Textarea, PasswordInput, SearchField |
| a number, a one-time code, tags, a copyable value | NumberField, OtpField, TagsInput, InputCopy |
| a file picker, a drop zone, files that are listed, checked, previewed and sent | FileInput (a native picker you own), FileDrop, FileUpload |
| on or off; one of a few; several of a few | Switch, Checkbox, CheckboxGroup, RadioGroup, Segmented |
| one from a long list; a path through nested options | Select, Listbox, Combobox, Picker, CascadeSelect |
| a number, a range, a rating, an angle, a color | Slider, NumberField, Rating, AngleSlider, ColorPicker |
| a date or a range of dates | Calendar, DatePicker |
| a dialog, a sheet, a docked drawer | Dialog (with focusReturn), Sheet, Drawer |
| a popover, a tooltip, a hover card, a floating window, a guided tour | Popover, Tooltip, HoverIntent, FloatingPanel, Tour |
| a menu, a context menu, a menu bar | Menu, Menubar |
| tabs, site navigation, breadcrumbs, pages, a stepper | Tabs, Nav, Breadcrumb, Pagination, Steps |
| an app frame, a sidebar, an accordion, a tree | AppShell, Sidebar, Accordion, TreeView |
| a table, a card, a list row, an avatar | Table, Card, Item, Avatar |
| an alert, a toast, a progress bar, a loading state | Alert, Toast, Progress, Meter, Spinner, Skeleton |
| a very long list | VirtualList, WindowList |
| a chat | ChatMessage, MessageScroller, ThinkingIndicator, ThinkingSteps, Questionnaire |
| a widget's state placed in my Model without writing its fold | Bundles.X |
| a widget's look, words and mixins stated once | X.configure, Recipes.X |
| my own keyboard shortcut on a widget | Application key routes |
| focus that survives removing what had it | Focus after removal |
| a form that submits natively | Form participation |
| a right-to-left page | Right to left |
Each group below is a table (the widget, what it is and its call, its recipe
axes and Slots) and notes on the widgets whose behavior needs more than a line.
A row says A small Model where the widget keeps interaction state for the
application to place and fold with its update; the rest keep nothing. Every
view takes an optional style of its Slots and mixins beside it, and h last.
Style the Slots with the matching recipe (Recipes); hide text with
U.srOnly from foldkit-mixins/utilities; name a control with
FieldAssociation, whose derived id Label.view takes.
Behavior shared by many widgets is described once, in Mechanisms shared by many
widgets, and the rows link to it: application
key routes (routes), focus after removal, form participation (name),
right to left (direction), exits and reduced motion, the opt-in Mounts
(fluid, overlayBars) and the top layer.