forked from mirrors/bookwyrm
Fix buttons styles
This commit is contained in:
parent
b1fea98458
commit
0b0a283e64
5 changed files with 41 additions and 17 deletions
|
@ -30,6 +30,30 @@ body {
|
||||||
min-width: 75% !important;
|
min-width: 75% !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Utils
|
||||||
|
******************************************************************************/
|
||||||
|
|
||||||
|
@media only screen and (max-width: 768px) {
|
||||||
|
.is-sr-only-mobile {
|
||||||
|
border: none !important;
|
||||||
|
clip: rect(0,0,0,0) !important;
|
||||||
|
height: .01em !important;
|
||||||
|
overflow: hidden !important;
|
||||||
|
padding: 0 !important;
|
||||||
|
position: absolute !important;
|
||||||
|
white-space: nowrap !important;
|
||||||
|
width: .01em !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.m-0-mobile {
|
||||||
|
margin: 0 !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.button.is-transparent {
|
||||||
|
background-color: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
/** Shelving
|
/** Shelving
|
||||||
******************************************************************************/
|
******************************************************************************/
|
||||||
|
|
||||||
|
|
|
@ -4,16 +4,16 @@
|
||||||
{% with status.id|uuid as uuid %}
|
{% with status.id|uuid as uuid %}
|
||||||
<form name="boost" action="/boost/{{ status.id }}" method="post" class="interaction boost-{{ status.id }}-{{ uuid }} {% if request.user|boosted:status %}is-hidden{% endif %}" data-id="boost-{{ status.id }}-{{ uuid }}">
|
<form name="boost" action="/boost/{{ status.id }}" method="post" class="interaction boost-{{ status.id }}-{{ uuid }} {% if request.user|boosted:status %}is-hidden{% endif %}" data-id="boost-{{ status.id }}-{{ uuid }}">
|
||||||
{% csrf_token %}
|
{% csrf_token %}
|
||||||
<button class="button is-small is-white" type="submit" {% if not status.boostable %}disabled{% endif %}>
|
<button class="button is-small is-light is-transparent" type="submit" {% if not status.boostable %}disabled{% endif %}>
|
||||||
<span class="icon icon-boost" title="{% trans 'Boost status' %}"></span>
|
<span class="icon icon-boost m-0-mobile" title="{% trans 'Boost' %}"></span>
|
||||||
<span>{% trans "Boost status" %}</span>
|
<span class="is-sr-only-mobile">{% trans "Boost" %}</span>
|
||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
<form name="unboost" action="/unboost/{{ status.id }}" method="post" class="interaction boost-{{ status.id }}-{{ uuid }} active {% if not request.user|boosted:status %}is-hidden{% endif %}" data-id="boost-{{ status.id }}-{{ uuid }}">
|
<form name="unboost" action="/unboost/{{ status.id }}" method="post" class="interaction boost-{{ status.id }}-{{ uuid }} active {% if not request.user|boosted:status %}is-hidden{% endif %}" data-id="boost-{{ status.id }}-{{ uuid }}">
|
||||||
{% csrf_token %}
|
{% csrf_token %}
|
||||||
<button class="button is-small is-white" type="submit">
|
<button class="button is-small is-light is-transparent" type="submit">
|
||||||
<span class="icon icon-boost has-text-primary" title="{% trans 'Un-boost status' %}"></span>
|
<span class="icon icon-boost has-text-primary m-0-mobile" title="{% trans 'Un-boost' %}"></span>
|
||||||
<span>{% trans "Un-boost status" %}</span>
|
<span class="is-sr-only-mobile">{% trans "Un-boost" %}</span>
|
||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
{% endwith %}
|
{% endwith %}
|
||||||
|
|
|
@ -3,17 +3,17 @@
|
||||||
{% with status.id|uuid as uuid %}
|
{% with status.id|uuid as uuid %}
|
||||||
<form name="favorite" action="/favorite/{{ status.id }}" method="POST" class="interaction fav-{{ status.id }}-{{ uuid }} {% if request.user|liked:status %}is-hidden{% endif %}" data-id="fav-{{ status.id }}-{{ uuid }}">
|
<form name="favorite" action="/favorite/{{ status.id }}" method="POST" class="interaction fav-{{ status.id }}-{{ uuid }} {% if request.user|liked:status %}is-hidden{% endif %}" data-id="fav-{{ status.id }}-{{ uuid }}">
|
||||||
{% csrf_token %}
|
{% csrf_token %}
|
||||||
<button class="button is-small is-white" type="submit">
|
<button class="button is-small is-light is-transparent" type="submit">
|
||||||
<span class="icon icon-heart" title="{% trans 'Like status' %}">
|
<span class="icon icon-heart m-0-mobile" title="{% trans 'Like' %}">
|
||||||
</span>
|
</span>
|
||||||
<span>{% trans "Like status" %}</span>
|
<span class="is-sr-only-mobile">{% trans "Like" %}</span>
|
||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
<form name="unfavorite" action="/unfavorite/{{ status.id }}" method="POST" class="interaction fav-{{ status.id }}-{{ uuid }} active {% if not request.user|liked:status %}is-hidden{% endif %}" data-id="fav-{{ status.id }}-{{ uuid }}">
|
<form name="unfavorite" action="/unfavorite/{{ status.id }}" method="POST" class="interaction fav-{{ status.id }}-{{ uuid }} active {% if not request.user|liked:status %}is-hidden{% endif %}" data-id="fav-{{ status.id }}-{{ uuid }}">
|
||||||
{% csrf_token %}
|
{% csrf_token %}
|
||||||
<button class="button is-white is-small" type="submit">
|
<button class="button is-light is-transparent is-small" type="submit">
|
||||||
<span class="icon icon-heart has-text-primary" title="{% trans 'Un-like status' %}"></span>
|
<span class="icon icon-heart has-text-primary m-0-mobile" title="{% trans 'Un-like' %}"></span>
|
||||||
<span>{% trans "Un-like status" %}</span>
|
<span class="is-sr-only-mobile">{% trans "Un-like" %}</span>
|
||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
{% endwith %}
|
{% endwith %}
|
||||||
|
|
|
@ -3,8 +3,8 @@
|
||||||
{% load bookwyrm_tags %}
|
{% load bookwyrm_tags %}
|
||||||
|
|
||||||
{% block dropdown-trigger %}
|
{% block dropdown-trigger %}
|
||||||
<span class="icon icon-dots-three"></span>
|
<span class="icon icon-dots-three m-0-mobile"></span>
|
||||||
<span>{% trans "More options" %}</span>
|
<span class="is-sr-only-mobile">{% trans "More options" %}</span>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% block dropdown-list %}
|
{% block dropdown-list %}
|
||||||
|
|
|
@ -10,12 +10,12 @@
|
||||||
>
|
>
|
||||||
|
|
||||||
{% if icon %}
|
{% if icon %}
|
||||||
<span class="icon icon-{{ icon }}" title="{{ text }}">
|
<span class="icon icon-{{ icon }} m-0-mobile" title="{{ text }}">
|
||||||
<span class="is-sr-only">{{ text }}</span>
|
<span class="is-sr-only">{{ text }}</span>
|
||||||
</span>
|
</span>
|
||||||
{% elif icon_with_text %}
|
{% elif icon_with_text %}
|
||||||
<span class="icon icon-{{ icon_with_text }}" aria-hidden></span>
|
<span class="icon icon-{{ icon_with_text }} m-0-mobile" title="{{ text }}"></span>
|
||||||
<span>{{ text }}</span>
|
<span class="is-sr-only-mobile">{{ text }}</span>
|
||||||
{% else %}
|
{% else %}
|
||||||
<span>{{ text }}</span>
|
<span>{{ text }}</span>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
Loading…
Reference in a new issue