forked from opencollective/opencollective-frontend
-
Notifications
You must be signed in to change notification settings - Fork 0
/
lostpixel.config.ts
28 lines (26 loc) · 878 Bytes
/
lostpixel.config.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// eslint-disable-next-line n/no-unpublished-import
import type { CustomProjectConfig } from 'lost-pixel';
// config file
// ts-unused-exports:disable-next-line
export const config: Partial<CustomProjectConfig> = {
storybookShots: {
storybookUrl: './storybook-static',
},
lostPixelProjectId: process.env.LOST_PIXEL_PROJECT_ID,
apiKey: process.env.LOST_PIXEL_API_KEY,
beforeScreenshot: async page => {
await page.addStyleTag({
content: `
/* Hide images from live domains as they may sometimes change or not load properly */
image[src*="https://images.opencollective.com/"],
image[src*="https://images-staging.opencollective.com/"] {
visibility: hidden;
}
/* Disable all background images for the same reason */
* {
background-image: none !important;
}
`,
});
},
};