Open
Bug 1243012
Opened 8 years ago
Updated 2 years ago
Highlighter shows nothing/black boxes if a page uses document.write() while a node is highlighted
Categories
(DevTools :: Inspector, defect, P3)
Tracking
(firefox47 affected)
NEW
Tracking | Status | |
---|---|---|
firefox47 | --- | affected |
People
(Reporter: arni2033, Unassigned)
References
()
Details
(Keywords: testcase, Whiteboard: [btpp-backlog])
>>> My Info: Win7_64, Nightly 46, 32bit, ID 20160121030208 STR: 1. Open the following "data:" url or click URL in the form above > data:text/html,<body><script>document.write('<br>'); </script> 2. Open devtools -> Inspector 3. Click on the <script> element in markup-view, press Ctrl+C to copy its outerHTML 4. Right-click the <body> element, click "Paste...", click "As last child" Result: Page (apparently) started reloading but it never finishes. There's a black rectangle displayed at the top of web page (presumably it's <br> element) If I right-click Back button, then popup menu says that current url is > wyciwyg://0/data:text/html,<body><script>document.write('<br>'); </script> Expectations: This part isn't easy. I guess, either A or B: A) An exception in Console explaining why the page never finishes loading B) The node should be appended, as if I just edited HTML and pasted the string from Step 3
Oh, sorry. The "infinite reload" part was expected. I'll investigate the black rectangle later.
Status: NEW → UNCONFIRMED
Ever confirmed: false
This problem can be reproduced in Fx36.0.4 & Fx44. The paste commands implement in bug 1095521. The STR works fine with Firebug 2.0.13 in Fx44.
Keywords: testcase
Version: Trunk → 36 Branch
Comment 3•8 years ago
|
||
I'm not seeing the black rectangle with FF47, I'm seeing the infinite reloading though. What do you mean by it being expected in comment 1? I'd like to assign a priority to this bug, but I'm not sure what problem is being described here.
Flags: needinfo?(arni2033)
In comment 1 I realized that there was no "document.close()", so infinite reloading is expected. But now I understand that the black rectangle is a real bug. Please mark this as NEW if it's reproducible: 1. Open "data:" url below [1] 2. In less than 5 seconds open Inspector and hover mouse over <body> in markup to highlight <body> 3. Wait 5 seconds 4. Hover mouse over any node in markup AR: Whole highlighted area is now black. (If I skip Step 2 in STR, highlighter just doesn't work) ER: Highlighter should work in a normal way. > [1] data:text/html,<body><script>setTimeout(function(){document.write('<br>'); document.close();},5000);</script><script>document.write('<br>'); document.close();</script> > Screencast: https://dl.dropboxusercontent.com/s/anbfkzn84nkyjf2/bug%201243012%20comment%204.webm
Flags: needinfo?(arni2033)
Summary: Page reloads infinitely and display black rectangles if I paste a script with document.write() as last child → Highlighter shows nothing/black boxes if a page uses document.write() while a node is highlighted
So, the priority is low, because so far user can only encounter this bug if it navigates to a page that uses (or is created by) "document.write()" (navigates to that page while Inspector is open).
Comment 6•8 years ago
|
||
Thanks for this new test case and explanations. I was able to reproduce the bug. The black rectangle is most probably due to the highlighter. The DOM element of the highlighter probably stays in the DOM but its associated CSS is removed, hence it appears black.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Priority: -- → P3
Whiteboard: [btpp-backlog]
Updated•6 years ago
|
Product: Firefox → DevTools
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•