mirror of
https://gitlab.com/SIGBUS/nyaa.git
synced 2024-10-31 23:25:58 +00:00
38f8880966
Infobubble text is now in a separate file, along with a timestamp in the main file, so that changes to it don't result in merge conflicts too often. We also add some JS to make the bubble dismissible, keeping track of the last timestamp that was dismissed in localstorage. A timestamp of 0 disables the infobubble altogether.
17 lines
586 B
HTML
17 lines
586 B
HTML
{# Update this to a larger timestamp if you change your announcement #}
|
|
{# A value of 0 disables the announcements altogether #}
|
|
{% set info_ts = 0 %}
|
|
{% if info_ts > 0 %}
|
|
<div class="alert alert-info alert-dismissible" id="infobubble" data-ts='{{ info_ts }}' hidden>
|
|
{% include 'infobubble_content.html' %}
|
|
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
|
|
<span aria-hidden="true">×</span>
|
|
</button>
|
|
</div>
|
|
<noscript>
|
|
<div class="alert alert-info" id="infobubble-noscript">
|
|
{% include 'infobubble_content.html' %}
|
|
</div>
|
|
</noscript>
|
|
{% endif %}
|