@aotearoan/neon 22.4.0 → 22.5.0

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 (69) hide show
  1. package/dist/common/enums/NeonInputIndicatorStyle.cjs.js +2 -0
  2. package/dist/common/enums/NeonInputIndicatorStyle.cjs.js.map +1 -0
  3. package/dist/common/enums/NeonInputIndicatorStyle.es.js +5 -0
  4. package/dist/common/enums/NeonInputIndicatorStyle.es.js.map +1 -0
  5. package/dist/components/navigation/link/NeonLink.cjs.js +1 -1
  6. package/dist/components/navigation/link/NeonLink.cjs.js.map +1 -1
  7. package/dist/components/navigation/link/NeonLink.es.js +23 -22
  8. package/dist/components/navigation/link/NeonLink.es.js.map +1 -1
  9. package/dist/components/navigation/link/NeonLink.vue.cjs.js +1 -1
  10. package/dist/components/navigation/link/NeonLink.vue.cjs.js.map +1 -1
  11. package/dist/components/navigation/link/NeonLink.vue.es.js +14 -11
  12. package/dist/components/navigation/link/NeonLink.vue.es.js.map +1 -1
  13. package/dist/components/presentation/tabs/NeonTabs.cjs.js +1 -1
  14. package/dist/components/presentation/tabs/NeonTabs.cjs.js.map +1 -1
  15. package/dist/components/presentation/tabs/NeonTabs.es.js +35 -18
  16. package/dist/components/presentation/tabs/NeonTabs.es.js.map +1 -1
  17. package/dist/components/presentation/tabs/NeonTabs.vue.cjs.js +1 -1
  18. package/dist/components/presentation/tabs/NeonTabs.vue.cjs.js.map +1 -1
  19. package/dist/components/presentation/tabs/NeonTabs.vue.es.js +55 -42
  20. package/dist/components/presentation/tabs/NeonTabs.vue.es.js.map +1 -1
  21. package/dist/components/user-input/field-group/NeonFieldGroup.cjs.js +1 -1
  22. package/dist/components/user-input/field-group/NeonFieldGroup.cjs.js.map +1 -1
  23. package/dist/components/user-input/field-group/NeonFieldGroup.es.js +22 -4
  24. package/dist/components/user-input/field-group/NeonFieldGroup.es.js.map +1 -1
  25. package/dist/components/user-input/field-group/NeonFieldGroup.vue.cjs.js +1 -1
  26. package/dist/components/user-input/field-group/NeonFieldGroup.vue.cjs.js.map +1 -1
  27. package/dist/components/user-input/field-group/NeonFieldGroup.vue.es.js +15 -10
  28. package/dist/components/user-input/field-group/NeonFieldGroup.vue.es.js.map +1 -1
  29. package/dist/components/user-input/number/NeonNumber.vue.cjs.js +1 -1
  30. package/dist/components/user-input/number/NeonNumber.vue.cjs.js.map +1 -1
  31. package/dist/components/user-input/number/NeonNumber.vue.es.js +7 -6
  32. package/dist/components/user-input/number/NeonNumber.vue.es.js.map +1 -1
  33. package/dist/neon.cjs.js +1 -1
  34. package/dist/neon.es.js +99 -97
  35. package/dist/neon.es.js.map +1 -1
  36. package/dist/src/common/enums/NeonInputIndicatorStyle.d.ts +10 -0
  37. package/dist/src/common/models/NeonTabModel.d.ts +2 -0
  38. package/dist/src/components/feedback/alert/NeonAlert.d.ts +1 -0
  39. package/dist/src/components/feedback/alert/container/NeonAlertContainer.d.ts +1 -0
  40. package/dist/src/components/feedback/dialog/NeonDialog.d.ts +6 -12
  41. package/dist/src/components/feedback/note/NeonNote.d.ts +9 -8
  42. package/dist/src/components/layout/card-list/NeonCardList.d.ts +4 -8
  43. package/dist/src/components/layout/modal/NeonModal.d.ts +1 -0
  44. package/dist/src/components/navigation/action-menu/NeonActionMenu.d.ts +3 -6
  45. package/dist/src/components/navigation/dropdown-menu/NeonDropdownMenu.d.ts +7 -0
  46. package/dist/src/components/navigation/link/NeonLink.d.ts +1 -0
  47. package/dist/src/components/navigation/menu/NeonMenu.d.ts +8 -0
  48. package/dist/src/components/navigation/mobile-menu/NeonMobileMenu.d.ts +8 -0
  49. package/dist/src/components/navigation/tree-menu/NeonTreeMenu.d.ts +1 -0
  50. package/dist/src/components/presentation/badge/NeonBadge.d.ts +1 -0
  51. package/dist/src/components/presentation/dropdown/NeonDropdown.d.ts +8 -2
  52. package/dist/src/components/presentation/image-carousel/NeonImageCarousel.d.ts +2 -0
  53. package/dist/src/components/presentation/tabs/NeonTabs.d.ts +374 -0
  54. package/dist/src/components/user-input/button/NeonButton.d.ts +1 -0
  55. package/dist/src/components/user-input/date-picker/NeonDatePicker.d.ts +3 -0
  56. package/dist/src/components/user-input/field-group/NeonFieldGroup.d.ts +55 -1
  57. package/dist/src/components/user-input/file/NeonFile.d.ts +2 -4
  58. package/dist/src/components/user-input/filter-list/NeonFilterList.d.ts +1 -0
  59. package/dist/src/components/user-input/number/NeonNumber.d.ts +32 -1
  60. package/dist/src/components/user-input/search/NeonSearch.d.ts +30 -6
  61. package/dist/src/components/user-input/select/NeonSelect.d.ts +6 -0
  62. package/dist/src/neon.d.ts +1 -0
  63. package/package.json +1 -1
  64. package/src/sass/components/_field-group.scss +121 -34
  65. package/src/sass/components/_input-indicator.scss +13 -9
  66. package/src/sass/components/_input.scss +36 -28
  67. package/src/sass/components/_tabs.scss +50 -30
  68. package/src/sass/includes/_dependencies.scss +1 -1
  69. package/src/sass/variables.scss +24 -5
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var r=(e=>(e.Internal="internal",e.External="external",e))(r||{});exports.NeonInputIndicatorStyle=r;
2
+ //# sourceMappingURL=NeonInputIndicatorStyle.cjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NeonInputIndicatorStyle.cjs.js","sources":["../../../src/common/enums/NeonInputIndicatorStyle.ts"],"sourcesContent":["export enum NeonInputIndicatorStyle {\n /**\n * Display input indicator INSIDE the adjacent input.\n */\n Internal = 'internal',\n /**\n * Display input indicator OUTSIDE the adjacent input.\n */\n External = 'external',\n}\n"],"names":["NeonInputIndicatorStyle"],"mappings":"gFAAO,IAAKA,GAAAA,IAIVA,EAAA,SAAW,WAIXA,EAAA,SAAW,WARDA,IAAAA,GAAA,CAAA,CAAA"}
@@ -0,0 +1,5 @@
1
+ var e = /* @__PURE__ */ ((r) => (r.Internal = "internal", r.External = "external", r))(e || {});
2
+ export {
3
+ e as NeonInputIndicatorStyle
4
+ };
5
+ //# sourceMappingURL=NeonInputIndicatorStyle.es.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NeonInputIndicatorStyle.es.js","sources":["../../../src/common/enums/NeonInputIndicatorStyle.ts"],"sourcesContent":["export enum NeonInputIndicatorStyle {\n /**\n * Display input indicator INSIDE the adjacent input.\n */\n Internal = 'internal',\n /**\n * Display input indicator OUTSIDE the adjacent input.\n */\n External = 'external',\n}\n"],"names":["NeonInputIndicatorStyle"],"mappings":"AAAO,IAAKA,sBAAAA,OAIVA,EAAA,WAAW,YAIXA,EAAA,WAAW,YARDA,IAAAA,KAAA,CAAA,CAAA;"}
@@ -1,2 +1,2 @@
1
- "use strict";const t=require("vue"),m=require("../../../common/enums/NeonOutlineStyle.cjs.js"),y=require("../../presentation/icon/NeonIcon.vue.cjs.js"),l=require("vue-router"),S=t.defineComponent({name:"NeonLink",components:{NeonIcon:y},props:{href:{type:String,default:null},noStyle:{type:Boolean,default:!1},outlineStyle:{type:String,default:m.NeonOutlineStyle.Text},externalIndicator:{type:Boolean,default:!1}},emits:["click"],setup(e,{emit:r}){const s=t.useAttrs(),a=l.useRouter(),o=l.useRoute(),u=t.computed(()=>{var n;return((n=e.href)==null?void 0:n.indexOf("/"))===0?e.href:void 0}),c=t.computed(()=>e.href&&e.href.indexOf(o.fullPath)===0),f=t.computed(()=>c.value&&e.href===o.fullPath),d=t.computed(()=>{const{onClick:n,...h}=s;return h}),i=()=>{r("click")};return{routerUrl:u,sanitizedAttributes:d,activeRoute:c,exactRoute:f,onClick:i,onSpace:async()=>{i(),u.value?await a.push(e.href):e.href&&window.location.replace(e.href)}}}});module.exports=S;
1
+ "use strict";const t=require("vue"),S=require("../../../common/enums/NeonOutlineStyle.cjs.js"),v=require("../../presentation/icon/NeonIcon.vue.cjs.js"),r=require("vue-router"),x=t.defineComponent({name:"NeonLink",components:{NeonIcon:v},props:{href:{type:String,default:null},noStyle:{type:Boolean,default:!1},outlineStyle:{type:String,default:S.NeonOutlineStyle.Text},externalIndicator:{type:Boolean,default:!1}},emits:["click"],setup(e,{emit:s,expose:a}){const o=t.ref(null),f=t.useAttrs(),d=r.useRouter(),u=r.useRoute(),c=t.computed(()=>{var n;return((n=e.href)==null?void 0:n.indexOf("/"))===0?e.href:void 0}),i=t.computed(()=>e.href&&e.href.indexOf(u.fullPath)===0),h=t.computed(()=>i.value&&e.href===u.fullPath),m=t.computed(()=>{const{onClick:n,...k}=f;return k}),l=()=>{s("click")},y=async()=>{l(),c.value?await d.push(e.href):e.href&&window.location.replace(e.href)};return a({neonLink:o}),{neonLink:o,routerUrl:c,sanitizedAttributes:m,activeRoute:i,exactRoute:h,onClick:l,onSpace:y}}});module.exports=x;
2
2
  //# sourceMappingURL=NeonLink.cjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"NeonLink.cjs.js","sources":["../../../../src/components/navigation/link/NeonLink.ts?vue&type=script&src=true&lang.ts"],"sourcesContent":["import { computed, defineComponent, useAttrs } from 'vue';\nimport { NeonOutlineStyle } from '@/common/enums/NeonOutlineStyle';\nimport NeonIcon from '@/components/presentation/icon/NeonIcon.vue';\nimport { useRoute, useRouter } from 'vue-router';\n\n/**\n * An HTML anchor component which handles VueRouter links (internal), href links (external) and clickable links (no href).\n */\nexport default defineComponent({\n name: 'NeonLink',\n components: {\n NeonIcon,\n },\n props: {\n /**\n * The href of the link, this can be an internal (relative or absolute) or an external link.\n */\n href: { type: String, default: null },\n /**\n * set to true if you would like a completely unstyled link. This is useful for creating a complex component which may use NeonLink.\n */\n noStyle: { type: Boolean, default: false },\n /**\n * Style of the outline to use when the link has focus, use <em>text</em> for wrapping text content and\n * <em>border</em> for tooltips wrapping \"block\" elements, e.g. buttons.\n */\n outlineStyle: { type: String as () => NeonOutlineStyle, default: NeonOutlineStyle.Text },\n /**\n * Display an external link icon to the right of the link indicating clicking it will take the user to another site.\n */\n externalIndicator: { type: Boolean, default: false },\n },\n emits: [\n /**\n * Emitted when the user triggers the link by clicking on it or hitting Enter or Space when the link has focus.\n * @type {void}\n */\n 'click',\n ],\n setup(props, { emit }) {\n const attrs = useAttrs();\n const router = useRouter();\n const route = useRoute();\n const routerUrl = computed(() => (props.href?.indexOf('/') === 0 ? props.href : undefined));\n\n const activeRoute = computed(() => props.href && props.href.indexOf(route.fullPath) === 0);\n const exactRoute = computed(() => activeRoute.value && props.href === route.fullPath);\n\n const sanitizedAttributes = computed(() => {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const { onClick, ...sanitized } = attrs;\n return sanitized;\n });\n\n const onClick = () => {\n emit('click');\n };\n\n const onSpace = async () => {\n onClick();\n\n if (routerUrl.value) {\n await router.push(props.href);\n } else if (props.href) {\n window.location.replace(props.href);\n }\n };\n\n return {\n routerUrl,\n sanitizedAttributes,\n activeRoute,\n exactRoute,\n onClick,\n onSpace,\n };\n },\n});\n"],"names":["_sfc_main","defineComponent","NeonIcon","NeonOutlineStyle","props","emit","attrs","useAttrs","router","useRouter","route","useRoute","routerUrl","computed","_a","activeRoute","exactRoute","sanitizedAttributes","onClick","sanitized"],"mappings":"gLAQAA,EAAeC,kBAAgB,CAC7B,KAAM,WACN,WAAY,CACV,SAAAC,CAAA,EAEF,MAAO,CAIL,KAAM,CAAE,KAAM,OAAQ,QAAS,IAAA,EAI/B,QAAS,CAAE,KAAM,QAAS,QAAS,EAAA,EAKnC,aAAc,CAAE,KAAM,OAAkC,QAASC,EAAAA,iBAAiB,IAAA,EAIlF,kBAAmB,CAAE,KAAM,QAAS,QAAS,EAAA,CAAM,EAErD,MAAO,CAKL,OAAA,EAEF,MAAMC,EAAO,CAAE,KAAAC,GAAQ,CACrB,MAAMC,EAAQC,EAAAA,SAAA,EACRC,EAASC,EAAAA,UAAA,EACTC,EAAQC,EAAAA,SAAA,EACRC,EAAYC,EAAAA,SAAS,IAAA,OAAO,QAAAC,EAAAV,EAAM,OAAN,YAAAU,EAAY,QAAQ,QAAS,EAAIV,EAAM,KAAO,OAAU,EAEpFW,EAAcF,EAAAA,SAAS,IAAMT,EAAM,MAAQA,EAAM,KAAK,QAAQM,EAAM,QAAQ,IAAM,CAAC,EACnFM,EAAaH,EAAAA,SAAS,IAAME,EAAY,OAASX,EAAM,OAASM,EAAM,QAAQ,EAE9EO,EAAsBJ,EAAAA,SAAS,IAAM,CAEzC,KAAM,CAAE,QAAAK,EAAS,GAAGC,GAAcb,EAClC,OAAOa,CACT,CAAC,EAEKD,EAAU,IAAM,CACpBb,EAAK,OAAO,CACd,EAYA,MAAO,CACL,UAAAO,EACA,oBAAAK,EACA,YAAAF,EACA,WAAAC,EACA,QAAAE,EACA,QAhBc,SAAY,CAC1BA,EAAA,EAEIN,EAAU,MACZ,MAAMJ,EAAO,KAAKJ,EAAM,IAAI,EACnBA,EAAM,MACf,OAAO,SAAS,QAAQA,EAAM,IAAI,CAEtC,CAQE,CAEJ,CACF,CAAC"}
