mirror of
https://github.com/YspCoder/clawgo.git
synced 2026-05-03 05:57:30 +08:00
refresh webui forms and fix whatsapp bridge login state
This commit is contained in:
24
webui/src/components/Checkbox.tsx
Normal file
24
webui/src/components/Checkbox.tsx
Normal file
@@ -0,0 +1,24 @@
|
||||
import React from 'react';
|
||||
|
||||
type CheckboxProps = Omit<React.InputHTMLAttributes<HTMLInputElement>, 'type'>;
|
||||
|
||||
function joinClasses(...values: Array<string | undefined | false>) {
|
||||
return values.filter(Boolean).join(' ');
|
||||
}
|
||||
|
||||
const Checkbox = React.forwardRef<HTMLInputElement, CheckboxProps>(function Checkbox(
|
||||
{ className, ...props },
|
||||
ref,
|
||||
) {
|
||||
return (
|
||||
<input
|
||||
{...props}
|
||||
ref={ref}
|
||||
type="checkbox"
|
||||
className={joinClasses('ui-checkbox', className)}
|
||||
/>
|
||||
);
|
||||
});
|
||||
|
||||
export default Checkbox;
|
||||
export type { CheckboxProps };
|
||||
Reference in New Issue
Block a user