Files
NapCatQQ/.pnpm-store/v3/files/18/919eca554b467d0591886bf320ae41a6cf0b104c4f7a1330e32ebad1cfb320de70d64bc932c1278fdfda3ac9c7ff61101d9e9942d953d78aa8af854a0ce317
TanTan e311ca3275
Build NapCat Artifacts / Windows Loader Test (push) Canceled after 0s
Build NapCat Artifacts / Type Check & Test (push) Canceled after 0s
Build NapCat Artifacts / Build NapCat.Framework (push) Canceled after 0s
Build NapCat Artifacts / Build NapCat.Shell (push) Canceled after 0s
docs: 仓库链接指向本镜像仓库
2026-11-13 09:25:58 +08:00

37 lines
1.0 KiB
Plaintext

"use client";
import {
CheckboxIcon
} from "./chunk-5E6Z6LLK.mjs";
import {
useCheckbox
} from "./chunk-5JTA22ZA.mjs";
// src/checkbox.tsx
import { forwardRef } from "@heroui/system";
import { cloneElement } from "react";
import { jsx, jsxs } from "react/jsx-runtime";
var Checkbox = forwardRef((props, ref) => {
const {
Component,
children,
icon = /* @__PURE__ */ jsx(CheckboxIcon, {}),
getBaseProps,
getWrapperProps,
getInputProps,
getIconProps,
getLabelProps
} = useCheckbox({ ...props, ref });
const clonedIcon = typeof icon === "function" ? icon(getIconProps()) : cloneElement(icon, getIconProps());
return /* @__PURE__ */ jsxs(Component, { ...getBaseProps(), children: [
/* @__PURE__ */ jsx("input", { ...getInputProps() }),
/* @__PURE__ */ jsx("span", { ...getWrapperProps(), children: clonedIcon }),
children && /* @__PURE__ */ jsx("span", { ...getLabelProps(), children })
] });
});
Checkbox.displayName = "HeroUI.Checkbox";
var checkbox_default = Checkbox;
export {
checkbox_default
};