Files
ComfyUI_frontend/packages/tailwind-utils
Alexander Brown aa5125cef6 Chore: Oxfmt formatting pass (#8341)
## Summary

Expanding the covered files to format. One-time formatting pass. To be
added to the `.git-blame-ignore-revs`

┆Issue is synchronized with this [Notion
page](https://www.notion.so/PR-8341-Chore-Oxfmt-formatting-pass-2f56d73d365081f2988fcb7570f9a2a1)
by [Unito](https://www.unito.io)
2026-01-27 17:59:19 -08:00
..

@comfyorg/tailwind-utils

Shared Tailwind CSS utility functions for the ComfyUI Frontend monorepo.

Usage

The cn function combines clsx and tailwind-merge to handle conditional classes and resolve Tailwind conflicts.

import { cn } from '@comfyorg/tailwind-utils'

// Use with conditional classes (object)
<div :class="cn('transition-opacity', { 'opacity-75': !isHovered })" />

// Use with conditional classes (ternary)
<button
  :class="cn('px-4 py-2', isActive ? 'bg-blue-500' : 'bg-smoke-500')"
/>

Installation

This package is part of the ComfyUI Frontend monorepo and is automatically available to all workspace packages.

{
  "dependencies": {
    "@comfyorg/tailwind-utils": "workspace:*"
  }
}