@nanoporetech-digital/components 5.4.2 → 5.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. package/CHANGELOG.md +30 -0
  2. package/dist/cjs/nano-global-nav-user-profile_3.cjs.entry.js +1 -1
  3. package/dist/cjs/nano-global-nav-user-profile_3.cjs.entry.js.map +1 -1
  4. package/dist/cjs/nano-global-nav.cjs.entry.js +1 -4
  5. package/dist/cjs/nano-global-nav.cjs.entry.js.map +1 -1
  6. package/dist/cjs/nano-slides.cjs.entry.js +64 -33
  7. package/dist/cjs/nano-slides.cjs.entry.js.map +1 -1
  8. package/dist/cjs/{nano-table-201b1ee2.js → nano-table-884ce575.js} +2 -2
  9. package/dist/cjs/{nano-table-201b1ee2.js.map → nano-table-884ce575.js.map} +1 -1
  10. package/dist/cjs/nano-table.cjs.entry.js +1 -1
  11. package/dist/cjs/{table.worker-1b295406.js → table.worker-670457aa.js} +2 -2
  12. package/dist/cjs/table.worker-670457aa.js.map +1 -0
  13. package/dist/collection/components/global-nav/global-nav.js +1 -4
  14. package/dist/collection/components/global-nav/global-nav.js.map +1 -1
  15. package/dist/collection/components/nav-item/nav-item.js +1 -1
  16. package/dist/collection/components/nav-item/nav-item.js.map +1 -1
  17. package/dist/collection/components/slides/lib/js/animate.js +5 -3
  18. package/dist/collection/components/slides/lib/js/flickity.js +1 -0
  19. package/dist/collection/components/slides/lib/js/page-dots.js +5 -0
  20. package/dist/collection/components/slides/lib/js/prev-next-button.js +23 -6
  21. package/dist/collection/components/slides/slides-interface.js.map +1 -1
  22. package/dist/collection/components/slides/slides.js +47 -28
  23. package/dist/collection/components/slides/slides.js.map +1 -1
  24. package/dist/components/nano-global-nav.js +1 -4
  25. package/dist/components/nano-global-nav.js.map +1 -1
  26. package/dist/components/nano-slides.js +64 -33
  27. package/dist/components/nano-slides.js.map +1 -1
  28. package/dist/components/nav-item.js +1 -1
  29. package/dist/components/nav-item.js.map +1 -1
  30. package/dist/esm/nano-global-nav-user-profile_3.entry.js +1 -1
  31. package/dist/esm/nano-global-nav-user-profile_3.entry.js.map +1 -1
  32. package/dist/esm/nano-global-nav.entry.js +1 -4
  33. package/dist/esm/nano-global-nav.entry.js.map +1 -1
  34. package/dist/esm/nano-slides.entry.js +64 -33
  35. package/dist/esm/nano-slides.entry.js.map +1 -1
  36. package/dist/esm/{nano-table-f2c222e8.js → nano-table-c6a4e1dc.js} +2 -2
  37. package/dist/esm/{nano-table-f2c222e8.js.map → nano-table-c6a4e1dc.js.map} +1 -1
  38. package/dist/esm/nano-table.entry.js +1 -1
  39. package/dist/esm/{table.worker-8356a40e.js → table.worker-2568f20c.js} +2 -2
  40. package/dist/esm/table.worker-2568f20c.js.map +1 -0
  41. package/dist/nano-components/nano-components.esm.js +1 -1
  42. package/dist/nano-components/{p-bdb5dfc3.js → p-4ef3200a.js} +2 -2
  43. package/dist/nano-components/p-7c4ac519.entry.js +23 -0
  44. package/dist/nano-components/p-7c4ac519.entry.js.map +1 -0
  45. package/dist/nano-components/{p-fa9f834b.entry.js → p-997319eb.entry.js} +2 -2
  46. package/dist/nano-components/{p-fa9f834b.entry.js.map → p-997319eb.entry.js.map} +1 -1
  47. package/dist/nano-components/{p-e94da35a.entry.js → p-9a0191c7.entry.js} +2 -2
  48. package/dist/nano-components/p-afd3cd17.entry.js +5 -0
  49. package/dist/nano-components/p-afd3cd17.entry.js.map +1 -0
  50. package/dist/nano-components/{p-a593dac2.js → p-f5698b41.js} +2 -2
  51. package/dist/types/components/slides/slides-interface.d.ts +2 -0
  52. package/dist/types/components/slides/slides.d.ts +39 -74
  53. package/dist/types/components.d.ts +3 -3
  54. package/docs-json.json +104 -7
  55. package/hydrate/index.js +80 -39
  56. package/package.json +2 -2
  57. package/dist/cjs/table.worker-1b295406.js.map +0 -1
  58. package/dist/esm/table.worker-8356a40e.js.map +0 -1
  59. package/dist/nano-components/p-37c7eda3.entry.js +0 -5
  60. package/dist/nano-components/p-37c7eda3.entry.js.map +0 -1
  61. package/dist/nano-components/p-7f5fb917.entry.js +0 -23
  62. package/dist/nano-components/p-7f5fb917.entry.js.map +0 -1
  63. /package/dist/nano-components/{p-bdb5dfc3.js.map → p-4ef3200a.js.map} +0 -0
  64. /package/dist/nano-components/{p-a593dac2.js.map → p-9a0191c7.entry.js.map} +0 -0
  65. /package/dist/nano-components/{p-e94da35a.entry.js.map → p-f5698b41.js.map} +0 -0
