@histoire/plugin-screenshot 0.10.7 → 0.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.
- package/dist/index.js +1 -1
- package/package.json +3 -3
- package/src/index.ts +1 -1
package/dist/index.js
CHANGED
|
@@ -33,7 +33,7 @@ export function HstScreenshot(options = {}) {
|
|
|
33
33
|
}
|
|
34
34
|
console.log('Rendering screenshot for', file, 'title:', story.title, 'variant:', variant.id, 'title:', variant.title);
|
|
35
35
|
for (const preset of finalOptions.presets) {
|
|
36
|
-
await captureWebsite.file(url, path.join(finalOptions.saveFolder, `${story.id}-${variant.id}.png`), {
|
|
36
|
+
await captureWebsite.file(url, path.join(finalOptions.saveFolder, `${story.id}-${variant.id}-${preset.width}x${preset.height}.png`), {
|
|
37
37
|
overwrite: true,
|
|
38
38
|
width: preset.width,
|
|
39
39
|
height: preset.height,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@histoire/plugin-screenshot",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.0",
|
|
4
4
|
"description": "Histoire plugin to take screenshots for visual regression testing",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": {
|
|
@@ -30,11 +30,11 @@
|
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@types/node": "^17.0.32",
|
|
33
|
-
"histoire": "0.
|
|
33
|
+
"histoire": "0.11.0",
|
|
34
34
|
"typescript": "^4.7.4"
|
|
35
35
|
},
|
|
36
36
|
"peerDependencies": {
|
|
37
|
-
"histoire": "^0.
|
|
37
|
+
"histoire": "^0.11.0"
|
|
38
38
|
},
|
|
39
39
|
"scripts": {
|
|
40
40
|
"build": "rimraf dist && tsc -d",
|
package/src/index.ts
CHANGED
|
@@ -64,7 +64,7 @@ export function HstScreenshot (options: ScreenshotPluginOptions = {}): Plugin {
|
|
|
64
64
|
}
|
|
65
65
|
console.log('Rendering screenshot for', file, 'title:', story.title, 'variant:', variant.id, 'title:', variant.title)
|
|
66
66
|
for (const preset of finalOptions.presets) {
|
|
67
|
-
await captureWebsite.file(url, path.join(finalOptions.saveFolder, `${story.id}-${variant.id}.png`), {
|
|
67
|
+
await captureWebsite.file(url, path.join(finalOptions.saveFolder, `${story.id}-${variant.id}-${preset.width}x${preset.height}.png`), {
|
|
68
68
|
overwrite: true,
|
|
69
69
|
width: preset.width,
|
|
70
70
|
height: preset.height,
|