{"ast":null,"code":"import React, { Component } from 'react';\nimport { classNames, UniqueComponentId, DomHandler } from 'primereact/utils';\nimport { Ripple } from 'primereact/ripple';\nimport PrimeReact from 'primereact/api';\n\nfunction _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}\n\nfunction _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return _arrayLikeToArray(arr);\n}\n\nfunction _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && iter[Symbol.iterator] != null || iter[\"@@iterator\"] != null) return Array.from(iter);\n}\n\nfunction _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return _arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);\n}\n\nfunction _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\n\nfunction _toConsumableArray(arr) {\n return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();\n}\n\nfunction _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return self;\n}\n\nfunction _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}\n\nfunction _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nfunction _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n Object.defineProperty(Constructor, \"prototype\", {\n writable: false\n });\n return Constructor;\n}\n\nfunction _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n\n return _setPrototypeOf(o, p);\n}\n\nfunction _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n });\n Object.defineProperty(subClass, \"prototype\", {\n writable: false\n });\n if (superClass) _setPrototypeOf(subClass, superClass);\n}\n\nfunction _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (obj) {\n return typeof obj;\n } : function (obj) {\n return obj && \"function\" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n }, _typeof(obj);\n}\n\nfunction _possibleConstructorReturn(self, call) {\n if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) {\n return call;\n } else if (call !== void 0) {\n throw new TypeError(\"Derived constructors may only return object or undefined\");\n }\n\n return _assertThisInitialized(self);\n}\n\nfunction _getPrototypeOf(o) {\n _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return _getPrototypeOf(o);\n}\n\nfunction _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}\n\nfunction ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n enumerableOnly && (symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n })), keys.push.apply(keys, symbols);\n }\n\n return keys;\n}\n\nfunction _objectSpread(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = null != arguments[i] ? arguments[i] : {};\n i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {\n _defineProperty(target, key, source[key]);\n }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n\n return target;\n}\n\nfunction _createSuper(Derived) {\n var hasNativeReflectConstruct = _isNativeReflectConstruct();\n\n return function _createSuperInternal() {\n var Super = _getPrototypeOf(Derived),\n result;\n\n if (hasNativeReflectConstruct) {\n var NewTarget = _getPrototypeOf(this).constructor;\n\n result = Reflect.construct(Super, arguments, NewTarget);\n } else {\n result = Super.apply(this, arguments);\n }\n\n return _possibleConstructorReturn(this, result);\n };\n}\n\nfunction _isNativeReflectConstruct() {\n if (typeof Reflect === \"undefined\" || !Reflect.construct) return false;\n if (Reflect.construct.sham) return false;\n if (typeof Proxy === \"function\") return true;\n\n try {\n Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));\n return true;\n } catch (e) {\n return false;\n }\n}\n\nvar CarouselItem = /*#__PURE__*/function (_Component) {\n _inherits(CarouselItem, _Component);\n\n var _super = _createSuper(CarouselItem);\n\n function CarouselItem() {\n _classCallCheck(this, CarouselItem);\n\n return _super.apply(this, arguments);\n }\n\n _createClass(CarouselItem, [{\n key: \"render\",\n value: function render() {\n var content = this.props.template(this.props.item);\n var itemClassName = classNames(this.props.className, 'p-carousel-item', {\n 'p-carousel-item-active': this.props.active,\n 'p-carousel-item-start': this.props.start,\n 'p-carousel-item-end': this.props.end\n });\n return /*#__PURE__*/React.createElement(\"div\", {\n className: itemClassName\n }, content);\n }\n }]);\n\n return CarouselItem;\n}(Component);\n\n_defineProperty(CarouselItem, \"defaultProps\", {\n template: null,\n item: null,\n active: false,\n start: false,\n end: false,\n className: null\n});\n\nvar Carousel = /*#__PURE__*/function (_Component2) {\n _inherits(Carousel, _Component2);\n\n var _super2 = _createSuper(Carousel);\n\n function Carousel(props) {\n var _this;\n\n _classCallCheck(this, Carousel);\n\n _this = _super2.call(this, props);\n _this.state = {\n numVisible: props.numVisible,\n numScroll: props.numScroll,\n totalShiftedItems: props.page * props.numScroll * -1\n };\n\n if (!_this.props.onPageChange) {\n _this.state = _objectSpread(_objectSpread({}, _this.state), {}, {\n page: props.page\n });\n }\n\n _this.navBackward = _this.navBackward.bind(_assertThisInitialized(_this));\n _this.navForward = _this.navForward.bind(_assertThisInitialized(_this));\n _this.onTransitionEnd = _this.onTransitionEnd.bind(_assertThisInitialized(_this));\n _this.onTouchStart = _this.onTouchStart.bind(_assertThisInitialized(_this));\n _this.onTouchMove = _this.onTouchMove.bind(_assertThisInitialized(_this));\n _this.onTouchEnd = _this.onTouchEnd.bind(_assertThisInitialized(_this));\n _this.totalIndicators = 0;\n _this.remainingItems = 0;\n _this.allowAutoplay = !!_this.props.autoplayInterval;\n _this.circular = _this.props.circular || _this.allowAutoplay;\n _this.attributeSelector = UniqueComponentId();\n _this.swipeThreshold = 20;\n return _this;\n }\n\n _createClass(Carousel, [{\n key: \"step\",\n value: function step(dir, page) {\n var totalShiftedItems = this.state.totalShiftedItems;\n var isCircular = this.isCircular();\n\n if (page != null) {\n totalShiftedItems = this.state.numScroll * page * -1;\n\n if (isCircular) {\n totalShiftedItems -= this.state.numVisible;\n }\n\n this.isRemainingItemsAdded = false;\n } else {\n totalShiftedItems += this.state.numScroll * dir;\n\n if (this.isRemainingItemsAdded) {\n totalShiftedItems += this.remainingItems - this.state.numScroll * dir;\n this.isRemainingItemsAdded = false;\n }\n\n var originalShiftedItems = isCircular ? totalShiftedItems + this.state.numVisible : totalShiftedItems;\n page = Math.abs(Math.floor(originalShiftedItems / this.state.numScroll));\n }\n\n if (isCircular && this.state.page === this.totalIndicators - 1 && dir === -1) {\n totalShiftedItems = -1 * (this.props.value.length + this.state.numVisible);\n page = 0;\n } else if (isCircular && this.state.page === 0 && dir === 1) {\n totalShiftedItems = 0;\n page = this.totalIndicators - 1;\n } else if (page === this.totalIndicators - 1 && this.remainingItems > 0) {\n totalShiftedItems += this.remainingItems * -1 - this.state.numScroll * dir;\n this.isRemainingItemsAdded = true;\n }\n\n if (this.itemsContainer) {\n DomHandler.removeClass(this.itemsContainer, 'p-items-hidden');\n this.changePosition(totalShiftedItems);\n this.itemsContainer.style.transition = 'transform 500ms ease 0s';\n }\n\n if (this.props.onPageChange) {\n this.setState({\n totalShiftedItems: totalShiftedItems\n });\n this.props.onPageChange({\n page: page\n });\n } else {\n this.setState({\n page: page,\n totalShiftedItems: totalShiftedItems\n });\n }\n }\n }, {\n key: \"calculatePosition\",\n value: function calculatePosition() {\n if (this.itemsContainer && this.responsiveOptions) {\n var windowWidth = window.innerWidth;\n var matchedResponsiveData = {\n numVisible: this.props.numVisible,\n numScroll: this.props.numScroll\n };\n\n for (var i = 0; i < this.responsiveOptions.length; i++) {\n var res = this.responsiveOptions[i];\n\n if (parseInt(res.breakpoint, 10) >= windowWidth) {\n matchedResponsiveData = res;\n }\n }\n\n var state = {};\n\n if (this.state.numScroll !== matchedResponsiveData.numScroll) {\n var page = this.getPage();\n page = Math.floor(page * this.state.numScroll / matchedResponsiveData.numScroll);\n var totalShiftedItems = matchedResponsiveData.numScroll * page * -1;\n\n if (this.isCircular()) {\n totalShiftedItems -= matchedResponsiveData.numVisible;\n }\n\n state = {\n totalShiftedItems: totalShiftedItems,\n numScroll: matchedResponsiveData.numScroll\n };\n\n if (this.props.onPageChange) {\n this.props.onPageChange({\n page: page\n });\n } else {\n state = _objectSpread(_objectSpread({}, state), {}, {\n page: page\n });\n }\n }\n\n if (this.state.numVisible !== matchedResponsiveData.numVisible) {\n state = _objectSpread(_objectSpread({}, state), {}, {\n numVisible: matchedResponsiveData.numVisible\n });\n }\n\n if (Object.keys(state).length) {\n this.setState(state);\n }\n }\n }\n }, {\n key: \"navBackward\",\n value: function navBackward(e, page) {\n if (this.circular || this.getPage() !== 0) {\n this.step(1, page);\n }\n\n this.allowAutoplay = false;\n\n if (e.cancelable) {\n e.preventDefault();\n }\n }\n }, {\n key: \"navForward\",\n value: function navForward(e, page) {\n if (this.circular || this.getPage() < this.totalIndicators - 1) {\n this.step(-1, page);\n }\n\n this.allowAutoplay = false;\n\n if (e.cancelable) {\n e.preventDefault();\n }\n }\n }, {\n key: \"onDotClick\",\n value: function onDotClick(e, page) {\n var currentPage = this.getPage();\n\n if (page > currentPage) {\n this.navForward(e, page);\n } else if (page < currentPage) {\n this.navBackward(e, page);\n }\n }\n }, {\n key: \"onTransitionEnd\",\n value: function onTransitionEnd(e) {\n if (this.itemsContainer && e.propertyName === 'transform') {\n DomHandler.addClass(this.itemsContainer, 'p-items-hidden');\n this.itemsContainer.style.transition = '';\n\n if ((this.state.page === 0 || this.state.page === this.totalIndicators - 1) && this.isCircular()) {\n this.changePosition(this.state.totalShiftedItems);\n }\n }\n }\n }, {\n key: \"onTouchStart\",\n value: function onTouchStart(e) {\n var touchobj = e.changedTouches[0];\n this.startPos = {\n x: touchobj.pageX,\n y: touchobj.pageY\n };\n }\n }, {\n key: \"onTouchMove\",\n value: function onTouchMove(e) {\n if (e.cancelable) {\n e.preventDefault();\n }\n }\n }, {\n key: \"onTouchEnd\",\n value: function onTouchEnd(e) {\n var touchobj = e.changedTouches[0];\n\n if (this.isVertical()) {\n this.changePageOnTouch(e, touchobj.pageY - this.startPos.y);\n } else {\n this.changePageOnTouch(e, touchobj.pageX - this.startPos.x);\n }\n }\n }, {\n key: \"changePageOnTouch\",\n value: function changePageOnTouch(e, diff) {\n if (Math.abs(diff) > this.swipeThreshold) {\n if (diff < 0) {\n // left\n this.navForward(e);\n } else {\n // right\n this.navBackward(e);\n }\n }\n }\n }, {\n key: \"bindDocumentListeners\",\n value: function bindDocumentListeners() {\n var _this2 = this;\n\n if (!this.documentResizeListener) {\n this.documentResizeListener = function () {\n _this2.calculatePosition();\n };\n\n window.addEventListener('resize', this.documentResizeListener);\n }\n }\n }, {\n key: \"unbindDocumentListeners\",\n value: function unbindDocumentListeners() {\n if (this.documentResizeListener) {\n window.removeEventListener('resize', this.documentResizeListener);\n this.documentResizeListener = null;\n }\n }\n }, {\n key: \"isVertical\",\n value: function isVertical() {\n return this.props.orientation === 'vertical';\n }\n }, {\n key: \"isCircular\",\n value: function isCircular() {\n return this.circular && this.props.value.length >= this.state.numVisible;\n }\n }, {\n key: \"getPage\",\n value: function getPage() {\n return this.props.onPageChange ? this.props.page : this.state.page;\n }\n }, {\n key: \"getTotalIndicators\",\n value: function getTotalIndicators() {\n return this.props.value ? Math.ceil((this.props.value.length - this.state.numVisible) / this.state.numScroll) + 1 : 0;\n }\n }, {\n key: \"isAutoplay\",\n value: function isAutoplay() {\n return this.props.autoplayInterval && this.allowAutoplay;\n }\n }, {\n key: \"startAutoplay\",\n value: function startAutoplay() {\n var _this3 = this;\n\n this.interval = setInterval(function () {\n if (_this3.state.page === _this3.totalIndicators - 1) {\n _this3.step(-1, 0);\n } else {\n _this3.step(-1, _this3.state.page + 1);\n }\n }, this.props.autoplayInterval);\n }\n }, {\n key: \"stopAutoplay\",\n value: function stopAutoplay() {\n if (this.interval) {\n clearInterval(this.interval);\n }\n }\n }, {\n key: \"createStyle\",\n value: function createStyle() {\n if (!this.carouselStyle) {\n this.carouselStyle = DomHandler.createInlineStyle(PrimeReact.nonce);\n }\n\n var innerHTML = \"\\n .p-carousel[\".concat(this.attributeSelector, \"] .p-carousel-item {\\n flex: 1 0 \").concat(100 / this.state.numVisible, \"%\\n }\\n \");\n\n if (this.props.responsiveOptions) {\n this.responsiveOptions = _toConsumableArray(this.props.responsiveOptions);\n this.responsiveOptions.sort(function (data1, data2) {\n var value1 = data1.breakpoint;\n var value2 = data2.breakpoint;\n var result = null;\n if (value1 == null && value2 != null) result = -1;else if (value1 != null && value2 == null) result = 1;else if (value1 == null && value2 == null) result = 0;else if (typeof value1 === 'string' && typeof value2 === 'string') result = value1.localeCompare(value2, undefined, {\n numeric: true\n });else result = value1 < value2 ? -1 : value1 > value2 ? 1 : 0;\n return -1 * result;\n });\n\n for (var i = 0; i < this.responsiveOptions.length; i++) {\n var res = this.responsiveOptions[i];\n innerHTML += \"\\n @media screen and (max-width: \".concat(res.breakpoint, \") {\\n .p-carousel[\").concat(this.attributeSelector, \"] .p-carousel-item {\\n flex: 1 0 \").concat(100 / res.numVisible, \"%\\n }\\n }\\n \");\n }\n }\n\n this.carouselStyle.innerHTML = innerHTML;\n }\n }, {\n key: \"changePosition\",\n value: function changePosition(totalShiftedItems) {\n if (this.itemsContainer) {\n this.itemsContainer.style.transform = this.isVertical() ? \"translate3d(0, \".concat(totalShiftedItems * (100 / this.state.numVisible), \"%, 0)\") : \"translate3d(\".concat(totalShiftedItems * (100 / this.state.numVisible), \"%, 0, 0)\");\n }\n }\n }, {\n key: \"componentDidMount\",\n value: function componentDidMount() {\n if (this.container) {\n this.container.setAttribute(this.attributeSelector, '');\n }\n\n this.createStyle();\n this.calculatePosition();\n this.changePosition(this.state.totalShiftedItems);\n\n if (this.props.responsiveOptions) {\n this.bindDocumentListeners();\n }\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate(prevProps, prevState) {\n var isCircular = this.isCircular();\n var stateChanged = false;\n var totalShiftedItems = this.state.totalShiftedItems;\n\n if (this.props.autoplayInterval) {\n this.stopAutoplay();\n }\n\n if (prevState.numScroll !== this.state.numScroll || prevState.numVisible !== this.state.numVisible || this.props.value && prevProps.value && prevProps.value.length !== this.props.value.length) {\n this.remainingItems = (this.props.value.length - this.state.numVisible) % this.state.numScroll;\n var page = this.getPage();\n\n if (this.totalIndicators !== 0 && page >= this.totalIndicators) {\n page = this.totalIndicators - 1;\n\n if (this.props.onPageChange) {\n this.props.onPageChange({\n page: page\n });\n } else {\n this.setState({\n page: page\n });\n }\n\n stateChanged = true;\n }\n\n totalShiftedItems = page * this.state.numScroll * -1;\n\n if (isCircular) {\n totalShiftedItems -= this.state.numVisible;\n }\n\n if (page === this.totalIndicators - 1 && this.remainingItems > 0) {\n totalShiftedItems += -1 * this.remainingItems + this.state.numScroll;\n this.isRemainingItemsAdded = true;\n } else {\n this.isRemainingItemsAdded = false;\n }\n\n if (totalShiftedItems !== this.state.totalShiftedItems) {\n this.setState({\n totalShiftedItems: totalShiftedItems\n });\n stateChanged = true;\n }\n\n this.changePosition(totalShiftedItems);\n }\n\n if (isCircular) {\n if (this.state.page === 0) {\n totalShiftedItems = -1 * this.state.numVisible;\n } else if (totalShiftedItems === 0) {\n totalShiftedItems = -1 * this.props.value.length;\n\n if (this.remainingItems > 0) {\n this.isRemainingItemsAdded = true;\n }\n }\n\n if (totalShiftedItems !== this.state.totalShiftedItems) {\n this.setState({\n totalShiftedItems: totalShiftedItems\n });\n stateChanged = true;\n }\n }\n\n if (prevProps.page !== this.props.page) {\n if (this.props.page > prevProps.page && this.props.page <= this.totalIndicators - 1) {\n this.step(-1, this.props.page);\n } else if (this.props.page < prevProps.page) {\n this.step(1, this.props.page);\n }\n }\n\n if (!stateChanged && this.isAutoplay()) {\n this.startAutoplay();\n }\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n if (this.props.responsiveOptions) {\n this.unbindDocumentListeners();\n }\n\n if (this.props.autoplayInterval) {\n this.stopAutoplay();\n }\n }\n }, {\n key: \"renderItems\",\n value: function renderItems() {\n var _this4 = this;\n\n if (this.props.value && this.props.value.length) {\n var isCircular = this.isCircular();\n var clonedItemsForStarting = null;\n var clonedItemsForFinishing = null;\n\n if (isCircular) {\n var clonedElements = null;\n clonedElements = this.props.value.slice(-1 * this.state.numVisible);\n clonedItemsForStarting = clonedElements.map(function (item, index) {\n var isActive = _this4.state.totalShiftedItems * -1 === _this4.props.value.length + _this4.state.numVisible,\n start = index === 0,\n end = index === clonedElements.length - 1;\n return /*#__PURE__*/React.createElement(CarouselItem, {\n key: index + '_scloned',\n className: \"p-carousel-item-cloned\",\n template: _this4.props.itemTemplate,\n item: item,\n active: isActive,\n start: start,\n end: end\n });\n });\n clonedElements = this.props.value.slice(0, this.state.numVisible);\n clonedItemsForFinishing = clonedElements.map(function (item, index) {\n var isActive = _this4.state.totalShiftedItems === 0,\n start = index === 0,\n end = index === clonedElements.length - 1;\n return /*#__PURE__*/React.createElement(CarouselItem, {\n key: index + '_fcloned',\n className: \"p-carousel-item-cloned\",\n template: _this4.props.itemTemplate,\n item: item,\n active: isActive,\n start: start,\n end: end\n });\n });\n }\n\n var items = this.props.value.map(function (item, index) {\n var firstIndex = isCircular ? -1 * (_this4.state.totalShiftedItems + _this4.state.numVisible) : _this4.state.totalShiftedItems * -1,\n lastIndex = firstIndex + _this4.state.numVisible - 1,\n isActive = firstIndex <= index && lastIndex >= index,\n start = firstIndex === index,\n end = lastIndex === index;\n return /*#__PURE__*/React.createElement(CarouselItem, {\n key: index,\n template: _this4.props.itemTemplate,\n item: item,\n active: isActive,\n start: start,\n end: end\n });\n });\n return /*#__PURE__*/React.createElement(React.Fragment, null, clonedItemsForStarting, items, clonedItemsForFinishing);\n }\n }\n }, {\n key: \"renderHeader\",\n value: function renderHeader() {\n if (this.props.header) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: \"p-carousel-header\"\n }, this.props.header);\n }\n\n return null;\n }\n }, {\n key: \"renderFooter\",\n value: function renderFooter() {\n if (this.props.footer) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: \"p-carousel-footer\"\n }, this.props.footer);\n }\n\n return null;\n }\n }, {\n key: \"renderContent\",\n value: function renderContent() {\n var _this5 = this;\n\n var items = this.renderItems();\n var height = this.isVertical() ? this.props.verticalViewPortHeight : 'auto';\n var backwardNavigator = this.renderBackwardNavigator();\n var forwardNavigator = this.renderForwardNavigator();\n var containerClassName = classNames('p-carousel-container', this.props.containerClassName);\n return /*#__PURE__*/React.createElement(\"div\", {\n className: containerClassName\n }, backwardNavigator, /*#__PURE__*/React.createElement(\"div\", {\n className: \"p-carousel-items-content\",\n style: {\n 'height': height\n },\n onTouchStart: this.onTouchStart,\n onTouchMove: this.onTouchMove,\n onTouchEnd: this.onTouchEnd\n }, /*#__PURE__*/React.createElement(\"div\", {\n ref: function ref(el) {\n return _this5.itemsContainer = el;\n },\n className: \"p-carousel-items-container\",\n onTransitionEnd: this.onTransitionEnd\n }, items)), forwardNavigator);\n }\n }, {\n key: \"renderBackwardNavigator\",\n value: function renderBackwardNavigator() {\n var isDisabled = (!this.circular || this.props.value && this.props.value.length < this.state.numVisible) && this.getPage() === 0;\n var buttonClassName = classNames('p-carousel-prev p-link', {\n 'p-disabled': isDisabled\n }),\n iconClassName = classNames('p-carousel-prev-icon pi', {\n 'pi-chevron-left': !this.isVertical(),\n 'pi-chevron-up': this.isVertical()\n });\n return /*#__PURE__*/React.createElement(\"button\", {\n type: \"button\",\n className: buttonClassName,\n onClick: this.navBackward,\n disabled: isDisabled\n }, /*#__PURE__*/React.createElement(\"span\", {\n className: iconClassName\n }), /*#__PURE__*/React.createElement(Ripple, null));\n }\n }, {\n key: \"renderForwardNavigator\",\n value: function renderForwardNavigator() {\n var isDisabled = (!this.circular || this.props.value && this.props.value.length < this.state.numVisible) && (this.getPage() === this.totalIndicators - 1 || this.totalIndicators === 0);\n var buttonClassName = classNames('p-carousel-next p-link', {\n 'p-disabled': isDisabled\n }),\n iconClassName = classNames('p-carousel-next-icon pi', {\n 'pi-chevron-right': !this.isVertical(),\n 'pi-chevron-down': this.isVertical()\n });\n return /*#__PURE__*/React.createElement(\"button\", {\n type: \"button\",\n className: buttonClassName,\n onClick: this.navForward,\n disabled: isDisabled\n }, /*#__PURE__*/React.createElement(\"span\", {\n className: iconClassName\n }), /*#__PURE__*/React.createElement(Ripple, null));\n }\n }, {\n key: \"renderIndicator\",\n value: function renderIndicator(index) {\n var _this6 = this;\n\n var isActive = this.getPage() === index,\n indicatorItemClassName = classNames('p-carousel-indicator', {\n 'p-highlight': isActive\n });\n return /*#__PURE__*/React.createElement(\"li\", {\n className: indicatorItemClassName,\n key: 'p-carousel-indicator-' + index\n }, /*#__PURE__*/React.createElement(\"button\", {\n type: \"button\",\n className: \"p-link\",\n onClick: function onClick(e) {\n return _this6.onDotClick(e, index);\n }\n }, /*#__PURE__*/React.createElement(Ripple, null)));\n }\n }, {\n key: \"renderIndicators\",\n value: function renderIndicators() {\n var indicatorsContentClassName = classNames('p-carousel-indicators p-reset', this.props.indicatorsContentClassName);\n var indicators = [];\n\n for (var i = 0; i < this.totalIndicators; i++) {\n indicators.push(this.renderIndicator(i));\n }\n\n return /*#__PURE__*/React.createElement(\"ul\", {\n className: indicatorsContentClassName\n }, indicators);\n }\n }, {\n key: \"render\",\n value: function render() {\n var _this7 = this;\n\n var className = classNames('p-carousel p-component', {\n 'p-carousel-vertical': this.isVertical(),\n 'p-carousel-horizontal': !this.isVertical()\n }, this.props.className);\n var contentClassName = classNames('p-carousel-content', this.props.contentClassName);\n this.totalIndicators = this.getTotalIndicators();\n var content = this.renderContent();\n var indicators = this.renderIndicators();\n var header = this.renderHeader();\n var footer = this.renderFooter();\n return /*#__PURE__*/React.createElement(\"div\", {\n ref: function ref(el) {\n return _this7.container = el;\n },\n id: this.props.id,\n className: className,\n style: this.props.style\n }, header, /*#__PURE__*/React.createElement(\"div\", {\n className: contentClassName\n }, content, indicators), footer);\n }\n }]);\n\n return Carousel;\n}(Component);\n\n_defineProperty(Carousel, \"defaultProps\", {\n id: null,\n value: null,\n page: 0,\n header: null,\n footer: null,\n style: null,\n className: null,\n itemTemplate: null,\n circular: false,\n autoplayInterval: 0,\n numVisible: 1,\n numScroll: 1,\n responsiveOptions: null,\n orientation: \"horizontal\",\n verticalViewPortHeight: \"300px\",\n contentClassName: null,\n containerClassName: null,\n indicatorsContentClassName: null,\n onPageChange: null\n});\n\nexport { Carousel };","map":{"version":3,"names":["React","Component","classNames","UniqueComponentId","DomHandler","Ripple","PrimeReact","_arrayLikeToArray","arr","len","length","i","arr2","Array","_arrayWithoutHoles","isArray","_iterableToArray","iter","Symbol","iterator","from","_unsupportedIterableToArray","o","minLen","n","Object","prototype","toString","call","slice","constructor","name","test","_nonIterableSpread","TypeError","_toConsumableArray","_assertThisInitialized","self","ReferenceError","_classCallCheck","instance","Constructor","_defineProperties","target","props","descriptor","enumerable","configurable","writable","defineProperty","key","_createClass","protoProps","staticProps","_setPrototypeOf","p","setPrototypeOf","__proto__","_inherits","subClass","superClass","create","value","_typeof","obj","_possibleConstructorReturn","_getPrototypeOf","getPrototypeOf","_defineProperty","ownKeys","object","enumerableOnly","keys","getOwnPropertySymbols","symbols","filter","sym","getOwnPropertyDescriptor","push","apply","_objectSpread","arguments","source","forEach","getOwnPropertyDescriptors","defineProperties","_createSuper","Derived","hasNativeReflectConstruct","_isNativeReflectConstruct","_createSuperInternal","Super","result","NewTarget","Reflect","construct","sham","Proxy","Boolean","valueOf","e","CarouselItem","_Component","_super","render","content","template","item","itemClassName","className","active","start","end","createElement","Carousel","_Component2","_super2","_this","state","numVisible","numScroll","totalShiftedItems","page","onPageChange","navBackward","bind","navForward","onTransitionEnd","onTouchStart","onTouchMove","onTouchEnd","totalIndicators","remainingItems","allowAutoplay","autoplayInterval","circular","attributeSelector","swipeThreshold","step","dir","isCircular","isRemainingItemsAdded","originalShiftedItems","Math","abs","floor","itemsContainer","removeClass","changePosition","style","transition","setState","calculatePosition","responsiveOptions","windowWidth","window","innerWidth","matchedResponsiveData","res","parseInt","breakpoint","getPage","cancelable","preventDefault","onDotClick","currentPage","propertyName","addClass","touchobj","changedTouches","startPos","x","pageX","y","pageY","isVertical","changePageOnTouch","diff","bindDocumentListeners","_this2","documentResizeListener","addEventListener","unbindDocumentListeners","removeEventListener","orientation","getTotalIndicators","ceil","isAutoplay","startAutoplay","_this3","interval","setInterval","stopAutoplay","clearInterval","createStyle","carouselStyle","createInlineStyle","nonce","innerHTML","concat","sort","data1","data2","value1","value2","localeCompare","undefined","numeric","transform","componentDidMount","container","setAttribute","componentDidUpdate","prevProps","prevState","stateChanged","componentWillUnmount","renderItems","_this4","clonedItemsForStarting","clonedItemsForFinishing","clonedElements","map","index","isActive","itemTemplate","items","firstIndex","lastIndex","Fragment","renderHeader","header","renderFooter","footer","renderContent","_this5","height","verticalViewPortHeight","backwardNavigator","renderBackwardNavigator","forwardNavigator","renderForwardNavigator","containerClassName","ref","el","isDisabled","buttonClassName","iconClassName","type","onClick","disabled","renderIndicator","_this6","indicatorItemClassName","renderIndicators","indicatorsContentClassName","indicators","_this7","contentClassName","id"],"sources":["/Users/paolasanchez/Desktop/Pry4/Katoikia/katoikia-app/web-ui/sakai-react/node_modules/primereact/carousel/carousel.esm.js"],"sourcesContent":["import React, { Component } from 'react';\nimport { classNames, UniqueComponentId, DomHandler } from 'primereact/utils';\nimport { Ripple } from 'primereact/ripple';\nimport PrimeReact from 'primereact/api';\n\nfunction _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}\n\nfunction _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return _arrayLikeToArray(arr);\n}\n\nfunction _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && iter[Symbol.iterator] != null || iter[\"@@iterator\"] != null) return Array.from(iter);\n}\n\nfunction _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return _arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);\n}\n\nfunction _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\n\nfunction _toConsumableArray(arr) {\n return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();\n}\n\nfunction _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return self;\n}\n\nfunction _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}\n\nfunction _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nfunction _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n Object.defineProperty(Constructor, \"prototype\", {\n writable: false\n });\n return Constructor;\n}\n\nfunction _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n\n return _setPrototypeOf(o, p);\n}\n\nfunction _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n });\n Object.defineProperty(subClass, \"prototype\", {\n writable: false\n });\n if (superClass) _setPrototypeOf(subClass, superClass);\n}\n\nfunction _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (obj) {\n return typeof obj;\n } : function (obj) {\n return obj && \"function\" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n }, _typeof(obj);\n}\n\nfunction _possibleConstructorReturn(self, call) {\n if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) {\n return call;\n } else if (call !== void 0) {\n throw new TypeError(\"Derived constructors may only return object or undefined\");\n }\n\n return _assertThisInitialized(self);\n}\n\nfunction _getPrototypeOf(o) {\n _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return _getPrototypeOf(o);\n}\n\nfunction _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }\n\nvar CarouselItem = /*#__PURE__*/function (_Component) {\n _inherits(CarouselItem, _Component);\n\n var _super = _createSuper(CarouselItem);\n\n function CarouselItem() {\n _classCallCheck(this, CarouselItem);\n\n return _super.apply(this, arguments);\n }\n\n _createClass(CarouselItem, [{\n key: \"render\",\n value: function render() {\n var content = this.props.template(this.props.item);\n var itemClassName = classNames(this.props.className, 'p-carousel-item', {\n 'p-carousel-item-active': this.props.active,\n 'p-carousel-item-start': this.props.start,\n 'p-carousel-item-end': this.props.end\n });\n return /*#__PURE__*/React.createElement(\"div\", {\n className: itemClassName\n }, content);\n }\n }]);\n\n return CarouselItem;\n}(Component);\n\n_defineProperty(CarouselItem, \"defaultProps\", {\n template: null,\n item: null,\n active: false,\n start: false,\n end: false,\n className: null\n});\n\nvar Carousel = /*#__PURE__*/function (_Component2) {\n _inherits(Carousel, _Component2);\n\n var _super2 = _createSuper(Carousel);\n\n function Carousel(props) {\n var _this;\n\n _classCallCheck(this, Carousel);\n\n _this = _super2.call(this, props);\n _this.state = {\n numVisible: props.numVisible,\n numScroll: props.numScroll,\n totalShiftedItems: props.page * props.numScroll * -1\n };\n\n if (!_this.props.onPageChange) {\n _this.state = _objectSpread(_objectSpread({}, _this.state), {}, {\n page: props.page\n });\n }\n\n _this.navBackward = _this.navBackward.bind(_assertThisInitialized(_this));\n _this.navForward = _this.navForward.bind(_assertThisInitialized(_this));\n _this.onTransitionEnd = _this.onTransitionEnd.bind(_assertThisInitialized(_this));\n _this.onTouchStart = _this.onTouchStart.bind(_assertThisInitialized(_this));\n _this.onTouchMove = _this.onTouchMove.bind(_assertThisInitialized(_this));\n _this.onTouchEnd = _this.onTouchEnd.bind(_assertThisInitialized(_this));\n _this.totalIndicators = 0;\n _this.remainingItems = 0;\n _this.allowAutoplay = !!_this.props.autoplayInterval;\n _this.circular = _this.props.circular || _this.allowAutoplay;\n _this.attributeSelector = UniqueComponentId();\n _this.swipeThreshold = 20;\n return _this;\n }\n\n _createClass(Carousel, [{\n key: \"step\",\n value: function step(dir, page) {\n var totalShiftedItems = this.state.totalShiftedItems;\n var isCircular = this.isCircular();\n\n if (page != null) {\n totalShiftedItems = this.state.numScroll * page * -1;\n\n if (isCircular) {\n totalShiftedItems -= this.state.numVisible;\n }\n\n this.isRemainingItemsAdded = false;\n } else {\n totalShiftedItems += this.state.numScroll * dir;\n\n if (this.isRemainingItemsAdded) {\n totalShiftedItems += this.remainingItems - this.state.numScroll * dir;\n this.isRemainingItemsAdded = false;\n }\n\n var originalShiftedItems = isCircular ? totalShiftedItems + this.state.numVisible : totalShiftedItems;\n page = Math.abs(Math.floor(originalShiftedItems / this.state.numScroll));\n }\n\n if (isCircular && this.state.page === this.totalIndicators - 1 && dir === -1) {\n totalShiftedItems = -1 * (this.props.value.length + this.state.numVisible);\n page = 0;\n } else if (isCircular && this.state.page === 0 && dir === 1) {\n totalShiftedItems = 0;\n page = this.totalIndicators - 1;\n } else if (page === this.totalIndicators - 1 && this.remainingItems > 0) {\n totalShiftedItems += this.remainingItems * -1 - this.state.numScroll * dir;\n this.isRemainingItemsAdded = true;\n }\n\n if (this.itemsContainer) {\n DomHandler.removeClass(this.itemsContainer, 'p-items-hidden');\n this.changePosition(totalShiftedItems);\n this.itemsContainer.style.transition = 'transform 500ms ease 0s';\n }\n\n if (this.props.onPageChange) {\n this.setState({\n totalShiftedItems: totalShiftedItems\n });\n this.props.onPageChange({\n page: page\n });\n } else {\n this.setState({\n page: page,\n totalShiftedItems: totalShiftedItems\n });\n }\n }\n }, {\n key: \"calculatePosition\",\n value: function calculatePosition() {\n if (this.itemsContainer && this.responsiveOptions) {\n var windowWidth = window.innerWidth;\n var matchedResponsiveData = {\n numVisible: this.props.numVisible,\n numScroll: this.props.numScroll\n };\n\n for (var i = 0; i < this.responsiveOptions.length; i++) {\n var res = this.responsiveOptions[i];\n\n if (parseInt(res.breakpoint, 10) >= windowWidth) {\n matchedResponsiveData = res;\n }\n }\n\n var state = {};\n\n if (this.state.numScroll !== matchedResponsiveData.numScroll) {\n var page = this.getPage();\n page = Math.floor(page * this.state.numScroll / matchedResponsiveData.numScroll);\n var totalShiftedItems = matchedResponsiveData.numScroll * page * -1;\n\n if (this.isCircular()) {\n totalShiftedItems -= matchedResponsiveData.numVisible;\n }\n\n state = {\n totalShiftedItems: totalShiftedItems,\n numScroll: matchedResponsiveData.numScroll\n };\n\n if (this.props.onPageChange) {\n this.props.onPageChange({\n page: page\n });\n } else {\n state = _objectSpread(_objectSpread({}, state), {}, {\n page: page\n });\n }\n }\n\n if (this.state.numVisible !== matchedResponsiveData.numVisible) {\n state = _objectSpread(_objectSpread({}, state), {}, {\n numVisible: matchedResponsiveData.numVisible\n });\n }\n\n if (Object.keys(state).length) {\n this.setState(state);\n }\n }\n }\n }, {\n key: \"navBackward\",\n value: function navBackward(e, page) {\n if (this.circular || this.getPage() !== 0) {\n this.step(1, page);\n }\n\n this.allowAutoplay = false;\n\n if (e.cancelable) {\n e.preventDefault();\n }\n }\n }, {\n key: \"navForward\",\n value: function navForward(e, page) {\n if (this.circular || this.getPage() < this.totalIndicators - 1) {\n this.step(-1, page);\n }\n\n this.allowAutoplay = false;\n\n if (e.cancelable) {\n e.preventDefault();\n }\n }\n }, {\n key: \"onDotClick\",\n value: function onDotClick(e, page) {\n var currentPage = this.getPage();\n\n if (page > currentPage) {\n this.navForward(e, page);\n } else if (page < currentPage) {\n this.navBackward(e, page);\n }\n }\n }, {\n key: \"onTransitionEnd\",\n value: function onTransitionEnd(e) {\n if (this.itemsContainer && e.propertyName === 'transform') {\n DomHandler.addClass(this.itemsContainer, 'p-items-hidden');\n this.itemsContainer.style.transition = '';\n\n if ((this.state.page === 0 || this.state.page === this.totalIndicators - 1) && this.isCircular()) {\n this.changePosition(this.state.totalShiftedItems);\n }\n }\n }\n }, {\n key: \"onTouchStart\",\n value: function onTouchStart(e) {\n var touchobj = e.changedTouches[0];\n this.startPos = {\n x: touchobj.pageX,\n y: touchobj.pageY\n };\n }\n }, {\n key: \"onTouchMove\",\n value: function onTouchMove(e) {\n if (e.cancelable) {\n e.preventDefault();\n }\n }\n }, {\n key: \"onTouchEnd\",\n value: function onTouchEnd(e) {\n var touchobj = e.changedTouches[0];\n\n if (this.isVertical()) {\n this.changePageOnTouch(e, touchobj.pageY - this.startPos.y);\n } else {\n this.changePageOnTouch(e, touchobj.pageX - this.startPos.x);\n }\n }\n }, {\n key: \"changePageOnTouch\",\n value: function changePageOnTouch(e, diff) {\n if (Math.abs(diff) > this.swipeThreshold) {\n if (diff < 0) {\n // left\n this.navForward(e);\n } else {\n // right\n this.navBackward(e);\n }\n }\n }\n }, {\n key: \"bindDocumentListeners\",\n value: function bindDocumentListeners() {\n var _this2 = this;\n\n if (!this.documentResizeListener) {\n this.documentResizeListener = function () {\n _this2.calculatePosition();\n };\n\n window.addEventListener('resize', this.documentResizeListener);\n }\n }\n }, {\n key: \"unbindDocumentListeners\",\n value: function unbindDocumentListeners() {\n if (this.documentResizeListener) {\n window.removeEventListener('resize', this.documentResizeListener);\n this.documentResizeListener = null;\n }\n }\n }, {\n key: \"isVertical\",\n value: function isVertical() {\n return this.props.orientation === 'vertical';\n }\n }, {\n key: \"isCircular\",\n value: function isCircular() {\n return this.circular && this.props.value.length >= this.state.numVisible;\n }\n }, {\n key: \"getPage\",\n value: function getPage() {\n return this.props.onPageChange ? this.props.page : this.state.page;\n }\n }, {\n key: \"getTotalIndicators\",\n value: function getTotalIndicators() {\n return this.props.value ? Math.ceil((this.props.value.length - this.state.numVisible) / this.state.numScroll) + 1 : 0;\n }\n }, {\n key: \"isAutoplay\",\n value: function isAutoplay() {\n return this.props.autoplayInterval && this.allowAutoplay;\n }\n }, {\n key: \"startAutoplay\",\n value: function startAutoplay() {\n var _this3 = this;\n\n this.interval = setInterval(function () {\n if (_this3.state.page === _this3.totalIndicators - 1) {\n _this3.step(-1, 0);\n } else {\n _this3.step(-1, _this3.state.page + 1);\n }\n }, this.props.autoplayInterval);\n }\n }, {\n key: \"stopAutoplay\",\n value: function stopAutoplay() {\n if (this.interval) {\n clearInterval(this.interval);\n }\n }\n }, {\n key: \"createStyle\",\n value: function createStyle() {\n if (!this.carouselStyle) {\n this.carouselStyle = DomHandler.createInlineStyle(PrimeReact.nonce);\n }\n\n var innerHTML = \"\\n .p-carousel[\".concat(this.attributeSelector, \"] .p-carousel-item {\\n flex: 1 0 \").concat(100 / this.state.numVisible, \"%\\n }\\n \");\n\n if (this.props.responsiveOptions) {\n this.responsiveOptions = _toConsumableArray(this.props.responsiveOptions);\n this.responsiveOptions.sort(function (data1, data2) {\n var value1 = data1.breakpoint;\n var value2 = data2.breakpoint;\n var result = null;\n if (value1 == null && value2 != null) result = -1;else if (value1 != null && value2 == null) result = 1;else if (value1 == null && value2 == null) result = 0;else if (typeof value1 === 'string' && typeof value2 === 'string') result = value1.localeCompare(value2, undefined, {\n numeric: true\n });else result = value1 < value2 ? -1 : value1 > value2 ? 1 : 0;\n return -1 * result;\n });\n\n for (var i = 0; i < this.responsiveOptions.length; i++) {\n var res = this.responsiveOptions[i];\n innerHTML += \"\\n @media screen and (max-width: \".concat(res.breakpoint, \") {\\n .p-carousel[\").concat(this.attributeSelector, \"] .p-carousel-item {\\n flex: 1 0 \").concat(100 / res.numVisible, \"%\\n }\\n }\\n \");\n }\n }\n\n this.carouselStyle.innerHTML = innerHTML;\n }\n }, {\n key: \"changePosition\",\n value: function changePosition(totalShiftedItems) {\n if (this.itemsContainer) {\n this.itemsContainer.style.transform = this.isVertical() ? \"translate3d(0, \".concat(totalShiftedItems * (100 / this.state.numVisible), \"%, 0)\") : \"translate3d(\".concat(totalShiftedItems * (100 / this.state.numVisible), \"%, 0, 0)\");\n }\n }\n }, {\n key: \"componentDidMount\",\n value: function componentDidMount() {\n if (this.container) {\n this.container.setAttribute(this.attributeSelector, '');\n }\n\n this.createStyle();\n this.calculatePosition();\n this.changePosition(this.state.totalShiftedItems);\n\n if (this.props.responsiveOptions) {\n this.bindDocumentListeners();\n }\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate(prevProps, prevState) {\n var isCircular = this.isCircular();\n var stateChanged = false;\n var totalShiftedItems = this.state.totalShiftedItems;\n\n if (this.props.autoplayInterval) {\n this.stopAutoplay();\n }\n\n if (prevState.numScroll !== this.state.numScroll || prevState.numVisible !== this.state.numVisible || this.props.value && prevProps.value && prevProps.value.length !== this.props.value.length) {\n this.remainingItems = (this.props.value.length - this.state.numVisible) % this.state.numScroll;\n var page = this.getPage();\n\n if (this.totalIndicators !== 0 && page >= this.totalIndicators) {\n page = this.totalIndicators - 1;\n\n if (this.props.onPageChange) {\n this.props.onPageChange({\n page: page\n });\n } else {\n this.setState({\n page: page\n });\n }\n\n stateChanged = true;\n }\n\n totalShiftedItems = page * this.state.numScroll * -1;\n\n if (isCircular) {\n totalShiftedItems -= this.state.numVisible;\n }\n\n if (page === this.totalIndicators - 1 && this.remainingItems > 0) {\n totalShiftedItems += -1 * this.remainingItems + this.state.numScroll;\n this.isRemainingItemsAdded = true;\n } else {\n this.isRemainingItemsAdded = false;\n }\n\n if (totalShiftedItems !== this.state.totalShiftedItems) {\n this.setState({\n totalShiftedItems: totalShiftedItems\n });\n stateChanged = true;\n }\n\n this.changePosition(totalShiftedItems);\n }\n\n if (isCircular) {\n if (this.state.page === 0) {\n totalShiftedItems = -1 * this.state.numVisible;\n } else if (totalShiftedItems === 0) {\n totalShiftedItems = -1 * this.props.value.length;\n\n if (this.remainingItems > 0) {\n this.isRemainingItemsAdded = true;\n }\n }\n\n if (totalShiftedItems !== this.state.totalShiftedItems) {\n this.setState({\n totalShiftedItems: totalShiftedItems\n });\n stateChanged = true;\n }\n }\n\n if (prevProps.page !== this.props.page) {\n if (this.props.page > prevProps.page && this.props.page <= this.totalIndicators - 1) {\n this.step(-1, this.props.page);\n } else if (this.props.page < prevProps.page) {\n this.step(1, this.props.page);\n }\n }\n\n if (!stateChanged && this.isAutoplay()) {\n this.startAutoplay();\n }\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n if (this.props.responsiveOptions) {\n this.unbindDocumentListeners();\n }\n\n if (this.props.autoplayInterval) {\n this.stopAutoplay();\n }\n }\n }, {\n key: \"renderItems\",\n value: function renderItems() {\n var _this4 = this;\n\n if (this.props.value && this.props.value.length) {\n var isCircular = this.isCircular();\n var clonedItemsForStarting = null;\n var clonedItemsForFinishing = null;\n\n if (isCircular) {\n var clonedElements = null;\n clonedElements = this.props.value.slice(-1 * this.state.numVisible);\n clonedItemsForStarting = clonedElements.map(function (item, index) {\n var isActive = _this4.state.totalShiftedItems * -1 === _this4.props.value.length + _this4.state.numVisible,\n start = index === 0,\n end = index === clonedElements.length - 1;\n return /*#__PURE__*/React.createElement(CarouselItem, {\n key: index + '_scloned',\n className: \"p-carousel-item-cloned\",\n template: _this4.props.itemTemplate,\n item: item,\n active: isActive,\n start: start,\n end: end\n });\n });\n clonedElements = this.props.value.slice(0, this.state.numVisible);\n clonedItemsForFinishing = clonedElements.map(function (item, index) {\n var isActive = _this4.state.totalShiftedItems === 0,\n start = index === 0,\n end = index === clonedElements.length - 1;\n return /*#__PURE__*/React.createElement(CarouselItem, {\n key: index + '_fcloned',\n className: \"p-carousel-item-cloned\",\n template: _this4.props.itemTemplate,\n item: item,\n active: isActive,\n start: start,\n end: end\n });\n });\n }\n\n var items = this.props.value.map(function (item, index) {\n var firstIndex = isCircular ? -1 * (_this4.state.totalShiftedItems + _this4.state.numVisible) : _this4.state.totalShiftedItems * -1,\n lastIndex = firstIndex + _this4.state.numVisible - 1,\n isActive = firstIndex <= index && lastIndex >= index,\n start = firstIndex === index,\n end = lastIndex === index;\n return /*#__PURE__*/React.createElement(CarouselItem, {\n key: index,\n template: _this4.props.itemTemplate,\n item: item,\n active: isActive,\n start: start,\n end: end\n });\n });\n return /*#__PURE__*/React.createElement(React.Fragment, null, clonedItemsForStarting, items, clonedItemsForFinishing);\n }\n }\n }, {\n key: \"renderHeader\",\n value: function renderHeader() {\n if (this.props.header) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: \"p-carousel-header\"\n }, this.props.header);\n }\n\n return null;\n }\n }, {\n key: \"renderFooter\",\n value: function renderFooter() {\n if (this.props.footer) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: \"p-carousel-footer\"\n }, this.props.footer);\n }\n\n return null;\n }\n }, {\n key: \"renderContent\",\n value: function renderContent() {\n var _this5 = this;\n\n var items = this.renderItems();\n var height = this.isVertical() ? this.props.verticalViewPortHeight : 'auto';\n var backwardNavigator = this.renderBackwardNavigator();\n var forwardNavigator = this.renderForwardNavigator();\n var containerClassName = classNames('p-carousel-container', this.props.containerClassName);\n return /*#__PURE__*/React.createElement(\"div\", {\n className: containerClassName\n }, backwardNavigator, /*#__PURE__*/React.createElement(\"div\", {\n className: \"p-carousel-items-content\",\n style: {\n 'height': height\n },\n onTouchStart: this.onTouchStart,\n onTouchMove: this.onTouchMove,\n onTouchEnd: this.onTouchEnd\n }, /*#__PURE__*/React.createElement(\"div\", {\n ref: function ref(el) {\n return _this5.itemsContainer = el;\n },\n className: \"p-carousel-items-container\",\n onTransitionEnd: this.onTransitionEnd\n }, items)), forwardNavigator);\n }\n }, {\n key: \"renderBackwardNavigator\",\n value: function renderBackwardNavigator() {\n var isDisabled = (!this.circular || this.props.value && this.props.value.length < this.state.numVisible) && this.getPage() === 0;\n var buttonClassName = classNames('p-carousel-prev p-link', {\n 'p-disabled': isDisabled\n }),\n iconClassName = classNames('p-carousel-prev-icon pi', {\n 'pi-chevron-left': !this.isVertical(),\n 'pi-chevron-up': this.isVertical()\n });\n return /*#__PURE__*/React.createElement(\"button\", {\n type: \"button\",\n className: buttonClassName,\n onClick: this.navBackward,\n disabled: isDisabled\n }, /*#__PURE__*/React.createElement(\"span\", {\n className: iconClassName\n }), /*#__PURE__*/React.createElement(Ripple, null));\n }\n }, {\n key: \"renderForwardNavigator\",\n value: function renderForwardNavigator() {\n var isDisabled = (!this.circular || this.props.value && this.props.value.length < this.state.numVisible) && (this.getPage() === this.totalIndicators - 1 || this.totalIndicators === 0);\n var buttonClassName = classNames('p-carousel-next p-link', {\n 'p-disabled': isDisabled\n }),\n iconClassName = classNames('p-carousel-next-icon pi', {\n 'pi-chevron-right': !this.isVertical(),\n 'pi-chevron-down': this.isVertical()\n });\n return /*#__PURE__*/React.createElement(\"button\", {\n type: \"button\",\n className: buttonClassName,\n onClick: this.navForward,\n disabled: isDisabled\n }, /*#__PURE__*/React.createElement(\"span\", {\n className: iconClassName\n }), /*#__PURE__*/React.createElement(Ripple, null));\n }\n }, {\n key: \"renderIndicator\",\n value: function renderIndicator(index) {\n var _this6 = this;\n\n var isActive = this.getPage() === index,\n indicatorItemClassName = classNames('p-carousel-indicator', {\n 'p-highlight': isActive\n });\n return /*#__PURE__*/React.createElement(\"li\", {\n className: indicatorItemClassName,\n key: 'p-carousel-indicator-' + index\n }, /*#__PURE__*/React.createElement(\"button\", {\n type: \"button\",\n className: \"p-link\",\n onClick: function onClick(e) {\n return _this6.onDotClick(e, index);\n }\n }, /*#__PURE__*/React.createElement(Ripple, null)));\n }\n }, {\n key: \"renderIndicators\",\n value: function renderIndicators() {\n var indicatorsContentClassName = classNames('p-carousel-indicators p-reset', this.props.indicatorsContentClassName);\n var indicators = [];\n\n for (var i = 0; i < this.totalIndicators; i++) {\n indicators.push(this.renderIndicator(i));\n }\n\n return /*#__PURE__*/React.createElement(\"ul\", {\n className: indicatorsContentClassName\n }, indicators);\n }\n }, {\n key: \"render\",\n value: function render() {\n var _this7 = this;\n\n var className = classNames('p-carousel p-component', {\n 'p-carousel-vertical': this.isVertical(),\n 'p-carousel-horizontal': !this.isVertical()\n }, this.props.className);\n var contentClassName = classNames('p-carousel-content', this.props.contentClassName);\n this.totalIndicators = this.getTotalIndicators();\n var content = this.renderContent();\n var indicators = this.renderIndicators();\n var header = this.renderHeader();\n var footer = this.renderFooter();\n return /*#__PURE__*/React.createElement(\"div\", {\n ref: function ref(el) {\n return _this7.container = el;\n },\n id: this.props.id,\n className: className,\n style: this.props.style\n }, header, /*#__PURE__*/React.createElement(\"div\", {\n className: contentClassName\n }, content, indicators), footer);\n }\n }]);\n\n return Carousel;\n}(Component);\n\n_defineProperty(Carousel, \"defaultProps\", {\n id: null,\n value: null,\n page: 0,\n header: null,\n footer: null,\n style: null,\n className: null,\n itemTemplate: null,\n circular: false,\n autoplayInterval: 0,\n numVisible: 1,\n numScroll: 1,\n responsiveOptions: null,\n orientation: \"horizontal\",\n verticalViewPortHeight: \"300px\",\n contentClassName: null,\n containerClassName: null,\n indicatorsContentClassName: null,\n onPageChange: null\n});\n\nexport { Carousel };\n"],"mappings":"AAAA,OAAOA,KAAP,IAAgBC,SAAhB,QAAiC,OAAjC;AACA,SAASC,UAAT,EAAqBC,iBAArB,EAAwCC,UAAxC,QAA0D,kBAA1D;AACA,SAASC,MAAT,QAAuB,mBAAvB;AACA,OAAOC,UAAP,MAAuB,gBAAvB;;AAEA,SAASC,iBAAT,CAA2BC,GAA3B,EAAgCC,GAAhC,EAAqC;EACnC,IAAIA,GAAG,IAAI,IAAP,IAAeA,GAAG,GAAGD,GAAG,CAACE,MAA7B,EAAqCD,GAAG,GAAGD,GAAG,CAACE,MAAV;;EAErC,KAAK,IAAIC,CAAC,GAAG,CAAR,EAAWC,IAAI,GAAG,IAAIC,KAAJ,CAAUJ,GAAV,CAAvB,EAAuCE,CAAC,GAAGF,GAA3C,EAAgDE,CAAC,EAAjD,EAAqD;IACnDC,IAAI,CAACD,CAAD,CAAJ,GAAUH,GAAG,CAACG,CAAD,CAAb;EACD;;EAED,OAAOC,IAAP;AACD;;AAED,SAASE,kBAAT,CAA4BN,GAA5B,EAAiC;EAC/B,IAAIK,KAAK,CAACE,OAAN,CAAcP,GAAd,CAAJ,EAAwB,OAAOD,iBAAiB,CAACC,GAAD,CAAxB;AACzB;;AAED,SAASQ,gBAAT,CAA0BC,IAA1B,EAAgC;EAC9B,IAAI,OAAOC,MAAP,KAAkB,WAAlB,IAAiCD,IAAI,CAACC,M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