From 67606ee1d2c540c2fee087090e3f61dfaf294542 Mon Sep 17 00:00:00 2001 From: Simon Knott Date: Tue, 22 Oct 2024 11:24:19 +0200 Subject: [PATCH] address feedback --- .../src/utils/isomorphic/locatorGenerators.ts | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/packages/playwright-core/src/utils/isomorphic/locatorGenerators.ts b/packages/playwright-core/src/utils/isomorphic/locatorGenerators.ts index e46ebcc1f1..704bfba3e8 100644 --- a/packages/playwright-core/src/utils/isomorphic/locatorGenerators.ts +++ b/packages/playwright-core/src/utils/isomorphic/locatorGenerators.ts @@ -157,11 +157,6 @@ function innerAsLocators(factory: LocatorFactory, parsed: ParsedSelector, isFram continue; } } - if (part.name === 'internal:control' && (part.body as string) === 'enter-frame') { - tokens.push([factory.generateLocator(base, 'frame', '')]); - nextBase = 'frame-locator'; - continue; - } const nextPart = parts[index + 1]; @@ -208,11 +203,12 @@ function innerAsLocators(factory: LocatorFactory, parsed: ParsedSelector, isFram factory.generateLocator(base, 'frame-locator', selectorPart), ] - if (locatorPartWithEngine) + if (locatorPartWithEngine) { options.push( factory.chainLocators([locatorPartWithEngine, contentFrame]), factory.generateLocator(base, 'frame-locator', stringifySelector({ parts: [part] }, /* forceEngineName */ true)), ) + } tokens.push(options); nextBase = 'frame-locator';