(browser: Playwright)
| 1125 | } |
| 1126 | |
| 1127 | export function getRedboxHeader(browser: Playwright): Promise<string | null> { |
| 1128 | return browser.eval(() => { |
| 1129 | const portal = [].slice |
| 1130 | .call(document.querySelectorAll('nextjs-portal')) |
| 1131 | .find((p) => p.shadowRoot.querySelector('[data-nextjs-dialog-header]')) |
| 1132 | const root = portal?.shadowRoot |
| 1133 | return root?.querySelector('[data-nextjs-dialog-header]')?.innerText ?? null |
| 1134 | }) |
| 1135 | } |
| 1136 | |
| 1137 | export async function getRedboxTotalErrorCount( |
| 1138 | browser: Playwright |