mirror of
https://github.com/andwati/zitadel.git
synced 2026-11-07 06:42:15 +00:00
feat(console): message and login texts, privacy policy (#2016)
* message texts wrapper components * message-text sub, i18n, grid * fix routing * pack * pack * update material * audit * fix mgmt service for labelplcy * map conv * edit text from map * request map * fetch data, mgmt admin service * warn box, i18n * resetbtn * login texts * login text requests * reset, default, i18n * disabled, features, message text setter, service * locale switcher * policy grid * password reset, domain claimed i18n * lint files * fix admin service, i18n, lang setter * fix scss duplicate * privacy policy, cleanup grid, fix message, login texts (#2031) * policy grid everywhere 🦒 * cleanup home * log login text request * patch all data * refresh toggle * fix: add dialog for unsaved changes (#2057) * logintexts dialog * check for dialog on pairwise operation * fix: patch value to local state after save * fix: i18n and custom login texts (#2060) * fix: i18n and custom login texts * fix: tos and privacy texts * fix frontend * fix: tos and privacy texts and tests * fix: i18n, tos and privacy texts and tests * fix frontend maps * i18n * add ResetCustomLoginTextToDefault in admin api and fix template remove in handlers * resetlogintexttodefault Co-authored-by: Livio Amstutz <[email protected]>
This commit is contained in:
co-authored by
Livio Amstutz
parent
26e4e607bc
commit
2e684684de
@@ -168,46 +168,42 @@ type CustomLoginTextReadModel struct {
|
||||
RegistrationOptionUserNameButtonText string
|
||||
RegistrationOptionExternalLoginDescription string
|
||||
|
||||
RegistrationUserTitle string
|
||||
RegistrationUserDescription string
|
||||
RegistrationUserDescriptionOrgRegister string
|
||||
RegistrationUserFirstnameLabel string
|
||||
RegistrationUserLastnameLabel string
|
||||
RegistrationUserEmailLabel string
|
||||
RegistrationUserUsernameLabel string
|
||||
RegistrationUserLanguageLabel string
|
||||
RegistrationUserGenderLabel string
|
||||
RegistrationUserPasswordLabel string
|
||||
RegistrationUserPasswordConfirmLabel string
|
||||
RegistrationUserTOSAndPrivacyLabel string
|
||||
RegistrationUserTOSConfirm string
|
||||
RegistrationUserTOSLink string
|
||||
RegistrationUserTOSLinkText string
|
||||
RegistrationUserPrivacyConfirm string
|
||||
RegistrationUserPrivacyLink string
|
||||
RegistrationUserPrivacyLinkText string
|
||||
RegistrationUserExternalLoginDescription string
|
||||
RegistrationUserNextButtonText string
|
||||
RegistrationUserBackButtonText string
|
||||
RegistrationUserTitle string
|
||||
RegistrationUserDescription string
|
||||
RegistrationUserDescriptionOrgRegister string
|
||||
RegistrationUserFirstnameLabel string
|
||||
RegistrationUserLastnameLabel string
|
||||
RegistrationUserEmailLabel string
|
||||
RegistrationUserUsernameLabel string
|
||||
RegistrationUserLanguageLabel string
|
||||
RegistrationUserGenderLabel string
|
||||
RegistrationUserPasswordLabel string
|
||||
RegistrationUserPasswordConfirmLabel string
|
||||
RegistrationUserTOSAndPrivacyLabel string
|
||||
RegistrationUserTOSConfirm string
|
||||
RegistrationUserTOSLink string
|
||||
RegistrationUserTOSLinkText string
|
||||
RegistrationUserTOSConfirmAnd string
|
||||
RegistrationUserPrivacyLink string
|
||||
RegistrationUserPrivacyLinkText string
|
||||
RegistrationUserNextButtonText string
|
||||
RegistrationUserBackButtonText string
|
||||
|
||||
RegisterOrgTitle string
|
||||
RegisterOrgDescription string
|
||||
RegisterOrgOrgNameLabel string
|
||||
RegisterOrgFirstnameLabel string
|
||||
RegisterOrgLastnameLabel string
|
||||
RegisterOrgUsernameLabel string
|
||||
RegisterOrgEmailLabel string
|
||||
RegisterOrgPasswordLabel string
|
||||
RegisterOrgPasswordConfirmLabel string
|
||||
RegisterOrgTOSAndPrivacyLabel string
|
||||
RegisterOrgTOSConfirm string
|
||||
RegisterOrgTOSLink string
|
||||
RegisterOrgTOSLinkText string
|
||||
RegisterOrgPrivacyConfirm string
|
||||
RegisterOrgPrivacyLink string
|
||||
RegisterOrgPrivacyLinkText string
|
||||
RegisterOrgExternalLoginDescription string
|
||||
RegisterOrgSaveButtonText string
|
||||
RegisterOrgTitle string
|
||||
RegisterOrgDescription string
|
||||
RegisterOrgOrgNameLabel string
|
||||
RegisterOrgFirstnameLabel string
|
||||
RegisterOrgLastnameLabel string
|
||||
RegisterOrgUsernameLabel string
|
||||
RegisterOrgEmailLabel string
|
||||
RegisterOrgPasswordLabel string
|
||||
RegisterOrgPasswordConfirmLabel string
|
||||
RegisterOrgTOSAndPrivacyLabel string
|
||||
RegisterOrgTOSConfirm string
|
||||
RegisterOrgTOSLinkText string
|
||||
RegisterOrgTOSConfirmAnd string
|
||||
RegisterOrgPrivacyLinkText string
|
||||
RegisterOrgSaveButtonText string
|
||||
|
||||
LinkingUserDoneTitle string
|
||||
LinkingUserDoneDescription string
|
||||
@@ -228,12 +224,10 @@ type CustomLoginTextReadModel struct {
|
||||
LogoutDoneDescription string
|
||||
LogoutDoneLoginButtonText string
|
||||
|
||||
FooterTOS string
|
||||
FooterTOSLink string
|
||||
FooterPrivacyPolicy string
|
||||
FooterPrivacyPolicyLink string
|
||||
FooterHelp string
|
||||
FooterHelpLink string
|
||||
FooterTOS string
|
||||
FooterPrivacyPolicy string
|
||||
FooterHelp string
|
||||
FooterHelpLink string
|
||||
}
|
||||
|
||||
func (wm *CustomLoginTextReadModel) Reduce() error {
|
||||
@@ -1708,30 +1702,18 @@ func (wm *CustomLoginTextReadModel) handleRegistrationUserScreenSetEvent(e *poli
|
||||
wm.RegistrationUserTOSConfirm = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserTOSLink {
|
||||
wm.RegistrationUserTOSLink = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserTOSLinkText {
|
||||
wm.RegistrationUserTOSLinkText = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserPrivacyConfirm {
|
||||
wm.RegistrationUserPrivacyConfirm = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserPrivacyLink {
|
||||
wm.RegistrationUserPrivacyLink = e.Text
|
||||
if e.Key == domain.LoginKeyRegistrationUserTOSConfirmAnd {
|
||||
wm.RegistrationUserTOSConfirmAnd = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserPrivacyLinkText {
|
||||
wm.RegistrationUserPrivacyLinkText = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserExternalLoginDescription {
|
||||
wm.RegistrationUserExternalLoginDescription = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserNextButtonText {
|
||||
wm.RegistrationUserNextButtonText = e.Text
|
||||
return
|
||||
@@ -1795,30 +1777,18 @@ func (wm *CustomLoginTextReadModel) handleRegistrationUserScreenRemoveEvent(e *p
|
||||
wm.RegistrationUserTOSConfirm = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserTOSLink {
|
||||
wm.RegistrationUserTOSLink = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserTOSLinkText {
|
||||
wm.RegistrationUserTOSLinkText = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserPrivacyConfirm {
|
||||
wm.RegistrationUserPrivacyConfirm = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserPrivacyLink {
|
||||
wm.RegistrationUserPrivacyLink = ""
|
||||
if e.Key == domain.LoginKeyRegistrationUserTOSConfirmAnd {
|
||||
wm.RegistrationUserTOSConfirmAnd = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserPrivacyLinkText {
|
||||
wm.RegistrationUserPrivacyLinkText = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserExternalLoginDescription {
|
||||
wm.RegistrationUserExternalLoginDescription = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegistrationUserNextButtonText {
|
||||
wm.RegistrationUserNextButtonText = ""
|
||||
return
|
||||
@@ -1874,30 +1844,18 @@ func (wm *CustomLoginTextReadModel) handleRegistrationOrgScreenSetEvent(e *polic
|
||||
wm.RegisterOrgTOSConfirm = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgTOSLink {
|
||||
wm.RegisterOrgTOSLink = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgTOSLinkText {
|
||||
wm.RegisterOrgTOSLinkText = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgPrivacyConfirm {
|
||||
wm.RegisterOrgPrivacyConfirm = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgPrivacyLink {
|
||||
wm.RegisterOrgPrivacyLink = e.Text
|
||||
if e.Key == domain.LoginKeyRegisterOrgTosConfirmAnd {
|
||||
wm.RegisterOrgTOSConfirmAnd = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgPrivacyLinkText {
|
||||
wm.RegisterOrgPrivacyLinkText = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgExternalLoginDescription {
|
||||
wm.RegisterOrgExternalLoginDescription = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgSaveButtonText {
|
||||
wm.RegisterOrgSaveButtonText = e.Text
|
||||
return
|
||||
@@ -1949,30 +1907,18 @@ func (wm *CustomLoginTextReadModel) handleRegistrationOrgScreenRemoveEvent(e *po
|
||||
wm.RegisterOrgTOSConfirm = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgTOSLink {
|
||||
wm.RegisterOrgTOSLink = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgTOSLinkText {
|
||||
wm.RegisterOrgTOSLinkText = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgPrivacyConfirm {
|
||||
wm.RegisterOrgPrivacyConfirm = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgPrivacyLink {
|
||||
wm.RegisterOrgPrivacyLink = ""
|
||||
if e.Key == domain.LoginKeyRegisterOrgTosConfirmAnd {
|
||||
wm.RegisterOrgTOSConfirmAnd = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgPrivacyLinkText {
|
||||
wm.RegisterOrgPrivacyLinkText = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgExternalLoginDescription {
|
||||
wm.RegisterOrgExternalLoginDescription = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyRegisterOrgSaveButtonText {
|
||||
wm.RegisterOrgSaveButtonText = ""
|
||||
return
|
||||
@@ -2128,18 +2074,10 @@ func (wm *CustomLoginTextReadModel) handleFooterTextSetEvent(e *policy.CustomTex
|
||||
wm.FooterTOS = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyFooterTOSLink {
|
||||
wm.FooterTOSLink = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyFooterPrivacy {
|
||||
if e.Key == domain.LoginKeyFooterPrivacyPolicy {
|
||||
wm.FooterPrivacyPolicy = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyFooterPrivacyLink {
|
||||
wm.FooterPrivacyPolicyLink = e.Text
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyFooterHelp {
|
||||
wm.FooterHelp = e.Text
|
||||
return
|
||||
@@ -2155,18 +2093,10 @@ func (wm *CustomLoginTextReadModel) handleFooterTextRemoveEvent(e *policy.Custom
|
||||
wm.FooterTOS = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyFooterTOSLink {
|
||||
wm.FooterTOSLink = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyFooterPrivacy {
|
||||
if e.Key == domain.LoginKeyFooterPrivacyPolicy {
|
||||
wm.FooterPrivacyPolicy = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyFooterPrivacyLink {
|
||||
wm.FooterPrivacyPolicyLink = ""
|
||||
return
|
||||
}
|
||||
if e.Key == domain.LoginKeyFooterHelp {
|
||||
wm.FooterHelp = ""
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user