File tree Expand file tree Collapse file tree 1 file changed +6
-14
lines changed Expand file tree Collapse file tree 1 file changed +6
-14
lines changed Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ import * as CollapsibleRUI from "@radix-ui/react-collapsible"
55 ChevronUpIcon,
66} from "@radix-ui/react-icons"*/
77
8- import { ChevronDownIcon , ChevronUpIcon , ChevronRightIcon } from "lucide-react"
8+ import { ChevronRightIcon , ChevronLeftIcon } from "lucide-react"
99
1010import { forwardRef , type HTMLProps } from "react"
1111import { twMerge } from "tailwind-merge"
@@ -91,13 +91,9 @@ export const Collapsible = forwardRef(
9191 chevronClassName ,
9292 ) }
9393 >
94- < ChevronDownIcon
95- aria-label = "close"
96- className = "group-data-[state=open]:block group-data-[state=closed]:hidden"
97- />
9894 < ChevronRightIcon
99- aria-label = " open"
100- className = "group-data-[state=closed]:block group-data-[state=open]:hidden "
95+ aria-label = { opened ? "close" : " open"}
96+ className = "group-data-[state=closed]:rotate-0 group-data-[state=open]:rotate-90 transform transition-transform "
10197 />
10298 </ div >
10399 ) }
@@ -118,13 +114,9 @@ export const Collapsible = forwardRef(
118114 ) }
119115 style = { chevronStyle }
120116 >
121- < ChevronDownIcon
122- aria-label = "close"
123- className = "group-data-[state=open]:block group-data-[state=closed]:hidden"
124- />
125- < ChevronUpIcon
126- aria-label = "open"
127- className = "group-data-[state=closed]:block group-data-[state=open]:hidden"
117+ < ChevronLeftIcon
118+ aria-label = { opened ? "close" : "open" }
119+ className = "group-data-[state=closed]:rotate-0 group-data-[state=open]:-rotate-90 transform transition-transform"
128120 />
129121 </ div >
130122 ) }
You can’t perform that action at this time.
0 commit comments