@szum-tech/design-system
Version:
Szum-Tech design system with tailwindcss support
1 lines • 1.73 kB
JavaScript
import {a as a$1}from'./chunk-ZGZS5I45.js';import {a}from'./chunk-JUNHRB4B.js';import {cva}from'class-variance-authority';import {jsx}from'react/jsx-runtime';import {Slot}from'@radix-ui/react-slot';var n=cva(["group/button-group flex w-fit items-stretch","*:focus-visible:relative *:focus-visible:z-10","has-[>[data-slot=button-group]]:gap-2","has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-r","[&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit","[&>input]:flex-1"],{variants:{orientation:{horizontal:"[&>*:not(:first-child)]:rounded-l-none [&>*:not(:first-child)]:border-l-0 [&>*:not(:last-child)]:rounded-r-none [&>[data-slot]:not(:has(~[data-slot]))]:rounded-r!",vertical:"flex-col [&>*:not(:first-child)]:rounded-t-none [&>*:not(:first-child)]:border-t-0 [&>*:not(:last-child)]:rounded-b-none [&>[data-slot]:not(:has(~[data-slot]))]:rounded-b!"}},defaultVariants:{orientation:"horizontal"}});function h({className:r,orientation:t,...e}){return jsx("div",{role:"group","data-slot":"button-group","data-orientation":t,className:a(n({orientation:t}),r),...e})}function B({className:r,asChild:t=false,...e}){return jsx(t?Slot:"div",{"data-slot":"button-group-text",className:a("bg-muted flex items-center gap-2 rounded-lg border px-2.5 text-sm font-medium [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4",r),...e})}function R({className:r,orientation:t="vertical",...e}){return jsx(a$1,{"data-slot":"button-group-separator",orientation:t,className:a("bg-input relative self-stretch data-[orientation=horizontal]:mx-px data-[orientation=horizontal]:w-auto data-[orientation=vertical]:my-px data-[orientation=vertical]:h-auto",r),...e})}export{h as a,B as b,R as c};