LCOV - code coverage report
Current view: top level - packages/design-system/src/components/dialog - dialog.variants.ts Coverage Total Hit
Test: ComfyUI E2E Coverage Lines: 100.0 % 1 1
Test Date: 2026-11-17 04:17:53

            Line data    Source code
       1              : import type { VariantProps } from 'cva'
       2              : import { cva } from 'cva'
       3              : 
       4         2356 : export const dialogContentVariants = cva({
       5              :   base: 'fixed flex flex-col outline-none data-[state=closed]:pointer-events-none data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95',
       6              :   variants: {
       7              :     surface: {
       8              :       card: 'rounded-2xl border bg-background shadow-lg',
       9              :       none: ''
      10              :     },
      11              :     size: {
      12              :       sm: 'sm:max-w-96',
      13              :       md: 'sm:max-w-xl',
      14              :       lg: 'sm:max-w-3xl',
      15              :       xl: 'sm:max-w-5xl',
      16              :       full: '',
      17              :       fit: ''
      18              :     },
      19              :     maximized: {
      20              :       true: 'inset-2 top-2 left-2 size-auto max-h-none max-w-none sm:max-w-none',
      21              :       false:
      22              :         'top-1/2 left-1/2 max-h-[85vh] w-[calc(100vw-1rem)] -translate-x-1/2 -translate-y-1/2'
      23              :     }
      24              :   },
      25              :   compoundVariants: [
      26              :     {
      27              :       size: 'full',
      28              :       maximized: false,
      29              :       class: 'h-[90vh] max-h-[90vh] w-[90vw] max-w-[90vw]'
      30              :     },
      31              :     {
      32              :       size: 'fit',
      33              :       maximized: false,
      34              :       class: 'w-fit max-w-[calc(100vw-1rem)]'
      35              :     }
      36              :   ],
      37              :   defaultVariants: {
      38              :     surface: 'card',
      39              :     size: 'md',
      40              :     maximized: false
      41              :   }
      42              : })
      43              : 
      44              : type DialogContentVariants = VariantProps<typeof dialogContentVariants>
      45              : 
      46              : export type DialogContentSize = NonNullable<DialogContentVariants['size']>
      47              : export type DialogContentSurface = NonNullable<DialogContentVariants['surface']>
        

Generated by: LCOV version 2.0-1