Repository navigation
Releases
Releases · lostcoords/ui
v0.8.1
Additive release on top of 0.8.0: no API was removed or renamed.
Added
lc_search(empty:, prompt:)and a busy state whilesrcanswers, so the empty note no longer flashes.dialog.trigger { |attrs| … }renders your own element as a dialog trigger; content markeddata-dialog-size="sm|md|lg|xl"sizes its dialog. The size scale lives once indialog.css.lc_menu_group(label, id:)labels a group of menu options.lc_list_field(label, icon:, id:, tag:, surface:)for form rows in a list group, andlc_input(plain: true).lc_icon_button(variant:, tone:)(and the link/to forms);lc_button(expanded_icon:, as: :span);lc_collapsible(button:).lc_toggle_group(variant: :pills, size:), empty item values.lc_avatarandlc_icon_badgespacing-step sizes (size: 6/7/11) andlc_icon_badge(shape: :plain).--lc-toast-offset-top/-bottomand--lc-nav-dock-indicator.
Changes in 0.8.1
Nothing needs an edit, but these look different:
- A secondary destructive button has a soft destructive fill. Before:
variant: :secondary, tone: :destructive
kept the neutral secondary fill with destructive ink. After: it fills with the same soft destructive mix a
destructive ghost button shows on hover, so the tones read solid, soft, then ink only. - Toggles style
aria-checked. Anlc_toggle_classelement witharia-checked="true"now looks pressed, so
toggle pills can be the radios of avariant: :pillstoggle group. - A toggle's fill follows
--lc-field-bg. Before:lc_togglealways filled with--input. After: it reads
--lc-field-bglike fields and the select trigger, so on a card or list row it takes--card-input. - The emoji picker's skin-tone menu opens downward. Before: it opened above its toggle, which sits in the
picker's top row, so it escaped the picker. After: it opens below the toggle, inside the picker. - A card's destructive edge ignores its closed menus. Before: a destructive option in a menu or popover
inside a card (a row's "Remove") tinted the card's edge. After: only the card's own controls and invalid
fields do.
v0.8.0
Upgrading from 0.7
Everything else in 0.8 is additive. These changes need edits in an app built on 0.7:
- A named
lc_toggle_grouprenders native radios. Before:lc_toggle_group(name:)rendered radio
buttons, a hidden input and thelc-selectioncontroller. After: each item is alabelaround an
input type=radiowith that name, so listen for the inputs'changeinstead oflc-selection:change, and
mark the selected item withchecked:or the group'svalue:instead ofselected:. A group without
name:keeps the radio buttons andlc-selection:change; it no longer has aninputtarget. lc_sheet_datais gone. Before:tag.dialog data: lc_sheet_data({ controller: "picker" }, detents: "large").
After:lc_sheet tag: :dialog, detents: "large", data: { controller: "picker" }.lc_sheetalso renders
non-dialog sheets, so drop any hand-writtendata-controller="lc-sheet"and handle element too.- The
lc-confirm-dialogcontroller is gone. Before: a pre-rendered confirm<dialog>wired to
lc-confirm-dialog. After: renderlc_confirm_sheetonce in the layout and putdata-turbo-confirmon
the form, withdata-turbo-confirm-description,data-turbo-confirm-acceptand
data-turbo-confirm-tonefor its description, label and tone. - A modal
lc_dialogis 32rem wide on desktop. Before:min(92vw, 31rem). After:size: :md,
min(32rem, 100vw - 2rem). Passsize: :sm(24rem) for a narrower dialog, or set--lc-dialog-width. lc_dialogputs your content in a body slot. Before: the block rendered straight after the header
inside[data-slot=dialog-content]. After: it renders inside[data-slot=dialog-body], which scrolls on
desktop, and the close button sits in[data-slot=dialog-actions]. Update CSS that selects children of
dialog-content.- A swiped-away popover sheet hides itself. Before:
lc-sheet:dismissonly notified listeners on a
non-dialog sheet. After: an open[popover]sheet hides unless a listener callspreventDefault(). - An unpadded
lc_cardno longer gaps its children. Before:lc_card(padding: :none)stacked its
children--lc-insetapart. After: they meet edge to edge, as rows and empty states in an unpadded card
expect. Passclass: "gap-inset"to keep the old spacing. lc_text(size: :label)is semibold. Before: weight 500. After: 600, the same as a field label, so
one label role serves both. Addclass: "font-medium"where the lighter weight was intended.
v0.4.1
The first RubyGems release of lostcoords-ui.
- ActionView and ERB components styled with Tailwind CSS v4 and wired with Stimulus.
- Automatic Rails engine integration with Propshaft and importmap.
- Standalone ActionView rendering without booting a Rails application.
- An
lc_*helper namespace, component variants, theme tokens, copy buttons, and motion styles. - Vendored Heroicons SVGs with outline, solid, mini, and micro variants.
Add the gem to your Gemfile:
gem "lostcoords-ui", "~> 0.4.0"See the installation guide and standalone ActionView setup.