feat: add tooltip to subscribe bell
This commit is contained in:
parent
299653b53b
commit
ab1e6a94d1
@ -288,42 +288,43 @@ a.btn, a.btn2, a.nav-link {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.tooltip {
|
.tooltip {
|
||||||
position: relative;
|
position: relative;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
border-bottom: 1px dotted black;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.tooltip .tooltiptext {
|
.tooltip .tooltiptext {
|
||||||
visibility: hidden;
|
font-size: 1rem;
|
||||||
width: 200px;
|
font-weight: normal;
|
||||||
background-color: var(--primary-dark-one);
|
visibility: hidden;
|
||||||
color: var(--secondary-light-one);
|
width: 200px;
|
||||||
text-align: center;
|
background-color: var(--primary-dark-one);
|
||||||
border-radius: 6px;
|
color: var(--secondary-light-one);
|
||||||
padding: 5px 0;
|
text-align: center;
|
||||||
position: absolute;
|
border-radius: 6px;
|
||||||
z-index: 1;
|
padding: 5px 0;
|
||||||
bottom: 125%;
|
position: absolute;
|
||||||
left: 50%;
|
z-index: 1;
|
||||||
margin-left: -100px;
|
bottom: 125%;
|
||||||
opacity: 0;
|
left: 50%;
|
||||||
transition: opacity 0.3s;
|
margin-left: -100px;
|
||||||
|
opacity: 0;
|
||||||
|
transition: opacity 0.3s;
|
||||||
}
|
}
|
||||||
|
|
||||||
.tooltip .tooltiptext::after {
|
.tooltip .tooltiptext::after {
|
||||||
content: "";
|
content: "";
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 100%;
|
top: 100%;
|
||||||
left: 50%;
|
left: 50%;
|
||||||
margin-left: -5px;
|
margin-left: -5px;
|
||||||
border-width: 5px;
|
border-width: 5px;
|
||||||
border-style: solid;
|
border-style: solid;
|
||||||
border-color: var(--primary-dark-one) transparent transparent transparent;
|
border-color: var(--primary-dark-one) transparent transparent transparent;
|
||||||
}
|
}
|
||||||
|
|
||||||
.tooltip:hover .tooltiptext {
|
.tooltip:hover .tooltiptext {
|
||||||
visibility: visible;
|
visibility: visible;
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*********************/
|
/*********************/
|
||||||
|
@ -8,12 +8,17 @@
|
|||||||
<div class="detail-adoption-notice-header">
|
<div class="detail-adoption-notice-header">
|
||||||
<h1 class="detail-adoption-notice-header">{{ adoption_notice.name }}
|
<h1 class="detail-adoption-notice-header">{{ adoption_notice.name }}
|
||||||
{% if not is_subscribed %}
|
{% if not is_subscribed %}
|
||||||
<form class="notification-card-mark-read" method="post">
|
<div class="tooltip">
|
||||||
{% csrf_token %}
|
<form class="notification-card-mark-read" method="post">
|
||||||
<input type="hidden" name="action" value="subscribe">
|
{% csrf_token %}
|
||||||
<input type="hidden" name="adoption_notice_id" value="{{ adoption_notice.pk }}">
|
<input type="hidden" name="action" value="subscribe">
|
||||||
<button class="btn2" type="submit" id="submit"><i class="fa-solid fa-bell"></i></button>
|
<input type="hidden" name="adoption_notice_id" value="{{ adoption_notice.pk }}">
|
||||||
</form>
|
<button class="btn2" type="submit" id="submit"><i class="fa-solid fa-bell"></i></button>
|
||||||
|
</form>
|
||||||
|
<span class="tooltiptext">
|
||||||
|
{% translate 'Abonniere diese Vermittlung um bei Kommentaren oder Statusänderungen benachrichtigt zu werden' %}
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
{% else %}
|
{% else %}
|
||||||
<form class="notification-card-mark-read" method="post">
|
<form class="notification-card-mark-read" method="post">
|
||||||
{% csrf_token %}
|
{% csrf_token %}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user