@aotearoan/neon 19.0.1 → 19.0.2
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.
- package/dist/components/presentation/image-carousel/NeonImageCarousel.cjs.js +1 -1
- package/dist/components/presentation/image-carousel/NeonImageCarousel.cjs.js.map +1 -1
- package/dist/components/presentation/image-carousel/NeonImageCarousel.es.js +16 -12
- package/dist/components/presentation/image-carousel/NeonImageCarousel.es.js.map +1 -1
- package/dist/components/presentation/image-carousel/NeonImageCarousel.vue.cjs.js +1 -1
- package/dist/components/presentation/image-carousel/NeonImageCarousel.vue.cjs.js.map +1 -1
- package/dist/components/presentation/image-carousel/NeonImageCarousel.vue.es.js +27 -26
- package/dist/components/presentation/image-carousel/NeonImageCarousel.vue.es.js.map +1 -1
- package/dist/src/components/presentation/image-carousel/NeonImageCarousel.d.ts +15 -0
- package/package.json +1 -1
- package/src/sass/components/_search.scss +1 -1
- package/src/sass/variables.scss +6 -6
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";const o=require("vue"),b=require("../../navigation/link/NeonLink.vue.cjs.js"),I=require("../../user-input/button/NeonButton.vue.cjs.js"),L=o.defineComponent({name:"NeonImageCarousel",components:{NeonButton:I,NeonLink:b},props:{images:{type:Array,required:!0},imageCountLabel:{type:String,default:void 0},previousLabel:{type:String,default:"Previous"},nextLabel:{type:String,default:"Next"}},emits:["current-image"],setup(
|
|
1
|
+
"use strict";const o=require("vue"),b=require("../../navigation/link/NeonLink.vue.cjs.js"),I=require("../../user-input/button/NeonButton.vue.cjs.js"),L=o.defineComponent({name:"NeonImageCarousel",components:{NeonButton:I,NeonLink:b},props:{images:{type:Array,required:!0},imageCountLabel:{type:String,default:void 0},hideLabel:{type:Boolean,default:!1},previousLabel:{type:String,default:"Previous"},nextLabel:{type:String,default:"Next"}},emits:["current-image"],setup(a,{emit:u}){const r=o.ref(!1),n=o.ref(0),t=o.ref(null),l=o.ref([]),i=o.ref([]),c=e=>{e!==n.value&&(n.value=e,u("current-image",e))},s=e=>{t.value&&a.images.length>0&&(c(e),t.value.scrollTo(t.value.clientWidth*e,0))},f=()=>{n.value<a.images.length-1&&s(n.value+1)},m=()=>{n.value!==0&&s(n.value-1)};return o.onMounted(()=>{const e={root:t.value,rootMargin:"0px",threshold:.6};i.value=l.value.map((g,p)=>{const v=new IntersectionObserver(d=>{d.forEach(h=>{r.value&&h.isIntersecting&&c(p)})},e);return v.observe(g),v}),setTimeout(()=>{t.value&&t.value.scrollLeft!==0&&(t.value.scrollLeft=0),r.value=!0},50)}),o.onUnmounted(()=>{i.value.forEach(e=>e.disconnect())}),{emit:u,currentImage:n,carouselItem:l,carouselItems:t,initialised:r,next:f,previous:m,scrollTo:s}}});module.exports=L;
|
|
2
2
|
//# sourceMappingURL=NeonImageCarousel.cjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NeonImageCarousel.cjs.js","sources":["../../../../src/components/presentation/image-carousel/NeonImageCarousel.ts?vue&type=script&src=true&lang.ts"],"sourcesContent":["import { defineComponent, onMounted, onUnmounted, ref } from 'vue';\nimport type { NeonCarouselImage } from '@/common/models/NeonCarouselImage';\nimport NeonLink from '@/components/navigation/link/NeonLink.vue';\nimport NeonButton from '@/components/user-input/button/NeonButton.vue';\n\n/**\n * <p>\n * The <strong>NeonImageCarousel</strong> is used to display a carousel of images for the user to swipe\n * through. NOTE: It is recommended to explicitly set the width & height of the carousel via CSS, this will\n * ensure it will not be impacted by images with different aspect ratios. Images are automatically resized to fit the\n * carousel dimensions.\n * </p>\n */\nexport default defineComponent({\n name: 'NeonImageCarousel',\n components: {\n NeonButton,\n NeonLink,\n },\n props: {\n /**\n * The images to be displayed in the carousel.\n */\n images: { type: Array as () => Array<NeonCarouselImage>, required: true },\n /**\n * Provide an alternative image count label. This can be useful for translations. The default is e.g.\n * <em>2 images</em>.\n */\n imageCountLabel: { type: String, default: undefined },\n /**\n * Provide an alternative label for the Previous button.\n */\n previousLabel: { type: String, default: 'Previous' },\n /**\n * Provide an alternative label for the Next button.\n */\n nextLabel: { type: String, default: 'Next' },\n },\n emits: [\n /**\n * The index of the currently visible image.\n *\n * @type {number}\n */\n 'current-image',\n ],\n setup(props, { emit }) {\n const initialised = ref<boolean>(false);\n const currentImage = ref<number>(0);\n const carouselItems = ref<HTMLUListElement | null>(null);\n const carouselItem = ref<Array<HTMLLIElement>>([]);\n const observers = ref<Array<IntersectionObserver>>([]);\n\n const changeImage = (index: number) => {\n if (index !== currentImage.value) {\n currentImage.value = index;\n emit('current-image', index);\n }\n };\n\n const scrollTo = (index: number) => {\n if (carouselItems.value && props.images.length > 0) {\n changeImage(index);\n carouselItems.value.scrollTo(carouselItems.value.clientWidth * index, 0);\n }\n };\n\n const next = () => {\n if (currentImage.value < props.images.length - 1) {\n scrollTo(currentImage.value + 1);\n }\n };\n\n const previous = () => {\n if (currentImage.value !== 0) {\n scrollTo(currentImage.value - 1);\n }\n };\n\n onMounted(() => {\n const options = {\n root: carouselItems.value,\n rootMargin: '0px',\n threshold: 0.6,\n };\n\n observers.value = carouselItem.value.map((el, index) => {\n const obs = new IntersectionObserver((entries) => {\n entries.forEach((entry) => {\n // filter out the observations on initialization\n if (initialised.value && entry.isIntersecting) {\n changeImage(index);\n }\n });\n }, options);\n obs.observe(el);\n\n return obs;\n });\n\n setTimeout(() => {\n // initialise scroll position to first element\n if (carouselItems.value && carouselItems.value.scrollLeft !== 0) {\n carouselItems.value.scrollLeft = 0;\n }\n initialised.value = true;\n }, 50);\n });\n\n onUnmounted(() => {\n observers.value.forEach((observer) => observer.disconnect());\n });\n\n return {\n emit,\n currentImage,\n carouselItem,\n carouselItems,\n initialised,\n next,\n previous,\n scrollTo,\n };\n },\n});\n"],"names":["_sfc_main","defineComponent","NeonButton","NeonLink","props","emit","initialised","ref","currentImage","carouselItems","carouselItem","observers","changeImage","index","scrollTo","next","previous","onMounted","options","el","obs","entries","entry","onUnmounted","observer"],"mappings":"sJAaAA,EAAeC,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GK,CAAO,EACV,OAAAE,EAAI,QAAQD,CAAE,EAEPC,CACT,CAAC,EAED,WAAW,IAAM,CAEXX,EAAc,OAASA,EAAc,MAAM,aAAe,IAC5DA,EAAc,MAAM,WAAa,GAEnCH,EAAY,MAAQ,EACtB,EAAG,EAAE,CACP,CAAC,EAEDiB,EAAAA,YAAY,IAAM,CAChBZ,EAAU,MAAM,QAASa,GAAaA,EAAS,YAAY,CAC7D,CAAC,EAEM,CACL,KAAAnB,EACA,aAAAG,EACA,aAAAE,EACA,cAAAD,EACA,YAAAH,EACA,KAAAS,EACA,SAAAC,EACA,SAAAF,CAAA,CAEJ,CACF,CAAC"}
|
|
1
|
+
{"version":3,"file":"NeonImageCarousel.cjs.js","sources":["../../../../src/components/presentation/image-carousel/NeonImageCarousel.ts?vue&type=script&src=true&lang.ts"],"sourcesContent":["import { defineComponent, onMounted, onUnmounted, ref } from 'vue';\nimport type { NeonCarouselImage } from '@/common/models/NeonCarouselImage';\nimport NeonLink from '@/components/navigation/link/NeonLink.vue';\nimport NeonButton from '@/components/user-input/button/NeonButton.vue';\n\n/**\n * <p>\n * The <strong>NeonImageCarousel</strong> is used to display a carousel of images for the user to swipe\n * through. NOTE: It is recommended to explicitly set the width & height of the carousel via CSS, this will\n * ensure it will not be impacted by images with different aspect ratios. Images are automatically resized to fit the\n * carousel dimensions.\n * </p>\n */\nexport default defineComponent({\n name: 'NeonImageCarousel',\n components: {\n NeonButton,\n NeonLink,\n },\n props: {\n /**\n * The images to be displayed in the carousel.\n */\n images: { type: Array as () => Array<NeonCarouselImage>, required: true },\n /**\n * Provide an alternative image count label. This can be useful for translations. The default is e.g.\n * <em>2 images</em>.\n */\n imageCountLabel: { type: String, default: undefined },\n /**\n * Hide the label under the dot navigation.\n */\n hideLabel: { type: Boolean, default: false },\n /**\n * Provide an alternative label for the Previous button.\n */\n previousLabel: { type: String, default: 'Previous' },\n /**\n * Provide an alternative label for the Next button.\n */\n nextLabel: { type: String, default: 'Next' },\n },\n emits: [\n /**\n * The index of the currently visible image.\n *\n * @type {number}\n */\n 'current-image',\n ],\n setup(props, { emit }) {\n const initialised = ref<boolean>(false);\n const currentImage = ref<number>(0);\n const carouselItems = ref<HTMLUListElement | null>(null);\n const carouselItem = ref<Array<HTMLLIElement>>([]);\n const observers = ref<Array<IntersectionObserver>>([]);\n\n const changeImage = (index: number) => {\n if (index !== currentImage.value) {\n currentImage.value = index;\n emit('current-image', index);\n }\n };\n\n const scrollTo = (index: number) => {\n if (carouselItems.value && props.images.length > 0) {\n changeImage(index);\n carouselItems.value.scrollTo(carouselItems.value.clientWidth * index, 0);\n }\n };\n\n const next = () => {\n if (currentImage.value < props.images.length - 1) {\n scrollTo(currentImage.value + 1);\n }\n };\n\n const previous = () => {\n if (currentImage.value !== 0) {\n scrollTo(currentImage.value - 1);\n }\n };\n\n onMounted(() => {\n const options = {\n root: carouselItems.value,\n rootMargin: '0px',\n threshold: 0.6,\n };\n\n observers.value = carouselItem.value.map((el, index) => {\n const obs = new IntersectionObserver((entries) => {\n entries.forEach((entry) => {\n // filter out the observations on initialization\n if (initialised.value && entry.isIntersecting) {\n changeImage(index);\n }\n });\n }, options);\n obs.observe(el);\n\n return obs;\n });\n\n setTimeout(() => {\n // initialise scroll position to first element\n if (carouselItems.value && carouselItems.value.scrollLeft !== 0) {\n carouselItems.value.scrollLeft = 0;\n }\n initialised.value = true;\n }, 50);\n });\n\n onUnmounted(() => {\n observers.value.forEach((observer) => observer.disconnect());\n });\n\n return {\n emit,\n currentImage,\n carouselItem,\n carouselItems,\n initialised,\n next,\n previous,\n scrollTo,\n };\n },\n});\n"],"names":["_sfc_main","defineComponent","NeonButton","NeonLink","props","emit","initialised","ref","currentImage","carouselItems","carouselItem","observers","changeImage","index","scrollTo","next","previous","onMounted","options","el","obs","entries","entry","onUnmounted","observer"],"mappings":"sJAaAA,EAAeC,kBAAgB,CAC7B,KAAM,oBACN,WAAY,CACV,WAAAC,EACA,SAAAC,CAAA,EAEF,MAAO,CAIL,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E,EAEPC,CACT,CAAC,EAED,WAAW,IAAM,CAEXX,EAAc,OAASA,EAAc,MAAM,aAAe,IAC5DA,EAAc,MAAM,WAAa,GAEnCH,EAAY,MAAQ,EACtB,EAAG,EAAE,CACP,CAAC,EAEDiB,EAAAA,YAAY,IAAM,CAChBZ,EAAU,MAAM,QAASa,GAAaA,EAAS,YAAY,CAC7D,CAAC,EAEM,CACL,KAAAnB,EACA,aAAAG,EACA,aAAAE,EACA,cAAAD,EACA,YAAAH,EACA,KAAAS,EACA,SAAAC,EACA,SAAAF,CAAA,CAEJ,CACF,CAAC"}
|
|
@@ -17,6 +17,10 @@ const x = b({
|
|
|
17
17
|
* <em>2 images</em>.
|
|
18
18
|
*/
|
|
19
19
|
imageCountLabel: { type: String, default: void 0 },
|
|
20
|
+
/**
|
|
21
|
+
* Hide the label under the dot navigation.
|
|
22
|
+
*/
|
|
23
|
+
hideLabel: { type: Boolean, default: !1 },
|
|
20
24
|
/**
|
|
21
25
|
* Provide an alternative label for the Previous button.
|
|
22
26
|
*/
|
|
@@ -34,15 +38,15 @@ const x = b({
|
|
|
34
38
|
*/
|
|
35
39
|
"current-image"
|
|
36
40
|
],
|
|
37
|
-
setup(
|
|
38
|
-
const
|
|
39
|
-
e !== o.value && (o.value = e,
|
|
40
|
-
},
|
|
41
|
-
t.value &&
|
|
41
|
+
setup(l, { emit: s }) {
|
|
42
|
+
const a = n(!1), o = n(0), t = n(null), u = n([]), i = n([]), c = (e) => {
|
|
43
|
+
e !== o.value && (o.value = e, s("current-image", e));
|
|
44
|
+
}, r = (e) => {
|
|
45
|
+
t.value && l.images.length > 0 && (c(e), t.value.scrollTo(t.value.clientWidth * e, 0));
|
|
42
46
|
}, m = () => {
|
|
43
|
-
o.value <
|
|
47
|
+
o.value < l.images.length - 1 && r(o.value + 1);
|
|
44
48
|
}, f = () => {
|
|
45
|
-
o.value !== 0 &&
|
|
49
|
+
o.value !== 0 && r(o.value - 1);
|
|
46
50
|
};
|
|
47
51
|
return I(() => {
|
|
48
52
|
const e = {
|
|
@@ -53,24 +57,24 @@ const x = b({
|
|
|
53
57
|
i.value = u.value.map((g, p) => {
|
|
54
58
|
const v = new IntersectionObserver((d) => {
|
|
55
59
|
d.forEach((h) => {
|
|
56
|
-
|
|
60
|
+
a.value && h.isIntersecting && c(p);
|
|
57
61
|
});
|
|
58
62
|
}, e);
|
|
59
63
|
return v.observe(g), v;
|
|
60
64
|
}), setTimeout(() => {
|
|
61
|
-
t.value && t.value.scrollLeft !== 0 && (t.value.scrollLeft = 0),
|
|
65
|
+
t.value && t.value.scrollLeft !== 0 && (t.value.scrollLeft = 0), a.value = !0;
|
|
62
66
|
}, 50);
|
|
63
67
|
}), L(() => {
|
|
64
68
|
i.value.forEach((e) => e.disconnect());
|
|
65
69
|
}), {
|
|
66
|
-
emit:
|
|
70
|
+
emit: s,
|
|
67
71
|
currentImage: o,
|
|
68
72
|
carouselItem: u,
|
|
69
73
|
carouselItems: t,
|
|
70
|
-
initialised:
|
|
74
|
+
initialised: a,
|
|
71
75
|
next: m,
|
|
72
76
|
previous: f,
|
|
73
|
-
scrollTo:
|
|
77
|
+
scrollTo: r
|
|
74
78
|
};
|
|
75
79
|
}
|
|
76
80
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NeonImageCarousel.es.js","sources":["../../../../src/components/presentation/image-carousel/NeonImageCarousel.ts?vue&type=script&src=true&lang.ts"],"sourcesContent":["import { defineComponent, onMounted, onUnmounted, ref } from 'vue';\nimport type { NeonCarouselImage } from '@/common/models/NeonCarouselImage';\nimport NeonLink from '@/components/navigation/link/NeonLink.vue';\nimport NeonButton from '@/components/user-input/button/NeonButton.vue';\n\n/**\n * <p>\n * The <strong>NeonImageCarousel</strong> is used to display a carousel of images for the user to swipe\n * through. NOTE: It is recommended to explicitly set the width & height of the carousel via CSS, this will\n * ensure it will not be impacted by images with different aspect ratios. Images are automatically resized to fit the\n * carousel dimensions.\n * </p>\n */\nexport default defineComponent({\n name: 'NeonImageCarousel',\n components: {\n NeonButton,\n NeonLink,\n },\n props: {\n /**\n * The images to be displayed in the carousel.\n */\n images: { type: Array as () => Array<NeonCarouselImage>, required: true },\n /**\n * Provide an alternative image count label. This can be useful for translations. The default is e.g.\n * <em>2 images</em>.\n */\n imageCountLabel: { type: String, default: undefined },\n /**\n * Provide an alternative label for the Previous button.\n */\n previousLabel: { type: String, default: 'Previous' },\n /**\n * Provide an alternative label for the Next button.\n */\n nextLabel: { type: String, default: 'Next' },\n },\n emits: [\n /**\n * The index of the currently visible image.\n *\n * @type {number}\n */\n 'current-image',\n ],\n setup(props, { emit }) {\n const initialised = ref<boolean>(false);\n const currentImage = ref<number>(0);\n const carouselItems = ref<HTMLUListElement | null>(null);\n const carouselItem = ref<Array<HTMLLIElement>>([]);\n const observers = ref<Array<IntersectionObserver>>([]);\n\n const changeImage = (index: number) => {\n if (index !== currentImage.value) {\n currentImage.value = index;\n emit('current-image', index);\n }\n };\n\n const scrollTo = (index: number) => {\n if (carouselItems.value && props.images.length > 0) {\n changeImage(index);\n carouselItems.value.scrollTo(carouselItems.value.clientWidth * index, 0);\n }\n };\n\n const next = () => {\n if (currentImage.value < props.images.length - 1) {\n scrollTo(currentImage.value + 1);\n }\n };\n\n const previous = () => {\n if (currentImage.value !== 0) {\n scrollTo(currentImage.value - 1);\n }\n };\n\n onMounted(() => {\n const options = {\n root: carouselItems.value,\n rootMargin: '0px',\n threshold: 0.6,\n };\n\n observers.value = carouselItem.value.map((el, index) => {\n const obs = new IntersectionObserver((entries) => {\n entries.forEach((entry) => {\n // filter out the observations on initialization\n if (initialised.value && entry.isIntersecting) {\n changeImage(index);\n }\n });\n }, options);\n obs.observe(el);\n\n return obs;\n });\n\n setTimeout(() => {\n // initialise scroll position to first element\n if (carouselItems.value && carouselItems.value.scrollLeft !== 0) {\n carouselItems.value.scrollLeft = 0;\n }\n initialised.value = true;\n }, 50);\n });\n\n onUnmounted(() => {\n observers.value.forEach((observer) => observer.disconnect());\n });\n\n return {\n emit,\n currentImage,\n carouselItem,\n carouselItems,\n initialised,\n next,\n previous,\n scrollTo,\n };\n },\n});\n"],"names":["_sfc_main","defineComponent","NeonButton","NeonLink","props","emit","initialised","ref","currentImage","carouselItems","carouselItem","observers","changeImage","index","scrollTo","next","previous","onMounted","options","el","obs","entries","entry","onUnmounted","observer"],"mappings":";;;AAaA,MAAAA,IAAeC,EAAgB;AAAA,EAC7B,MAAM;AAAA,EACN,YAAY;AAAA,IACV,YAAAC;AAAA,IACA,UAAAC;AAAA,EAAA;AAAA,EAEF,OAAO;AAAA;AAAA;AAAA;AAAA,IAIL,QAAQ,EAAE,MAAM,OAAyC,UAAU,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAKnE,iBAAiB,EAAE,MAAM,QAAQ,SAAS,OAAA;AAAA;AAAA;AAAA;AAAA,IAI1C,eAAe,EAAE,MAAM,QAAQ,SAAS,WAAA;AAAA;AAAA;AAAA;AAAA,IAIxC,WAAW,EAAE,MAAM,QAAQ,SAAS,OAAA;AAAA,EAAO;AAAA,EAE7C,OAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAML;AAAA,EAAA;AAAA,EAEF,MAAMC,GAAO,EAAE,MAAAC,KAAQ;AACrB,UAAMC,IAAcC,EAAa,EAAK,GAChCC,IAAeD,EAAY,CAAC,GAC5BE,IAAgBF,EAA6B,IAAI,GACjDG,IAAeH,EAA0B,EAAE,GAC3CI,IAAYJ,EAAiC,EAAE,GAE/CK,IAAc,CAACC,MAAkB;AACrC,MAAIA,MAAUL,EAAa,UACzBA,EAAa,QAAQK,GACrBR,EAAK,iBAAiBQ,CAAK;AAAA,IAE/B,GAEMC,IAAW,CAACD,MAAkB;AAClC,MAAIJ,EAAc,SAASL,EAAM,OAAO,SAAS,MAC/CQ,EAAYC,CAAK,GACjBJ,EAAc,MAAM,SAASA,EAAc,MAAM,cAAcI,GAAO,CAAC;AAAA,IAE3E,GAEME,IAAO,MAAM;AACjB,MAAIP,EAAa,QAAQJ,EAAM,OAAO,SAAS,KAC7CU,EAASN,EAAa,QAAQ,CAAC;AAAA,IAEnC,GAEMQ,IAAW,MAAM;AACrB,MAAIR,EAAa,UAAU,KACzBM,EAASN,EAAa,QAAQ,CAAC;AAAA,IAEnC;AAEA,WAAAS,EAAU,MAAM;AACd,YAAMC,IAAU;AAAA,QACd,MAAMT,EAAc;AAAA,QACpB,YAAY;AAAA,QACZ,WAAW;AAAA,MAAA;AAGb,MAAAE,EAAU,QAAQD,EAAa,MAAM,IAAI,CAACS,GAAIN,MAAU;AACtD,cAAMO,IAAM,IAAI,qBAAqB,CAACC,MAAY;AAChD,UAAAA,EAAQ,QAAQ,CAACC,MAAU;AAEzB,YAAIhB,EAAY,SAASgB,EAAM,kBAC7BV,EAAYC,CAAK;AAAA,UAErB,CAAC;AAAA,QACH,GAAGK,CAAO;AACV,eAAAE,EAAI,QAAQD,CAAE,GAEPC;AAAA,MACT,CAAC,GAED,WAAW,MAAM;AAEf,QAAIX,EAAc,SAASA,EAAc,MAAM,eAAe,MAC5DA,EAAc,MAAM,aAAa,IAEnCH,EAAY,QAAQ;AAAA,MACtB,GAAG,EAAE;AAAA,IACP,CAAC,GAEDiB,EAAY,MAAM;AAChB,MAAAZ,EAAU,MAAM,QAAQ,CAACa,MAAaA,EAAS,YAAY;AAAA,IAC7D,CAAC,GAEM;AAAA,MACL,MAAAnB;AAAA,MACA,cAAAG;AAAA,MACA,cAAAE;AAAA,MACA,eAAAD;AAAA,MACA,aAAAH;AAAA,MACA,MAAAS;AAAA,MACA,UAAAC;AAAA,MACA,UAAAF;AAAA,IAAA;AAAA,EAEJ;AACF,CAAC;"}
|
|
1
|
+
{"version":3,"file":"NeonImageCarousel.es.js","sources":["../../../../src/components/presentation/image-carousel/NeonImageCarousel.ts?vue&type=script&src=true&lang.ts"],"sourcesContent":["import { defineComponent, onMounted, onUnmounted, ref } from 'vue';\nimport type { NeonCarouselImage } from '@/common/models/NeonCarouselImage';\nimport NeonLink from '@/components/navigation/link/NeonLink.vue';\nimport NeonButton from '@/components/user-input/button/NeonButton.vue';\n\n/**\n * <p>\n * The <strong>NeonImageCarousel</strong> is used to display a carousel of images for the user to swipe\n * through. NOTE: It is recommended to explicitly set the width & height of the carousel via CSS, this will\n * ensure it will not be impacted by images with different aspect ratios. Images are automatically resized to fit the\n * carousel dimensions.\n * </p>\n */\nexport default defineComponent({\n name: 'NeonImageCarousel',\n components: {\n NeonButton,\n NeonLink,\n },\n props: {\n /**\n * The images to be displayed in the carousel.\n */\n images: { type: Array as () => Array<NeonCarouselImage>, required: true },\n /**\n * Provide an alternative image count label. This can be useful for translations. The default is e.g.\n * <em>2 images</em>.\n */\n imageCountLabel: { type: String, default: undefined },\n /**\n * Hide the label under the dot navigation.\n */\n hideLabel: { type: Boolean, default: false },\n /**\n * Provide an alternative label for the Previous button.\n */\n previousLabel: { type: String, default: 'Previous' },\n /**\n * Provide an alternative label for the Next button.\n */\n nextLabel: { type: String, default: 'Next' },\n },\n emits: [\n /**\n * The index of the currently visible image.\n *\n * @type {number}\n */\n 'current-image',\n ],\n setup(props, { emit }) {\n const initialised = ref<boolean>(false);\n const currentImage = ref<number>(0);\n const carouselItems = ref<HTMLUListElement | null>(null);\n const carouselItem = ref<Array<HTMLLIElement>>([]);\n const observers = ref<Array<IntersectionObserver>>([]);\n\n const changeImage = (index: number) => {\n if (index !== currentImage.value) {\n currentImage.value = index;\n emit('current-image', index);\n }\n };\n\n const scrollTo = (index: number) => {\n if (carouselItems.value && props.images.length > 0) {\n changeImage(index);\n carouselItems.value.scrollTo(carouselItems.value.clientWidth * index, 0);\n }\n };\n\n const next = () => {\n if (currentImage.value < props.images.length - 1) {\n scrollTo(currentImage.value + 1);\n }\n };\n\n const previous = () => {\n if (currentImage.value !== 0) {\n scrollTo(currentImage.value - 1);\n }\n };\n\n onMounted(() => {\n const options = {\n root: carouselItems.value,\n rootMargin: '0px',\n threshold: 0.6,\n };\n\n observers.value = carouselItem.value.map((el, index) => {\n const obs = new IntersectionObserver((entries) => {\n entries.forEach((entry) => {\n // filter out the observations on initialization\n if (initialised.value && entry.isIntersecting) {\n changeImage(index);\n }\n });\n }, options);\n obs.observe(el);\n\n return obs;\n });\n\n setTimeout(() => {\n // initialise scroll position to first element\n if (carouselItems.value && carouselItems.value.scrollLeft !== 0) {\n carouselItems.value.scrollLeft = 0;\n }\n initialised.value = true;\n }, 50);\n });\n\n onUnmounted(() => {\n observers.value.forEach((observer) => observer.disconnect());\n });\n\n return {\n emit,\n currentImage,\n carouselItem,\n carouselItems,\n initialised,\n next,\n previous,\n scrollTo,\n };\n },\n});\n"],"names":["_sfc_main","defineComponent","NeonButton","NeonLink","props","emit","initialised","ref","currentImage","carouselItems","carouselItem","observers","changeImage","index","scrollTo","next","previous","onMounted","options","el","obs","entries","entry","onUnmounted","observer"],"mappings":";;;AAaA,MAAAA,IAAeC,EAAgB;AAAA,EAC7B,MAAM;AAAA,EACN,YAAY;AAAA,IACV,YAAAC;AAAA,IACA,UAAAC;AAAA,EAAA;AAAA,EAEF,OAAO;AAAA;AAAA;AAAA;AAAA,IAIL,QAAQ,EAAE,MAAM,OAAyC,UAAU,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAKnE,iBAAiB,EAAE,MAAM,QAAQ,SAAS,OAAA;AAAA;AAAA;AAAA;AAAA,IAI1C,WAAW,EAAE,MAAM,SAAS,SAAS,GAAA;AAAA;AAAA;AAAA;AAAA,IAIrC,eAAe,EAAE,MAAM,QAAQ,SAAS,WAAA;AAAA;AAAA;AAAA;AAAA,IAIxC,WAAW,EAAE,MAAM,QAAQ,SAAS,OAAA;AAAA,EAAO;AAAA,EAE7C,OAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAML;AAAA,EAAA;AAAA,EAEF,MAAMC,GAAO,EAAE,MAAAC,KAAQ;AACrB,UAAMC,IAAcC,EAAa,EAAK,GAChCC,IAAeD,EAAY,CAAC,GAC5BE,IAAgBF,EAA6B,IAAI,GACjDG,IAAeH,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cAAAG;AAAA,MACA,cAAAE;AAAA,MACA,eAAAD;AAAA,MACA,aAAAH;AAAA,MACA,MAAAS;AAAA,MACA,UAAAC;AAAA,MACA,UAAAF;AAAA,IAAA;AAAA,EAEJ;AACF,CAAC;"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";const i=require("./NeonImageCarousel.cjs.js"),e=require("vue"),c=require("../../../_virtual/_plugin-vue_export-helper.cjs.js"),u={class:"neon-image-carousel__container",tabindex:"-1"},m={ref:"carouselItems",class:"no-style neon-image-carousel__items"},d=["alt","src"],g={class:"neon-image-carousel__nav",tabindex:"-1"},p=["onClick"],_={class:"neon-image-carousel__label",tabindex:"-1"};function v(n,l,
|
|
1
|
+
"use strict";const i=require("./NeonImageCarousel.cjs.js"),e=require("vue"),c=require("../../../_virtual/_plugin-vue_export-helper.cjs.js"),u={class:"neon-image-carousel__container",tabindex:"-1"},m={ref:"carouselItems",class:"no-style neon-image-carousel__items"},d=["alt","src"],g={class:"neon-image-carousel__nav",tabindex:"-1"},p=["onClick"],_={key:0,class:"neon-image-carousel__label",tabindex:"-1"};function v(n,l,b,h,y,C){const r=e.resolveComponent("neon-button"),a=e.resolveComponent("neon-link");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass([{"neon-image-carousel--initialised":n.initialised},"neon-image-carousel"]),tabindex:"0",onKeydown:[l[0]||(l[0]=e.withKeys(e.withModifiers((...o)=>n.previous&&n.previous(...o),["stop","prevent"]),["left"])),l[1]||(l[1]=e.withKeys(e.withModifiers((...o)=>n.next&&n.next(...o),["stop","prevent"]),["right"]))]},[e.createElementVNode("div",u,[e.createVNode(r,{circular:!0,disabled:n.currentImage===0,title:n.previousLabel,transparent:!0,"button-style":"text",class:"neon-image-carousel__previous",color:"neutral",icon:"chevron-left",size:"l",onClick:n.previous},null,8,["disabled","title","onClick"]),e.createElementVNode("ul",m,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.images,(o,t)=>(e.openBlock(),e.createElementBlock("li",{key:o.src,ref_for:!0,ref:"carouselItem",class:e.normalizeClass([{"neon-image-carousel__item--active":t===n.currentImage},"neon-image-carousel__item"])},[e.createElementVNode("img",{alt:o.alt,src:o.src,class:"neon-image-carousel__image"},null,8,d)],2))),128))],512),e.createVNode(r,{circular:!0,disabled:n.currentImage===n.images.length-1,title:n.nextLabel,transparent:!0,"button-style":"text",class:"neon-image-carousel__next",color:"neutral",icon:"chevron-right",size:"l",onClick:n.next},null,8,["disabled","title","onClick"])]),e.createElementVNode("div",g,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.images,(o,t)=>(e.openBlock(),e.createBlock(a,{key:t,"aria-label":`Display image ${t+1}`,class:"neon-image-carousel__nav-item-link","outline-style":"none",role:"button",tabindex:"0",onKeydown:[e.withKeys(e.withModifiers(s=>n.scrollTo(t),["stop","prevent"]),["enter"]),e.withKeys(e.withModifiers(s=>n.scrollTo(t),["stop","prevent"]),["space"])]},{default:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass([{"neon-image-carousel__nav-item--active":t===n.currentImage},"neon-image-carousel__nav-item"]),tabindex:"-1",onClick:s=>n.scrollTo(t)},[...l[2]||(l[2]=[e.createElementVNode("div",{class:"neon-image-carousel__nav-item-indicator"},null,-1)])],10,p)]),_:2},1032,["aria-label","onKeydown"]))),128))]),n.hideLabel?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",_,e.toDisplayString(n.imageCountLabel||`${n.images.length} ${n.images.length===1?"image":"images"}`),1))],34)}const k=c(i,[["render",v]]);module.exports=k;
|
|
2
2
|
//# sourceMappingURL=NeonImageCarousel.vue.cjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NeonImageCarousel.vue.cjs.js","sources":["../../../../src/components/presentation/image-carousel/NeonImageCarousel.vue"],"sourcesContent":["<template>\n <div\n :class=\"{ 'neon-image-carousel--initialised': initialised }\"\n class=\"neon-image-carousel\"\n tabindex=\"0\"\n @keydown.stop.prevent.left=\"previous\"\n @keydown.stop.prevent.right=\"next\"\n >\n <div class=\"neon-image-carousel__container\" tabindex=\"-1\">\n <neon-button\n :circular=\"true\"\n :disabled=\"currentImage === 0\"\n :title=\"previousLabel\"\n :transparent=\"true\"\n button-style=\"text\"\n class=\"neon-image-carousel__previous\"\n color=\"neutral\"\n icon=\"chevron-left\"\n size=\"l\"\n @click=\"previous\"\n />\n <ul ref=\"carouselItems\" class=\"no-style neon-image-carousel__items\">\n <li\n v-for=\"(image, index) in images\"\n :key=\"image.src\"\n ref=\"carouselItem\"\n :class=\"{ 'neon-image-carousel__item--active': index === currentImage }\"\n class=\"neon-image-carousel__item\"\n >\n <img :alt=\"image.alt\" :src=\"image.src\" class=\"neon-image-carousel__image\" />\n </li>\n </ul>\n <neon-button\n :circular=\"true\"\n :disabled=\"currentImage === images.length - 1\"\n :title=\"nextLabel\"\n :transparent=\"true\"\n button-style=\"text\"\n class=\"neon-image-carousel__next\"\n color=\"neutral\"\n icon=\"chevron-right\"\n size=\"l\"\n @click=\"next\"\n />\n </div>\n <div class=\"neon-image-carousel__nav\" tabindex=\"-1\">\n <neon-link\n v-for=\"(_image, index) in images\"\n :key=\"index\"\n :aria-label=\"`Display image ${index + 1}`\"\n class=\"neon-image-carousel__nav-item-link\"\n outline-style=\"none\"\n role=\"button\"\n tabindex=\"0\"\n @keydown.stop.prevent.enter=\"scrollTo(index)\"\n @keydown.stop.prevent.space=\"scrollTo(index)\"\n >\n <div\n :class=\"{ 'neon-image-carousel__nav-item--active': index === currentImage }\"\n class=\"neon-image-carousel__nav-item\"\n tabindex=\"-1\"\n @click=\"scrollTo(index)\"\n >\n <div class=\"neon-image-carousel__nav-item-indicator\"></div>\n </div>\n </neon-link>\n </div>\n <span class=\"neon-image-carousel__label\" tabindex=\"-1\">\n {{ imageCountLabel || `${images.length} ${images.length === 1 ? 'image' : 'images'}` }}\n </span>\n </div>\n</template>\n\n<script lang=\"ts\" src=\"./NeonImageCarousel.ts\" />\n"],"names":["_createElementBlock","_normalizeClass","_ctx","args","_createElementVNode","_hoisted_1","_createVNode","_component_neon_button","_hoisted_2","_openBlock","_Fragment","_renderList","image","index","_hoisted_4","_image","_createBlock","_component_neon_link","_withKeys","_withModifiers","$event","_hoisted_6","_toDisplayString"],"mappings":"+IAQS,MAAM,iCAAiC,SAAS,SAa/C,IAAI,gBAAgB,MAAM,0DAwB3B,MAAM,2BAA2B,SAAS,
|
|
1
|
+
{"version":3,"file":"NeonImageCarousel.vue.cjs.js","sources":["../../../../src/components/presentation/image-carousel/NeonImageCarousel.vue"],"sourcesContent":["<template>\n <div\n :class=\"{ 'neon-image-carousel--initialised': initialised }\"\n class=\"neon-image-carousel\"\n tabindex=\"0\"\n @keydown.stop.prevent.left=\"previous\"\n @keydown.stop.prevent.right=\"next\"\n >\n <div class=\"neon-image-carousel__container\" tabindex=\"-1\">\n <neon-button\n :circular=\"true\"\n :disabled=\"currentImage === 0\"\n :title=\"previousLabel\"\n :transparent=\"true\"\n button-style=\"text\"\n class=\"neon-image-carousel__previous\"\n color=\"neutral\"\n icon=\"chevron-left\"\n size=\"l\"\n @click=\"previous\"\n />\n <ul ref=\"carouselItems\" class=\"no-style neon-image-carousel__items\">\n <li\n v-for=\"(image, index) in images\"\n :key=\"image.src\"\n ref=\"carouselItem\"\n :class=\"{ 'neon-image-carousel__item--active': index === currentImage }\"\n class=\"neon-image-carousel__item\"\n >\n <img :alt=\"image.alt\" :src=\"image.src\" class=\"neon-image-carousel__image\" />\n </li>\n </ul>\n <neon-button\n :circular=\"true\"\n :disabled=\"currentImage === images.length - 1\"\n :title=\"nextLabel\"\n :transparent=\"true\"\n button-style=\"text\"\n class=\"neon-image-carousel__next\"\n color=\"neutral\"\n icon=\"chevron-right\"\n size=\"l\"\n @click=\"next\"\n />\n </div>\n <div class=\"neon-image-carousel__nav\" tabindex=\"-1\">\n <neon-link\n v-for=\"(_image, index) in images\"\n :key=\"index\"\n :aria-label=\"`Display image ${index + 1}`\"\n class=\"neon-image-carousel__nav-item-link\"\n outline-style=\"none\"\n role=\"button\"\n tabindex=\"0\"\n @keydown.stop.prevent.enter=\"scrollTo(index)\"\n @keydown.stop.prevent.space=\"scrollTo(index)\"\n >\n <div\n :class=\"{ 'neon-image-carousel__nav-item--active': index === currentImage }\"\n class=\"neon-image-carousel__nav-item\"\n tabindex=\"-1\"\n @click=\"scrollTo(index)\"\n >\n <div class=\"neon-image-carousel__nav-item-indicator\"></div>\n </div>\n </neon-link>\n </div>\n <span v-if=\"!hideLabel\" class=\"neon-image-carousel__label\" tabindex=\"-1\">\n {{ imageCountLabel || `${images.length} ${images.length === 1 ? 'image' : 'images'}` }}\n </span>\n </div>\n</template>\n\n<script lang=\"ts\" src=\"./NeonImageCarousel.ts\" />\n"],"names":["_createElementBlock","_normalizeClass","_ctx","args","_createElementVNode","_hoisted_1","_createVNode","_component_neon_button","_hoisted_2","_openBlock","_Fragment","_renderList","image","index","_hoisted_4","_image","_createBlock","_component_neon_link","_withKeys","_withModifiers","$event","_hoisted_6","_toDisplayString"],"mappings":"+IAQS,MAAM,iCAAiC,SAAS,SAa/C,IAAI,gBAAgB,MAAM,0DAwB3B,MAAM,2BAA2B,SAAS,6BAsBvB,MAAM,6BAA6B,SAAS,+HAlEtEA,EAAAA,mBAqEM,MAAA,CApEH,MAAKC,EAAAA,eAAA,CAAA,CAAA,mCAAwCC,EAAA,WAAW,EACnD,qBAAqB,CAAA,EAC3B,SAAS,IACR,UAAO,gDAAoBA,EAAA,UAAAA,EAAA,SAAA,GAAAC,CAAA,EAAQ,CAAA,OAAA,SAAA,CAAA,EAAA,CAAA,MAAA,CAAA,kDACPD,EAAA,MAAAA,EAAA,KAAA,GAAAC,CAAA,EAAI,CAAA,OAAA,SAAA,CAAA,EAAA,CAAA,OAAA,CAAA,MAEjCC,EAAAA,mBAoCM,MApCNC,EAoCM,CAnCJC,EAAAA,YAWEC,EAAA,CAVC,SAAU,GACV,SAAUL,EAAA,eAAY,EACtB,MAAOA,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CAAA,CAAA,wCAA6CY,IAAUX,EAAA,cACvD,+BAA+B,CAAA,EACrC,SAAS,KACR,QAAKkB,GAAElB,EAAA,SAASW,CAAK,oBAEtBT,EAAAA,mBAA2D,MAAA,CAAtD,MAAM,yCAAyC,EAAA,KAAA,EAAA,6DAI7CF,EAAA,qDAAbF,qBAEO,OAFPqB,EAEOC,EAAAA,gBADFpB,EAAA,iBAAe,GAAOA,EAAA,OAAO,MAAM,IAAIA,EAAA,OAAO,SAAM,EAAA,QAAA,QAAA,EAAA,EAAA,CAAA"}
|
|
@@ -1,31 +1,32 @@
|
|
|
1
1
|
import b from "./NeonImageCarousel.es.js";
|
|
2
|
-
import { resolveComponent as
|
|
3
|
-
import
|
|
4
|
-
const
|
|
2
|
+
import { resolveComponent as d, openBlock as a, createElementBlock as s, withKeys as i, withModifiers as r, normalizeClass as u, createElementVNode as l, createVNode as g, Fragment as p, renderList as v, createBlock as f, withCtx as k, toDisplayString as y, createCommentVNode as h } from "vue";
|
|
3
|
+
import C from "../../../_virtual/_plugin-vue_export-helper.es.js";
|
|
4
|
+
const $ = {
|
|
5
5
|
class: "neon-image-carousel__container",
|
|
6
6
|
tabindex: "-1"
|
|
7
|
-
},
|
|
7
|
+
}, I = {
|
|
8
8
|
ref: "carouselItems",
|
|
9
9
|
class: "no-style neon-image-carousel__items"
|
|
10
|
-
},
|
|
10
|
+
}, w = ["alt", "src"], L = {
|
|
11
11
|
class: "neon-image-carousel__nav",
|
|
12
12
|
tabindex: "-1"
|
|
13
|
-
}, K = ["onClick"],
|
|
13
|
+
}, K = ["onClick"], N = {
|
|
14
|
+
key: 0,
|
|
14
15
|
class: "neon-image-carousel__label",
|
|
15
16
|
tabindex: "-1"
|
|
16
17
|
};
|
|
17
|
-
function z(e,
|
|
18
|
-
const m =
|
|
19
|
-
return
|
|
18
|
+
function z(e, t, B, T, V, D) {
|
|
19
|
+
const m = d("neon-button"), _ = d("neon-link");
|
|
20
|
+
return a(), s("div", {
|
|
20
21
|
class: u([{ "neon-image-carousel--initialised": e.initialised }, "neon-image-carousel"]),
|
|
21
22
|
tabindex: "0",
|
|
22
23
|
onKeydown: [
|
|
23
|
-
|
|
24
|
-
|
|
24
|
+
t[0] || (t[0] = i(r((...n) => e.previous && e.previous(...n), ["stop", "prevent"]), ["left"])),
|
|
25
|
+
t[1] || (t[1] = i(r((...n) => e.next && e.next(...n), ["stop", "prevent"]), ["right"]))
|
|
25
26
|
]
|
|
26
27
|
}, [
|
|
27
|
-
|
|
28
|
-
|
|
28
|
+
l("div", $, [
|
|
29
|
+
g(m, {
|
|
29
30
|
circular: !0,
|
|
30
31
|
disabled: e.currentImage === 0,
|
|
31
32
|
title: e.previousLabel,
|
|
@@ -37,21 +38,21 @@ function z(e, a, B, N, T, D) {
|
|
|
37
38
|
size: "l",
|
|
38
39
|
onClick: e.previous
|
|
39
40
|
}, null, 8, ["disabled", "title", "onClick"]),
|
|
40
|
-
|
|
41
|
-
(
|
|
41
|
+
l("ul", I, [
|
|
42
|
+
(a(!0), s(p, null, v(e.images, (n, o) => (a(), s("li", {
|
|
42
43
|
key: n.src,
|
|
43
44
|
ref_for: !0,
|
|
44
45
|
ref: "carouselItem",
|
|
45
46
|
class: u([{ "neon-image-carousel__item--active": o === e.currentImage }, "neon-image-carousel__item"])
|
|
46
47
|
}, [
|
|
47
|
-
|
|
48
|
+
l("img", {
|
|
48
49
|
alt: n.alt,
|
|
49
50
|
src: n.src,
|
|
50
51
|
class: "neon-image-carousel__image"
|
|
51
|
-
}, null, 8,
|
|
52
|
+
}, null, 8, w)
|
|
52
53
|
], 2))), 128))
|
|
53
54
|
], 512),
|
|
54
|
-
|
|
55
|
+
g(m, {
|
|
55
56
|
circular: !0,
|
|
56
57
|
disabled: e.currentImage === e.images.length - 1,
|
|
57
58
|
title: e.nextLabel,
|
|
@@ -64,8 +65,8 @@ function z(e, a, B, N, T, D) {
|
|
|
64
65
|
onClick: e.next
|
|
65
66
|
}, null, 8, ["disabled", "title", "onClick"])
|
|
66
67
|
]),
|
|
67
|
-
|
|
68
|
-
(
|
|
68
|
+
l("div", L, [
|
|
69
|
+
(a(!0), s(p, null, v(e.images, (n, o) => (a(), f(_, {
|
|
69
70
|
key: o,
|
|
70
71
|
"aria-label": `Display image ${o + 1}`,
|
|
71
72
|
class: "neon-image-carousel__nav-item-link",
|
|
@@ -78,22 +79,22 @@ function z(e, a, B, N, T, D) {
|
|
|
78
79
|
]
|
|
79
80
|
}, {
|
|
80
81
|
default: k(() => [
|
|
81
|
-
|
|
82
|
+
l("div", {
|
|
82
83
|
class: u([{ "neon-image-carousel__nav-item--active": o === e.currentImage }, "neon-image-carousel__nav-item"]),
|
|
83
84
|
tabindex: "-1",
|
|
84
85
|
onClick: (c) => e.scrollTo(o)
|
|
85
|
-
}, [...
|
|
86
|
-
|
|
86
|
+
}, [...t[2] || (t[2] = [
|
|
87
|
+
l("div", { class: "neon-image-carousel__nav-item-indicator" }, null, -1)
|
|
87
88
|
])], 10, K)
|
|
88
89
|
]),
|
|
89
90
|
_: 2
|
|
90
91
|
}, 1032, ["aria-label", "onKeydown"]))), 128))
|
|
91
92
|
]),
|
|
92
|
-
|
|
93
|
+
e.hideLabel ? h("", !0) : (a(), s("span", N, y(e.imageCountLabel || `${e.images.length} ${e.images.length === 1 ? "image" : "images"}`), 1))
|
|
93
94
|
], 34);
|
|
94
95
|
}
|
|
95
|
-
const
|
|
96
|
+
const S = /* @__PURE__ */ C(b, [["render", z]]);
|
|
96
97
|
export {
|
|
97
|
-
|
|
98
|
+
S as default
|
|
98
99
|
};
|
|
99
100
|
//# sourceMappingURL=NeonImageCarousel.vue.es.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NeonImageCarousel.vue.es.js","sources":["../../../../src/components/presentation/image-carousel/NeonImageCarousel.vue"],"sourcesContent":["<template>\n <div\n :class=\"{ 'neon-image-carousel--initialised': initialised }\"\n class=\"neon-image-carousel\"\n tabindex=\"0\"\n @keydown.stop.prevent.left=\"previous\"\n @keydown.stop.prevent.right=\"next\"\n >\n <div class=\"neon-image-carousel__container\" tabindex=\"-1\">\n <neon-button\n :circular=\"true\"\n :disabled=\"currentImage === 0\"\n :title=\"previousLabel\"\n :transparent=\"true\"\n button-style=\"text\"\n class=\"neon-image-carousel__previous\"\n color=\"neutral\"\n icon=\"chevron-left\"\n size=\"l\"\n @click=\"previous\"\n />\n <ul ref=\"carouselItems\" class=\"no-style neon-image-carousel__items\">\n <li\n v-for=\"(image, index) in images\"\n :key=\"image.src\"\n ref=\"carouselItem\"\n :class=\"{ 'neon-image-carousel__item--active': index === currentImage }\"\n class=\"neon-image-carousel__item\"\n >\n <img :alt=\"image.alt\" :src=\"image.src\" class=\"neon-image-carousel__image\" />\n </li>\n </ul>\n <neon-button\n :circular=\"true\"\n :disabled=\"currentImage === images.length - 1\"\n :title=\"nextLabel\"\n :transparent=\"true\"\n button-style=\"text\"\n class=\"neon-image-carousel__next\"\n color=\"neutral\"\n icon=\"chevron-right\"\n size=\"l\"\n @click=\"next\"\n />\n </div>\n <div class=\"neon-image-carousel__nav\" tabindex=\"-1\">\n <neon-link\n v-for=\"(_image, index) in images\"\n :key=\"index\"\n :aria-label=\"`Display image ${index + 1}`\"\n class=\"neon-image-carousel__nav-item-link\"\n outline-style=\"none\"\n role=\"button\"\n tabindex=\"0\"\n @keydown.stop.prevent.enter=\"scrollTo(index)\"\n @keydown.stop.prevent.space=\"scrollTo(index)\"\n >\n <div\n :class=\"{ 'neon-image-carousel__nav-item--active': index === currentImage }\"\n class=\"neon-image-carousel__nav-item\"\n tabindex=\"-1\"\n @click=\"scrollTo(index)\"\n >\n <div class=\"neon-image-carousel__nav-item-indicator\"></div>\n </div>\n </neon-link>\n </div>\n <span class=\"neon-image-carousel__label\" tabindex=\"-1\">\n {{ imageCountLabel || `${images.length} ${images.length === 1 ? 'image' : 'images'}` }}\n </span>\n </div>\n</template>\n\n<script lang=\"ts\" src=\"./NeonImageCarousel.ts\" />\n"],"names":["_createElementBlock","_normalizeClass","_ctx","args","_createElementVNode","_hoisted_1","_createVNode","_component_neon_button","_hoisted_2","_openBlock","_Fragment","_renderList","image","index","_hoisted_4","_image","_createBlock","_component_neon_link","_withKeys","_withModifiers","$event","_hoisted_6","_toDisplayString"],"mappings":";;;;EAQS,OAAM;AAAA,EAAiC,UAAS;;EAa/C,KAAI;AAAA,EAAgB,OAAM;;EAwB3B,OAAM;AAAA,EAA2B,UAAS
|
|
1
|
+
{"version":3,"file":"NeonImageCarousel.vue.es.js","sources":["../../../../src/components/presentation/image-carousel/NeonImageCarousel.vue"],"sourcesContent":["<template>\n <div\n :class=\"{ 'neon-image-carousel--initialised': initialised }\"\n class=\"neon-image-carousel\"\n tabindex=\"0\"\n @keydown.stop.prevent.left=\"previous\"\n @keydown.stop.prevent.right=\"next\"\n >\n <div class=\"neon-image-carousel__container\" tabindex=\"-1\">\n <neon-button\n :circular=\"true\"\n :disabled=\"currentImage === 0\"\n :title=\"previousLabel\"\n :transparent=\"true\"\n button-style=\"text\"\n class=\"neon-image-carousel__previous\"\n color=\"neutral\"\n icon=\"chevron-left\"\n size=\"l\"\n @click=\"previous\"\n />\n <ul ref=\"carouselItems\" class=\"no-style neon-image-carousel__items\">\n <li\n v-for=\"(image, index) in images\"\n :key=\"image.src\"\n ref=\"carouselItem\"\n :class=\"{ 'neon-image-carousel__item--active': index === currentImage }\"\n class=\"neon-image-carousel__item\"\n >\n <img :alt=\"image.alt\" :src=\"image.src\" class=\"neon-image-carousel__image\" />\n </li>\n </ul>\n <neon-button\n :circular=\"true\"\n :disabled=\"currentImage === images.length - 1\"\n :title=\"nextLabel\"\n :transparent=\"true\"\n button-style=\"text\"\n class=\"neon-image-carousel__next\"\n color=\"neutral\"\n icon=\"chevron-right\"\n size=\"l\"\n @click=\"next\"\n />\n </div>\n <div class=\"neon-image-carousel__nav\" tabindex=\"-1\">\n <neon-link\n v-for=\"(_image, index) in images\"\n :key=\"index\"\n :aria-label=\"`Display image ${index + 1}`\"\n class=\"neon-image-carousel__nav-item-link\"\n outline-style=\"none\"\n role=\"button\"\n tabindex=\"0\"\n @keydown.stop.prevent.enter=\"scrollTo(index)\"\n @keydown.stop.prevent.space=\"scrollTo(index)\"\n >\n <div\n :class=\"{ 'neon-image-carousel__nav-item--active': index === currentImage }\"\n class=\"neon-image-carousel__nav-item\"\n tabindex=\"-1\"\n @click=\"scrollTo(index)\"\n >\n <div class=\"neon-image-carousel__nav-item-indicator\"></div>\n </div>\n </neon-link>\n </div>\n <span v-if=\"!hideLabel\" class=\"neon-image-carousel__label\" tabindex=\"-1\">\n {{ imageCountLabel || `${images.length} ${images.length === 1 ? 'image' : 'images'}` }}\n </span>\n </div>\n</template>\n\n<script lang=\"ts\" src=\"./NeonImageCarousel.ts\" />\n"],"names":["_createElementBlock","_normalizeClass","_ctx","args","_createElementVNode","_hoisted_1","_createVNode","_component_neon_button","_hoisted_2","_openBlock","_Fragment","_renderList","image","index","_hoisted_4","_image","_createBlock","_component_neon_link","_withKeys","_withModifiers","$event","_hoisted_6","_toDisplayString"],"mappings":";;;;EAQS,OAAM;AAAA,EAAiC,UAAS;;EAa/C,KAAI;AAAA,EAAgB,OAAM;;EAwB3B,OAAM;AAAA,EAA2B,UAAS;;;EAsBvB,OAAM;AAAA,EAA6B,UAAS;;;;cAlEtEA,EAqEM,OAAA;AAAA,IApEH,OAAKC,EAAA,CAAA,EAAA,oCAAwCC,EAAA,YAAW,GACnD,qBAAqB,CAAA;AAAA,IAC3B,UAAS;AAAA,IACR,WAAO;AAAA,oCAAoBA,EAAA,YAAAA,EAAA,SAAA,GAAAC,CAAA,GAAQ,CAAA,QAAA,SAAA,CAAA,GAAA,CAAA,MAAA,CAAA;AAAA,oCACPD,EAAA,QAAAA,EAAA,KAAA,GAAAC,CAAA,GAAI,CAAA,QAAA,SAAA,CAAA,GAAA,CAAA,OAAA,CAAA;AAAA;;IAEjCC,EAoCM,OApCNC,GAoCM;AAAA,MAnCJC,EAWEC,GAAA;AAAA,QAVC,UAAU;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A,CAAAC,MAAAlB,EAAA,SAASW,CAAK,GAAA,CAAA,QAAA,SAAA,CAAA,GAAA,CAAA,OAAA,CAAA;AAAA;;mBAE3C,MAOM;AAAA,UAPNT,EAOM,OAAA;AAAA,YANH,OAAKH,EAAA,CAAA,EAAA,yCAA6CY,MAAUX,EAAA,gBACvD,+BAA+B,CAAA;AAAA,YACrC,UAAS;AAAA,YACR,SAAK,CAAAkB,MAAElB,EAAA,SAASW,CAAK;AAAA;YAEtBT,EAA2D,OAAA,EAAtD,OAAM,0CAAyC,GAAA,MAAA,EAAA;AAAA;;;;;IAI7CF,EAAA,8BAAbF,EAEO,QAFPqB,GAEOC,EADFpB,EAAA,mBAAe,GAAOA,EAAA,OAAO,MAAM,IAAIA,EAAA,OAAO,WAAM,IAAA,UAAA,QAAA,EAAA,GAAA,CAAA;AAAA;;;"}
|
|
@@ -23,6 +23,13 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
23
23
|
type: StringConstructor;
|
|
24
24
|
default: undefined;
|
|
25
25
|
};
|
|
26
|
+
/**
|
|
27
|
+
* Hide the label under the dot navigation.
|
|
28
|
+
*/
|
|
29
|
+
hideLabel: {
|
|
30
|
+
type: BooleanConstructor;
|
|
31
|
+
default: boolean;
|
|
32
|
+
};
|
|
26
33
|
/**
|
|
27
34
|
* Provide an alternative label for the Previous button.
|
|
28
35
|
*/
|
|
@@ -62,6 +69,13 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
62
69
|
type: StringConstructor;
|
|
63
70
|
default: undefined;
|
|
64
71
|
};
|
|
72
|
+
/**
|
|
73
|
+
* Hide the label under the dot navigation.
|
|
74
|
+
*/
|
|
75
|
+
hideLabel: {
|
|
76
|
+
type: BooleanConstructor;
|
|
77
|
+
default: boolean;
|
|
78
|
+
};
|
|
65
79
|
/**
|
|
66
80
|
* Provide an alternative label for the Previous button.
|
|
67
81
|
*/
|
|
@@ -80,6 +94,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
80
94
|
"onCurrent-image"?: ((...args: any[]) => any) | undefined;
|
|
81
95
|
}>, {
|
|
82
96
|
imageCountLabel: string;
|
|
97
|
+
hideLabel: boolean;
|
|
83
98
|
previousLabel: string;
|
|
84
99
|
nextLabel: string;
|
|
85
100
|
}, {}, {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aotearoan/neon",
|
|
3
3
|
"description": "Neon is a lightweight design library of Vue 3 components with minimal dependencies.",
|
|
4
|
-
"version": "19.0.
|
|
4
|
+
"version": "19.0.2",
|
|
5
5
|
"main": "./dist/neon.cjs.js",
|
|
6
6
|
"module": "./dist/neon.es.js",
|
|
7
7
|
"types": "./dist/src/neon.d.ts",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
flex-direction: row;
|
|
49
49
|
flex-wrap: wrap;
|
|
50
50
|
align-items: center;
|
|
51
|
-
border-radius: var(--neon-border-radius);
|
|
51
|
+
border-radius: var(--neon-border-radius-input);
|
|
52
52
|
padding-left: var(--neon-space-40);
|
|
53
53
|
padding-top: var(--neon-space-2);
|
|
54
54
|
padding-bottom: var(--neon-space-2);
|
package/src/sass/variables.scss
CHANGED
|
@@ -570,9 +570,9 @@
|
|
|
570
570
|
--neon-border-top-footer: none;
|
|
571
571
|
|
|
572
572
|
/* skeleton loader */
|
|
573
|
-
--neon-color-loading-1:
|
|
574
|
-
--neon-color-loading-2:
|
|
575
|
-
--neon-color-loading-3: rgba(
|
|
573
|
+
--neon-color-loading-1: rgb(64, 64, 64);
|
|
574
|
+
--neon-color-loading-2: rgb(82, 82, 82);
|
|
575
|
+
--neon-color-loading-3: rgba(82, 82, 82, 0.5);
|
|
576
576
|
|
|
577
577
|
/* scrollbars */
|
|
578
578
|
--neon-color-scrollbar: rgba(255, 255, 255, 0.05);
|
|
@@ -876,9 +876,9 @@
|
|
|
876
876
|
--neon-border-top-footer: none;
|
|
877
877
|
|
|
878
878
|
/* skeleton loader */
|
|
879
|
-
--neon-color-loading-1:
|
|
880
|
-
--neon-color-loading-2:
|
|
881
|
-
--neon-color-loading-3:
|
|
879
|
+
--neon-color-loading-1: rgb(226, 226, 226);
|
|
880
|
+
--neon-color-loading-2: rgb(212, 212, 212);
|
|
881
|
+
--neon-color-loading-3: rgba(212, 212, 212, 0.5);
|
|
882
882
|
|
|
883
883
|
/* toggle */
|
|
884
884
|
--neon-margin-toggle-option: 1rem;
|