mirror of
https://github.com/anomalyco/opencode.git
synced 2026-05-26 14:24:46 +00:00
21 lines
429 B
TypeScript
21 lines
429 B
TypeScript
import type { ComponentProps, ParentProps } from "solid-js"
|
|
|
|
export interface KeybindProps extends ParentProps {
|
|
class?: string
|
|
classList?: ComponentProps<"span">["classList"]
|
|
}
|
|
|
|
export function Keybind(props: KeybindProps) {
|
|
return (
|
|
<span
|
|
data-component="keybind"
|
|
classList={{
|
|
...props.classList,
|
|
[props.class ?? ""]: !!props.class,
|
|
}}
|
|
>
|
|
{props.children}
|
|
</span>
|
|
)
|
|
}
|