mirror of
https://github.com/misode/misode.github.io.git
synced 2026-04-26 08:26:51 +00:00
Add versions explorer page
This commit is contained in:
14
src/app/components/forms/Checkbox.tsx
Normal file
14
src/app/components/forms/Checkbox.tsx
Normal file
@@ -0,0 +1,14 @@
|
||||
import { hexId } from '../../Utils'
|
||||
|
||||
interface Props {
|
||||
label: string,
|
||||
value: boolean,
|
||||
onChange: (value: boolean) => unknown,
|
||||
}
|
||||
export function Checkbox({ label, value, onChange }: Props) {
|
||||
const id = hexId()
|
||||
return <label class="checkbox">
|
||||
<input id={id} type="checkbox" checked={value} onClick={() => onChange(!value)} />
|
||||
{label}
|
||||
</label>
|
||||
}
|
||||
@@ -1,2 +1,3 @@
|
||||
export * from './Checkbox'
|
||||
export * from './Input'
|
||||
export * from './SearchList'
|
||||
|
||||
Reference in New Issue
Block a user