contenteditable not editable when loaded from file on disc

RESOLVED WORKSFORME

Status

()

RESOLVED WORKSFORME
6 years ago
2 years ago

People

(Reporter: erik2, Unassigned)

Tracking

13 Branch
x86_64
Windows 7
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

6 years ago
Created attachment 637931 [details]
FFIssue2.html

User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:13.0) Gecko/20100101 Firefox/13.0.1
Build ID: 20120614114901

Steps to reproduce:

Created a simple test case with two contenteditable div's, one div is directly in the body, and the other div is inside a foreignobject inside an svg inside the body.

Load the file two different ways: one as a file from the file system (windows) and the other from a http server.  The method of loading alters the behavior.


Actual results:

load the following html source from the windows file system, and the contenteditable div's are not editable.  However, when this html source is returned by a server then the contenteditable div's are editable.


Expected results:

contenteditable div's should be editable regardless of source load location, no?

Note: there are ways to get the first div (the one not inside svg) to be editable.
1. load the file from an http server instead of from the disc, and both div's are now editable.
2. comment out the svg element, and the first/remaining one is editable regardless of how the file is loaded.
(Reporter)

Comment 1

6 years ago
<!DOCTYPE html>

<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
<head>
	<meta charset="utf-8" />
	<title></title>
</head>
<body>

	<!-- neither of the following divs are editible when this html is loaded as a file from the disc -->
	<!-- if you comment out the svg element, then the first (the remaining) div is editable when loaded as a file from the disc -->
	<!-- however, if you load this html from a server, then it is editable -->

	<div contenteditable="true">div #1, with contenteditable=true</div>

	<svg id="svg" xmlns="http://www.w3.org/2000/svg" style="border: 1px yellow solid" height="200px" width="100%">
		<foreignobject id="fo" class="node" x="46" y="22" width="100%" height="100%">                
			<div contenteditable="true">div #2, with contenteditable=true</div>
        </foreignobject>
	</svg>

</body>
</html>
(Reporter)

Updated

6 years ago
Attachment #637931 - Attachment mime type: text/plain → text/html
This is WFM testing a local Version of you Testcase against Mozilla/5.0 (Windows NT 6.1; WOW64; rv:13.0) Gecko/20100101 Firefox/13.0.1 ID:20120614114901 and Mozilla/5.0 (Windows NT 6.1; WOW64; rv:16.0) Gecko/16.0 Firefox/16.0 ID:20120630030532

Comment 3

6 years ago
The first div is editable in Nightly 20120703 Mac 10.7 and I get the same behavior in Opera 12.

Comment 4

3 years ago
User Agent 	Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:46.0) Gecko/20100101 Firefox/46.0
Version 	46.0a1
Build ID 	20160112030207
Channel 	nightly

Thank you for taking time to report this.
Are you still able to reproduce this in the latest version ? I can edit the content.
Component: Untriaged → Editor
Flags: needinfo?(erik2)
Product: Firefox → Core

Comment 5

3 years ago
It is not reproducible. Closing this as works for me.
Please feel free to reopen this bug if it still reproduces in the latest versions. Thanks
Status: UNCONFIRMED → RESOLVED
Last Resolved: 3 years ago
Resolution: --- → WORKSFORME

Updated

2 years ago
Flags: needinfo?(erik2)
You need to log in before you can comment on or make changes to this bug.