1
+ {"version":3,"file":"NeonLink.cjs.js","sources":["../../../../src/components/navigation/link/NeonLink.ts?vue&type=script&src=true&lang.ts"],"sourcesContent":["import { computed, defineComponent, ref, useAttrs } from 'vue';\nimport { NeonOutlineStyle } from '@/common/enums/NeonOutlineStyle';\nimport NeonIcon from '@/components/presentation/icon/NeonIcon.vue';\nimport { useRoute, useRouter } from 'vue-router';\n\n/**\n * An HTML anchor component which handles VueRouter links (internal), href links (external) and clickable links (no href).\n */\nexport default defineComponent({\n name: 'NeonLink',\n components: {\n NeonIcon,\n },\n props: {\n /**\n * The href of the link, this can be an internal (relative or absolute) or an external link.\n */\n href: { type: String, default: null },\n /**\n * set to true if you would like a completely unstyled link. This is useful for creating a complex component which may use NeonLink.\n */\n noStyle: { type: Boolean, default: false },\n /**\n * Style of the outline to use when the link has focus, use <em>text</em> for wrapping text content and\n * <em>border</em> for tooltips wrapping \"block\" elements, e.g. buttons.\n */\n outlineStyle: { type: String as () => NeonOutlineStyle, default: NeonOutlineStyle.Text },\n /**\n * Display an external link icon to the right of the link indicating clicking it will take the user to another site.\n */\n externalIndicator: { type: Boolean, default: false },\n },\n emits: [\n /**\n * Emitted when the user triggers the link by clicking on it or hitting Enter or Space when the link has focus.\n * @type {void}\n */\n 'click',\n ],\n setup(props, { emit, expose }) {\n const neonLink = ref<HTMLAnchorElement | null>(null);\n const attrs = useAttrs();\n const router = useRouter();\n const route = useRoute();\n const routerUrl = computed(() => (props.href?.indexOf('/') === 0 ? props.href : undefined));\n\n const activeRoute = computed(() => props.href && props.href.indexOf(route.fullPath) === 0);\n const exactRoute = computed(() => activeRoute.value && props.href === route.fullPath);\n\n const sanitizedAttributes = computed(() => {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const { onClick, ...sanitized } = attrs;\n return sanitized;\n });\n\n const onClick = () => {\n emit('click');\n };\n\n const onSpace = async () => {\n onClick();\n\n if (routerUrl.value) {\n await router.push(props.href);\n } else if (props.href) {\n window.location.replace(props.href);\n }\n };\n\n expose({ neonLink });\n\n return {\n neonLink,\n routerUrl,\n sanitizedAttributes,\n activeRoute,\n exactRoute,\n onClick,\n onSpace,\n };\n },\n});\n"],"names":["_sfc_main","defineComponent","NeonIcon","NeonOutlineStyle","props","emit","expose","neonLink","ref","attrs","useAttrs","router","useRouter","route","useRoute","routerUrl","computed","_a","activeRoute","exactRoute","sanitizedAttributes","onClick","sanitized","onSpace"],"mappings":"gLAQAA,EAAeC,kBAAgB,CAC7B,KAAM,WACN,WAAY,CACV,SAAAC,CAAA,EAEF,MAAO,CAIL,KAAM,CAAE,KAAM,OAAQ,QAAS,IAAA,EAI/B,QAAS,CAAE,KAAM,QAAS,QAAS,EAAA,EAKnC,aAAc,CAAE,KAAM,OAAkC,QAASC,EAAAA,iBAAiB,IAAA,EAIlF,kBAAmB,CAAE,KAAM,QAAS,QAAS,EAAA,CAAM,EAErD,MAAO,CAKL,OAAA,EAEF,MAAMC,EAAO,CAAE,KAAAC,EAAM,OAAAC,GAAU,CAC7B,MAAMC,EAAWC,EAAAA,IAA8B,IAAI,EAC7CC,EAAQC,EAAAA,SAAA,EACRC,EAASC,EAAAA,UAAA,EACTC,EAAQC,EAAAA,SAAA,EACRC,EAAYC,EAAAA,SAAS,IAAA,OAAO,QAAAC,EAAAb,EAAM,OAAN,YAAAa,EAAY,QAAQ,QAAS,EAAIb,EAAM,KAAO,OAAU,EAEpFc,EAAcF,EAAAA,SAAS,IAAMZ,EAAM,MAAQA,EAAM,KAAK,QAAQS,EAAM,QAAQ,IAAM,CAAC,EACnFM,EAAaH,EAAAA,SAAS,IAAME,EAAY,OAASd,EAAM,OAASS,EAAM,QAAQ,EAE9EO,EAAsBJ,EAAAA,SAAS,IAAM,CAEzC,KAAM,CAAE,QAAAK,EAAS,GAAGC,GAAcb,EAClC,OAAOa,CACT,CAAC,EAEKD,EAAU,IAAM,CACpBhB,EAAK,OAAO,CACd,EAEMkB,EAAU,SAAY,CAC1BF,EAAA,EAEIN,EAAU,MACZ,MAAMJ,EAAO,KAAKP,EAAM,IAAI,EACnBA,EAAM,MACf,OAAO,SAAS,QAAQA,EAAM,IAAI,CAEtC,EAEA,OAAAE,EAAO,CAAE,SAAAC,EAAU,EAEZ,CACL,SAAAA,EACA,UAAAQ,EACA,oBAAAK,EACA,YAAAF,EACA,WAAAC,EACA,QAAAE,EACA,QAAAE,CAAA,CAEJ,CACF,CAAC"}
@@ -1,11 +1,11 @@
1
- import { defineComponent as m, useAttrs as h, computed as t } from "vue";
2
- import { NeonOutlineStyle as y } from "../../../common/enums/NeonOutlineStyle.es.js";
3
- import S from "../../presentation/icon/NeonIcon.vue.es.js";
4
- import { useRouter as k, useRoute as x } from "vue-router";
5
- const N = m({
1
+ import { defineComponent as k, ref as x, useAttrs as S, computed as t } from "vue";
2
+ import { NeonOutlineStyle as p } from "../../../common/enums/NeonOutlineStyle.es.js";
3
+ import v from "../../presentation/icon/NeonIcon.vue.es.js";
4
+ import { useRouter as C, useRoute as R } from "vue-router";
5
+ const z = k({
6
6
  name: "NeonLink",
7
7
  components: {
8
- NeonIcon: S
8
+ NeonIcon: v
9
9
  },
10
10
  props: {
11
11
  /**
@@ -20,7 +20,7 @@ const N = m({
20
20
  * Style of the outline to use when the link has focus, use <em>text</em> for wrapping text content and
21
21
  * <em>border</em> for tooltips wrapping "block" elements, e.g. buttons.
22
22
  */
23
- outlineStyle: { type: String, default: y.Text },
23
+ outlineStyle: { type: String, default: p.Text },
24
24
  /**
25
25
  * Display an external link icon to the right of the link indicating clicking it will take the user to another site.
26
26
  */
@@ -33,29 +33,30 @@ const N = m({
33
33
  */
34
34
  "click"
35
35
  ],
36
- setup(e, { emit: a }) {
37
- const c = h(), f = k(), o = x(), i = t(() => {
36
+ setup(e, { emit: a, expose: f }) {
37
+ const o = x(null), u = S(), s = C(), l = R(), i = t(() => {
38
38
  var n;
39
39
  return ((n = e.href) == null ? void 0 : n.indexOf("/")) === 0 ? e.href : void 0;
40
- }), l = t(() => e.href && e.href.indexOf(o.fullPath) === 0), u = t(() => l.value && e.href === o.fullPath), s = t(() => {
41
- const { onClick: n, ...d } = c;
42
- return d;
43
- }), r = () => {
40
+ }), r = t(() => e.href && e.href.indexOf(l.fullPath) === 0), d = t(() => r.value && e.href === l.fullPath), m = t(() => {
41
+ const { onClick: n, ...y } = u;
42
+ return y;
43
+ }), c = () => {
44
44
  a("click");
45
+ }, h = async () => {
46
+ c(), i.value ? await s.push(e.href) : e.href && window.location.replace(e.href);
45
47
  };
46
- return {
48
+ return f({ neonLink: o }), {
49
+ neonLink: o,
47
50
  routerUrl: i,
48
- sanitizedAttributes: s,
49
- activeRoute: l,
50
- exactRoute: u,
51
- onClick: r,
52
- onSpace: async () => {
53
- r(), i.value ? await f.push(e.href) : e.href && window.location.replace(e.href);
54
- }
51
+ sanitizedAttributes: m,
52
+ activeRoute: r,
53
+ exactRoute: d,
54
+ onClick: c,
55
+ onSpace: h
55
56
  };
56
57
  }
57
58
  });
58
59
  export {
59
- N as default
60
+ z as default
60
61
  };
61
62
  //# sourceMappingURL=NeonLink.es.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"NeonLink.es.js","sources":["../../../../src/components/navigation/link/NeonLink.ts?vue&type=script&src=true&lang.ts"],"sourcesContent":["import { computed, defineComponent, useAttrs } from 'vue';\nimport { NeonOutlineStyle } from '@/common/enums/NeonOutlineStyle';\nimport NeonIcon from '@/components/presentation/icon/NeonIcon.vue';\nimport { useRoute, useRouter } from 'vue-router';\n\n/**\n * An HTML anchor component which handles VueRouter links (internal), href links (external) and clickable links (no href).\n */\nexport default defineComponent({\n name: 'NeonLink',\n components: {\n NeonIcon,\n },\n props: {\n /**\n * The href of the link, this can be an internal (relative or absolute) or an external link.\n */\n href: { type: String, default: null },\n /**\n * set to true if you would like a completely unstyled link. This is useful for creating a complex component which may use NeonLink.\n */\n noStyle: { type: Boolean, default: false },\n /**\n * Style of the outline to use when the link has focus, use <em>text</em> for wrapping text content and\n * <em>border</em> for tooltips wrapping \"block\" elements, e.g. buttons.\n */\n outlineStyle: { type: String as () => NeonOutlineStyle, default: NeonOutlineStyle.Text },\n /**\n * Display an external link icon to the right of the link indicating clicking it will take the user to another site.\n */\n externalIndicator: { type: Boolean, default: false },\n },\n emits: [\n /**\n * Emitted when the user triggers the link by clicking on it or hitting Enter or Space when the link has focus.\n * @type {void}\n */\n 'click',\n ],\n setup(props, { emit }) {\n const attrs = useAttrs();\n const router = useRouter();\n const route = useRoute();\n const routerUrl = computed(() => (props.href?.indexOf('/') === 0 ? props.href : undefined));\n\n const activeRoute = computed(() => props.href && props.href.indexOf(route.fullPath) === 0);\n const exactRoute = computed(() => activeRoute.value && props.href === route.fullPath);\n\n const sanitizedAttributes = computed(() => {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const { onClick, ...sanitized } = attrs;\n return sanitized;\n });\n\n const onClick = () => {\n emit('click');\n };\n\n const onSpace = async () => {\n onClick();\n\n if (routerUrl.value) {\n await router.push(props.href);\n } else if (props.href) {\n window.location.replace(props.href);\n }\n };\n\n return {\n routerUrl,\n sanitizedAttributes,\n activeRoute,\n exactRoute,\n onClick,\n onSpace,\n };\n },\n});\n"],"names":["_sfc_main","defineComponent","NeonIcon","NeonOutlineStyle","props","emit","attrs","useAttrs","router","useRouter","route","useRoute","routerUrl","computed","_a","activeRoute","exactRoute","sanitizedAttributes","onClick","sanitized"],"mappings":";;;;AAQA,MAAAA,IAAeC,EAAgB;AAAA,EAC7B,MAAM;AAAA,EACN,YAAY;AAAA,IACV,UAAAC;AAAA,EAAA;AAAA,EAEF,OAAO;AAAA;AAAA;AAAA;AAAA,IAIL,MAAM,EAAE,MAAM,QAAQ,SAAS,KAAA;AAAA;AAAA;AAAA;AAAA,IAI/B,SAAS,EAAE,MAAM,SAAS,SAAS,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAKnC,cAAc,EAAE,MAAM,QAAkC,SAASC,EAAiB,KAAA;AAAA;AAAA;AAAA;AAAA,IAIlF,mBAAmB,EAAE,MAAM,SAAS,SAAS,GAAA;AAAA,EAAM;AAAA,EAErD,OAAO;AAAA;AAAA;AAAA;AAAA;AAAA,IAKL;AAAA,EAAA;AAAA,EAEF,MAAMC,GAAO,EAAE,MAAAC,KAAQ;AACrB,UAAMC,IAAQC,EAAA,GACRC,IAASC,EAAA,GACTC,IAAQC,EAAA,GACRC,IAAYC,EAAS,MAAA;;AAAO,eAAAC,IAAAV,EAAM,SAAN,gBAAAU,EAAY,QAAQ,UAAS,IAAIV,EAAM,OAAO;AAAA,KAAU,GAEpFW,IAAcF,EAAS,MAAMT,EAAM,QAAQA,EAAM,KAAK,QAAQM,EAAM,QAAQ,MAAM,CAAC,GACnFM,IAAaH,EAAS,MAAME,EAAY,SAASX,EAAM,SAASM,EAAM,QAAQ,GAE9EO,IAAsBJ,EAAS,MAAM;AAEzC,YAAM,EAAE,SAAAK,GAAS,GAAGC,MAAcb;AAClC,aAAOa;AAAA,IACT,CAAC,GAEKD,IAAU,MAAM;AACpB,MAAAb,EAAK,OAAO;AAAA,IACd;AAYA,WAAO;AAAA,MACL,WAAAO;AAAA,MACA,qBAAAK;AAAA,MACA,aAAAF;AAAA,MACA,YAAAC;AAAA,MACA,SAAAE;AAAA,MACA,SAhBc,YAAY;AAC1B,QAAAA,EAAA,GAEIN,EAAU,QACZ,MAAMJ,EAAO,KAAKJ,EAAM,IAAI,IACnBA,EAAM,QACf,OAAO,SAAS,QAAQA,EAAM,IAAI;AAAA,MAEtC;AAAA,IAQE;AAAA,EAEJ;AACF,CAAC;"}
1
+ {"version":3,"file":"NeonLink.es.js","sources":["../../../../src/components/navigation/link/NeonLink.ts?vue&type=script&src=true&lang.ts"],"sourcesContent":["import { computed, defineComponent, ref, useAttrs } from 'vue';\nimport { NeonOutlineStyle } from '@/common/enums/NeonOutlineStyle';\nimport NeonIcon from '@/components/presentation/icon/NeonIcon.vue';\nimport { useRoute, useRouter } from 'vue-router';\n\n/**\n * An HTML anchor component which handles VueRouter links (internal), href links (external) and clickable links (no href).\n */\nexport default defineComponent({\n name: 'NeonLink',\n components: {\n NeonIcon,\n },\n props: {\n /**\n * The href of the link, this can be an internal (relative or absolute) or an external link.\n */\n href: { type: String, default: null },\n /**\n * set to true if you would like a completely unstyled link. This is useful for creating a complex component which may use NeonLink.\n */\n noStyle: { type: Boolean, default: false },\n /**\n * Style of the outline to use when the link has focus, use <em>text</em> for wrapping text content and\n * <em>border</em> for tooltips wrapping \"block\" elements, e.g. buttons.\n */\n outlineStyle: { type: String as () => NeonOutlineStyle, default: NeonOutlineStyle.Text },\n /**\n * Display an external link icon to the right of the link indicating clicking it will take the user to another site.\n */\n externalIndicator: { type: Boolean, default: false },\n },\n emits: [\n /**\n * Emitted when the user triggers the link by clicking on it or hitting Enter or Space when the link has focus.\n * @type {void}\n */\n 'click',\n ],\n setup(props, { emit, expose }) {\n const neonLink = ref<HTMLAnchorElement | null>(null);\n const attrs = useAttrs();\n const router = useRouter();\n const route = useRoute();\n const routerUrl = computed(() => (props.href?.indexOf('/') === 0 ? props.href : undefined));\n\n const activeRoute = computed(() => props.href && props.href.indexOf(route.fullPath) === 0);\n const exactRoute = computed(() => activeRoute.value && props.href === route.fullPath);\n\n const sanitizedAttributes = computed(() => {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const { onClick, ...sanitized } = attrs;\n return sanitized;\n });\n\n const onClick = () => {\n emit('click');\n };\n\n const onSpace = async () => {\n onClick();\n\n if (routerUrl.value) {\n await router.push(props.href);\n } else if (props.href) {\n window.location.replace(props.href);\n }\n };\n\n expose({ neonLink });\n\n return {\n neonLink,\n routerUrl,\n sanitizedAttributes,\n activeRoute,\n exactRoute,\n onClick,\n onSpace,\n };\n },\n});\n"],"names":["_sfc_main","defineComponent","NeonIcon","NeonOutlineStyle","props","emit","expose","neonLink","ref","attrs","useAttrs","router","useRouter","route","useRoute","routerUrl","computed","_a","activeRoute","exactRoute","sanitizedAttributes","onClick","sanitized","onSpace"],"mappings":";;;;AAQA,MAAAA,IAAeC,EAAgB;AAAA,EAC7B,MAAM;AAAA,EACN,YAAY;AAAA,IACV,UAAAC;AAAA,EAAA;AAAA,EAEF,OAAO;AAAA;AAAA;AAAA;AAAA,IAIL,MAAM,EAAE,MAAM,QAAQ,SAAS,KAAA;AAAA;AAAA;AAAA;AAAA,IAI/B,SAAS,EAAE,MAAM,SAAS,SAAS,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAKnC,cAAc,EAAE,MAAM,QAAkC,SAASC,EAAiB,KAAA;AAAA;AAAA;AAAA;AAAA,IAIlF,mBAAmB,EAAE,MAAM,SAAS,SAAS,GAAA;AAAA,EAAM;AAAA,EAErD,OAAO;AAAA;AAAA;AAAA;AAAA;AAAA,IAKL;AAAA,EAAA;AAAA,EAEF,MAAMC,GAAO,EAAE,MAAAC,GAAM,QAAAC,KAAU;AAC7B,UAAMC,IAAWC,EAA8B,IAAI,GAC7CC,IAAQC,EAAA,GACRC,IAASC,EAAA,GACTC,IAAQC,EAAA,GACRC,IAAYC,EAAS,MAAA;;AAAO,eAAAC,IAAAb,EAAM,SAAN,gBAAAa,EAAY,QAAQ,UAAS,IAAIb,EAAM,OAAO;AAAA,KAAU,GAEpFc,IAAcF,EAAS,MAAMZ,EAAM,QAAQA,EAAM,KAAK,QAAQS,EAAM,QAAQ,MAAM,CAAC,GACnFM,IAAaH,EAAS,MAAME,EAAY,SAASd,EAAM,SAASS,EAAM,QAAQ,GAE9EO,IAAsBJ,EAAS,MAAM;AAEzC,YAAM,EAAE,SAAAK,GAAS,GAAGC,MAAcb;AAClC,aAAOa;AAAA,IACT,CAAC,GAEKD,IAAU,MAAM;AACpB,MAAAhB,EAAK,OAAO;AAAA,IACd,GAEMkB,IAAU,YAAY;AAC1B,MAAAF,EAAA,GAEIN,EAAU,QACZ,MAAMJ,EAAO,KAAKP,EAAM,IAAI,IACnBA,EAAM,QACf,OAAO,SAAS,QAAQA,EAAM,IAAI;AAAA,IAEtC;AAEA,WAAAE,EAAO,EAAE,UAAAC,GAAU,GAEZ;AAAA,MACL,UAAAA;AAAA,MACA,WAAAQ;AAAA,MACA,qBAAAK;AAAA,MACA,aAAAF;AAAA,MACA,YAAAC;AAAA,MACA,SAAAE;AAAA,MACA,SAAAE;AAAA,IAAA;AAAA,EAEJ;AACF,CAAC;"}
@@ -1,2 +1,2 @@
1
- "use strict";const r=require("./NeonLink.cjs.js"),n=require("vue"),s=require("../../../_virtual/_plugin-vue_export-helper.cjs.js"),k=["href"];function a(e,o,p,d,y,C){const l=n.resolveComponent("router-link"),t=n.resolveComponent("neon-icon");return e.routerUrl?(n.openBlock(),n.createBlock(l,n.mergeProps({key:0,class:[[{"neon-link--no-style":e.noStyle,"neon-link--active":e.activeRoute,"neon-link--exact-active":e.exactRoute},`neon-link--outline-${e.outlineStyle}`],"neon-link neon-link--router-link"],to:e.routerUrl,tabindex:"0"},e.sanitizedAttributes,{onClick:e.onClick,onKeydown:[n.withKeys(e.onClick,["enter"]),n.withKeys(n.withModifiers(e.onSpace,["prevent"]),["space"])]}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default")]),_:3},16,["class","to","onClick","onKeydown"])):e.href?(n.openBlock(),n.createElementBlock("a",n.mergeProps({key:1,class:[[{"neon-link--no-style":e.noStyle,"neon-link--with-external-indicator":e.externalIndicator,"neon-link--active":e.activeRoute,"neon-link--exact-active":e.exactRoute},`neon-link--outline-${e.outlineStyle}`],"neon-link neon-link--external-link"],href:e.href,rel:"noopener",tabindex:"0"},e.sanitizedAttributes,{onClick:o[0]||(o[0]=(...i)=>e.onClick&&e.onClick(...i)),onKeydown:[o[1]||(o[1]=n.withKeys((...i)=>e.onClick&&e.onClick(...i),["enter"])),o[2]||(o[2]=n.withKeys(n.withModifiers((...i)=>e.onSpace&&e.onSpace(...i),["prevent"]),["space"]))]}),[n.renderSlot(e.$slots,"default"),e.externalIndicator?(n.openBlock(),n.createBlock(t,{key:0,class:"neon-link__external-indicator",color:"low-contrast",name:"share-external-link-1"})):n.createCommentVNode("",!0)],16,k)):(n.openBlock(),n.createElementBlock("a",n.mergeProps({key:2,class:[[{"neon-link--no-style":e.noStyle},`neon-link--outline-${e.outlineStyle}`],"neon-link"],tabindex:"0"},e.sanitizedAttributes,{onClick:o[3]||(o[3]=(...i)=>e.onClick&&e.onClick(...i)),onKeydown:[o[4]||(o[4]=n.withKeys((...i)=>e.onClick&&e.onClick(...i),["enter"])),o[5]||(o[5]=n.withKeys(n.withModifiers((...i)=>e.onSpace&&e.onSpace(...i),["prevent"]),["space"]))]}),[n.renderSlot(e.$slots,"default")],16))}const u=s(r,[["render",a]]);module.exports=u;
1
+ "use strict";const r=require("./NeonLink.cjs.js"),n=require("vue"),s=require("../../../_virtual/_plugin-vue_export-helper.cjs.js"),k=["href"];function a(e,o,p,d,y,C){const l=n.resolveComponent("router-link"),t=n.resolveComponent("neon-icon");return e.routerUrl?(n.openBlock(),n.createBlock(l,n.mergeProps({key:0,ref:"neonLink",class:[[{"neon-link--no-style":e.noStyle,"neon-link--active":e.activeRoute,"neon-link--exact-active":e.exactRoute},`neon-link--outline-${e.outlineStyle}`],"neon-link neon-link--router-link"],to:e.routerUrl,tabindex:"0"},e.sanitizedAttributes,{onClick:e.onClick,onKeydown:[n.withKeys(e.onClick,["enter"]),n.withKeys(n.withModifiers(e.onSpace,["prevent"]),["space"])]}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default")]),_:3},16,["class","to","onClick","onKeydown"])):e.href?(n.openBlock(),n.createElementBlock("a",n.mergeProps({key:1,ref:"neonLink",class:[[{"neon-link--no-style":e.noStyle,"neon-link--with-external-indicator":e.externalIndicator,"neon-link--active":e.activeRoute,"neon-link--exact-active":e.exactRoute},`neon-link--outline-${e.outlineStyle}`],"neon-link neon-link--external-link"],href:e.href,rel:"noopener",tabindex:"0"},e.sanitizedAttributes,{onClick:o[0]||(o[0]=(...i)=>e.onClick&&e.onClick(...i)),onKeydown:[o[1]||(o[1]=n.withKeys((...i)=>e.onClick&&e.onClick(...i),["enter"])),o[2]||(o[2]=n.withKeys(n.withModifiers((...i)=>e.onSpace&&e.onSpace(...i),["prevent"]),["space"]))]}),[n.renderSlot(e.$slots,"default"),e.externalIndicator?(n.openBlock(),n.createBlock(t,{key:0,class:"neon-link__external-indicator",color:"low-contrast",name:"share-external-link-1"})):n.createCommentVNode("",!0)],16,k)):(n.openBlock(),n.createElementBlock("a",n.mergeProps({key:2,ref:"neonLink",class:[[{"neon-link--no-style":e.noStyle},`neon-link--outline-${e.outlineStyle}`],"neon-link"],tabindex:"0"},e.sanitizedAttributes,{onClick:o[3]||(o[3]=(...i)=>e.onClick&&e.onClick(...i)),onKeydown:[o[4]||(o[4]=n.withKeys((...i)=>e.onClick&&e.onClick(...i),["enter"])),o[5]||(o[5]=n.withKeys(n.withModifiers((...i)=>e.onSpace&&e.onSpace(...i),["prevent"]),["space"]))]}),[n.renderSlot(e.$slots,"default")],16))}const u=s(r,[["render",a]]);module.exports=u;
2
2
  //# sourceMappingURL=NeonLink.vue.cjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"NeonLink.vue.cjs.js","sources":["../../../../src/components/navigation/link/NeonLink.vue"],"sourcesContent":["<template>\n <router-link\n v-if=\"routerUrl\"\n :class=\"[\n { 'neon-link--no-style': noStyle, 'neon-link--active': activeRoute, 'neon-link--exact-active': exactRoute },\n `neon-link--outline-${outlineStyle}`,\n ]\"\n :to=\"routerUrl\"\n class=\"neon-link neon-link--router-link\"\n tabindex=\"0\"\n v-bind=\"sanitizedAttributes\"\n @click=\"onClick\"\n @keydown.enter=\"onClick\"\n @keydown.space.prevent=\"onSpace\"\n >\n <!-- @slot the content of the link -->\n <slot></slot>\n </router-link>\n <a\n v-else-if=\"href\"\n :class=\"[\n {\n 'neon-link--no-style': noStyle,\n 'neon-link--with-external-indicator': externalIndicator,\n 'neon-link--active': activeRoute,\n 'neon-link--exact-active': exactRoute,\n },\n `neon-link--outline-${outlineStyle}`,\n ]\"\n :href=\"href\"\n class=\"neon-link neon-link--external-link\"\n rel=\"noopener\"\n tabindex=\"0\"\n v-bind=\"sanitizedAttributes\"\n @click=\"onClick\"\n @keydown.enter=\"onClick\"\n @keydown.space.prevent=\"onSpace\"\n >\n <!-- @slot the content of the link -->\n <slot></slot>\n <neon-icon\n v-if=\"externalIndicator\"\n class=\"neon-link__external-indicator\"\n color=\"low-contrast\"\n name=\"share-external-link-1\"\n />\n </a>\n <a\n v-else\n :class=\"[{ 'neon-link--no-style': noStyle }, `neon-link--outline-${outlineStyle}`]\"\n class=\"neon-link\"\n tabindex=\"0\"\n v-bind=\"sanitizedAttributes\"\n @click=\"onClick\"\n @keydown.enter=\"onClick\"\n @keydown.space.prevent=\"onSpace\"\n >\n <!-- @slot the content of the link -->\n <slot></slot>\n </a>\n</template>\n\n<script lang=\"ts\" src=\"./NeonLink.ts\" />\n"],"names":["_ctx","_openBlock","_createBlock","_component_router_link","_mergeProps","_renderSlot","_createElementBlock","args","_component_neon_icon"],"mappings":"yPAEUA,EAAA,WADRC,EAAAA,YAAAC,EAAAA,YAgBcC,EAhBdC,aAgBc,OAdX,MAAK,CAAA,wBAAmCJ,EAAA,QAAO,oBAAuBA,EAAA,YAAW,0BAA6BA,EAAA,UAAU,wBAAgC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A,CAAA,OAAA,CAAA,OAG/BF,aAAaL,EAAA,OAAA,SAAA"}
1
+ {"version":3,"file":"NeonLink.vue.cjs.js","sources":["../../../../src/components/navigation/link/NeonLink.vue"],"sourcesContent":["<template>\n <router-link\n v-if=\"routerUrl\"\n ref=\"neonLink\"\n :class=\"[\n { 'neon-link--no-style': noStyle, 'neon-link--active': activeRoute, 'neon-link--exact-active': exactRoute },\n `neon-link--outline-${outlineStyle}`,\n ]\"\n :to=\"routerUrl\"\n class=\"neon-link neon-link--router-link\"\n tabindex=\"0\"\n v-bind=\"sanitizedAttributes\"\n @click=\"onClick\"\n @keydown.enter=\"onClick\"\n @keydown.space.prevent=\"onSpace\"\n >\n <!-- @slot the content of the link -->\n <slot></slot>\n </router-link>\n <a\n v-else-if=\"href\"\n ref=\"neonLink\"\n :class=\"[\n {\n 'neon-link--no-style': noStyle,\n 'neon-link--with-external-indicator': externalIndicator,\n 'neon-link--active': activeRoute,\n 'neon-link--exact-active': exactRoute,\n },\n `neon-link--outline-${outlineStyle}`,\n ]\"\n :href=\"href\"\n class=\"neon-link neon-link--external-link\"\n rel=\"noopener\"\n tabindex=\"0\"\n v-bind=\"sanitizedAttributes\"\n @click=\"onClick\"\n @keydown.enter=\"onClick\"\n @keydown.space.prevent=\"onSpace\"\n >\n <!-- @slot the content of the link -->\n <slot></slot>\n <neon-icon\n v-if=\"externalIndicator\"\n class=\"neon-link__external-indicator\"\n color=\"low-contrast\"\n name=\"share-external-link-1\"\n />\n </a>\n <a\n v-else\n ref=\"neonLink\"\n :class=\"[{ 'neon-link--no-style': noStyle }, `neon-link--outline-${outlineStyle}`]\"\n class=\"neon-link\"\n tabindex=\"0\"\n v-bind=\"sanitizedAttributes\"\n @click=\"onClick\"\n @keydown.enter=\"onClick\"\n @keydown.space.prevent=\"onSpace\"\n >\n <!-- @slot the content of the link -->\n <slot></slot>\n </a>\n</template>\n\n<script lang=\"ts\" src=\"./NeonLink.ts\" />\n"],"names":["_ctx","_openBlock","_createBl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E,WAAW,EACjB,SAAS,KACDA,EAAA,oBAAmB,CAC1B,4BAAOA,EAAA,SAAAA,EAAA,QAAA,GAAAO,CAAA,GACP,UAAO,gCAAQP,EAAA,SAAAA,EAAA,QAAA,GAAAO,CAAA,EAAO,CAAA,OAAA,CAAA,kDACCP,EAAA,SAAAA,EAAA,QAAA,GAAAO,CAAA,EAAO,CAAA,SAAA,CAAA,EAAA,CAAA,OAAA,CAAA,OAG/BF,aAAaL,EAAA,OAAA,SAAA"}
@@ -1,11 +1,12 @@
1
- import y from "./NeonLink.es.js";
2
- import { resolveComponent as a, openBlock as l, createBlock as k, mergeProps as t, withKeys as i, withModifiers as r, withCtx as f, renderSlot as s, createElementBlock as u, createCommentVNode as C } from "vue";
1
+ import f from "./NeonLink.es.js";
2
+ import { resolveComponent as s, openBlock as l, createBlock as a, mergeProps as t, withKeys as i, withModifiers as r, withCtx as y, renderSlot as k, createElementBlock as u, createCommentVNode as C } from "vue";
3
3
  import m from "../../../_virtual/_plugin-vue_export-helper.es.js";
4
4
  const S = ["href"];
5
5
  function v(n, e, $, w, b, K) {
6
- const d = a("router-link"), p = a("neon-icon");
7
- return n.routerUrl ? (l(), k(d, t({
6
+ const d = s("router-link"), p = s("neon-icon");
7
+ return n.routerUrl ? (l(), a(d, t({
8
8
  key: 0,
9
+ ref: "neonLink",
9
10
  class: [[
10
11
  { "neon-link--no-style": n.noStyle, "neon-link--active": n.activeRoute, "neon-link--exact-active": n.exactRoute },
11
12
  `neon-link--outline-${n.outlineStyle}`
@@ -19,12 +20,13 @@ function v(n, e, $, w, b, K) {
19
20
  i(r(n.onSpace, ["prevent"]), ["space"])
20
21
  ]
21
22
  }), {
22
- default: f(() => [
23
- s(n.$slots, "default")
23
+ default: y(() => [
24
+ k(n.$slots, "default")
24
25
  ]),
25
26
  _: 3
26
27
  }, 16, ["class", "to", "onClick", "onKeydown"])) : n.href ? (l(), u("a", t({
27
28
  key: 1,
29
+ ref: "neonLink",
28
30
  class: [[
29
31
  {
30
32
  "neon-link--no-style": n.noStyle,
@@ -44,8 +46,8 @@ function v(n, e, $, w, b, K) {
44
46
  e[2] || (e[2] = i(r((...o) => n.onSpace && n.onSpace(...o), ["prevent"]), ["space"]))
45
47
  ]
46
48
  }), [
47
- s(n.$slots, "default"),
48
- n.externalIndicator ? (l(), k(p, {
49
+ k(n.$slots, "default"),
50
+ n.externalIndicator ? (l(), a(p, {
49
51
  key: 0,
50
52
  class: "neon-link__external-indicator",
51
53
  color: "low-contrast",
@@ -53,6 +55,7 @@ function v(n, e, $, w, b, K) {
53
55
  })) : C("", !0)
54
56
  ], 16, S)) : (l(), u("a", t({
55
57
  key: 2,
58
+ ref: "neonLink",
56
59
  class: [[{ "neon-link--no-style": n.noStyle }, `neon-link--outline-${n.outlineStyle}`], "neon-link"],
57
60
  tabindex: "0"
58
61
  }, n.sanitizedAttributes, {
@@ -62,11 +65,11 @@ function v(n, e, $, w, b, K) {
62
65
  e[5] || (e[5] = i(r((...o) => n.onSpace && n.onSpace(...o), ["prevent"]), ["space"]))
63
66
  ]
64
67
  }), [
65
- s(n.$slots, "default")
68
+ k(n.$slots, "default")
66
69
  ], 16));
67
70
  }
68
- const A = /* @__PURE__ */ m(y, [["render", v]]);
71
+ const z = /* @__PURE__ */ m(f, [["render", v]]);
69
72
  export {
70
- A as default
73
+ z as default
71
74
  };
72
75
  //# sourceMappingURL=NeonLink.vue.es.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"NeonLink.vue.es.js","sources":["../../../../src/components/navigation/link/NeonLink.vue"],"sourcesContent":["<template>\n <router-link\n v-if=\"routerUrl\"\n :class=\"[\n { 'neon-link--no-style': noStyle, 'neon-link--active': activeRoute, 'neon-link--exact-active': exactRoute },\n `neon-link--outline-${outlineStyle}`,\n ]\"\n :to=\"routerUrl\"\n class=\"neon-link neon-link--router-link\"\n tabindex=\"0\"\n v-bind=\"sanitizedAttributes\"\n @click=\"onClick\"\n @keydown.enter=\"onClick\"\n @keydown.space.prevent=\"onSpace\"\n >\n <!-- @slot the content of the link -->\n <slot></slot>\n </router-link>\n <a\n v-else-if=\"href\"\n :class=\"[\n {\n 'neon-link--no-style': noStyle,\n 'neon-link--with-external-indicator': externalIndicator,\n 'neon-link--active': activeRoute,\n 'neon-link--exact-active': exactRoute,\n },\n `neon-link--outline-${outlineStyle}`,\n ]\"\n :href=\"href\"\n class=\"neon-link neon-link--external-link\"\n rel=\"noopener\"\n tabindex=\"0\"\n v-bind=\"sanitizedAttributes\"\n @click=\"onClick\"\n @keydown.enter=\"onClick\"\n @keydown.space.prevent=\"onSpace\"\n >\n <!-- @slot the content of the link -->\n <slot></slot>\n <neon-icon\n v-if=\"externalIndicator\"\n class=\"neon-link__external-indicator\"\n color=\"low-contrast\"\n name=\"share-external-link-1\"\n />\n </a>\n <a\n v-else\n :class=\"[{ 'neon-link--no-style': noStyle }, `neon-link--outline-${outlineStyle}`]\"\n class=\"neon-link\"\n tabindex=\"0\"\n v-bind=\"sanitizedAttributes\"\n @click=\"onClick\"\n @keydown.enter=\"onClick\"\n @keydown.space.prevent=\"onSpace\"\n >\n <!-- @slot the content of the link -->\n <slot></slot>\n </a>\n</template>\n\n<script lang=\"ts\" src=\"./NeonLink.ts\" />\n"],"names":["_ctx","_openBlock","_createBlock","_component_router_link","_mergeProps","_renderSlot","_createElementBlock","args","_component_neon_icon"],"mappings":";;;;;;SAEUA,EAAA,aADRC,KAAAC,EAgBcC,GAhBdC,EAgBc;AAAA;IAdX,OAAK,CAAA;AAAA,+BAAmCJ,EAAA,SAAO,qBAAuBA,EAAA,aAAW,2BAA6BA,EAAA,WAAU;AAAA,4BAAgCA,EAAA,YAAY;AAAA,OAK/J,kCAAkC;AAAA,IADvC,IAAIA,EAAA;AAAA,IAEL,UAAS;AAAA,KACDA,EAAA,qBAAmB;AAAA,IAC1B,SAAOA,EAAA;AAAA,IACP,WAAO;AAAA,QAAQA,EAAA,SAAO,CAAA,OAAA,CAAA;AAAA,UACCA,EAAA,SAAO,CAAA,SAAA,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BF,EAAaL,EAAA,QAAA,SAAA;AAAA;;;"}
1
+ {"version":3,"file":"NeonLink.vue.es.js","sources":["../../../../src/components/navigation/link/NeonLink.vue"],"sourcesContent":["<template>\n <router-link\n v-if=\"routerUrl\"\n ref=\"neonLink\"\n :class=\"[\n { 'neon-link--no-style': noStyle, 'neon-link--active': activeRoute, 'neon-link--exact-active': exactRoute },\n `neon-link--outline-${outlineStyle}`,\n ]\"\n :to=\"routerUrl\"\n class=\"neon-link neon-link--router-link\"\n tabindex=\"0\"\n v-bind=\"sanitizedAttributes\"\n @click=\"onClick\"\n @keydown.enter=\"onClick\"\n @keydown.space.prevent=\"onSpace\"\n >\n <!-- @slot the content of the link -->\n <slot></slot>\n </router-link>\n <a\n v-else-if=\"href\"\n ref=\"neonLink\"\n :class=\"[\n {\n 'neon-link--no-style': noStyle,\n 'neon-link--with-external-indicator': externalIndicator,\n 'neon-link--active': activeRoute,\n 'neon-link--exact-active': exactRoute,\n },\n `neon-link--outline-${outlineStyle}`,\n ]\"\n :href=\"href\"\n class=\"neon-link neon-link--external-link\"\n rel=\"noopener\"\n tabindex=\"0\"\n v-bind=\"sanitizedAttributes\"\n @click=\"onClick\"\n @keydown.enter=\"onClick\"\n @keydown.space.prevent=\"onSpace\"\n >\n <!-- @slot the content of the link -->\n <slot></slot>\n <neon-icon\n v-if=\"externalIndicator\"\n class=\"neon-link__external-indicator\"\n color=\"low-contrast\"\n name=\"share-external-link-1\"\n />\n </a>\n <a\n v-else\n ref=\"neonLink\"\n :class=\"[{ 'neon-link--no-style': noStyle }, `neon-link--outline-${outlineStyle}`]\"\n class=\"neon-link\"\n tabindex=\"0\"\n v-bind=\"sanitizedAttributes\"\n @click=\"onClick\"\n @keydown.enter=\"onClick\"\n @keydown.space.prevent=\"onSpace\"\n >\n <!-- @slot the content of the link -->\n <slot></slot>\n </a>\n</template>\n\n<script lang=\"ts\" src=\"./NeonLink.ts\" />\n"],"names":["_ctx","_openBlock","_createBlock","_component_router_link","_mergeProps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AM;AAAA,MACN,MAAK;AAAA;gBAGTP,KAAAK,EAaI,KAbJF,EAaI;AAAA;IAXF,KAAI;AAAA,IACH,OAAK,CAAA,CAAA,EAAA,uBAA4BJ,EAAA,QAAO,GAAA,sBAA0BA,EAAA,YAAY,KACzE,WAAW;AAAA,IACjB,UAAS;AAAA,KACDA,EAAA,qBAAmB;AAAA,IAC1B,mCAAOA,EAAA,WAAAA,EAAA,QAAA,GAAAO,CAAA;AAAA,IACP,WAAO;AAAA,kCAAQP,EAAA,WAAAA,EAAA,QAAA,GAAAO,CAAA,GAAO,CAAA,OAAA,CAAA;AAAA,oCACCP,EAAA,WAAAA,EAAA,QAAA,GAAAO,CAAA,GAAO,CAAA,SAAA,CAAA,GAAA,CAAA,OAAA,CAAA;AAAA;;IAG/BF,EAAaL,EAAA,QAAA,SAAA;AAAA;;;"}
@@ -1,2 +1,2 @@
1
- "use strict";const r=require("vue"),u=require("../../../common/enums/NeonFunctionalColor.cjs.js"),i=require("../../../common/enums/NeonSize.cjs.js"),s=require("../icon/NeonIcon.vue.cjs.js"),a=r.defineComponent({name:"NeonTabs",components:{NeonIcon:s},props:{tabs:{type:Array,required:!0},modelValue:{type:String,required:!0},color:{type:String,default:u.NeonFunctionalColor.Primary},size:{type:String,default:i.NeonSize.Medium},underline:{type:Boolean,default:!0}},emits:["update:modelValue"],setup(l,{emit:o}){return{onClick:(e,n=!1)=>{if(n){const t=document.getElementById(`${e}ButtonContainer`);t&&t.focus()}o("update:modelValue",e)}}}});module.exports=a;
1
+ "use strict";const o=require("vue"),s=require("../../../common/enums/NeonFunctionalColor.cjs.js"),a=require("../../../common/enums/NeonSize.cjs.js"),c=require("../icon/NeonIcon.vue.cjs.js"),d=require("../../navigation/link/NeonLink.vue.cjs.js"),m=require("../../layout/swiper/NeonSwiper.vue.cjs.js"),f=o.defineComponent({name:"NeonTabs",components:{NeonIcon:c,NeonLink:d,NeonSwiper:m},props:{tabs:{type:Array,required:!0},modelValue:{type:String,required:!0},color:{type:String,default:s.NeonFunctionalColor.Primary},size:{type:String,default:a.NeonSize.Medium},underline:{type:Boolean,default:!0},fullWidthMobile:{type:Boolean,default:!0}},emits:["update:modelValue"],setup(r,{emit:u}){const i=o.ref([]),l=(n,t=!1)=>{if(t){const e=document.getElementById(`${n}ButtonContainer`);e&&e.focus()}u("update:modelValue",n)};return o.onMounted(()=>{var t;const n=r.tabs.findIndex(e=>e.key===r.modelValue);if(n>=0){const e=(t=i.value[n])==null?void 0:t.neonLink;e&&e.scrollIntoView({block:"nearest",inline:"nearest"})}}),{onClick:l,menuItem:i}}});module.exports=f;
2
2
  //# sourceMappingURL=NeonTabs.cjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"NeonTabs.cjs.js","sources":["../../../../src/components/presentation/tabs/NeonTabs.ts?vue&type=script&src=true&lang.ts"],"sourcesContent":["import { defineComponent } from 'vue';\nimport type { NeonTabModel } from '@/common/models/NeonTabModel';\nimport { NeonFunctionalColor } from '@/common/enums/NeonFunctionalColor';\nimport { NeonSize } from '@/common/enums/NeonSize';\nimport NeonIcon from '@/components/presentation/icon/NeonIcon.vue';\n\n/**\n * A component for displaying tabbed content.\n */\nexport default defineComponent({\n name: 'NeonTabs',\n components: {\n NeonIcon,\n },\n props: {\n /**\n * The list of tabs to display.\n * */\n tabs: { type: Array as () => Array<NeonTabModel>, required: true },\n /**\n * The key of the selected tab.\n */\n modelValue: { type: String, required: true },\n /**\n * The tab highlight color (excludes low-contrast).\n */\n color: { type: String as () => NeonFunctionalColor, default: NeonFunctionalColor.Primary },\n /**\n * The tab size\n */\n size: { type: String as () => NeonSize, default: NeonSize.Medium },\n /**\n * Display a border underlining all tabs. When tabs are in an element with a border-bottom it is preferable to omit the tabs border-bottom\n */\n underline: { type: Boolean, default: true },\n },\n emits: [\n /**\n * Emitted when the selected tab is changed.\n * @type {string} The key of the selected tab.\n */\n 'update:modelValue',\n ],\n setup(_props, { emit }) {\n const onClick = (key: string, changeFocus = false) => {\n if (changeFocus) {\n const tab = document.getElementById(`${key}ButtonContainer`);\n if (tab) {\n tab.focus();\n }\n }\n emit('update:modelValue', key);\n };\n\n return {\n onClick,\n };\n },\n});\n"],"names":["_sfc_main","defineComponent","NeonIcon","NeonFunctionalColor","NeonSize","_props","emit","key","changeFocus","tab"],"mappings":"8LASAA,EAAeC,kBAAgB,CAC7B,KAAM,WACN,WAAY,CACV,SAAAC,CAAA,EAEF,MAAO,CAIL,KAAM,CAAE,KAAM,MAAoC,SAAU,EAAA,EAI5D,WAAY,CAAE,KAAM,OAAQ,SAAU,EAAA,EAItC,MAAO,CAAE,KAAM,OAAqC,QAASC,EAAAA,oBAAoB,OAAA,EAIjF,KAAM,CAAE,KAAM,OAA0B,QAASC,EAAAA,SAAS,MAAA,EAI1D,UAAW,CAAE,KAAM,QAAS,QAAS,EAAA,CAAK,EAE5C,MAAO,CAKL,mBAAA,EAEF,MAAMC,EAAQ,CAAE,KAAAC,GAAQ,CAWtB,MAAO,CACL,QAXc,CAACC,EAAaC,EAAc,KAAU,CACpD,GAAIA,EAAa,CACf,MAAMC,EAAM,SAAS,eAAe,GAAGF,CAAG,iBAAiB,EACvDE,GACFA,EAAI,MAAA,CAER,CACAH,EAAK,oBAAqBC,CAAG,CAC/B,CAGE,CAEJ,CACF,CAAC"}
1
+ {"version":3,"file":"NeonTabs.cjs.js","sources":["../../../../src/components/presentation/tabs/NeonTabs.ts?vue&type=script&src=true&lang.ts"],"sourcesContent":["import { defineComponent, onMounted, ref } from 'vue';\nimport type { NeonTabModel } from '@/common/models/NeonTabModel';\nimport { NeonFunctionalColor } from '@/common/enums/NeonFunctionalColor';\nimport { NeonSize } from '@/common/enums/NeonSize';\nimport NeonIcon from '@/components/presentation/icon/NeonIcon.vue';\nimport NeonLink from '@/components/navigation/link/NeonLink.vue';\nimport NeonSwiper from '@/components/layout/swiper/NeonSwiper.vue';\n\n/**\n * A component for displaying tabbed content.\n */\nexport default defineComponent({\n name: 'NeonTabs',\n components: {\n NeonIcon,\n NeonLink,\n NeonSwiper,\n },\n props: {\n /**\n * The list of tabs to display.\n * */\n tabs: { type: Array as () => Array<NeonTabModel>, required: true },\n /**\n * The key of the selected tab.\n */\n modelValue: { type: String, required: true },\n /**\n * The tab highlight color (excludes low-contrast).\n */\n color: { type: String as () => NeonFunctionalColor, default: NeonFunctionalColor.Primary },\n /**\n * The tab size\n */\n size: { type: String as () => NeonSize, default: NeonSize.Medium },\n /**\n * Display a border underlining all tabs. When tabs are in an element with a border-bottom it is preferable to omit the tabs border-bottom\n */\n underline: { type: Boolean, default: true },\n /**\n * Display tab buttons full screen width at the mobile-large breakpoint.\n */\n fullWidthMobile: { type: Boolean, default: true },\n },\n emits: [\n /**\n * Emitted when the selected tab is changed.\n * @type {string} The key of the selected tab.\n */\n 'update:modelValue',\n ],\n setup(props, { emit }) {\n const menuItem = ref<Array<typeof NeonLink>>([]);\n\n const onClick = (key: string, changeFocus = false) => {\n if (changeFocus) {\n const tab = document.getElementById(`${key}ButtonContainer`);\n if (tab) {\n tab.focus();\n }\n }\n emit('update:modelValue', key);\n };\n\n onMounted(() => {\n const selectedIndex = props.tabs.findIndex((tab) => tab.key === props.modelValue);\n\n if (selectedIndex >= 0) {\n const selectedElement = menuItem.value[selectedIndex]?.neonLink;\n\n if (selectedElement) {\n selectedElement.scrollIntoView({ block: 'nearest', inline: 'nearest' });\n }\n }\n });\n\n return {\n onClick,\n menuItem,\n };\n },\n});\n"],"names":["_sfc_main","defineComponent","NeonIcon","NeonLink","NeonSwiper","NeonFunctionalColor","NeonSize","props","emit","menuItem","ref","onClick","key","changeFocus","tab","onMounted","selectedIndex","selectedElement","_a"],"mappings":"4SAWAA,EAAeC,kBAAgB,CAC7B,KAAM,WACN,WAAY,CACV,SAAAC,EACA,SAAAC,EACA,WAAAC,CAAA,EAEF,MAAO,CAIL,KAAM,CAAE,KAAM,MAAoC,SAAU,EAAA,EAI5D,WAAY,CAAE,KAAM,OAAQ,SAAU,EAAA,EAItC,MAAO,CAAE,KAAM,OAAqC,QAASC,EAAAA,oBAAoB,OAAA,EAIjF,KAAM,CAAE,KAAM,OAA0B,QAASC,EAAAA,SAAS,MAAA,EAI1D,UAAW,CAAE,KAAM,QAAS,QAAS,EAAA,EAIrC,gBAAiB,CAAE,KAAM,QAAS,QAAS,EAAA,CAAK,EAElD,MAAO,CAKL,mBAAA,EAEF,MAAMC,EAAO,CAAE,KAAAC,GAAQ,CACrB,MAAMC,EAAWC,EAAAA,IAA4B,EAAE,EAEzCC,EAAU,CAACC,EAAaC,EAAc,KAAU,CACpD,GAAIA,EAAa,CACf,MAAMC,EAAM,SAAS,eAAe,GAAGF,CAAG,iBAAiB,EACvDE,GACFA,EAAI,MAAA,CAER,CACAN,EAAK,oBAAqBI,CAAG,CAC/B,EAEAG,OAAAA,EAAAA,UAAU,IAAM,OACd,MAAMC,EAAgBT,EAAM,KAAK,UAAWO,GAAQA,EAAI,MAAQP,EAAM,UAAU,EAEhF,GAAIS,GAAiB,EAAG,CACtB,MAAMC,GAAkBC,EAAAT,EAAS,MAAMO,CAAa,IAA5B,YAAAE,EAA+B,SAEnDD,GACFA,EAAgB,eAAe,CAAE,MAAO,UAAW,OAAQ,UAAW,CAE1E,CACF,CAAC,EAEM,CACL,QAAAN,EACA,SAAAF,CAAA,CAEJ,CACF,CAAC"}
@@ -1,11 +1,15 @@
1
- import { defineComponent as r } from "vue";
2
- import { NeonFunctionalColor as i } from "../../../common/enums/NeonFunctionalColor.es.js";
3
- import { NeonSize as u } from "../../../common/enums/NeonSize.es.js";
4
- import a from "../icon/NeonIcon.vue.es.js";
5
- const c = r({
1
+ import { defineComponent as u, ref as a, onMounted as m } from "vue";
2
+ import { NeonFunctionalColor as d } from "../../../common/enums/NeonFunctionalColor.es.js";
3
+ import { NeonSize as f } from "../../../common/enums/NeonSize.es.js";
4
+ import s from "../icon/NeonIcon.vue.es.js";
5
+ import p from "../../navigation/link/NeonLink.vue.es.js";
6
+ import c from "../../layout/swiper/NeonSwiper.vue.es.js";
7
+ const g = u({
6
8
  name: "NeonTabs",
7
9
  components: {
8
- NeonIcon: a
10
+ NeonIcon: s,
11
+ NeonLink: p,
12
+ NeonSwiper: c
9
13
  },
10
14
  props: {
11
15
  /**
@@ -19,15 +23,19 @@ const c = r({
19
23
  /**
20
24
  * The tab highlight color (excludes low-contrast).
21
25
  */
22
- color: { type: String, default: i.Primary },
26
+ color: { type: String, default: d.Primary },
23
27
  /**
24
28
  * The tab size
25
29
  */
26
- size: { type: String, default: u.Medium },
30
+ size: { type: String, default: f.Medium },
27
31
  /**
28
32
  * Display a border underlining all tabs. When tabs are in an element with a border-bottom it is preferable to omit the tabs border-bottom
29
33
  */
30
- underline: { type: Boolean, default: !0 }
34
+ underline: { type: Boolean, default: !0 },
35
+ /**
36
+ * Display tab buttons full screen width at the mobile-large breakpoint.
37
+ */
38
+ fullWidthMobile: { type: Boolean, default: !0 }
31
39
  },
32
40
  emits: [
33
41
  /**
@@ -36,19 +44,28 @@ const c = r({
36
44
  */
37
45
  "update:modelValue"
38
46
  ],
39
- setup(m, { emit: t }) {
40
- return {
41
- onClick: (e, n = !1) => {
42
- if (n) {
43
- const o = document.getElementById(`${e}ButtonContainer`);
44
- o && o.focus();
45
- }
46
- t("update:modelValue", e);
47
+ setup(n, { emit: i }) {
48
+ const r = a([]), l = (t, o = !1) => {
49
+ if (o) {
50
+ const e = document.getElementById(`${t}ButtonContainer`);
51
+ e && e.focus();
52
+ }
53
+ i("update:modelValue", t);
54
+ };
55
+ return m(() => {
56
+ var o;
57
+ const t = n.tabs.findIndex((e) => e.key === n.modelValue);
58
+ if (t >= 0) {
59
+ const e = (o = r.value[t]) == null ? void 0 : o.neonLink;
60
+ e && e.scrollIntoView({ block: "nearest", inline: "nearest" });
47
61
  }
62
+ }), {
63
+ onClick: l,
64
+ menuItem: r
48
65
  };
49
66
  }
50
67
  });
51
68
  export {
52
- c as default
69
+ g as default
53
70
  };
54
71
  //# sourceMappingURL=NeonTabs.es.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"NeonTabs.es.js","sources":["../../../../src/components/presentation/tabs/NeonTabs.ts?vue&type=script&src=true&lang.ts"],"sourcesContent":["import { defineComponent } from 'vue';\nimport type { NeonTabModel } from '@/common/models/NeonTabModel';\nimport { NeonFunctionalColor } from '@/common/enums/NeonFunctionalColor';\nimport { NeonSize } from '@/common/enums/NeonSize';\nimport NeonIcon from '@/components/presentation/icon/NeonIcon.vue';\n\n/**\n * A component for displaying tabbed content.\n */\nexport default defineComponent({\n name: 'NeonTabs',\n components: {\n NeonIcon,\n },\n props: {\n /**\n * The list of tabs to display.\n * */\n tabs: { type: Array as () => Array<NeonTabModel>, required: true },\n /**\n * The key of the selected tab.\n */\n modelValue: { type: String, required: true },\n /**\n * The tab highlight color (excludes low-contrast).\n */\n color: { type: String as () => NeonFunctionalColor, default: NeonFunctionalColor.Primary },\n /**\n * The tab size\n */\n size: { type: String as () => NeonSize, default: NeonSize.Medium },\n /**\n * Display a border underlining all tabs. When tabs are in an element with a border-bottom it is preferable to omit the tabs border-bottom\n */\n underline: { type: Boolean, default: true },\n },\n emits: [\n /**\n * Emitted when the selected tab is changed.\n * @type {string} The key of the selected tab.\n */\n 'update:modelValue',\n ],\n setup(_props, { emit }) {\n const onClick = (key: string, changeFocus = false) => {\n if (changeFocus) {\n const tab = document.getElementById(`${key}ButtonContainer`);\n if (tab) {\n tab.focus();\n }\n }\n emit('update:modelValue', key);\n };\n\n return {\n onClick,\n };\n },\n});\n"],"names":["_sfc_main","defineComponent","NeonIcon","NeonFunctionalColor","NeonSize","_props","emit","key","changeFocus","tab"],"mappings":";;;;AASA,MAAAA,IAAeC,EAAgB;AAAA,EAC7B,MAAM;AAAA,EACN,YAAY;AAAA,IACV,UAAAC;AAAA,EAAA;AAAA,EAEF,OAAO;AAAA;AAAA;AAAA;AAAA,IAIL,MAAM,EAAE,MAAM,OAAoC,UAAU,GAAA;AAAA;AAAA;AAAA;AAAA,IAI5D,YAAY,EAAE,MAAM,QAAQ,UAAU,GAAA;AAAA;AAAA;AAAA;AAAA,IAItC,OAAO,EAAE,MAAM,QAAqC,SAASC,EAAoB,QAAA;AAAA;AAAA;AAAA;AAAA,IAIjF,MAAM,EAAE,MAAM,QAA0B,SAASC,EAAS,OAAA;AAAA;AAAA;AAAA;AAAA,IAI1D,WAAW,EAAE,MAAM,SAAS,SAAS,GAAA;AAAA,EAAK;AAAA,EAE5C,OAAO;AAAA;AAAA;AAAA;AAAA;AAAA,IAKL;AAAA,EAAA;AAAA,EAEF,MAAMC,GAAQ,EAAE,MAAAC,KAAQ;AAWtB,WAAO;AAAA,MACL,SAXc,CAACC,GAAaC,IAAc,OAAU;AACpD,YAAIA,GAAa;AACf,gBAAMC,IAAM,SAAS,eAAe,GAAGF,CAAG,iBAAiB;AAC3D,UAAIE,KACFA,EAAI,MAAA;AAAA,QAER;AACA,QAAAH,EAAK,qBAAqBC,CAAG;AAAA,MAC/B;AAAA,IAGE;AAAA,EAEJ;AACF,CAAC;"}
1
+ {"version":3,"file":"NeonTabs.es.js","sources":["../../../../src/components/presentation/tabs/NeonTabs.ts?vue&type=script&src=true&lang.ts"],"sourcesContent":["import { defineComponent, onMounted, ref } from 'vue';\nimport type { NeonTabModel } from '@/common/models/NeonTabModel';\nimport { NeonFunctionalColor } from '@/common/enums/NeonFunctionalColor';\nimport { NeonSize } from '@/common/enums/NeonSize';\nimport NeonIcon from '@/components/presentation/icon/NeonIcon.vue';\nimport NeonLink from '@/components/navigation/link/NeonLink.vue';\nimport NeonSwiper from '@/components/layout/swiper/NeonSwiper.vue';\n\n/**\n * A component for displaying tabbed content.\n */\nexport default defineComponent({\n name: 'NeonTabs',\n components: {\n NeonIcon,\n NeonLink,\n NeonSwiper,\n },\n props: {\n /**\n * The list of tabs to display.\n * */\n tabs: { type: Array as () => Array<NeonTabModel>, required: true },\n /**\n * The key of the selected tab.\n */\n modelValue: { type: String, required: true },\n /**\n * The tab highlight color (excludes low-contrast).\n */\n color: { type: String as () => NeonFunctionalColor, default: NeonFunctionalColor.Primary },\n /**\n * The tab size\n */\n size: { type: String as () => NeonSize, default: NeonSize.Medium },\n /**\n * Display a border underlining all tabs. When tabs are in an element with a border-bottom it is preferable to omit the tabs border-bottom\n */\n underline: { type: Boolean, default: true },\n /**\n * Display tab buttons full screen width at the mobile-large breakpoint.\n */\n fullWidthMobile: { type: Boolean, default: true },\n },\n emits: [\n /**\n * Emitted when the selected tab is changed.\n * @type {string} The key of the selected tab.\n */\n 'update:modelValue',\n ],\n setup(props, { emit }) {\n const menuItem = ref<Array<typeof NeonLink>>([]);\n\n const onClick = (key: string, changeFocus = false) => {\n if (changeFocus) {\n const tab = document.getElementById(`${key}ButtonContainer`);\n if (tab) {\n tab.focus();\n }\n }\n emit('update:modelValue', key);\n };\n\n onMounted(() => {\n const selectedIndex = props.tabs.findIndex((tab) => tab.key === props.modelValue);\n\n if (selectedIndex >= 0) {\n const selectedElement = menuItem.value[selectedIndex]?.neonLink;\n\n if (selectedElement) {\n selectedElement.scrollIntoView({ block: 'nearest', inline: 'nearest' });\n }\n }\n });\n\n return {\n onClick,\n menuItem,\n };\n },\n});\n"],"names":["_sfc_main","defineComponent","NeonIcon","NeonLink","NeonSwiper","NeonFunctionalColor","NeonSize","props","emit","menuItem","ref","onClick","key","changeFocus","tab","onMounted","selectedIndex","selectedElement","_a"],"mappings":";;;;;;AAWA,MAAAA,IAAeC,EAAgB;AAAA,EAC7B,MAAM;AAAA,EACN,YAAY;AAAA,IACV,UAAAC;AAAA,IACA,UAAAC;AAAA,IACA,YAAAC;AAAA,EAAA;AAAA,EAEF,OAAO;AAAA;AAAA;AAAA;AAAA,IAIL,MAAM,EAAE,MAAM,OAAoC,UAAU,GAAA;AAAA;AAAA;AAAA;AAAA,IAI5D,YAAY,EAAE,MAAM,QAAQ,UAAU,GAAA;AAAA;AAAA;AAAA;AAAA,IAItC,OAAO,EAAE,MAAM,QAAqC,SAASC,EAAoB,QAAA;AAAA;AAAA;AAAA;AAAA,IAIjF,MAAM,EAAE,MAAM,QAA0B,SAASC,EAAS,OAAA;AAAA;AAAA;AAAA;AAAA,IAI1D,WAAW,EAAE,MAAM,SAAS,SAAS,GAAA;AAAA;AAAA;AAAA;AAAA,IAIrC,iBAAiB,EAAE,MAAM,SAAS,SAAS,GAAA;AAAA,EAAK;AAAA,EAElD,OAAO;AAAA;AAAA;AAAA;AAAA;AAAA,IAKL;AAAA,EAAA;AAAA,EAEF,MAAMC,GAAO,EAAE,MAAAC,KAAQ;AACrB,UAAMC,IAAWC,EAA4B,EAAE,GAEzCC,IAAU,CAACC,GAAaC,IAAc,OAAU;AACpD,UAAIA,GAAa;AACf,cAAMC,IAAM,SAAS,eAAe,GAAGF,CAAG,iBAAiB;AAC3D,QAAIE,KACFA,EAAI,MAAA;AAAA,MAER;AACA,MAAAN,EAAK,qBAAqBI,CAAG;AAAA,IAC/B;AAEA,WAAAG,EAAU,MAAM;;AACd,YAAMC,IAAgBT,EAAM,KAAK,UAAU,CAACO,MAAQA,EAAI,QAAQP,EAAM,UAAU;AAEhF,UAAIS,KAAiB,GAAG;AACtB,cAAMC,KAAkBC,IAAAT,EAAS,MAAMO,CAAa,MAA5B,gBAAAE,EAA+B;AAEvD,QAAID,KACFA,EAAgB,eAAe,EAAE,OAAO,WAAW,QAAQ,WAAW;AAAA,MAE1E;AAAA,IACF,CAAC,GAEM;AAAA,MACL,SAAAN;AAAA,MACA,UAAAF;AAAA,IAAA;AAAA,EAEJ;AACF,CAAC;"}
@@ -1,2 +1,2 @@
1
- "use strict";const r=require("./NeonTabs.cjs.js"),e=require("vue"),a=require("../../../_virtual/_plugin-vue_export-helper.cjs.js"),i=["id","aria-controls","aria-selected","onClick"],c=["id","tabindex","onKeydown"],u={key:1,class:"neon-tabs__menu-label"};function m(n,k,y,_,p,b){const s=e.resolveComponent("neon-icon");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass([[`neon-tabs--${n.size}`,`neon-tabs--${n.color}`],"neon-tabs"]),role:"tablist"},[e.createElementVNode("div",{class:e.normalizeClass([{"neon-tabs__menu-items--underlined":n.underline},"neon-tabs__menu-items"])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.tabs,(o,t)=>(e.openBlock(),e.createElementBlock("div",{id:`${o.key}Button`,key:o.key,"aria-controls":o.key,"aria-selected":o.key===n.modelValue,class:e.normalizeClass([{"neon-tabs__menu-item--selected":o.key===n.modelValue},"neon-tabs__menu-item"]),role:"tab",tabindex:"-1",onClick:l=>o.key!==n.modelValue&&n.onClick(o.key)},[e.createElementVNode("div",{id:`${o.key}ButtonContainer`,tabindex:o.key===n.modelValue?0:-1,class:"neon-tabs__menu-item-container",onKeydown:[e.withKeys(l=>n.onClick(n.tabs[t+1===n.tabs.length?0:t+1].key,!0),["right"]),e.withKeys(l=>n.onClick(n.tabs[t===0?n.tabs.length-1:t-1].key,!0),["left"])]},[o.icon?(e.openBlock(),e.createBlock(s,{key:0,name:o.icon,class:"neon-tabs__menu-icon"},null,8,["name"])):e.createCommentVNode("",!0),o.label?(e.openBlock(),e.createElementBlock("span",u,e.toDisplayString(o.label),1)):e.createCommentVNode("",!0)],40,c)],10,i))),128))],2),e.renderSlot(n.$slots,"default")],2)}const d=a(r,[["render",m]]);module.exports=d;
1
+ "use strict";const i=require("./NeonTabs.cjs.js"),e=require("vue"),c=require("../../../_virtual/_plugin-vue_export-helper.cjs.js"),u=["id","tabindex","onKeydown"],m={key:1,class:"neon-tabs__menu-label"};function d(n,_,p,y,C,b){const s=e.resolveComponent("neon-icon"),r=e.resolveComponent("neon-link"),a=e.resolveComponent("neon-swiper");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass([[`neon-tabs--${n.size}`,`neon-tabs--${n.color}`],"neon-tabs"]),role:"tablist"},[e.createVNode(a,{class:e.normalizeClass([{"neon-tabs__menu-items--underlined":n.underline,"neon-tabs__menu-items--full-width-mobile":n.fullWidthMobile},"neon-tabs__menu-items"])},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.tabs,(o,t)=>(e.openBlock(),e.createBlock(r,{id:`${o.key}Button`,key:o.key,ref_for:!0,ref:"menuItem","aria-controls":o.key,"aria-selected":o.key===n.modelValue,class:e.normalizeClass([{"neon-tabs__menu-item--selected":o.key===n.modelValue},"neon-tabs__menu-item"]),href:o.href,"no-style":"",role:"tab",tabindex:"-1",onClick:l=>o.key!==n.modelValue&&n.onClick(o.key)},{default:e.withCtx(()=>[e.createElementVNode("div",{id:`${o.key}ButtonContainer`,tabindex:o.key===n.modelValue?0:-1,class:"neon-tabs__menu-item-container",onKeydown:[e.withKeys(l=>n.onClick(n.tabs[t+1===n.tabs.length?0:t+1].key,!0),["right"]),e.withKeys(l=>n.onClick(n.tabs[t===0?n.tabs.length-1:t-1].key,!0),["left"])]},[o.icon?(e.openBlock(),e.createBlock(s,{key:0,name:o.icon,class:"neon-tabs__menu-icon"},null,8,["name"])):e.createCommentVNode("",!0),o.label?(e.openBlock(),e.createElementBlock("span",m,e.toDisplayString(o.label),1)):e.createCommentVNode("",!0)],40,u)]),_:2},1032,["id","aria-controls","aria-selected","class","href","onClick"]))),128))]),_:1},8,["class"]),e.renderSlot(n.$slots,"default")],2)}const k=c(i,[["render",d]]);module.exports=k;
2
2
  //# sourceMappingURL=NeonTabs.vue.cjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"NeonTabs.vue.cjs.js","sources":["../../../../src/components/presentation/tabs/NeonTabs.vue"],"sourcesContent":["<template>\n <div :class=\"[`neon-tabs--${size}`, `neon-tabs--${color}`]\" class=\"neon-tabs\" role=\"tablist\">\n <div :class=\"{ 'neon-tabs__menu-items--underlined': underline }\" class=\"neon-tabs__menu-items\">\n <div\n v-for=\"(tab, index) in tabs\"\n :id=\"`${tab.key}Button`\"\n :key=\"tab.key\"\n :aria-controls=\"tab.key\"\n :aria-selected=\"tab.key === modelValue\"\n :class=\"{ 'neon-tabs__menu-item--selected': tab.key === modelValue }\"\n class=\"neon-tabs__menu-item\"\n role=\"tab\"\n tabindex=\"-1\"\n @click=\"tab.key !== modelValue && onClick(tab.key)\"\n >\n <div\n :id=\"`${tab.key}ButtonContainer`\"\n :tabindex=\"tab.key === modelValue ? 0 : -1\"\n class=\"neon-tabs__menu-item-container\"\n @keydown.right=\"onClick(tabs[index + 1 === tabs.length ? 0 : index + 1].key, true)\"\n @keydown.left=\"onClick(tabs[index === 0 ? tabs.length - 1 : index - 1].key, true)\"\n >\n <neon-icon v-if=\"tab.icon\" :name=\"tab.icon\" class=\"neon-tabs__menu-icon\" />\n <span v-if=\"tab.label\" class=\"neon-tabs__menu-label\">{{ tab.label }}</span>\n </div>\n </div>\n </div>\n <!-- @slot Add tabs here (NeonTab). NOTE: Tabs can also be added outside the component if preferred -->\n <slot></slot>\n </div>\n</template>\n\n<script lang=\"ts\" src=\"./NeonTabs.ts\"></script>\n"],"names":["_createElementBlock","_normalizeClass","_ctx","_createElementVNode","_openBlock","_Fragment","_renderList","tab","index","$event","_createBlock","_component_neon_icon","_hoisted_3","_toDisplayString","_renderSlot"],"mappings":"+NAuBiC,MAAM,8GAtBrCA,EAAAA,mBA4BM,MAAA,CA5BA,MAAKC,EAAAA,eAAA,CAAA,CAAA,cAAiBC,EAAA,IAAI,GAAA,cAAkBA,EAAA,KAAK,IAAW,WAAW,CAAA,EAAC,KAAK,YACjFC,EAAAA,mBAwBM,MAAA,CAxBA,MAAKF,EAAAA,eAAA,CAAA,CAAA,oCAAyCC,EAAA,SAAS,EAAU,uBAAuB,CAAA,KAC5FE,EAAAA,UAAA,EAAA,EAAAJ,EAAAA,mBAsBMK,WAAA,KAAAC,EAAAA,WArBmBJ,EAAA,KAAI,CAAnBK,EAAKC,mBADfR,EAAAA,mBAsBM,MAAA,CApBH,GAAE,GAAKO,EAAI,GAAG,SACd,IAAKA,EAAI,IACT,gBAAeA,EAAI,IACnB,gBAAeA,EAAI,MAAQL,EAAA,WAC3B,0DAA2CK,EAAI,MAAQL,EAAA,YAClD,sBAAsB,CAAA,EAC5B,KAAK,MACL,SAAS,KACR,QAAKO,GAAEF,EAAI,MAAQL,EAAA,YAAcA,EAAA,QAAQK,EAAI,GAAG,IAEjDJ,EAAAA,mBASM,MAAA,CARH,GAAE,GAAKI,EAAI,GAAG,kBACd,SAAUA,EAAI,MAAQL,EAAA,WAAU,EAAA,GACjC,MAAM,iCACL,UAAO,eAAQA,EAAA,QAAQA,EAAA,KAAKM,EAAK,IAASN,EAAA,KAAK,OAAM,EAAOM,EAAK,CAAA,EAAM,IAAG,EAAA,EAAA,CAAA,OAAA,CAAA,gBAC5DN,EAAA,QAAQA,EAAA,KAAKM,IAAK,EAASN,EAAA,KAAK,OAAM,EAAOM,EAAK,CAAA,EAAM,IAAG,EAAA,EAAA,CAAA,MAAA,CAAA,KAEzDD,EAAI,oBAArBG,EAAAA,YAA2EC,EAAA,OAA/C,KAAMJ,EAAI,KAAM,MAAM,sEACtCA,EAAI,OAAhBH,YAAA,EAAAJ,EAAAA,mBAA2E,OAA3EY,EAA2EC,EAAAA,gBAAnBN,EAAI,KAAK,EAAA,CAAA,yDAKvEO,aAAaZ,EAAA,OAAA,SAAA"}
1
+ {"version":3,"file":"NeonTabs.vue.cjs.js","sources":["../../../../src/components/presentation/tabs/NeonTabs.vue"],"sourcesContent":["<template>\n <div :class=\"[`neon-tabs--${size}`, `neon-tabs--${color}`]\" class=\"neon-tabs\" role=\"tablist\">\n <neon-swiper\n :class=\"{\n 'neon-tabs__menu-items--underlined': underline,\n 'neon-tabs__menu-items--full-width-mobile': fullWidthMobile,\n }\"\n class=\"neon-tabs__menu-items\"\n >\n <neon-link\n v-for=\"(tab, index) in tabs\"\n :id=\"`${tab.key}Button`\"\n :key=\"tab.key\"\n ref=\"menuItem\"\n :aria-controls=\"tab.key\"\n :aria-selected=\"tab.key === modelValue\"\n :class=\"{ 'neon-tabs__menu-item--selected': tab.key === modelValue }\"\n :href=\"tab.href\"\n class=\"neon-tabs__menu-item\"\n no-style\n role=\"tab\"\n tabindex=\"-1\"\n @click=\"tab.key !== modelValue && onClick(tab.key)\"\n >\n <div\n :id=\"`${tab.key}ButtonContainer`\"\n :tabindex=\"tab.key === modelValue ? 0 : -1\"\n class=\"neon-tabs__menu-item-container\"\n @keydown.right=\"onClick(tabs[index + 1 === tabs.length ? 0 : index + 1].key, true)\"\n @keydown.left=\"onClick(tabs[index === 0 ? tabs.length - 1 : index - 1].key, true)\"\n >\n <neon-icon v-if=\"tab.icon\" :name=\"tab.icon\" class=\"neon-tabs__menu-icon\" />\n <span v-if=\"tab.label\" class=\"neon-tabs__menu-label\">{{ tab.label }}</span>\n </div>\n </neon-link>\n </neon-swiper>\n <!-- @slot Add tabs here (NeonTab). NOTE: Tabs can also be added outside the component if preferred -->\n <slot></slot>\n </div>\n</template>\n\n<script lang=\"ts\" src=\"./NeonTabs.ts\"></script>\n"],"names":["_createElementBlock","_normalizeClass","_ctx","_createVNode","_component_neon_swiper","_openBlock","_Fragment","_renderList","tab","index","_createBlock","_component_neon_link","$event","_createElementVNode","_component_neon_icon","_hoisted_2","_toDisplayString","_renderSlot"],"mappings":"4KAgCiC,MAAM,oLA/BrCA,EAAAA,mBAqCM,MAAA,CArCA,MAAKC,EAAAA,eAAA,CAAA,CAAA,cAAiBC,EAAA,IAAI,GAAA,cAAkBA,EAAA,KAAK,IAAW,WAAW,CAAA,EAAC,KAAK,YACjFC,EAAAA,YAiCcC,EAAA,CAhCX,MAAKH,EAAAA,eAAA,CAAA,qCAAiDC,EAAA,qDAA+DA,EAAA,iBAIhH,uBAAuB,CAAA,sBAG3B,IAA4B,EAD9BG,EAAAA,UAAA,EAAA,EAAAL,EAAAA,mBAyBYM,WAAA,KAAAC,EAAAA,WAxBaL,EAAA,KAAI,CAAnBM,EAAKC,mBADfC,EAAAA,YAyBYC,EAAA,CAvBT,GAAE,GAAKH,EAAI,GAAG,SACd,IAAKA,EAAI,eACV,IAAI,WACH,gBAAeA,EAAI,IACnB,gBAAeA,EAAI,MAAQN,EAAA,WAC3B,0DAA2CM,EAAI,MAAQN,EAAA,YAElD,sBAAsB,CAAA,EAD3B,KAAMM,EAAI,KAEX,WAAA,GACA,KAAK,MACL,SAAS,KACR,QAAKI,GAAEJ,EAAI,MAAQN,EAAA,YAAcA,EAAA,QAAQM,EAAI,GAAG,sBAEjD,IASM,CATNK,EAAAA,mBASM,MAAA,CARH,GAAE,GAAKL,EAAI,GAAG,kBACd,SAAUA,EAAI,MAAQN,EAAA,WAAU,EAAA,GACjC,MAAM,iCACL,UAAO,eAAQA,EAAA,QAAQA,EAAA,KAAKO,EAAK,IAASP,EAAA,KAAK,OAAM,EAAOO,EAAK,CAAA,EAAM,IAAG,EAAA,EAAA,CAAA,OAAA,CAAA,gBAC5DP,EAAA,QAAQA,EAAA,KAAKO,IAAK,EAASP,EAAA,KAAK,OAAM,EAAOO,EAAK,CAAA,EAAM,IAAG,EAAA,EAAA,CAAA,MAAA,CAAA,KAEzDD,EAAI,oBAArBE,EAAAA,YAA2EI,EAAA,OAA/C,KAAMN,EAAI,KAAM,MAAM,sEACtCA,EAAI,OAAhBH,YAAA,EAAAL,EAAAA,mBAA2E,OAA3Ee,EAA2EC,EAAAA,gBAAnBR,EAAI,KAAK,EAAA,CAAA,+IAKvES,aAAaf,EAAA,OAAA,SAAA"}
@@ -1,52 +1,65 @@
1
- import u from "./NeonTabs.es.js";
2
- import { resolveComponent as c, openBlock as o, createElementBlock as t, normalizeClass as l, createElementVNode as i, Fragment as k, renderList as y, withKeys as r, createBlock as _, createCommentVNode as m, toDisplayString as p, renderSlot as b } from "vue";
3
- import $ from "../../../_virtual/_plugin-vue_export-helper.es.js";
4
- const f = ["id", "aria-controls", "aria-selected", "onClick"], C = ["id", "tabindex", "onKeydown"], h = {
1
+ import f from "./NeonTabs.es.js";
2
+ import { resolveComponent as s, openBlock as o, createElementBlock as l, normalizeClass as r, createVNode as y, withCtx as i, Fragment as p, renderList as b, createBlock as m, createElementVNode as h, withKeys as u, createCommentVNode as d, toDisplayString as $, renderSlot as C } from "vue";
3
+ import w from "../../../_virtual/_plugin-vue_export-helper.es.js";
4
+ const V = ["id", "tabindex", "onKeydown"], v = {
5
5
  key: 1,
6
6
  class: "neon-tabs__menu-label"
7
7
  };
8
- function v(e, V, g, B, w, K) {
9
- const d = c("neon-icon");
10
- return o(), t("div", {
11
- class: l([[`neon-tabs--${e.size}`, `neon-tabs--${e.color}`], "neon-tabs"]),
8
+ function g(e, B, N, K, z, E) {
9
+ const c = s("neon-icon"), k = s("neon-link"), _ = s("neon-swiper");
10
+ return o(), l("div", {
11
+ class: r([[`neon-tabs--${e.size}`, `neon-tabs--${e.color}`], "neon-tabs"]),
12
12
  role: "tablist"
13
13
  }, [
14
- i("div", {
15
- class: l([{ "neon-tabs__menu-items--underlined": e.underline }, "neon-tabs__menu-items"])
16
- }, [
17
- (o(!0), t(k, null, y(e.tabs, (n, s) => (o(), t("div", {
18
- id: `${n.key}Button`,
19
- key: n.key,
20
- "aria-controls": n.key,
21
- "aria-selected": n.key === e.modelValue,
22
- class: l([{ "neon-tabs__menu-item--selected": n.key === e.modelValue }, "neon-tabs__menu-item"]),
23
- role: "tab",
24
- tabindex: "-1",
25
- onClick: (a) => n.key !== e.modelValue && e.onClick(n.key)
26
- }, [
27
- i("div", {
28
- id: `${n.key}ButtonContainer`,
29
- tabindex: n.key === e.modelValue ? 0 : -1,
30
- class: "neon-tabs__menu-item-container",
31
- onKeydown: [
32
- r((a) => e.onClick(e.tabs[s + 1 === e.tabs.length ? 0 : s + 1].key, !0), ["right"]),
33
- r((a) => e.onClick(e.tabs[s === 0 ? e.tabs.length - 1 : s - 1].key, !0), ["left"])
34
- ]
35
- }, [
36
- n.icon ? (o(), _(d, {
37
- key: 0,
38
- name: n.icon,
39
- class: "neon-tabs__menu-icon"
40
- }, null, 8, ["name"])) : m("", !0),
41
- n.label ? (o(), t("span", h, p(n.label), 1)) : m("", !0)
42
- ], 40, C)
43
- ], 10, f))), 128))
44
- ], 2),
45
- b(e.$slots, "default")
14
+ y(_, {
15
+ class: r([{
16
+ "neon-tabs__menu-items--underlined": e.underline,
17
+ "neon-tabs__menu-items--full-width-mobile": e.fullWidthMobile
18
+ }, "neon-tabs__menu-items"])
19
+ }, {
20
+ default: i(() => [
21
+ (o(!0), l(p, null, b(e.tabs, (n, t) => (o(), m(k, {
22
+ id: `${n.key}Button`,
23
+ key: n.key,
24
+ ref_for: !0,
25
+ ref: "menuItem",
26
+ "aria-controls": n.key,
27
+ "aria-selected": n.key === e.modelValue,
28
+ class: r([{ "neon-tabs__menu-item--selected": n.key === e.modelValue }, "neon-tabs__menu-item"]),
29
+ href: n.href,
30
+ "no-style": "",
31
+ role: "tab",
32
+ tabindex: "-1",
33
+ onClick: (a) => n.key !== e.modelValue && e.onClick(n.key)
34
+ }, {
35
+ default: i(() => [
36
+ h("div", {
37
+ id: `${n.key}ButtonContainer`,
38
+ tabindex: n.key === e.modelValue ? 0 : -1,
39
+ class: "neon-tabs__menu-item-container",
40
+ onKeydown: [
41
+ u((a) => e.onClick(e.tabs[t + 1 === e.tabs.length ? 0 : t + 1].key, !0), ["right"]),
42
+ u((a) => e.onClick(e.tabs[t === 0 ? e.tabs.length - 1 : t - 1].key, !0), ["left"])
43
+ ]
44
+ }, [
45
+ n.icon ? (o(), m(c, {
46
+ key: 0,
47
+ name: n.icon,
48
+ class: "neon-tabs__menu-icon"
49
+ }, null, 8, ["name"])) : d("", !0),
50
+ n.label ? (o(), l("span", v, $(n.label), 1)) : d("", !0)
51
+ ], 40, V)
52
+ ]),
53
+ _: 2
54
+ }, 1032, ["id", "aria-controls", "aria-selected", "class", "href", "onClick"]))), 128))
55
+ ]),
56
+ _: 1
57
+ }, 8, ["class"]),
58
+ C(e.$slots, "default")
46
59
  ], 2);
47
60
  }
48
- const S = /* @__PURE__ */ $(u, [["render", v]]);
61
+ const I = /* @__PURE__ */ w(f, [["render", g]]);
49
62
  export {
50
- S as default
63
+ I as default
51
64
  };
52
65
  //# sourceMappingURL=NeonTabs.vue.es.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"NeonTabs.vue.es.js","sources":["../../../../src/components/presentation/tabs/NeonTabs.vue"],"sourcesContent":["<template>\n <div :class=\"[`neon-tabs--${size}`, `neon-tabs--${color}`]\" class=\"neon-tabs\" role=\"tablist\">\n <div :class=\"{ 'neon-tabs__menu-items--underlined': underline }\" class=\"neon-tabs__menu-items\">\n <div\n v-for=\"(tab, index) in tabs\"\n :id=\"`${tab.key}Button`\"\n :key=\"tab.key\"\n :aria-controls=\"tab.key\"\n :aria-selected=\"tab.key === modelValue\"\n :class=\"{ 'neon-tabs__menu-item--selected': tab.key === modelValue }\"\n class=\"neon-tabs__menu-item\"\n role=\"tab\"\n tabindex=\"-1\"\n @click=\"tab.key !== modelValue && onClick(tab.key)\"\n >\n <div\n :id=\"`${tab.key}ButtonContainer`\"\n :tabindex=\"tab.key === modelValue ? 0 : -1\"\n class=\"neon-tabs__menu-item-container\"\n @keydown.right=\"onClick(tabs[index + 1 === tabs.length ? 0 : index + 1].key, true)\"\n @keydown.left=\"onClick(tabs[index === 0 ? tabs.length - 1 : index - 1].key, true)\"\n >\n <neon-icon v-if=\"tab.icon\" :name=\"tab.icon\" class=\"neon-tabs__menu-icon\" />\n <span v-if=\"tab.label\" class=\"neon-tabs__menu-label\">{{ tab.label }}</span>\n </div>\n </div>\n </div>\n <!-- @slot Add tabs here (NeonTab). NOTE: Tabs can also be added outside the component if preferred -->\n <slot></slot>\n </div>\n</template>\n\n<script lang=\"ts\" src=\"./NeonTabs.ts\"></script>\n"],"names":["_createElementBlock","_normalizeClass","_ctx","_createElementVNode","_openBlock","_Fragment","_renderList","tab","index","$event","_createBlock","_component_neon_icon","_hoisted_3","_toDisplayString","_renderSlot"],"mappings":";;;;;EAuBiC,OAAM;;;;cAtBrCA,EA4BM,OAAA;AAAA,IA5BA,OAAKC,EAAA,CAAA,CAAA,cAAiBC,EAAA,IAAI,IAAA,cAAkBA,EAAA,KAAK,KAAW,WAAW,CAAA;AAAA,IAAC,MAAK;AAAA;IACjFC,EA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"],"sourcesContent":["<template>\n <div :class=\"[`neon-tabs--${size}`, `neon-tabs--${color}`]\" class=\"neon-tabs\" role=\"tablist\">\n <neon-swiper\n :class=\"{\n 'neon-tabs__menu-items--underlined': underline,\n 'neon-tabs__menu-items--full-width-mobile': fullWidthMobile,\n }\"\n class=\"neon-tabs__menu-items\"\n >\n <neon-link\n v-for=\"(tab, index) in tabs\"\n :id=\"`${tab.key}Button`\"\n :key=\"tab.key\"\n ref=\"menuItem\"\n :aria-controls=\"tab.key\"\n :aria-selected=\"tab.key === modelValue\"\n :class=\"{ 'neon-tabs__menu-item--selected': tab.key === modelValue }\"\n :href=\"tab.href\"\n class=\"neon-tabs__menu-item\"\n no-style\n role=\"tab\"\n tabindex=\"-1\"\n @click=\"tab.key !== modelValue && onClick(tab.key)\"\n >\n <div\n :id=\"`${tab.key}ButtonContainer`\"\n :tabindex=\"tab.key === modelValue ? 0 : -1\"\n class=\"neon-tabs__menu-item-container\"\n @keydown.right=\"onClick(tabs[index + 1 === tabs.length ? 0 : index + 1].key, true)\"\n @keydown.left=\"onClick(tabs[index === 0 ? tabs.length - 1 : index - 1].key, true)\"\n >\n <neon-icon v-if=\"tab.icon\" :name=\"tab.icon\" class=\"neon-tabs__menu-icon\" />\n <span v-if=\"tab.label\" class=\"neon-tabs__menu-label\">{{ tab.label }}</span>\n </div>\n </neon-link>\n </neon-swiper>\n <!-- @slot Add tabs here (NeonTab). NOTE: Tabs can also be added outside the component if preferred -->\n <slot></slot>\n </div>\n</template>\n\n<script lang=\"ts\" src=\"./NeonTabs.ts\"></script>\n"],"names":["_createElementBlock","_normalizeClass","_ctx","_createVNode","_component_neon_swiper","_openBlock","_Fragment","_renderList","tab","index","_createBlock","_component_neon_link","$event","_createElementVNode","_component_neon_icon","_hoisted_2","_toDisplayString","_renderSlot"],"mappings":";;;;;EAgCiC,OAAM;;;;cA/BrCA,EAqCM,OAAA;AAAA,IArCA,OAAKC,EAAA,CAAA,CAAA,cAAiBC,EAAA,IAAI,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I,SAAhBH,EAAA,GAAAL,EAA2E,QAA3Ee,GAA2EC,EAAnBR,EAAI,KAAK,GAAA,CAAA;;;;;;;;IAKvES,EAAaf,EAAA,QAAA,SAAA;AAAA;;;"}
@@ -1,2 +1,2 @@
1
- "use strict";const e=require("vue"),n=e.defineComponent({name:"NeonFieldGroup"});module.exports=n;
1
+ "use strict";const e=require("vue"),n=require("../../../common/enums/NeonFunctionalColor.cjs.js"),o=require("../../../common/enums/NeonInputIndicatorStyle.cjs.js"),t=e.defineComponent({name:"NeonFieldGroup",props:{indicatorStyle:{type:String,default:o.NeonInputIndicatorStyle.Internal},color:{type:String,default:n.NeonFunctionalColor.Primary},disabled:{type:Boolean,default:!1}}});module.exports=t;
2
2
  //# sourceMappingURL=NeonFieldGroup.cjs.js.map