@worksafevictoria/wcl7.5 1.10.0 → 1.11.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 (39) hide show
  1. package/package.json +1 -1
  2. package/src/assets/styles/generated-icons.scss +46 -46
  3. package/src/components/Common/CardGridItem/card-grid-item-caret.vue +39 -45
  4. package/src/components/Common/CardGridItem/card-grid-item-icon.vue +1 -1
  5. package/src/components/Common/CardGridItem/index.vue +8 -2
  6. package/src/components/Containers/Carousel/index.stories.js +6 -4
  7. package/src/components/Containers/Carousel/index.vue +131 -120
  8. package/src/components/Containers/HomepageHeader/index.stories.js +1 -1
  9. package/src/components/Containers/HomepageHeaderNew/index.stories.js +3 -15
  10. package/src/components/Containers/HomepageHeaderNew/index.vue +3 -7
  11. package/src/components/Global/AppFooter/index.vue +130 -137
  12. package/src/components/Global/AppHeader/ModalSearch/index.vue +7 -1
  13. package/src/components/Global/AppHeader/index.stories.js +2 -2
  14. package/src/components/Global/AppHeaderNew/ModalSearch/index.vue +21 -17
  15. package/src/components/Global/AppHeaderNew/index.stories.js +2 -2
  16. package/src/components/Global/AppHeaderNew/index.vue +53 -24
  17. package/src/components/Global/BackToTop/index.vue +16 -16
  18. package/src/components/Global/ContrastMode/index.stories.js +1 -1
  19. package/src/components/Global/HeroHeader/index.vue +62 -73
  20. package/src/components/Global/SocialShare/index.vue +114 -129
  21. package/src/components/Global/Strip/index.vue +9 -5
  22. package/src/components/Paragraphs/Accordion/AccordionItem/index.vue +22 -24
  23. package/src/components/Paragraphs/Accordion/StepperItem/index.vue +15 -15
  24. package/src/components/Paragraphs/Calculator/CardContainer/index.vue +74 -75
  25. package/src/components/Paragraphs/Calculator/RiskLevel/index.vue +31 -39
  26. package/src/components/Paragraphs/Directory/Asbestos/Records/SingleRecord/index.vue +104 -107
  27. package/src/components/Paragraphs/Directory/Asbestos/Records/index.vue +152 -120
  28. package/src/components/Paragraphs/Directory/HSCP/Records/SingleRecord/index.vue +127 -133
  29. package/src/components/Paragraphs/Directory/HSCP/Records/index.vue +158 -128
  30. package/src/components/Paragraphs/Tabs/index.vue +4 -4
  31. package/src/components/Paragraphs/TabulatedData/index.vue +21 -20
  32. package/src/components/SubComponents/CtaButton/index.vue +47 -44
  33. package/src/components/SubComponents/Icon/README.md +2 -2
  34. package/src/components/SubComponents/Icon/example.js +1 -0
  35. package/src/components/SubComponents/Icon/index.stories.js +1 -1
  36. package/src/components/SubComponents/Icon/index.vue +47 -47
  37. package/src/components/SubComponents/ResourceGroup/cardbody.vue +49 -61
  38. package/src/components/SubComponents/VideoThumbnail/index.vue +8 -6
  39. package/src/mock/carousel-items.js +46 -81
@@ -13,6 +13,7 @@
13
13
  :height="glyphHeight"
14
14
  :glyph="glyph"
15
15
  :class="glyphClass"
16
+ icon-alt="button icon"
16
17
  />
17
18
  <arrow-right v-else-if="!rtl && !textOnly" :class="glyphClass" />
18
19
  <arrow-left v-else-if="!textOnly" :class="glyphClass" />
@@ -36,6 +37,7 @@
36
37
  :height="glyphHeight"
37
38
  :glyph="glyph"
38
39
  :class="glyphClass"
40
+ icon-alt="anchor icon"
39
41
  />
