@base-ui/react
Version:
Base UI is a library of headless ('unstyled') React components and low-level hooks. You gain complete control over your app's CSS and accessibility features.
19 lines • 632 B
TypeScript
import * as React from 'react';
export declare function useLabelableId(params?: useLabelableId.Parameters): string | undefined;
export interface UseLabelableIdParameters {
id?: string | undefined;
/**
* Whether implicit labelling is supported.
* @default false
*/
implicit?: boolean | undefined;
/**
* A ref to an element that can be implicitly labelled.
*/
controlRef?: React.RefObject<HTMLElement | null> | undefined;
}
export type UseLabelableIdReturnValue = string;
export declare namespace useLabelableId {
type Parameters = UseLabelableIdParameters;
type ReturnValue = UseLabelableIdReturnValue;
}