import type { FormFieldState } from '@primevue/forms'; import { type InjectionKey, type MaybeRefOrGetter } from 'vue'; import type { FormInstance, FormValues } from '../types/form.js'; /** * The injection key for acquiring a {@link FormInstance} object within the * descendant component of a Form. Consider using {@link injectFormInstance} * instead. */ export declare const FormSymbol: InjectionKey; /** * Helper method to create a new stateful object for a Form. You shouldn't ever * need to use this directly. * * @private */ export declare function createFormInstance(uid?: string): FormInstance; /** * Provides the object that a Form uses to convey stateful information to the * DI registry. You shouldn't ever need to use this directly. * * @private */ export declare function provideFormInstance(uid?: string): FormInstance; /** * Injects the stateful object provided by an ancestor Form instance. If not * available, a dummy state object is generated. * * @private */ export declare function injectFormInstance(uid?: string): FormInstance; /** * Takes a Primevue Form's `states` object, and extracts the current values * of each named property. In doing so, it will deref proxies, and create * shallow clones of any arrays/objects it encounters. * * @private */ export declare function getValuesFromFormState(state: Record): T; /** * @private */ export type UseOptionListMethodsConfig = { optionLabel?: string | ((data: unknown) => string); optionValue?: string | ((data: unknown) => string); optionIcon?: string | ((data: unknown) => string); optionDisabled?: string | ((data: unknown) => boolean); optionDataKey?: string; }; /** * Creates a set of common methods for interacting with an array of "options" like what * gets provided to a Select or RadioGroup. * * @private */ export declare function useOptionListMethods(config: MaybeRefOrGetter): import("vue").ComputedRef<{ getOptionLabel: (option: unknown) => string; getOptionValue: (option: unknown) => unknown; getOptionIcon: (option: unknown) => string | undefined; getOptionDisabled: (option: unknown) => boolean; getOptionRenderKey: (option: unknown) => string | number | undefined; getOptionIndex: (needle: unknown, haystack: unknown) => number; getOptionByValue: (needle: unknown, haystack: MaybeRefOrGetter) => T | undefined; }>;