{"version":3,"file":"main-cf7c6c0c.js","sources":["../../../../node_modules/@rei/cedar/dist/components/icon/comps/arrow-left.vue.mjs","../../../../node_modules/@rei/cedar/dist/components/icon/comps/arrow-right.vue.mjs","../../../../node_modules/@rei/carousel/dist/main.mjs"],"sourcesContent":["import { defineComponent as o, openBlock as a, createBlock as n, normalizeProps as p, guardReactiveProps as l, withCtx as s, renderSlot as m, createElementVNode as d } from \"vue\";\nimport f from \"../CdrIcon.vue.mjs\";\nconst c = /* @__PURE__ */ o({\n name: \"ArrowLeft\",\n __name: \"arrow-left\",\n props: {\n props: {\n type: Object\n }\n },\n setup(r) {\n return (t, e) => (a(), n(f, p(l(r.props)), {\n default: s(() => [m(t.$slots, \"default\"), e[0] || (e[0] = d(\"path\", {\n role: \"presentation\",\n d: \"M7.415 11l3.295-3.295a1 1 0 00-1.417-1.412l-4.98 4.98a.997.997 0 00-.025 1.429l5.005 5.005a1 1 0 101.414-1.414L7.414 13H19a1 1 0 000-2H7.415z\"\n }, null, -1))]),\n _: 3\n }, 16));\n }\n});\nexport {\n c as default\n};\n","import { defineComponent as o, openBlock as a, createBlock as n, normalizeProps as p, guardReactiveProps as l, withCtx as s, renderSlot as i, createElementVNode as m } from \"vue\";\nimport d from \"../CdrIcon.vue.mjs\";\nconst f = /* @__PURE__ */ o({\n name: \"ArrowRight\",\n __name: \"arrow-right\",\n props: {\n props: {\n type: Object\n }\n },\n setup(r) {\n return (t, e) => (a(), n(d, p(l(r.props)), {\n default: s(() => [i(t.$slots, \"default\"), e[0] || (e[0] = m(\"path\", {\n role: \"presentation\",\n d: \"M16.585 13l-3.295 3.295a1 1 0 001.417 1.412l4.98-4.98a.997.997 0 00.025-1.429l-5.005-5.005a1 1 0 00-1.414 1.414L16.586 11H5a1 1 0 000 2h11.585z\"\n }, null, -1))]),\n _: 3\n }, 16));\n }\n});\nexport {\n f as default\n};\n","import \"core-js/modules/es.array.push.js\";\nimport \"core-js/modules/es.error.cause.js\";\nimport { defineComponent as U, openBlock as y, createElementBlock as $, Fragment as L, renderList as I, renderSlot as D, normalizeProps as O, guardReactiveProps as K, createElementVNode as W, mergeProps as k, withModifiers as x, toDisplayString as G, resolveComponent as B, resolveDirective as J, normalizeClass as A, createVNode as M, createSlots as R, withCtx as _, createCommentVNode as E, withDirectives as Q, normalizeStyle as Z, withKeys as q, createBlock as F, resolveDynamicComponent as tt } from \"vue\";\nimport { CdrButton as et, IconArrowLeft as H, IconArrowRight as X } from \"@rei/cedar\";\nimport { CdrTimingFunctionEaseOut as it, CdrDuration3X as P } from \"@rei/cdr-tokens\";\nconst V = (t, e) => {\n const i = t.__vccOpts || t;\n for (const [o, r] of e)\n i[o] = r;\n return i;\n}, st = U({\n name: \"DotsComponent\",\n props: {\n slidesUsedForDots: {\n type: Array,\n required: !0\n },\n getDotConfig: {\n type: Function,\n required: !0\n },\n handleDotClick: {\n type: Function,\n required: !0\n }\n }\n}), ot = {\n class: \"carousel-component__dots-track\",\n \"aria-label\": \"Choose a slide to display\"\n}, nt = [\"onClick\"], rt = {\n class: \"visually-hidden\"\n};\nfunction at(t, e, i, o, r, a) {\n return y(), $(\"ol\", ot, [(y(!0), $(L, null, I(t.slidesUsedForDots, ({\n key: c,\n props: u\n }, l) => (y(), $(\"li\", {\n key: c,\n ref_for: !0,\n ref: `dot-${u.originalIndex}`,\n class: \"carousel-component__dot\"\n }, [D(t.$slots, \"dot\", O(K(t.getDotConfig({\n key: c,\n index: l,\n ...u\n }))), () => [W(\"button\", k({\n class: \"carousel-component__dot-button carousel-component__dot-button--default\"\n }, t.getDotConfig({\n key: c,\n index: l,\n ...u\n }), {\n onClick: x((d) => t.handleDotClick(d, u.originalIndex, l), [\"prevent\"])\n }), [W(\"span\", rt, G(u.originalIndex), 1)], 16, nt)])]))), 128))]);\n}\nconst lt = /* @__PURE__ */ V(st, [[\"render\", at]]);\nfunction N(t, e, i) {\n let o;\n return function() {\n const a = this, c = arguments, u = function() {\n o = null, i || t.apply(a, c);\n }, l = i && !o;\n clearTimeout(o), o = setTimeout(u, e), l && t.apply(a, c);\n };\n}\nconst ct = U({\n name: \"CarouselComponent\",\n components: {\n CdrButton: et,\n DotsComponent: lt,\n IconArrowLeft: H,\n IconArrowRight: X\n },\n props: {\n allowArrowsTabFocus: {\n type: Boolean,\n required: !1,\n default: !0\n },\n arrows: {\n type: Boolean,\n required: !1,\n default: !0\n },\n centerMode: {\n type: [Boolean, Number],\n required: !1,\n default: !1\n },\n cssEasing: {\n type: String,\n required: !1,\n default: it\n },\n description: {\n type: String,\n required: !1,\n default: \"\"\n },\n dots: {\n type: Boolean,\n required: !1,\n default: !1\n },\n dotsLocation: {\n type: String,\n required: !1,\n default: \"bottom\",\n validator: (t) => [\"top\", \"bottom\"].includes(t)\n },\n enableBoundaryBounce: {\n type: Boolean,\n required: !1,\n default: !1\n },\n focusOnSliderElement: {\n type: Boolean,\n required: !1,\n default: !0\n },\n height: {\n type: String,\n required: !1,\n default: \"initial\",\n validator: (t) => t === \"initial\" || t === \"auto\" || [\"vw\", \"vh\", \"px\", \"em\", \"rem\"].some((e) => t.endsWith(e))\n },\n id: {\n type: String,\n required: !0\n },\n infinite: {\n type: Boolean,\n required: !1,\n default: !1\n },\n initialIndex: {\n type: Number,\n required: !1,\n default: 0,\n validator: (t) => typeof t == \"number\"\n },\n slides: {\n type: Array,\n required: !1,\n validator: (t) => t.every(({\n key: e,\n props: i\n }) => !!e && !!i)\n },\n slidesToShow: {\n type: Number,\n required: !1,\n default: 1\n },\n slidesToScroll: {\n type: Number,\n required: !1,\n default: 1\n },\n touchEnabled: {\n type: Boolean,\n required: !1,\n default: !0\n },\n touchThreshold: {\n type: Number,\n required: !1,\n default: 90\n },\n transitionDuration: {\n type: Number,\n required: !1,\n default: 400\n },\n transitionType: {\n type: String,\n required: !1,\n default: \"default\",\n validator: (t) => [\"default\", \"direct\", \"fade\"].includes(t)\n },\n variableWidth: {\n type: Boolean,\n required: !1,\n default: !1\n }\n },\n emits: [\"init\", \"after-change\", \"before-change\", \"arrow-click\", \"dot-click\", \"slide-loaded\", \"all-loaded\"],\n data() {\n return {\n animateTransition: !1,\n animateToIndex: 0,\n animateToIndexCache: null,\n activeIndex: 0,\n activeIndexCache: null,\n animateBoundaryBounce: null,\n containerWidth: 0,\n currentSlideHeight: 0,\n currentDirection: null,\n directAnimation: !1,\n dotsLeftMax: !1,\n dotsOverflow: !1,\n dotsRightMax: !1,\n dotsWidth: 0,\n dotsScrollLeft: 0,\n hydrateSlidesActive: !1,\n hydratedSlides: [],\n precedingSlideWidth: 0,\n precedingSlideWidthCache: 0,\n swipeDelta: 0,\n touchStartX: 0,\n trackWidth: 0,\n trackWidthCache: null,\n windowWidth: 0\n };\n },\n computed: {\n arrowTabindex() {\n return this.allowArrowsTabFocus ? \"0\" : \"-1\";\n },\n /*\n of slides with original indexes attached\n */\n canonicalSlides() {\n const {\n slides: t = []\n } = this;\n return t.map(({\n key: e,\n props: i\n }, o) => ({\n key: e,\n props: {\n ...i,\n originalIndex: o,\n loaded: null,\n // clientWidth: null,\n clientHeight: null\n }\n }));\n },\n /*\n between 0 - 1 reflecting scale factor of each slide\n */\n slideWidthScale() {\n const {\n centerMode: t\n } = this;\n let e = 1;\n return t !== !1 && (e = typeof t == \"number\" ? t : 0.8), e;\n },\n /*\n for arrows based on defaults and any arrow configuration props\n */\n computedArrowsConfig() {\n const {\n slidesToScroll: t\n } = this;\n return [{\n delta: -t,\n direction: \"left\",\n icon: H\n }, {\n delta: t,\n direction: \"right\",\n icon: X\n }];\n },\n /*\n indicating whether dots are allowed and have been activated by user\n */\n computedDots() {\n return !this.computedInfinite && this.dots;\n },\n /*\n of indexes, where each entry is the index of the first slide in each slide group.\n EX: slides.length = 9, slidesToShow = 3; slidesUsedForDots should be [0, 3, 6];\n */\n slidesUsedForDots() {\n const {\n slidesToShow: t,\n slidesToScroll: e,\n canonicalSlides: i\n } = this;\n return e === 1 ? i : i.filter((r) => r.props.originalIndex % e === 0 && r.props.originalIndex + (t - e) < i.length);\n },\n /*\n indicating whether infinite mode is allowed and has been activated by user\n */\n computedInfinite() {\n const {\n slidesToScroll: t\n } = this, e = 1 + t * 2;\n return this.infinite && this.canonicalSlides.length >= e;\n },\n /*\n of slides based on desired [non?]infinite behavior\n */\n computedSlides() {\n return this.computedInfinite ? this.infiniteSlides : this.finiteSlides;\n },\n /*\n of transitionType\n if 'direct' or 'fade' transition is desired, only allow it when the carousel has\n slides of uniform width, displays a single slide at a time, and is not in center mode.\n */\n computedTransitionType() {\n const {\n centerMode: t,\n transitionType: e,\n slidesToShow: i,\n slidesToScroll: o,\n variableWidth: r\n } = this;\n return e !== \"default\" && !t && i === 1 && o === 1 && !r ? e : \"default\";\n },\n /*\n which applies aria attributes for container element of carousel\n */\n containerAria() {\n const {\n description: t\n } = this, e = {};\n return t && (e[\"aria-label\"] = t), e;\n },\n /*\n which applies classes for container element of carousel\n */\n containerClasses() {\n const {\n centerMode: t\n } = this;\n return {\n \"carousel-component\": !0,\n \"carousel-component--center-mode\": t\n };\n },\n /*\n representing the pixel width of each slide\n */\n defaultWidth() {\n return this.containerWidth * this.slideWidthScale;\n },\n /*\n containing classes for dots container.\n */\n dotsContainerClasses() {\n const {\n dotsOverflow: t,\n dotsLeftMax: e,\n dotsRightMax: i\n } = this, o = [\"carousel-component__dots\"];\n return t && (o.push(\"carousel-component__dots--overflow\"), o.push({\n \"carousel-component__dots--left-max\": e\n }), o.push({\n \"carousel-component__dots--right-max\": i && !e\n })), o;\n },\n /*\n of slides that can be truncated if computedTransitionType === 'direct'\n */\n finiteSlides() {\n const {\n activeIndexCache: t,\n animateToIndexCache: e,\n hydratedSlides: i,\n directAnimation: o\n } = this;\n return o && i ? i.filter(({\n props: {\n originalIndex: a\n }\n }) => [t, e].includes(a)) : i;\n },\n /*\n , dynamically-sized by including `offset` number of slides on either side of\n the one `activeIndex` slide. Generates adjusted item key if any slide is repeated.\n */\n infiniteSlides() {\n const {\n activeIndex: t,\n hydratedSlides: e,\n offset: i,\n slidesToShow: o\n } = this, r = i + o + i;\n return e ? [...new Array(r)].map((c, u) => {\n const l = t + (u - i);\n let d = l, h = !1;\n l < 0 ? (h = r > e.length, d = e.length + l) : l >= e.length && (h = r > e.length, d = l - e.length);\n const {\n key: f,\n props: g\n } = e[d] || {};\n return {\n key: h ? `clone-${f}` : f,\n props: {\n ...g,\n originalIndex: d\n }\n };\n }) : [];\n },\n /*\n number of slides to render on either side of the active slide\n */\n offset() {\n const {\n slidesToScroll: t\n } = this, e = 2;\n return t > e ? t : e;\n },\n /*\n for the carousel track id based on the container id attribute\n */\n trackID() {\n return `${this.id}-items`;\n },\n /*\n containing styles for the carousel track.\n Translates the track L/R and conditionally allows it to animate\n */\n trackStyle() {\n const {\n animateTransition: t,\n computedInfinite: e,\n computedTransitionType: i,\n containerWidth: o,\n currentSlideHeight: r,\n cssEasing: a,\n height: c,\n precedingSlideWidth: u,\n transitionDuration: l,\n trackWidth: d\n } = this;\n let h = -1 * u;\n if (!e) {\n const s = this.getRelativeSlideWidths().reduce((S, b) => S + b), n = s - o >= 0 ? s - o : 0;\n h = -1 * (u > n ? n : u);\n }\n let f = `translateX(${h}px)`;\n if (this.animateBoundaryBounce) {\n let s;\n switch (this.animateBoundaryBounce) {\n case \"left\":\n s = 20;\n break;\n case \"right\":\n s = -20;\n break;\n default:\n s = 0;\n break;\n }\n f = `translateX(${h + s}px)`;\n }\n let g = c;\n c === \"initial\" && (g = r > 0 ? `${r}px` : c);\n const C = d > 0 ? `${d}px` : \"initial\", v = {\n transform: f,\n height: g,\n width: C\n };\n if (t && (v.transition = `all ${l}ms ${a}`, i === \"fade\")) {\n const s = l;\n v.transition = `all 0s ${s}ms,\n opacity ${l}ms ${a},\n height ${l}ms ${a}`, v.opacity = 0;\n }\n return this.animateBoundaryBounce && (v.transition = `transform ${P} ${a}`), v;\n }\n },\n watch: {\n slides() {\n let {\n initialIndex: t\n } = this;\n this.computedInfinite && ({\n offset: t\n } = this), this.hydratedSlides = this.canonicalSlides, this.animateToIndex = t, this.animateToIndexCache = null, this.activeIndex = t, this.activeIndexCache = null, this.$nextTick(() => {\n this.reset();\n });\n },\n dotsScrollLeft() {\n const {\n $refs: {\n dotsContainer: t\n },\n dotsScrollLeft: e\n } = this;\n t.scrollLeft = e;\n },\n slidesToScroll() {\n this.resetActiveDot();\n }\n },\n created() {\n this.slides && (this.hydratedSlides = this.canonicalSlides);\n const {\n focusOnSliderElement: t,\n setFocusOnSliderElement: e\n } = this;\n this.setFocusOnSliderElement = t ? e : () => {\n }, this.animateToIndex = this.initialIndex, this.activeIndex = this.initialIndex;\n },\n mounted() {\n this.slides && (this.debouncedReset = this.getDebouncedReset(), this.debouncedBoundaryHandler = this.getDebouncedBoundaryHandler(), this.reset(), this.setTabindexes(), this.$nextTick(() => {\n if (this.reset(), this.setCurrentSlideHeight(this.initialIndex), window && window.addEventListener(\"resize\", this.debouncedReset), this.$refs.dotsContainer) {\n const t = this.$refs.dotsTrack.$el;\n t.$el && (t.$el.addEventListener(\"scroll\", this.handleDotsScroll), this.handleDotsScroll({\n target: this.$refs.dotsContainer\n }));\n }\n this.$emit(\"init\");\n }));\n },\n beforeUnmount() {\n if (window && window.removeEventListener(\"resize\", this.debouncedReset), this.$refs.dotsContainer) {\n const t = this.$refs.dotsTrack.$el;\n t && t.removeEventListener(\"scroll\", this.handleDotsScroll);\n }\n },\n methods: {\n /*\n Shifts activeIndex the correct number in either direction and applies classes to animate\n the carousel track, then re-renders slides in place without animating\n */\n changeIndex(t = 0) {\n const {\n activeIndex: e,\n animateTransition: i,\n computedInfinite: o,\n offset: r,\n canonicalSlides: a,\n transitionDuration: c,\n computedTransitionType: u\n } = this;\n if (i)\n return;\n const l = e + t;\n let d = l;\n l < 0 && (d = o ? a.length + l : e), l >= a.length && (d = o ? l - a.length : e);\n const h = o ? r + t : d;\n u === \"direct\" && Math.abs(t) > 1 ? this.startDirectTransition({\n activeIndex: e,\n animateToIndex: h\n })().then(({\n directActiveIndex: f,\n directAnimateToIndex: g\n }) => {\n this.activeIndex = f, this.animateToIndex = f;\n const {\n preceding: C\n } = this.getSlideWidths(f);\n this.precedingSlideWidth = C, this.$nextTick(() => {\n const v = {\n activeIndex: e,\n animateToIndex: g,\n nextActiveIndex: d\n };\n this.executeTransitionAnimation(v), setTimeout(() => {\n this.completeTransition({\n animateToIndex: h,\n postAnimationIndex: h\n });\n }, c);\n });\n }).catch((f) => this.handleError(f)) : this.startDefaultTransition({\n nextActiveIndex: d\n })().then(({\n postAnimationIndex: f\n }) => {\n const g = {\n activeIndex: e,\n animateToIndex: h,\n nextActiveIndex: d\n };\n this.executeTransitionAnimation(g), setTimeout(() => {\n this.completeTransition({\n animateToIndex: d,\n postAnimationIndex: f\n });\n }, c);\n }).catch((f) => this.handleError(f));\n },\n completeTransition({\n animateToIndex: t,\n postAnimationIndex: e\n }) {\n const {\n trackWidthCache: i,\n cssEasing: o,\n transitionDuration: r\n } = this;\n this.animateTransition = !1, this.directAnimation = !1, this.activeIndexCache = null, this.animateToIndexCache = null, this.activeIndex = t, this.animateToIndex = t, i && (this.trackWidth = i, this.trackWidthCache = null), this.$nextTick(function() {\n const {\n preceding: c\n } = this.getSlideWidths(e);\n this.precedingSlideWidth = c, this.setTabindexes(), this.computedDots && this.setFocus(e);\n const u = this.slidesToShow - this.slidesToScroll, l = this.currentDirection === \"right\" ? e + u : e - u;\n this.setFocusOnSliderElement(l), this.$emit(\"after-change\", {\n currIndex: t\n });\n }), this.computedTransitionType === \"fade\" && (this.trackStyle.transition = `opacity ${r}ms ${o}`, this.trackStyle.opacity = 1);\n },\n /*\n Triggers actions on the carousel based on named events\n */\n dispatchEvent(t) {\n const {\n slidesToScroll: e,\n slides: i,\n activeIndex: o\n } = this;\n switch (t) {\n case \"FIRST\":\n this.changeIndex(o * -1);\n break;\n case \"LAST\":\n this.changeIndex(i.length - o - 1);\n break;\n case \"NEXT\":\n this.changeIndex(e);\n break;\n case \"PREV\":\n this.changeIndex(-e);\n break;\n default:\n console.warn(`handleSlideEvent called with unsupported event \"${t}\"`);\n break;\n }\n },\n /*\n Toggles animation css on, sets new slider track translateX, and emits event\n */\n executeTransitionAnimation({\n activeIndex: t,\n animateToIndex: e,\n nextActiveIndex: i\n }) {\n const {\n $refs: o,\n computedDots: r\n } = this;\n let a;\n if (r) {\n const u = o.dotsTrack.$refs[`dot-${i}`], l = u && u[0];\n a = l && l.querySelector(\"button\"), a && this.handleDotOverflow(a);\n }\n this.setCurrentSlideHeight(i), this.animateTransition = !0, this.animateToIndex = e;\n const {\n preceding: c\n } = this.getSlideWidths(e);\n this.precedingSlideWidth = c, this.$emit(\"before-change\", {\n prevIndex: t,\n nextIndex: i,\n element: a\n });\n },\n setFocusOnSliderElement(t) {\n if (!this.currentDirection)\n return;\n const {\n computedSlides: e,\n slidesToShow: i\n } = this, o = this.currentDirection === \"right\" ? t : t + i - 1;\n if (!e[o])\n return;\n const r = e[o].key, a = this.getSlideFocusableElements(r);\n if (a.length) {\n const c = this.currentDirection === \"right\" ? 0 : a.length - 1;\n a[c].focus();\n }\n },\n /*\n Returns with class and aria attributes for each arrow\n */\n getArrowConfig(t) {\n const {\n activeIndex: e,\n computedInfinite: i,\n canonicalSlides: o,\n slidesToShow: r\n } = this;\n let a = {\n \"data-ui\": `carousel-component-arrow-${t}`,\n class: `carousel-component__arrow carousel-component__arrow--${t}`,\n \"aria-label\": `${t === \"right\" ? \"Next\" : \"Previous\"} Slide`,\n \"aria-controls\": this.trackID,\n tabindex: this.arrowTabindex\n };\n if (!i) {\n const c = e === 0 && t === \"left\", u = e + r >= o.length && t === \"right\";\n if (!(c || u))\n return a;\n this.enableBoundaryBounce ? (a.class = `${a.class} carousel-component__arrow--disabled`, a = {\n ...a,\n \"aria-disabled\": !0\n }) : (a = {\n ...a,\n \"aria-disabled\": !0\n }, a.disabled = !0);\n }\n return a;\n },\n /*\n Returns with class and aria attributes for each dot\n */\n getDotConfig({\n key: t,\n originalIndex: e,\n index: i,\n clientHeight: o,\n ...r\n }) {\n const {\n canonicalSlides: a,\n slidesToScroll: c,\n animateToIndex: u,\n animateToIndexCache: l\n } = this, h = e === (l || u), f = {\n \"carousel-component__dot-button\": !0,\n \"carousel-component__dot-button--active\": h\n }, g = e + 1, C = g + c > a.length ? a.length : g + c, v = {\n ...r,\n active: h,\n // this odd way of passing the click handler is required for custom dots\n handleClick: (s) => this.handleDotClick(s, e, i),\n \"data-ui\": \"carousel-component-dot\",\n class: f,\n \"aria-label\": `Show items ${g} to ${C} of ${a.length}`\n };\n return h && (v[\"aria-disabled\"] = \"true\"), v;\n },\n /*\n Returns indicating slide's width\n */\n getSlideWidth() {\n const {\n centerMode: t,\n containerWidth: e,\n slideWidthScale: i,\n slidesToShow: o\n } = this, r = t ? e * i : e / o;\n return r > 0 ? `${r}px` : null;\n },\n /*\n Performs calculations to determine the correct amount to translate the carousel track\n provided as argument instead of coming from data to allow slides to transition\n */\n getSlideWidths(t) {\n const {\n centerMode: e,\n containerWidth: i\n } = this, o = this.getRelativeSlideWidths();\n let r = o.slice(0, t).reduce((u, l) => u + l, 0);\n if (e) {\n const u = o[t], l = (i - u) / 2;\n r -= l;\n }\n return {\n all: o.reduce((u, l) => u + l, 0),\n preceding: r\n };\n },\n /*\n Returns an of representing the width of each visible slide.\n Not a calculated prop because caching this value breaks screen resize functionality\n */\n getRelativeSlideWidths() {\n const {\n $refs: t,\n computedSlides: e,\n defaultWidth: i\n } = this;\n return e.map(({\n key: o\n /* , props: { clientWidth } */\n } = {}) => {\n const r = t[o] || {}, {\n clientWidth: a = 0\n } = r;\n let c = a;\n return (a === 0 || i < a) && (c = i), c;\n });\n },\n /*\n Returns props for each slide.\n Configures active and visible states for classes and aria attributes.\n */\n getSlideConfig({\n key: t,\n originalIndex: e\n }) {\n const {\n activeIndex: i,\n computedInfinite: o,\n canonicalSlides: r,\n centerMode: a,\n variableWidth: c,\n slidesToShow: u\n } = this, l = i === e, d = {\n \"aria-hidden\": (!l).toString(),\n class: {\n \"carousel-component__item\": !0,\n \"carousel-component__item--active\": l,\n // indicates this slide is the activeIndex\n \"carousel-component__item--visible\": l\n // indicates this slide is visible in the carousel\n },\n id: this.getSlideId(t),\n ref: t\n };\n if (c || (d.style = {\n width: this.getSlideWidth()\n }), u > 1 && !a) {\n const h = e > i && e < i + u;\n let f = l || h;\n !o && i >= r.length - u && (f = e >= r.length - u), d.class[\"carousel-component__item--visible\"] = f, d[\"aria-hidden\"] = (!f).toString();\n }\n return d;\n },\n /*\n Returns a collection of elements that can receive tab focus within the slide\n */\n getSlideFocusableElements(t) {\n return this.$refs[t].querySelectorAll('button:not([tabindex]), a:not([tabindex]), [tabindex]:not([tabindex=\"-1\"])');\n },\n /*\n Returns id for each slide based on the key for that slide\n */\n getSlideId(t) {\n return `${this.id}_slide_${t}`;\n },\n /*\n Returns ref for each slide based on the key for that slide\n */\n getSlideInnerRef(t) {\n return `${t}-inner`;\n },\n /*\n Returns containing all props and two new methods for each slide\n */\n getSlotConfig({\n props: t\n }) {\n return {\n ...t,\n handleSlideEvent: (e) => this.dispatchEvent(e),\n handleLoad: (e) => this.handleLoad(t.originalIndex, e)\n };\n },\n /*\n Calls changeIndex with the appropriate argument after emitting arrow click event\n */\n handleArrowClick({\n delta: t,\n direction: e\n }) {\n const {\n activeIndex: i,\n slidesToShow: o,\n canonicalSlides: r,\n computedInfinite: a\n } = this;\n if (this.enableBoundaryBounce && !a) {\n const c = i === 0 && e === \"left\", u = i + o >= r.length && e === \"right\";\n if (c || u) {\n this.debouncedBoundaryHandler(e);\n return;\n }\n }\n this.currentDirection = e, this.$emit(\"arrow-click\", {\n currIndex: i,\n direction: e\n }), this.changeIndex(t);\n },\n /*\n Calls changeIndex with the appropriate argument when a default dot is clicked\n */\n handleDotClick(t, e, i) {\n const o = e - this.activeIndex, r = o > 0 ? \"right\" : \"left\", {\n target: a\n } = t || {};\n this.$emit(\"dot-click\", {\n nextIndex: e,\n dotIndex: i,\n direction: r\n }), this.handleDotOverflow(a), this.changeIndex(o);\n },\n /*\n Determines whether dot element is offscreen, and calls transition method accordingly\n */\n handleDotOverflow(t) {\n const {\n $refs: e\n } = this, {\n left: i,\n right: o\n } = t.getBoundingClientRect(), r = e.dotsTrack.$el;\n if (!r)\n return;\n const {\n left: a,\n right: c\n } = r.getBoundingClientRect(), u = i < a ? i - a : 0, l = o > c ? o - c : 0;\n if (u || l) {\n const d = {\n amount: u || l\n };\n this.transitionDots(d);\n }\n },\n /*\n Sets up local state to render dots classes based on dot's scroll positions\n */\n handleDotsScroll({\n target: t = {}\n }) {\n const {\n clientWidth: e = 0,\n scrollLeft: i = 0,\n scrollWidth: o = 0\n } = t, r = i === 0, a = e + i === o;\n this.dotsLeftMax = r, this.dotsRightMax = a;\n },\n /*\n Triggers carousel animation after touch interaction concludes\n */\n handleEnd({\n touches: t\n } = {}) {\n const {\n animateTransition: e,\n swipeDelta: i,\n touchEnabled: o\n } = this;\n o && t && (e || (this.changeIndex(i), this.swipeDelta = 0));\n },\n /*\n Decorates each slide with props based on post-image-load slide container properties\n */\n handleLoad(t, e) {\n this.hydrateSlidesActive = !0;\n const i = [];\n let {\n target: o\n } = e;\n do\n i.push(o), o = o.parentNode;\n while (o);\n const r = i.find(({\n classList: l\n }) => l.contains(\"carousel-component__slide-inner\")), {\n clientHeight: a\n } = r, c = {\n loaded: !0,\n clientHeight: a\n };\n this.setDecoratedSlides(t, c), this.$emit(\"slide-loaded\", t), this.computedSlides.every(({\n props: l\n }) => l.loaded) && (this.$emit(\"all-loaded\"), this.reset()), this.activeIndex === t && this.setCurrentSlideHeight(t);\n },\n /*\n Performs calculations to correctly animate an ongoing user touch\n Sets direction flag used in slide change animation after conclusion of user interaction\n */\n handleMoving({\n touches: t\n }) {\n const {\n animateTransition: e,\n precedingSlideWidthCache: i,\n touchEnabled: o,\n touchStartX: r,\n touchThreshold: a,\n slidesToScroll: c\n } = this;\n if (o && !e && t) {\n const {\n clientX: u\n } = t[0], l = r - u, d = i + l;\n this.precedingSlideWidth = d;\n const h = i - d, f = Math.abs(h);\n if (f > a) {\n const g = h === f ? c * -1 : c;\n this.swipeDelta = g;\n }\n }\n },\n /*\n Sets up state to correctly animate an ongoing user touch\n */\n handleStart({\n touches: t\n }) {\n const {\n animateTransition: e,\n precedingSlideWidth: i,\n touchEnabled: o\n } = this;\n if (o && !e && t) {\n const [r] = t;\n this.touchStartX = r.clientX, this.precedingSlideWidthCache = i;\n }\n },\n /*\n Prints error to console. Also provides surface area for testing.\n */\n handleError(t) {\n console.error(Error(t));\n },\n handleTab(t, {\n key: e,\n originalIndex: i,\n direction: o\n }) {\n const {\n activeIndex: r,\n slidesToShow: a,\n slidesToScroll: c,\n canonicalSlides: u\n } = this;\n if (!(a === 0 || this.allowArrowsTabFocus))\n if (o === \"left\")\n i === r && i !== 0 && this.getSlideFocusableElements(e)[0] === t.srcElement && (t.preventDefault(), this.handleArrowClick({\n delta: -c,\n direction: \"left\"\n }));\n else {\n const l = r + a === i + 1, d = i < u.length - 1;\n if (l && d) {\n const h = this.getSlideFocusableElements(e);\n h[h.length - 1] === t.srcElement && (t.preventDefault(), this.handleArrowClick({\n delta: c,\n direction: \"right\"\n }));\n }\n }\n },\n /*\n Performs reecalc operations if the browser width changes\n */\n reset() {\n const {\n $refs: t,\n activeIndex: e,\n slideWidthScale: i,\n computedSlides: o,\n hydrateSlidesActive: r,\n hydratedSlides: a = [],\n offset: c\n } = this;\n if (r) {\n const v = [...a].map(({\n key: s,\n props: n\n }) => {\n const m = this.getSlideInnerRef(s), S = t[m] || [], [b = {}] = S, {\n clientHeight: p = 0\n } = b;\n return {\n key: s,\n props: {\n ...n,\n clientHeight: p\n }\n };\n });\n this.hydratedSlides = v;\n }\n if (!t.container)\n return;\n const {\n container: u = {},\n dotsContainer: l = {}\n } = t, {\n clientWidth: d = 0\n } = u, {\n scrollWidth: h = 0\n } = l;\n this.containerWidth = d, this.dotsWidth = h, this.dotsOverflow = d < h, this.handleDotsScroll({\n target: l\n }), this.setCurrentSlideHeight(e);\n const f = this.infinite ? c : e, {\n preceding: g\n } = this.getSlideWidths(f);\n this.precedingSlideWidth = g;\n const C = d * i * o.length;\n this.trackWidth = C;\n },\n resetActiveDot() {\n const {\n activeIndex: t,\n slidesToScroll: e,\n slidesUsedForDots: i\n } = this;\n if (e > 1) {\n const a = i.map((c) => c.props.originalIndex).reduce((c, u) => Math.abs(u - t) < Math.abs(c - t) ? u : c) - t;\n this.changeIndex(a);\n }\n },\n /**\n * Debounce this click handler so multiple clicks don't trigger multiple animations\n */\n getDebouncedBoundaryHandler() {\n const t = parseFloat(P);\n return N((e) => {\n this.animateBoundaryBounce = e;\n const i = () => new Promise((r) => {\n setTimeout(() => (this.animateBoundaryBounce = \"reset\", r()), t * 0.85);\n }), o = () => {\n setTimeout(() => {\n this.animateBoundaryBounce = null;\n }, t * 0.15);\n };\n i().then(o).catch();\n }, 200);\n },\n /**\n * We'll debounce the resize event so that we're not having to do expensive\n * re-renders for intermediate resets, and can thus improve perceived\n * performance when resizing. Using \"setTimeout\" allows us to add a call to\n * {@link this.reset} in the JS event queue, allowing the carousel to\n * re-render its track/slide elements after browser resize, and correctly\n * recomputing {@link trackStyle}.\n *\n * @return {Function} The debounced reset function with a 250\n * millesecond timer.\n */\n getDebouncedReset() {\n return N(() => {\n this.reset(), setTimeout(this.reset, 0);\n }, 250);\n },\n /*\n Sets prop `currentSlideHeight` with clientHeight of activeIndex slide. Not a computed prop\n this approach offers greater control over when this change happens.\n */\n setCurrentSlideHeight(t = 0) {\n const {\n canonicalSlides: e,\n hydratedSlides: i,\n hydrateSlidesActive: o,\n $refs: r\n } = this;\n let a;\n if (o)\n ({\n props: {\n clientHeight: a\n }\n } = i[t]);\n else {\n const {\n key: c\n } = e[t], u = this.getSlideInnerRef(c), l = r[u] || [], [d = {}] = l;\n ({\n clientHeight: a = 0\n } = d);\n }\n this.currentSlideHeight = a;\n },\n /*\n Utility for updating hydratedSlides prop\n */\n setDecoratedSlides(t, e = {}) {\n const i = [...this.hydratedSlides];\n this.hydratedSlides = i.map(({\n key: o,\n props: r\n }) => t === r.originalIndex ? {\n key: o,\n props: {\n ...r,\n ...e\n }\n } : {\n key: o,\n props: r\n });\n },\n /*\n Applies focus to correct slide\n */\n setFocus(t) {\n const {\n activeElement: e = {}\n } = document, {\n classList: i = []\n } = e;\n if (i.contains(\"carousel-component__arrow\"))\n return;\n const {\n computedSlides: o,\n $refs: r\n } = this, {\n key: a\n } = o[t];\n r[a].focus({\n preventScroll: !0\n });\n },\n /*\n Finds and applies tabindex=\"-1\" on any or