Page MenuHomePhabricator

querySelectorAll seems to be malfunctioning on "body > p:nth-child( 1 )" and ...( 2 )
Closed, InvalidPublic


html =
body class="mw-content-rtl sitedir-rtl rtl mw-body-content parsoid-body mediawiki mw-parser-output" dir="rtl" data-object-id="0"><p data-object-id="1">a\n\nb</p></body>
wt =
selector =
"body > p:nth-child(2)"
querySelectorAll() returns no node element
"body > p:nth-child(1)"
querySelectorAll() returns a node element but its dsr is 0-6 not 0-1

Event Timeline

Sbailey created this task.Jul 15 2019, 11:03 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptJul 15 2019, 11:03 PM

Change 523345 had a related patch set uploaded (by C. Scott Ananian; owner: C. Scott Ananian):
[mediawiki/libs/Zest@master] WIP: Attempt to reproduce nth-child bug

ssastry closed this task as Invalid.Jul 16 2019, 6:03 PM
ssastry added a subscriber: ssastry.

The problem is with the code that generates the DOM to which the selectors are applied, Zest output is correct for the provided dom.

Change 523345 abandoned by C. Scott Ananian:
WIP: Attempt to reproduce nth-child bug

I think this turned out to not actually be a zest bug.