({label, ...props}: ColorSliderProps)
| 29 | } |
| 30 | |
| 31 | export function ColorSlider({label, ...props}: ColorSliderProps) { |
| 32 | return ( |
| 33 | <AriaColorSlider |
| 34 | {...props} |
| 35 | className={composeTailwindRenderProps( |
| 36 | props.className, |
| 37 | 'font-sans orientation-horizontal:grid orientation-vertical:flex grid-cols-[1fr_auto] flex-col items-center gap-2 orientation-horizontal:w-56' |
| 38 | )}> |
| 39 | <Label>{label}</Label> |
| 40 | <SliderOutput className="text-sm text-neutral-500 dark:text-neutral-400 font-medium orientation-vertical:hidden" /> |
| 41 | <SliderTrack |
| 42 | className={trackStyles} |
| 43 | style={({defaultStyle, isDisabled}) => ({ |
| 44 | ...defaultStyle, |
| 45 | background: isDisabled |
| 46 | ? undefined |
| 47 | : `${defaultStyle.background}, repeating-conic-gradient(#CCC 0% 25%, white 0% 50%) 50% / 16px 16px` |
| 48 | })}> |
| 49 | <ColorThumb /> |
| 50 | </SliderTrack> |
| 51 | </AriaColorSlider> |
| 52 | ); |
| 53 | } |
nothing calls this directly
no test coverage detected