diff --git a/docs/static/img/screenshots/dashboard.jpg b/docs/static/img/screenshots/dashboard.jpg index 9062d7a479d..da11fff6a52 100644 Binary files a/docs/static/img/screenshots/dashboard.jpg and b/docs/static/img/screenshots/dashboard.jpg differ diff --git a/docs/static/img/screenshots/explore.jpg b/docs/static/img/screenshots/explore.jpg index 8ac41b65796..0785b41bcb5 100644 Binary files a/docs/static/img/screenshots/explore.jpg and b/docs/static/img/screenshots/explore.jpg differ diff --git a/docs/static/img/screenshots/gallery.jpg b/docs/static/img/screenshots/gallery.jpg index 2312bd37982..50087c44a68 100644 Binary files a/docs/static/img/screenshots/gallery.jpg and b/docs/static/img/screenshots/gallery.jpg differ diff --git a/docs/static/img/screenshots/sql_lab.jpg b/docs/static/img/screenshots/sql_lab.jpg index d8f5a964adb..c47738c28db 100644 Binary files a/docs/static/img/screenshots/sql_lab.jpg and b/docs/static/img/screenshots/sql_lab.jpg differ diff --git a/docs/static/img/tutorial/create_pivot.png b/docs/static/img/tutorial/create_pivot.png index 2a24ee25153..5d619b7724b 100644 Binary files a/docs/static/img/tutorial/create_pivot.png and b/docs/static/img/tutorial/create_pivot.png differ diff --git a/docs/static/img/tutorial/tutorial_08_sources_tables.png b/docs/static/img/tutorial/tutorial_08_sources_tables.png index 67252a706e9..064a85b0f34 100644 Binary files a/docs/static/img/tutorial/tutorial_08_sources_tables.png and b/docs/static/img/tutorial/tutorial_08_sources_tables.png differ diff --git a/superset-frontend/playwright/generators/docs/docs-screenshots.spec.ts b/superset-frontend/playwright/generators/docs/docs-screenshots.spec.ts index c2692d8bcd3..f3d7fa0b79c 100644 --- a/superset-frontend/playwright/generators/docs/docs-screenshots.spec.ts +++ b/superset-frontend/playwright/generators/docs/docs-screenshots.spec.ts @@ -152,7 +152,7 @@ test('chart editor screenshot', async ({ page }) => { }); test('SQL Lab screenshot', async ({ page }) => { - // SQL Lab has many interactive steps (schema, table, query, results) — allow extra time + // SQL Lab has many interactive steps — allow extra time test.setTimeout(90000); await page.goto(URL.SQLLAB); @@ -169,34 +169,7 @@ test('SQL Lab screenshot', async ({ page }) => { } await expect(aceEditor).toBeVisible({ timeout: 15000 }); - // Select the "public" schema so we can pick a table from the left panel - const schemaSelect = page.locator('#select-schema'); - await expect(schemaSelect).toBeEnabled({ timeout: 10000 }); - await schemaSelect.click({ force: true }); - await schemaSelect.fill('public'); - await page.getByRole('option', { name: 'public' }).click(); - - // Wait for table list to load after schema change, then select birth_names - const tableSelectWrapper = page - .locator('.ant-select') - .filter({ has: page.locator('#select-table') }); - await expect(tableSelectWrapper).toBeVisible({ timeout: 10000 }); - await tableSelectWrapper.click(); - await page.keyboard.type('birth_names'); - // Wait for the filtered option to appear in the DOM, then select it - const tableOption = page - .locator('.ant-select-dropdown [role="option"]') - .filter({ hasText: 'birth_names' }); - await expect(tableOption).toBeAttached({ timeout: 10000 }); - await page.keyboard.press('Enter'); - - // Wait for table schema to load and show columns in the left panel - await expect(page.locator('[data-test="col-name"]').first()).toBeVisible({ - timeout: 15000, - }); - - // Close the table dropdown by clicking elsewhere, then switch to the query tab - await page.locator('[data-test="sql-editor-tabs"]').first().click(); + // Click the active query tab to ensure focus is on the editor pane await page.getByText('Untitled Query').first().click(); // Write a multi-line SELECT with explicit columns to fill the editor @@ -206,8 +179,8 @@ test('SQL Lab screenshot', async ({ page }) => { 'SELECT\n ds,\n name,\n gender,\n state,\n num\nFROM birth_names\nLIMIT 100', ); - // Run the query - const runButton = page.getByText('Run', { exact: true }); + // Run the query — use role to avoid matching "Run" text in other tab panels + const runButton = page.getByRole('button', { name: /caret-right Run/i }); await expect(runButton).toBeVisible(); await runButton.click(); @@ -239,8 +212,10 @@ test('datasets list screenshot', async ({ page }) => { const table = page.locator('[data-test="listview-table"]'); await expect(table).toBeVisible({ timeout: 15000 }); - // Wait for at least one data row (not just the header row) - await expect(table.locator('tbody tr').first()).toBeVisible({ + // Wait for at least one visible data row (skip ant-table-measure-row which is always hidden) + await expect( + table.locator('tbody tr:not(.ant-table-measure-row)').first(), + ).toBeVisible({ timeout: 10000, }); diff --git a/superset-frontend/playwright/generators/playwright.config.ts b/superset-frontend/playwright/generators/playwright.config.ts index 54b8b4be702..0ebc082a860 100644 --- a/superset-frontend/playwright/generators/playwright.config.ts +++ b/superset-frontend/playwright/generators/playwright.config.ts @@ -64,6 +64,7 @@ export default defineConfig({ name: 'docs-generators', use: { browserName: 'chromium', + baseURL, // explicit here so globalSetup can read it from config.projects[0].use.baseURL testIdAttribute: 'data-test', storageState: path.resolve(__dirname, '../.auth/user.json'), },