BreakpointScanner
Scans your modules and purges unreachable code nodes.
Preview
Scans your modules and purges unreachable code nodes.
concurrency4
nodes: 0coverage: 0%
accordion.tsxidle
"use client"
import * as React from "react"
import { ChevronDown } from "lucide-react"
import { cn } from "@/lib/utils"
interface AccordionContextValue {
openValue: string
setOpenValue: (value: string) => void
}
const AccordionContext = React.createContext<AccordionContextValue | null>(null)
export function Accordion({
children,
defaultValue,
className,
}: {
children: React.ReactNode
defaultValue?: string
className?: string
}) {
const [openValue, setOpenValue] = React.useState(defaultValue ?? "")
return (
<AccordionContext.Provider value={{ openValue, setOpenValue }}>
<div className={cn("divide-y rounded-lg border", className)}>{children}</div>
</AccordionContext.Provider>
)
}Move your mouse to aim · click to start · click again to pause (boss key).
Installation
bash
npx shadcn@latest add https://ui.moyu.dev/r/breakpoint-scanner.jsonUsage
tsx
import { BreakpointScanner } from "@/components/moyu/breakpoint-scanner"
export default function Example() {
return <BreakpointScanner />
}API Reference
| Prop | Type | Default | Description |
|---|---|---|---|
| target | string | — | Module graph to scan |
| concurrency | number | 4 | Parallel scan probes |
| retainLayout | boolean | true | Keep node positions after processing |
| pauseOnBlur | boolean | true | Freeze scan when tab loses focus |