Skip to content

Commit ceb514c

Browse files
committed
Merge branch 'main' into mafredri/docs-ea-devcontainers
2 parents 466bc9a + 6bafe35 commit ceb514c

File tree

178 files changed

+632
-1750
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

178 files changed

+632
-1750
lines changed

site/.knip.jsonc

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"$schema": "https://unpkg.com/knip@5/schema.json",
3+
"entry": ["./src/index.tsx", "./src/serviceWorker.ts"],
4+
"project": ["./src/**/*.ts", "./src/**/*.tsx", "./e2e/**/*.ts"],
5+
"ignore": ["**/*Generated.ts"],
6+
"ignoreBinaries": ["protoc"],
7+
"ignoreDependencies": [
8+
"@types/react-virtualized-auto-sizer",
9+
"jest_workaround",
10+
"ts-proto"
11+
],
12+
// Don't report unused exports of types as long as they are used within the file.
13+
"ignoreExportsUsedInFile": {
14+
"interface": true,
15+
"type": true
16+
}
17+
}

site/biome.jsonc

+3
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@
1616
"useButtonType": { "level": "off" },
1717
"useSemanticElements": { "level": "off" }
1818
},
19+
"correctness": {
20+
"noUnusedImports": "warn"
21+
},
1922
"style": {
2023
"noNonNullAssertion": { "level": "off" },
2124
"noParameterAssign": { "level": "off" },

site/e2e/constants.ts

-8
Original file line numberDiff line numberDiff line change
@@ -78,14 +78,6 @@ export const premiumTestsRequired = Boolean(
7878

7979
export const license = process.env.CODER_E2E_LICENSE ?? "";
8080

81-
/**
82-
* Certain parts of the UI change when organizations are enabled. Organizations
83-
* are enabled by a license entitlement, and license configuration is guaranteed
84-
* to run before any other tests, so having this as a bit of "global state" is
85-
* fine.
86-
*/
87-
export const organizationsEnabled = Boolean(license);
88-
8981
// Disabling terraform tests is optional for environments without Docker + Terraform.
9082
// By default, we opt into these tests.
9183
export const requireTerraformTests = !process.env.CODER_E2E_DISABLE_TERRAFORM;

site/e2e/helpers.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ export async function login(page: Page, options: LoginOptions = users.owner) {
8181
(ctx as any)[Symbol.for("currentUser")] = options;
8282
}
8383

84-
export function currentUser(page: Page): LoginOptions {
84+
function currentUser(page: Page): LoginOptions {
8585
const ctx = page.context();
8686
// biome-ignore lint/suspicious/noExplicitAny: get the current user
8787
const user = (ctx as any)[Symbol.for("currentUser")];
@@ -875,7 +875,7 @@ export const echoResponsesWithExternalAuth = (
875875
};
876876
};
877877

878-
export const fillParameters = async (
878+
const fillParameters = async (
879879
page: Page,
880880
richParameters: RichParameter[] = [],
881881
buildParameters: WorkspaceBuildParameter[] = [],

site/e2e/tests/deployment/idpOrgSync.spec.ts

-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import {
55
deleteOrganization,
66
setupApiCalls,
77
} from "../../api";
8-
import { users } from "../../constants";
98
import { login, randomName, requiresLicense } from "../../helpers";
109
import { beforeCoderTest } from "../../hooks";
1110

site/e2e/tests/organizations/auditLogs.spec.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { type Page, expect, test } from "@playwright/test";
1+
import { expect, test } from "@playwright/test";
22
import {
33
createOrganization,
44
createOrganizationMember,

site/package.json

+5-11
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,11 @@
1313
"dev": "vite",
1414
"format": "biome format --write .",
1515
"format:check": "biome format .",
16-
"lint": "pnpm run lint:check && pnpm run lint:types && pnpm run lint:circular-deps",
16+
"lint": "pnpm run lint:check && pnpm run lint:types && pnpm run lint:circular-deps && knip",
1717
"lint:check": " biome lint --error-on-warnings .",
1818
"lint:circular-deps": "dpdm --no-tree --no-warning -T ./src/App.tsx",
19-
"lint:fix": " biome lint --error-on-warnings --write .",
19+
"lint:knip": "knip",
20+
"lint:fix": " biome lint --error-on-warnings --write . && knip --fix",
2021
"lint:types": "tsc -p .",
2122
"playwright:install": "playwright install --with-deps chromium",
2223
"playwright:test": "playwright test --config=e2e/playwright.config.ts",
@@ -29,7 +30,6 @@
2930
"test:ci": "jest --selectProjects test --silent",
3031
"test:coverage": "jest --selectProjects test --collectCoverage",
3132
"test:watch": "jest --selectProjects test --watch",
32-
"test:storybook": "test-storybook",
3333
"stats": "STATS=true pnpm build && npx http-server ./stats -p 8081 -c-1",
3434
"deadcode": "ts-prune | grep -v \".stories\\|.config\\|e2e\\|__mocks__\\|used in module\\|testHelpers\\|typesGenerated\" || echo \"No deadcode found.\"",
3535
"update-emojis": "cp -rf ./node_modules/emoji-datasource-apple/img/apple/64/* ./static/emojis"
@@ -68,7 +68,6 @@
6868
"@radix-ui/react-slot": "1.1.1",
6969
"@radix-ui/react-switch": "1.1.1",
7070
"@radix-ui/react-tooltip": "1.1.7",
71-
"@radix-ui/react-visually-hidden": "1.1.0",
7271
"@tanstack/react-query-devtools": "4.35.3",
7372
"@xterm/addon-canvas": "0.7.0",
7473
"@xterm/addon-fit": "0.10.0",
@@ -78,10 +77,8 @@
7877
"@xterm/xterm": "5.5.0",
7978
"ansi-to-html": "0.7.2",
8079
"axios": "1.8.2",
81-
"canvas": "3.1.0",
8280
"chart.js": "4.4.0",
8381
"chartjs-adapter-date-fns": "3.0.0",
84-
"chartjs-plugin-annotation": "3.0.1",
8582
"chroma-js": "2.4.2",
8683
"class-variance-authority": "0.7.1",
8784
"clsx": "2.1.1",
@@ -91,7 +88,6 @@
9188
"cronstrue": "2.50.0",
9289
"date-fns": "2.30.0",
9390
"dayjs": "1.11.13",
94-
"emoji-datasource-apple": "15.1.2",
9591
"emoji-mart": "5.6.0",
9692
"file-saver": "2.0.5",
9793
"formik": "2.4.6",
@@ -149,7 +145,6 @@
149145
"@tailwindcss/typography": "0.5.16",
150146
"@testing-library/jest-dom": "6.6.3",
151147
"@testing-library/react": "14.3.1",
152-
"@testing-library/react-hooks": "8.0.1",
153148
"@testing-library/user-event": "14.6.1",
154149
"@types/chroma-js": "2.4.0",
155150
"@types/color-convert": "2.0.4",
@@ -181,20 +176,19 @@
181176
"jest-location-mock": "2.0.0",
182177
"jest-websocket-mock": "2.5.0",
183178
"jest_workaround": "0.1.14",
179+
"knip": "5.51.0",
184180
"msw": "2.4.8",
185181
"postcss": "8.5.1",
186182
"protobufjs": "7.4.0",
187183
"rxjs": "7.8.1",
188184
"ssh2": "1.16.0",
189185
"storybook": "8.5.3",
190186
"storybook-addon-remix-react-router": "3.1.0",
191-
"storybook-react-context": "0.7.0",
192187
"tailwindcss": "3.4.17",
193-
"ts-node": "10.9.2",
194188
"ts-proto": "1.164.0",
195189
"ts-prune": "0.10.3",
196190
"typescript": "5.6.3",
197-
"vite": "5.4.18",
191+
"vite": "5.4.19",
198192
"vite-plugin-checker": "0.8.0",
199193
"vite-plugin-turbosnap": "1.0.3"
200194
},

0 commit comments

Comments
 (0)