docs: fix the login button snippet

The documented snippet relied on is="emby-linkbutton", but Jellyfin renders the
login disclaimer through markdown-it and then DOMPurify, which strips the is
attribute. The anchor therefore never became a button component and rendered as
a plain link.

Drop the attribute, keep the classes so the theme styles the button, and
document the Custom CSS the disclaimer needs: .disclaimerContainer is not a
block by default, so a "block" button cannot stretch to the width of the other
login buttons, and the anchor colour rule outranks .emby-button.

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2026-07-29 15:48:30 +02:00
parent fda59741b5
commit b5a0bd79a3

View File

@@ -89,13 +89,39 @@ Then in Jellyfin: Dashboard → Plugins → OIDC Auth:
## Login button on the web login page ## Login button on the web login page
Jellyfin does not let plugins modify the login page. Add a button via Jellyfin does not let plugins modify the login page. The login disclaimer is the
Dashboard → General → Branding → Login disclaimer: only injection point, and it needs a little CSS to look like a real button.
Dashboard → General → Branding → **Login disclaimer**:
```html ```html
<a is="emby-linkbutton" class="raised block emby-button" href="/OidcAuth/login">Sign in with SSO</a> <a href="/OidcAuth/login" class="raised block emby-button">Sign in with SSO</a>
``` ```
Dashboard → General → Branding → **Custom CSS**:
```css
.disclaimerContainer {
display: block;
}
a.raised.emby-button {
padding: 0.9em 1em;
color: inherit !important;
text-decoration: none;
}
```
Both pieces are needed. Jellyfin renders the disclaimer through markdown-it and
then DOMPurify, which strips the `is="emby-linkbutton"` attribute that would
normally turn the anchor into a button component — so the styling has to come
from the classes instead. `.disclaimerContainer` is not a block by default,
which is what otherwise leaves the link shrink-wrapped and centred instead of
matching the width of the buttons above it.
Styling via the theme's own classes rather than inline styles keeps the button
correct when the theme changes, since `.raised` is defined per theme.
## TV and native clients ## TV and native clients
The plugin does not change or disable Jellyfin's normal password login, so TV apps The plugin does not change or disable Jellyfin's normal password login, so TV apps