Right now mostly extracted from configuration-manager and SilverBullet+'s dashboard. Will be used in more plugs moving forward.
11 lines
373 B
TypeScript
11 lines
373 B
TypeScript
import type { ComponentChildren, JSX } from "preact";
|
|
import { cx } from "./cx.ts";
|
|
|
|
export type SelectProps =
|
|
& Omit<JSX.IntrinsicElements["select"], "class">
|
|
& { class?: string; children?: ComponentChildren };
|
|
|
|
export function Select({ class: extra, children, ...rest }: SelectProps) {
|
|
return <select class={cx("sb-select", extra)} {...rest}>{children}</select>;
|
|
}
|