feat: rebuild onboarding experience

This commit is contained in:
Thomas Camlong authored and ajnart committed 2026-08-14 11:32:11 +02:00
1 parent d091362db2
commit e41605640b
249 files changed
+8216 -14060

No files matched your search

+8 -10
View File
@@ -27,14 +27,14 @@ export class OnboardingActions {
}
}
public async startOnboardingAsync(type: "scratch" | "before 1.0") {
await this.page.locator("button", { hasText: type }).click();
public async startOnboardingAsync() {
await this.page.getByRole("button", { name: "Get started" }).click();
}
public async processUserStepAsync(input: { username: string; password: string; confirmPassword: string }) {
await this.page.waitForSelector("text=administrator user");
await this.page.getByRole("heading", { name: "Create your administrator" }).waitFor();
await this.page.getByLabel("Username").fill(input.username);
await this.page.getByLabel("Administrator username").fill(input.username);
await this.page.getByLabel("Password", { exact: true }).fill(input.password);
await this.page.getByLabel("Confirm password").fill(input.confirmPassword);
@@ -42,18 +42,16 @@ export class OnboardingActions {
}
public async processExternalGroupStepAsync(input: { name: string }) {
await this.page.waitForSelector("text=external provider");
await this.page.locator("input").fill(input.name);
await this.page.getByRole("heading", { name: "Connect your administrator group" }).waitFor();
await this.page.getByLabel("External administrator group").fill(input.name);
await this.page.locator("css=button[type='submit']").click();
}
public async processSettingsStepAsync() {
await this.page.waitForSelector("text=Analytics");
await this.page.locator("css=button[type='submit']").click();
await this.page.getByRole("heading", { name: "Start with familiar defaults" }).waitFor();
}
public async processIntegrationsStepAsync() {
await this.page.waitForSelector("text=integrations you'd like to connect");
await this.page.locator("button", { hasText: "Skip for now" }).click();
await this.page.getByRole("button", { name: "Build my board" }).click();
}
}
@@ -57,6 +57,6 @@ export class OnboardingAssertions {
}
public async assertFinishStepVisibleAsync() {
await this.page.waitForSelector("text=completed the setup", { timeout: 30_000 });
await this.page.getByRole("heading", { name: "Your first board is ready." }).waitFor({ timeout: 30_000 });
}
}
+2 -2
View File
@@ -17,13 +17,13 @@ export const seedAdminUserAsync = async (db: SqliteDatabase, input: SeedAdminUse
if (existingOnboarding) {
await db.update(sqliteSchema.onboarding).set({
step: "finish",
previousStep: "settings",
previousStep: "setup",
});
} else {
await db.insert(sqliteSchema.onboarding).values({
id: createId(),
step: "finish",
previousStep: "settings",
previousStep: "setup",
});
}