Skip to content

Commit

Permalink
Merge pull request #33 from MPSxDev/feat/components
Browse files Browse the repository at this point in the history
feat: Add select component
  • Loading branch information
MPSxDev authored Nov 28, 2024
2 parents 515e866 + 232914d commit c3ecebe
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions paystell-frontend/src/components/ui/select.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import * as React from "react"
import { cn } from "@/lib/utils"

export interface SelectProps
extends React.SelectHTMLAttributes<HTMLSelectElement> {}

const Select = React.forwardRef<HTMLSelectElement, SelectProps>(
({ className, children, ...props }, ref) => {
return (
<select
className={cn(
"flex w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-0 focus-visible:border-primary focus-visible:border-2 disabled:cursor-not-allowed disabled:opacity-50 my-1",
className
)}
ref={ref}
{...props}
>
{children}
</select>
)
}
)
Select.displayName = "Select"

export { Select }

0 comments on commit c3ecebe

Please sign in to comment.