mirror of
https://github.com/penpot/penpot.git
synced 2026-04-25 11:18:36 +00:00
✨ Allow customising the OIDC login button label (#9026)
* ✨ Allow customising the OIDC login button label (#7027) * 📚 Add CHANGES entry and docs for PENPOT_OIDC_NAME (#7027) --------- Co-authored-by: wdeveloper16 <wdeveloer16@protonmail.com>
This commit is contained in:
parent
c5a2b592a2
commit
d772632b08
@ -40,7 +40,7 @@
|
||||
- Persist asset search query and section filter when switching sidebar tabs (by @eureka0928) [Github #2913](https://github.com/penpot/penpot/issues/2913)
|
||||
- Add delete and duplicate buttons to typography dialog (by @eureka0928) [Github #5270](https://github.com/penpot/penpot/issues/5270)
|
||||
- Edit ruler guide position by double-clicking the guide pill (by @eureka0928) [Github #2311](https://github.com/penpot/penpot/issues/2311)
|
||||
|
||||
- Allow customising the OIDC login button label (by @wdeveloper16) [Github #7027](https://github.com/penpot/penpot/issues/7027)
|
||||
|
||||
### :bug: Bugs fixed
|
||||
|
||||
|
||||
@ -1,2 +1,3 @@
|
||||
// Frontend configuration
|
||||
//var penpotFlags = "";
|
||||
//var penpotOIDCName = "";
|
||||
|
||||
@ -21,7 +21,16 @@ update_flags() {
|
||||
fi
|
||||
}
|
||||
|
||||
update_oidc_name() {
|
||||
if [ -n "$PENPOT_OIDC_NAME" ]; then
|
||||
echo "$(sed \
|
||||
-e "s|^//var penpotOIDCName = .*;|var penpotOIDCName = \"$PENPOT_OIDC_NAME\";|g" \
|
||||
"$1")" > "$1"
|
||||
fi
|
||||
}
|
||||
|
||||
update_flags /var/www/app/js/config.js
|
||||
update_oidc_name /var/www/app/js/config.js
|
||||
|
||||
#########################################
|
||||
## Nginx Config
|
||||
|
||||
@ -242,6 +242,16 @@ register with another method.
|
||||
PENPOT_FLAGS: [...] enable-oidc-registration
|
||||
```
|
||||
|
||||
__Since version 2.16.0__
|
||||
|
||||
Allows customising the label shown on the OIDC login button (defaults to "OpenID").
|
||||
|
||||
```bash
|
||||
# Frontend
|
||||
PENPOT_OIDC_NAME: <provider-name>
|
||||
```
|
||||
<br />
|
||||
|
||||
#### Azure Active Directory using OpenID Connect
|
||||
|
||||
Allows integrating with Azure Active Directory as authentication provider:
|
||||
|
||||
@ -154,6 +154,7 @@
|
||||
true))))
|
||||
|
||||
(def terms-of-service-uri (obj/get global "penpotTermsOfServiceURI"))
|
||||
(def oidc-name (obj/get global "penpotOIDCName"))
|
||||
(def privacy-policy-uri (obj/get global "penpotPrivacyPolicyURI"))
|
||||
(def flex-help-uri (obj/get global "penpotGridHelpURI" "https://help.penpot.app/user-guide/flexible-layouts/"))
|
||||
(def grid-help-uri (obj/get global "penpotGridHelpURI" "https://help.penpot.app/user-guide/flexible-layouts/"))
|
||||
|
||||
@ -239,7 +239,7 @@
|
||||
(when (contains? cf/flags :login-with-oidc)
|
||||
[:& bl/button-link {:on-click login-with-oidc
|
||||
:icon deprecated-icon/brand-openid
|
||||
:label (tr "auth.login-with-oidc-submit")
|
||||
:label (or (not-empty cf/oidc-name) (tr "auth.login-with-oidc-submit"))
|
||||
:class (stl/css :login-btn :btn-oidc-auth)}])]))
|
||||
|
||||
(mf/defc login-dialog*
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user