UNPKG

31.6 kBTypeScriptView Raw
1import { A11yOptions } from './modules/a11y';
2import { AutoplayOptions } from './modules/autoplay';
3import { ControllerOptions } from './modules/controller';
4import { CoverflowEffectOptions } from './modules/effect-coverflow';
5import { CubeEffectOptions } from './modules/effect-cube';
6import { FadeEffectOptions } from './modules/effect-fade';
7import { FlipEffectOptions } from './modules/effect-flip';
8import { CreativeEffectOptions } from './modules/effect-creative';
9import { CardsEffectOptions } from './modules/effect-cards';
10import { HashNavigationOptions } from './modules/hash-navigation';
11import { HistoryOptions } from './modules/history';
12import { KeyboardOptions } from './modules/keyboard';
13import { LazyOptions } from './modules/lazy';
14import { MousewheelOptions } from './modules/mousewheel';
15import { NavigationOptions } from './modules/navigation';
16import { PaginationOptions } from './modules/pagination';
17import { ParallaxOptions } from './modules/parallax';
18import { ScrollbarOptions } from './modules/scrollbar';
19import { ThumbsOptions } from './modules/thumbs';
20import { VirtualOptions } from './modules/virtual';
21import { ZoomOptions } from './modules/zoom';
22import { FreeModeOptions } from './modules/free-mode';
23import { GridOptions } from './modules/grid';
24
25import { CSSSelector, SwiperModule } from './shared';
26import { SwiperEvents } from './swiper-events';
27
28export interface SwiperOptions {
29 /**
30 * Array with Swiper modules
31 *
32 * @example
33 * ```js
34 * import Swiper, { Navigation, Pagination } from 'swiper';
35 *
36 * const swiper = new Swiper('.swiper', {
37 * modules: [ Navigation, Pagination ],
38 * });
39 * ```
40 */
41 modules?: SwiperModule[];
42 /**
43 * Whether Swiper should be initialised automatically when you create an instance.
44 * If disabled, then you need to init it manually by calling `swiper.init()`
45 *
46 * @default true
47 */
48 init?: boolean;
49
50 /**
51 * Whether Swiper initially enabled. When Swiper is disabled, it will hide all navigation elements and won't respond to any events and interactions
52 *
53 * @default true
54 */
55 enabled?: boolean;
56
57 /**
58 * Swiper will recalculate slides position on window resize (orientationchange)
59 *
60 * @default true
61 */
62 updateOnWindowResize?: boolean;
63
64 /**
65 * When enabled it will use ResizeObserver (if supported by browser) on swiper container to detect container resize (instead of watching for window resize)
66 *
67 * @default true
68 */
69 resizeObserver?: boolean;
70
71 /**
72 * Index number of initial slide.
73 *
74 * @default 0
75 */
76 initialSlide?: number;
77
78 /**
79 * Can be `'horizontal'` or `'vertical'` (for vertical slider).
80 *
81 * @default 'horizontal'
82 */
83 direction?: 'horizontal' | 'vertical';
84
85 /**
86 * Duration of transition between slides (in ms)
87 *
88 * @default 300
89 */
90 speed?: number;
91
92 /**
93 * Enabled this option and plugin will set width/height on swiper wrapper equal to total size of all slides.
94 * Mostly should be used as compatibility fallback option for browser that don't support flexbox layout well
95 *
96 * @default false
97 */
98 setWrapperSize?: boolean;
99
100 /**
101 * Enabled this option and swiper will be operated as usual except it will not move, real translate values on wrapper will not be set.
102 * Useful when you may need to create custom slide transition
103 *
104 * @default false
105 */
106 virtualTranslate?: boolean;
107
108 /**
109 * Swiper width (in px). Parameter allows to force Swiper width.
110 * Useful only if you initialize Swiper when it is hidden and in SSR and Test environments for correct Swiper initialization
111 *
112 * @default null
113 *
114 * @note Setting this parameter will make Swiper not responsive
115 */
116 width?: number | null;
117
118 /**
119 * Swiper height (in px). Parameter allows to force Swiper height.
120 * Useful only if you initialize Swiper when it is hidden and in SSR and Test environments for correct Swiper initialization
121 *
122 * @default null
123 *
124 * @note Setting this parameter will make Swiper not responsive
125 */
126 height?: number | null;
127
128 /**
129 * Set to `true` and slider wrapper will adapt its height to the height of the currently active slide
130 *
131 * @default false
132 */
133 autoHeight?: boolean;
134
135 /**
136 * Set to `true` to round values of slides width and height to prevent blurry texts on usual
137 * resolution screens (if you have such)
138 *
139 * @default false
140 */
141 roundLengths?: boolean;
142
143 /**
144 * Set to `true` on Swiper for correct touch events interception. Use only on
145 * swipers that use same direction as the parent one
146 *
147 * @default false
148 */
149 nested?: boolean;
150
151 /**
152 * When enabled Swiper will automatically wrap slides with swiper-wrapper element,
153 * and will create required elements for navigation, pagination and scrollbar
154 * they are enabled (with their respective params object or with boolean `true`))
155 *
156 * @default false
157 */
158 createElements?: boolean;
159
160 /**
161 * CSS selector for focusable elements. Swiping will be disabled on such elements if they are "focused"
162 *
163 * @default 'input, select, option, textarea, button, video, label'
164 */
165 focusableElements?: string;
166
167 /**
168 * If enabled (by default) and navigation elements' parameters passed as a string (like `".pagination"`)
169 * then Swiper will look for such elements through child elements first.
170 * Applies for pagination, prev/next buttons and scrollbar elements
171 *
172 * @default true
173 */
174 uniqueNavElements?: boolean;
175
176 /**
177 * Transition effect. Can be `'slide'`, `'fade'`, `'cube'`, `'coverflow'`, `'flip'` or `'creative'`
178 *
179 * @default 'slide'
180 */
181 effect?: 'slide' | 'fade' | 'cube' | 'coverflow' | 'flip' | 'creative' | 'cards';
182
183 /**
184 * Fire Transition/SlideChange/Start/End events on swiper initialization.
185 * Such events will be fired on initialization in case of your initialSlide is not 0, or you use loop mode
186 *
187 * @default true
188 */
189 runCallbacksOnInit?: boolean;
190
191 /**
192 * When enabled Swiper will be disabled and hide navigation buttons on
193 * case there are not enough slides for sliding.
194 *
195 * @default true
196 */
197 watchOverflow?: boolean;
198
199 /**
200 * userAgent string. Required for browser/device detection when rendered on server-side
201 *
202 * @default null
203 */
204 userAgent?: string | null;
205
206 /**
207 * Required for active slide detection when rendered on server-side and enabled history
208 *
209 * @default null
210 */
211 url?: string | null;
212
213 /**
214 * Register event handlers
215 */
216 on?: {
217 [event in keyof SwiperEvents]?: SwiperEvents[event];
218 };
219
220 /**
221 * Add event listener that will be fired on all events
222 *
223 * @example
224 * ```js
225 * const swiper = new Swiper('.swiper', {
226 * onAny(eventName, ...args) {
227 * console.log('Event: ', eventName);
228 * console.log('Event data: ', args);
229 * }
230 * });
231 * ```
232 */
233 onAny?(handler: (eventName: string, ...args: any[]) => void): void;
234
235 /**
236 * When enabled it will use modern CSS Scroll Snap API.
237 * It doesn't support all of Swiper's features, but potentially should bring a much better performance in simple configurations.
238 *
239 * This is what is not supported when it is enabled:
240 *
241 * - Cube and Cards effects
242 * - `speed` parameter may not have no effect
243 * - All transition start/end related events (use `slideChange` instead)
244 * - `slidesPerGroup` has limited support
245 * - `simulateTouch` doesn't have effect and "dragging" with mouse doesn't work
246 * - `resistance` doesn't have any effect
247 * - `allowSlidePrev/Next`
248 * - `swipeHandler`
249 * - `freeMode` and all relevant features
250 *
251 * @default false
252 */
253 cssMode?: boolean;
254
255 // Slides grid
256
257 /**
258 * Distance between slides in px.
259 *
260 * @default 0
261 *
262 * @note If you use "margin" css property to the elements which go into Swiper in which you pass "spaceBetween" into, navigation might not work property.
263 */
264 spaceBetween?: number;
265
266 /**
267 * Number of slides per view (slides visible at the same time on slider's container).
268 * @note If you use it with "auto" value and along with `loop: true` then you need to specify `loopedSlides` parameter with amount of slides to loop (duplicate)
269 * @note `slidesPerView: 'auto'` is currently not compatible with multirow mode, when `grid.rows` > 1
270 *
271 * @default 1
272 */
273 slidesPerView?: number | 'auto';
274
275 /**
276 * Set numbers of slides to define and enable group sliding. Useful to use with slidesPerView > 1
277 *
278 * @default 1
279 */
280 slidesPerGroup?: number;
281
282 /**
283 * The parameter works in the following way: If `slidesPerGroupSkip` equals `0` (default), no slides are excluded from grouping, and the resulting behaviour is the same as without this change.
284 *
285 * If `slidesPerGroupSkip` is equal or greater than `1` the first X slides are treated as single groups, whereas all following slides are grouped by the `slidesPerGroup` value.
286 *
287 * @default 0
288 */
289 slidesPerGroupSkip?: number;
290
291 /**
292 * This param intended to be used only with `slidesPerView: 'auto'` and `slidesPerGroup: 1`. When enabled, it will skip all slides in view on `.slideNext()` & `.slidePrev()` methods calls, on Navigation "buttons" clicks and in autoplay.
293 *
294 * @default false
295 */
296 slidesPerGroupAuto?: boolean;
297
298 /**
299 * If `true`, then active slide will be centered, not always on the left side.
300 *
301 * @default false
302 */
303 centeredSlides?: boolean;
304
305 /**
306 * If `true`, then active slide will be centered without adding gaps at the beginning and end of slider.
307 * Required `centeredSlides: true`. Not intended to be used with `loop` or `pagination`
308 *
309 * @default false
310 */
311 centeredSlidesBounds?: boolean;
312
313 /**
314 * Add (in px) additional slide offset in the beginning of the container (before all slides)
315 *
316 * @default 0
317 */
318 slidesOffsetBefore?: number;
319
320 /**
321 * Add (in px) additional slide offset in the end of the container (after all slides)
322 *
323 * @default 0
324 */
325 slidesOffsetAfter?: number;
326
327 /**
328 * Normalize slide index.
329 *
330 * @default true
331 */
332 normalizeSlideIndex?: boolean;
333
334 /**
335 * When enabled it center slides if the amount of slides less than `slidesPerView`. Not intended to be used `loop` mode and `grid.rows`
336 *
337 * @default false
338 */
339 centerInsufficientSlides?: boolean;
340
341 /**
342 * This option may a little improve desktop usability. If `true`, user will see the "grab" cursor when hover on Swiper
343 *
344 * @default false
345 */
346 grabCursor?: boolean;
347
348 /**
349 * Target element to listen touch events on. Can be `'container'` (to listen for touch events on swiper) or `'wrapper'`
350 * (to listen for touch events on swiper-wrapper)
351 *
352 * @default 'wrapper'
353 */
354 touchEventsTarget?: 'container' | 'wrapper';
355
356 /**
357 * Touch ratio
358 *
359 * @default 1
360 */
361 touchRatio?: number;
362
363 /**
364 * Allowable angle (in degrees) to trigger touch move
365 *
366 * @default 45
367 */
368 touchAngle?: number;
369
370 /**
371 * If `true`, Swiper will accept mouse events like touch events (click and drag to change slides)
372 *
373 * @default true
374 */
375 simulateTouch?: boolean;
376
377 /**
378 * Set to `false` if you want to disable short swipes
379 *
380 * @default true
381 */
382 shortSwipes?: boolean;
383
384 /**
385 * Set to `false` if you want to disable long swipes
386 *
387 * @default true
388 */
389 longSwipes?: boolean;
390
391 /**
392 * Ratio to trigger swipe to next/previous slide during long swipes
393 *
394 * @default 0.5
395 */
396 longSwipesRatio?: number;
397
398 /**
399 * Minimal duration (in ms) to trigger swipe to next/previous slide during long swipes
400 *
401 * @default 300
402 */
403 longSwipesMs?: number;
404
405 /**
406 * If disabled, then slider will be animated only when you release it, it will not move while you hold your finger on it
407 *
408 * @default true
409 */
410 followFinger?: boolean;
411
412 /**
413 * If `false`, then the only way to switch the slide is use of external API functions like slidePrev or slideNext
414 *
415 * @default true
416 */
417 allowTouchMove?: boolean;
418
419 /**
420 * Threshold value in px. If "touch distance" will be lower than this value then swiper will not move
421 *
422 * @default 0
423 */
424 threshold?: number;
425
426 /**
427 * If disabled, `touchstart` (`pointerdown`) event won't be prevented
428 *
429 * @default true
430 */
431 touchStartPreventDefault?: boolean;
432
433 /**
434 * Force to always prevent default for `touchstart` (`pointerdown`) event
435 *
436 * @default false
437 */
438 touchStartForcePreventDefault?: boolean;
439
440 /**
441 * If enabled, then propagation of "touchmove" will be stopped
442 *
443 * @default false
444 */
445 touchMoveStopPropagation?: boolean;
446
447 /**
448 * Enable to release Swiper events for swipe-back work in app. If set to `'prevent'` then it will prevent system swipe-back navigation instead
449 *
450 * @default false
451 */
452 edgeSwipeDetection?: boolean | string;
453
454 /**
455 * Area (in px) from left edge of the screen to release touch events for swipe-back in app
456 *
457 * @default 20
458 */
459 edgeSwipeThreshold?: number;
460
461 /**
462 * Enable to release touch events on slider edge position (beginning, end) to allow for further page scrolling
463 *
464 * @default false
465 */
466 touchReleaseOnEdges?: boolean;
467
468 /**
469 * Passive event listeners will be used by default where possible to improve scrolling performance on mobile devices.
470 * But if you need to use `e.preventDefault` and you have conflict with it, then you should disable this parameter
471 *
472 * @default true
473 */
474 passiveListeners?: boolean;
475
476 // Touch Resistance
477
478 /**
479 * Set to `false` if you want to disable resistant bounds
480 *
481 * @default true
482 */
483 resistance?: boolean;
484
485 /**
486 * This option allows you to control resistance ratio
487 *
488 * @default 0.85
489 */
490 resistanceRatio?: number;
491
492 // Swiping / No swiping
493 /**
494 * When enabled it won't allow to change slides by swiping or navigation/pagination buttons during transition
495 *
496 * @default false
497 */
498 preventInteractionOnTransition?: boolean;
499
500 /**
501 * Set to `false` to disable swiping to previous slide direction (to left or top)
502 *
503 * @default true
504 */
505 allowSlidePrev?: boolean;
506
507 /**
508 * Set to `false` to disable swiping to next slide direction (to right or bottom)
509 *
510 * @default true
511 */
512 allowSlideNext?: boolean;
513
514 /**
515 * Enable/disable swiping on elements matched to class specified in `noSwipingClass`
516 *
517 * @default true
518 */
519 noSwiping?: boolean;
520
521 /**
522 * Specify `noSwiping`'s element css class
523 *
524 * @default 'swiper-no-swiping'
525 */
526 noSwipingClass?: string;
527
528 /**
529 * Can be used instead of `noSwipingClass` to specify elements to disable swiping on.
530 * For example `'input'` will disable swiping on all inputs
531 *
532 * @default
533 */
534 noSwipingSelector?: string;
535
536 /**
537 * String with CSS selector or HTML element of the container with pagination that will work as only available handler for swiping
538 *
539 * @default null
540 */
541 swipeHandler?: CSSSelector | HTMLElement | null;
542
543 // Clicks
544 /**
545 * Set to `true` to prevent accidental unwanted clicks on links during swiping
546 *
547 * @default true
548 */
549 preventClicks?: boolean;
550
551 /**
552 * Set to `true` to stop clicks event propagation on links during swiping
553 *
554 * @default true
555 */
556 preventClicksPropagation?: boolean;
557
558 /**
559 * Set to `true` and click on any slide will produce transition to this slide
560 *
561 * @default false
562 */
563 slideToClickedSlide?: boolean;
564
565 // Progress
566 /**
567 * Enable this feature to calculate each slides progress and visibility (slides in viewport will have additional visible class)
568 *
569 * @default false
570 */
571 watchSlidesProgress?: boolean;
572
573 // Images
574 /**
575 * When enabled Swiper will force to load all images
576 *
577 * @default true
578 */
579 preloadImages?: boolean;
580
581 /**
582 * When enabled Swiper will be reinitialized after all inner images (<img> tags) are loaded. Required `preloadImages: true`
583 *
584 * @default true
585 */
586 updateOnImagesReady?: boolean;
587
588 /**
589 * Set to `true` to enable continuous loop mode
590 *
591 * Because of nature of how the loop mode works, it will add duplicated slides. Such duplicated slides will have additional classes:
592 * - `swiper-slide-duplicate` - represents duplicated slide
593 * - `swiper-slide-duplicate-active` - represents slide duplicated to the currently active slide
594 * - `swiper-slide-duplicate-next` - represents slide duplicated to the slide next to active
595 * - `swiper-slide-duplicate-prev` - represents slide duplicated to the slide previous to active
596 *
597 * @default false
598 *
599 * @note If you use it along with `slidesPerView: 'auto'` then you need to specify `loopedSlides` parameter with amount of slides to loop (duplicate)
600 */
601 loop?: boolean;
602
603 /**
604 * Addition number of slides that will be cloned after creating of loop
605 *
606 * @default 0
607 */
608 loopAdditionalSlides?: number;
609
610 /**
611 * If you use `slidesPerView:'auto'` with loop mode you should tell to Swiper how many slides it should loop (duplicate) using this parameter
612 *
613 * @default null
614 */
615 loopedSlides?: number | null;
616
617 /**
618 * Enable and loop mode will fill groups with insufficient number of slides with blank slides. Good to be used with `slidesPerGroup` parameter
619 *
620 * @default false
621 */
622 loopFillGroupWithBlank?: boolean;
623 /**
624 * When enabled it prevents Swiper slide prev/next transitions when transitions is already in progress (has effect when `loop` enabled)
625 *
626 * @default true
627 */
628 loopPreventsSlide?: boolean;
629
630 /**
631 * Allows to set different parameter for different responsive breakpoints (screen sizes). Not all parameters can be changed in breakpoints, only those which are not required different layout and logic, like `slidesPerView`, `slidesPerGroup`, `spaceBetween`, `grid.rows`. Such parameters like `loop` and `effect` won't work
632 *
633 * @example
634 * ```js
635 * const swiper = new Swiper('.swiper', {
636 * // Default parameters
637 * slidesPerView: 1,
638 * spaceBetween: 10,
639 * // Responsive breakpoints
640 * breakpoints: {
641 * // when window width is >= 320px
642 * 320: {
643 * slidesPerView: 2,
644 * spaceBetween: 20
645 * },
646 * // when window width is >= 480px
647 * 480: {
648 * slidesPerView: 3,
649 * spaceBetween: 30
650 * },
651 * // when window width is >= 640px
652 * 640: {
653 * slidesPerView: 4,
654 * spaceBetween: 40
655 * }
656 * }
657 * })
658 * ```
659 *
660 * @example
661 * ```js
662 * const swiper = new Swiper('.swiper', {
663 * slidesPerView: 1,
664 * spaceBetween: 10,
665 * // using "ratio" endpoints
666 * breakpoints: {
667 * '@0.75': {
668 * slidesPerView: 2,
669 * spaceBetween: 20,
670 * },
671 * '@1.00': {
672 * slidesPerView: 3,
673 * spaceBetween: 40,
674 * },
675 * '@1.50': {
676 * slidesPerView: 4,
677 * spaceBetween: 50,
678 * },
679 * }
680 * });
681 * ```
682 */
683 breakpoints?: {
684 [width: number]: SwiperOptions;
685 [ratio: string]: SwiperOptions;
686 };
687
688 /**
689 * Base for breakpoints (beta). Can be `window` or `container`. If set to `window` (by default) then breakpoint keys mean window width. If set to `container` then breakpoint keys treated as swiper container width
690 *
691 * @default 'window'
692 *
693 * @note Currently in beta and not supported by Swiper Angular, React, Svelte and Vue components
694 */
695 breakpointsBase?: string;
696
697 // Observer
698 /**
699 * Set to `true` to enable Mutation Observer on Swiper and its elements. In this case Swiper will be updated (reinitialized) each time if you change its style (like hide/show) or modify its child elements (like adding/removing slides)
700 *
701 * @default false
702 */
703 observer?: boolean;
704 /**
705 * Set to `true` if you also need to watch Mutations for Swiper slide children elements
706 *
707 * @default false
708 */
709 observeSlideChildren?: boolean;
710 /**
711 * Set to `true` if you also need to watch Mutations for Swiper parent elements
712 *
713 * @default false
714 */
715 observeParents?: boolean;
716
717 // Namespace
718 /**
719 * The beginning of the modifier CSS class that can be added to swiper container depending on different parameters
720 *
721 * @default 'swiper-'
722 */
723 containerModifierClass?: string;
724
725 /**
726 * CSS class name of slide
727 *
728 * @default 'swiper-slide'
729 *
730 * @note By changing classes you will also need to change Swiper's CSS to reflect changed classes
731 *
732 * @note Not supported in Swiper Angular/React/Svelte/Vue components
733 */
734 slideClass?: string;
735
736 /**
737 * CSS class name of currently active slide
738 *
739 * @default 'swiper-slide-active'
740 *
741 * @note By changing classes you will also need to change Swiper's CSS to reflect changed classes
742 *
743 * @note Not supported in Swiper Angular/React/Svelte/Vue components
744 */
745 slideActiveClass?: string;
746
747 /**
748 * CSS class name of duplicated slide which represents the currently active slide
749 *
750 * @default 'swiper-slide-duplicate-active'
751 *
752 * @note By changing classes you will also need to change Swiper's CSS to reflect changed classes
753 *
754 * @note Not supported in Swiper Angular/React/Svelte/Vue components
755 */
756 slideDuplicateActiveClass?: string;
757
758 /**
759 * CSS class name of currently visible slide
760 *
761 * @default 'swiper-slide-visible'
762 *
763 * @note By changing classes you will also need to change Swiper's CSS to reflect changed classes
764 *
765 * @note Not supported in Swiper Angular/React/Svelte/Vue
766 */
767 slideVisibleClass?: string;
768
769 /**
770 * CSS class name of slide duplicated by loop mode
771 *
772 * @default 'swiper-slide-duplicate'
773 *
774 * @note By changing classes you will also need to change Swiper's CSS to reflect changed classes
775 *
776 * @note Not supported in Swiper Angular/React/Svelte/Vue
777 */
778 slideDuplicateClass?: string;
779
780 /**
781 * CSS class name of slide which is right after currently active slide
782 *
783 * @default 'swiper-slide-next'
784 *
785 * @note By changing classes you will also need to change Swiper's CSS to reflect changed classes
786 *
787 * @note Not supported in Swiper Angular/React/Svelte/Vue
788 */
789 slideNextClass?: string;
790
791 /**
792 * CSS class name of duplicated slide which represents the slide next to active slide
793 *
794 * @default 'swiper-slide-duplicate-next'
795 *
796 * @note By changing classes you will also need to change Swiper's CSS to reflect changed classes
797 *
798 * @note Not supported in Swiper Angular/React/Svelte/Vue
799 */
800 slideDuplicateNextClass?: string;
801
802 /**
803 * CSS class name of slide which is right before currently active slide
804 *
805 * @default 'swiper-slide-prev'
806 *
807 * @note By changing classes you will also need to change Swiper's CSS to reflect changed classes
808 *
809 * @note Not supported in Swiper Angular/React/Svelte/Vue
810 */
811 slidePrevClass?: string;
812
813 /**
814 * CSS class name of duplicated slide which represents the slide previous to active slide
815 *
816 * @default 'swiper-slide-duplicate-prev'
817 *
818 * @note By changing classes you will also need to change Swiper's CSS to reflect changed classes
819 *
820 * @note Not supported in Swiper Angular/React/Svelte/Vue
821 */
822 slideDuplicatePrevClass?: string;
823
824 /**
825 * CSS class name of blank slide append to fill groups in loop mode when `loopFillGroupWithBlank` is also enabled
826 *
827 * @default 'swiper-slide-invisible-blank'
828 *
829 * @note By changing classes you will also need to change Swiper's CSS to reflect changed classes
830 *
831 * @note Not supported in Swiper Angular/React/Svelte/Vue
832 */
833 slideBlankClass?: string;
834
835 /**
836 * CSS class name of slides' wrapper
837 *
838 * @default 'swiper-wrapper'
839 *
840 * @note By changing classes you will also need to change Swiper's CSS to reflect changed classes
841 *
842 * @note Not supported in Swiper Angular/React/Svelte/Vue
843 *
844 */
845 wrapperClass?: string;
846
847 /**
848 * Object with a11y parameters or boolean `true` to enable with default settings.
849 *
850 * @example
851 * ```js
852 * const swiper = new Swiper('.swiper', {
853 * a11y: {
854 * prevSlideMessage: 'Previous slide',
855 * nextSlideMessage: 'Next slide',
856 * },
857 * });
858 * ```
859 */
860 a11y?: A11yOptions;
861
862 /**
863 * Object with autoplay parameters or boolean `true` to enable with default settings
864 *
865 * @example
866 * ```js
867 * const swiper = new Swiper('.swiper', {
868 * autoplay: {
869 * delay: 5000,
870 * },
871 *});
872 * ```
873 */
874 autoplay?: AutoplayOptions | boolean;
875
876 /**
877 * Object with controller parameters or boolean `true` to enable with default settings
878 *
879 * @example
880 * ```js
881 * const swiper = new Swiper('.swiper', {
882 * controller: {
883 * inverse: true,
884 * },
885 * });
886 * ```
887 */
888 controller?: ControllerOptions;
889
890 /**
891 * Object with Coverflow-effect parameters.
892 *
893 * @example
894 * ```js
895 * const swiper = new Swiper('.swiper', {
896 * effect: 'coverflow',
897 * coverflowEffect: {
898 * rotate: 30,
899 * slideShadows: false,
900 * },
901 * });
902 * ```
903 */
904 coverflowEffect?: CoverflowEffectOptions;
905
906 /**
907 * Object with Cube-effect parameters
908 *
909 * @example
910 * ```js
911 * const swiper = new Swiper('.swiper', {
912 * effect: 'cube',
913 * cubeEffect: {
914 * slideShadows: false,
915 * },
916 * });
917 * ```
918 */
919 cubeEffect?: CubeEffectOptions;
920
921 /**
922 * Object with Fade-effect parameters
923 *
924 * @example
925 * ```js
926 * const swiper = new Swiper('.swiper', {
927 * effect: 'fade',
928 * fadeEffect: {
929 * crossFade: true
930 * },
931 * });
932 * ```
933 */
934 fadeEffect?: FadeEffectOptions;
935
936 /**
937 * Object with Flip-effect parameters
938 *
939 * @example
940 * ```js
941 * const swiper = new Swiper('.swiper', {
942 * effect: 'flip',
943 * flipEffect: {
944 * slideShadows: false,
945 * },
946 * });
947 * ```
948 */
949 flipEffect?: FlipEffectOptions;
950
951 /**
952 * Object with Creative-effect parameters
953 *
954 * @example
955 * ```js
956 * const swiper = new Swiper('.swiper', {
957 * effect: 'creative',
958 * creativeEffect: {
959 * prev: {
960 * // will set `translateZ(-400px)` on previous slides
961 * translate: [0, 0, -400],
962 * },
963 * next: {
964 * // will set `translateX(100%)` on next slides
965 * translate: ['100%', 0, 0],
966 * },
967 * },
968 * });
969 * ```
970 */
971 creativeEffect?: CreativeEffectOptions;
972
973 /**
974 * Object with Cards-effect parameters
975 *
976 * @example
977 * ```js
978 * const swiper = new Swiper('.swiper', {
979 * effect: 'cards',
980 * cardsEffect: {
981 * // ...
982 * },
983 * });
984 * ```
985 */
986 cardsEffect?: CardsEffectOptions;
987
988 /**
989 * Enables hash url navigation to for slides.
990 * Object with hash navigation parameters or boolean `true` to enable with default settings
991 *
992 * @example
993 * ```js
994 * const swiper = new Swiper('.swiper', {
995 * hashNavigation: {
996 * replaceState: true,
997 * },
998 * });
999 * ```
1000 */
1001 hashNavigation?: HashNavigationOptions | boolean;
1002
1003 /**
1004 * Enables history push state where every slide will have its own url. In this parameter you have to specify main slides url like `"slides"` and specify every slide url using `data-history` attribute.
1005 *
1006 * Object with history navigation parameters or boolean `true` to enable with default settings
1007 *
1008 * @example
1009 * ```js
1010 * const swiper = new Swiper('.swiper', {
1011 * history: {
1012 * replaceState: true,
1013 * },
1014 * });
1015 * ```
1016 *
1017 * @example
1018 * ```html
1019 * <!-- will produce "slides/slide1" url in browser history -->
1020 * <div class="swiper-slide" data-history="slide1"></div>
1021 * ```
1022 */
1023 history?: HistoryOptions | boolean;
1024
1025 /**
1026 * Enables navigation through slides using keyboard. Object with keyboard parameters or boolean `true` to enable with default settings
1027 *
1028 * @example
1029 * ```js
1030 * const swiper = new Swiper('.swiper', {
1031 * keyboard: {
1032 * enabled: true,
1033 * onlyInViewport: false,
1034 * },
1035 * });
1036 * ```
1037 */
1038 keyboard?: KeyboardOptions | boolean;
1039
1040 /**
1041 * Enables images lazy loading. Object with lazy loading parameters or boolean `true` to enable with default settings
1042 *
1043 * @example
1044 * ```js
1045 * const swiper = new Swiper('.swiper', {
1046 * lazy: {
1047 * loadPrevNext: true,
1048 * },
1049 * });
1050 * ```
1051 */
1052 lazy?: LazyOptions | boolean;
1053
1054 /**
1055 * Enables navigation through slides using mouse wheel. Object with mousewheel parameters or boolean `true` to enable with default settings
1056 *
1057 * @example
1058 * ```js
1059 * const swiper = new Swiper('.swiper', {
1060 * mousewheel: {
1061 * invert: true,
1062 * },
1063 * });
1064 * ```
1065 */
1066 mousewheel?: MousewheelOptions | boolean;
1067
1068 /**
1069 * Object with navigation parameters or boolean `true` to enable with default settings.
1070 *
1071 * @example
1072 * ```js
1073 * const swiper = new Swiper('.swiper', {
1074 * navigation: {
1075 * nextEl: '.swiper-button-next',
1076 * prevEl: '.swiper-button-prev',
1077 * },
1078 * });
1079 * ```
1080 */
1081 navigation?: NavigationOptions | boolean;
1082
1083 /**
1084 * Object with pagination parameters or boolean `true` to enable with default settings.
1085 *
1086 * @example
1087 * ```js
1088 * const swiper = new Swiper('.swiper', {
1089 * pagination: {
1090 * el: '.swiper-pagination',
1091 * type: 'bullets',
1092 * },
1093 * });
1094 * ```
1095 */
1096 pagination?: PaginationOptions | boolean;
1097
1098 /**
1099 * Object with parallax parameters or boolean `true` to enable with default settings.
1100 *
1101 * @example
1102 * ```js
1103 * const swiper = new Swiper('.swiper', {
1104 * parallax: true,
1105 * });
1106 * ```
1107 */
1108 parallax?: ParallaxOptions | boolean;
1109
1110 /**
1111 * Object with scrollbar parameters or boolean `true` to enable with default settings.
1112 *
1113 * @example
1114 * ```js
1115 * const swiper = new Swiper('.swiper', {
1116 * scrollbar: {
1117 * el: '.swiper-scrollbar',
1118 * draggable: true,
1119 * },
1120 * });
1121 * ```
1122 */
1123 scrollbar?: ScrollbarOptions | boolean;
1124
1125 /**
1126 * Object with thumbs component parameters
1127 *
1128 * @example
1129 * ```js
1130 * const swiper = new Swiper('.swiper', {
1131 * ...
1132 * thumbs: {
1133 * swiper: thumbsSwiper
1134 * }
1135 * });
1136 * ```
1137 */
1138 thumbs?: ThumbsOptions;
1139
1140 /**
1141 * Enables virtual slides functionality. Object with virtual slides parameters or boolean `true` to enable with default settings.
1142 *
1143 * @example
1144 * ```js
1145 * const swiper = new Swiper('.swiper', {
1146 * virtual: {
1147 * slides: ['Slide 1', 'Slide 2', 'Slide 3', 'Slide 4', 'Slide 5'],
1148 * },
1149 * });
1150 * ```
1151 */
1152 virtual?: VirtualOptions | boolean;
1153
1154 /**
1155 * Enables zooming functionality. Object with zoom parameters or boolean `true` to enable with default settings
1156 *
1157 * @example
1158 * ```js
1159 * const swiper = new Swiper('.swiper', {
1160 * zoom: {
1161 * maxRatio: 5,
1162 * },
1163 * });
1164 * ```
1165 */
1166 zoom?: ZoomOptions | boolean;
1167
1168 /**
1169 * Enables free mode functionality. Object with free mode parameters or boolean `true` to enable with default settings.
1170 *
1171 * @example
1172 * ```js
1173 * const swiper = new Swiper('.swiper', {
1174 * freeMode: true,
1175 * });
1176 *
1177 * const swiper = new Swiper('.swiper', {
1178 * freeMode: {
1179 * enabled: true,
1180 * sticky: true,
1181 * },
1182 * });
1183 * ```
1184 */
1185 freeMode?: FreeModeOptions | boolean;
1186
1187 /**
1188 * Object with grid parameters to enable "multirow" slider.
1189 *
1190 * @example
1191 * ```js
1192 * const swiper = new Swiper('.swiper', {
1193 * grid: {
1194 * rows: 2,
1195 * },
1196 * });
1197 * ```
1198 */
1199 grid?: GridOptions;
1200
1201 /**
1202 * !INTERNAL When enabled will emit "_containerClasses" and "_slideClass" events
1203 */
1204 _emitClasses?: boolean;
1205}
1206
\No newline at end of file