/** * * GalleryThumbnailItem represents a single thumbnail tile inside `GalleryThumbnailContent`. Clicking it activates * the corresponding gallery item via `index`. The root carries `data-active` while it represents the active item. * * By default it renders as `CarouselItem` so it integrates with the underlying scroll-snap carousel. * * [Live Demo](https://www.primevue.dev/gallery/) * * @module gallerythumbnailitem * */ import type { DefineComponent, DesignToken, EmitFn, PassThrough } from '@primevue/core'; import type { ComponentHooks } from '@primevue/core/basecomponent'; import type { PassThroughOptions } from 'primevue/passthrough'; import type { Component, HTMLAttributes, VNode } from 'vue'; export declare type GalleryThumbnailItemPassThroughOptionType = GalleryThumbnailItemPassThroughAttributes | ((options: GalleryThumbnailItemPassThroughMethodOptions) => GalleryThumbnailItemPassThroughAttributes | string) | string | null | undefined; /** * Custom passthrough(pt) option method. */ export interface GalleryThumbnailItemPassThroughMethodOptions { /** * Defines instance. */ instance: any; /** * Defines valid properties. */ props: GalleryThumbnailItemProps; /** * Defines valid attributes. */ attrs: any; /** * Defines parent options. */ parent: any; /** * Defines passthrough(pt) options in global config. */ global: object | undefined; } /** * Custom passthrough(pt) options. * @see {@link GalleryThumbnailItemProps.pt} */ export interface GalleryThumbnailItemPassThroughOptions { /** * Used to pass attributes to the root's DOM element. */ root?: GalleryThumbnailItemPassThroughOptionType; /** * Used to manage all lifecycle hooks. */ hooks?: ComponentHooks; } /** * Custom passthrough attributes for each DOM elements. */ export interface GalleryThumbnailItemPassThroughAttributes { [key: string]: any; } /** * Defines valid properties in GalleryThumbnailItem component. */ export interface GalleryThumbnailItemProps { /** * Index of the gallery item this thumbnail represents. When the user clicks it, Gallery sets its * `activeIndex` to this value. * @defaultValue undefined */ index?: number | undefined; /** * Use to change the rendered element. Defaults to `CarouselItem` so the thumbnail participates in * the scroll-snap layout provided by the parent carousel. * @defaultValue CarouselItem */ as?: string | Component | undefined; /** * When enabled, it changes the default rendered element for the one passed as a child element. * @defaultValue false */ asChild?: boolean | undefined; /** * It generates scoped CSS variables using design tokens for the component. */ dt?: DesignToken; /** * Used to pass attributes to DOM elements inside the component. */ pt?: PassThrough; /** * Used to configure passthrough(pt) options of the component. */ ptOptions?: PassThroughOptions; /** * When enabled, it removes component related styles in the core. * @defaultValue false */ unstyled?: boolean; } /** * Root element attributes forwarded to the consumer when `asChild` is enabled. */ export interface GalleryThumbnailItemA11yAttrs extends HTMLAttributes { /** * PrimeVue component identifier. */ 'data-pc-name': 'gallerythumbnailitem'; /** * PrimeVue section identifier within the component. */ 'data-pc-section': 'root'; /** * Present when this thumbnail represents the currently active gallery item. */ 'data-active'?: '' | undefined; /** * Click handler that selects this thumbnail's index in Gallery. */ onClick: (event: MouseEvent) => void; } /** * Defines valid slots in GalleryThumbnailItem component. */ export interface GalleryThumbnailItemSlots { /** * Custom content template. Receives `active` (and consumer-targeted props when `asChild` is enabled). * @param {Object} scope - default slot's params. */ default(scope: { /** * Computed class name for the thumbnail root (only emitted when `asChild` is enabled). */ class?: string | object | Array; /** * Attributes to spread on the consumer's root element so the parent Gallery * can detect active state and intercept the click (only emitted when `asChild` * is enabled). */ a11yAttrs?: GalleryThumbnailItemA11yAttrs; /** * Whether this thumbnail represents the currently active gallery item. */ active: boolean; }): VNode[]; } /** * Defines valid emits in GalleryThumbnailItem component. */ export interface GalleryThumbnailItemEmitsOptions {} export declare type GalleryThumbnailItemEmits = EmitFn; /** * **PrimeVue - GalleryThumbnailItem** * * _GalleryThumbnailItem is a helper component for Gallery component._ * * [Live Demo](https://www.primevue.dev/gallery/) * --- --- * ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png) * * @group Component * */ declare const GalleryThumbnailItem: DefineComponent; declare module 'vue' { export interface GlobalComponents { GalleryThumbnailItem: DefineComponent; } } export default GalleryThumbnailItem;