hgfd
This commit is contained in:
+20
-2
@@ -103,12 +103,30 @@
|
||||
if (canManage) {
|
||||
span.classList.add('can-cycle');
|
||||
}
|
||||
} else if (!window.f0ckSession?.is_anonymized && window.f0ckSession?.logged_in && !window.f0ckSession?.is_anon && (tag.display_name || tag.user)) {
|
||||
span.setAttribute('tooltip', tag.display_name || tag.user);
|
||||
} else {
|
||||
span.classList.add('tag-badge');
|
||||
span.setAttribute('data-tag-id', tag.id || '');
|
||||
span.setAttribute('data-tag', tag.tag);
|
||||
span.setAttribute('data-tag-normalized', tag.normalized);
|
||||
if (!window.f0ckSession?.is_anonymized && window.f0ckSession?.logged_in && !window.f0ckSession?.is_anon && (tag.display_name || tag.user)) {
|
||||
span.setAttribute('tooltip', tag.display_name || tag.user);
|
||||
}
|
||||
const isExcl = !!tag.is_excluded;
|
||||
if (isExcl) span.classList.add('tag-is-excluded');
|
||||
}
|
||||
|
||||
span.insertAdjacentElement("beforeend", contentEl);
|
||||
|
||||
if (!isRating && tag.can_exclude) {
|
||||
const excludeBtn = document.createElement('button');
|
||||
excludeBtn.type = 'button';
|
||||
excludeBtn.className = 'tag-exclude-btn';
|
||||
excludeBtn.setAttribute('title', tag.is_excluded ? 'Excluded (click to unexclude)' : 'Exclude tag');
|
||||
excludeBtn.setAttribute('aria-label', 'Exclude tag');
|
||||
excludeBtn.innerHTML = `<i class="fa-solid ${tag.is_excluded ? 'fa-circle-check' : 'fa-ban'}"></i>`;
|
||||
span.insertAdjacentElement('beforeend', excludeBtn);
|
||||
}
|
||||
|
||||
if (window.f0ckSession && (window.f0ckSession.is_admin || window.f0ckSession.is_moderator) && !isRating) {
|
||||
const space = document.createTextNode('\u00A0'); //
|
||||
span.appendChild(space);
|
||||
|
||||
Reference in New Issue
Block a user