UNPKG

bootstrap-vue-next

Version:

BootstrapVueNext is an early and lovely component library for Vue 3 & Nuxt 3 based on Bootstrap 5 and Typescript.

181 lines (180 loc) 8.11 kB
import { ComponentInternalInstance, ComputedRef, InjectionKey, Ref } from 'vue'; import { TabType } from '../types/Tab'; import { ClassValue } from '../types/AnyValuedAttributes'; import { Numberish, ValidationState } from '../types/CommonTypes'; import { LiteralUnion } from '../types/LiteralUnion'; import { Size } from '../types/Size'; import { RadiusElement } from '../types/RadiusElement'; import { BgColorVariant, ButtonVariant, ColorVariant, TextColorVariant } from '../types/ColorTypes'; import { CheckboxValue } from '../types/CheckboxTypes'; import { RadioValue } from '../types/RadioTypes'; import { BreadcrumbItemRaw } from '../types/BreadcrumbTypes'; import { ControllerKey, ModalOrchestratorMapValue, ModalOrchestratorShowParam, PopoverOrchestratorParam, PopoverOrchestratorShowParam, ToastOrchestratorArrayValue, ToastOrchestratorShowParam, TooltipOrchestratorParam, TooltipOrchestratorShowParam } from '../types/ComponentOrchestratorTypes'; import { BvnComponentProps } from '../types/BootstrapVueOptions'; export declare const genericBvnPrefix = "BootstrapVueNext__"; export declare const withBvnPrefix: (value: string, suffix?: string) => string; export declare const carouselInjectionKey: InjectionKey<{ background: Readonly<Ref<string | undefined>>; width: Readonly<Ref<string | undefined>>; height: Readonly<Ref<string | undefined>>; }>; export declare const tabsInjectionKey: InjectionKey<{ lazy: Readonly<Ref<boolean>>; card: Readonly<Ref<boolean>>; noFade: Readonly<Ref<boolean>>; registerTab: (tab: Readonly<Ref<TabType>>) => void; unregisterTab: (id: string) => void; activateTab: (id: string | undefined) => void; activeTabClass: Readonly<Ref<ClassValue>>; inactiveTabClass: Readonly<Ref<ClassValue>>; tabClass: Readonly<Ref<ClassValue>>; activeId: Readonly<Ref<string | undefined>>; }>; export declare const progressInjectionKey: InjectionKey<{ animated: Readonly<Ref<boolean | undefined>>; max: Readonly<Ref<Numberish>>; showProgress: Readonly<Ref<boolean | undefined>>; showValue: Readonly<Ref<boolean | undefined>>; striped: Readonly<Ref<boolean | undefined>>; }>; export declare const listGroupInjectionKey: InjectionKey<{ numbered: Readonly<Ref<boolean>>; }>; export declare const avatarGroupInjectionKey: InjectionKey<{ overlapScale: Readonly<Ref<number>>; size: Readonly<Ref<LiteralUnion<Size, Numberish> | undefined>>; square: Readonly<Ref<boolean>>; rounded: Readonly<Ref<RadiusElement | boolean>>; roundedTop: Readonly<Ref<RadiusElement | boolean | undefined>>; roundedBottom: Readonly<Ref<RadiusElement | boolean | undefined>>; roundedStart: Readonly<Ref<RadiusElement | boolean | undefined>>; roundedEnd: Readonly<Ref<RadiusElement | boolean | undefined>>; variant: Readonly<Ref<ColorVariant | null>>; bgVariant: Readonly<Ref<BgColorVariant | null>>; textVariant: Readonly<Ref<TextColorVariant | null>>; }>; export declare const accordionInjectionKey: InjectionKey<{ openItem: Readonly<Ref<string | undefined>>; free: Readonly<Ref<boolean>>; initialAnimation: Readonly<Ref<boolean>>; lazy: Readonly<Ref<boolean>>; unmountLazy: Readonly<Ref<boolean>>; setOpenItem: (id: string) => void; }>; export declare const checkboxGroupKey: InjectionKey<{ modelValue: Ref<readonly CheckboxValue[]>; switch: Readonly<Ref<boolean>>; buttonVariant: Readonly<Ref<ButtonVariant | null>>; form: Readonly<Ref<string | undefined>>; name: Readonly<Ref<string>>; state: Readonly<Ref<ValidationState | undefined>>; plain: Readonly<Ref<boolean>>; size: Readonly<Ref<Size>>; inline: Readonly<Ref<boolean>>; reverse: Readonly<Ref<boolean>>; required: Readonly<Ref<boolean>>; buttons: Readonly<Ref<boolean>>; disabled: Readonly<Ref<boolean>>; }>; export declare const radioGroupKey: InjectionKey<{ modelValue: Ref<RadioValue>; buttonVariant: Readonly<Ref<ButtonVariant | null>>; form: Readonly<Ref<string | undefined>>; name: Readonly<Ref<string>>; buttons: Readonly<Ref<boolean>>; state: Readonly<Ref<ValidationState | undefined>>; plain: Readonly<Ref<boolean>>; size: Readonly<Ref<Size>>; inline: Readonly<Ref<boolean>>; reverse: Readonly<Ref<boolean>>; required: Readonly<Ref<boolean>>; disabled: Readonly<Ref<boolean>>; }>; export declare const collapseInjectionKey: InjectionKey<{ id?: Readonly<Ref<string>>; readonly hide?: () => void; readonly show?: () => void; readonly toggle?: () => void; visible?: Readonly<Ref<boolean>>; isNav?: Readonly<Ref<boolean>>; }>; export type RegisterShowHideFnInput = { id: string; value: Ref<boolean>; toggle: () => void; show: () => void; hide: (trigger?: string) => void; }; export interface RegisterShowHideValue { (input: RegisterShowHideFnInput): { unregister: () => void; }; map: Readonly<Record<string, { value: boolean; toggle: () => void; show: () => void; hide: (trigger?: string) => void; }>>; } export declare const globalShowHideStorageInjectionKey: InjectionKey<RegisterShowHideValue>; export declare const dropdownInjectionKey: InjectionKey<{ id?: Readonly<Ref<string>>; readonly hide?: () => void; readonly show?: () => void; readonly toggle?: () => void; visible?: Readonly<Ref<boolean>>; isNav?: Readonly<Ref<boolean>>; }>; export declare const navbarInjectionKey: InjectionKey<{ tag?: Readonly<Ref<string>>; autoClose?: Readonly<Ref<boolean>>; }>; export declare const rtlPluginKey: InjectionKey<{ isRtl: Ref<boolean>; locale: Ref<string | undefined>; }>; export declare const breadcrumbGlobalIndexKey = "BootstrapVueNext__global_breadcrumb"; export declare const breadcrumbPluginKey: InjectionKey<{ items: Ref<Record<string, BreadcrumbItemRaw[]>>; reset: (key?: string) => void; }>; export declare const modalManagerPluginKey: InjectionKey<{ stack: ComputedRef<ComponentInternalInstance[]>; countStack: ComputedRef<number>; lastStack: ComputedRef<ComponentInternalInstance | undefined>; pushStack: (modal: Readonly<ComponentInternalInstance>) => void; removeStack: (modal: Readonly<ComponentInternalInstance>) => void; registry: Readonly<Ref<Map<number, ComponentInternalInstance>>>; pushRegistry: (modal: Readonly<ComponentInternalInstance>) => void; removeRegistry: (modal: Readonly<ComponentInternalInstance>) => void; }>; export declare const defaultsKey: InjectionKey<Ref<Partial<BvnComponentProps>>>; export declare const inputGroupKey: InjectionKey<boolean>; export declare const buttonGroupKey: InjectionKey<boolean>; export declare const toastPluginKey: InjectionKey<{ toasts: Ref<ToastOrchestratorArrayValue[]>; _setIsAppend: (value: boolean) => void; show: (obj: ToastOrchestratorShowParam) => ControllerKey; remove: (self: ControllerKey) => void; leave: (self: ControllerKey) => void; }>; export declare const modalControllerPluginKey: InjectionKey<{ modals: Ref<Map<ControllerKey, ModalOrchestratorMapValue>>; show: (obj: ModalOrchestratorShowParam) => Promise<boolean | null>; confirm: (obj: ModalOrchestratorShowParam) => Promise<boolean | null>; remove: (self: ControllerKey) => void; leave: (self: ControllerKey) => void; }>; export declare const popoverPluginKey: InjectionKey<{ popovers: Ref<Map<ControllerKey, PopoverOrchestratorParam>>; popover: (obj: PopoverOrchestratorShowParam) => ControllerKey; setPopover: (self: ControllerKey, val: Partial<PopoverOrchestratorParam>) => void; removePopover: (self: ControllerKey) => void; tooltips: Ref<Map<ControllerKey, TooltipOrchestratorParam>>; tooltip: (obj: TooltipOrchestratorShowParam) => ControllerKey; setTooltip: (self: ControllerKey, val: Partial<TooltipOrchestratorParam>) => void; removeTooltip: (self: ControllerKey) => void; }>; export declare const formGroupPluginKey: InjectionKey<(id: Ref<string>) => { state: Readonly<Ref<ValidationState | undefined>>; }>;