mirror of https://gitlab.com/tildes/tildes.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
764 B
25 lines
764 B
{# Copyright (c) 2018 Tildes contributors <code@tildes.net> #}
|
|
{# SPDX-License-Identifier: AGPL-3.0-or-later #}
|
|
|
|
{% for r, ratio in ratios.items() %}
|
|
{% if ratio.ratio == 1.0 %}
|
|
.topic-icon {
|
|
background-image: url('/images/{{ ratio.sprite_path }}?{{ hash }}');
|
|
background-size: 0 0;
|
|
}
|
|
{% else %}
|
|
@media screen and (min-device-pixel-ratio: {{ ratio.ratio }}), screen and (min-resolution: {{ ratio.ratio }}dppx) {
|
|
.topic-icon {
|
|
background-image: url('/images/{{ ratio.sprite_path }}?{{ hash }}');
|
|
}
|
|
}
|
|
{% endif %}
|
|
{% endfor %}
|
|
|
|
{% for image in images %}
|
|
.topic-icon-{{ image.label }} {
|
|
background-position: {{ image.x ~ ('px' if image.x) }} {{ image.y ~ ('px' if image.y) }};
|
|
background-size: {{ width }}px {{ height }}px;
|
|
border: 0;
|
|
}
|
|
{% endfor %}
|