use of selectable

This commit is contained in:
2026-02-11 21:57:17 -05:00
parent 9a2b790897
commit 72000b362d
10 changed files with 293 additions and 193 deletions

View File

@@ -6,14 +6,12 @@ export function SelectableBox({
selected,
children,
...props
}: {
selected: () => boolean;
children: JSXElement;
} & BoxOptions) {
}: { selected: () => boolean; children: JSXElement } & BoxOptions) {
const { theme } = useTheme();
return (
<box
border={!!props.border}
borderColor={selected() ? theme.surface : theme.border}
backgroundColor={selected() ? theme.primary : theme.surface}
{...props}