package/docs-json.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "timestamp": "2023-09-09T00:05:28",
2
+ "timestamp": "2023-09-29T10:16:55",
3
3
  "compiler": {
4
4
  "name": "@stencil/core",
5
5
  "version": "2.23.1",
@@ -13631,13 +13631,61 @@
13631
13631
  "readme": "# ion-slides\n\nThe Slides component is a multi-section container. Each section can be swiped\nor dragged between. It contains any number of [Slide](../slide) components.\n\n\nAdopted from Swiper.js:\nThe most modern mobile touch slider and framework with hardware accelerated transitions.\n\nhttp://www.idangero.us/swiper/\n\nCopyright 2016, Vladimir Kharlampidi\nThe iDangero.us\nhttp://www.idangero.us/\n\nLicensed under MIT\n\n## Custom Animations\n\nBy default, Ionic slides use the built-in `slide` animation effect. Custom animations can be provided via the `options` property. Examples of other animations can be found below.\n\n\n### Coverflow\n\n```typescript\nconst slideOpts = {\n slidesPerView: 3,\n coverflowEffect: {\n rotate: 50,\n stretch: 0,\n depth: 100,\n modifier: 1,\n slideShadows: true,\n },\n on: {\n beforeInit() {\n const swiper = this;\n\n swiper.classNames.push(`${swiper.params.containerModifierClass}coverflow`);\n swiper.classNames.push(`${swiper.params.containerModifierClass}3d`);\n\n swiper.params.watchSlidesProgress = true;\n swiper.originalParams.watchSlidesProgress = true;\n },\n setTranslate() {\n const swiper = this;\n const {\n width: swiperWidth, height: swiperHeight, slides, $wrapperEl, slidesSizesGrid, $\n } = swiper;\n const params = swiper.params.coverflowEffect;\n const isHorizontal = swiper.isHorizontal();\n const transform$$1 = swiper.translate;\n const center = isHorizontal ? -transform$$1 + (swiperWidth / 2) : -transform$$1 + (swiperHeight / 2);\n const rotate = isHorizontal ? params.rotate : -params.rotate;\n const translate = params.depth;\n // Each slide offset from center\n for (let i = 0, length = slides.length; i < length; i += 1) {\n const $slideEl = slides.eq(i);\n const slideSize = slidesSizesGrid[i];\n const slideOffset = $slideEl[0].swiperSlideOffset;\n const offsetMultiplier = ((center - slideOffset - (slideSize / 2)) / slideSize) * params.modifier;\n\n let rotateY = isHorizontal ? rotate * offsetMultiplier : 0;\n let rotateX = isHorizontal ? 0 : rotate * offsetMultiplier;\n // var rotateZ = 0\n let translateZ = -translate * Math.abs(offsetMultiplier);\n\n let translateY = isHorizontal ? 0 : params.stretch * (offsetMultiplier);\n let translateX = isHorizontal ? params.stretch * (offsetMultiplier) : 0;\n\n // Fix for ultra small values\n if (Math.abs(translateX) < 0.001) translateX = 0;\n if (Math.abs(translateY) < 0.001) translateY = 0;\n if (Math.abs(translateZ) < 0.001) translateZ = 0;\n if (Math.abs(rotateY) < 0.001) rotateY = 0;\n if (Math.abs(rotateX) < 0.001) rotateX = 0;\n\n const slideTransform = `translate3d(${translateX}px,${translateY}px,${translateZ}px) rotateX(${rotateX}deg) rotateY(${rotateY}deg)`;\n\n $slideEl.transform(slideTransform);\n $slideEl[0].style.zIndex = -Math.abs(Math.round(offsetMultiplier)) + 1;\n if (params.slideShadows) {\n // Set shadows\n let $shadowBeforeEl = isHorizontal ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top');\n let $shadowAfterEl = isHorizontal ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom');\n if ($shadowBeforeEl.length === 0) {\n $shadowBeforeEl = swiper.$(`<div class=\"swiper-slide-shadow-${isHorizontal ? 'left' : 'top'}\"></div>`);\n $slideEl.append($shadowBeforeEl);\n }\n if ($shadowAfterEl.length === 0) {\n $shadowAfterEl = swiper.$(`<div class=\"swiper-slide-shadow-${isHorizontal ? 'right' : 'bottom'}\"></div>`);\n $slideEl.append($shadowAfterEl);\n }\n if ($shadowBeforeEl.length) $shadowBeforeEl[0].style.opacity = offsetMultiplier > 0 ? offsetMultiplier : 0;\n if ($shadowAfterEl.length) $shadowAfterEl[0].style.opacity = (-offsetMultiplier) > 0 ? -offsetMultiplier : 0;\n }\n }\n\n // Set correct perspective for IE10\n if (swiper.support.pointerEvents || swiper.support.prefixedPointerEvents) {\n const ws = $wrapperEl[0].style;\n ws.perspectiveOrigin = `${center}px 50%`;\n }\n },\n setTransition(duration) {\n const swiper = this;\n swiper.slides\n .transition(duration)\n .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left')\n .transition(duration);\n }\n }\n}\n```\n\n### Cube\n\n```typescript\nconst slideOpts = {\n grabCursor: true,\n cubeEffect: {\n shadow: true,\n slideShadows: true,\n shadowOffset: 20,\n shadowScale: 0.94,\n },\n on: {\n beforeInit: function() {\n const swiper = this;\n swiper.classNames.push(`${swiper.params.containerModifierClass}cube`);\n swiper.classNames.push(`${swiper.params.containerModifierClass}3d`);\n\n const overwriteParams = {\n slidesPerView: 1,\n slidesPerColumn: 1,\n slidesPerGroup: 1,\n watchSlidesProgress: true,\n resistanceRatio: 0,\n spaceBetween: 0,\n centeredSlides: false,\n virtualTranslate: true,\n };\n\n this.params = Object.assign(this.params, overwriteParams);\n this.originalParams = Object.assign(this.originalParams, overwriteParams);\n },\n setTranslate: function() {\n const swiper = this;\n const {\n $el, $wrapperEl, slides, width: swiperWidth, height: swiperHeight, rtlTranslate: rtl, size: swiperSize,\n } = swiper;\n const params = swiper.params.cubeEffect;\n const isHorizontal = swiper.isHorizontal();\n const isVirtual = swiper.virtual && swiper.params.virtual.enabled;\n let wrapperRotate = 0;\n let $cubeShadowEl;\n if (params.shadow) {\n if (isHorizontal) {\n $cubeShadowEl = $wrapperEl.find('.swiper-cube-shadow');\n if ($cubeShadowEl.length === 0) {\n $cubeShadowEl = swiper.$('<div class=\"swiper-cube-shadow\"></div>');\n $wrapperEl.append($cubeShadowEl);\n }\n $cubeShadowEl.css({ height: `${swiperWidth}px` });\n } else {\n $cubeShadowEl = $el.find('.swiper-cube-shadow');\n if ($cubeShadowEl.length === 0) {\n $cubeShadowEl = swiper.$('<div class=\"swiper-cube-shadow\"></div>');\n $el.append($cubeShadowEl);\n }\n }\n }\n\n for (let i = 0; i < slides.length; i += 1) {\n const $slideEl = slides.eq(i);\n let slideIndex = i;\n if (isVirtual) {\n slideIndex = parseInt($slideEl.attr('data-swiper-slide-index'), 10);\n }\n let slideAngle = slideIndex * 90;\n let round = Math.floor(slideAngle / 360);\n if (rtl) {\n slideAngle = -slideAngle;\n round = Math.floor(-slideAngle / 360);\n }\n const progress = Math.max(Math.min($slideEl[0].progress, 1), -1);\n let tx = 0;\n let ty = 0;\n let tz = 0;\n if (slideIndex % 4 === 0) {\n tx = -round * 4 * swiperSize;\n tz = 0;\n } else if ((slideIndex - 1) % 4 === 0) {\n tx = 0;\n tz = -round * 4 * swiperSize;\n } else if ((slideIndex - 2) % 4 === 0) {\n tx = swiperSize + (round * 4 * swiperSize);\n tz = swiperSize;\n } else if ((slideIndex - 3) % 4 === 0) {\n tx = -swiperSize;\n tz = (3 * swiperSize) + (swiperSize * 4 * round);\n }\n if (rtl) {\n tx = -tx;\n }\n\n if (!isHorizontal) {\n ty = tx;\n tx = 0;\n }\n\n const transform$$1 = `rotateX(${isHorizontal ? 0 : -slideAngle}deg) rotateY(${isHorizontal ? slideAngle : 0}deg) translate3d(${tx}px, ${ty}px, ${tz}px)`;\n if (progress <= 1 && progress > -1) {\n wrapperRotate = (slideIndex * 90) + (progress * 90);\n if (rtl) wrapperRotate = (-slideIndex * 90) - (progress * 90);\n }\n $slideEl.transform(transform$$1);\n if (params.slideShadows) {\n // Set shadows\n let shadowBefore = isHorizontal ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top');\n let shadowAfter = isHorizontal ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom');\n if (shadowBefore.length === 0) {\n shadowBefore = swiper.$(`<div class=\"swiper-slide-shadow-${isHorizontal ? 'left' : 'top'}\"></div>`);\n $slideEl.append(shadowBefore);\n }\n if (shadowAfter.length === 0) {\n shadowAfter = swiper.$(`<div class=\"swiper-slide-shadow-${isHorizontal ? 'right' : 'bottom'}\"></div>`);\n $slideEl.append(shadowAfter);\n }\n if (shadowBefore.length) shadowBefore[0].style.opacity = Math.max(-progress, 0);\n if (shadowAfter.length) shadowAfter[0].style.opacity = Math.max(progress, 0);\n }\n }\n $wrapperEl.css({\n '-webkit-transform-origin': `50% 50% -${swiperSize / 2}px`,\n '-moz-transform-origin': `50% 50% -${swiperSize / 2}px`,\n '-ms-transform-origin': `50% 50% -${swiperSize / 2}px`,\n 'transform-origin': `50% 50% -${swiperSize / 2}px`,\n });\n\n if (params.shadow) {\n if (isHorizontal) {\n $cubeShadowEl.transform(`translate3d(0px, ${(swiperWidth / 2) + params.shadowOffset}px, ${-swiperWidth / 2}px) rotateX(90deg) rotateZ(0deg) scale(${params.shadowScale})`);\n } else {\n const shadowAngle = Math.abs(wrapperRotate) - (Math.floor(Math.abs(wrapperRotate) / 90) * 90);\n const multiplier = 1.5 - (\n (Math.sin((shadowAngle * 2 * Math.PI) / 360) / 2)\n + (Math.cos((shadowAngle * 2 * Math.PI) / 360) / 2)\n );\n const scale1 = params.shadowScale;\n const scale2 = params.shadowScale / multiplier;\n const offset$$1 = params.shadowOffset;\n $cubeShadowEl.transform(`scale3d(${scale1}, 1, ${scale2}) translate3d(0px, ${(swiperHeight / 2) + offset$$1}px, ${-swiperHeight / 2 / scale2}px) rotateX(-90deg)`);\n }\n }\n\n const zFactor = (swiper.browser.isSafari || swiper.browser.isUiWebView) ? (-swiperSize / 2) : 0;\n $wrapperEl\n .transform(`translate3d(0px,0,${zFactor}px) rotateX(${swiper.isHorizontal() ? 0 : wrapperRotate}deg) rotateY(${swiper.isHorizontal() ? -wrapperRotate : 0}deg)`);\n },\n setTransition: function(duration) {\n const swiper = this;\n const { $el, slides } = swiper;\n slides\n .transition(duration)\n .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left')\n .transition(duration);\n if (swiper.params.cubeEffect.shadow && !swiper.isHorizontal()) {\n $el.find('.swiper-cube-shadow').transition(duration);\n }\n },\n }\n}\n```\n\n### Fade\n\n```typescript\nconst slideOpts = {\n on: {\n beforeInit() {\n const swiper = this;\n swiper.classNames.push(`${swiper.params.containerModifierClass}fade`);\n const overwriteParams = {\n slidesPerView: 1,\n slidesPerColumn: 1,\n slidesPerGroup: 1,\n watchSlidesProgress: true,\n spaceBetween: 0,\n virtualTranslate: true,\n };\n swiper.params = Object.assign(swiper.params, overwriteParams);\n swiper.params = Object.assign(swiper.originalParams, overwriteParams);\n },\n setTranslate() {\n const swiper = this;\n const { slides } = swiper;\n for (let i = 0; i < slides.length; i += 1) {\n const $slideEl = swiper.slides.eq(i);\n const offset$$1 = $slideEl[0].swiperSlideOffset;\n let tx = -offset$$1;\n if (!swiper.params.virtualTranslate) tx -= swiper.translate;\n let ty = 0;\n if (!swiper.isHorizontal()) {\n ty = tx;\n tx = 0;\n }\n const slideOpacity = swiper.params.fadeEffect.crossFade\n ? Math.max(1 - Math.abs($slideEl[0].progress), 0)\n : 1 + Math.min(Math.max($slideEl[0].progress, -1), 0);\n $slideEl\n .css({\n opacity: slideOpacity,\n })\n .transform(`translate3d(${tx}px, ${ty}px, 0px)`);\n }\n },\n setTransition(duration) {\n const swiper = this;\n const { slides, $wrapperEl } = swiper;\n slides.transition(duration);\n if (swiper.params.virtualTranslate && duration !== 0) {\n let eventTriggered = false;\n slides.transitionEnd(() => {\n if (eventTriggered) return;\n if (!swiper || swiper.destroyed) return;\n eventTriggered = true;\n swiper.animating = false;\n const triggerEvents = ['webkitTransitionEnd', 'transitionend'];\n for (let i = 0; i < triggerEvents.length; i += 1) {\n $wrapperEl.trigger(triggerEvents[i]);\n }\n });\n }\n },\n }\n}\n```\n\n### Flip\n\n```typescript\nconst slideOpts = {\n on: {\n beforeInit() {\n const swiper = this;\n swiper.classNames.push(`${swiper.params.containerModifierClass}flip`);\n swiper.classNames.push(`${swiper.params.containerModifierClass}3d`);\n const overwriteParams = {\n slidesPerView: 1,\n slidesPerColumn: 1,\n slidesPerGroup: 1,\n watchSlidesProgress: true,\n spaceBetween: 0,\n virtualTranslate: true,\n };\n swiper.params = Object.assign(swiper.params, overwriteParams);\n swiper.originalParams = Object.assign(swiper.originalParams, overwriteParams);\n },\n setTranslate() {\n const swiper = this;\n const { $, slides, rtlTranslate: rtl } = swiper;\n for (let i = 0; i < slides.length; i += 1) {\n const $slideEl = slides.eq(i);\n let progress = $slideEl[0].progress;\n if (swiper.params.flipEffect.limitRotation) {\n progress = Math.max(Math.min($slideEl[0].progress, 1), -1);\n }\n const offset$$1 = $slideEl[0].swiperSlideOffset;\n const rotate = -180 * progress;\n let rotateY = rotate;\n let rotateX = 0;\n let tx = -offset$$1;\n let ty = 0;\n if (!swiper.isHorizontal()) {\n ty = tx;\n tx = 0;\n rotateX = -rotateY;\n rotateY = 0;\n } else if (rtl) {\n rotateY = -rotateY;\n }\n\n $slideEl[0].style.zIndex = -Math.abs(Math.round(progress)) + slides.length;\n\n if (swiper.params.flipEffect.slideShadows) {\n // Set shadows\n let shadowBefore = swiper.isHorizontal() ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top');\n let shadowAfter = swiper.isHorizontal() ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom');\n if (shadowBefore.length === 0) {\n shadowBefore = swiper.$(`<div class=\"swiper-slide-shadow-${swiper.isHorizontal() ? 'left' : 'top'}\"></div>`);\n $slideEl.append(shadowBefore);\n }\n if (shadowAfter.length === 0) {\n shadowAfter = swiper.$(`<div class=\"swiper-slide-shadow-${swiper.isHorizontal() ? 'right' : 'bottom'}\"></div>`);\n $slideEl.append(shadowAfter);\n }\n if (shadowBefore.length) shadowBefore[0].style.opacity = Math.max(-progress, 0);\n if (shadowAfter.length) shadowAfter[0].style.opacity = Math.max(progress, 0);\n }\n $slideEl\n .transform(`translate3d(${tx}px, ${ty}px, 0px) rotateX(${rotateX}deg) rotateY(${rotateY}deg)`);\n }\n },\n setTransition(duration) {\n const swiper = this;\n const { slides, activeIndex, $wrapperEl } = swiper;\n slides\n .transition(duration)\n .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left')\n .transition(duration);\n if (swiper.params.virtualTranslate && duration !== 0) {\n let eventTriggered = false;\n // eslint-disable-next-line\n slides.eq(activeIndex).transitionEnd(function onTransitionEnd() {\n if (eventTriggered) return;\n if (!swiper || swiper.destroyed) return;\n\n eventTriggered = true;\n swiper.animating = false;\n const triggerEvents = ['webkitTransitionEnd', 'transitionend'];\n for (let i = 0; i < triggerEvents.length; i += 1) {\n $wrapperEl.trigger(triggerEvents[i]);\n }\n });\n }\n }\n }\n};\n```\n",
13632
13632
  "docs": "The Slides component is a multi-section container. Each section can be swiped or dragged between.\nIt contains any number of Slide components.\n\nUses [Flickity](https://flickity.metafizzy.co/) under the hood.",
13633
13633
  "docsTags": [
13634
+ {
13635
+ "name": "part",
13636
+ "text": "base - Wrapper around slides and additional ui elements."
13637
+ },
13638
+ {
13639
+ "name": "part",
13640
+ "text": "slide-container - Wraps all slide elements."
13641
+ },
13642
+ {
13643
+ "name": "part",
13644
+ "text": "slide-viewport - The visible, scrollable area around slide elements."
13645
+ },
13646
+ {
13647
+ "name": "part",
13648
+ "text": "navigation-button - Next / previous navigation buttons."
13649
+ },
13650
+ {
13651
+ "name": "part",
13652
+ "text": "navigation-button--next - the next navigation button."
13653
+ },
13654
+ {
13655
+ "name": "part",
13656
+ "text": "navigation-button--previous - The previous navigation button."
13657
+ },
13658
+ {
13659
+ "name": "part",
13660
+ "text": "navigation-icon - The chevron / arrow icon within a navigation button."
13661
+ },
13662
+ {
13663
+ "name": "part",
13664
+ "text": "pagination - Wraps pagination indicators."
13665
+ },
13666
+ {
13667
+ "name": "part",
13668
+ "text": "pagination-item - A pagination indicator."
13669
+ },
13670
+ {
13671
+ "name": "part",
13672
+ "text": "pagination-item--active - The current, active pagination indicator."
13673
+ },
13634
13674
  {
13635
13675
  "name": "slot",
13636
- "text": "- default slot of nano-slide components"
13676
+ "text": "- default slot of nano-slide components."
13637
13677
  },
13638
13678
  {
13639
13679
  "name": "slot",
13640
13680
  "text": "ui - An absolutely positioned element that will be placed over the slider. Any custom ui can be housed here."
13681
+ },
13682
+ {
13683
+ "name": "slot",
13684
+ "text": "next-icon - Optional next icon to use instead of the default."
13685
+ },
13686
+ {
13687
+ "name": "slot",
13688
+ "text": "previous-icon - Optional previous icon to use instead of the default."
13641
13689
  }
13642
13690
  ],
13643
13691
  "usage": {},
@@ -14023,7 +14071,7 @@
14023
14071
  "bubbles": true,
14024
14072
  "cancelable": true,
14025
14073
  "composed": true,
14026
- "docs": "Emitted after component initialization",
14074
+ "docs": "Emitted after component initialisation.",
14027
14075
  "docsTags": []
14028
14076
  },
