From c7364e1e552788b842c840f68f9c159ad5810d04 Mon Sep 17 00:00:00 2001 From: saintpreston <90055250+Saintpreston@users.noreply.github.com> Date: Mon, 6 Feb 2023 14:21:37 -0500 Subject: [PATCH] Add "data-selected" attribute to Item Component --- cmdk/src/index.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/cmdk/src/index.tsx b/cmdk/src/index.tsx index 1dfc4d0..31a60e8 100644 --- a/cmdk/src/index.tsx +++ b/cmdk/src/index.tsx @@ -612,6 +612,7 @@ const Item = React.forwardRef((props, forwardedRef) = role="option" aria-disabled={disabled || undefined} aria-selected={selected || undefined} + data-selected={selected || undefined} onPointerMove={disabled ? undefined : select} onClick={disabled ? undefined : onSelect} >