@primevue/mcp 4.5.5 → 5.0.0-rc.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE.md +45 -21
- package/README.md +48 -250
- package/data/components.json +47269 -0
- package/data/llms/components/accordion.md +629 -0
- package/data/llms/components/animateonscroll.md +165 -0
- package/data/llms/components/autocomplete.md +995 -0
- package/data/llms/components/avatar.md +264 -0
- package/data/llms/components/badge.md +200 -0
- package/data/llms/components/blockui.md +99 -0
- package/data/llms/components/breadcrumb.md +269 -0
- package/data/llms/components/button.md +902 -0
- package/data/llms/components/card.md +209 -0
- package/data/llms/components/carousel.md +506 -0
- package/data/llms/components/cascadeselect.md +1207 -0
- package/data/llms/components/chart.md +1022 -0
- package/data/llms/components/checkbox.md +401 -0
- package/data/llms/components/chip.md +206 -0
- package/data/llms/components/colorpicker.md +213 -0
- package/data/llms/components/commandmenu.md +660 -0
- package/data/llms/components/compare.md +407 -0
- package/data/llms/components/confirmdialog.md +343 -0
- package/data/llms/components/confirmpopup.md +252 -0
- package/data/llms/components/contextmenu.md +522 -0
- package/data/llms/components/datatable.md +5266 -0
- package/data/llms/components/dataview.md +569 -0
- package/data/llms/components/datepicker.md +964 -0
- package/data/llms/components/deferredcontent.md +96 -0
- package/data/llms/components/dialog.md +702 -0
- package/data/llms/components/divider.md +152 -0
- package/data/llms/components/dock.md +488 -0
- package/data/llms/components/drawer.md +469 -0
- package/data/llms/components/dynamicdialog.md +214 -0
- package/data/llms/components/editor.md +205 -0
- package/data/llms/components/fieldset.md +253 -0
- package/data/llms/components/fileupload.md +459 -0
- package/data/llms/components/floatlabel.md +144 -0
- package/data/llms/components/fluid.md +104 -0
- package/data/llms/components/focustrap.md +59 -0
- package/data/llms/components/forms.md +344 -0
- package/data/llms/components/galleria.md +1119 -0
- package/data/llms/components/gallery.md +1003 -0
- package/data/llms/components/iconfield.md +283 -0
- package/data/llms/components/iftalabel.md +96 -0
- package/data/llms/components/image.md +179 -0
- package/data/llms/components/imagecompare.md +108 -0
- package/data/llms/components/inplace.md +183 -0
- package/data/llms/components/inputcolor.md +869 -0
- package/data/llms/components/inputgroup.md +419 -0
- package/data/llms/components/inputmask.md +345 -0
- package/data/llms/components/inputnumber.md +551 -0
- package/data/llms/components/inputotp.md +345 -0
- package/data/llms/components/inputpassword.md +738 -0
- package/data/llms/components/inputtags.md +432 -0
- package/data/llms/components/inputtext.md +569 -0
- package/data/llms/components/installation.md +1 -0
- package/data/llms/components/keyfilter.md +116 -0
- package/data/llms/components/knob.md +318 -0
- package/data/llms/components/label.md +151 -0
- package/data/llms/components/laravel.md +53 -0
- package/data/llms/components/listbox.md +636 -0
- package/data/llms/components/mask.md +203 -0
- package/data/llms/components/mcp.md +39 -0
- package/data/llms/components/megamenu.md +563 -0
- package/data/llms/components/menu.md +651 -0
- package/data/llms/components/menubar.md +446 -0
- package/data/llms/components/message.md +497 -0
- package/data/llms/components/metergroup.md +281 -0
- package/data/llms/components/multiselect.md +752 -0
- package/data/llms/components/orderlist.md +224 -0
- package/data/llms/components/organizationchart.md +418 -0
- package/data/llms/components/paginator.md +221 -0
- package/data/llms/components/panel.md +321 -0
- package/data/llms/components/panelmenu.md +703 -0
- package/data/llms/components/password.md +657 -0
- package/data/llms/components/picklist.md +286 -0
- package/data/llms/components/popover.md +145 -0
- package/data/llms/components/progressbar.md +242 -0
- package/data/llms/components/progressspinner.md +104 -0
- package/data/llms/components/radiobutton.md +427 -0
- package/data/llms/components/rating.md +312 -0
- package/data/llms/components/ripple.md +91 -0
- package/data/llms/components/scrollarea.md +700 -0
- package/data/llms/components/scrollpanel.md +131 -0
- package/data/llms/components/scrolltop.md +87 -0
- package/data/llms/components/select.md +1251 -0
- package/data/llms/components/selectbutton.md +268 -0
- package/data/llms/components/sidebar.md +2232 -0
- package/data/llms/components/skeleton.md +302 -0
- package/data/llms/components/slider.md +416 -0
- package/data/llms/components/speeddial.md +402 -0
- package/data/llms/components/splitbutton.md +840 -0
- package/data/llms/components/splitter.md +447 -0
- package/data/llms/components/stepper.md +551 -0
- package/data/llms/components/styleclass.md +226 -0
- package/data/llms/components/tabs.md +609 -0
- package/data/llms/components/tag.md +178 -0
- package/data/llms/components/terminal.md +123 -0
- package/data/llms/components/textarea.md +519 -0
- package/data/llms/components/tieredmenu.md +578 -0
- package/data/llms/components/timeline.md +494 -0
- package/data/llms/components/toast.md +472 -0
- package/data/llms/components/togglebutton.md +276 -0
- package/data/llms/components/toggleswitch.md +271 -0
- package/data/llms/components/toolbar.md +140 -0
- package/data/llms/components/tooltip.md +160 -0
- package/data/llms/components/tree.md +1076 -0
- package/data/llms/components/treeselect.md +660 -0
- package/data/llms/components/treetable.md +2493 -0
- package/data/llms/components/virtualscroller.md +265 -0
- package/data/llms/guides/autoimport.md +28 -0
- package/data/llms/guides/cdn.md +72 -0
- package/data/llms/guides/configuration.md +158 -0
- package/data/llms/guides/customicons.md +67 -0
- package/data/llms/guides/guides/accessibility.md +27 -0
- package/data/llms/guides/guides/animations.md +119 -0
- package/data/llms/guides/guides/rtl.md +7 -0
- package/data/llms/guides/icons.md +136 -0
- package/data/llms/guides/installation.md +3 -0
- package/data/llms/guides/laravel.md +66 -0
- package/data/llms/guides/llms.md +15 -0
- package/data/llms/guides/mcp.md +104 -0
- package/data/llms/guides/migration/v4.md +15 -0
- package/data/llms/guides/migration/v5.md +15 -0
- package/data/llms/guides/nuxt.md +141 -0
- package/data/llms/guides/passthrough.md +137 -0
- package/data/llms/guides/primeclt.md +43 -0
- package/data/llms/guides/tailwind.md +151 -0
- package/data/llms/guides/theming/styled.md +497 -0
- package/data/llms/guides/theming/unstyled.md +57 -0
- package/data/llms/guides/uikit.md +3 -0
- package/data/llms/guides/vite.md +90 -0
- package/data/llms/llms-full.txt +54465 -0
- package/data/llms/llms.txt +132 -0
- package/data/llms/pages/accessibility.md +27 -0
- package/data/llms/pages/animations.md +119 -0
- package/data/llms/pages/autoimport.md +28 -0
- package/data/llms/pages/cdn.md +72 -0
- package/data/llms/pages/configuration.md +158 -0
- package/data/llms/pages/contribution.md +31 -0
- package/data/llms/pages/customicons.md +67 -0
- package/data/llms/pages/designer.md +79 -0
- package/data/llms/pages/dynamicimports.md +7 -0
- package/data/llms/pages/forms.md +63 -0
- package/data/llms/pages/guides/accessibility.md +27 -0
- package/data/llms/pages/guides/animations.md +119 -0
- package/data/llms/pages/guides/rtl.md +7 -0
- package/data/llms/pages/icons.md +136 -0
- package/data/llms/pages/installation.md +3 -0
- package/data/llms/pages/introduction.md +23 -0
- package/data/llms/pages/laravel.md +66 -0
- package/data/llms/pages/llms.md +15 -0
- package/data/llms/pages/mcp.md +104 -0
- package/data/llms/pages/migration/v4.md +15 -0
- package/data/llms/pages/migration/v5.md +15 -0
- package/data/llms/pages/nuxt.md +141 -0
- package/data/llms/pages/passthrough.md +137 -0
- package/data/llms/pages/primeclt.md +43 -0
- package/data/llms/pages/rtl.md +7 -0
- package/data/llms/pages/setup.md +3 -0
- package/data/llms/pages/styled.md +497 -0
- package/data/llms/pages/tailwind.md +151 -0
- package/data/llms/pages/theming/styled.md +497 -0
- package/data/llms/pages/theming/unstyled.md +57 -0
- package/data/llms/pages/uikit.md +3 -0
- package/data/llms/pages/unstyled.md +57 -0
- package/data/llms/pages/v4.md +15 -0
- package/data/llms/pages/v5.md +15 -0
- package/data/llms/pages/vite.md +90 -0
- package/data/manifest.json +11117 -0
- package/data/mcp-data.json +55940 -0
- package/dist/index.d.ts +17 -1
- package/dist/index.js +66066 -72541
- package/package.json +10 -12
|
@@ -0,0 +1,1003 @@
|
|
|
1
|
+
# Gallery
|
|
2
|
+
|
|
3
|
+
Gallery is an image viewer with zoom, rotate, flip and download capabilities.
|
|
4
|
+
|
|
5
|
+
## Basic
|
|
6
|
+
|
|
7
|
+
Displays a collection of images with a lightbox viewer.
|
|
8
|
+
|
|
9
|
+
```vue
|
|
10
|
+
<template>
|
|
11
|
+
<Gallery class="w-full not-data-fullscreen:h-150!">
|
|
12
|
+
<GalleryBackdrop />
|
|
13
|
+
|
|
14
|
+
<GalleryPrev>
|
|
15
|
+
<ChevronLeft />
|
|
16
|
+
</GalleryPrev>
|
|
17
|
+
<GalleryNext>
|
|
18
|
+
<ChevronRight />
|
|
19
|
+
</GalleryNext>
|
|
20
|
+
|
|
21
|
+
<GalleryContent>
|
|
22
|
+
<GalleryItem v-for="(image, index) in images" :key="image">
|
|
23
|
+
<img :src="image" :alt="\`image-\${index + 1}\`" />
|
|
24
|
+
</GalleryItem>
|
|
25
|
+
</GalleryContent>
|
|
26
|
+
</Gallery>
|
|
27
|
+
</template>
|
|
28
|
+
|
|
29
|
+
<script setup>
|
|
30
|
+
import ChevronLeft from '@primeicons/vue/chevron-left';
|
|
31
|
+
import ChevronRight from '@primeicons/vue/chevron-right';
|
|
32
|
+
|
|
33
|
+
const photos = [
|
|
34
|
+
[10, 1200, 800],
|
|
35
|
+
[11, 800, 1200],
|
|
36
|
+
[15, 1400, 700],
|
|
37
|
+
[16, 700, 1050],
|
|
38
|
+
[17, 1000, 1000]
|
|
39
|
+
];
|
|
40
|
+
|
|
41
|
+
const images = photos.map(([id, w, h]) => \`https://picsum.photos/id/\${id}/\${w}/\${h}\`);
|
|
42
|
+
<\/script>
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
## Toolbar
|
|
46
|
+
|
|
47
|
+
Add a GalleryHeader with action sub-components like GalleryRotateLeft , GalleryZoomIn , GalleryDownload , and GalleryFullScreen to expose image controls.
|
|
48
|
+
|
|
49
|
+
```vue
|
|
50
|
+
<template>
|
|
51
|
+
<Gallery class="h-150!">
|
|
52
|
+
<GalleryBackdrop />
|
|
53
|
+
|
|
54
|
+
<GalleryPrev>
|
|
55
|
+
<ChevronLeft />
|
|
56
|
+
</GalleryPrev>
|
|
57
|
+
<GalleryNext>
|
|
58
|
+
<ChevronRight />
|
|
59
|
+
</GalleryNext>
|
|
60
|
+
|
|
61
|
+
<GalleryHeader class="justify-end gap-0.5">
|
|
62
|
+
<GalleryRotateLeft>
|
|
63
|
+
<Replay />
|
|
64
|
+
</GalleryRotateLeft>
|
|
65
|
+
<GalleryRotateRight>
|
|
66
|
+
<Refresh />
|
|
67
|
+
</GalleryRotateRight>
|
|
68
|
+
<GalleryZoomIn>
|
|
69
|
+
<SearchPlus />
|
|
70
|
+
</GalleryZoomIn>
|
|
71
|
+
<GalleryZoomOut>
|
|
72
|
+
<SearchMinus />
|
|
73
|
+
</GalleryZoomOut>
|
|
74
|
+
<GalleryFlipX>
|
|
75
|
+
<ArrowsH />
|
|
76
|
+
</GalleryFlipX>
|
|
77
|
+
<GalleryFlipY>
|
|
78
|
+
<ArrowsV />
|
|
79
|
+
</GalleryFlipY>
|
|
80
|
+
<GalleryDownload>
|
|
81
|
+
<Download />
|
|
82
|
+
</GalleryDownload>
|
|
83
|
+
<GalleryFullScreen class="group">
|
|
84
|
+
<ArrowUpRightAndArrowDownLeftFromCenter class="group-data-[fullscreen]:hidden" />
|
|
85
|
+
<ArrowDownLeftAndArrowUpRightToCenter class="hidden group-data-[fullscreen]:block" />
|
|
86
|
+
</GalleryFullScreen>
|
|
87
|
+
</GalleryHeader>
|
|
88
|
+
|
|
89
|
+
<GalleryContent>
|
|
90
|
+
<GalleryItem v-for="(image, index) in images" :key="image">
|
|
91
|
+
<img :src="image" :alt="\`image-\${index + 1}\`" />
|
|
92
|
+
</GalleryItem>
|
|
93
|
+
</GalleryContent>
|
|
94
|
+
</Gallery>
|
|
95
|
+
</template>
|
|
96
|
+
|
|
97
|
+
<script setup>
|
|
98
|
+
import ArrowDownLeftAndArrowUpRightToCenter from '@primeicons/vue/arrow-down-left-and-arrow-up-right-to-center';
|
|
99
|
+
import ArrowUpRightAndArrowDownLeftFromCenter from '@primeicons/vue/arrow-up-right-and-arrow-down-left-from-center';
|
|
100
|
+
import ArrowsH from '@primeicons/vue/arrows-h';
|
|
101
|
+
import ArrowsV from '@primeicons/vue/arrows-v';
|
|
102
|
+
import ChevronLeft from '@primeicons/vue/chevron-left';
|
|
103
|
+
import ChevronRight from '@primeicons/vue/chevron-right';
|
|
104
|
+
import Download from '@primeicons/vue/download';
|
|
105
|
+
import Refresh from '@primeicons/vue/refresh';
|
|
106
|
+
import Replay from '@primeicons/vue/replay';
|
|
107
|
+
import SearchMinus from '@primeicons/vue/search-minus';
|
|
108
|
+
import SearchPlus from '@primeicons/vue/search-plus';
|
|
109
|
+
|
|
110
|
+
const photos = [
|
|
111
|
+
[10, 1200, 800],
|
|
112
|
+
[11, 800, 1200],
|
|
113
|
+
[15, 1400, 700],
|
|
114
|
+
[16, 700, 1050],
|
|
115
|
+
[17, 1000, 1000]
|
|
116
|
+
];
|
|
117
|
+
|
|
118
|
+
const images = photos.map(([id, w, h]) => \`https://picsum.photos/id/\${id}/\${w}/\${h}\`);
|
|
119
|
+
<\/script>
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
## Thumbnails
|
|
123
|
+
|
|
124
|
+
Add a GalleryFooter with GalleryThumbnail to render a thumbnail strip for quick navigation.
|
|
125
|
+
|
|
126
|
+
```vue
|
|
127
|
+
<template>
|
|
128
|
+
<Gallery class="h-150!">
|
|
129
|
+
<GalleryBackdrop />
|
|
130
|
+
|
|
131
|
+
<GalleryPrev>
|
|
132
|
+
<ChevronLeft />
|
|
133
|
+
</GalleryPrev>
|
|
134
|
+
<GalleryNext>
|
|
135
|
+
<ChevronRight />
|
|
136
|
+
</GalleryNext>
|
|
137
|
+
|
|
138
|
+
<GalleryContent>
|
|
139
|
+
<GalleryItem v-for="(image, index) in images" :key="image">
|
|
140
|
+
<img :src="image" :alt="\`image-\${index + 1}\`" />
|
|
141
|
+
</GalleryItem>
|
|
142
|
+
</GalleryContent>
|
|
143
|
+
|
|
144
|
+
<GalleryFooter>
|
|
145
|
+
<GalleryThumbnail>
|
|
146
|
+
<GalleryThumbnailContent>
|
|
147
|
+
<GalleryThumbnailItem v-for="(image, index) in images" :key="index" :index="index">
|
|
148
|
+
<img draggable="false" :src="image" class="h-full w-full object-cover" />
|
|
149
|
+
</GalleryThumbnailItem>
|
|
150
|
+
</GalleryThumbnailContent>
|
|
151
|
+
</GalleryThumbnail>
|
|
152
|
+
</GalleryFooter>
|
|
153
|
+
</Gallery>
|
|
154
|
+
</template>
|
|
155
|
+
|
|
156
|
+
<script setup>
|
|
157
|
+
import ChevronLeft from '@primeicons/vue/chevron-left';
|
|
158
|
+
import ChevronRight from '@primeicons/vue/chevron-right';
|
|
159
|
+
|
|
160
|
+
const photos = [
|
|
161
|
+
[10, 1200, 800],
|
|
162
|
+
[11, 800, 1200],
|
|
163
|
+
[15, 1400, 700],
|
|
164
|
+
[16, 700, 1050],
|
|
165
|
+
[17, 1000, 1000],
|
|
166
|
+
[18, 1300, 650],
|
|
167
|
+
[19, 600, 1200],
|
|
168
|
+
[20, 1200, 900],
|
|
169
|
+
[27, 750, 1125],
|
|
170
|
+
[28, 1400, 800],
|
|
171
|
+
[29, 800, 1100],
|
|
172
|
+
[36, 1100, 700],
|
|
173
|
+
[37, 650, 1300],
|
|
174
|
+
[39, 1200, 750],
|
|
175
|
+
[42, 900, 1200],
|
|
176
|
+
[43, 1300, 800],
|
|
177
|
+
[47, 700, 1400],
|
|
178
|
+
[48, 1000, 800],
|
|
179
|
+
[49, 800, 1000],
|
|
180
|
+
[50, 1400, 600],
|
|
181
|
+
[52, 600, 900],
|
|
182
|
+
[53, 1200, 1200],
|
|
183
|
+
[54, 900, 600],
|
|
184
|
+
[55, 750, 1000],
|
|
185
|
+
[56, 1100, 800],
|
|
186
|
+
[57, 1400, 900],
|
|
187
|
+
[58, 850, 1275],
|
|
188
|
+
[59, 1000, 600],
|
|
189
|
+
[60, 600, 1000],
|
|
190
|
+
[64, 1300, 1300]
|
|
191
|
+
];
|
|
192
|
+
|
|
193
|
+
const images = photos.map(([id, w, h]) => \`https://picsum.photos/id/\${id}/\${w}/\${h}\`);
|
|
194
|
+
<\/script>
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
## Single
|
|
198
|
+
|
|
199
|
+
Click on the image to open it in a fullscreen dialog without thumbnails or navigation buttons.
|
|
200
|
+
|
|
201
|
+
```vue
|
|
202
|
+
<template>
|
|
203
|
+
<div class="flex justify-center">
|
|
204
|
+
<div class="w-80 aspect-3/2 cursor-pointer hover:opacity-75 transition-opacity" @click="open = true">
|
|
205
|
+
<img :src="image" alt="image" class="w-full h-full object-cover rounded-lg" />
|
|
206
|
+
</div>
|
|
207
|
+
<Gallery v-if="open" fullscreen @update:fullscreen="open = $event">
|
|
208
|
+
<GalleryBackdrop />
|
|
209
|
+
<GalleryHeader class="justify-end gap-0.5">
|
|
210
|
+
<GalleryRotateLeft>
|
|
211
|
+
<Replay />
|
|
212
|
+
</GalleryRotateLeft>
|
|
213
|
+
<GalleryRotateRight>
|
|
214
|
+
<Refresh />
|
|
215
|
+
</GalleryRotateRight>
|
|
216
|
+
<GalleryZoomIn>
|
|
217
|
+
<SearchPlus />
|
|
218
|
+
</GalleryZoomIn>
|
|
219
|
+
<GalleryZoomOut>
|
|
220
|
+
<SearchMinus />
|
|
221
|
+
</GalleryZoomOut>
|
|
222
|
+
<GalleryFlipX>
|
|
223
|
+
<ArrowsH />
|
|
224
|
+
</GalleryFlipX>
|
|
225
|
+
<GalleryFlipY>
|
|
226
|
+
<ArrowsV />
|
|
227
|
+
</GalleryFlipY>
|
|
228
|
+
<GalleryDownload>
|
|
229
|
+
<Download />
|
|
230
|
+
</GalleryDownload>
|
|
231
|
+
<button class="p-gallery-action" @click="open = false">
|
|
232
|
+
<Times />
|
|
233
|
+
</button>
|
|
234
|
+
</GalleryHeader>
|
|
235
|
+
<GalleryContent>
|
|
236
|
+
<GalleryItem>
|
|
237
|
+
<img :src="image" alt="image" />
|
|
238
|
+
</GalleryItem>
|
|
239
|
+
</GalleryContent>
|
|
240
|
+
</Gallery>
|
|
241
|
+
</div>
|
|
242
|
+
</template>
|
|
243
|
+
|
|
244
|
+
<script setup>
|
|
245
|
+
import { ref } from 'vue';
|
|
246
|
+
import ArrowsH from '@primeicons/vue/arrows-h';
|
|
247
|
+
import ArrowsV from '@primeicons/vue/arrows-v';
|
|
248
|
+
import Download from '@primeicons/vue/download';
|
|
249
|
+
import Refresh from '@primeicons/vue/refresh';
|
|
250
|
+
import Replay from '@primeicons/vue/replay';
|
|
251
|
+
import SearchMinus from '@primeicons/vue/search-minus';
|
|
252
|
+
import SearchPlus from '@primeicons/vue/search-plus';
|
|
253
|
+
import Times from '@primeicons/vue/times';
|
|
254
|
+
|
|
255
|
+
const image = ref('https://picsum.photos/id/10/1200/800');
|
|
256
|
+
const open = ref(false);
|
|
257
|
+
<\/script>
|
|
258
|
+
```
|
|
259
|
+
|
|
260
|
+
## Grid
|
|
261
|
+
|
|
262
|
+
Gallery can be used as a lightbox by combining it with a grid of thumbnails. Click on an image to open the gallery in fullscreen mode.
|
|
263
|
+
|
|
264
|
+
```vue
|
|
265
|
+
<template>
|
|
266
|
+
<div class="grid grid-cols-2 md:grid-cols-4 2xl:grid-cols-6 gap-2">
|
|
267
|
+
<div v-for="(image, index) in images" :key="image" class="aspect-square cursor-pointer hover:opacity-75 transition-opacity" @click="openAt(index)">
|
|
268
|
+
<img :src="image" alt="image" class="w-full h-full object-cover rounded-lg" />
|
|
269
|
+
</div>
|
|
270
|
+
</div>
|
|
271
|
+
|
|
272
|
+
<Gallery v-if="open" fullscreen v-model:activeIndex="activeIndex" class="transition-opacity duration-200" :class="visible ? 'opacity-100' : 'opacity-0'" @update:fullscreen="onFullscreenChange">
|
|
273
|
+
<GalleryBackdrop />
|
|
274
|
+
<GalleryPrev>
|
|
275
|
+
<ChevronLeft />
|
|
276
|
+
</GalleryPrev>
|
|
277
|
+
<GalleryNext>
|
|
278
|
+
<ChevronRight />
|
|
279
|
+
</GalleryNext>
|
|
280
|
+
<GalleryHeader class="justify-end gap-0.5">
|
|
281
|
+
<GalleryRotateLeft>
|
|
282
|
+
<Replay />
|
|
283
|
+
</GalleryRotateLeft>
|
|
284
|
+
<GalleryRotateRight>
|
|
285
|
+
<Refresh />
|
|
286
|
+
</GalleryRotateRight>
|
|
287
|
+
<GalleryZoomIn>
|
|
288
|
+
<SearchPlus />
|
|
289
|
+
</GalleryZoomIn>
|
|
290
|
+
<GalleryZoomOut>
|
|
291
|
+
<SearchMinus />
|
|
292
|
+
</GalleryZoomOut>
|
|
293
|
+
<GalleryFlipX>
|
|
294
|
+
<ArrowsH />
|
|
295
|
+
</GalleryFlipX>
|
|
296
|
+
<GalleryFlipY>
|
|
297
|
+
<ArrowsV />
|
|
298
|
+
</GalleryFlipY>
|
|
299
|
+
<GalleryDownload>
|
|
300
|
+
<Download />
|
|
301
|
+
</GalleryDownload>
|
|
302
|
+
<button type="button" class="p-gallery-action" @click="close">
|
|
303
|
+
<Times />
|
|
304
|
+
</button>
|
|
305
|
+
</GalleryHeader>
|
|
306
|
+
<GalleryContent>
|
|
307
|
+
<GalleryItem v-for="(image, index) in images" :key="image">
|
|
308
|
+
<img :src="image" :alt="\`image-\${index + 1}\`" class="transition-[scale,filter] duration-300" :class="visible ? 'scale-100 blur-none' : 'scale-[0.9] blur-2xl'" />
|
|
309
|
+
</GalleryItem>
|
|
310
|
+
</GalleryContent>
|
|
311
|
+
<GalleryFooter>
|
|
312
|
+
<GalleryThumbnail>
|
|
313
|
+
<GalleryThumbnailContent>
|
|
314
|
+
<GalleryThumbnailItem v-for="(image, index) in images" :key="index" :index="index">
|
|
315
|
+
<img draggable="false" :src="image" class="h-full w-full object-cover" />
|
|
316
|
+
</GalleryThumbnailItem>
|
|
317
|
+
</GalleryThumbnailContent>
|
|
318
|
+
</GalleryThumbnail>
|
|
319
|
+
</GalleryFooter>
|
|
320
|
+
</Gallery>
|
|
321
|
+
</template>
|
|
322
|
+
|
|
323
|
+
<script setup>
|
|
324
|
+
import { nextTick, ref } from 'vue';
|
|
325
|
+
import ArrowsH from '@primeicons/vue/arrows-h';
|
|
326
|
+
import ArrowsV from '@primeicons/vue/arrows-v';
|
|
327
|
+
import ChevronLeft from '@primeicons/vue/chevron-left';
|
|
328
|
+
import ChevronRight from '@primeicons/vue/chevron-right';
|
|
329
|
+
import Download from '@primeicons/vue/download';
|
|
330
|
+
import Refresh from '@primeicons/vue/refresh';
|
|
331
|
+
import Replay from '@primeicons/vue/replay';
|
|
332
|
+
import SearchMinus from '@primeicons/vue/search-minus';
|
|
333
|
+
import SearchPlus from '@primeicons/vue/search-plus';
|
|
334
|
+
import Times from '@primeicons/vue/times';
|
|
335
|
+
|
|
336
|
+
const photos = [
|
|
337
|
+
[10, 1200, 800],
|
|
338
|
+
[11, 800, 1200],
|
|
339
|
+
[15, 1400, 700],
|
|
340
|
+
[16, 700, 1050],
|
|
341
|
+
[17, 1000, 1000],
|
|
342
|
+
[18, 1300, 650],
|
|
343
|
+
[19, 600, 1200],
|
|
344
|
+
[20, 1200, 900],
|
|
345
|
+
[27, 750, 1125],
|
|
346
|
+
[28, 1400, 800],
|
|
347
|
+
[29, 800, 1100],
|
|
348
|
+
[36, 1100, 700],
|
|
349
|
+
[37, 650, 1300],
|
|
350
|
+
[39, 1200, 750],
|
|
351
|
+
[42, 900, 1200],
|
|
352
|
+
[43, 1300, 800],
|
|
353
|
+
[47, 700, 1400],
|
|
354
|
+
[48, 1000, 800],
|
|
355
|
+
[49, 800, 1000],
|
|
356
|
+
[50, 1400, 600],
|
|
357
|
+
[52, 600, 900],
|
|
358
|
+
[53, 1200, 1200],
|
|
359
|
+
[54, 900, 600],
|
|
360
|
+
[55, 750, 1000],
|
|
361
|
+
[56, 1100, 800],
|
|
362
|
+
[57, 1400, 900],
|
|
363
|
+
[58, 850, 1275],
|
|
364
|
+
[59, 1000, 600],
|
|
365
|
+
[60, 600, 1000],
|
|
366
|
+
[64, 1300, 1300]
|
|
367
|
+
];
|
|
368
|
+
|
|
369
|
+
const images = ref(photos.map(([id, w, h]) => \`https://picsum.photos/id/\${id}/\${w}/\${h}\`));
|
|
370
|
+
const open = ref(false);
|
|
371
|
+
const activeIndex = ref(0);
|
|
372
|
+
const visible = ref(false);
|
|
373
|
+
|
|
374
|
+
const openAt = (index) => {
|
|
375
|
+
activeIndex.value = index;
|
|
376
|
+
open.value = true;
|
|
377
|
+
nextTick(() => requestAnimationFrame(() => (visible.value = true)));
|
|
378
|
+
};
|
|
379
|
+
|
|
380
|
+
const close = () => {
|
|
381
|
+
if (!open.value) return;
|
|
382
|
+
visible.value = false;
|
|
383
|
+
setTimeout(() => (open.value = false), 200);
|
|
384
|
+
};
|
|
385
|
+
|
|
386
|
+
const onFullscreenChange = (value) => {
|
|
387
|
+
if (!value) close();
|
|
388
|
+
};
|
|
389
|
+
<\/script>
|
|
390
|
+
```
|
|
391
|
+
|
|
392
|
+
## Accessibility
|
|
393
|
+
|
|
394
|
+
Screen Reader Gallery uses semantic button elements for all interactive controls. Use aria-label attributes on buttons to provide accessible names.
|
|
395
|
+
|
|
396
|
+
## Gallery API
|
|
397
|
+
|
|
398
|
+
### Props
|
|
399
|
+
|
|
400
|
+
| Name |Type |Default |Description |
|
|
401
|
+
| --- | --- | --- | --- |
|
|
402
|
+
| activeIndex | number | 0 | Index of the active item. Pair with `v-model:activeIndex` for two-way binding. |
|
|
403
|
+
| as | string \| Component | DIV | Use to change the HTML tag of root element. |
|
|
404
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
405
|
+
| fullscreen | boolean | false | When enabled, the gallery is displayed in fullscreen mode. Pair with `v-model:fullscreen` for two-way binding. |
|
|
406
|
+
| closeOnEscape | boolean | true | Whether pressing the Escape key exits fullscreen mode. |
|
|
407
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
408
|
+
| pt | PassThrough<GalleryPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
409
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
410
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
411
|
+
|
|
412
|
+
### Pass Through Options
|
|
413
|
+
|
|
414
|
+
| Name |Type |Description |
|
|
415
|
+
| --- | --- | --- |
|
|
416
|
+
| root | GalleryPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
417
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
418
|
+
|
|
419
|
+
### Theming
|
|
420
|
+
|
|
421
|
+
### CSS Classes
|
|
422
|
+
|
|
423
|
+
| Class |Description |
|
|
424
|
+
| --- | --- |
|
|
425
|
+
| p-gallery | Class name of the root element |
|
|
426
|
+
|
|
427
|
+
### Design Tokens
|
|
428
|
+
|
|
429
|
+
| Token |CSS Variable |Description |
|
|
430
|
+
| --- | --- | --- |
|
|
431
|
+
| gallery.backdrop.background | --p-gallery-backdrop-background | Background of backdrop |
|
|
432
|
+
| gallery.header.padding | --p-gallery-header-padding | Padding of header |
|
|
433
|
+
| gallery.header.background | --p-gallery-header-background | Background of header |
|
|
434
|
+
| gallery.footer.padding | --p-gallery-footer-padding | Padding of footer |
|
|
435
|
+
| gallery.footer.background | --p-gallery-footer-background | Background of footer |
|
|
436
|
+
| gallery.footer.border.color | --p-gallery-footer-border-color | Border color of footer |
|
|
437
|
+
| gallery.item.transition.duration | --p-gallery-item-transition-duration | Transition duration of item (transform and opacity) |
|
|
438
|
+
| gallery.action.size | --p-gallery-action-size | Size of action (shared by action / next / prev) |
|
|
439
|
+
| gallery.action.border.radius | --p-gallery-action-border-radius | Border radius of action |
|
|
440
|
+
| gallery.action.color | --p-gallery-action-color | Color of action |
|
|
441
|
+
| gallery.action.hover.background | --p-gallery-action-hover-background | Hover background of action |
|
|
442
|
+
| gallery.action.hover.color | --p-gallery-action-hover-color | Hover color of action |
|
|
443
|
+
| gallery.action.disabled.opacity | --p-gallery-action-disabled-opacity | Disabled opacity of action |
|
|
444
|
+
| gallery.action.transition.duration | --p-gallery-action-transition-duration | Transition duration of action |
|
|
445
|
+
| gallery.action.icon.size | --p-gallery-action-icon-size | Icon size of action |
|
|
446
|
+
| gallery.navigation.background | --p-gallery-navigation-background | Background of navigation (next / prev) |
|
|
447
|
+
| gallery.navigation.size | --p-gallery-navigation-size | Size of navigation |
|
|
448
|
+
| gallery.navigation.border.radius | --p-gallery-navigation-border-radius | Border radius of navigation |
|
|
449
|
+
| gallery.navigation.color | --p-gallery-navigation-color | Color of navigation |
|
|
450
|
+
| gallery.navigation.hover.background | --p-gallery-navigation-hover-background | Hover background of navigation |
|
|
451
|
+
| gallery.navigation.hover.color | --p-gallery-navigation-hover-color | Hover color of navigation |
|
|
452
|
+
| gallery.navigation.offset | --p-gallery-navigation-offset | Edge offset of navigation |
|
|
453
|
+
| gallery.navigation.transition.duration | --p-gallery-navigation-transition-duration | Transition duration of navigation |
|
|
454
|
+
| gallery.navigation.icon.size | --p-gallery-navigation-icon-size | Icon size of navigation |
|
|
455
|
+
| gallery.thumbnail.size | --p-gallery-thumbnail-size | Size of thumbnail item |
|
|
456
|
+
| gallery.thumbnail.padding | --p-gallery-thumbnail-padding | Padding of thumbnail item |
|
|
457
|
+
| gallery.thumbnail.background | --p-gallery-thumbnail-background | Background of thumbnail item |
|
|
458
|
+
| gallery.thumbnail.border.radius | --p-gallery-thumbnail-border-radius | Border radius of thumbnail item |
|
|
459
|
+
| gallery.thumbnail.border.width | --p-gallery-thumbnail-border-width | Border width of thumbnail item (outline width) |
|
|
460
|
+
| gallery.thumbnail.hover.border.color | --p-gallery-thumbnail-hover-border-color | Hover border color of thumbnail item |
|
|
461
|
+
| gallery.thumbnail.active.border.color | --p-gallery-thumbnail-active-border-color | Active border color of thumbnail item |
|
|
462
|
+
| gallery.thumbnail.active.scale | --p-gallery-thumbnail-active-scale | Active scale of thumbnail item |
|
|
463
|
+
| gallery.thumbnail.transition.duration | --p-gallery-thumbnail-transition-duration | Transition duration of thumbnail item |
|
|
464
|
+
| gallery.thumbnail.content.padding | --p-gallery-thumbnail-content-padding | Padding of thumbnail content |
|
|
465
|
+
|
|
466
|
+
## Gallery Backdrop API
|
|
467
|
+
|
|
468
|
+
### Props
|
|
469
|
+
|
|
470
|
+
| Name |Type |Default |Description |
|
|
471
|
+
| --- | --- | --- | --- |
|
|
472
|
+
| as | string \| Component | DIV | Use to change the HTML tag of root element. |
|
|
473
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
474
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
475
|
+
| pt | PassThrough<GalleryBackdropPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
476
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
477
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
478
|
+
|
|
479
|
+
### Pass Through Options
|
|
480
|
+
|
|
481
|
+
| Name |Type |Description |
|
|
482
|
+
| --- | --- | --- |
|
|
483
|
+
| root | GalleryBackdropPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
484
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
485
|
+
|
|
486
|
+
### Theming
|
|
487
|
+
|
|
488
|
+
### CSS Classes
|
|
489
|
+
|
|
490
|
+
| Class |Description |
|
|
491
|
+
| --- | --- |
|
|
492
|
+
| p-gallery-backdrop | Class name of the root element |
|
|
493
|
+
|
|
494
|
+
## Gallery Header API
|
|
495
|
+
|
|
496
|
+
### Props
|
|
497
|
+
|
|
498
|
+
| Name |Type |Default |Description |
|
|
499
|
+
| --- | --- | --- | --- |
|
|
500
|
+
| as | string \| Component | DIV | Use to change the HTML tag of root element. |
|
|
501
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
502
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
503
|
+
| pt | PassThrough<GalleryHeaderPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
504
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
505
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
506
|
+
|
|
507
|
+
### Pass Through Options
|
|
508
|
+
|
|
509
|
+
| Name |Type |Description |
|
|
510
|
+
| --- | --- | --- |
|
|
511
|
+
| root | GalleryHeaderPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
512
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
513
|
+
|
|
514
|
+
### Theming
|
|
515
|
+
|
|
516
|
+
### CSS Classes
|
|
517
|
+
|
|
518
|
+
| Class |Description |
|
|
519
|
+
| --- | --- |
|
|
520
|
+
| p-gallery-header | Class name of the root element |
|
|
521
|
+
|
|
522
|
+
## Gallery Content API
|
|
523
|
+
|
|
524
|
+
### Props
|
|
525
|
+
|
|
526
|
+
| Name |Type |Default |Description |
|
|
527
|
+
| --- | --- | --- | --- |
|
|
528
|
+
| as | string \| Component | DIV | Use to change the HTML tag of root element. |
|
|
529
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. The slot receives `a11yAttrs` that include the function ref Gallery uses as the reference box for item sizing. |
|
|
530
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
531
|
+
| pt | PassThrough<GalleryContentPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
532
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
533
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
534
|
+
|
|
535
|
+
### Pass Through Options
|
|
536
|
+
|
|
537
|
+
| Name |Type |Description |
|
|
538
|
+
| --- | --- | --- |
|
|
539
|
+
| root | GalleryContentPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
540
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
541
|
+
|
|
542
|
+
### Theming
|
|
543
|
+
|
|
544
|
+
### CSS Classes
|
|
545
|
+
|
|
546
|
+
| Class |Description |
|
|
547
|
+
| --- | --- |
|
|
548
|
+
| p-gallery-content | Class name of the root element |
|
|
549
|
+
|
|
550
|
+
## Gallery Item API
|
|
551
|
+
|
|
552
|
+
### Props
|
|
553
|
+
|
|
554
|
+
| Name |Type |Default |Description |
|
|
555
|
+
| --- | --- | --- | --- |
|
|
556
|
+
| normalScale | number | 1 | Scale factor when the item is at its natural (non-zoomed) state. |
|
|
557
|
+
| zoomedScale | number | 3 | Maximum scale factor reached when the item is zoomed in. |
|
|
558
|
+
| as | string \| Component | DIV | Use to change the HTML tag of root element. |
|
|
559
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
560
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
561
|
+
| pt | PassThrough<GalleryItemPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
562
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
563
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
564
|
+
|
|
565
|
+
### Pass Through Options
|
|
566
|
+
|
|
567
|
+
| Name |Type |Description |
|
|
568
|
+
| --- | --- | --- |
|
|
569
|
+
| root | GalleryItemPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
570
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
571
|
+
|
|
572
|
+
### Theming
|
|
573
|
+
|
|
574
|
+
### CSS Classes
|
|
575
|
+
|
|
576
|
+
| Class |Description |
|
|
577
|
+
| --- | --- |
|
|
578
|
+
| p-gallery-item | Class name of the root element |
|
|
579
|
+
|
|
580
|
+
## Gallery Footer API
|
|
581
|
+
|
|
582
|
+
### Props
|
|
583
|
+
|
|
584
|
+
| Name |Type |Default |Description |
|
|
585
|
+
| --- | --- | --- | --- |
|
|
586
|
+
| as | string \| Component | DIV | Use to change the HTML tag of root element. |
|
|
587
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
588
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
589
|
+
| pt | PassThrough<GalleryFooterPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
590
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
591
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
592
|
+
|
|
593
|
+
### Pass Through Options
|
|
594
|
+
|
|
595
|
+
| Name |Type |Description |
|
|
596
|
+
| --- | --- | --- |
|
|
597
|
+
| root | GalleryFooterPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
598
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
599
|
+
|
|
600
|
+
### Theming
|
|
601
|
+
|
|
602
|
+
### CSS Classes
|
|
603
|
+
|
|
604
|
+
| Class |Description |
|
|
605
|
+
| --- | --- |
|
|
606
|
+
| p-gallery-footer | Class name of the root element |
|
|
607
|
+
|
|
608
|
+
## Gallery Thumbnail API
|
|
609
|
+
|
|
610
|
+
### Props
|
|
611
|
+
|
|
612
|
+
| Name |Type |Default |Description |
|
|
613
|
+
| --- | --- | --- | --- |
|
|
614
|
+
| as | string \| Component | Carousel | Use to change the rendered element. Defaults to `Carousel` to wire the thumbnail strip into the scroll-snap carousel infrastructure. |
|
|
615
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
616
|
+
| autoSize | boolean | true | Forwarded to the underlying carousel. Each item sizes itself to its intrinsic content rather than a fixed slide width. |
|
|
617
|
+
| loop | boolean | true | Forwarded to the underlying carousel. Whether scrolling wraps around at the ends. |
|
|
618
|
+
| align | "start" \| "center" \| "end" | 'center' | Forwarded to the underlying carousel. Snap alignment for each item. |
|
|
619
|
+
| spacing | number | 8 | Forwarded to the underlying carousel. Spacing in pixels between items. |
|
|
620
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
621
|
+
| pt | PassThrough<GalleryThumbnailPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
622
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
623
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
624
|
+
|
|
625
|
+
### Pass Through Options
|
|
626
|
+
|
|
627
|
+
| Name |Type |Description |
|
|
628
|
+
| --- | --- | --- |
|
|
629
|
+
| root | GalleryThumbnailPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
630
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
631
|
+
|
|
632
|
+
### Theming
|
|
633
|
+
|
|
634
|
+
### CSS Classes
|
|
635
|
+
|
|
636
|
+
| Class |Description |
|
|
637
|
+
| --- | --- |
|
|
638
|
+
| p-gallery-thumbnail | Class name of the root element |
|
|
639
|
+
|
|
640
|
+
## Gallery Thumbnail Content API
|
|
641
|
+
|
|
642
|
+
### Props
|
|
643
|
+
|
|
644
|
+
| Name |Type |Default |Description |
|
|
645
|
+
| --- | --- | --- | --- |
|
|
646
|
+
| as | string \| Component | CarouselContent | Use to change the rendered element. Defaults to `CarouselContent` to inherit the scroll-snap track. |
|
|
647
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
648
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
649
|
+
| pt | PassThrough<GalleryThumbnailContentPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
650
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
651
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
652
|
+
|
|
653
|
+
### Pass Through Options
|
|
654
|
+
|
|
655
|
+
| Name |Type |Description |
|
|
656
|
+
| --- | --- | --- |
|
|
657
|
+
| root | GalleryThumbnailContentPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
658
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
659
|
+
|
|
660
|
+
### Theming
|
|
661
|
+
|
|
662
|
+
### CSS Classes
|
|
663
|
+
|
|
664
|
+
| Class |Description |
|
|
665
|
+
| --- | --- |
|
|
666
|
+
| p-gallery-thumbnail-content | Class name of the root element |
|
|
667
|
+
|
|
668
|
+
## Gallery Thumbnail Item API
|
|
669
|
+
|
|
670
|
+
### Props
|
|
671
|
+
|
|
672
|
+
| Name |Type |Default |Description |
|
|
673
|
+
| --- | --- | --- | --- |
|
|
674
|
+
| index | number | undefined | Index of the gallery item this thumbnail represents. When the user clicks it, Gallery sets its `activeIndex` to this value. |
|
|
675
|
+
| as | string \| Component | CarouselItem | Use to change the rendered element. Defaults to `CarouselItem` so the thumbnail participates in the scroll-snap layout provided by the parent carousel. |
|
|
676
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
677
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
678
|
+
| pt | PassThrough<GalleryThumbnailItemPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
679
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
680
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
681
|
+
|
|
682
|
+
### Pass Through Options
|
|
683
|
+
|
|
684
|
+
| Name |Type |Description |
|
|
685
|
+
| --- | --- | --- |
|
|
686
|
+
| root | GalleryThumbnailItemPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
687
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
688
|
+
|
|
689
|
+
### Theming
|
|
690
|
+
|
|
691
|
+
### CSS Classes
|
|
692
|
+
|
|
693
|
+
| Class |Description |
|
|
694
|
+
| --- | --- |
|
|
695
|
+
| p-gallery-thumbnail-item | Class name of the root element |
|
|
696
|
+
|
|
697
|
+
## Gallery Prev API
|
|
698
|
+
|
|
699
|
+
### Props
|
|
700
|
+
|
|
701
|
+
| Name |Type |Default |Description |
|
|
702
|
+
| --- | --- | --- | --- |
|
|
703
|
+
| as | string \| Component | BUTTON | Use to change the HTML tag of root element. |
|
|
704
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
705
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
706
|
+
| pt | PassThrough<GalleryPrevPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
707
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
708
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
709
|
+
|
|
710
|
+
### Pass Through Options
|
|
711
|
+
|
|
712
|
+
| Name |Type |Description |
|
|
713
|
+
| --- | --- | --- |
|
|
714
|
+
| root | GalleryPrevPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
715
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
716
|
+
|
|
717
|
+
### Theming
|
|
718
|
+
|
|
719
|
+
### CSS Classes
|
|
720
|
+
|
|
721
|
+
| Class |Description |
|
|
722
|
+
| --- | --- |
|
|
723
|
+
| p-gallery-prev | Class name of the root element |
|
|
724
|
+
|
|
725
|
+
## Gallery Next API
|
|
726
|
+
|
|
727
|
+
### Props
|
|
728
|
+
|
|
729
|
+
| Name |Type |Default |Description |
|
|
730
|
+
| --- | --- | --- | --- |
|
|
731
|
+
| as | string \| Component | BUTTON | Use to change the HTML tag of root element. |
|
|
732
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
733
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
734
|
+
| pt | PassThrough<GalleryNextPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
735
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
736
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
737
|
+
|
|
738
|
+
### Pass Through Options
|
|
739
|
+
|
|
740
|
+
| Name |Type |Description |
|
|
741
|
+
| --- | --- | --- |
|
|
742
|
+
| root | GalleryNextPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
743
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
744
|
+
|
|
745
|
+
### Theming
|
|
746
|
+
|
|
747
|
+
### CSS Classes
|
|
748
|
+
|
|
749
|
+
| Class |Description |
|
|
750
|
+
| --- | --- |
|
|
751
|
+
| p-gallery-next | Class name of the root element |
|
|
752
|
+
|
|
753
|
+
## Gallery Rotate Left API
|
|
754
|
+
|
|
755
|
+
### Props
|
|
756
|
+
|
|
757
|
+
| Name |Type |Default |Description |
|
|
758
|
+
| --- | --- | --- | --- |
|
|
759
|
+
| as | string \| Component | BUTTON | Use to change the HTML tag of root element. |
|
|
760
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
761
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
762
|
+
| pt | PassThrough<GalleryRotateLeftPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
763
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
764
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
765
|
+
|
|
766
|
+
### Pass Through Options
|
|
767
|
+
|
|
768
|
+
| Name |Type |Description |
|
|
769
|
+
| --- | --- | --- |
|
|
770
|
+
| root | GalleryRotateLeftPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
771
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
772
|
+
|
|
773
|
+
### Theming
|
|
774
|
+
|
|
775
|
+
### CSS Classes
|
|
776
|
+
|
|
777
|
+
| Class |Description |
|
|
778
|
+
| --- | --- |
|
|
779
|
+
| p-gallery-rotate-left | Class name of the root element |
|
|
780
|
+
|
|
781
|
+
## Gallery Rotate Right API
|
|
782
|
+
|
|
783
|
+
### Props
|
|
784
|
+
|
|
785
|
+
| Name |Type |Default |Description |
|
|
786
|
+
| --- | --- | --- | --- |
|
|
787
|
+
| as | string \| Component | BUTTON | Use to change the HTML tag of root element. |
|
|
788
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
789
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
790
|
+
| pt | PassThrough<GalleryRotateRightPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
791
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
792
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
793
|
+
|
|
794
|
+
### Pass Through Options
|
|
795
|
+
|
|
796
|
+
| Name |Type |Description |
|
|
797
|
+
| --- | --- | --- |
|
|
798
|
+
| root | GalleryRotateRightPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
799
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
800
|
+
|
|
801
|
+
### Theming
|
|
802
|
+
|
|
803
|
+
### CSS Classes
|
|
804
|
+
|
|
805
|
+
| Class |Description |
|
|
806
|
+
| --- | --- |
|
|
807
|
+
| p-gallery-rotate-right | Class name of the root element |
|
|
808
|
+
|
|
809
|
+
## Gallery Zoom In API
|
|
810
|
+
|
|
811
|
+
### Props
|
|
812
|
+
|
|
813
|
+
| Name |Type |Default |Description |
|
|
814
|
+
| --- | --- | --- | --- |
|
|
815
|
+
| as | string \| Component | BUTTON | Use to change the HTML tag of root element. |
|
|
816
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
817
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
818
|
+
| pt | PassThrough<GalleryZoomInPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
819
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
820
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
821
|
+
|
|
822
|
+
### Pass Through Options
|
|
823
|
+
|
|
824
|
+
| Name |Type |Description |
|
|
825
|
+
| --- | --- | --- |
|
|
826
|
+
| root | GalleryZoomInPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
827
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
828
|
+
|
|
829
|
+
### Theming
|
|
830
|
+
|
|
831
|
+
### CSS Classes
|
|
832
|
+
|
|
833
|
+
| Class |Description |
|
|
834
|
+
| --- | --- |
|
|
835
|
+
| p-gallery-zoom-in | Class name of the root element |
|
|
836
|
+
|
|
837
|
+
## Gallery Zoom Out API
|
|
838
|
+
|
|
839
|
+
### Props
|
|
840
|
+
|
|
841
|
+
| Name |Type |Default |Description |
|
|
842
|
+
| --- | --- | --- | --- |
|
|
843
|
+
| as | string \| Component | BUTTON | Use to change the HTML tag of root element. |
|
|
844
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
845
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
846
|
+
| pt | PassThrough<GalleryZoomOutPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
847
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
848
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
849
|
+
|
|
850
|
+
### Pass Through Options
|
|
851
|
+
|
|
852
|
+
| Name |Type |Description |
|
|
853
|
+
| --- | --- | --- |
|
|
854
|
+
| root | GalleryZoomOutPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
855
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
856
|
+
|
|
857
|
+
### Theming
|
|
858
|
+
|
|
859
|
+
### CSS Classes
|
|
860
|
+
|
|
861
|
+
| Class |Description |
|
|
862
|
+
| --- | --- |
|
|
863
|
+
| p-gallery-zoom-out | Class name of the root element |
|
|
864
|
+
|
|
865
|
+
## Gallery Zoom Toggle API
|
|
866
|
+
|
|
867
|
+
### Props
|
|
868
|
+
|
|
869
|
+
| Name |Type |Default |Description |
|
|
870
|
+
| --- | --- | --- | --- |
|
|
871
|
+
| as | string \| Component | BUTTON | Use to change the HTML tag of root element. |
|
|
872
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
873
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
874
|
+
| pt | PassThrough<GalleryZoomTogglePassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
875
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
876
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
877
|
+
|
|
878
|
+
### Pass Through Options
|
|
879
|
+
|
|
880
|
+
| Name |Type |Description |
|
|
881
|
+
| --- | --- | --- |
|
|
882
|
+
| root | GalleryZoomTogglePassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
883
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
884
|
+
|
|
885
|
+
### Theming
|
|
886
|
+
|
|
887
|
+
### CSS Classes
|
|
888
|
+
|
|
889
|
+
| Class |Description |
|
|
890
|
+
| --- | --- |
|
|
891
|
+
| p-gallery-zoom-toggle | Class name of the root element |
|
|
892
|
+
|
|
893
|
+
## Gallery Flip X API
|
|
894
|
+
|
|
895
|
+
### Props
|
|
896
|
+
|
|
897
|
+
| Name |Type |Default |Description |
|
|
898
|
+
| --- | --- | --- | --- |
|
|
899
|
+
| as | string \| Component | BUTTON | Use to change the HTML tag of root element. |
|
|
900
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
901
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
902
|
+
| pt | PassThrough<GalleryFlipXPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
903
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
904
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
905
|
+
|
|
906
|
+
### Pass Through Options
|
|
907
|
+
|
|
908
|
+
| Name |Type |Description |
|
|
909
|
+
| --- | --- | --- |
|
|
910
|
+
| root | GalleryFlipXPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
911
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
912
|
+
|
|
913
|
+
### Theming
|
|
914
|
+
|
|
915
|
+
### CSS Classes
|
|
916
|
+
|
|
917
|
+
| Class |Description |
|
|
918
|
+
| --- | --- |
|
|
919
|
+
| p-gallery-flip-x | Class name of the root element |
|
|
920
|
+
|
|
921
|
+
## Gallery Flip Y API
|
|
922
|
+
|
|
923
|
+
### Props
|
|
924
|
+
|
|
925
|
+
| Name |Type |Default |Description |
|
|
926
|
+
| --- | --- | --- | --- |
|
|
927
|
+
| as | string \| Component | BUTTON | Use to change the HTML tag of root element. |
|
|
928
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
929
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
930
|
+
| pt | PassThrough<GalleryFlipYPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
931
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
932
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
933
|
+
|
|
934
|
+
### Pass Through Options
|
|
935
|
+
|
|
936
|
+
| Name |Type |Description |
|
|
937
|
+
| --- | --- | --- |
|
|
938
|
+
| root | GalleryFlipYPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
939
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
940
|
+
|
|
941
|
+
### Theming
|
|
942
|
+
|
|
943
|
+
### CSS Classes
|
|
944
|
+
|
|
945
|
+
| Class |Description |
|
|
946
|
+
| --- | --- |
|
|
947
|
+
| p-gallery-flip-y | Class name of the root element |
|
|
948
|
+
|
|
949
|
+
## Gallery Download API
|
|
950
|
+
|
|
951
|
+
### Props
|
|
952
|
+
|
|
953
|
+
| Name |Type |Default |Description |
|
|
954
|
+
| --- | --- | --- | --- |
|
|
955
|
+
| as | string \| Component | BUTTON | Use to change the HTML tag of root element. |
|
|
956
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
957
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
958
|
+
| pt | PassThrough<GalleryDownloadPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
959
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
960
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
961
|
+
|
|
962
|
+
### Pass Through Options
|
|
963
|
+
|
|
964
|
+
| Name |Type |Description |
|
|
965
|
+
| --- | --- | --- |
|
|
966
|
+
| root | GalleryDownloadPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
967
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
968
|
+
|
|
969
|
+
### Theming
|
|
970
|
+
|
|
971
|
+
### CSS Classes
|
|
972
|
+
|
|
973
|
+
| Class |Description |
|
|
974
|
+
| --- | --- |
|
|
975
|
+
| p-gallery-download | Class name of the root element |
|
|
976
|
+
|
|
977
|
+
## Gallery Full Screen API
|
|
978
|
+
|
|
979
|
+
### Props
|
|
980
|
+
|
|
981
|
+
| Name |Type |Default |Description |
|
|
982
|
+
| --- | --- | --- | --- |
|
|
983
|
+
| as | string \| Component | BUTTON | Use to change the HTML tag of root element. |
|
|
984
|
+
| asChild | boolean | false | When enabled, it changes the default rendered element for the one passed as a child element. |
|
|
985
|
+
| dt | any | - | It generates scoped CSS variables using design tokens for the component. |
|
|
986
|
+
| pt | PassThrough<GalleryFullScreenPassThroughOptions> | - | Used to pass attributes to DOM elements inside the component. |
|
|
987
|
+
| ptOptions | any | - | Used to configure passthrough(pt) options of the component. |
|
|
988
|
+
| unstyled | boolean | false | When enabled, it removes component related styles in the core. |
|
|
989
|
+
|
|
990
|
+
### Pass Through Options
|
|
991
|
+
|
|
992
|
+
| Name |Type |Description |
|
|
993
|
+
| --- | --- | --- |
|
|
994
|
+
| root | GalleryFullScreenPassThroughOptionType | Used to pass attributes to the root's DOM element. |
|
|
995
|
+
| hooks | any | Used to manage all lifecycle hooks. |
|
|
996
|
+
|
|
997
|
+
### Theming
|
|
998
|
+
|
|
999
|
+
### CSS Classes
|
|
1000
|
+
|
|
1001
|
+
| Class |Description |
|
|
1002
|
+
| --- | --- |
|
|
1003
|
+
| p-gallery-fullscreen | Class name of the root element |
|