From d4ae9aa501ece99ea6c5e6b8fb01c3005f5b7f03 Mon Sep 17 00:00:00 2001 From: toasted-nutbread Date: Sat, 2 May 2020 13:05:43 -0400 Subject: DOMTextScanner (#458) * Create new class for scanning text in a document * Update test styles * Add tests --- test/data/html/test-dom-text-scanner.html | 393 ++++++++++++++++++++++++++++++ 1 file changed, 393 insertions(+) create mode 100644 test/data/html/test-dom-text-scanner.html (limited to 'test/data/html/test-dom-text-scanner.html') diff --git a/test/data/html/test-dom-text-scanner.html b/test/data/html/test-dom-text-scanner.html new file mode 100644 index 00000000..6b78570a --- /dev/null +++ b/test/data/html/test-dom-text-scanner.html @@ -0,0 +1,393 @@ + + + + + + Yomichan DOMTextScanner Tests + + + + + +

Yomichan DOMTextScanner Tests

+ + + Layout newlines expected due to entering and exiting display:block nodes. +
小ぢん
まり1
+
小ぢん
まり2
+
+ + + Layout newline expected due to sequential display:block elements. +
小ぢんまり1
小ぢんまり2
+
+ + + Layout newline expected due to sequential display:block elements separated by a newline. +
小ぢんまり1
+
小ぢんまり2
+
+ + + No newlines expected due to display:inline. +小ぢんまり1小ぢんまり2 + + + + No newlines expected due to white-space:normal. +小ぢんまり1 +小ぢんまり2 + + + + Newline expected due to white-space:pre. +
+小ぢんまり1
+小ぢんまり2
+
+
+ + + No newlines expected due to display:inline-block. Actual layout flow cannot be determined by DOM/CSS alone. +小ぢんまり1小ぢんまり2 + + + + Single newline expected due to display:block layout. +
小ぢんまり1
小ぢんまり2
+
+ + + Two newlines expected due to position:absolute causing a significant layout change. +
小ぢんまり1
小ぢんまり2
+
+ + + Two newlines expected due to position:fixed causing a significant layout change. +
小ぢんまり1
小ぢんまり2
+
+ + + Two newlines expected due to position:sticky being able to cause a significant layout change. +
小ぢんまり1
小ぢんまり2
+
+ + + Scanning text starting in an <rt> element. Should start scanning at the start of the <ruby> tag instead. +
()ぢんまり1
+
+ + + Skip <script> content. +
小ぢんまり1
+
+ + + Skip <style> content. +
小ぢんまり1
+
+ + + Skip <textarea> content. +
小ぢんまり1
+
+ + + Skip <input> content. +
小ぢんまり1
+
+ + + Skip <button> content. +
小ぢんまり1
+
+ + + Skip content with font-size:0. +
小ぢんcontentまり1
+
+ + + Skip content with opacity:0. +
小ぢんcontentまり1
+
+ + + Skip content with visibility:hidden. +
小ぢんcontentまり1
+
+ + + Skip content with display:none. +
小ぢんcontentまり1
+
+ + + Don't skip content with user-select:none. +
小ぢまり1
+
+ + + Skip content with user-select:none and a transparent color. +
小ぢんcontentまり1
+
+ + + \ No newline at end of file -- cgit v1.2.3