File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed
test/query-tests/DOM/TargetBlank Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -31,7 +31,9 @@ predicate hasDynamicHrefHostAttributeValue(DOM::ElementDefinition elem) {
3131 // fixed string with templating
3232 url .regexpMatch ( Templating:: getDelimiterMatchingRegexp ( ) ) and
3333 // ... that does not start with a fixed host or a relative path (common formats)
34- not url .regexpMatch ( "(?i)((https?:)?//)?[-a-z0-9.]*/.*" )
34+ not url .regexpMatch ( "(?i)((https?:)?//)?[-a-z0-9.]*/.*" ) and
35+ // ... that is not a mailto: link
36+ not url .regexpMatch ( "mailto:.*" )
3537 )
3638 )
3739}
Original file line number Diff line number Diff line change @@ -26,5 +26,8 @@ <h1>NOT OK, because of dynamic URL</h1>
2626 Example
2727</ a >
2828
29+ < h1 > OK: mailto is fine.</ h1 >
30+ < a target ="_blank " href ="mailto:{{var:mail}} "> mail somone</ a >
31+
2932</ body >
3033</ html >
You can’t perform that action at this time.
0 commit comments