DonutsNL / DonutsNL/samlsso

'Feature request: make login screen header text and IdP button icon configurable via plugin settings' labels: enhancement

Open
#159 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
PHP
Stars
55
Forks
13
PR merge metrics
No merged PRs in 30d

Description

**Plugin version:** 1.3.1
**GLPI version:** 11.0.8

## Feature request

Currently the SAML login section on the GLPI login page is not customizable without code/CSS changes:

1. **Header text** is hardcoded in `src/LoginFlow.php` (`showLoginScreen()`):
```php
$tplVars['header'] = __('Login with external provider', PLUGIN_NAME);
```
There is no setting to change this text (e.g., to the organization's own wording or language).

2. **Button icon** is a FontAwesome CSS class stored in the `conf_icon` field of the IdP configuration. It is not possible to use a custom uploaded image/logo without CSS hacks (overriding the `` element background via custom stylesheet).

## Suggested improvement

- Add an optional **custom header text** setting to the IdP configuration form (falling back to the default translatable string when empty). It would be even better if the text could support per-language values.
- Add an option to use a **custom image URL** for the login button icon (in addition to the FontAwesome picker), e.g., a text field for an image URL or an upload field. The login screen template (`templates/loginScreen.html.twig`) would render an `` instead of `` when a custom image is set.

## Current workarounds

- Header text: override via GLPI custom CSS:
```css
#saml_header h2 { font-size: 0; }
#saml_header h2::after { content: "Your custom text"; font-size: 1.5rem; }
```
or by editing `templates/loginScreen.html.twig` (lost on plugin update).
- Icon: CSS background-image override on `#saml_buttons button i.fa-5x` (also lost/unmaintainable across updates, and fragile).

These workarounds are fragile and not accessible to non-technical administrators. Native settings would be much appreciated.

Contributor guide

Open the contributing guide

Research direction

Start with src/LoginFlow.php and showLoginScreen(), then inspect templates/loginScreen.html.twig and the IdP configuration form. Trace how conf_icon is stored and rendered before deciding how the optional header text and custom image setting fit the existing configuration flow. Done means administrators can configure these values, defaults remain unchanged when empty, and the login screen renders the configured text and icon.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
authentication
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.