Skip to content

Commit

Permalink
refactor: Update button and slider components to remove focus ring fo…
Browse files Browse the repository at this point in the history
…r improved accessibility and visual clarity; add tint-tracker-vite dependency
  • Loading branch information
HasanYahya101 committed Nov 16, 2024
1 parent 4358e1a commit 3a49233
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/components/ui/button.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { cva } from "class-variance-authority";
import { cn } from "@/lib/utils"

const buttonVariants = cva(
"inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",
"inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-0 focus-visible:ring-ring focus-visible:ring-offset-0 disabled:pointer-events-none disabled:opacity-50",
{
variants: {
variant: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/slider.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const Slider = React.forwardRef(({ className, ...props }, ref) => (
<SliderPrimitive.Range className="absolute h-full bg-primary" />
</SliderPrimitive.Track>
<SliderPrimitive.Thumb
className="block h-5 w-5 rounded-full border-2 border-primary bg-background ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50" />
className="block h-5 w-5 rounded-full border-2 border-primary bg-background ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-0 focus-visible:ring-ring focus-visible:ring-offset-0 disabled:pointer-events-none disabled:opacity-50" />
</SliderPrimitive.Root>
))
Slider.displayName = SliderPrimitive.Root.displayName
Expand Down

0 comments on commit 3a49233

Please sign in to comment.