40
42
  <arrow-right v-else-if="!rtl && !textOnly" :class="glyphClass" />
41
43
  <arrow-left v-else-if="!textOnly" :class="glyphClass" />
@@ -59,6 +61,7 @@
59
61
  :height="glyphHeight"
60
62
  :glyph="glyph"
61
63
  :class="glyphClass"
64
+ icon-alt="link icon"
62
65
  />
63
66
  <arrow-right v-else-if="!rtl && !textOnly" :class="glyphClass" />
64
67
  <arrow-left v-else-if="!textOnly" :class="glyphClass" />
@@ -66,12 +69,12 @@
66
69
  </template>
67
70
 
68
71
  <script>
69
- import arrowRight from '../../../assets/icons/arrow-right.svg?component'
70
- import arrowLeft from '../../../assets/icons/arrow-left.svg?component'
71
- import icon from './../Icon/index.vue'
72
+ import arrowRight from "../../../assets/icons/arrow-right.svg?component";
73
+ import arrowLeft from "../../../assets/icons/arrow-left.svg?component";
74
+ import icon from "./../Icon/index.vue";
72
75
 
73
76
  export default {
74
- name: 'CtaButton',
77
+ name: "CtaButton",
75
78
  components: {
76
79
  arrowRight,
77
80
  arrowLeft,
@@ -80,18 +83,18 @@ export default {
80
83
  props: {
81
84
  type: {
82
85
  type: String,
83
- default: 'default',
86
+ default: "default",
84
87
  validator: (value) =>
85
- ['default', 'white', 'gray', 'workwell', 'dark'].indexOf(value) >= 0,
88
+ ["default", "white", "gray", "workwell", "dark"].indexOf(value) >= 0,
86
89
  },
87
90
  url: {
88
91
  type: String,
89
92
  required: false,
90
- default: '',
93
+ default: "",
91
94
  },
92
95
  alt: {
93
96
  type: String,
94
- default: '',
97
+ default: "",
95
98
  },
96
99
  rtl: {
97
100
  type: Boolean,
@@ -138,15 +141,15 @@ export default {
138
141
  },
139
142
  focusOutline: {
140
143
  type: String,
141
- default: 'default',
142
- validator: (value) => ['default', 'light', 'dark'].indexOf(value) >= 0,
144
+ default: "default",
145
+ validator: (value) => ["default", "light", "dark"].indexOf(value) >= 0,
143
146
  },
144
147
  },
145
148
  data() {
146
149
  return {
147
150
  arrowRight,
148
151
  arrowLeft,
149
- }
152
+ };
150
153
  },
151
154
  computed: {
152
155
  // var r = new RegExp('^(?:[a-z]+:)?//', 'i');
@@ -158,81 +161,81 @@ export default {
158
161
  // r.test('/myfolder/test.txt'); // false - relative URL
159
162
  // r.test('test'); // false - also relative URL
160
163
  isAbsolute() {
161
- let r = new RegExp('^(?:[a-z]+:)?//', 'i')
162
- return r.test(this.url)
164
+ let r = new RegExp("^(?:[a-z]+:)?//", "i");
165
+ return r.test(this.url);
163
166
  },
164
167
  // Some links come out of Drupal in the format `entity:node/551`
165
168
  // As an interim solution, make the link go to `node/551` and it
166
169
  // will render correctly. Not ideal as it doesn't forward to the
167
170
  // friendly link. Should come out of Drupal with a proper alias.
168
171
  linkUriProcessed() {
169
- if (this.url?.indexOf('entity:') === 0) {
170
- return this.url.slice(7)
171
- } else if (this.url?.indexOf('internal:') === 0) {
172
- return this.url.slice(9)
172
+ if (this.url?.indexOf("entity:") === 0) {
173
+ return this.url.slice(7);
174
+ } else if (this.url?.indexOf("internal:") === 0) {
175
+ return this.url.slice(9);
173
176
  } else {
174
- return this.url
177
+ return this.url;
175
178
  }
176
179
  },
177
180
  generatedClass() {
178
- return `wcl-cta ${this.type} ${this.rtl ? 'rtl' : ''} ${
179
- this.workwell ? 'workwell' : ''
180
- } ${this.isCentred ? 'text-center' : ''} ${
181
- this.textOnly ? 'wcl-cta--text-only' : ''
182
- } ${this.stretch ? 'wcl-cta--stretch' : ''} ${
183
- this.slim ? 'wcl-cta--slim' : ''
184
- } ${'wcl-cta--focus-' + this.focusOutline}`
181
+ return `wcl-cta ${this.type} ${this.rtl ? "rtl" : ""} ${
182
+ this.workwell ? "workwell" : ""
183
+ } ${this.isCentred ? "text-center" : ""} ${
184
+ this.textOnly ? "wcl-cta--text-only" : ""
185
+ } ${this.stretch ? "wcl-cta--stretch" : ""} ${this.slim ? "wcl-cta--slim" : ""} ${
186
+ "wcl-cta--focus-" + this.focusOutline
187
+ }`;
185
188
  },
186
189
  glyphClass() {
187
- const hasArrow = !this.glyph && !this.textOnly
190
+ const hasArrow = !this.glyph && !this.textOnly;
188
191
  return this.isCentred
189
- ? { ['wcl-cta__arrow']: hasArrow }
192
+ ? { ["wcl-cta__arrow"]: hasArrow }
190
193
  : {
191
- ['wcl-cta__arrow']: hasArrow,
192
- }
194
+ ["wcl-cta__arrow"]: hasArrow,
195
+ };
193
196
  },
194
197
  textClass() {
195
- return this.isCentred ? {} : {}
198
+ return this.isCentred ? {} : {};
196
199
  },
197
200
  },
198
201
  methods: {
199
202
  clicked() {
200
- var theEl = this.$el.getElementsByClassName('wcl-cta__link-text')
201
- var attrs
203
+ var theEl = this.$el.getElementsByClassName("wcl-cta__link-text");
204
+ var attrs;
202
205
  if (theEl && theEl.length > 0) {
203
206
  attrs = {
204
207
  //group: this.$store?.state?.page?.content?.title,
205
208
  group: this.$pageStore?.content?.title,
206
- label: theEl[0]?.innerText?.split('\n')[0],
209
+ label: theEl[0]?.innerText?.split("\n")[0],
207
210
  data: this.url,
208
- }
211
+ };
209
212
  } else {
210
213
  attrs = {
211
214
  //group: this.$store?.state?.page?.content?.title,
212
215
  group: this.$pageStore?.content?.title,
213
- label: '',
216
+ label: "",
214
217
  data: this.url,
215
- }
218
+ };
216
219
  }
217
220
  // push event to gtm
218
221
  if (this.$gtm) {
219
- this.$gtm.push({ event: 'custom.interaction.cta.click', ...attrs })
222
+ this.$gtm.push({ event: "custom.interaction.cta.click", ...attrs });
220
223
  }
221
224
  // navigate to url
222
225
  if (!this.url) {
223
226
  //donothing
224
227
  } else if (this.isAbsolute) {
225
- window.open(this.url)
228
+ window.open(this.url);
226
229
  } else {
227
- this.$router.push(this.url)
230
+ this.$router.push(this.url);
228
231
  }
229
- this.$emit('clicked')
232
+ this.$emit("clicked");
230
233
  },
231
234
  },
232
- }
235
+ };
233
236
  </script>
