mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-12 16:35:45 +01:00
add missing beta annotations to radio button api
This commit is contained in:
@@ -41,6 +41,10 @@ type Props<T extends Record<string, unknown>> = Omit<
|
|||||||
readOnly?: boolean;
|
readOnly?: boolean;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @beta
|
||||||
|
* @since 2.48.0
|
||||||
|
*/
|
||||||
function ControlledRadioGroupField<T extends Record<string, unknown>>({
|
function ControlledRadioGroupField<T extends Record<string, unknown>>({
|
||||||
name,
|
name,
|
||||||
label,
|
label,
|
||||||
|
|||||||
@@ -83,6 +83,10 @@ type Props = {
|
|||||||
helpText?: string;
|
helpText?: string;
|
||||||
} & ComponentProps<typeof RadioGroup.Item>;
|
} & ComponentProps<typeof RadioGroup.Item>;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @beta
|
||||||
|
* @since 2.48.0
|
||||||
|
*/
|
||||||
const RadioButton = React.forwardRef<HTMLButtonElement, Props>(
|
const RadioButton = React.forwardRef<HTMLButtonElement, Props>(
|
||||||
({ id, testId, indicatorClassName, label, labelClassName, className, helpText, value, ...props }, ref) => {
|
({ id, testId, indicatorClassName, label, labelClassName, className, helpText, value, ...props }, ref) => {
|
||||||
const context = useRadioButtonContext();
|
const context = useRadioButtonContext();
|
||||||
|
|||||||
@@ -31,6 +31,10 @@ type Props = {
|
|||||||
options?: { value: string; label?: string; helpText?: string }[];
|
options?: { value: string; label?: string; helpText?: string }[];
|
||||||
} & ComponentProps<typeof RadixRadio.Root>;
|
} & ComponentProps<typeof RadixRadio.Root>;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @beta
|
||||||
|
* @since 2.48.0
|
||||||
|
*/
|
||||||
const RadioGroup = React.forwardRef<HTMLDivElement, Props>(({ options, children, className, ...props }, ref) => (
|
const RadioGroup = React.forwardRef<HTMLDivElement, Props>(({ options, children, className, ...props }, ref) => (
|
||||||
<RadixRadio.Root {...props} asChild>
|
<RadixRadio.Root {...props} asChild>
|
||||||
<Control ref={ref} className={className}>
|
<Control ref={ref} className={className}>
|
||||||
|
|||||||
@@ -35,6 +35,10 @@ type Props = {
|
|||||||
helpText?: string;
|
helpText?: string;
|
||||||
} & ComponentProps<typeof RadioGroup>;
|
} & ComponentProps<typeof RadioGroup>;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @beta
|
||||||
|
* @since 2.48.0
|
||||||
|
*/
|
||||||
const RadioGroupField = React.forwardRef<HTMLDivElement, Props>(
|
const RadioGroupField = React.forwardRef<HTMLDivElement, Props>(
|
||||||
({ fieldClassName, labelClassName, label, helpText, children, ...props }, ref) => {
|
({ fieldClassName, labelClassName, label, helpText, children, ...props }, ref) => {
|
||||||
return (
|
return (
|
||||||
|
|||||||
Reference in New Issue
Block a user