14029
14077
  {
@@ -14068,7 +14116,7 @@
14068
14116
  "bubbles": true,
14069
14117
  "cancelable": true,
14070
14118
  "composed": true,
14071
- "docs": "Emitted after flickity initialization",
14119
+ "docs": "Emitted after flickity initialisation.",
14072
14120
  "docsTags": []
14073
14121
  },
14074
14122
  {
@@ -14086,7 +14134,7 @@
14086
14134
  "bubbles": true,
14087
14135
  "cancelable": true,
14088
14136
  "composed": true,
14089
- "docs": "Emitted when a slide is selected, even on the same slide",
14137
+ "docs": "Emitted when a slide is selected, even on the same slide.",
14090
14138
  "docsTags": []
14091
14139
  },
14092
14140
  {
@@ -14154,14 +14202,63 @@
14154
14202
  "slots": [
14155
14203
  {
14156
14204
  "name": "",
14157
- "docs": "default slot of nano-slide components"
14205
+ "docs": "default slot of nano-slide components."
14206
+ },
14207
+ {
14208
+ "name": "next-icon",
14209
+ "docs": "Optional next icon to use instead of the default."
14210
+ },
14211
+ {
14212
+ "name": "previous-icon",
14213
+ "docs": "Optional previous icon to use instead of the default."
14158
14214
  },
14159
14215
  {
14160
14216
  "name": "ui",
14161
14217
  "docs": "An absolutely positioned element that will be placed over the slider. Any custom ui can be housed here."
14162
14218
  }
14163
14219
  ],
14164
- "parts": [],
14220
+ "parts": [
14221
+ {
14222
+ "name": "base",
14223
+ "docs": "Wrapper around slides and additional ui elements."
14224
+ },
14225
+ {
14226
+ "name": "navigation-button",
14227
+ "docs": "Next / previous navigation buttons."
14228
+ },
14229
+ {
14230
+ "name": "navigation-button--next",
14231
+ "docs": "the next navigation button."
14232
+ },
14233
+ {
14234
+ "name": "navigation-button--previous",
14235
+ "docs": "The previous navigation button."
14236
+ },
14237
+ {
14238
+ "name": "navigation-icon",
14239
+ "docs": "The chevron / arrow icon within a navigation button."
14240
+ },
14241
+ {
14242
+ "name": "pagination",
14243
+ "docs": "Wraps pagination indicators."
14244
+ },
14245
+ {
14246
+ "name": "pagination-item",
14247
+ "docs": "A pagination indicator."
14248
+ },
14249
+ {
14250
+ "name": "pagination-item--active",
14251
+ "docs": "The current, active pagination indicator."
14252
+ },
14253
+ {
14254
+ "name": "slide-container",
14255
+ "docs": "Wraps all slide elements."
14256
+ },
14257
+ {
14258
+ "name": "slide-viewport",
14259
+ "docs": "The visible, scrollable area around slide elements."
14260
+ }
14261
+ ],
14165
14262
  "dependents": [],
14166
14263
  "dependencies": [],
14167
14264
  "dependencyGraph": {}
package/hydrate/index.js CHANGED
@@ -17290,10 +17290,7 @@ class GlobalNav {
17290
17290
  (this.loggedInNavItms.length || this.hasLoggedinSlot) && (hAsync("nav", { class: "nav-links", "aria-label": "Your user account links" }, hAsync("nano-nav-item", { class: "nano-global-nav user-nav nano-global-nav-menu" }, this.myAccountUser.name, hAsync("nano-icon", { slot: "icon-end", name: "solid/chevron-right" }), hAsync("div", { slot: "secondary" }, hAsync("div", { class: "content" }, hAsync("button", { class: "back-btn", onClick: this.subMenuClose }, hAsync("nano-icon", { slot: "icon-end", name: "solid/chevron-left", "aria-label": "go back" }), this.myAccountUser.name), !!((_a = this.myAccountUser) === null || _a === void 0 ? void 0 : _a.small_avatar_url) && (hAsync("nano-global-nav-user-profile", { myAccountUser: this.myAccountUser, userProfileUrl: this.userProfileUrl })), hAsync("div", { class: "content--sub" }, hAsync("slot", { name: "loggedin", onSlotchange: this.assessSlottedContent }), this.loggedInNavItms.map((link) => {
17291
17291
  return (hAsync("nano-nav-item", { class: "nano-global-nav nano-global-nav-menu" }, hAsync("a", { href: link.address, target: link.target }, link.title)));
17292
17292
  }), hAsync("nano-nav-item", { class: "nano-global-nav nano-global-nav-menu" }, hAsync("a", { href: this.myAccData.urls.forgot_password +
17293
- this.ssoRedirect }, "Change Password")))))))), hAsync("slot", { name: "promotion", onSlotchange: this.assessSlottedContent }), this.myAccData && this.myAccData.urls.logout && (hAsync("div", { class: "login-btn logout-btn" }, hAsync("a", { href: this.myAccData.urls.logout + this.ssoRedirect }, "Logout")))))), hAsync("div", { class: "sticker-trigger" }), hAsync("nano-sticker", { "auto-resize": "false", "break-point-max": "800", quietMode: { h: 600, w: 800 }, part: "sticker" }, hAsync("div", { class: "bars", part: "bars" }, hAsync("nav", { part: "main-bar", class: "main-bar", "aria-label": "Main site navigation", tabindex: "-1", ref: (div) => (this.mainBarDiv = div), role: !!this.mainSlotLen &&
17294
- this.threshold >= this.THRESHOLDLIMIT - THRESHOLDBREAKS.main
17295
- ? 'menu'
17296
- : undefined }, (this.hasPromotionSlot ||
17293
+ this.ssoRedirect }, "Change Password")))))))), hAsync("slot", { name: "promotion", onSlotchange: this.assessSlottedContent }), this.myAccData && this.myAccData.urls.logout && (hAsync("div", { class: "login-btn logout-btn" }, hAsync("a", { href: this.myAccData.urls.logout + this.ssoRedirect }, "Logout")))))), hAsync("div", { class: "sticker-trigger" }), hAsync("nano-sticker", { "auto-resize": "false", "break-point-max": "800", quietMode: { h: 600, w: 800 }, part: "sticker" }, hAsync("div", { class: "bars", part: "bars" }, hAsync("nav", { part: "main-bar", class: "main-bar", "aria-label": "Main site navigation", tabindex: "-1", ref: (div) => (this.mainBarDiv = div) }, (this.hasPromotionSlot ||
17297
17294
  !!this.overflowSlotLen ||
17298
17295
  ((this.myAccData || !!this.iconSlotLen) &&
17299
17296
  this.threshold <
@@ -20212,7 +20209,7 @@ class NavItem {
20212
20209
  'nano-global-nav': this.isInGlobalNav,
20213
20210
  'nano-menu-drawer': this.isInMenuDrawer,
20214
20211
  'nano-menu': this.isInMenu,
20215
- }, onBlur: this.handleHostBlur, dir: this.el.ownerDocument.dir === 'rtl' ? 'rtl' : null, onMouseEnter: this.handleMouseEnter, onMouseLeave: this.handleMouseLeave, onClick: this.handleHostClick, role: "menuitem" }, hAsync("div", { class: {
20212
+ }, onBlur: this.handleHostBlur, dir: this.el.ownerDocument.dir === 'rtl' ? 'rtl' : null, onMouseEnter: this.handleMouseEnter, onMouseLeave: this.handleMouseLeave, onClick: this.handleHostClick, role: this.el.closest('[role="menu"]') ? 'menuitem' : undefined }, hAsync("div", { class: {
20216
20213
  'nav-item': true,
20217
20214
  'secondary-open': this.open,
20218
20215
  selected: this.selected,
@@ -23067,9 +23064,11 @@ proto$9.setTranslateX = function (x, is3d) {
23067
23064
  var translateX = this.getPositionValue(x);
23068
23065
  // use 3D tranforms for hardware acceleration on iOS
23069
23066
  // but use 2D when settled, for better font-rendering
23070
- this.slider.style.transform = is3d
23071
- ? 'translate3d(' + translateX + ',0,0)'
23072
- : 'translateX(' + translateX + ')';
23067
+ // this.slider.style.transform = is3d
23068
+ // ? 'translate3d(' + translateX + ',0,0)'
23069
+ // : 'translateX(' + translateX + ')';
23070
+
23071
+ this.slider.style.transform = 'translate3d(' + translateX + ',0,0)';
23073
23072
  };
23074
23073
 
23075
23074
  proto$9.dispatchScrollEvent = function () {
@@ -23274,6 +23273,7 @@ proto$8._create = function () {
23274
23273
  // create viewport & slider
23275
23274
  this.viewport = document.createElement('div');
23276
23275
  this.viewport.className = 'flickity-viewport';
23276
+ this.viewport.part.add('slide-viewport');
23277
23277
  this._createSlider();
23278
23278
 
23279
23279
  if (this.options.resize || this.options.watchCSS) {
@@ -25014,19 +25014,35 @@ PrevNextButton.prototype._create = function () {
25014
25014
  var leftDirection = this.parent.options.rightToLeft ? 1 : -1;
25015
25015
  this.isLeft = this.direction == leftDirection;
25016
25016
 
25017
- var element = (this.element = document.createElement('button'));
25018
- element.className = 'flickity-button flickity-prev-next-button';
25019
- element.className += this.isPrevious ? ' previous' : ' next';
25017
+ var button = (this.element = document.createElement('button'));
25018
+ button.className = 'flickity-button flickity-prev-next-button';
25019
+ button.part.add('navigation-button');
25020
+ if (this.isPrevious) {
25021
+ button.classList.add('previous');
25022
+ button.part.add('navigation-button--previous');
25023
+ } else {
25024
+ button.classList.add('next');
25025
+ button.part.add('navigation-button--next');
25026
+ }
25020
25027
  // prevent button from submitting form http://stackoverflow.com/a/10836076/182183
25021
- element.setAttribute('type', 'button');
25028
+ button.setAttribute('type', 'button');
25022
25029
  // init as disabled
25023
25030
  this.disable();
25024
25031
 
25025
- element.setAttribute('aria-label', this.isPrevious ? 'Previous' : 'Next');
25032
+ button.setAttribute('aria-label', this.isPrevious ? 'Previous' : 'Next');
25033
+
25034
+ const slot = document.createElement('slot');
25035
+ slot.name = this.isPrevious ? 'previous-icon' : 'next-icon';
25036
+ button.appendChild(slot);
25037
+ slot.addEventListener('slotchange', () => {
25038
+ slot.assignedElements({ flatten: true }).forEach((ele) => {
25039
+ ele.removeAttribute('hidden');
25040
+ });
25041
+ });
25026
25042
 
25027
25043
  // create arrow
25028
25044
  var svg = this.createSVG();
25029
- element.appendChild(svg);
25045
+ slot.appendChild(svg);
25030
25046
  // events
25031
25047
  this.parent.on('select', this.update.bind(this));
25032
25048
  this.on('pointerDown', this.parent.childUIPointerDown.bind(this.parent));
@@ -25051,6 +25067,7 @@ PrevNextButton.prototype.createSVG = function () {
25051
25067
  var svg = document.createElementNS(svgURI$1, 'svg');
25052
25068
  svg.setAttribute('class', 'flickity-button-icon');
25053
25069
  svg.setAttribute('viewBox', '0 0 100 100');
25070
+ svg.part.add('navigation-icon');
25054
25071
  var path = document.createElementNS(svgURI$1, 'path');
25055
25072
  var pathMovements = getArrowMovements(this.parent.options.arrowShape);
25056
25073
  path.setAttribute('d', pathMovements);
@@ -25201,6 +25218,8 @@ PageDots.prototype._create = function () {
25201
25218
  // create holder element
25202
25219
  this.holder = document.createElement('ol');
25203
25220
  this.holder.className = 'flickity-page-dots';
25221
+ this.holder.part.add('pagination');
25222
+
25204
25223
  // create dots, array of elements
25205
25224
  this.dots = [];
25206
25225
  // events
@@ -25242,6 +25261,7 @@ PageDots.prototype.addDots = function (count) {
25242
25261
  for (var i = length; i < max; i++) {
25243
25262
  var dot = document.createElement('li');
25244
25263
  dot.classList.add('dot');
25264
+ dot.part.add('pagination-item');
25245
25265
  dot.setAttribute('aria-label', 'Page dot ' + (i + 1));
25246
25266
  fragment.appendChild(dot);
25247
25267
  newDots.push(dot);
@@ -25264,6 +25284,7 @@ PageDots.prototype.updateSelected = function () {
25264
25284
  // remove selected class on previous
25265
25285
  if (this.selectedDot) {
25266
25286
  this.selectedDot.classList.remove('is-selected');
25287
+ this.selectedDot.part.remove('pagination-item--active');
25267
25288
  this.selectedDot.removeAttribute('aria-current');
25268
25289
  }
25269
25290
  // don't proceed if no dots
@@ -25272,6 +25293,7 @@ PageDots.prototype.updateSelected = function () {
25272
25293
  }
25273
25294
  this.selectedDot = this.dots[this.parent.selectedIndex];
25274
25295
  this.selectedDot.classList.add('is-selected');
25296
+ this.selectedDot.part.add('pagination-item--active');
25275
25297
  this.selectedDot.setAttribute('aria-current', 'step');
25276
25298
  };
25277
25299
 
@@ -26101,14 +26123,30 @@ const flickity = Flickity;
26101
26123
 
26102
26124
  const slidesCss = "/*!@:host*/.sc-nano-slides-h{box-sizing:border-box}/*!@*,\n*::before,\n*::after*/*.sc-nano-slides,*.sc-nano-slides::before,*.sc-nano-slides::after{box-sizing:border-box}/*!@[hidden]*/[hidden].sc-nano-slides{display:none !important}/*!@:host*/.sc-nano-slides-h{--dot-color:#ccc;--dot-color-active:var(--nano-color-primary, #007495);--navbtns-icon-color:var(--dot-color-active);--navbtns-bg-color:white;--navbtns-icon-color-disabled:var(--dot-color-active);--navbtns-bg-color-disabled:white;--fsbtn-icon-color:var(--dot-color-active);--fsbtn-bg-color:white;display:block;-webkit-user-select:none;user-select:none;overflow:hidden;transition:opacity 0.2s;opacity:0;max-width:100vw}/*!@:host([ready])*/[ready].sc-nano-slides-h{opacity:1}/*!@.slideshow*/.slideshow.sc-nano-slides{max-height:100%;min-height:inherit;height:inherit;position:relative}/*!@.slideshow.not-ready*/.slideshow.not-ready.sc-nano-slides{max-width:98vw}/*!@.flickity-container*/.flickity-container.sc-nano-slides{opacity:0;transition:opacity 0.2s;display:flex;width:-moz-fit-content;width:fit-content;height:-moz-fit-content;height:fit-content}/*!@.not-ready .flickity-container*/.not-ready.sc-nano-slides .flickity-container.sc-nano-slides{width:-moz-fit-content;width:fit-content;height:-moz-fit-content;height:fit-content}/*!@.flickity-container.slides-ready*/.flickity-container.slides-ready.sc-nano-slides{min-height:inherit;max-height:inherit;height:inherit;width:auto}/*!@[hidden]*/[hidden].sc-nano-slides{display:none !important}/*!@.ui-extras*/.ui-extras.sc-nano-slides{pointer-events:none;position:absolute;block-size:100%;inline-size:100%;inset-block-start:0;inset-inline-start:0}/*!@.ui-extras **/.ui-extras.sc-nano-slides *.sc-nano-slides{pointer-events:all}/*!@.flickity-enabled*/.flickity-enabled.sc-nano-slides{position:relative;opacity:1}/*!@.flickity-enabled:focus*/.flickity-enabled.sc-nano-slides:focus{outline:none}/*!@.flickity-viewport*/.flickity-viewport.sc-nano-slides{overflow:hidden;position:relative;min-block-size:100%;flex:1}/*!@.flickity-slider*/.flickity-slider.sc-nano-slides{position:absolute;inline-size:100%;block-size:100%}/*!@.flickity-enabled.is-draggable*/.flickity-enabled.is-draggable.sc-nano-slides{-webkit-tap-highlight-color:transparent;-webkit-user-select:none;user-select:none}/*!@.flickity-enabled.is-draggable .flickity-viewport*/.flickity-enabled.is-draggable.sc-nano-slides .flickity-viewport.sc-nano-slides{cursor:move;cursor:grab;cursor:grab}/*!@.flickity-enabled.is-draggable .flickity-viewport.is-pointer-down*/.flickity-enabled.is-draggable.sc-nano-slides .flickity-viewport.is-pointer-down.sc-nano-slides{cursor:grabbing}/*!@.flickity-button*/.flickity-button.sc-nano-slides{position:absolute;background:var(--navbtns-bg-color);border:none;color:#333;opacity:0.75}/*!@.flickity-button:hover*/.flickity-button.sc-nano-slides:hover{opacity:1;cursor:pointer}/*!@.flickity-button:focus*/.flickity-button.sc-nano-slides:focus{outline:none;box-shadow:0 0 0 5px #19f}/*!@.flickity-button:active*/.flickity-button.sc-nano-slides:active{opacity:0.6}/*!@.flickity-button:disabled*/.flickity-button.sc-nano-slides:disabled{opacity:0.3;cursor:auto;pointer-events:none;background:var(--navbtns-bg-color-disabled)}/*!@.flickity-button-icon*/.flickity-button-icon.sc-nano-slides{fill:var(--navbtns-icon-color)}/*!@.flickity-button:disabled .flickity-button-icon*/.flickity-button.sc-nano-slides:disabled .flickity-button-icon.sc-nano-slides{fill:var(--navbtns-icon-color-disabled)}/*!@.flickity-prev-next-button*/.flickity-prev-next-button.sc-nano-slides{inset-block-start:50%;inline-size:44px;block-size:44px;border-radius:50%;transform:translateY(-50%)}/*!@.flickity-prev-next-button.previous*/.flickity-prev-next-button.previous.sc-nano-slides{inset-inline-start:10px}/*!@.flickity-prev-next-button.next*/.flickity-prev-next-button.next.sc-nano-slides{inset-inline-end:10px}/*!@.flickity-rtl .flickity-prev-next-button.previous*/.flickity-rtl.sc-nano-slides .flickity-prev-next-button.previous.sc-nano-slides{inset-inline:auto 10px}/*!@.flickity-rtl .flickity-prev-next-button.next*/.flickity-rtl.sc-nano-slides .flickity-prev-next-button.next.sc-nano-slides{inset-inline:10px auto}/*!@.flickity-prev-next-button .flickity-button-icon*/.flickity-prev-next-button.sc-nano-slides .flickity-button-icon.sc-nano-slides{position:absolute;inset-inline-start:20%;inset-block-start:20%;inline-size:60%;block-size:60%}/*!@.flickity-page-dots*/.flickity-page-dots.sc-nano-slides{position:absolute;inline-size:100%;inset-block-end:10px;padding:0;margin:0;list-style:none;text-align:center;line-height:1;z-index:4}/*!@.flickity-rtl .flickity-page-dots*/.flickity-rtl.sc-nano-slides .flickity-page-dots.sc-nano-slides{direction:rtl}/*!@.flickity-page-dots .dot*/.flickity-page-dots.sc-nano-slides .dot.sc-nano-slides{display:inline-block;inline-size:10px;block-size:10px;margin-block:0;margin-inline:8px;border-radius:50%;cursor:pointer;background:var(--dot-color)}/*!@.flickity-page-dots .dot.is-selected*/.flickity-page-dots.sc-nano-slides .dot.is-selected.sc-nano-slides{opacity:1;background:var(--dot-color-active)}/*!@.flickity-enabled.is-fullscreen*/.flickity-enabled.is-fullscreen.sc-nano-slides{position:fixed;inset-inline-start:0;inset-block-start:0;inline-size:100%;block-size:100%;background:rgba(0, 0, 0, 0.9);-webkit-padding-after:35px;padding-block-end:35px;z-index:100}/*!@.flickity-enabled.is-fullscreen .flickity-page-dots*/.flickity-enabled.is-fullscreen.sc-nano-slides .flickity-page-dots.sc-nano-slides{inset-block-end:45px}/*!@html.is-flickity-fullscreen*/html.is-flickity-fullscreen.sc-nano-slides{overflow:hidden}/*!@.flickity-fullscreen-button*/.flickity-fullscreen-button.sc-nano-slides{display:block;inset-inline-end:10px;inset-block-start:10px;inline-size:24px;block-size:24px;border-radius:4px;background:var(--fsbtn-bg-color);fill:var(--fsbtn-icon-color)}/*!@.flickity-rtl .flickity-fullscreen-button*/.flickity-rtl.sc-nano-slides .flickity-fullscreen-button.sc-nano-slides{inset-inline:10px auto}/*!@.flickity-fullscreen-button-exit*/.flickity-fullscreen-button-exit.sc-nano-slides{display:none}/*!@.flickity-enabled.is-fullscreen .flickity-fullscreen-button-exit*/.flickity-enabled.is-fullscreen.sc-nano-slides .flickity-fullscreen-button-exit.sc-nano-slides{display:block}/*!@.flickity-enabled.is-fullscreen .flickity-fullscreen-button-view*/.flickity-enabled.is-fullscreen.sc-nano-slides .flickity-fullscreen-button-view.sc-nano-slides{display:none}/*!@.flickity-fullscreen-button .flickity-button-icon*/.flickity-fullscreen-button.sc-nano-slides .flickity-button-icon.sc-nano-slides{position:absolute;inline-size:16px;block-size:16px;inset-inline-start:4px;inset-block-start:4px}/*!@.flickity-enabled.is-fade .flickity-slider > **/.flickity-enabled.is-fade.sc-nano-slides .flickity-slider.sc-nano-slides>*.sc-nano-slides{pointer-events:none;z-index:0}/*!@.flickity-enabled.is-fade .flickity-slider ::slotted(.is-selected)*/.flickity-enabled.is-fade .flickity-slider .sc-nano-slides-s>.is-selected{pointer-events:auto;z-index:1}";
26103
26125
 
26126
+ const modulo = (num, div) => {
26127
+ return ((num % div) + div) % div;
26128
+ };
26104
26129
  /**
26105
26130
  * The Slides component is a multi-section container. Each section can be swiped or dragged between.
26106
26131
  * It contains any number of Slide components.
26107
26132
  *
26108
26133
  * Uses [Flickity](https://flickity.metafizzy.co/) under the hood.
26109
26134
  *
26110
- * @slot - default slot of nano-slide components
26135
+ * @part base - Wrapper around slides and additional ui elements.
26136
+ * @part slide-container - Wraps all slide elements.
26137
+ * @part slide-viewport - The visible, scrollable area around slide elements.
26138
+ * @part navigation-button - Next / previous navigation buttons.
26139
+ * @part navigation-button--next - the next navigation button.
26140
+ * @part navigation-button--previous - The previous navigation button.
26141
+ * @part navigation-icon - The chevron / arrow icon within a navigation button.
26142
+ * @part pagination - Wraps pagination indicators.
26143
+ * @part pagination-item - A pagination indicator.
26144
+ * @part pagination-item--active - The current, active pagination indicator.
26145
+ *
26146
+ * @slot - default slot of nano-slide components.
26111
26147
  * @slot ui - An absolutely positioned element that will be placed over the slider. Any custom ui can be housed here.
26148
+ * @slot next-icon - Optional next icon to use instead of the default.
26149
+ * @slot previous-icon - Optional previous icon to use instead of the default.
26112
26150
  */
26113
26151
  class Slides {
26114
26152
  constructor(hostRef) {
@@ -26128,12 +26166,25 @@ class Slides {
26128
26166
  this.flickity = new Promise((resolve) => {
26129
26167
  this.readyflickity = resolve;
26130
26168
  });
26131
- this.parralax = async () => {
26169
+ this.parallax = async () => {
26132
26170
  const flkty = await this.flickity;
26133
- flkty.slides.forEach((slide, i) => {
26171
+ flkty.cells.forEach((el, i) => {
26172
+ const cell = el;
26173
+ let flkX = flkty.x;
26174
+ const shiftedPos = cell.x + flkty.slideableWidth * cell.shift;
26134
26175
  const ele = this.childrenEles[i];
26135
- const x = ((slide.target + flkty.x) * -1) / 3;
26136
- ele.style['transform'] = 'translateX(' + x + 'px)';
26176
+ if (flkty.options.wrapAround && flkty.cells.length > 1) {
26177
+ flkX = modulo(flkX, flkty.slideableWidth);
26178
+ flkX = flkX - flkty.slideableWidth;
26179
+ }
26180
+ let x = ((cell.target + flkX) * -1) / 3;
26181
+ if (cell.shift < 0) {
26182
+ x = x + Math.abs(shiftedPos) * 1.3333;
26183
+ }
26184
+ else if (cell.shift > 0) {
26185
+ x = ((cell.target + (flkX + shiftedPos)) * -1) / 3;
26186
+ }
26187
+ ele.style.transform = 'translate3d(' + x + 'px, 0, 0)';
26137
26188
  });
26138
26189
  };
26139
26190
  this.handleFullscreen = (isFullScreen) => {
@@ -26194,7 +26245,7 @@ class Slides {
26194
26245
  slide.style['left'] = undefined;
26195
26246
  });
26196
26247
  if (oldAnim === 'parallax') {
26197
- flkty.off('scroll', this.parralax);
26248
+ flkty.off('scroll', this.parallax);
26198
26249
  slides.forEach((_, i) => {
26199
26250
  if (this.childrenEles && this.childrenEles[i])
26200
26251
  this.childrenEles[i].style['transform'] = undefined;
@@ -26208,7 +26259,7 @@ class Slides {
26208
26259
  break;
26209
26260
  case 'parallax':
26210
26261
  this.options = { fade: false, percentPosition: false };
26211
- flkty.on('scroll', this.parralax);
26262
+ flkty.on('scroll', this.parallax);
26212
26263
  break;
26213
26264
  default:
26214
26265
  this.options = { fade: false, percentPosition: true };
@@ -26286,30 +26337,22 @@ class Slides {
26286
26337
  const flickity = await this.getflickity();
26287
26338
  flickity.previous(instant, wrap);
26288
26339
  }
26289
- /**
26290
- * Get the index of the active slide.
26291
- */
26340
+ /** Get the index of the active slide. */
26292
26341
  async getActiveIndex() {
26293
26342
  const flickity = await this.getflickity();
26294
26343
  return flickity.selectedIndex;
26295
26344
  }
26296
- /**
26297
- * Get the total number of slides.
26298
- */
26345
+ /** Get the total number of slides. */
26299
26346
  async length() {
26300
26347
  const flickity = await this.getflickity();
26301
26348
  return flickity.slides.length;
26302
26349
  }
26303
- /**
26304
- * Get whether or not the current slide is the last slide.
26305
- */
26350
+ /** Get whether or not the current slide is the last slide. */
26306
26351
  async isEnd() {
26307
26352
  const flickity = await this.getflickity();
26308
26353
  return flickity.selectedIndex === flickity.slides.length - 1;
26309
26354
  }
26310
- /**
26311
- * Get whether or not the current slide is the first slide.
26312
- */
26355
+ /** Get whether or not the current slide is the first slide. */
26313
26356
  async isBeginning() {
26314
26357
  const flickity = await this.getflickity();
26315
26358
  return flickity.selectedIndex === 0;
@@ -26324,9 +26367,7 @@ class Slides {
26324
26367
  this.options = { autoPlay: time };
26325
26368
  setTimeout(() => flickity.playPlayer());
26326
26369
  }
26327
- /**
26328
- * Stop auto play.
26329
- */
26370
+ /** Stop auto play. */
26330
26371
  async stopAutoplay() {
26331
26372
  const flickity = await this.getflickity();
26332
26373
  flickity.stopPlayer();
@@ -26406,7 +26447,7 @@ class Slides {
26406
26447
  this.ready = true;
26407
26448
  if (!window['ResizeObserver'])
26408
26449
  return;
26409
- // just boots and brances to make sure it's the correct size oninit
26450
+ // just boots and braces to make sure it's the correct size oninit
26410
26451
  const ro = (this.resizeO = new ResizeObserver(() => {
26411
26452
  flick.resize();
26412
26453
  // this.resizeO.disconnect();
@@ -26485,11 +26526,11 @@ class Slides {
26485
26526
  slideshow: true,
26486
26527
  ready: this.ready,
26487
26528
  'not-ready': !this.ready,
26488
- } }, hAsync("div", { ref: (div) => (this.flickityEl = div), class: {
26529
+ }, part: "base" }, hAsync("div", { ref: (div) => (this.flickityEl = div), class: {
26489
26530
  'flickity-container': true,
26490
26531
  'slides-ready': this.slidesReady,
26491
26532
  'slides-not-ready': !this.slidesReady,
26492
- } }, hAsync("slot", null)), hAsync("div", { class: "ui-extras" }, hAsync("slot", { name: "ui" })))));
26533
+ }, part: "slide-container" }, hAsync("slot", null)), hAsync("div", { class: "ui-extras" }, hAsync("slot", { name: "ui" })))));
26493
26534
  }
26494
26535
  get host() { return getElement(this); }
26495
26536
  static get watchers() { return {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nanoporetech-digital/components",
3
- "version": "5.4.2",
3
+ "version": "5.5.1",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://git.oxfordnanolabs.local/Digital/nano-components"
@@ -131,7 +131,7 @@
131
131
  "nanopore",
132
132
  "digital"
133
133
  ],
134
- "gitHead": "351cba2d67b5997430819509ffb41490ca07e106",
134
+ "gitHead": "0b7b272095323bc7e95104a214b1f53bc028c8c5",
135
135
  "volta": {
136
136
  "node": "14.18.1",
137
137
  "npm": "8.6.0"
@@ -1 +0,0 @@
1
- {"file":"table.worker-1b295406.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":[],"sourcesContent":[],"version":3}
@@ -1 +0,0 @@
1
- {"file":"table.worker-8356a40e.js","mappings":";;;;;;;;;;;;;;;;;;;","names":[],"sources":[],"sourcesContent":[],"version":3}