Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(87)

Unified Diff: LayoutTests/editing/deleting/merge-div-from-span-with-style.html

Issue 22353004: background-color and text-decoration are not preserved when merging paragraphs (Closed) Base URL: https://chromium.googlesource.com/chromium/blink@master
Patch Set: Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | LayoutTests/editing/deleting/merge-div-from-span-with-style-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/editing/deleting/merge-div-from-span-with-style.html
diff --git a/LayoutTests/editing/deleting/merge-div-from-span-with-style.html b/LayoutTests/editing/deleting/merge-div-from-span-with-style.html
new file mode 100644
index 0000000000000000000000000000000000000000..4ba9566fbd400564af821c4f255c145b34e67c2a
--- /dev/null
+++ b/LayoutTests/editing/deleting/merge-div-from-span-with-style.html
@@ -0,0 +1,28 @@
+<!DOCTYPE html>
+<html>
+<head>
+<style type="text/css">
+.NonInheritableProperties {
+background-color: yellow;
+text-decoration: underline;
+}
+</style>
+</head>
+<body>
+<div id="test" contenteditable="true">
+<div>foo</div>
+<span id="spanToMerge" class="NonInheritableProperties">bar</span>
+</div>
+<script src="../../resources/dump-as-markup.js"></script>
+<script>
+Markup.description('The span style should be preserved when merging div element.\n'
++ 'The test passes if "bar" contatins the yellow background and it\'s underlined.');
+
+var spanToMerge = document.getElementById("spanToMerge");
+spanToMerge.focus();
+getSelection().collapse(spanToMerge, 0);
+document.execCommand("Delete");
+Markup.dump(document.getElementById("test"));
+</script>
+</body>
+</html>
« no previous file with comments | « no previous file | LayoutTests/editing/deleting/merge-div-from-span-with-style-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698