typescript-typenfehler behoben.. npm run lint läuft nun fehlerfrei durch.

This commit is contained in:
Codex Agent
2025-11-22 11:49:47 +01:00
parent 6c78d7e281
commit eb41cb6194
74 changed files with 469 additions and 396 deletions

View File

@@ -1,8 +1,6 @@
import * as React from "react"
import { ChevronLeft, ChevronRight } from "lucide-react"
import { cn } from "@/lib/utils"
import { Button } from "@/components/ui/button"
interface Step {
id: string
@@ -66,4 +64,4 @@ const Steps = React.forwardRef<HTMLDivElement, StepsProps>(
)
Steps.displayName = "Steps"
export { Steps }
export { Steps }

View File

@@ -10,7 +10,7 @@ import useEmblaCarousel from "embla-carousel-react"
interface CarouselApi {
slideNodes(): HTMLElement[]
on(event: string, listener: (...args: any[]) => void): void
on(event: string, listener: (...args: unknown[]) => void): void
scrollPrev(): void
scrollNext(): void
reInit(): void
@@ -18,21 +18,24 @@ interface CarouselApi {
const CarouselContext = React.createContext<CarouselApi | null>(null)
interface CarouselProps {
type CarouselProps = React.HTMLAttributes<HTMLDivElement> & {
opts?: {
align?: "start" | "center" | "end"
loop?: boolean
}
plugins?: any[]
plugins?: unknown[]
setApi?: (api: CarouselApi) => void
[key: string]: any
}
const Carousel = React.forwardRef<HTMLDivElement, CarouselProps>(
({ opts, plugins = [Autoplay()], setApi, className, children, ...props }, ref) => {
const [api, setApiInternal] = React.useState<CarouselApi | null>(null)
const [emblaRef] = useEmblaCarousel(opts, plugins)
const [emblaRef, emblaApi] = useEmblaCarousel(opts, plugins)
React.useEffect(() => {
setApiInternal(emblaApi ?? null)
}, [emblaApi])
React.useEffect(() => {
if (!api) {

View File

@@ -2,7 +2,7 @@ import * as React from "react"
import { cn } from "@/lib/utils"
export interface TextareaProps extends React.TextareaHTMLAttributes<HTMLTextAreaElement> {}
export type TextareaProps = React.TextareaHTMLAttributes<HTMLTextAreaElement>
const Textarea = React.forwardRef<HTMLTextAreaElement, TextareaProps>(
({ className, ...props }, ref) => {