234
237
  <style lang="scss" scoped>
235
- @import '../../../includes/scss/all';
238
+ @import "../../../includes/scss/all";
236
239
  // styles can be found in global src/assets/styles/stylesheet.scss
237
240
  // this is because rich text html can dynamically specify cta button class
238
241
  .wcl-cta {
@@ -245,12 +248,12 @@ export default {
245
248
  &--focus {
246
249
  &-light {
247
250
  &:focus {
248
- @include focus-outline('light');
251
+ @include focus-outline("light");
249
252
  }
250
253
  }
251
254
  &-dark {
252
255
  &:focus {
253
- @include focus-outline('dark');
256
+ @include focus-outline("dark");
254
257
  }
255
258
  }
256
259
  }
@@ -9,8 +9,8 @@ Import the Icon component, and give it the URL path to the SVG file. When webpac
9
9
  ```html
10
10
  <template>
11
11
  <div id="app">
12
- <icon width="100" height="100" :glyph="Logo"></icon>
13
- <icon width="100" height="100" :glyph="Close"></icon>
12
+ <icon width="100" height="100" :glyph="Logo" icon-alt="Logo icon"></icon>
13
+ <icon width="100" height="100" :glyph="Close" icon-alt="Close icon"></icon>
14
14
  </div>
15
15
  </template>
16
16
 
@@ -3,6 +3,7 @@ const template = `
3
3
  width="40"
4
4
  height="40"
5
5
  glyph="icon"
6
+ icon-alt="icon"
6
7
  />
7
8
  `
8
9
 
@@ -29,7 +29,7 @@ const generate = (args) => ({
29
29
  },
30
30
  template: `
31
31
  <div style="margin-top:15px" :style="{background: !args.inverted ? 'white' : 'grey'}">
32
- <icon v-bind="args" />
32
+ <icon v-bind="args" icon-alt="icon" />
33
33
  </div>`
34
34
  })
35
35
 
@@ -7,9 +7,9 @@
7
7
  aria-hidden="true"
8
8
  :class="
9
9
  className +
10
- (first ? ' icon_first' : '') +
11
- (last ? ' icon_last' : '') +
12
- (inverted ? ' icon--inverted' : '')
10
+ (first ? ' icon_first' : '') +
11
+ (last ? ' icon_last' : '') +
12
+ (inverted ? ' icon--inverted' : '')
13
13
  "
14
14
  :width="width"
15
15
  :height="height"
@@ -24,104 +24,104 @@
24
24
  </template>
25
25
 
26
26
  <script>
27
- import { detectBrowser } from '../../../../lib/detect-browser'
27
+ import { detectBrowser } from "../../../../lib/detect-browser";
28
28
  // TODO: Add .visually-hidden label prop
29
29
  export default {
30
- name: 'Icon',
30
+ name: "Icon",
31
31
  props: {
32
32
  className: {
33
33
  type: String,
34
- default: ''
34
+ default: "",
35
35
  },
36
36
  glyph: {
37
37
  type: [Object, String],
38
- required: true
38
+ required: true,
39
39
  },
40
40
  width: {
41
41
  type: [Number, String],
42
- default: 32
42
+ default: 32,
43
43
  },
44
44
  height: {
45
45
  // height is required in IE
46
46
  // undefined type added in case height was going to be handled explicitly, check JobsAtHomeDay for more details
47
47
  type: [Number, String],
48
- default: 32
48
+ default: 32,
49
49
  },
50
50
  first: {
51
51
  type: Boolean,
52
- default: false
52
+ default: false,
53
53
  },
54
54
  last: {
55
55
  type: Boolean,
56
- default: false
56
+ default: false,
57
57
  },
58
58
  inverted: {
59
59
  type: Boolean,
60
- default: false
60
+ default: false,
61
61
  },
62
62
  bordered: {
63
63
  type: Boolean,
64
- default: false
64
+ default: false,
65
65
  },
66
66
  iconAlt: {
67
67
  type: String,
68
- default: ''
69
- }
68
+ default: "",
69
+ },
70
70
  },
71
71
  data() {
72
72
  return {
73
- renderedSVG: undefined
74
- }
73
+ renderedSVG: undefined,
74
+ };
75
75
  },
76
76
  computed: {
77
77
  isHtml() {
78
- return this.glyph && typeof this.glyph === 'string'
79
- }
78
+ return this.glyph && typeof this.glyph === "string";
79
+ },
80
80
  },
81
81
  mounted() {
82
- this.renderedSVG = this.getSvg()
82
+ this.renderedSVG = this.getSvg();
83
83
  },
84
84
  methods: {
85
85
  getSvg() {
86
86
  if (this.glyph) {
87
- let icon
88
- const content = String(this.glyph)
89
- const isSVGTag = content.includes('<svg')
87
+ let icon;
88
+ const content = String(this.glyph);
89
+ const isSVGTag = content.includes("<svg");
90
90
  if (!isSVGTag) {
91
- icon = document.createElement('img')
92
- icon.src = content
91
+ icon = document.createElement("img");
92
+ icon.src = content;
93
93
  } else {
94
- if (window && navigator && detectBrowser(navigator) === 'IE') {
95
- return this.glyph
94
+ if (window && navigator && detectBrowser(navigator) === "IE") {
95
+ return this.glyph;
96
96
  } else {
97
- const temp = document.createElement('div')
98
- temp.innerHTML = content
99
- icon = temp.querySelector('svg')
100
- icon.removeAttribute('width')
101
- icon.removeAttribute('height')
97
+ const temp = document.createElement("div");
98
+ temp.innerHTML = content;
99
+ icon = temp.querySelector("svg");
100
+ icon.removeAttribute("width");
101
+ icon.removeAttribute("height");
102
102
  }
103
103
  }
104
104
  if (this.iconAlt) {
105
- icon.setAttribute('alt', this.iconAlt)
105
+ icon.setAttribute("alt", this.iconAlt);
106
106
  }
107
- icon.setAttribute('width', this.width)
108
- icon.setAttribute('height', this.height)
107
+ icon.setAttribute("width", this.width);
108
+ icon.setAttribute("height", this.height);
109
109
  const customClass =
110
110
  this.className +
111
- (this.first ? ' icon_first' : '') +
112
- (this.last ? ' icon_last' : '') +
113
- (this.inverted ? ' icon--inverted' : '')
114
- icon.setAttribute('class', 'icon ' + customClass)
115
- icon.setAttribute('focusable', false)
116
- icon.setAttribute('aria-hidden', true)
117
- return icon.outerHTML
111
+ (this.first ? " icon_first" : "") +
112
+ (this.last ? " icon_last" : "") +
113
+ (this.inverted ? " icon--inverted" : "");
114
+ icon.setAttribute("class", "icon " + customClass);
115
+ icon.setAttribute("focusable", false);
116
+ icon.setAttribute("aria-hidden", true);
117
+ return icon.outerHTML;
118
118
  }
119
- return null
120
- }
121
- }
122
- }
119
+ return null;
120
+ },
121
+ },
122
+ };
123
123
  </script>
124
124
 
125
125
  <style lang="scss">
126
- @import './styles';
126
+ @import "./styles";
127
127
  </style>
@@ -30,7 +30,7 @@
30
30
  height="12"
31
31
  width="17"
32
32
  class="card_item-menu__title__caret"
33
- alt=""
33
+ alt="Card item Menu Title expand icon"
34
34
  />
35
35
  <img
36
36
  v-show="cardMenuIsOpen"
@@ -38,7 +38,7 @@
38
38
  height="12"
39
39
  width="17"
40
40
  class="card_item-menu__title__caret"
41
- alt=""
41
+ alt="Card item Menu Title collapse icon"
42
42
  />
43
43
  <h3 class="card_item-menu__title--small">
44
44
  {{ card.dropdownTitle }}
@@ -49,60 +49,48 @@
49
49
  v-if="card.fileType"
50
50
  class="card_item-menu__item card_item-menu__item--link"
51
51
  :class="{
52
- 'card_item-menu__item--hide': !cardMenuIsOpen
52
+ 'card_item-menu__item--hide': !cardMenuIsOpen,
53
53
  }"
54
54
  >
55
55
  {{ card.fileTypeTitle }}
56
56
  <column class="card_item__meta card_item__meta--filetype">
57
- <rich-text
58
- :content="card.fileType"
59
- :without-container="true"
60
- />
57
+ <rich-text :content="card.fileType" :without-container="true" />
61
58
  </column>
62
59
  </li>
63
60
  <li
64
61
  v-if="card.fileSize"
65
62
  class="card_item-menu__item card_item-menu__item--link"
66
63
  :class="{
67
- 'card_item-menu__item--hide': !cardMenuIsOpen
64
+ 'card_item-menu__item--hide': !cardMenuIsOpen,
68
65
  }"
69
66
  >
70
67
  {{ card.fileSizeTitle }}
71
68
  <column class="card_item__meta card_item__meta--filesize">
72
- <rich-text
73
- :content="card.fileSize"
74
- :without-container="true"
75
- />
69
+ <rich-text :content="card.fileSize" :without-container="true" />
76
70
  </column>
77
71
  </li>
78
72
  <li
79
73
  v-if="card.fileLength"
80
74
  class="card_item-menu__item card_item-menu__item--link"
81
75
  :class="{
82
- 'card_item-menu__item--hide': !cardMenuIsOpen
76
+ 'card_item-menu__item--hide': !cardMenuIsOpen,
83
77
  }"
84
78
  >
85
79
  {{ card.fileLengthTitle }}
86
80
  <column class="card_item__meta card_item__meta--filelength">
87
- <rich-text
88
- :content="card.fileLength"
89
- :without-container="true"
90
- />
81
+ <rich-text :content="card.fileLength" :without-container="true" />
91
82
  </column>
92
83
  </li>
93
84
  <li
94
85
  v-if="card.readingLevel"
95
86
  class="card_item-menu__item card_item-menu__item--link"
96
87
  :class="{
97
- 'card_item-menu__item--hide': !cardMenuIsOpen
88
+ 'card_item-menu__item--hide': !cardMenuIsOpen,
98
89
  }"
99
90
  >
100
91
  {{ card.readingLevelTitle }}
101
92
  <column class="card_item__meta card_item__meta--readinglevel">
102
- <rich-text
103
- :content="card.readingLevel"
104
- :without-container="true"
105
- />
93
+ <rich-text :content="card.readingLevel" :without-container="true" />
106
94
  </column>
107
95
  </li>
108
96
  </ul>
@@ -119,30 +107,30 @@
119
107
  </template>
120
108
 
121
109
  <script>
122
- import Row from '../../Containers/Row/index.vue'
123
- import Column from '../../Containers/Column/index.vue'
124
- import CardFooter from './cardfooter.vue'
125
- import documentsvg from '../../../assets/icons/document.svg?url'
126
- import CaretUp from '../../../assets/icons/caret-up.svg?url'
127
- import CaretDown from '../../../assets/icons/caret-down.svg?url'
128
- import RichText from '../../Paragraphs/RichText/index.vue'
110
+ import Row from "../../Containers/Row/index.vue";
111
+ import Column from "../../Containers/Column/index.vue";
112
+ import CardFooter from "./cardfooter.vue";
113
+ import documentsvg from "../../../assets/icons/document.svg?url";
114
+ import CaretUp from "../../../assets/icons/caret-up.svg?url";
115
+ import CaretDown from "../../../assets/icons/caret-down.svg?url";
116
+ import RichText from "../../Paragraphs/RichText/index.vue";
129
117
 
130
118
  export default {
131
119
  components: {
132
120
  Column,
133
121
  Row,
134
122
  CardFooter,
135
- RichText
123
+ RichText,
136
124
  },
137
125
  props: {
138
126
  card: {
139
127
  type: Object,
140
- required: true
128
+ required: true,
141
129
  },
142
130
  resourceType: {
143
131
  type: String,
144
- default: 'resource-group'
145
- }
132
+ default: "resource-group",
133
+ },
146
134
  },
147
135
  data() {
148
136
  return {
@@ -152,36 +140,36 @@ export default {
152
140
  documentsvg,
153
141
  CaretUp,
154
142
  CaretDown,
155
- windowWidth: 0
156
- }
143
+ windowWidth: 0,
144
+ };
157
145
  },
158
146
  computed: {
159
147
  isMobile() {
160
- return this.windowWidth < 768
148
+ return this.windowWidth < 768;
161
149
  },
162
150
  isResourceGroup() {
163
- return this.cardResourseType === 'resource-group' ? true : false
164
- }
151
+ return this.cardResourseType === "resource-group" ? true : false;
152
+ },
165
153
  },
166
154
  mounted() {
167
155
  this.$nextTick(() => {
168
- window.addEventListener('resize', this.onResize)
169
- })
170
- this.onResize()
156
+ window.addEventListener("resize", this.onResize);
157
+ });
158
+ this.onResize();
171
159
  },
172
160
  beforeDestroy() {
173
- window.removeEventListener('resize', this.onResize)
161
+ window.removeEventListener("resize", this.onResize);
174
162
  },
175
163
  methods: {
176
164
  handleMenuItemClick(menuItem) {
177
165
  if (this.isMobile || this.isResourceGroup) {
178
166
  for (let i = 0; i < menuItem.length; i++) {
179
- let newMenuItem = menuItem[i]
167
+ let newMenuItem = menuItem[i];
180
168
 
181
- this.cardMenuIsOpen = !this.cardMenuIsOpen
169
+ this.cardMenuIsOpen = !this.cardMenuIsOpen;
182
170
 
183
- newMenuItem.isOpen = false
184
- menuItem.splice(i, 1, newMenuItem)
171
+ newMenuItem.isOpen = false;
172
+ menuItem.splice(i, 1, newMenuItem);
185
173
  }
186
174
  }
187
175
  },
@@ -189,33 +177,33 @@ export default {
189
177
  if (this.isMobile || this.isResourceGroup) {
190
178
  if (event.keyCode === 32 || event.keyCode === 13) {
191
179
  for (let i = 0; i < menuItem.length; i++) {
192
- let newMenuItem = menuItem[i]
193
- this.cardMenuIsOpen = !this.cardMenuIsOpen
194
- newMenuItem.isOpen = false
195
- menuItem.splice(i, 1, newMenuItem)
180
+ let newMenuItem = menuItem[i];
181
+ this.cardMenuIsOpen = !this.cardMenuIsOpen;
182
+ newMenuItem.isOpen = false;
183
+ menuItem.splice(i, 1, newMenuItem);
196
184
  }
197
185
  }
198
186
  }
199
187
  },
200
188
  onResize() {
201
- this.windowWidth = window.innerWidth
202
- let titles = document.getElementsByClassName('card_item-menu__title')
189
+ this.windowWidth = window.innerWidth;
190
+ let titles = document.getElementsByClassName("card_item-menu__title");
203
191
  if (Array.isArray(titles)) {
204
192
  if (this.isMobile || this.isResourceGroup) {
205
193
  titles.forEach((t) => {
206
- t.setAttribute('tabIndex', '0')
207
- })
194
+ t.setAttribute("tabIndex", "0");
195
+ });
208
196
  } else {
209
197
  titles.forEach((t) => {
210
- t.removeAttribute('tabIndex')
211
- })
198
+ t.removeAttribute("tabIndex");
199
+ });
212
200
  }
213
201
  }
214
- }
215
- }
216
- }
202
+ },
203
+ },
204
+ };
217
205
  </script>
218
206
  <style lang="scss" scoped>
219
- @import '../../../includes/scss/all';
220
- @import './styles';
207
+ @import "../../../includes/scss/all";
208
+ @import "./styles";
221
209
  </style>