fsd
parent
78dbd250f6
commit
81353bc46d
|
@ -75,6 +75,17 @@
|
|||
document.getElementById('toast-post-error-text').innerText = "Only logged-in users can vote!";
|
||||
{% endif %}
|
||||
}
|
||||
|
||||
const popoverTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="popover"]'));
|
||||
|
||||
const popoverList = popoverTriggerList.map(function(popoverTriggerEl) {
|
||||
const popoverId = popoverTriggerEl.getAttribute('data-content-id');
|
||||
const contentEl = document.getElementById(popoverId).innerHTML;
|
||||
return new bootstrap.Popover(popoverTriggerEl, {
|
||||
content: contentEl,
|
||||
html: true,
|
||||
});
|
||||
})
|
||||
</script>
|
||||
|
||||
|
||||
|
@ -98,6 +109,40 @@
|
|||
})()
|
||||
</script>
|
||||
|
||||
<div style="display:none" id="popover-{{p.id}}">
|
||||
<div class="popover-user-profile" role="tooltip">
|
||||
<img class="w-100 h-64 object-cover" src="{{p.author.banner_url}}">
|
||||
<div class="d-flex align-items-end px-3 mt-n6 mb-3">
|
||||
<img class="avatar-72 rounded img-thumbnail shadow-sm" src="{{p.author.profile_url}}">
|
||||
<div class="px-3 text-truncate">
|
||||
<h5 class="text-truncate text-black">{{p.author.username}}</h5>
|
||||
</div>
|
||||
</div>
|
||||
<div class="px-3">
|
||||
<span class="text-black">{% if p.author.bio_html %}{{p.author.bio_html | safe}}{% endif %}</span>
|
||||
</div>
|
||||
<div class="border-top d-flex align-items-center p-3 mt-3 gap-3">
|
||||
<span>
|
||||
<strong class="text-black">{{p.author.post_count}}</strong>
|
||||
<span class="text-black">posts</span>
|
||||
</span>
|
||||
<span class="ml-2">
|
||||
<strong class="text-black">{{p.author.comment_count}}</strong>
|
||||
<span class="text-black">comments</span>
|
||||
</span>
|
||||
<span class="ml-2">
|
||||
<strong class="text-black">{{p.author.coins}}</strong>
|
||||
<span class="text-black">dramacoins</span>
|
||||
</span>
|
||||
|
||||
<a {% if v %}href="{{p.author.url}}"{% else %}href="/logged_out{{p.author.url}}"{% endif %} target="_blank" class="ml-auto text-decoration-none">
|
||||
View
|
||||
<i class="fas fa-arrow-right fa-sm px-1"></i>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% set ups=c.upvotes %}
|
||||
{% set downs=c.downvotes %}
|
||||
{% set score=ups-downs %}
|
||||
|
@ -228,7 +273,7 @@
|
|||
{% if c.author.verified %}<i class="fas fa-badge-check align-middle ml-1" style="color:{% if c.author.id == 541 %}#62ca56{% else %}#1DA1F2{% endif %}" data-bs-toggle="tooltip" data-bs-placement="bottom" title="" data-bs-original-title="{{c.author.verified}}"></i>
|
||||
{% endif %}
|
||||
|
||||
<a {% if v %}href="{{c.author.url}}"{% else %}href="/logged_out{{c.author.url}}"{% endif %} style="color:#{{c.author.namecolor}}; font-size:12px; font-weight:bold;"><img loading="lazy" src="{{c.author.profile_url}}" class="profile-pic-25 mr-2"/><span {% if c.author.patron and not c.distinguish_level %}class="patron" style="background-color:#{{c.author.namecolor}};"{% elif c.distinguish_level and 'rama' in request.host %}class="mod"{% endif %}>{{c.author.username}}</span></a>
|
||||
<a class="user-name text-decoration-none" data-bs-position="auto" data-bs-toggle="popover" data-bs-trigger="focus" data-content-id="popover-{{p.id}}" href="javascript:void(0)" tabindex="0" style="color:#{{c.author.namecolor}}; font-size:12px; font-weight:bold;"><img loading="lazy" src="{{c.author.profile_url}}" class="profile-pic-25 mr-2"/><span {% if c.author.patron and not c.distinguish_level %}class="patron" style="background-color:#{{c.author.namecolor}};"{% elif c.distinguish_level and 'rama' in request.host %}class="mod"{% endif %}>{{c.author.username}}</span></a>
|
||||
{% if c.author.customtitle %} <bdi style="color: #{{c.author.titlecolor}}"> {% if c.author.quadrant %}<img loading="lazy" height="20" src="/assets/images/PCM/quadrants/{{c.author.quadrant}}.gif">{% endif %}{{c.author.customtitle | safe}}</bdi>{% endif %}
|
||||
|
||||
{% if c.parent_comment_id and not standalone and level<=7 %}<a href="#comment-{{ c.parent_comment_id }}-only" class="text-muted ml-2"><i class="fas fa-reply fa-sm fa-fw fa-flip-horizontal mr-1"></i>{{ c.parent_comment.author.username }}</a>{% endif %}
|
||||
|
@ -681,6 +726,59 @@
|
|||
background: -webkit-linear-gradient(left, red, orange, yellow, green, blue, indigo, violet );
|
||||
text-shadow:-1px -1px 0 black,1px -1px 0 black,-1px 1px 0 black,1px 1px 0 black;
|
||||
}
|
||||
|
||||
.popover {
|
||||
max-width: 320px;
|
||||
box-shadow: 0 1rem 3rem rgba(0, 0, 0, .175);
|
||||
border-color: #dadada;
|
||||
}
|
||||
|
||||
.popover-arrow {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.popover-user-profile {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
padding: 0;
|
||||
background: var(--gray-600);
|
||||
}
|
||||
|
||||
.popover-body {
|
||||
padding: 0;
|
||||
border-radius: .25rem;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.mt-n6 {
|
||||
margin-top: -1.75rem !important;
|
||||
}
|
||||
|
||||
.avatar-72 {
|
||||
width: 72px;
|
||||
height: 72px;
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
.h-64 {
|
||||
height: 64px;
|
||||
}
|
||||
|
||||
.object-cover {
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
.text-black {
|
||||
color: var(--black);
|
||||
}
|
||||
|
||||
.smolbtn {
|
||||
font-weight: 600;
|
||||
font-size: .9rem;
|
||||
border-radius: 0.2rem;
|
||||
padding: 0.1rem 0.50rem 0rem 0.30rem;
|
||||
background-color: var(--black) !important;
|
||||
}
|
||||
</style>
|
||||
|
||||
</body>
|
|
@ -163,6 +163,42 @@
|
|||
{% block pagetype %}thread{% endblock %}
|
||||
|
||||
{% block actionsModal %}
|
||||
|
||||
<div style="display:none" id="popover-{{p.id}}">
|
||||
<div class="popover-user-profile" role="tooltip">
|
||||
<img class="w-100 h-64 object-cover" src="{{p.author.banner_url}}">
|
||||
<div class="d-flex align-items-end px-3 mt-n6 mb-3">
|
||||
<img class="avatar-72 rounded img-thumbnail shadow-sm" src="{{p.author.profile_url}}">
|
||||
<div class="px-3 text-truncate">
|
||||
<h5 class="text-truncate text-black">{{p.author.username}}</h5>
|
||||
</div>
|
||||
</div>
|
||||
<div class="px-3">
|
||||
<span class="text-black">{% if p.author.bio_html %}{{p.author.bio_html | safe}}{% endif %}</span>
|
||||
</div>
|
||||
<div class="border-top d-flex align-items-center p-3 mt-3 gap-3">
|
||||
<span>
|
||||
<strong class="text-black">{{p.author.post_count}}</strong>
|
||||
<span class="text-black">posts</span>
|
||||
</span>
|
||||
<span class="ml-2">
|
||||
<strong class="text-black">{{p.author.comment_count}}</strong>
|
||||
<span class="text-black">comments</span>
|
||||
</span>
|
||||
<span class="ml-2">
|
||||
<strong class="text-black">{{p.author.coins}}</strong>
|
||||
<span class="text-black">dramacoins</span>
|
||||
</span>
|
||||
|
||||
<a {% if v %}href="{{p.author.url}}"{% else %}href="/logged_out{{p.author.url}}"{% endif %} target="_blank" class="ml-auto text-decoration-none">
|
||||
View
|
||||
<i class="fas fa-arrow-right fa-sm px-1"></i>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="modal fade modal-sm-bottom d-md-none" id="actionsModal" tabindex="-1" role="dialog" aria-labelledby="actionsModalTitle" aria-hidden="true">
|
||||
<div class="modal-dialog modal-dialog-centered" role="document">
|
||||
<div class="modal-content">
|
||||
|
@ -300,7 +336,7 @@
|
|||
{% if p.active_flags %}<a class="btn btn-primary" href="javascript:void(0)" style="padding:1px 5px; font-size:10px;" onclick="document.getElementById('flaggers').classList.toggle('d-none')">{{p.active_flags}} Reports</a>{% endif %}
|
||||
{% if p.author.verified %}<i class="fas fa-badge-check align-middle ml-1" style="color:{% if p.author.id == 541 %}#62ca56{% else %}#1DA1F2{% endif %}" data-bs-toggle="tooltip" data-bs-placement="bottom" title="" data-bs-original-title="{{p.author.verified}}"></i>
|
||||
{% endif %}
|
||||
<a {% if v %}href="{{p.author.url}}"{% else %}href="/logged_out{{p.author.url}}"{% endif %} style="color: #{{p.author.namecolor}}; font-weight: bold;" class="user-name"><img loading="lazy" src="{{p.author.profile_url}}" class="profile-pic-25 mr-2"/><span {% if p.author.patron and not p.distinguish_level %}class="patron" style="background-color:#{{p.author.namecolor}};"{% elif p.distinguish_level and 'rama' in request.host %}class="mod"{% endif %}>{{p.author.username}}</span></a>{% if p.author.customtitle %} <bdi style="color: #{{p.author.titlecolor}}"> {% if p.author.quadrant %}<img loading="lazy" height="20" src="/assets/images/PCM/quadrants/{{p.author.quadrant}}.gif">{% endif %}{{p.author.customtitle | safe}}</bdi>{% endif %}
|
||||
<a class="user-name text-decoration-none" data-bs-position="auto" data-bs-toggle="popover" data-bs-trigger="focus" data-content-id="popover-{{p.id}}" href="javascript:void(0)" tabindex="0" style="color: #{{p.author.namecolor}}; font-weight: bold;" class="user-name"><img loading="lazy" src="{{p.author.profile_url}}" class="profile-pic-25 mr-2"/><span {% if p.author.patron and not p.distinguish_level %}class="patron" style="background-color:#{{p.author.namecolor}};"{% elif p.distinguish_level and 'rama' in request.host %}class="mod"{% endif %}>{{p.author.username}}</span></a>{% if p.author.customtitle %} <bdi style="color: #{{p.author.titlecolor}}"> {% if p.author.quadrant %}<img loading="lazy" height="20" src="/assets/images/PCM/quadrants/{{p.author.quadrant}}.gif">{% endif %}{{p.author.customtitle | safe}}</bdi>{% endif %}
|
||||
<span data-bs-toggle="tooltip" data-bs-placement="bottom" id="timestamp"> {{p.age_string}}</span>
|
||||
({% if p.realurl(v) %}<a href="/search/posts/?q=domain%3A{{p.domain}}&sort=new&t=all" {% if not v or v.newtabexternal %}target="_blank"{% endif %}>{{p.domain}}</a>{% else %}text post{% endif %})
|
||||
|
||||
|
|
|
@ -20,16 +20,6 @@
|
|||
console.log(e);
|
||||
});
|
||||
|
||||
const popoverTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="popover"]'));
|
||||
|
||||
const popoverList = popoverTriggerList.map(function(popoverTriggerEl) {
|
||||
const popoverId = popoverTriggerEl.getAttribute('data-content-id');
|
||||
const contentEl = document.getElementById(popoverId).innerHTML;
|
||||
return new bootstrap.Popover(popoverTriggerEl, {
|
||||
content: contentEl,
|
||||
html: true,
|
||||
});
|
||||
})
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
@ -89,17 +79,13 @@
|
|||
|
||||
{% for p in listing %}
|
||||
|
||||
<div style="display: none" id="popover-{{p.id}}">
|
||||
<div style="display:none" id="popover-{{p.id}}">
|
||||
<div class="popover-user-profile" role="tooltip">
|
||||
<img class="w-100 h-64 object-cover" src="{{p.author.banner_url}}">
|
||||
<div class="d-flex align-items-end px-3 mt-n6 mb-3">
|
||||
<img class="avatar-72 rounded img-thumbnail shadow-sm" src="{{p.author.profile_url}}">
|
||||
<div class="px-3 text-truncate">
|
||||
<h5 class="text-truncate text-black">{{p.author.username}}</h5>
|
||||
<!-- {% if p.author.id != 995 %}<a id="button-unsub2" class="smolbtn btn-secondary {% if not is_following %}d-none{% endif %}" href="javascript:void(0)" onclick="post_toast2('/unfollow/{{p.author.username}}','button-unsub2','button-sub2')">Unfollow</a>{% endif %}
|
||||
<a id="button-sub2" class="smolbtn btn-primary {% if is_following or p.author.is_nofollow or p.author.is_blocked %}d-none{% endif %}" href="javascript:void(0)" onclick="post_toast2('/follow/{{p.author.username}}','button-unsub2','button-sub2')">Follow</a> -->
|
||||
<button id="block-user-{{p.id}}" class="smolbtn btn-primary {% if p.is_blocking %}d-none{% endif %}" href="javascript:void(0)" onclick="alert('1')"><i class="fas fa-eye-slash"></i>Block</button>
|
||||
<a id="unblock-user-{{p.id}}" class="smolbtn btn-primary {% if not p.is_blocking %}d-none{% endif %}" href="javascript:void(0)" onclick="post_toast2('/settings/unblock?username={{p.author.username}}','block-user-{{p.id}}','unblock-user-{{p.id}}')"><i class="fas fa-eye"></i>Unblock</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="px-3">
|
||||
|
|
Loading…
Reference in New Issue