ShareLinks: disable tag links, actually hide add-to-playlist/collection

The movie detail page's Tags section lives in its own .itemTags container,
not inside .detailsGroupItem like genres/studios/cast, so tag chips stayed
clickable for guests. Disable those links too.

The add-to-playlist and add-to-collection entries in the item's "..."
menu render with data-id="playlist"/data-id="addtocollection", not
data-action="addtoplaylist"/"addtocollection" as previously assumed —
that selector matched an unrelated list-row button and never hid the
actual menu items. Target the correct attribute so both are hidden.

Also drop the specific plugin name from the guest-hidden-selectors
description in favor of generic wording; the default selector value
is unchanged.
Cette révision appartient à :
Franciskid
2026-07-07 09:05:18 +02:00
Parent 1f7928527e
révision ceb3c03c87
5 fichiers modifiés avec 17 ajouts et 12 suppressions
+1 -1
Voir le fichier
@@ -125,7 +125,7 @@
<div class="sl-field inputContainer" style="grid-column: 1 / -1;">
<input is="emby-input" type="text" id="GuestHiddenSelectors" label="Guest hidden selectors (CSS, comma-separated)" />
<div class="fieldDescription">Elements hidden from guest sessions, e.g. other plugins' buttons. Default hides the AI Search UI.</div>
<div class="fieldDescription">Elements hidden from guest sessions, e.g. other plugins' buttons. The default hides a plugin I had installed that injects its own floating UI into the web client.</div>
</div>
<div class="sl-field inputContainer">
+5 -2
Voir le fichier
@@ -2,7 +2,7 @@
var pluginId = '68540b76-ee74-436d-85ff-2abc884bbea6';
var copyLabel = 'Copy Stream URL';
var actionLabel = 'ShareLink';
var clientVersion = '1.0.0-ui-modal-9';
var clientVersion = '1.0.0-ui-modal-10';
var allowedItemStorageKey = 'sharelinks.allowedItemId';
var guestClassName = 'sharelinks-guest';
var hiddenAttr = 'data-sharelinks-hidden';
@@ -233,12 +233,15 @@
+ ' body.' + guestClassName + ' .mainDrawerButton,'
+ ' body.' + guestClassName + ' .headerSearchButton,'
+ ' body.' + guestClassName + ' [data-action="addtoplaylist"],'
+ ' body.' + guestClassName + ' [data-action="addtocollection"] { display: none !important; }'
+ ' body.' + guestClassName + ' [data-action="addtocollection"],'
+ ' body.' + guestClassName + ' [data-id="playlist"],'
+ ' body.' + guestClassName + ' [data-id="addtocollection"] { display: none !important; }'
+ ' body.' + guestClassName + ' .card,'
+ ' body.' + guestClassName + ' #castCollapsible a,'
+ ' body.' + guestClassName + ' .detailsGroupItem a,'
+ ' body.' + guestClassName + ' .genresGroup a,'
+ ' body.' + guestClassName + ' .studiosGroup a,'
+ ' body.' + guestClassName + ' .itemTags a,'
+ ' body.' + guestClassName + ' .mediaInfoItem a { pointer-events: none !important; cursor: default !important; }';
document.head.appendChild(style);
}