Kunpei Sakai
28c70e62bb
html: port html5lib tests from html5lib/html5lib-tests
...
To reproduce this, execute following steps in order:
1. git clone git@github.com:html5lib/html5lib-tests.git && git checkout 6ddcf58bea5a01e616911050c173622f84297211
2. cp -Rv html5lib-tests/tree-construction/ testdata/webkit
Change-Id: Id32798b1ff881afad82d87c2fef0841e5223c7e6
Reviewed-on: https://go-review.googlesource.com/c/net/+/263397
Trust: Kunpei Sakai <namusyaka@gmail.com >
Trust: Nigel Tao <nigeltao@golang.org >
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Go Bot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2020-10-29 22:17:08 +00:00
Kunpei Sakai
942e2f445f
html: avoid using raw text mode even when nested noscript tags
...
Assuming "in head noscript" insertion mode, the scripting flag will be disabled.
Thus, even if nested noscript tags exist,
the tokenizer should not go into the raw text mode.
This change makes the following test happy:
<head><noscript><noscript class="foo"><!--foo--></noscript>
Change-Id: I2620e751d8be3d313c3a2e2f992b1e21ce2dc2ee
Reviewed-on: https://go-review.googlesource.com/c/net/+/263878
Trust: Kunpei Sakai <namusyaka@gmail.com >
Trust: Nigel Tao <nigeltao@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2020-10-29 05:50:24 +00:00
Kunpei Sakai
e0495509cf
html: skip tests for behavior outside the parsing algorithm
...
This also updates webkit/tests18.dat to latest.
Change-Id: I4ed37e918a7db63afd8d515dd3a2494699cc5b74
Reviewed-on: https://go-review.googlesource.com/c/net/+/264977
Trust: Kunpei Sakai <namusyaka@gmail.com >
Trust: Nigel Tao <nigeltao@golang.org >
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Go Bot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2020-10-29 03:25:33 +00:00
Kunpei Sakai
d65d470038
html: remove a few attributes from svg attribute adjustments
...
As per the current spec, "contentScriptType", "contentStyleType" and
"externalResourcesRequired" have been removed from the svg attribute adjustments.
See: https://html.spec.whatwg.org/multipage/parsing.html#adjust-svg-attributes
Change-Id: I904914691c3a3c3958868f7e49ba10f7d6f9ec09
Reviewed-on: https://go-review.googlesource.com/c/net/+/263398
Trust: Kunpei Sakai <namusyaka@gmail.com >
Trust: Nigel Tao <nigeltao@golang.org >
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Go Bot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2020-10-20 06:53:57 +00:00
Kunpei Sakai
51f093181b
html: update adoption agency algorithm
...
See: https://html.spec.whatwg.org/multipage/parsing.html#adoption-agency-algorithm
This follows up on golang.org/cl/205617
Change-Id: I45862eb81ed421b327e216254169355e63698716
Reviewed-on: https://go-review.googlesource.com/c/net/+/210317
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2019-12-07 00:05:07 +00:00
Kunpei Sakai
1ddd1de85c
html: implement generic raw text element parsing algorithm
...
See: https://html.spec.whatwg.org/multipage/parsing.html#parsing-elements-that-contain-only-text
This follows up on golang.org/cl/205617
Change-Id: Id99054bc25e9ea90bb3f03b15c14c13573520997
Reviewed-on: https://go-review.googlesource.com/c/net/+/210318
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2019-12-06 10:30:17 +00:00
Kunpei Sakai
afd1edf42a
html: drop <isindex> and <command> specific handlings
...
This commit also adds remaining tests to follow up on golang.org/cl/205617
Change-Id: I8b155f9f605c6a0eb8745c32f5e785f5b4bc1c7e
Reviewed-on: https://go-review.googlesource.com/c/net/+/208937
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2019-12-06 10:28:45 +00:00
Kunpei Sakai
ffdde10578
html: implement adjusted current node and make parser support foreign fragment
...
This follows up on golang.org/cl/205617
Change-Id: Id94a4fcef6a604936c404f75999ba37321b6c2c0
Reviewed-on: https://go-review.googlesource.com/c/net/+/206121
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2019-11-25 08:49:36 +00:00
Kunpei Sakai
72fef5d5e2
html: remove "filterres" from svg attribute adjustments
...
This follows up on golang.org/cl/205617
Ref: c0ffd43f89
Change-Id: I0a7399368bb8c28c5bf65adf3614a84ffeb82b8c
Reviewed-on: https://go-review.googlesource.com/c/net/+/206120
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2019-11-24 23:54:46 +00:00
Kunpei Sakai
b954d4e333
html: add Main support
...
This follows up on golang.org/cl/205617
Change-Id: Ic4a232c40a69bcd3ba35abdd36bce933f35248ea
Reviewed-on: https://go-review.googlesource.com/c/net/+/206117
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2019-11-24 23:23:54 +00:00
Kunpei Sakai
7e6e90b9ea
html: port html5lib test data from html5lib/html5lib-tests
...
1. git clone git@github.com:html5lib/html5lib-tests.git && git checkout 88b8ee967f9f6f42fcd84c65af774860a70ecf3c
2. cp -Rv html5lib-tests/tree-construction/ into testdata/webkit
3. Drop unpassed following changes:
testdata/webkit/foreign-fragment.dat
testdata/webkit/isindex.dat
testdata/webkit/main-element.dat
testdata/webkit/menuitem-element.dat
testdata/webkit/tests11.dat
testdata/webkit/tests16.dat
testdata/webkit/tests19.dat
testdata/webkit/tests25.dat
testdata/webkit/tests5.dat
testdata/webkit/webkit02.dat
Change-Id: Ie60b6e24751a1efb83caf326b7e42f0517ec6b96
Reviewed-on: https://go-review.googlesource.com/c/net/+/205617
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2019-11-08 06:38:44 +00:00
Kunpei Sakai
6f6bbb1828
html: add Dialog support
...
Change-Id: I16afe71ca444afb03526f94e6743a587cd82a8d4
Reviewed-on: https://go-review.googlesource.com/c/net/+/205618
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2019-11-08 04:52:52 +00:00
Kunpei Sakai
8a410e7b63
html: fix wrong comparison in foster parenting algorithm
...
Fixes golang/go#23071
Change-Id: I383e13bfd87e32ffb775dff54c46b66b090e5017
Reviewed-on: https://go-review.googlesource.com/131475
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2018-08-26 01:23:51 +00:00
Kunpei Sakai
4bcd98cce5
html: copy passed tests from chromium
...
Updates golang/go#23071
Change-Id: I1fdf3fe8c94efdf3c4bf9c39900468381159a032
Reviewed-on: https://go-review.googlesource.com/131178
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org >
2018-08-24 15:20:47 +00:00
Kunpei Sakai
faa378e6db
html: handle end-of-file cases correctly
...
Updates golang/go#23071
Change-Id: I02a61109b5738759a9ee3e448981778de7d0ff62
Reviewed-on: https://go-review.googlesource.com/130795
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2018-08-24 04:51:31 +00:00
Kunpei Sakai
aaf6012214
html: remove special procedure for <template> in frameset im
...
See more details: https://bugs.chromium.org/p/chromium/issues/detail?id=829668
Updates golang/go#23071
Change-Id: Ib9c963269f814c3f21d3784754729df57dcc8f90
Reviewed-on: https://go-review.googlesource.com/123776
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2018-08-16 10:28:01 +00:00
Kunpei Sakai
c394268923
html: don't ignore token when current token is not <template>
...
Updates golang/go#23071
Change-Id: I36b0ee58f61b7de25730e0fb082eeb7ef2787594
Reviewed-on: https://go-review.googlesource.com/123920
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2018-08-11 02:16:10 +00:00
Kunpei Sakai
d41e817464
html: handle rb and rtc elements
...
Updates golang/go#23071
Change-Id: Ifef79e077801422eb273af3e5a541c85c63bfce4
Reviewed-on: https://go-review.googlesource.com/107575
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2018-04-18 06:21:11 +00:00
namusyaka
500e7a4f95
html: add "in template" insertion mode support
...
See:
https://html.spec.whatwg.org/multipage/parsing.html#parsing-main-intemplate
Updates golang/go#23071
Change-Id: I36529b7cf5d2adf159ed5c471fba9f67890b7eb9
Reviewed-on: https://go-review.googlesource.com/94838
Run-TryBot: Kunpei Sakai <namusyaka@gmail.com >
TryBot-Result: Gobot Gobot <gobot@golang.org >
Reviewed-by: Nigel Tao <nigeltao@golang.org >
2018-04-15 21:43:07 +00:00
Nigel Tao
ea127e889c
go.net/html: move exp/html and exp/html/atom here to the go.net
...
sub-repo.
It's a straight copy, except for these modifications:
* "exp/html" and "exp/html/atom" imports were renamed, and
* the "TODO... When this package moves out of exp" comment was
deleted from atom/atom.go.
The matching change is at https://golang.org/cl/7317043
The rationale was discussed at
https://groups.google.com/d/topic/golang-nuts/Qq5hTQyPuLg/discussion
R=adg, remyoudompheng, dave
CC=golang-dev
https://golang.org/cl/7310063
2013-02-11 11:55:20 +11:00