Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,846 changes: 1,845 additions & 1 deletion web/package-lock.json

Large diffs are not rendered by default.

7 changes: 5 additions & 2 deletions web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@
"preview": "vite preview",
"test": "jest",
"lint": "npx eslint src",
"format": "npx prettier --write \"src/**/*.js{,x}\""
"format": "npx prettier --write \"src/**/*.js{,x}\"",
"screenshots": "viteshot shoot"
},
"browserslist": {
"production": [
Expand Down Expand Up @@ -51,8 +52,10 @@
"identity-obj-proxy": "^3.0.0",
"jest": "^27.5.1",
"jest-transform-stub": "^2.0.0",
"playwright": "^1.20.2",
"prettier": "^2.5.1",
"sass": "^1.49.8",
"vite": "^2.8.4"
"vite": "^2.8.4",
"viteshot": "^0.3.1"
}
}
4 changes: 4 additions & 0 deletions web/src/InstallationFinished.screenshot.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import React from "react";
import InstallationFinished from "./InstallationFinished";

export const InstallationFinishedScreenshot = () => <InstallationFinished />;
25 changes: 25 additions & 0 deletions web/src/ScreenshotsWrapper.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import React, { StrictMode } from "react";
import { InstallerClientProvider } from "./context/installer";
import { AuthProvider } from "./context/auth";
import { createClient } from "./lib/client";

import "./patternfly.scss";
import "@fontsource/lato/400.css";
import "@fontsource/lato/400-italic.css";
import "@fontsource/lato/700.css";
import "@fontsource/poppins/300.css";
import "@fontsource/poppins/500.css";
import "@fontsource/roboto-mono/400.css";
import "./app.scss";

const client = createClient();

export const ScreenshotsWrapper = ({ children }) => (
<StrictMode>
<InstallerClientProvider client={client}>
<AuthProvider>
{children}
</AuthProvider>
</InstallerClientProvider>
</StrictMode>
);
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
30 changes: 30 additions & 0 deletions web/viteshot.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
const playwrightShooter = require("viteshot/shooters/playwright");
const playwright = require("playwright");
const viteCommonjs = require("@originjs/vite-plugin-commonjs").viteCommonjs;
const vite = require("vite");

module.exports = {
framework: {
type: "react"
},
vite: vite.defineConfig({
base: "./",
plugins: [viteCommonjs()],
optimizeDeps: {
include: ['attr-accept', '@patternfly/react-styles']
}
}),
shooter: playwrightShooter(playwright.chromium, {
contexts: {
desktop: playwright.devices["Desktop Chrome"],
desktopHiDPI: playwright.devices["Desktop Chrome HiDPI"],
pixel5: playwright.devices["Pixel 5"]
}
}),
filePathPattern: "**/*.screenshot.@(js|jsx|tsx|vue|svelte)",

wrapper: {
path: "src/ScreenshotsWrapper.jsx",
componentName: "ScreenshotsWrapper"
}
};