fix(trace-viewer): use sdkLanguage for Pick Locator (#26737)

Fixes https://github.com/microsoft/playwright/issues/26736
This commit is contained in:
Max Schmitt 2023-08-28 17:39:02 +02:00 committed by GitHub
parent 36347e7fea
commit 39f8f2ed8d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -241,7 +241,7 @@ export const InspectModeController: React.FunctionComponent<{
const injectedScript = new InjectedScript(win, false, sdkLanguage, testIdAttributeName, 1, 'chromium', []);
recorder = new Recorder(injectedScript, {
async setSelector(selector: string) {
setHighlightedLocator(asLocator('javascript', selector, false /* isFrameLocator */, true /* playSafe */));
setHighlightedLocator(asLocator(sdkLanguage, selector, false /* isFrameLocator */, true /* playSafe */));
}
});
win._recorder = recorder;