1 line
87 KiB
Plaintext
1 line
87 KiB
Plaintext
|
|
{"version":3,"file":"index.mjs","sources":["../../src/carousel/BaseCarousel.vue","../../src/carousel/Carousel.vue","../../src/carousel/Carousel.vue?vue&type=template&id=880aa236&lang.js"],"sourcesContent":["<script>\nimport BaseComponent from '@primevue/core/basecomponent';\nimport CarouselStyle from 'primevue/carousel/style';\n\nexport default {\n name: 'BaseCarousel',\n extends: BaseComponent,\n props: {\n value: null,\n page: {\n type: Number,\n default: 0\n },\n numVisible: {\n type: Number,\n default: 1\n },\n numScroll: {\n type: Number,\n default: 1\n },\n responsiveOptions: Array,\n orientation: {\n type: String,\n default: 'horizontal'\n },\n verticalViewPortHeight: {\n type: String,\n default: '300px'\n },\n contentClass: String,\n containerClass: String,\n indicatorsContentClass: String,\n circular: {\n type: Boolean,\n default: false\n },\n autoplayInterval: {\n type: Number,\n default: 0\n },\n showNavigators: {\n type: Boolean,\n default: true\n },\n showIndicators: {\n type: Boolean,\n default: true\n },\n prevButtonProps: {\n type: Object,\n default: () => {\n return { severity: 'secondary', text: true, rounded: true };\n }\n },\n nextButtonProps: {\n type: Object,\n default: () => {\n return { severity: 'secondary', text: true, rounded: true };\n }\n }\n },\n style: CarouselStyle,\n provide() {\n return {\n $pcCarousel: this,\n $parentInstance: this\n };\n }\n};\n</script>\n","<template>\n <div :class=\"cx('root')\" role=\"region\" v-bind=\"ptmi('root')\">\n <div v-if=\"$slots.header\" :class=\"cx('header')\" v-bind=\"ptm('header')\">\n <slot name=\"header\"></slot>\n </div>\n <div v-if=\"!empty\" :class=\"[cx('contentContainer'), containerClass]\" v-bind=\"ptm('contentContainer')\">\n <div :class=\"[cx('content'), contentClass]\" :aria-live=\"allowAutoplay ? 'polite' : 'off'\" v-bind=\"ptm('content')\">\n <Button\n v-if=\"showNavigators\"\n :class=\"cx('pcPrevButton')\"\n :disabled=\"backwardIsDisabled\"\n :aria-label=\"ariaPrevButtonLabel\"\n :unstyled=\"unstyled\"\n @click=\"navBackward\"\n v-bind=\"prevButtonProps\"\n :pt=\"ptm('pcPrevButton')\"\n data-pc-group-section=\"navigator\"\n >\n <template #icon=\"slotProps\">\n <slot name=\"previcon\">\n <component :is=\"isVertical() ? 'ChevronUpIcon' : 'ChevronLeftIcon'\" :class=\"slotProps.icon\" v-bind=\"ptm('pcPrevButton')['icon']\" />\n </slot>\n </template>\n </Button>\n <div :class=\"cx('viewport')\" :style=\"[{ height: isVertical() ? verticalViewPortHeight : 'auto' }]\" @touchend=\"onTouchEnd\" @touchstart=\"onTouchStart\" @touchmove=\"onTouchMove\" v-bind=\"ptm('viewport')\">\n <div ref=\"itemsContainer\" :class=\"cx('itemList')\" @transitionend=\"onTransitionEnd\" v-bind=\"ptm('itemList')\">\n <template v-if=\"isCircular()\">\n <div\n v-for=\"(item, index) of value.slice(-1 * d_numVisible)\"\n :key=\"index + '_scloned'\"\n :class=\"cx('itemClone', { index, value, totalShiftedItems, d_numVisible })\"\n v-bind=\"ptm('itemClone')\"\n
|