mirror of
https://github.com/DustinBrett/daedalOS.git
synced 2025-12-06 00:20:05 +01:00
This commit is contained in:
parent
7afce9c3ac
commit
741a36d14d
|
|
@ -80,6 +80,7 @@
|
||||||
"error",
|
"error",
|
||||||
{ "allowNumber": true }
|
{ "allowNumber": true }
|
||||||
],
|
],
|
||||||
|
"@typescript-eslint/triple-slash-reference": "off",
|
||||||
"@typescript-eslint/use-unknown-in-catch-callback-variable": "off",
|
"@typescript-eslint/use-unknown-in-catch-callback-variable": "off",
|
||||||
"camelcase": "off",
|
"camelcase": "off",
|
||||||
"class-methods-use-this": "off",
|
"class-methods-use-this": "off",
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,7 @@ import {
|
||||||
TASKBAR_ENTRY_MENU_ITEMS,
|
TASKBAR_ENTRY_MENU_ITEMS,
|
||||||
TEST_APP_ICON,
|
TEST_APP_ICON,
|
||||||
TEST_APP_TITLE,
|
TEST_APP_TITLE,
|
||||||
|
WEBGPU_HEADLESS_NOT_SUPPORTED_BROWSERS,
|
||||||
} from "e2e/constants";
|
} from "e2e/constants";
|
||||||
import {
|
import {
|
||||||
calendarIsVisible,
|
calendarIsVisible,
|
||||||
|
|
@ -184,10 +185,14 @@ test.describe("entries", () => {
|
||||||
await contextMenuIsVisible({ page });
|
await contextMenuIsVisible({ page });
|
||||||
});
|
});
|
||||||
|
|
||||||
test("has items", async ({ page }) => {
|
test("has items", async ({ browserName, page }) => {
|
||||||
await contextMenuHasCount(TASKBAR_ENTRIES_MENU_ITEMS.length, { page });
|
const entries = TASKBAR_ENTRIES_MENU_ITEMS(
|
||||||
|
!WEBGPU_HEADLESS_NOT_SUPPORTED_BROWSERS.has(browserName)
|
||||||
|
);
|
||||||
|
|
||||||
for (const label of TASKBAR_ENTRIES_MENU_ITEMS) {
|
await contextMenuHasCount(entries.length, { page });
|
||||||
|
|
||||||
|
for (const label of entries) {
|
||||||
// eslint-disable-next-line no-await-in-loop
|
// eslint-disable-next-line no-await-in-loop
|
||||||
await contextMenuEntryIsVisible(label, { page });
|
await contextMenuEntryIsVisible(label, { page });
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -41,12 +41,7 @@ export const EXCLUDED_CONSOLE_LOGS = (
|
||||||
}
|
}
|
||||||
|
|
||||||
if (process.env.CI) {
|
if (process.env.CI) {
|
||||||
if (browserName === "chromium") {
|
if (browserName === "firefox") {
|
||||||
excludedConsoleLogs.push(
|
|
||||||
"Failed to create WebGPU Context Provider",
|
|
||||||
"WebGPU is experimental on this platform"
|
|
||||||
);
|
|
||||||
} else if (browserName === "firefox") {
|
|
||||||
excludedConsoleLogs.push(
|
excludedConsoleLogs.push(
|
||||||
"WebGL warning",
|
"WebGL warning",
|
||||||
"Failed to create WebGL context",
|
"Failed to create WebGL context",
|
||||||
|
|
@ -185,6 +180,7 @@ export const MEDIA_RECORDER_HEADLESS_NOT_SUPPORTED_BROWSERS = new Set([
|
||||||
"webkit",
|
"webkit",
|
||||||
]);
|
]);
|
||||||
export const PYODIDE_HEADLESS_NOT_SUPPORTED_BROWSERS = new Set(["firefox"]);
|
export const PYODIDE_HEADLESS_NOT_SUPPORTED_BROWSERS = new Set(["firefox"]);
|
||||||
|
export const WEBGPU_HEADLESS_NOT_SUPPORTED_BROWSERS = new Set(["webkit"]);
|
||||||
|
|
||||||
export const FILE_MENU_ITEMS = [
|
export const FILE_MENU_ITEMS = [
|
||||||
/^Open$/,
|
/^Open$/,
|
||||||
|
|
@ -221,8 +217,9 @@ export const DESKTOP_MENU_ITEMS: MenuItems = {
|
||||||
|
|
||||||
export const CLOCK_MENU_ITEMS = [/^Local time$/, /^Server time$/];
|
export const CLOCK_MENU_ITEMS = [/^Local time$/, /^Server time$/];
|
||||||
|
|
||||||
export const TASKBAR_ENTRIES_MENU_ITEMS = [
|
export const TASKBAR_ENTRIES_MENU_ITEMS = (hasWebGpu: boolean): RegExp[] => [
|
||||||
/^Enter full screen$/,
|
/^Enter full screen$/,
|
||||||
|
...(hasWebGpu ? [/^Show Talos button$/] : []),
|
||||||
/^Show the desktop$/,
|
/^Show the desktop$/,
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
||||||
1
next-env.d.ts
vendored
1
next-env.d.ts
vendored
|
|
@ -1,5 +1,6 @@
|
||||||
/// <reference types="next" />
|
/// <reference types="next" />
|
||||||
/// <reference types="next/image-types/global" />
|
/// <reference types="next/image-types/global" />
|
||||||
|
/// <reference path="./.next/types/routes.d.ts" />
|
||||||
|
|
||||||
// NOTE: This file should not be edited
|
// NOTE: This file should not be edited
|
||||||
// see https://nextjs.org/docs/pages/api-reference/config/typescript for more information.
|
// see https://nextjs.org/docs/pages/api-reference/config/typescript for more information.
|
||||||
|
|
|
||||||
30
package.json
30
package.json
|
|
@ -29,7 +29,7 @@
|
||||||
"serve": "serve out",
|
"serve": "serve out",
|
||||||
"stylelint": "stylelint --formatter=verbose **/*.ts*",
|
"stylelint": "stylelint --formatter=verbose **/*.ts*",
|
||||||
"test": "jest",
|
"test": "jest",
|
||||||
"unused-exports": "ts-prune --project tsconfig.json --ignore \"\\pages|\\e2e\" --error",
|
"unused-exports": "ts-prune --project tsconfig.json --ignore \"\\.next|pages|\\e2e\" --error",
|
||||||
"update": "yarn upgrade-interactive --latest"
|
"update": "yarn upgrade-interactive --latest"
|
||||||
},
|
},
|
||||||
"lint-staged": {
|
"lint-staged": {
|
||||||
|
|
@ -60,14 +60,14 @@
|
||||||
"gif.js": "^0.2.0",
|
"gif.js": "^0.2.0",
|
||||||
"idb": "^8.0.3",
|
"idb": "^8.0.3",
|
||||||
"ini": "^5.0.0",
|
"ini": "^5.0.0",
|
||||||
"isomorphic-git": "^1.33.0",
|
"isomorphic-git": "^1.33.1",
|
||||||
"libheif-js": "^1.19.8",
|
"libheif-js": "^1.19.8",
|
||||||
"mediainfo.js": "0.3.5",
|
"mediainfo.js": "0.3.5",
|
||||||
"minimist": "^1.2.8",
|
"minimist": "^1.2.8",
|
||||||
"motion": "^12.23.12",
|
"motion": "^12.23.12",
|
||||||
"multiformats": "^13.4.0",
|
"multiformats": "^13.4.0",
|
||||||
"music-metadata-browser": "^2.5.11",
|
"music-metadata-browser": "^2.5.11",
|
||||||
"next": "^15.4.7",
|
"next": "^15.5.2",
|
||||||
"nostr-tools": "^1.17.0",
|
"nostr-tools": "^1.17.0",
|
||||||
"opentype.js": "^1.3.4",
|
"opentype.js": "^1.3.4",
|
||||||
"playlist-parser": "^0.0.12",
|
"playlist-parser": "^0.0.12",
|
||||||
|
|
@ -86,9 +86,9 @@
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"7z-wasm": "^1.2.0",
|
"7z-wasm": "^1.2.0",
|
||||||
"@axe-core/playwright": "^4.10.2",
|
"@axe-core/playwright": "^4.10.2",
|
||||||
"@next/bundle-analyzer": "^15.4.7",
|
"@next/bundle-analyzer": "^15.5.2",
|
||||||
"@next/eslint-plugin-next": "^15.4.7",
|
"@next/eslint-plugin-next": "^15.5.2",
|
||||||
"@playwright/test": "^1.54.2",
|
"@playwright/test": "^1.55.0",
|
||||||
"@types/canvas-confetti": "^1.9.0",
|
"@types/canvas-confetti": "^1.9.0",
|
||||||
"@types/dom-chromium-ai": "0.0.6",
|
"@types/dom-chromium-ai": "0.0.6",
|
||||||
"@types/dompurify": "^3.2.0",
|
"@types/dompurify": "^3.2.0",
|
||||||
|
|
@ -100,19 +100,19 @@
|
||||||
"@types/node": "^24.3.0",
|
"@types/node": "^24.3.0",
|
||||||
"@types/offscreencanvas": "^2019.7.3",
|
"@types/offscreencanvas": "^2019.7.3",
|
||||||
"@types/opentype.js": "^1.3.8",
|
"@types/opentype.js": "^1.3.8",
|
||||||
"@types/react": "^19.1.10",
|
"@types/react": "^19.1.12",
|
||||||
"@types/react-dom": "^19.1.7",
|
"@types/react-dom": "^19.1.9",
|
||||||
"@types/ua-parser-js": "^0.7.39",
|
"@types/ua-parser-js": "^0.7.39",
|
||||||
"@types/video.js": "^7.3.58",
|
"@types/video.js": "^7.3.58",
|
||||||
"@types/wicg-file-system-access": "^2023.10.6",
|
"@types/wicg-file-system-access": "^2023.10.6",
|
||||||
"@typescript-eslint/eslint-plugin": "^8.40.0",
|
"@typescript-eslint/eslint-plugin": "^8.41.0",
|
||||||
"@typescript-eslint/parser": "^8.40.0",
|
"@typescript-eslint/parser": "^8.41.0",
|
||||||
"emulators": "^8.3.9",
|
"emulators": "^8.3.9",
|
||||||
"emulators-ui": "^0.73.9",
|
"emulators-ui": "^0.73.9",
|
||||||
"eruda": "^3.4.3",
|
"eruda": "^3.4.3",
|
||||||
"eslint": "^8.57.0",
|
"eslint": "^8.57.0",
|
||||||
"eslint-config-airbnb": "^19.0.4",
|
"eslint-config-airbnb": "^19.0.4",
|
||||||
"eslint-config-next": "^15.4.7",
|
"eslint-config-next": "^15.5.2",
|
||||||
"eslint-config-prettier": "^10.1.8",
|
"eslint-config-prettier": "^10.1.8",
|
||||||
"eslint-plugin-deprecation": "^3.0.0",
|
"eslint-plugin-deprecation": "^3.0.0",
|
||||||
"eslint-plugin-import": "^2.32.0",
|
"eslint-plugin-import": "^2.32.0",
|
||||||
|
|
@ -125,7 +125,7 @@
|
||||||
"eslint-plugin-react-hooks": "^5.2.0",
|
"eslint-plugin-react-hooks": "^5.2.0",
|
||||||
"eslint-plugin-react-hooks-addons": "^0.5.0",
|
"eslint-plugin-react-hooks-addons": "^0.5.0",
|
||||||
"eslint-plugin-regexp": "^2.10.0",
|
"eslint-plugin-regexp": "^2.10.0",
|
||||||
"eslint-plugin-sonarjs": "^3.0.4",
|
"eslint-plugin-sonarjs": "^3.0.5",
|
||||||
"eslint-plugin-sort-keys-fix": "^1.1.2",
|
"eslint-plugin-sort-keys-fix": "^1.1.2",
|
||||||
"eslint-plugin-typescript-sort-keys": "^3.3.0",
|
"eslint-plugin-typescript-sort-keys": "^3.3.0",
|
||||||
"eslint-plugin-unicorn": "^56.0.1",
|
"eslint-plugin-unicorn": "^56.0.1",
|
||||||
|
|
@ -133,13 +133,13 @@
|
||||||
"html-minifier-terser": "^7.2.0",
|
"html-minifier-terser": "^7.2.0",
|
||||||
"html-to-image": "^1.11.13",
|
"html-to-image": "^1.11.13",
|
||||||
"husky": "^9.1.7",
|
"husky": "^9.1.7",
|
||||||
"jest": "^30.0.5",
|
"jest": "^30.1.1",
|
||||||
"jest-environment-jsdom": "^30.0.5",
|
"jest-environment-jsdom": "^30.1.1",
|
||||||
"lint-staged": "^16.1.5",
|
"lint-staged": "^16.1.5",
|
||||||
"lunr": "^2.3.9",
|
"lunr": "^2.3.9",
|
||||||
"monaco-editor": "^0.52.2",
|
"monaco-editor": "^0.52.2",
|
||||||
"pdfjs-dist": "^5.4.54",
|
"pdfjs-dist": "^5.4.54",
|
||||||
"playwright-core": "^1.54.2",
|
"playwright-core": "^1.55.0",
|
||||||
"postcss": "^8.5.6",
|
"postcss": "^8.5.6",
|
||||||
"postcss-styled-syntax": "^0.7.1",
|
"postcss-styled-syntax": "^0.7.1",
|
||||||
"postcss-syntax": "^0.36.2",
|
"postcss-syntax": "^0.36.2",
|
||||||
|
|
|
||||||
|
|
@ -1,17 +1,26 @@
|
||||||
import { type PlaywrightTestConfig, devices } from "@playwright/test";
|
import { type PlaywrightTestConfig, devices } from "@playwright/test";
|
||||||
|
|
||||||
const overrideUrl = "";
|
const OVERRIDE_URL = "";
|
||||||
const { CI, PORT = 3000 } = process.env;
|
const { CI, PORT = 3000 } = process.env;
|
||||||
|
|
||||||
const {
|
const {
|
||||||
"Desktop Chrome": chrome,
|
"Desktop Chrome": chrome,
|
||||||
"Desktop Firefox": firefox,
|
"Desktop Firefox": firefox,
|
||||||
"Desktop Safari": safari,
|
"Desktop Safari": safari,
|
||||||
} = devices;
|
} = devices;
|
||||||
const baseURL = overrideUrl || `http://localhost:${PORT}`;
|
const baseURL = OVERRIDE_URL || `http://localhost:${PORT}`;
|
||||||
const config: PlaywrightTestConfig = {
|
const config: PlaywrightTestConfig = {
|
||||||
fullyParallel: true,
|
fullyParallel: true,
|
||||||
projects: [
|
projects: [
|
||||||
{ name: "chromium", use: chrome },
|
{
|
||||||
|
name: "chromium",
|
||||||
|
use: {
|
||||||
|
...chrome,
|
||||||
|
launchOptions: {
|
||||||
|
args: ["--enable-gpu", "--use-gl=angle"],
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
{ name: "firefox", use: firefox },
|
{ name: "firefox", use: firefox },
|
||||||
{ name: "webkit", use: safari },
|
{ name: "webkit", use: safari },
|
||||||
],
|
],
|
||||||
|
|
@ -24,9 +33,9 @@ const config: PlaywrightTestConfig = {
|
||||||
video: "retain-on-failure",
|
video: "retain-on-failure",
|
||||||
},
|
},
|
||||||
webServer: {
|
webServer: {
|
||||||
command: overrideUrl ? "" : CI ? "yarn serve" : "yarn dev",
|
command: OVERRIDE_URL ? "" : CI ? "yarn serve" : "yarn dev",
|
||||||
reuseExistingServer: Boolean(overrideUrl),
|
reuseExistingServer: Boolean(OVERRIDE_URL),
|
||||||
url: overrideUrl || baseURL,
|
url: OVERRIDE_URL || baseURL,
|
||||||
},
|
},
|
||||||
workers: CI ? 1 : undefined,
|
workers: CI ? 1 : undefined,
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user