import React from "react"; import { PlusRadio as PlusRadioElement } from "../dist/components/radio/index.js"; export type { PlusRadioElement }; export interface PlusRadioProps extends Pick< React.AllHTMLAttributes, | "children" | "dir" | "hidden" | "id" | "lang" | "slot" | "style" | "title" | "translate" | "onClick" | "onFocus" | "onBlur" > { /** Whether the radio is checked. */ checked?: boolean; /** Whether the radio is in an error state. */ error?: boolean; /** Whether the radio is disabled. */ disabled?: boolean; /** Whether the radio is readonly. */ readonly?: boolean; /** Whether the radio is required. */ required?: boolean; /** Sets the size of the radio button - sm: Small size - md: Medium size - lg: Large size */ size?: PlusRadioElement["size"]; /** Defines the text label for the radio button */ text?: PlusRadioElement["text"]; /** The radio's name attribute. */ name?: PlusRadioElement["name"]; /** The radio's value attribute. */ value?: PlusRadioElement["value"]; /** A space-separated list of the classes of the element. Classes allows CSS and JavaScript to select and access specific elements via the class selectors or functions like the method `Document.getElementsByClassName()`. */ className?: string; /** Contains a space-separated list of the part names of the element that should be exposed on the host element. */ exportparts?: string; /** Used for labels to link them with their inputs (using input id). */ htmlFor?: string; /** Used to help React identify which items have changed, are added, or are removed within a list. */ key?: number | string; /** Contains a space-separated list of the part names of the element. Part names allows CSS to select and style specific elements in a shadow tree via the ::part pseudo-element. */ part?: string; /** A mutable ref object whose `.current` property is initialized to the passed argument (`initialValue`). The returned object will persist for the full lifetime of the component. */ ref?: any; /** Allows developers to make HTML elements focusable, allow or prevent them from being sequentially focusable (usually with the `Tab` key, hence the name) and determine their relative ordering for sequential focus navigation. */ tabIndex?: number; /** Internal state to track if the radio button has focus */ hasFocus?: PlusRadioElement["hasFocus"]; /** Emitted when the radio button's checked state changes */ onPlusChange?: (event: CustomEvent) => void; } /** * Radio button component that allows single selection from a group of options. * --- * * * ### **Events:** * - **plus-change** - Emitted when the radio button's checked state changes * * ### **Methods:** * - **handleChange()** - Handles the change event when the radio button is toggled * * ### **Slots:** * - _default_ - The radio button label content * * ### **CSS Parts:** * - **radio** - The component's radio input element */ export const PlusRadio: React.ForwardRefExoticComponent;