Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove the trailing slash from void elements to comply with ... #1706

Merged
merged 1 commit into from
Jul 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/moin/apps/admin/templates/admin/userbrowser.html
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ <h1>{{ _("Users") }}</h1>
</td>
<td>
<form action="{{ url_for('admin.userprofile', user_name=u.name[0]) }}" method="POST">
<input type="hidden" name="key" value="disabled" />
<input type="hidden" name="val" value="{{ u.disabled and "0" or "1" }}" />
<input type="hidden" name="key" value="disabled">
<input type="hidden" name="val" value="{{ u.disabled and "0" or "1" }}">
{%- set cls = "fa-solid fa-user-plus fa-lg moin-button-less" if u.disabled else "fa fa-user-times fa-lg moin-button-less" %}
{%- set title = _("Enable user") if u.disabled else _("Disable user") %}
<button type="submit" class="{{ cls }}" title="{{ title }}">&nbsp;
Expand All @@ -39,7 +39,7 @@ <h1>{{ _("Users") }}</h1>
</td>
<td>
<form action="{{ url_for('admin.mail_recovery_token') }}" method="POST">
<input type="hidden" name="username" value="{{ u.name[0] }}" />
<input type="hidden" name="username" value="{{ u.name[0] }}">
<button type="submit" class="fa fa-envelope fa-lg moin-button-less" title="{{ _('Mail password reset') }}">&nbsp;
</button>
</form>
Expand Down
6 changes: 3 additions & 3 deletions src/moin/templates/atom.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@
{%- if get == 'xml' -%}
<?xml-stylesheet type="text/xsl" href="{{ theme_static('atom.xslt') }}"?>
{%- elif get == 'comment_cont_merge' -%}
<p style="font-size: 1.2em">…{{ comment }}</p> <br /> {{ content }}
<p style="font-size: 1.2em">…{{ comment }}</p> <br> {{ content }}
{%- elif get == 'first_revision' -%}
{{ content }}
<br />
<br>
<table class="moin-diff">
<tr>
<td class="moin-diff-header" style="width: 100%;">
Expand All @@ -32,7 +32,7 @@
{{ atom_style() }}
{%- elif get == 'binary' -%}
{{ content }}
<br />
<br>
<table class="moin-diff">
<tr>
<td class="moin-diff-header" style="width: 50%;">
Expand Down
24 changes: 12 additions & 12 deletions src/moin/templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@
<head>
{%- block head %}
{%- block head_meta %}
<meta charset="utf-8" />{# must be at the beginning #}
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta charset="utf-8">{# must be at the beginning #}
<meta name="viewport" content="width=device-width, initial-scale=1">
{%- if pi_refresh -%}
{{ '<meta http-equiv="refresh" content="%d;URL=%s" />' % pi_refresh }}
{{ '<meta http-equiv="refresh" content="%d;URL=%s">' % pi_refresh }}
{%- endif %}
{%- if html_head_meta %}
{%- for name, content in html_head_meta.items() %}
<meta name="{{ name }}" content="{{ content }}" />
<meta name="{{ name }}" content="{{ content }}">
{%- endfor %}
{%- endif %}
{%- endblock -%}
Expand Down Expand Up @@ -52,19 +52,19 @@
{{ favicon }}

{%- block theme_stylesheets %}
<link media="all" rel="stylesheet" href="{{ url_for('static', filename='css/normalize.css') }}" />
<link media="all" rel="stylesheet" href="{{ url_for('static', filename='css/variables.css') }}" />
<link media="all" rel="stylesheet" href="{{ url_for('static', filename='css/normalize.css') }}">
<link media="all" rel="stylesheet" href="{{ url_for('static', filename='css/variables.css') }}">
{%- if theme_supp.variables_css() %}
<link media="all" rel="stylesheet" href="{{ theme_static('css/variables.css') }}" />
<link media="all" rel="stylesheet" href="{{ theme_static('css/variables.css') }}">
{%- endif %}
<link media="all" rel="stylesheet" href="{{ url_for('serve.files', name='pygments', filename='css/colorful.css') }}" />
<link media="all" rel="stylesheet" href="{{ url_for('serve.files', name='font_awesome', filename='css/all.css') }}" />
<link media="all" rel="stylesheet" href="{{ url_for('static', filename='css/common.css') }}" />
<link media="all" rel="stylesheet" href="{{ theme_static('css/theme.css') }}" />
<link media="all" rel="stylesheet" href="{{ url_for('serve.files', name='pygments', filename='css/colorful.css') }}">
<link media="all" rel="stylesheet" href="{{ url_for('serve.files', name='font_awesome', filename='css/all.css') }}">
<link media="all" rel="stylesheet" href="{{ url_for('static', filename='css/common.css') }}">
<link media="all" rel="stylesheet" href="{{ theme_static('css/theme.css') }}">
{{ stylesheets }}
{%- endblock %}
{%- if user.valid and user.css_url -%}
<link media="all" rel="stylesheet" title="{{ user.name }}'s stylesheet" href="{{ user.css_url }}" />
<link media="all" rel="stylesheet" title="{{ user.name }}'s stylesheet" href="{{ user.css_url }}">
{%- endif -%}
{%- endblock -%}
{%- endblock %}
Expand Down
4 changes: 2 additions & 2 deletions src/moin/templates/blog/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

{% block theme_stylesheets %}
{{ super() }}
<link media="all" rel="stylesheet" href="{{ theme_static('css/blog.css') }}" />
<link media="all" rel="stylesheet" href="{{ theme_static('css/blog.css') }}">
{% endblock %}

{% block header_itemviews %}
Expand All @@ -39,7 +39,7 @@

<div id="moin-blog-body">
<div id="moin-blog-content">
{% block blog_content %}<br />{% endblock %}
{% block blog_content %}<br>{% endblock %}
</div>
{% if blog_name and supertags %}
<div id="moin-blog-sidebar">
Expand Down
4 changes: 2 additions & 2 deletions src/moin/templates/blog/utils.html
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,9 @@ <h1><a href="{{ url_for('frontend.show_item', item_name=entry_item.name) }}"
{{ forms.render(form['q']) }}
{{ forms.render_submit(form, id='moin-search-submit') }}
{{ forms.render_errors(form) }}
<br />
<br>
<input type="checkbox" id="moin-blog-search-this"
onclick="$('#moin-searchform').attr('action', this.checked ? '{{ url_for('frontend.search', item_name=blog_name) }}' : '{{ url_for('frontend.search') }}' );" />
onclick="$('#moin-searchform').attr('action', this.checked ? '{{ url_for('frontend.search', item_name=blog_name) }}' : '{{ url_for('frontend.search') }}' );">
{{ _("only this blog") }}
{{ gen.form.close() }}
{% endmacro %}
2 changes: 1 addition & 1 deletion src/moin/templates/forms.html
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
{% macro render_submit(form, name=None, value=None) %}
<div class="moin-float-fix"> {# needed to add vertical whitespace below floated element #}
{%- if name and value %}
<input type="hidden" name="{{ name }}" value="{{ value }}" />
<input type="hidden" name="{{ name }}" value="{{ value }}">
{% endif %}
{{ gen.input(type='submit', value=form.submit_label, class='moin-button', **kwargs) }}
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/moin/templates/global_history.html
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

{% block head %}
{{ super() }}
<link rel="alternate" title="Global History" href="{{ url_for('feed.atom') }}" type="application/atom+xml" />
<link rel="alternate" title="Global History" href="{{ url_for('feed.atom') }}" type="application/atom+xml">
{% endblock %}

{% block content %}
Expand Down
6 changes: 3 additions & 3 deletions src/moin/templates/history.html
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ <h1>{{ heading }}</h1>
{%- if history[0].trash %}
<th class="moin-button-diff"><span class="moin-button moin-button-disabled">Diff</span></th>
{%- else %}
<th class="moin-button-diff"><input class="moin-button" type="submit" value="Diff" /></th>
<th class="moin-button-diff"><input class="moin-button" type="submit" value="Diff"></th>
{%- endif %}
<th>{{ _("Editor") }}</th>
<th>{{ _("Content Type") }}</th>
Expand All @@ -74,8 +74,8 @@ <h1>{{ heading }}</h1>
{%- if doc.itemid == first_itemid %}
<div class="moin-hist-rev">
{%- if len(history) > 1 and not history[0].trash and not doc.trash %}
<input type="radio" name="rev1" value="{{ doc.revid }}" {{ checker['check1'] }} />
<input type="radio" name="rev2" value="{{ doc.revid }}" {{ checker['check2'] }} />
<input type="radio" name="rev1" value="{{ doc.revid }}" {{ checker['check1'] }}>
<input type="radio" name="rev2" value="{{ doc.revid }}" {{ checker['check2'] }}>
{%- if checker['check1'] %}
{%- if checker.update({'check1': ''}) %}{% endif %}
{%- elif checker['check2'] %}
Expand Down
2 changes: 1 addition & 1 deletion src/moin/templates/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
{% endfor %}
</ul>
{% endif %}
<hr class="moin-pageline" />
<hr class="moin-pageline">
{% block header_itemviews %}{% endblock %}
{% endblock %}
</header>
Expand Down
6 changes: 3 additions & 3 deletions src/moin/templates/modify.html
Original file line number Diff line number Diff line change
Expand Up @@ -100,13 +100,13 @@ <h1>{{ title }}</h1>

{% block options_for_javascript %}
{%- if user.scroll_page_after_edit -%}
<br id="moin-scroll-page-after-edit" />
<br id="moin-scroll-page-after-edit">
{%- endif %}
{%- if draft_data -%}
<textarea id="moin-draft-data">{{ draft_data }}</textarea>
{%- endif %}
{%- if lock_duration -%}
<input id="moin-lock_duration" value="{{ lock_duration }}" />
<input id="moin-lock_duration" value="{{ lock_duration }}">
{%- endif %}
<input id="moin-item-name" value="{{ fqname }}" />
<input id="moin-item-name" value="{{ fqname }}">
{% endblock %}
2 changes: 1 addition & 1 deletion src/moin/templates/modify_svg-edit.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@
<object data="{{ url_for('serve.files', name='svgedit_moin', filename='editor/svg-editor.html') }}?paramurl={{ url_for('frontend.get_item', item_name=item_name, member='drawing.svg') }}" width="100%" height="600">
</object>
</p>
<br />
<br>
{% endmacro %}
2 changes: 1 addition & 1 deletion src/moin/templates/modify_text.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,5 @@
<input type="button" onclick="moinFontChange()" value="{{ _('Toggle font width') }}" class="moin-button moin-textarea-font" >
{{ gen.textarea(form['data_text'], rows=textarea_rows|string, class=cls, **kwargs) }}
{{ base_editor(form) }}
<br />
<br>
{% endmacro %}
2 changes: 1 addition & 1 deletion src/moin/templates/modify_text_html.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

{% macro extra_head() %}
<script type="text/javascript" src="{{ url_for('serve.files', name='ckeditor', filename='ckeditor.js') }}"></script>
<link rel="stylesheet" href="{{ url_for('serve.files', name='ckeditor', filename='contents.css') }}" />
<link rel="stylesheet" href="{{ url_for('serve.files', name='ckeditor', filename='contents.css') }}">
{#- prevent ckeditor css from making body font-size 12px #}
<style>body {font-size: 1em;}</style>
{% endmacro %}
Expand Down
8 changes: 4 additions & 4 deletions src/moin/templates/show.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@

{% block head_links %}
{{ super() }}
<link rel="alternate" title="{{ item_name }} changes" href="{{ url_for('feed.atom', item_name=item_name) }}" type="application/atom+xml" />
<link rel="alternate" title="{{ item_name }} changes" href="{{ url_for('feed.atom', item_name=item_name) }}" type="application/atom+xml">
{# universal edit button support #}
{%- if user.may.write(item_name) and 'frontend.modify_item' not in cfg.endpoints_excluded -%}
<link rel="alternate" type="application/wiki" title="{{ _('Modify') }}" href="{{ url_for('frontend.modify_item', item_name=item_name) }}" />
<link rel="alternate" type="application/wiki" title="{{ _('Modify') }}" href="{{ url_for('frontend.modify_item', item_name=item_name) }}">
{%- endif %}
{% endblock %}

Expand Down Expand Up @@ -52,9 +52,9 @@

{% block options_for_javascript %}
{%- if item_name and user.edit_on_doubleclick and user.may.write(item_name) and data_rendered and not form -%}
<br id="moin-edit-on-doubleclick" />
<br id="moin-edit-on-doubleclick">
{%- endif %}
{%- if user.show_comments -%}
<br id="moin-show-comments" />
<br id="moin-show-comments">
{%- endif %}
{% endblock %}
6 changes: 3 additions & 3 deletions src/moin/templates/snippets.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
{# link to favicon inside <head> #}
{% macro favicon() -%}
{# default moin favicon #}
<link rel="icon" href="{{ url_for('static', filename='logos/favicon.ico') }}" />
<link rel="icon" href="{{ url_for('static', filename='logos/favicon.ico') }}">
{# for custom favicon, uncomment line below and place favicon file in wiki_local #}
{# <link rel="icon" href="{{ url_for('serve.files', name='wiki_local', filename='favicon.ico') }}" /> #}
{# <link rel="icon" href="{{ url_for('serve.files', name='wiki_local', filename='favicon.ico') }}"> #}
{%- endmacro %}

{# Additional HTML tags inside <head> #}
Expand Down Expand Up @@ -47,7 +47,7 @@

{# Helper macro to create image links #}
{% macro creditlogo(link, logo, alt, title) %}
<a href="{{ link }}" title="{{ title }}"><img src="{{ logo }}" alt="{{ alt }}" /></a>
<a href="{{ link }}" title="{{ title }}"><img src="{{ logo }}" alt="{{ alt }}"></a>
{% endmacro %}

{# Image links in the footer #}
Expand Down
4 changes: 2 additions & 2 deletions src/moin/templates/ticket/advanced.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
{% block content %}
<h1>{{ _("Advanced Search") }}</h1>
<p>
<input type="search" name="meta_summary" value="" class="moin-search-query" placeholder="Search Tickets" required="required" />
<input type="search" name="meta_summary" value="" class="moin-search-query" placeholder="Search Tickets" required="required">
</p>
<div id="finalresults">
{% include "ajaxsearch.html" %}
Expand Down Expand Up @@ -103,7 +103,7 @@ <h1>{{ _("Advanced Search") }}</h1>

{% block head %}
{{ super() }}
<link media="all" rel="stylesheet" href="{{ url_for('static', filename='css/ticket.css') }}" />
<link media="all" rel="stylesheet" href="{{ url_for('static', filename='css/ticket.css') }}">
{% endblock %}

{% block body_scripts %}
Expand Down
2 changes: 1 addition & 1 deletion src/moin/templates/ticket/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

{% block head %}
{{ super() }}
<link media="all" rel="stylesheet" href="{{ url_for('static', filename='css/ticket.css') }}" />
<link media="all" rel="stylesheet" href="{{ url_for('static', filename='css/ticket.css') }}">
{% endblock %}

{% set exists = item.fqname and storage.get_item(**item.fqname.query) %}
Expand Down
2 changes: 1 addition & 1 deletion src/moin/templates/utils.html
Original file line number Diff line number Diff line change
Expand Up @@ -447,7 +447,7 @@
{%- set avatar = user.avatar(20) %}
{%- if avatar %}
<li>
<img id="moin-avatar" src="{{ avatar }}" />
<img id="moin-avatar" src="{{ avatar }}">
</li>
{%- endif %}
{% if user.name -%}
Expand Down
2 changes: 1 addition & 1 deletion src/moin/themes/basic/templates/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@
{% if user.valid -%}
{% set avatar = user.avatar(20) %}
{% if avatar %}
<li><img id="moin-avatar" src="{{ avatar }}" /></li>
<li><img id="moin-avatar" src="{{ avatar }}"></li>
{%- endif %}
{% if user.name -%}
{% set wiki_href, aliasname, title, exists = theme_supp.userhome() %}
Expand Down
4 changes: 2 additions & 2 deletions src/moin/themes/basic/templates/modify.html
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ <h1>{{ title }}</h1>
</div>
{#
{{ gen.textarea(form['meta_text'], lang='en', dir='ltr', rows=rows_meta, cols=cols) }}
<br />
<br>
{{ forms.render_errors(form['meta_text']) }}
#}
{% if not form['content_form'].is_draw %}
Expand Down Expand Up @@ -122,7 +122,7 @@ <h1>{{ title }}</h1>

{% block options_for_javascript %}
{%- if user.scroll_page_after_edit -%}
<br id="moin-scroll-page-after-edit" />
<br id="moin-scroll-page-after-edit">
{%- endif %}
<input id="moin-item-name" value="{{ fqname }}" >
{% endblock %}
2 changes: 1 addition & 1 deletion src/moin/themes/basic/templates/modify_binary.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@

{% macro basic_data_editor(form, item_name, class) %}
{{ forms.render(form['data_file']) }}
<br />
<br>
{% endmacro %}
2 changes: 1 addition & 1 deletion src/moin/themes/basic/templates/modify_text.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
<input type="button" onclick="moinFontChange()" value="{{ _('Toggle font width') }}" class="moin-button moin-textarea-font" >
{{ gen.textarea(form['data_text'], rows=form.rows|string, cols=form.cols|string, class="moin-edit-content", **kwargs) }}
{{ base_editor(form) }}
<br />
<br>
{% endmacro %}
4 changes: 2 additions & 2 deletions src/moin/themes/basic/templates/show.html
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,9 @@

{% block options_for_javascript %}
{%- if item_name and user.edit_on_doubleclick and user.may.write(item_name) -%}
<br id="moin-edit-on-doubleclick" />
<br id="moin-edit-on-doubleclick">
{%- endif %}
{%- if user.show_comments -%}
<br id="moin-show-comments" />
<br id="moin-show-comments">
{%- endif %}
{% endblock %}