@worksafevictoria/wcl7.5 1.1.22 → 1.1.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/jest.config.js CHANGED
@@ -15,7 +15,7 @@ module.exports = {
15
15
  },
16
16
  transform: {
17
17
  '.*\\.vue$': '@vue/vue3-jest',
18
- '^.+\\.js$': 'babel-jest',
18
+ '^.+\\.[t|j]sx?$': 'babel-jest',
19
19
  '.+\\.(svg)$': '<rootDir>/src/mock/jest.svgtransformer.js'
20
20
  },
21
21
  transformIgnorePatterns: ['!node_modules/'],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@worksafevictoria/wcl7.5",
3
- "version": "1.1.22",
3
+ "version": "1.1.23",
4
4
  "main": "src/index.js",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -58,7 +58,8 @@
58
58
  "devDependencies": {
59
59
  "@babel/core": "^7.24.6",
60
60
  "@babel/plugin-transform-private-property-in-object": "^7.24.6",
61
- "@babel/preset-env": "^7.24.6",
61
+ "@babel/preset-env": "^7.25.3",
62
+ "@babel/preset-react": "^7.24.7",
62
63
  "@rushstack/eslint-patch": "^1.3.3",
63
64
  "@storybook/addon-a11y": "^7.6.3",
64
65
  "@storybook/addon-essentials": "^7.5.1",
@@ -72,7 +73,8 @@
72
73
  "@vue/eslint-config-prettier": "^8.0.0",
73
74
  "@vue/test-utils": "^2.4.6",
74
75
  "@vue/vue3-jest": "^29.2.6",
75
- "babel-jest": "^29.2.6",
76
+ "babel-jest": "^29.7.0",
77
+ "babel-preset-vite": "^1.1.3",
76
78
  "dotenv-webpack": "^8.1.0",
77
79
  "eslint": "^8.49.0",
78
80
  "eslint-plugin-storybook": "^0.6.15",
@@ -14,7 +14,7 @@
14
14
  class="homepage-header"
15
15
  >
16
16
  <template v-slot:top>
17
- <slot />
17
+ <slot></slot>
18
18
  </template>
19
19
 
20
20
  <template v-slot:description>
@@ -31,7 +31,6 @@ const heroTitle = 'HeroHeader hero example'
31
31
  export default {
32
32
  title: 'Global/HeroHeader',
33
33
  component: HeroHeader,
34
- tags: ['autodocs'],
35
34
  argTypes: {
36
35
  type: {
37
36
  control: 'string',
@@ -43,10 +42,9 @@ export default {
43
42
  title: 'HeroHeader default example',
44
43
  description: '<p class="intro">The page subtitle goes in here... The page subtitle goes in here... The page subtitle goes in here...</p><p><a href="#" class="cta-button">class cta-button</a></p>',
45
44
  image: {
46
- url:
47
- 'https://content-v2.api.worksafe.vic.gov.au/sites/default/files/2020-04/Topic-Coronavirus-COVID-19.jpg',
48
- alt: 'Some alt text'
49
- },
45
+ url: process.env.CONTENT_API_URL + '/sites/default/files/2020-04/Topic-Coronavirus-COVID-19.jpg',
46
+ alt: 'Some alt text'
47
+ },
50
48
  cta: cta_content,
51
49
  bgColor: false,
52
50
  breadcrumbItems: breadcrumb_content,
@@ -98,7 +98,7 @@
98
98
  >
99
99
  </column>
100
100
  </row>
101
- <social-share v-show="showSocial && type !== 'hero'" :rtl="rtl" />
101
+ <social-share v-show="showSocial && type !== 'hero'" :rtl="rtl" />
102
102
  </container>
103
103
  </div>
104
104
  <!-- Type Default -->
@@ -137,7 +137,8 @@ export default {
137
137
  }
138
138
  },
139
139
  mounted() {
140
- if (process.client) {
140
+ let winHref = window.location.href
141
+ if (winHref.toLowerCase().includes("worksafe")) {
141
142
  this.url = window.location.href;
142
143
  }
143
144
  },