mirror of https://github.com/zulip/zulip.git
lint: Ban Help Center relative links without leading /.
Such links would likely end up broken if we change our URL scheme to no longer be based around URL fragments.
This commit is contained in:
parent
44c9b788f9
commit
25999b7056
|
@ -109,7 +109,7 @@
|
|||
is_checked=realm_enable_spectator_access
|
||||
label=admin_settings_label.realm_enable_spectator_access
|
||||
is_disabled=disable_enable_spectator_access_setting
|
||||
help_link="help/public-access-option"}}
|
||||
help_link="/help/public-access-option"}}
|
||||
<div class="input-group realm_create_web_public_stream_policy">
|
||||
<label for="realm_create_web_public_stream_policy" class="dropdown-title">{{t "Who can create web-public streams" }}</label>
|
||||
<select name="realm_create_web_public_stream_policy" id="id_realm_create_web_public_stream_policy" class="prop-element" data-setting-widget-type="number">
|
||||
|
|
|
@ -662,6 +662,12 @@ html_rules: List["Rule"] = [
|
|||
"good_lines": ['<img src="{{source_url}}" alt="{{ _(name) }}" />'],
|
||||
"bad_lines": ['<img alt="{{ " />'],
|
||||
},
|
||||
{
|
||||
"pattern": r"link=\"help/",
|
||||
"description": "Relative links to Help Center should start with /help/",
|
||||
"good_lines": ['link="/help/foo"'],
|
||||
"bad_lines": ['link="help/foo"'],
|
||||
},
|
||||
{
|
||||
"pattern": r"\bon\w+ ?=",
|
||||
"description": "Don't use inline event handlers (onclick=, etc. attributes) in HTML. Instead,"
|
||||
|
|
Loading…
Reference in New Issue