Closed Bug 1732845 Opened 3 years ago Closed 3 years ago

Add `nsINode::IsInDesignMode()`

Categories

(Core :: DOM: Core & HTML, enhancement, P3)

enhancement

Tracking

()

RESOLVED FIXED
95 Branch
Tracking Status
firefox95 --- fixed

People

(Reporter: masayuki, Assigned: masayuki)

References

Details

Attachments

(1 file)

There are a lot of check of Document's editable state with comments. This means that it's unclear for developers that only Document node is editable in design mode.

Additionally, there are some points which use composed document rather than uncomposed document even though the raw level API uses uncomposed document. I'm not sure using uncomposed document is right or not, but we should do same check everywhere.

Therefore, nsINode should have a method to check whether it's in design mode or not.

There are a lot of check of Document's editable state with comments. This
means that it's unclear for developers that only Document node is editable in
design mode.

Additionally, there are some points which use composed document rather than
uncomposed document even though the raw level API uses uncomposed document. I'm
not sure using uncomposed document is right or not, but we should do same check
everywhere at least.

Therefore, nsINode should have a method to check whether it's in design mode
or not.

Attachment #9243186 - Attachment description: Bug 1732845 - Add `nsINode::IsInDesignMode()` r=smaug! → Bug 1732845 - Add `nsINode::IsInDesignMode()` to check whether the node is directly in design mode r=smaug!
Pushed by masayuki@d-toybox.com:
https://hg.mozilla.org/integration/autoland/rev/680ebfd6ee37
Add `nsINode::IsInDesignMode()` to check whether the node is directly in design mode r=smaug
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/31198 for changes under testing/web-platform/tests
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 95 Branch
Upstream PR merged by moz-wptsync-bot
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: