Fragiola

Getting started

Introduction

What Fragiola Primitives are - headless, accessible components with the same behaviour in React, Vue and Angular - and what they leave to your app.

Fragiola Primitives is a library of headless, accessible UI primitives: the overlays (Dialog, AlertDialog, Drawer, Popover, Tooltip, HoverCard, Menu, ContextMenu), the notifications (Toast, on a toast queue a plain module can import), the navigation (Tabs, NavigationMenu, Pagination), the disclosure components (Collapsible, Accordion), the form layer (Field, Fieldset, Form), the form controls (Button, Toggle and ToggleGroup, Toolbar, Checkbox and CheckboxGroup, RadioGroup and Radio, Switch, Slider, Select, CascadeSelect, Combobox, Autocomplete, Listbox), the command palette (Command), the inputs (Label, NumberField, OTPField), the tags and choices (TagGroup, TagsInput, SegmentedControl, Rating), the text inputs (PasswordInput, SearchField, Editable, Clipboard), the files (DropZone, FileUpload), navigation (Link, Breadcrumbs, Steps, Carousel), the color controls and pickers (ColorSlider, ColorArea, ColorWheel, ColorField, ColorSwatch, ColorSwatchPicker, ColorPicker and its popover, on the toolkit's color model), the dates (Calendar, RangeCalendar, MultipleCalendar, the month and year calendars, DatePicker, DateRangePicker, the month and year pickers, DateField, TimeField, DateRangeField, TimeRangeField, the pickers' typed input, presets and views, in 13 calendar systems and any time zone) and the display components (Progress, Meter, Avatar, Separator, ScrollArea, AspectRatio), with opt-in virtual and async lists for Listbox, Select, Combobox, Autocomplete and Command. It ships the same catalog with the same behaviour in React, Vue and Angular.

Settings tabs
Gallery

What a primitive gives you

  • Behaviour: opening and closing, selection, controlled and uncontrolled state, change reasons.
  • Accessibility: the roles, states and properties of the WAI-ARIA pattern, its keyboard map, where focus goes, a focus trap and an inert page for a modal.
  • Composable parts: Dialog.Root, Dialog.Trigger, Dialog.Popup, ... each rendering one element (or none) that you can replace with render.

What stays yours

  • Every pixel. No CSS, no class names, no inline style but the structural one (a position, a size, a CSS variable a style reads).
  • Every word. No text, no accessible names: the title of a dialog and the label of a tab list are your children and your aria-label.
  • Your framework's idioms. React takes props and ref; Vue takes v-model and slots; Angular takes attribute directives and two-way bindings.

One behaviour, three implementations

Each component has one spec, and each framework package implements it natively: there is no shared core to adapt. One conformance suite runs the same behaviour, contract and screenshot tests against all three. The pattern says why.