Flux ships with the entire Heroicons icon set by default. As with anything the Tailwind folks do, it's excellent.
However, at ~400 icons, it's more limited than other alternatives.
If there's an icon in your project that you need but isn't available in Heroicons, it's probably available in Lucide.
In version v1.0.20 of Flux, we've shipped a new command to easily import individual Lucide icons into your project:
Copy to clipboard
php artisan flux:icon
You will be prompted to enter the names of any icons you want, and it will import them locally into your project and format them as Blade components ready to use with Flux.
If Lucide doesn't have what you need still, you can just add your icons manually to the following directory in your project:
Flux uses the browser's new(ish) <dialog> element for its modals. There tons of benefits to this, but also a few quirks. One of them being, the <dialog> element doesn't respond to clicking outside to close a modal; only the escape key or a close button.
With a sprinkle of custom JavaScript, it was fairly trivial to implement this behavior in Flux. Now, by default, all <flux:modal> components will close on click outside.
Clearable inputs and selects
Another small improvement we made in this release was making any searchable input in Flux show a clear button when filled.
We've also made this configurable for inputs that don't show one by default:
You know those big boxy toggle thingy's you use to configure your new laptop purchase? Yep, those are radio cards; simple, bordered boxes that behave like radio buttons—meaning only one can be selected at a time.
Welp, we've got em' in Flux now, and using them is as simple as adding variant="cards" to a radio group:
By default, the cards will be laid out horizontally, but you can easily control this using simple flex box utilities like .flex-col. This makes it really easy to change the layout on mobile with a responsive utility like .max-sm:flex-col:
Although less common, there might be times you want the appearance of cards, but the behavior of checkboxes. Flux also supports variant="cards" for checkboxes:
Copy to clipboard
<flux:checkbox.group variant="cards"> <flux:checkbox label="Newsletter" description="Stay up to date" /> ...</flux:checkbox.group>
Of course, all of the aforementioned properties and customizations are available to checkbox cards as well.
Creating radio and checkbox variants like these is much more than just visuals. Each of these is fully controllable with a keyboard, uses a roving-tabindex to mimic the focus behavior of native checkboxes and radio buttons, and supports the proper attributes and roles so that screenreaders recognize these as standard form controls.
These are among the many details that differentiate Flux among other component libraries. We care deeply about providing world-class UI components that look amazing in the browser, feel amazing in your editor, and are accessible to as many people as possible.
Add radio cards variant
Add checkbox cards variant
Add segmented radio group variant
Change to solid icons for segmented tabs and radios
Add two pixel focus outline offset to radio, checkbox, and switch to match native outlines
Sortable column backgrounds were getting cut off on mobile
Translate "No results found" strings in combobox and listbox
:href properties were being escaped, causing links with ampersands to be malformed
All searchable inputs in Flux—searchable selects, comboboxes, command palettes—will now use JavaScript .includes(...) instead of .startsWith(...) when matching results so that searches are more inclusive.
This behavior mirrors the browser's native autocomplete behavior for the <datalist> element.
Support @close listeners on modal component
Add badge-color property to navlist and navbar
Use .includes() instead of .startsWith() for autocomplete/combobox/command search
Fix listbox/combobox not showing newly selected option if added dynamically
Make accordion heading text full-width
Silence error when non-valid colors are passed to badge component
Prevent radio/checkbox group labels from being grayed out if individual controls are disabled
Expose slots for select button and input in listbox/combobox
Make select full-width and forward classes to the <ui-selected> element instead of the <button> element
Polyfill the popover attribute for Safari 16 and lower
Provide fallbacks for unsupported CSS in older browsers