@unimelb/pattern-lib-vue 16.0.0-alpha.34 → 16.0.0-alpha.36
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/.out/vue.js +1 -1
- package/README.md +36 -10
- package/package.json +7 -9
package/README.md
CHANGED
|
@@ -17,7 +17,7 @@ The contents of this repository have been produced by The University of Melbourn
|
|
|
17
17
|
|
|
18
18
|
The design system requires:
|
|
19
19
|
|
|
20
|
-
- [Node](https://nodejs.org/en/) (
|
|
20
|
+
- [Node](https://nodejs.org/en/) (>=v22.17.0)
|
|
21
21
|
- [Yarn](https://yarnpkg.com/lang/en/docs/install/) (latest version)
|
|
22
22
|
|
|
23
23
|
```bash
|
|
@@ -127,11 +127,8 @@ JS files and single-file Vue components are linted on the fly with ESLint. The c
|
|
|
127
127
|
For your own sanity, make sure to install your code editor's ESLint and stylelint extensions. The following commands are available for on-demand linting and fixing:
|
|
128
128
|
|
|
129
129
|
- `yarn lint`
|
|
130
|
-
- `yarn lint:fix`
|
|
131
130
|
- `yarn lint:css`
|
|
132
|
-
- `yarn lint:css --fix`
|
|
133
131
|
- `yarn lint:js`
|
|
134
|
-
- `yarn lint:js --fix`
|
|
135
132
|
|
|
136
133
|
## Release process
|
|
137
134
|
|
|
@@ -147,7 +144,8 @@ For your own sanity, make sure to install your code editor's ESLint and stylelin
|
|
|
147
144
|
|
|
148
145
|
**At the end of the release sprint:**
|
|
149
146
|
|
|
150
|
-
> [!NOTE]
|
|
147
|
+
> [!NOTE]
|
|
148
|
+
> **Note on versioning**: the version number follows the [semver](http://semver.org/) convention `MAJOR.MINOR.PATCH`, where: `MAJOR` corresponds to a breaking change (e.g. a change in a component's markup), `MINOR` to a new feature (e.g. a new component, a new feature for an existing component, etc.), and `PATCH` to a bug fix or under-the-hood change (e.g. code clean-up, performance improvement, etc.)
|
|
151
149
|
|
|
152
150
|
1. Look at all the PRs that were assigned to `next-release` throughout the sprint and identify the highest-level of change (major, minor or patch). Deduce the next release's version number and rename the milestone accordingly.
|
|
153
151
|
1. Create a new release notes draft based on the following template: `.github/RELEASE_NOTES_TEMPLATE.md`.
|
|
@@ -171,7 +169,8 @@ For your own sanity, make sure to install your code editor's ESLint and stylelin
|
|
|
171
169
|
|
|
172
170
|
Pre-release builds can be created like this (using the git pre-push hook behind the scenes):
|
|
173
171
|
|
|
174
|
-
> [!NOTE]
|
|
172
|
+
> [!NOTE]
|
|
173
|
+
> **Note on pre-release versions**: These are legitimate [semver](http://semver.org/) versions. They have the format MAJOR.MINOR.PATCH-beta.NUMBER. **Only** these pre-release versions will be published on `dev`.
|
|
175
174
|
|
|
176
175
|
1. Check out a clean `dev` branch
|
|
177
176
|
1. in bash `git push` - this will increment the pre-release version number and make a commit to your local repository
|
|
@@ -188,13 +187,40 @@ To run the component units tests use `yarn test`. This runs the jest unit and ac
|
|
|
188
187
|
### Storybook end-to-end testing
|
|
189
188
|
To run the Storybook stories visual snapshots and story tests use `yarn test:e2e`.
|
|
190
189
|
|
|
191
|
-
|
|
190
|
+
To view the e2e test report use `yarn test:report`.
|
|
192
191
|
|
|
193
|
-
|
|
192
|
+
**Note:** the visual snapshot testing runs on Playwright and requires Docker to be up and running.
|
|
193
|
+
|
|
194
|
+
#### Visual snapshot testing
|
|
195
|
+
|
|
196
|
+
You can run the Storybook stories visual snapshot tests exclusively using `yarn test:snapshots`. This compares your changes against the baseline visual snapshot. To see the failed snapshot tests run `yarn test:report`.
|
|
194
197
|
|
|
195
198
|
If you wish to update the snapshots with your changes run `yarn test:update:snapshots`.
|
|
196
199
|
|
|
197
|
-
|
|
200
|
+
> [!IMPORTANT]
|
|
201
|
+
> Whenever a new story is created or the story name is updated, it is important to update the corresponding `*.spec.js` file for the story.
|
|
202
|
+
|
|
203
|
+
#### Example
|
|
204
|
+
The story `components/grid/stories/index.stories.js` corresponds to `e2e/tests/components/grid.spec.js`.
|
|
205
|
+
```
|
|
206
|
+
const component = 'Grid';
|
|
207
|
+
const stories = [
|
|
208
|
+
'Default',
|
|
209
|
+
'Desk',
|
|
210
|
+
'Desk Combination',
|
|
211
|
+
'Tab',
|
|
212
|
+
'Tab Combination',
|
|
213
|
+
'Wide',
|
|
214
|
+
'Wide Combination',
|
|
215
|
+
'Center Grid',
|
|
216
|
+
];
|
|
217
|
+
|
|
218
|
+
testVisualStory(component, stories);
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
`testVisualStory` will run the snapshot tests on the following viewports:
|
|
222
|
+
- 1280 x 3600 - desktop
|
|
223
|
+
- 480 x 3600 - mobile
|
|
198
224
|
|
|
199
225
|
### Testing Pull-requests
|
|
200
226
|
|
|
@@ -229,7 +255,7 @@ Recommended mobile devices for testing:
|
|
|
229
255
|
### Visual Regression Tests
|
|
230
256
|
|
|
231
257
|
> [!IMPORTANT]
|
|
232
|
-
> These tests should be run
|
|
258
|
+
> These tests should be run **exclusively** on your **local** machine to detect visual regressions **before merging** your pull-request.
|
|
233
259
|
|
|
234
260
|
You can test your changes against live `production` sites to ensure nothing breaks.
|
|
235
261
|
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unimelb/pattern-lib-vue",
|
|
3
3
|
"description": "A complete design system for the University of Melbourne.",
|
|
4
|
-
"version": "16.0.0-alpha.
|
|
4
|
+
"version": "16.0.0-alpha.36",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/unimelb/pattern-lib.git"
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"author": "The University of Melbourne",
|
|
10
10
|
"license": "UNLICENSED",
|
|
11
11
|
"engines": {
|
|
12
|
-
"node": ">=22.
|
|
12
|
+
"node": ">=22.17.0",
|
|
13
13
|
"yarn": "*"
|
|
14
14
|
},
|
|
15
15
|
"type": "module",
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"@fontsource-variable/fraunces": "5.0.21",
|
|
56
56
|
"@fontsource/source-sans-pro": "5.0.8",
|
|
57
57
|
"@splidejs/vue-splide": "0.6.12",
|
|
58
|
-
"@vue/compat": "3.5.
|
|
58
|
+
"@vue/compat": "3.5.22",
|
|
59
59
|
"babel-polyfill": "6.26.0",
|
|
60
60
|
"change-case": "3.1.0",
|
|
61
61
|
"core-js": "3",
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"throttle-debounce": "2.1.0",
|
|
73
73
|
"uuid": "3.4.0",
|
|
74
74
|
"v-scroll-lock": "1.3.1",
|
|
75
|
-
"vue": "3.5.
|
|
75
|
+
"vue": "3.5.22",
|
|
76
76
|
"vue-focus-lock": "1.4.0",
|
|
77
77
|
"xss": "1.0.15"
|
|
78
78
|
},
|
|
@@ -83,7 +83,7 @@
|
|
|
83
83
|
"@babel/polyfill": "7.12.1",
|
|
84
84
|
"@babel/preset-env": "7.24.8",
|
|
85
85
|
"@babel/preset-react": "7.24.7",
|
|
86
|
-
"@playwright/test": "1.
|
|
86
|
+
"@playwright/test": "1.56.1",
|
|
87
87
|
"@storybook/addon-essentials": "8.1.11",
|
|
88
88
|
"@storybook/addon-interactions": "8.1.11",
|
|
89
89
|
"@storybook/addon-links": "8.1.11",
|
|
@@ -103,8 +103,7 @@
|
|
|
103
103
|
"@storybook/vue3-webpack5": "8.1.11",
|
|
104
104
|
"@vue/babel-helper-vue-jsx-merge-props": "1.4.0",
|
|
105
105
|
"@vue/babel-plugin-transform-vue-jsx": "1.4.0",
|
|
106
|
-
"@vue/
|
|
107
|
-
"@vue/test-utils": "2.4.0-alpha.2",
|
|
106
|
+
"@vue/test-utils": "2.4.6",
|
|
108
107
|
"@vue/vue3-jest": "29.2.6",
|
|
109
108
|
"babel-core": "6.26.3",
|
|
110
109
|
"babel-helper-vue-jsx-merge-props": "2.0.3",
|
|
@@ -182,8 +181,7 @@
|
|
|
182
181
|
"svgo-loader": "4.0.0",
|
|
183
182
|
"terser-webpack-plugin": "5.3.10",
|
|
184
183
|
"vue-axe": "1.0.7",
|
|
185
|
-
"vue-
|
|
186
|
-
"vue-loader": "17.4.2",
|
|
184
|
+
"vue-loader": "17.3.1",
|
|
187
185
|
"webpack": "5.92.1",
|
|
188
186
|
"webpack-bundle-analyzer": "4.10.2",
|
|
189
187
|
"webpack-cli": "5.1.4",
|