UNPKG

@react95/core

Version:
19 lines (18 loc) 628 B
import React, { forwardRef } from "react"; import { label, field, icon, text } from "./RadioButton.css.mjs"; import cn from "classnames"; const RadioButton = forwardRef( ({ children, disabled, ...props }, ref) => /* @__PURE__ */ React.createElement("label", { className: cn(label, props.className) }, /* @__PURE__ */ React.createElement( "input", { type: "radio", disabled, className: field, ref, ...props } ), /* @__PURE__ */ React.createElement("span", { className: icon }), /* @__PURE__ */ React.createElement("span", { className: text }, children)) ); export { RadioButton };