mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 13:33:24 +00:00
lint: Add rule for spacing inside Handlebars translation tags.
This commit also includes the fixes to make all Handlebars templates compliant with the new rule.
This commit is contained in:
committed by
Tim Abbott
parent
3a4c6f83fc
commit
7d5d8ac61e
@@ -15,7 +15,7 @@
|
||||
<div class="progressive-table-wrapper">
|
||||
<table class="table table-condensed table-striped wrapped-table">
|
||||
<tbody id="admin_bots_table" class="admin_bot_table required-text thick"
|
||||
data-empty="{{ t 'No bots match your current filter.' }}"></tbody>
|
||||
data-empty="{{t 'No bots match your current filter.' }}"></tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div id="admin_page_bots_loading_indicator"></div>
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<span>{{ t 'Download config of all active outgoing webhook bots in Zulip Botserver format.' }}</span>
|
||||
<span>{{t 'Download config of all active outgoing webhook bots in Zulip Botserver format.' }}</span>
|
||||
<a type="submit" download="{{flaskbotrc}}" id= "download_flaskbotrc" class="btn" title="{{t 'Download flaskbotrc' }}">
|
||||
<i class="icon-vector-download-alt sea-green"></i>
|
||||
</a>
|
||||
|
||||
@@ -389,6 +389,8 @@ def build_custom_checkers(by_lang):
|
||||
handlebars_rules = html_rules + [
|
||||
{'pattern': "[<]script",
|
||||
'description': "Do not use inline <script> tags here; put JavaScript in static/js instead."},
|
||||
{'pattern': '{{ t ("|\')',
|
||||
'description': 'There should be no spaces before the "t" in a translation tag.'},
|
||||
{'pattern': "{{t '.*' }}[\.\?!]",
|
||||
'description': "Period should be part of the translatable string."},
|
||||
{'pattern': '{{t ".*" }}[\.\?!]',
|
||||
|
||||
Reference in New Issue
Block a user