Skip to content
v0.9.1
Utilities

State variants

Put a state in front of a utility and it only applies in that state: hover:shadow-md, dark:hidden, print:hidden. Like the screen-size prefixes (md:flex), but for hover, focus, dark mode, reduced motion and printing.

Hover and focus

hover: only on devices that can hover (no sticky hover after a tap on a phone). focus-visible: when reached with the keyboard.

<a class="box p-4 no-underline transition hover:shadow-md hover:-translate-x-0.5 hover:-translate-y-0.5 hover:bg-yellow-soft" href="#">Lift and color on hover</a>
<a class="box p-4 no-underline transition hover:rotate-2 hover:scale-105" href="#">Tilt</a>
<a class="btn transition focus-visible:bg-yellow" href="#">Tab to me</a>

Group hover

Mark a parent with .group; group-hover: on anything inside reacts when the pointer is over the parent, or when keyboard focus is inside it.

<a class="group box p-5 hstack no-underline max-w-md transition hover:shadow-md" href="#">
  <span class="feature-icon bg-violet-soft transition group-hover:rotate-6 group-hover:bg-violet"><i class="mi mi-sparkles" aria-hidden="true"></i></span>
  <span class="grow"><b>New components</b><br><span class="text-sm text-muted">See what came out this week</span></span>
  <i class="mi mi-arrow-right rtl-flip opacity-0 transition group-hover:opacity-100 group-hover:translate-x-1" aria-hidden="true"></i>
</a>

Dark and light

Swap a picture or logo by mode: show one with dark:hidden and the other with hidden dark:block. Colors work too: dark:bg-ink. They follow the system setting and the page's own data-momo-mode.

You're in light mode
Yellow in light, violet in dark
<span class="badge badge-yellow dark:hidden">You're in light mode</span>
<span class="badge badge-violet hidden dark:inline-block">You're in dark mode</span>
<div class="box p-3 bg-yellow-soft dark:bg-violet">Yellow in light, violet in dark</div>

Press the moon / sun button at the top of this page to see them change.

Motion and print

Which utilities each state has

PrefixWorks with
hover:Colors (bg-*, text-*, border-*), shadows, opacity-0/50/75/100, small transforms (rotate-1…6, scale-95…110, translate-x/y-0.5…2), underline, grayscale / grayscale-0 / blur-sm / blur-none
group-hover:The same, plus show / hide (hidden, block, flex, invisible…)
focus-visible:Colors, shadows, underline
dark:Colors, show / hide
light:, print:Show / hide
motion-safe:, motion-reduce:transition*, animate-*, show / hide

Each state gets only what is useful with it, so the file stays small. For anything else, write a line of CSS.

Start

OverviewStart Getting startedStart CustomizeStart

Guides

AccessibilityGuides BreakpointsGuides ChangelogGuides Customize componentsGuides JavaScriptGuides MotionGuides OptimizeGuides PhonesGuides RebootGuides Right-to-left (RTL)Guides Stacking orderGuides Using Momo with AIGuides

Foundations

ColorsFoundations TypographyFoundations ProseFoundations Images & figuresFoundations CodeFoundations Lines & shadowsFoundations Dark modeFoundations

Forms

Checkbox & switchForms ComboboxForms Date pickerForms Date rangeForms Fields & labelsForms File uploadForms Floating labelsForms Number stepperForms PasswordForms PIN codeForms RatingForms SelectForms SliderForms Tag inputForms Time pickerForms ValidationForms

Components

AccordionComponents Alert & bannerComponents AvatarComponents BadgeComponents BreadcrumbComponents ButtonComponents Button groupComponents CalendarComponents CardComponents CarouselComponents ChartsComponents ChipsComponents CollapseComponents Command paletteComponents CommentsComponents Confirm dialogsComponents Cookie bannerComponents Data tableComponents Description listComponents Dialog & toastComponents DividerComponents DrawerComponents Dropdown menuComponents Empty stateComponents File managerComponents Filter & sortComponents Gallery & lightboxComponents Inbox & chatComponents Infinite scrollComponents KanbanComponents Keyboard shortcutsComponents List groupComponents MarqueeComponents Media objectComponents Nav overflowComponents Notification centerComponents PaginationComponents ProgressComponents Pull to refreshComponents SkeletonComponents SortableComponents SpinnerComponents Split viewComponents Stat cardComponents Steps & wizardComponents Swipe actionsComponents TableComponents TabsComponents TimelineComponents TogglerComponents Tooltip & popoverComponents TourComponents Tree viewComponents VideoComponents WhiteboardComponents

Layout

Announcement barLayout App shellLayout Back to topLayout Container & sectionLayout ExamplesLayout FooterLayout HeroLayout JumbotronLayout Mega menuLayout NavbarLayout Site sidebarLayout

Sections

Bento gridSections Blog cardsSections Call to actionSections Contact & newsletterSections FAQSections FeaturesSections Logo cloudSections PricingSections TeamSections TestimonialsSections

Utilities

OverviewUtilities State variantsUtilities Display & flexUtilities Grid & gapUtilities SpacingUtilities SizingUtilities TextUtilities Links & color strengthUtilities Position & overflowUtilities BackgroundsUtilities Borders & effectsUtilities Transforms & filtersUtilities InteractionsUtilities

Helpers

Fixed, sticky & frostedHelpers Hover & focusHelpers Hover revealHelpers Icon linkHelpers PrintHelpers Relative timeHelpers Screen reader textHelpers Scroll inHelpers ScrollspyHelpers Share buttonHelpers Skip linkHelpers StacksHelpers Stretched linkHelpers Theme toggleHelpers Truncated textHelpers

Page patterns

404 pagePage patterns Coming soonPage patterns Login & registerPage patterns SettingsPage patterns ProfilePage patterns CRM contactsPage patterns ProjectsPage patterns File manager pagePage patterns Billing & plansPage patterns Help centerPage patterns Mobile app screensPage patterns
↑ ↓ moveEnter openEsc close