@keycloakify/angular 0.0.1-rc.0 → 0.0.1-rc.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (497) hide show
  1. package/account/DefaultPage.d.ts +38 -0
  2. package/account/DefaultPage.js +34 -0
  3. package/account/KcContext.d.ts +1 -0
  4. package/account/KcContext.js +2 -0
  5. package/account/classes/component-reference.class.d.ts +6 -0
  6. package/account/classes/component-reference.class.js +3 -0
  7. package/account/containers/template.component.d.ts +26 -0
  8. package/account/containers/template.component.js +66 -0
  9. package/account/directives/kc-class.directive.d.ts +26 -0
  10. package/account/directives/kc-class.directive.js +137 -0
  11. package/account/i18n.d.ts +4 -0
  12. package/account/i18n.js +2 -0
  13. package/account/pages/account/account.component.d.ts +14 -0
  14. package/account/pages/account/account.component.js +39 -0
  15. package/account/pages/applications/applications.component.d.ts +13 -0
  16. package/account/pages/applications/applications.component.js +37 -0
  17. package/account/pages/federatedIdentity/federatedIdentity.component.d.ts +13 -0
  18. package/account/pages/federatedIdentity/federatedIdentity.component.js +36 -0
  19. package/account/pages/log/log.component.d.ts +13 -0
  20. package/account/pages/log/log.component.js +36 -0
  21. package/account/pages/password/password.component.d.ts +28 -0
  22. package/account/pages/password/password.component.js +107 -0
  23. package/account/pages/sessions/sessions.component.d.ts +13 -0
  24. package/account/pages/sessions/sessions.component.js +36 -0
  25. package/account/pages/totp/totp.component.d.ts +13 -0
  26. package/account/pages/totp/totp.component.js +37 -0
  27. package/account/providers/keycloakify-angular.providers.d.ts +15 -0
  28. package/account/providers/keycloakify-angular.providers.js +48 -0
  29. package/account/services/i18n.service.d.ts +6 -0
  30. package/account/services/i18n.service.js +12 -0
  31. package/account/services/resource-injector.service.d.ts +10 -0
  32. package/account/services/resource-injector.service.js +37 -0
  33. package/account/tokens/classes.token.d.ts +16 -0
  34. package/account/tokens/classes.token.js +3 -0
  35. package/account/tokens/i18n.token.d.ts +2 -0
  36. package/account/tokens/i18n.token.js +3 -0
  37. package/account/tokens/kc-context.token.d.ts +3 -0
  38. package/account/tokens/kc-context.token.js +3 -0
  39. package/lib/directives/attributes.directive.d.ts +8 -0
  40. package/lib/directives/attributes.directive.js +26 -0
  41. package/lib/models/script.model.js +1 -1
  42. package/lib/pipes/input-type.pipe.d.ts +7 -0
  43. package/lib/pipes/input-type.pipe.js +20 -0
  44. package/lib/pipes/is-array-with-empty-object.pipe.d.ts +7 -0
  45. package/lib/pipes/is-array-with-empty-object.pipe.js +20 -0
  46. package/lib/pipes/kc-sanitize.pipe.d.ts +9 -0
  47. package/lib/pipes/kc-sanitize.pipe.js +29 -0
  48. package/lib/pipes/to-array.pipe.d.ts +7 -0
  49. package/lib/pipes/to-array.pipe.js +21 -0
  50. package/lib/pipes/to-number.pipe.d.ts +7 -0
  51. package/lib/pipes/to-number.pipe.js +20 -0
  52. package/lib/services/resource-injector.service.d.ts +5 -2
  53. package/lib/services/resource-injector.service.js +19 -22
  54. package/lib/tokens/use-default-css.token.d.ts +2 -0
  55. package/lib/tokens/use-default-css.token.js +3 -0
  56. package/login/DefaultPage.d.ts +28 -28
  57. package/login/DefaultPage.js +74 -74
  58. package/login/KcContext.d.ts +1 -1
  59. package/login/KcContext.js +1 -1
  60. package/login/classes/component-reference.class.d.ts +1 -1
  61. package/login/classes/component-reference.class.js +1 -1
  62. package/login/components/add-remove-buttons-multi-valued-attribute/add-remove-buttons-multi-valued-attribute.component.d.ts +7 -2
  63. package/login/components/add-remove-buttons-multi-valued-attribute/add-remove-buttons-multi-valued-attribute.component.js +19 -36
  64. package/login/components/field-errors/field-errors.component.d.ts +7 -4
  65. package/login/components/field-errors/field-errors.component.js +23 -35
  66. package/login/components/group-label/group-label.component.d.ts +8 -3
  67. package/login/components/group-label/group-label.component.js +29 -41
  68. package/login/components/input-field-by-type/input-field-by-type.component.d.ts +7 -4
  69. package/login/components/input-field-by-type/input-field-by-type.component.js +33 -50
  70. package/login/components/input-tag/input-tag.component.d.ts +9 -4
  71. package/login/components/input-tag/input-tag.component.js +47 -64
  72. package/login/components/input-tag-selects/input-tag-selects.component.d.ts +11 -6
  73. package/login/components/input-tag-selects/input-tag-selects.component.js +41 -56
  74. package/login/components/logout-other-sessions/logout-other-sessions.component.d.ts +7 -2
  75. package/login/components/logout-other-sessions/logout-other-sessions.component.js +25 -36
  76. package/login/components/password-wrapper/password-wrapper.component.d.ts +8 -3
  77. package/login/components/password-wrapper/password-wrapper.component.js +27 -38
  78. package/login/components/select-tag/select-tag.component.d.ts +9 -4
  79. package/login/components/select-tag/select-tag.component.js +32 -47
  80. package/login/components/textarea-tag/textarea-tag.component.d.ts +7 -4
  81. package/login/components/textarea-tag/textarea-tag.component.js +28 -42
  82. package/login/components/user-profile-form-fields/user-profile-form-fields.component.d.ts +11 -5
  83. package/login/components/user-profile-form-fields/user-profile-form-fields.component.js +45 -57
  84. package/login/containers/template.component.d.ts +11 -8
  85. package/login/containers/template.component.js +36 -42
  86. package/login/directives/kc-class.directive.d.ts +5 -2
  87. package/login/directives/kc-class.directive.js +35 -43
  88. package/login/i18n.d.ts +2 -2
  89. package/login/i18n.js +1 -1
  90. package/login/pages/code/code.component.d.ts +8 -3
  91. package/login/pages/code/code.component.js +28 -31
  92. package/login/pages/delete-account-confirm/delete-account-confirm.component.d.ts +8 -3
  93. package/login/pages/delete-account-confirm/delete-account-confirm.component.js +28 -31
  94. package/login/pages/delete-credential/delete-credential.component.d.ts +8 -3
  95. package/login/pages/delete-credential/delete-credential.component.js +28 -31
  96. package/login/pages/error/error.component.d.ts +8 -3
  97. package/login/pages/error/error.component.js +28 -31
  98. package/login/pages/frontchannel-logout/frontchannel-logout.component.d.ts +9 -4
  99. package/login/pages/frontchannel-logout/frontchannel-logout.component.js +28 -31
  100. package/login/pages/idp-review-user-profile/idp-review-user-profile.component.d.ts +13 -3
  101. package/login/pages/idp-review-user-profile/idp-review-user-profile.component.js +40 -41
  102. package/login/pages/info/info.component.d.ts +8 -9
  103. package/login/pages/info/info.component.js +31 -43
  104. package/login/pages/login/login.component.d.ts +8 -3
  105. package/login/pages/login/login.component.js +33 -47
  106. package/login/pages/login-config-totp/login-config-totp.component.d.ts +8 -3
  107. package/login/pages/login-config-totp/login-config-totp.component.js +31 -42
  108. package/login/pages/login-idp-link-confirm/login-idp-link-confirm.component.d.ts +8 -3
  109. package/login/pages/login-idp-link-confirm/login-idp-link-confirm.component.js +28 -31
  110. package/login/pages/login-idp-link-confirm-override/login-idp-link-confirm-override.component.d.ts +8 -3
  111. package/login/pages/login-idp-link-confirm-override/login-idp-link-confirm-override.component.js +28 -31
  112. package/login/pages/login-idp-link-email/login-idp-link-email.component.d.ts +8 -3
  113. package/login/pages/login-idp-link-email/login-idp-link-email.component.js +28 -31
  114. package/login/pages/login-oauth-grant/login-oauth-grant.component.d.ts +8 -3
  115. package/login/pages/login-oauth-grant/login-oauth-grant.component.js +29 -33
  116. package/login/pages/login-oauth2-device-verify-user-code/login-oauth2-device-verify-user-code.component.d.ts +8 -3
  117. package/login/pages/login-oauth2-device-verify-user-code/login-oauth2-device-verify-user-code.component.js +28 -31
  118. package/login/pages/login-otp/login-otp.component.d.ts +8 -3
  119. package/login/pages/login-otp/login-otp.component.js +30 -33
  120. package/login/pages/login-page-expired/login-page-expired.component.d.ts +8 -3
  121. package/login/pages/login-page-expired/login-page-expired.component.js +27 -30
  122. package/login/pages/login-passkeys-conditional-authenticate/login-passkeys-conditional-authenticate.component.d.ts +9 -6
  123. package/login/pages/login-passkeys-conditional-authenticate/login-passkeys-conditional-authenticate.component.js +37 -44
  124. package/login/pages/login-password/login-password.component.d.ts +8 -3
  125. package/login/pages/login-password/login-password.component.js +31 -40
  126. package/login/pages/login-recovery-authn-code-config/login-recovery-authn-code-config.component.d.ts +8 -3
  127. package/login/pages/login-recovery-authn-code-config/login-recovery-authn-code-config.component.js +30 -38
  128. package/login/pages/login-recovery-authn-code-input/login-recovery-authn-code-input.component.d.ts +8 -3
  129. package/login/pages/login-recovery-authn-code-input/login-recovery-authn-code-input.component.js +30 -33
  130. package/login/pages/login-reset-otp/login-reset-otp.component.d.ts +8 -3
  131. package/login/pages/login-reset-otp/login-reset-otp.component.js +29 -32
  132. package/login/pages/login-reset-password/login-reset-password.component.d.ts +8 -3
  133. package/login/pages/login-reset-password/login-reset-password.component.js +30 -33
  134. package/login/pages/login-update-password/login-update-password.component.d.ts +8 -3
  135. package/login/pages/login-update-password/login-update-password.component.js +32 -42
  136. package/login/pages/login-update-profile/login-update-profile.component.d.ts +13 -3
  137. package/login/pages/login-update-profile/login-update-profile.component.js +39 -39
  138. package/login/pages/login-username/login-username.component.d.ts +8 -3
  139. package/login/pages/login-username/login-username.component.js +32 -45
  140. package/login/pages/login-verify-email/login-verify-email.component.d.ts +8 -3
  141. package/login/pages/login-verify-email/login-verify-email.component.js +28 -31
  142. package/login/pages/login-x509-info/login-x509-info.component.d.ts +8 -3
  143. package/login/pages/login-x509-info/login-x509-info.component.js +28 -31
  144. package/login/pages/logout-confirm/logout-confirm.component.d.ts +8 -3
  145. package/login/pages/logout-confirm/logout-confirm.component.js +28 -31
  146. package/login/pages/register/register.component.d.ts +13 -3
  147. package/login/pages/register/register.component.js +41 -48
  148. package/login/pages/saml-post-form/saml-post-form.component.d.ts +9 -4
  149. package/login/pages/saml-post-form/saml-post-form.component.js +32 -35
  150. package/login/pages/select-authenticator/select-authenticator.component.d.ts +8 -3
  151. package/login/pages/select-authenticator/select-authenticator.component.js +29 -39
  152. package/login/pages/terms/terms.component.d.ts +8 -3
  153. package/login/pages/terms/terms.component.js +28 -31
  154. package/login/pages/update-email/update-email.component.d.ts +13 -3
  155. package/login/pages/update-email/update-email.component.js +40 -41
  156. package/login/pages/webauthn-authenticate/webauthn-authenticate.component.d.ts +9 -6
  157. package/login/pages/webauthn-authenticate/webauthn-authenticate.component.js +37 -50
  158. package/login/pages/webauthn-error/webauthn-error.component.d.ts +8 -3
  159. package/login/pages/webauthn-error/webauthn-error.component.js +32 -40
  160. package/login/pages/webauthn-register/webauthn-register.component.d.ts +9 -6
  161. package/login/pages/webauthn-register/webauthn-register.component.js +36 -46
  162. package/login/providers/keycloakify-angular.providers.d.ts +16 -0
  163. package/login/providers/keycloakify-angular.providers.js +53 -0
  164. package/login/services/i18n.service.d.ts +6 -0
  165. package/login/services/i18n.service.js +12 -0
  166. package/login/services/login-resource-injector.service.d.ts +4 -1
  167. package/login/services/login-resource-injector.service.js +22 -25
  168. package/login/services/submit.service.d.ts +9 -0
  169. package/login/services/submit.service.js +20 -0
  170. package/login/services/user-profile-form.service.d.ts +16 -12
  171. package/login/services/user-profile-form.service.js +293 -305
  172. package/{lib/providers/keycloakify-angular.providers.d.ts → login/tokens/classes.token.d.ts} +14 -37
  173. package/login/tokens/classes.token.js +3 -0
  174. package/login/tokens/i18n.token.d.ts +2 -0
  175. package/login/tokens/i18n.token.js +3 -0
  176. package/login/tokens/kc-context.token.d.ts +3 -0
  177. package/login/tokens/kc-context.token.js +3 -0
  178. package/login/tokens/make-user-confirm-password.token.d.ts +2 -0
  179. package/login/tokens/make-user-confirm-password.token.js +3 -0
  180. package/package.json +123 -181
  181. package/src/account/DefaultPage.ts +51 -0
  182. package/src/account/KcContext.ts +1 -0
  183. package/src/account/classes/component-reference.class.ts +6 -0
  184. package/src/account/containers/template.component.html +125 -0
  185. package/src/account/containers/template.component.ts +71 -0
  186. package/src/account/directives/kc-class.directive.ts +150 -0
  187. package/src/account/i18n.ts +4 -0
  188. package/src/account/pages/account/account.component.html +165 -0
  189. package/src/account/pages/account/account.component.ts +34 -0
  190. package/src/account/pages/applications/applications.component.html +156 -0
  191. package/src/account/pages/applications/applications.component.ts +32 -0
  192. package/src/account/pages/federatedIdentity/federatedIdentity.component.html +97 -0
  193. package/src/account/pages/federatedIdentity/federatedIdentity.component.ts +31 -0
  194. package/src/account/pages/log/log.component.html +44 -0
  195. package/src/account/pages/log/log.component.ts +31 -0
  196. package/src/account/pages/password/password.component.html +131 -0
  197. package/src/account/pages/password/password.component.ts +110 -0
  198. package/src/account/pages/sessions/sessions.component.html +63 -0
  199. package/src/account/pages/sessions/sessions.component.ts +31 -0
  200. package/src/account/pages/totp/totp.component.html +258 -0
  201. package/src/account/pages/totp/totp.component.ts +32 -0
  202. package/src/account/providers/keycloakify-angular.providers.ts +64 -0
  203. package/src/account/services/i18n.service.ts +7 -0
  204. package/src/account/services/resource-injector.service.ts +37 -0
  205. package/src/account/tokens/classes.token.ts +6 -0
  206. package/src/account/tokens/i18n.token.ts +3 -0
  207. package/src/account/tokens/kc-context.token.ts +4 -0
  208. package/src/{login → lib}/directives/attributes.directive.ts +2 -2
  209. package/src/{login → lib}/pipes/input-type.pipe.ts +4 -4
  210. package/src/lib/pipes/is-array-with-empty-object.pipe.ts +16 -0
  211. package/src/lib/pipes/kc-sanitize.pipe.ts +34 -0
  212. package/src/lib/pipes/to-array.pipe.ts +15 -0
  213. package/src/lib/pipes/to-number.pipe.ts +13 -0
  214. package/src/lib/services/resource-injector.service.ts +7 -7
  215. package/src/lib/tokens/use-default-css.token.ts +3 -0
  216. package/src/login/DefaultPage.ts +76 -76
  217. package/src/login/KcContext.ts +1 -1
  218. package/src/login/classes/component-reference.class.ts +1 -1
  219. package/src/login/components/add-remove-buttons-multi-valued-attribute/add-remove-buttons-multi-valued-attribute.component.html +19 -19
  220. package/src/login/components/add-remove-buttons-multi-valued-attribute/add-remove-buttons-multi-valued-attribute.component.ts +15 -23
  221. package/src/login/components/field-errors/field-errors.component.html +10 -10
  222. package/src/login/components/field-errors/field-errors.component.ts +11 -16
  223. package/src/login/components/group-label/group-label.component.html +25 -25
  224. package/src/login/components/group-label/group-label.component.ts +17 -21
  225. package/src/login/components/input-field-by-type/input-field-by-type.component.html +57 -57
  226. package/src/login/components/input-field-by-type/input-field-by-type.component.ts +18 -35
  227. package/src/login/components/input-tag/input-tag.component.html +41 -45
  228. package/src/login/components/input-tag/input-tag.component.ts +25 -34
  229. package/src/login/components/input-tag-selects/input-tag-selects.component.html +22 -22
  230. package/src/login/components/input-tag-selects/input-tag-selects.component.ts +32 -43
  231. package/src/login/components/logout-other-sessions/logout-other-sessions.component.html +15 -15
  232. package/src/login/components/logout-other-sessions/logout-other-sessions.component.ts +13 -10
  233. package/src/login/components/password-wrapper/password-wrapper.component.html +13 -13
  234. package/src/login/components/password-wrapper/password-wrapper.component.ts +15 -25
  235. package/src/login/components/select-tag/select-tag.component.html +26 -26
  236. package/src/login/components/select-tag/select-tag.component.ts +23 -35
  237. package/src/login/components/textarea-tag/textarea-tag.component.html +13 -15
  238. package/src/login/components/textarea-tag/textarea-tag.component.ts +16 -25
  239. package/src/login/components/user-profile-form-fields/user-profile-form-fields.component.html +70 -73
  240. package/src/login/components/user-profile-form-fields/user-profile-form-fields.component.ts +33 -47
  241. package/src/login/containers/template.component.html +183 -183
  242. package/src/login/containers/template.component.ts +26 -42
  243. package/src/login/directives/kc-class.directive.ts +11 -11
  244. package/src/login/i18n.ts +2 -2
  245. package/src/login/pages/code/code.component.html +21 -21
  246. package/src/login/pages/code/code.component.ts +17 -17
  247. package/src/login/pages/delete-account-confirm/delete-account-confirm.component.html +44 -42
  248. package/src/login/pages/delete-account-confirm/delete-account-confirm.component.ts +17 -18
  249. package/src/login/pages/delete-credential/delete-credential.component.html +29 -29
  250. package/src/login/pages/delete-credential/delete-credential.component.ts +17 -24
  251. package/src/login/pages/error/error.component.html +20 -20
  252. package/src/login/pages/error/error.component.ts +17 -17
  253. package/src/login/pages/frontchannel-logout/frontchannel-logout.component.html +31 -31
  254. package/src/login/pages/frontchannel-logout/frontchannel-logout.component.ts +17 -25
  255. package/src/login/pages/idp-review-user-profile/idp-review-user-profile.component.html +36 -36
  256. package/src/login/pages/idp-review-user-profile/idp-review-user-profile.component.ts +34 -33
  257. package/src/login/pages/info/info.component.html +45 -45
  258. package/src/login/pages/info/info.component.ts +20 -37
  259. package/src/login/pages/login/login.component.html +194 -194
  260. package/src/login/pages/login/login.component.ts +22 -43
  261. package/src/login/pages/login-config-totp/login-config-totp.component.html +189 -179
  262. package/src/login/pages/login-config-totp/login-config-totp.component.ts +20 -39
  263. package/src/login/pages/login-idp-link-confirm/login-idp-link-confirm.component.html +35 -35
  264. package/src/login/pages/login-idp-link-confirm/login-idp-link-confirm.component.ts +17 -24
  265. package/src/login/pages/login-idp-link-confirm-override/login-idp-link-confirm-override.component.html +34 -34
  266. package/src/login/pages/login-idp-link-confirm-override/login-idp-link-confirm-override.component.ts +17 -26
  267. package/src/login/pages/login-idp-link-email/login-idp-link-email.component.html +32 -30
  268. package/src/login/pages/login-idp-link-email/login-idp-link-email.component.ts +17 -24
  269. package/src/login/pages/login-oauth-grant/login-oauth-grant.component.html +83 -81
  270. package/src/login/pages/login-oauth-grant/login-oauth-grant.component.ts +18 -26
  271. package/src/login/pages/login-oauth2-device-verify-user-code/login-oauth2-device-verify-user-code.component.html +57 -57
  272. package/src/login/pages/login-oauth2-device-verify-user-code/login-oauth2-device-verify-user-code.component.ts +17 -26
  273. package/src/login/pages/login-otp/login-otp.component.html +96 -96
  274. package/src/login/pages/login-otp/login-otp.component.ts +19 -25
  275. package/src/login/pages/login-page-expired/login-page-expired.component.html +31 -31
  276. package/src/login/pages/login-page-expired/login-page-expired.component.ts +16 -23
  277. package/src/login/pages/login-passkeys-conditional-authenticate/login-passkeys-conditional-authenticate.component.html +183 -181
  278. package/src/login/pages/login-passkeys-conditional-authenticate/login-passkeys-conditional-authenticate.component.ts +25 -32
  279. package/src/login/pages/login-password/login-password.component.html +82 -82
  280. package/src/login/pages/login-password/login-password.component.ts +20 -33
  281. package/src/login/pages/login-recovery-authn-code-config/login-recovery-authn-code-config.component.html +142 -142
  282. package/src/login/pages/login-recovery-authn-code-config/login-recovery-authn-code-config.component.ts +19 -34
  283. package/src/login/pages/login-recovery-authn-code-input/login-recovery-authn-code-input.component.html +67 -67
  284. package/src/login/pages/login-recovery-authn-code-input/login-recovery-authn-code-input.component.ts +19 -29
  285. package/src/login/pages/login-reset-otp/login-reset-otp.component.html +61 -59
  286. package/src/login/pages/login-reset-otp/login-reset-otp.component.ts +18 -24
  287. package/src/login/pages/login-reset-password/login-reset-password.component.html +84 -84
  288. package/src/login/pages/login-reset-password/login-reset-password.component.ts +19 -26
  289. package/src/login/pages/login-update-password/login-update-password.component.html +107 -107
  290. package/src/login/pages/login-update-password/login-update-password.component.ts +21 -38
  291. package/src/login/pages/login-update-profile/login-update-profile.component.html +52 -53
  292. package/src/login/pages/login-update-profile/login-update-profile.component.ts +31 -32
  293. package/src/login/pages/login-username/login-username.component.html +146 -146
  294. package/src/login/pages/login-username/login-username.component.ts +21 -38
  295. package/src/login/pages/login-verify-email/login-verify-email.component.html +22 -22
  296. package/src/login/pages/login-verify-email/login-verify-email.component.ts +17 -24
  297. package/src/login/pages/login-x509-info/login-x509-info.component.html +96 -96
  298. package/src/login/pages/login-x509-info/login-x509-info.component.ts +17 -23
  299. package/src/login/pages/logout-confirm/logout-confirm.component.html +51 -51
  300. package/src/login/pages/logout-confirm/logout-confirm.component.ts +17 -23
  301. package/src/login/pages/register/register.component.html +113 -113
  302. package/src/login/pages/register/register.component.ts +33 -39
  303. package/src/login/pages/saml-post-form/saml-post-form.component.html +47 -48
  304. package/src/login/pages/saml-post-form/saml-post-form.component.ts +19 -27
  305. package/src/login/pages/select-authenticator/select-authenticator.component.html +43 -44
  306. package/src/login/pages/select-authenticator/select-authenticator.component.ts +18 -32
  307. package/src/login/pages/terms/terms.component.html +32 -32
  308. package/src/login/pages/terms/terms.component.ts +17 -23
  309. package/src/login/pages/update-email/update-email.component.html +52 -52
  310. package/src/login/pages/update-email/update-email.component.ts +33 -33
  311. package/src/login/pages/webauthn-authenticate/webauthn-authenticate.component.html +146 -148
  312. package/src/login/pages/webauthn-authenticate/webauthn-authenticate.component.ts +26 -50
  313. package/src/login/pages/webauthn-error/webauthn-error.component.html +53 -53
  314. package/src/login/pages/webauthn-error/webauthn-error.component.ts +21 -32
  315. package/src/login/pages/webauthn-register/webauthn-register.component.html +73 -73
  316. package/src/login/pages/webauthn-register/webauthn-register.component.ts +26 -40
  317. package/src/login/providers/keycloakify-angular.providers.ts +68 -0
  318. package/src/login/services/i18n.service.ts +7 -0
  319. package/src/login/services/login-resource-injector.service.ts +13 -12
  320. package/src/login/services/submit.service.ts +12 -0
  321. package/src/login/services/user-profile-form.service.ts +185 -187
  322. package/src/login/tokens/classes.token.ts +6 -0
  323. package/src/login/tokens/i18n.token.ts +3 -0
  324. package/src/login/tokens/kc-context.token.ts +4 -0
  325. package/src/login/tokens/make-user-confirm-password.token.ts +5 -0
  326. package/src/tsconfig.json +6 -1
  327. package/stories/login/pages/login/login.stories.ts +146 -0
  328. package/lib/i18n.d.ts +0 -4
  329. package/lib/i18n.js +0 -6
  330. package/lib/i18n.js.map +0 -1
  331. package/lib/models/index.d.ts +0 -1
  332. package/lib/models/index.js +0 -2
  333. package/lib/models/index.js.map +0 -1
  334. package/lib/models/script.model.js.map +0 -1
  335. package/lib/providers/keycloakify-angular.providers.js +0 -58
  336. package/lib/providers/keycloakify-angular.providers.js.map +0 -1
  337. package/lib/public-api.d.ts +0 -10
  338. package/lib/public-api.js +0 -4
  339. package/lib/public-api.js.map +0 -1
  340. package/lib/services/i18n.service.d.ts +0 -3
  341. package/lib/services/i18n.service.js +0 -14
  342. package/lib/services/i18n.service.js.map +0 -1
  343. package/lib/services/index.d.ts +0 -2
  344. package/lib/services/index.js +0 -3
  345. package/lib/services/index.js.map +0 -1
  346. package/lib/services/resource-injector.service.js.map +0 -1
  347. package/login/DefaultPage.js.map +0 -1
  348. package/login/KcContext.js.map +0 -1
  349. package/login/classes/component-reference.class.js.map +0 -1
  350. package/login/components/add-remove-buttons-multi-valued-attribute/add-remove-buttons-multi-valued-attribute.component.html +0 -24
  351. package/login/components/add-remove-buttons-multi-valued-attribute/add-remove-buttons-multi-valued-attribute.component.js.map +0 -1
  352. package/login/components/field-errors/field-errors.component.html +0 -15
  353. package/login/components/field-errors/field-errors.component.js.map +0 -1
  354. package/login/components/group-label/group-label.component.html +0 -30
  355. package/login/components/group-label/group-label.component.js.map +0 -1
  356. package/login/components/index.d.ts +0 -11
  357. package/login/components/index.js +0 -12
  358. package/login/components/index.js.map +0 -1
  359. package/login/components/input-field-by-type/input-field-by-type.component.html +0 -63
  360. package/login/components/input-field-by-type/input-field-by-type.component.js.map +0 -1
  361. package/login/components/input-tag/input-tag.component.html +0 -49
  362. package/login/components/input-tag/input-tag.component.js.map +0 -1
  363. package/login/components/input-tag-selects/input-tag-selects.component.html +0 -29
  364. package/login/components/input-tag-selects/input-tag-selects.component.js.map +0 -1
  365. package/login/components/logout-other-sessions/logout-other-sessions.component.html +0 -19
  366. package/login/components/logout-other-sessions/logout-other-sessions.component.js.map +0 -1
  367. package/login/components/password-wrapper/password-wrapper.component.html +0 -15
  368. package/login/components/password-wrapper/password-wrapper.component.js.map +0 -1
  369. package/login/components/select-tag/select-tag.component.html +0 -31
  370. package/login/components/select-tag/select-tag.component.js.map +0 -1
  371. package/login/components/textarea-tag/textarea-tag.component.html +0 -18
  372. package/login/components/textarea-tag/textarea-tag.component.js.map +0 -1
  373. package/login/components/user-profile-form-fields/user-profile-form-fields.component.html +0 -85
  374. package/login/components/user-profile-form-fields/user-profile-form-fields.component.js.map +0 -1
  375. package/login/containers/template.component.html +0 -203
  376. package/login/containers/template.component.js.map +0 -1
  377. package/login/directives/attributes.directive.d.ts +0 -5
  378. package/login/directives/attributes.directive.js +0 -34
  379. package/login/directives/attributes.directive.js.map +0 -1
  380. package/login/directives/index.d.ts +0 -2
  381. package/login/directives/index.js +0 -3
  382. package/login/directives/index.js.map +0 -1
  383. package/login/directives/kc-class.directive.js.map +0 -1
  384. package/login/i18n.js.map +0 -1
  385. package/login/pages/code/code.component.html +0 -26
  386. package/login/pages/code/code.component.js.map +0 -1
  387. package/login/pages/delete-account-confirm/delete-account-confirm.component.html +0 -46
  388. package/login/pages/delete-account-confirm/delete-account-confirm.component.js.map +0 -1
  389. package/login/pages/delete-credential/delete-credential.component.html +0 -35
  390. package/login/pages/delete-credential/delete-credential.component.js.map +0 -1
  391. package/login/pages/error/error.component.html +0 -25
  392. package/login/pages/error/error.component.js.map +0 -1
  393. package/login/pages/frontchannel-logout/frontchannel-logout.component.html +0 -35
  394. package/login/pages/frontchannel-logout/frontchannel-logout.component.js.map +0 -1
  395. package/login/pages/idp-review-user-profile/idp-review-user-profile.component.html +0 -41
  396. package/login/pages/idp-review-user-profile/idp-review-user-profile.component.js.map +0 -1
  397. package/login/pages/info/info.component.html +0 -54
  398. package/login/pages/info/info.component.js.map +0 -1
  399. package/login/pages/login/login.component.html +0 -212
  400. package/login/pages/login/login.component.js.map +0 -1
  401. package/login/pages/login-config-totp/login-config-totp.component.html +0 -190
  402. package/login/pages/login-config-totp/login-config-totp.component.js.map +0 -1
  403. package/login/pages/login-idp-link-confirm/login-idp-link-confirm.component.html +0 -41
  404. package/login/pages/login-idp-link-confirm/login-idp-link-confirm.component.js.map +0 -1
  405. package/login/pages/login-idp-link-confirm-override/login-idp-link-confirm-override.component.html +0 -40
  406. package/login/pages/login-idp-link-confirm-override/login-idp-link-confirm-override.component.js.map +0 -1
  407. package/login/pages/login-idp-link-email/login-idp-link-email.component.html +0 -37
  408. package/login/pages/login-idp-link-email/login-idp-link-email.component.js.map +0 -1
  409. package/login/pages/login-oauth-grant/login-oauth-grant.component.html +0 -92
  410. package/login/pages/login-oauth-grant/login-oauth-grant.component.js.map +0 -1
  411. package/login/pages/login-oauth2-device-verify-user-code/login-oauth2-device-verify-user-code.component.html +0 -63
  412. package/login/pages/login-oauth2-device-verify-user-code/login-oauth2-device-verify-user-code.component.js.map +0 -1
  413. package/login/pages/login-otp/login-otp.component.html +0 -103
  414. package/login/pages/login-otp/login-otp.component.js.map +0 -1
  415. package/login/pages/login-page-expired/login-page-expired.component.html +0 -35
  416. package/login/pages/login-page-expired/login-page-expired.component.js.map +0 -1
  417. package/login/pages/login-passkeys-conditional-authenticate/login-passkeys-conditional-authenticate.component.html +0 -203
  418. package/login/pages/login-passkeys-conditional-authenticate/login-passkeys-conditional-authenticate.component.js.map +0 -1
  419. package/login/pages/login-password/login-password.component.html +0 -90
  420. package/login/pages/login-password/login-password.component.js.map +0 -1
  421. package/login/pages/login-recovery-authn-code-config/login-recovery-authn-code-config.component.html +0 -155
  422. package/login/pages/login-recovery-authn-code-config/login-recovery-authn-code-config.component.js.map +0 -1
  423. package/login/pages/login-recovery-authn-code-input/login-recovery-authn-code-input.component.html +0 -76
  424. package/login/pages/login-recovery-authn-code-input/login-recovery-authn-code-input.component.js.map +0 -1
  425. package/login/pages/login-reset-otp/login-reset-otp.component.html +0 -65
  426. package/login/pages/login-reset-otp/login-reset-otp.component.js.map +0 -1
  427. package/login/pages/login-reset-password/login-reset-password.component.html +0 -95
  428. package/login/pages/login-reset-password/login-reset-password.component.js.map +0 -1
  429. package/login/pages/login-update-password/login-update-password.component.html +0 -116
  430. package/login/pages/login-update-password/login-update-password.component.js.map +0 -1
  431. package/login/pages/login-update-profile/login-update-profile.component.html +0 -59
  432. package/login/pages/login-update-profile/login-update-profile.component.js.map +0 -1
  433. package/login/pages/login-username/login-username.component.html +0 -161
  434. package/login/pages/login-username/login-username.component.js.map +0 -1
  435. package/login/pages/login-verify-email/login-verify-email.component.html +0 -27
  436. package/login/pages/login-verify-email/login-verify-email.component.js.map +0 -1
  437. package/login/pages/login-x509-info/login-x509-info.component.html +0 -102
  438. package/login/pages/login-x509-info/login-x509-info.component.js.map +0 -1
  439. package/login/pages/logout-confirm/logout-confirm.component.html +0 -59
  440. package/login/pages/logout-confirm/logout-confirm.component.js.map +0 -1
  441. package/login/pages/register/register.component.html +0 -126
  442. package/login/pages/register/register.component.js.map +0 -1
  443. package/login/pages/saml-post-form/saml-post-form.component.html +0 -51
  444. package/login/pages/saml-post-form/saml-post-form.component.js.map +0 -1
  445. package/login/pages/select-authenticator/select-authenticator.component.html +0 -49
  446. package/login/pages/select-authenticator/select-authenticator.component.js.map +0 -1
  447. package/login/pages/terms/terms.component.html +0 -36
  448. package/login/pages/terms/terms.component.js.map +0 -1
  449. package/login/pages/update-email/update-email.component.html +0 -58
  450. package/login/pages/update-email/update-email.component.js.map +0 -1
  451. package/login/pages/webauthn-authenticate/webauthn-authenticate.component.html +0 -162
  452. package/login/pages/webauthn-authenticate/webauthn-authenticate.component.js.map +0 -1
  453. package/login/pages/webauthn-error/webauthn-error.component.html +0 -60
  454. package/login/pages/webauthn-error/webauthn-error.component.js.map +0 -1
  455. package/login/pages/webauthn-register/webauthn-register.component.html +0 -82
  456. package/login/pages/webauthn-register/webauthn-register.component.js.map +0 -1
  457. package/login/pipes/advanced-msg-str.pipe.d.ts +0 -5
  458. package/login/pipes/advanced-msg-str.pipe.js +0 -31
  459. package/login/pipes/advanced-msg-str.pipe.js.map +0 -1
  460. package/login/pipes/index.d.ts +0 -6
  461. package/login/pipes/index.js +0 -7
  462. package/login/pipes/index.js.map +0 -1
  463. package/login/pipes/input-type.pipe.d.ts +0 -4
  464. package/login/pipes/input-type.pipe.js +0 -23
  465. package/login/pipes/input-type.pipe.js.map +0 -1
  466. package/login/pipes/kc-sanitize.pipe.d.ts +0 -7
  467. package/login/pipes/kc-sanitize.pipe.js +0 -36
  468. package/login/pipes/kc-sanitize.pipe.js.map +0 -1
  469. package/login/pipes/msg-str.pipe.d.ts +0 -6
  470. package/login/pipes/msg-str.pipe.js +0 -31
  471. package/login/pipes/msg-str.pipe.js.map +0 -1
  472. package/login/pipes/to-array.pipe.d.ts +0 -4
  473. package/login/pipes/to-array.pipe.js +0 -24
  474. package/login/pipes/to-array.pipe.js.map +0 -1
  475. package/login/pipes/to-number.pipe.d.ts +0 -4
  476. package/login/pipes/to-number.pipe.js +0 -23
  477. package/login/pipes/to-number.pipe.js.map +0 -1
  478. package/login/services/index.d.ts +0 -2
  479. package/login/services/index.js +0 -3
  480. package/login/services/index.js.map +0 -1
  481. package/login/services/login-resource-injector.service.js.map +0 -1
  482. package/login/services/user-profile-form.service.js.map +0 -1
  483. package/src/lib/i18n.ts +0 -9
  484. package/src/lib/models/index.ts +0 -1
  485. package/src/lib/providers/keycloakify-angular.providers.ts +0 -92
  486. package/src/lib/public-api.ts +0 -12
  487. package/src/lib/services/i18n.service.ts +0 -5
  488. package/src/lib/services/index.ts +0 -2
  489. package/src/login/components/index.ts +0 -11
  490. package/src/login/directives/index.ts +0 -2
  491. package/src/login/pipes/advanced-msg-str.pipe.ts +0 -13
  492. package/src/login/pipes/index.ts +0 -6
  493. package/src/login/pipes/kc-sanitize.pipe.ts +0 -36
  494. package/src/login/pipes/msg-str.pipe.ts +0 -14
  495. package/src/login/pipes/to-array.pipe.ts +0 -15
  496. package/src/login/pipes/to-number.pipe.ts +0 -13
  497. package/src/login/services/index.ts +0 -2
@@ -9,10 +9,10 @@ import {
9
9
  isDevMode,
10
10
  Renderer2,
11
11
  ɵstringify as stringify
12
- } from "@angular/core";
13
- import { ClassKey } from "keycloakify/login/lib/kcClsx";
14
- import { getKcClsx } from "keycloakify/login/lib/kcClsx";
15
- import { ComponentReference } from "../classes/component-reference.class";
12
+ } from '@angular/core';
13
+ import { type ClassKey } from 'keycloakify/login/lib/kcClsx';
14
+ import { getKcClsx } from 'keycloakify/login/lib/kcClsx';
15
+ import { ComponentReference } from '../classes/component-reference.class';
16
16
 
17
17
  interface CssClassState {
18
18
  // PERF: could use a bit mask to represent state as all fields are boolean flags
@@ -35,7 +35,7 @@ type NgClassSupportedTypes =
35
35
  | null
36
36
  | undefined;
37
37
 
38
- @Directive({ selector: "[kcClass]", standalone: true })
38
+ @Directive({ selector: '[kcClass]', standalone: true })
39
39
  export class KcClassDirective implements DoCheck {
40
40
  private initialClasses: string[] = [];
41
41
  private rawClass: NgClassSupportedTypes;
@@ -46,22 +46,22 @@ export class KcClassDirective implements DoCheck {
46
46
  readonly #el = inject(ElementRef);
47
47
  readonly #host = inject(ComponentReference);
48
48
  // eslint-disable-next-line @angular-eslint/no-input-rename
49
- @Input("class")
49
+ @Input('class')
50
50
  set klass(value: string) {
51
51
  this.initialClasses = value != null ? value.trim().split(/\s+/) : [];
52
52
  }
53
53
 
54
54
  // eslint-disable-next-line @angular-eslint/no-input-rename
55
- @Input("ngClass")
55
+ @Input('ngClass')
56
56
  set ngClass(value: string | NgClassSupportedTypes) {
57
- this.rawClass = typeof value === "string" ? value.trim().split(/\s+/) : value;
57
+ this.rawClass = typeof value === 'string' ? value.trim().split(/\s+/) : value;
58
58
  }
59
59
 
60
60
  // eslint-disable-next-line @angular-eslint/no-input-rename
61
- @Input("kcClass")
61
+ @Input('kcClass')
62
62
  set kcClass(value: ClassKey | KcClassSupportedTypes) {
63
63
  this.rawKcClass =
64
- typeof value === "string" ? (value.trim().split(/\s+/) as ClassKey[]) : value;
64
+ typeof value === 'string' ? (value.trim().split(/\s+/) as ClassKey[]) : value;
65
65
  }
66
66
 
67
67
  ngDoCheck(): void {
@@ -146,7 +146,7 @@ export class KcClassDirective implements DoCheck {
146
146
 
147
147
  private _toggleClass(klass: string, enabled: boolean): void {
148
148
  if (isDevMode()) {
149
- if (typeof klass !== "string") {
149
+ if (typeof klass !== 'string') {
150
150
  throw new Error(
151
151
  `NgClass can only toggle CSS classes expressed as strings, got ${stringify(klass)}`
152
152
  );
package/src/login/i18n.ts CHANGED
@@ -1,4 +1,4 @@
1
- import type { GenericI18n_noJsx } from "keycloakify/login/i18n/noJsx/GenericI18n_noJsx";
2
- import { MessageKey as MessageKey_defaultSet } from "keycloakify/login/i18n/messages_defaultSet/types";
1
+ import type { GenericI18n_noJsx } from 'keycloakify/login/i18n/noJsx/GenericI18n_noJsx';
2
+ import { type MessageKey as MessageKey_defaultSet } from 'keycloakify/login/i18n/messages_defaultSet/types';
3
3
  /** INTERNAL: DO NOT IMPORT THIS */
4
4
  export type I18n = GenericI18n_noJsx<MessageKey_defaultSet, string>;
@@ -1,26 +1,26 @@
1
1
  @let code = kcContext.code;
2
2
 
3
3
  <kc-login-template>
4
- <ng-container headerNode>
5
- @if (code.success) {
6
- {{ 'codeSuccessTitle' | msgStr }}
7
- } @else {
8
- {{ 'codeErrorTitle' | msgStr: code.error }}
9
- }
10
- </ng-container>
4
+ <ng-container headerNode>
5
+ @if (code.success) {
6
+ {{ i18n.msgStr('codeSuccessTitle') }}
7
+ } @else {
8
+ {{ i18n.msgStr('codeErrorTitle', code.error) }}
9
+ }
10
+ </ng-container>
11
11
 
12
- <ng-container content>
13
- <div id="kc-code">
14
- @if (code.success) {
15
- <p>{{ 'copyCodeInstruction' | msgStr }}</p>
16
- <input
17
- id="code"
18
- [kcClass]="'kcTextareaClass'"
19
- defaultValue="{{ code.code }}"
20
- />
21
- } @else {
22
- <p id="error">{{ code.error }}</p>
23
- }
24
- </div>
25
- </ng-container>
12
+ <ng-container content>
13
+ <div id="kc-code">
14
+ @if (code.success) {
15
+ <p>{{ i18n.msgStr('copyCodeInstruction') }}</p>
16
+ <input
17
+ id="code"
18
+ [kcClass]="'kcTextareaClass'"
19
+ [defaultValue]="code.code"
20
+ />
21
+ } @else {
22
+ <p id="error">{{ code.error }}</p>
23
+ }
24
+ </div>
25
+ </ng-container>
26
26
  </kc-login-template>
@@ -1,21 +1,20 @@
1
- import { ChangeDetectionStrategy, Component, forwardRef, inject } from "@angular/core";
2
- import {
3
- CLASSES,
4
- KC_CONTEXT,
5
- USE_DEFAULT_CSS
6
- } from "@keycloakify/angular/lib/public-api";
7
- import { ClassKey } from "keycloakify/login/lib/kcClsx";
8
- import { KcContext } from "keycloakify/login/KcContext";
9
- import { ComponentReference } from "@keycloakify/angular/login/classes/component-reference.class";
10
- import { TemplateComponent } from "@keycloakify/angular/login/containers/template.component";
11
- import { KcClassDirective } from "@keycloakify/angular/login/directives/kc-class.directive";
12
- import { MsgStrPipe } from "@keycloakify/angular/login/pipes/msg-str.pipe";
1
+ import { ChangeDetectionStrategy, Component, forwardRef, inject } from '@angular/core';
2
+ import { USE_DEFAULT_CSS } from '@keycloakify/angular/lib/tokens/use-default-css.token';
3
+ import { LOGIN_CLASSES } from '@keycloakify/angular/login/tokens/classes.token';
4
+ import { KC_LOGIN_CONTEXT } from '@keycloakify/angular/login/tokens/kc-context.token';
5
+ import { ComponentReference } from '@keycloakify/angular/login/classes/component-reference.class';
6
+ import { TemplateComponent } from '@keycloakify/angular/login/containers/template.component';
7
+ import { KcClassDirective } from '@keycloakify/angular/login/directives/kc-class.directive';
8
+ import { type ClassKey } from 'keycloakify/login/lib/kcClsx';
9
+ import { type KcContext } from '../../KcContext';
10
+ import { LOGIN_I18N } from '@keycloakify/angular/login/tokens/i18n.token';
11
+ import { type I18n } from '../../i18n';
13
12
 
14
13
  @Component({
15
14
  standalone: true,
16
- imports: [MsgStrPipe, TemplateComponent, KcClassDirective],
17
- selector: "kc-root",
18
- templateUrl: "code.component.html",
15
+ imports: [TemplateComponent, KcClassDirective],
16
+ selector: 'kc-root',
17
+ templateUrl: 'code.component.html',
19
18
  changeDetection: ChangeDetectionStrategy.OnPush,
20
19
  providers: [
21
20
  {
@@ -25,7 +24,8 @@ import { MsgStrPipe } from "@keycloakify/angular/login/pipes/msg-str.pipe";
25
24
  ]
26
25
  })
27
26
  export class CodeComponent extends ComponentReference {
28
- kcContext = inject<Extract<KcContext, { pageId: "code.ftl" }>>(KC_CONTEXT);
27
+ kcContext = inject<Extract<KcContext, { pageId: 'code.ftl' }>>(KC_LOGIN_CONTEXT);
28
+ i18n = inject<I18n>(LOGIN_I18N);
29
29
  override doUseDefaultCss = inject<boolean>(USE_DEFAULT_CSS);
30
- override classes = inject<Partial<Record<ClassKey, string>>>(CLASSES);
30
+ override classes = inject<Partial<Record<ClassKey, string>>>(LOGIN_CLASSES);
31
31
  }
@@ -1,46 +1,48 @@
1
1
  @let url = kcContext.url;
2
2
  @let triggered_from_aia = kcContext.triggered_from_aia;
3
3
  <kc-login-template>
4
- <ng-container headerNode>
5
- {{ 'deleteAccountConfirm' | msgStr }}
6
- </ng-container>
7
- <ng-container content>
8
- <form
9
- [action]="url.loginAction"
10
- method="post"
11
- class="form-actions"
12
- >
13
- <div
14
- class="alert alert-warning"
15
- style="margin-top: 0; margin-bottom: 30px"
16
- >
17
- <span class="pficon pficon-warning-triangle-o"></span>
18
- {{ 'irreversibleAction' | msgStr }}
19
- </div>
20
- <p>{{ 'deletingImplies' | msgStr }}</p>
21
- <ul style="color: #72767b; list-style: disc; list-style-position: inside">
22
- <li>{{ 'loggingOutImmediately' | msgStr }}</li>
23
- <li>{{ 'errasingData' | msgStr }}</li>
24
- </ul>
25
- <p class="delete-account-text">{{ 'finalDeletionConfirmation' | msgStr }}</p>
26
- <div id="kc-form-buttons">
27
- <input
28
- [kcClass]="['kcButtonClass', 'kcButtonPrimaryClass', 'kcButtonLargeClass']"
29
- type="submit"
30
- value="{{ 'doConfirmDelete' | msgStr }}"
31
- />
32
- @if (triggered_from_aia) {
33
- <button
34
- [kcClass]="['kcButtonClass', 'kcButtonDefaultClass', 'kcButtonLargeClass']"
35
- style="margin-left: calc(100% - 220px)"
36
- type="submit"
37
- name="cancel-aia"
38
- value="true"
39
- >
40
- {{ 'doCancel' | msgStr }}
41
- </button>
42
- }
43
- </div>
44
- </form>
45
- </ng-container>
4
+ <ng-container headerNode>
5
+ {{ i18n.msgStr('deleteAccountConfirm') }}
6
+ </ng-container>
7
+ <ng-container content>
8
+ <form
9
+ [action]="url.loginAction"
10
+ method="post"
11
+ class="form-actions"
12
+ >
13
+ <div
14
+ class="alert alert-warning"
15
+ style="margin-top: 0; margin-bottom: 30px"
16
+ >
17
+ <span class="pficon pficon-warning-triangle-o"></span>
18
+ {{ i18n.msgStr('irreversibleAction') }}
19
+ </div>
20
+ <p>{{ i18n.msgStr('deletingImplies') }}</p>
21
+ <ul style="color: #72767b; list-style: disc; list-style-position: inside">
22
+ <li>{{ i18n.msgStr('loggingOutImmediately') }}</li>
23
+ <li>{{ i18n.msgStr('errasingData') }}</li>
24
+ </ul>
25
+ <p class="delete-account-text">
26
+ {{ i18n.msgStr('finalDeletionConfirmation') }}
27
+ </p>
28
+ <div id="kc-form-buttons">
29
+ <input
30
+ [kcClass]="['kcButtonClass', 'kcButtonPrimaryClass', 'kcButtonLargeClass']"
31
+ type="submit"
32
+ [value]="i18n.msgStr('doConfirmDelete')"
33
+ />
34
+ @if (triggered_from_aia) {
35
+ <button
36
+ [kcClass]="['kcButtonClass', 'kcButtonDefaultClass', 'kcButtonLargeClass']"
37
+ style="margin-left: calc(100% - 220px)"
38
+ type="submit"
39
+ name="cancel-aia"
40
+ value="true"
41
+ >
42
+ {{ i18n.msgStr('doCancel') }}
43
+ </button>
44
+ }
45
+ </div>
46
+ </form>
47
+ </ng-container>
46
48
  </kc-login-template>
@@ -1,21 +1,20 @@
1
- import { ChangeDetectionStrategy, Component, forwardRef, inject } from "@angular/core";
2
- import {
3
- CLASSES,
4
- KC_CONTEXT,
5
- USE_DEFAULT_CSS
6
- } from "@keycloakify/angular/lib/public-api";
7
- import { ClassKey } from "keycloakify/login/lib/kcClsx";
8
- import { KcContext } from "keycloakify/login/KcContext";
9
- import { ComponentReference } from "@keycloakify/angular/login/classes/component-reference.class";
10
- import { TemplateComponent } from "@keycloakify/angular/login/containers/template.component";
11
- import { KcClassDirective } from "@keycloakify/angular/login/directives";
12
- import { MsgStrPipe } from "@keycloakify/angular/login/pipes/msg-str.pipe";
1
+ import { ChangeDetectionStrategy, Component, forwardRef, inject } from '@angular/core';
2
+ import { USE_DEFAULT_CSS } from '@keycloakify/angular/lib/tokens/use-default-css.token';
3
+ import { ComponentReference } from '@keycloakify/angular/login/classes/component-reference.class';
4
+ import { TemplateComponent } from '@keycloakify/angular/login/containers/template.component';
5
+ import { KcClassDirective } from '@keycloakify/angular/login/directives/kc-class.directive';
6
+ import { LOGIN_CLASSES } from '@keycloakify/angular/login/tokens/classes.token';
7
+ import { LOGIN_I18N } from '@keycloakify/angular/login/tokens/i18n.token';
8
+ import { KC_LOGIN_CONTEXT } from '@keycloakify/angular/login/tokens/kc-context.token';
9
+ import { type ClassKey } from 'keycloakify/login/lib/kcClsx';
10
+ import { type I18n } from '../../i18n';
11
+ import { type KcContext } from '../../KcContext';
13
12
 
14
13
  @Component({
15
14
  standalone: true,
16
- imports: [TemplateComponent, MsgStrPipe, KcClassDirective],
17
- selector: "kc-root",
18
- templateUrl: "delete-account-confirm.component.html",
15
+ imports: [TemplateComponent, KcClassDirective],
16
+ selector: 'kc-root',
17
+ templateUrl: 'delete-account-confirm.component.html',
19
18
  changeDetection: ChangeDetectionStrategy.OnPush,
20
19
  providers: [
21
20
  {
@@ -25,8 +24,8 @@ import { MsgStrPipe } from "@keycloakify/angular/login/pipes/msg-str.pipe";
25
24
  ]
26
25
  })
27
26
  export class DeleteAccountConfirmComponent extends ComponentReference {
28
- kcContext =
29
- inject<Extract<KcContext, { pageId: "delete-account-confirm.ftl" }>>(KC_CONTEXT);
27
+ kcContext = inject<Extract<KcContext, { pageId: 'delete-account-confirm.ftl' }>>(KC_LOGIN_CONTEXT);
28
+ i18n = inject<I18n>(LOGIN_I18N);
30
29
  override doUseDefaultCss = inject<boolean>(USE_DEFAULT_CSS);
31
- override classes = inject<Partial<Record<ClassKey, string>>>(CLASSES);
30
+ override classes = inject<Partial<Record<ClassKey, string>>>(LOGIN_CLASSES);
32
31
  }
@@ -1,35 +1,35 @@
1
1
  @let url = kcContext.url;
2
2
  @let credentialLabel = kcContext.credentialLabel;
3
3
  <kc-login-template [displayMessage]="displayMessage">
4
- <ng-container headerNode>
5
- {{ 'deleteCredentialTitle' | msgStr: credentialLabel }}
6
- </ng-container>
7
- <ng-container content>
8
- <div id="kc-delete-text">
9
- {{ 'deleteCredentialMessage' | msgStr: credentialLabel }}
10
- </div>
4
+ <ng-container headerNode>
5
+ {{ i18n.msgStr('deleteCredentialTitle', credentialLabel) }}
6
+ </ng-container>
7
+ <ng-container content>
8
+ <div id="kc-delete-text">
9
+ {{ i18n.msgStr('deleteCredentialMessage', credentialLabel) }}
10
+ </div>
11
11
 
12
- <form
13
- class="form-actions"
14
- [action]="url.loginAction"
15
- method="post"
16
- >
17
- <input
18
- [kcClass]="['kcButtonClass', 'kcButtonPrimaryClass', 'kcButtonLargeClass']"
19
- name="accept"
20
- id="kc-accept"
21
- type="submit"
22
- [value]="'doConfirmDelete' | msgStr"
23
- />
12
+ <form
13
+ class="form-actions"
14
+ [action]="url.loginAction"
15
+ method="post"
16
+ >
17
+ <input
18
+ [kcClass]="['kcButtonClass', 'kcButtonPrimaryClass', 'kcButtonLargeClass']"
19
+ name="accept"
20
+ id="kc-accept"
21
+ type="submit"
22
+ [value]="i18n.msgStr('doConfirmDelete')"
23
+ />
24
24
 
25
- <input
26
- [kcClass]="['kcButtonClass', 'kcButtonDefaultClass', 'kcButtonLargeClass']"
27
- name="cancel-aia"
28
- [value]="'doCancel' | msgStr"
29
- id="kc-decline"
30
- type="submit"
31
- />
32
- </form>
33
- <div class="clearfix"></div>
34
- </ng-container>
25
+ <input
26
+ [kcClass]="['kcButtonClass', 'kcButtonDefaultClass', 'kcButtonLargeClass']"
27
+ name="cancel-aia"
28
+ [value]="i18n.msgStr('doCancel')"
29
+ id="kc-decline"
30
+ type="submit"
31
+ />
32
+ </form>
33
+ <div class="clearfix"></div>
34
+ </ng-container>
35
35
  </kc-login-template>
@@ -1,27 +1,20 @@
1
- import {
2
- ChangeDetectionStrategy,
3
- Component,
4
- forwardRef,
5
- inject,
6
- input
7
- } from "@angular/core";
8
- import {
9
- CLASSES,
10
- KC_CONTEXT,
11
- USE_DEFAULT_CSS
12
- } from "@keycloakify/angular/lib/public-api";
13
- import { ClassKey } from "keycloakify/login/lib/kcClsx";
14
- import { KcContext } from "keycloakify/login/KcContext";
15
- import { ComponentReference } from "@keycloakify/angular/login/classes/component-reference.class";
16
- import { TemplateComponent } from "@keycloakify/angular/login/containers/template.component";
17
- import { KcClassDirective } from "@keycloakify/angular/login/directives/kc-class.directive";
18
- import { MsgStrPipe } from "@keycloakify/angular/login/pipes/msg-str.pipe";
1
+ import { ChangeDetectionStrategy, Component, forwardRef, inject, input } from '@angular/core';
2
+ import { USE_DEFAULT_CSS } from '@keycloakify/angular/lib/tokens/use-default-css.token';
3
+ import { ComponentReference } from '@keycloakify/angular/login/classes/component-reference.class';
4
+ import { TemplateComponent } from '@keycloakify/angular/login/containers/template.component';
5
+ import { KcClassDirective } from '@keycloakify/angular/login/directives/kc-class.directive';
6
+ import { LOGIN_CLASSES } from '@keycloakify/angular/login/tokens/classes.token';
7
+ import { LOGIN_I18N } from '@keycloakify/angular/login/tokens/i18n.token';
8
+ import { KC_LOGIN_CONTEXT } from '@keycloakify/angular/login/tokens/kc-context.token';
9
+ import { type ClassKey } from 'keycloakify/login/lib/kcClsx';
10
+ import { type I18n } from '../../i18n';
11
+ import { type KcContext } from '../../KcContext';
19
12
 
20
13
  @Component({
21
14
  standalone: true,
22
- imports: [MsgStrPipe, TemplateComponent, KcClassDirective],
23
- selector: "kc-root",
24
- templateUrl: "delete-credential.component.html",
15
+ imports: [TemplateComponent, KcClassDirective],
16
+ selector: 'kc-root',
17
+ templateUrl: 'delete-credential.component.html',
25
18
  changeDetection: ChangeDetectionStrategy.OnPush,
26
19
  providers: [
27
20
  {
@@ -31,10 +24,10 @@ import { MsgStrPipe } from "@keycloakify/angular/login/pipes/msg-str.pipe";
31
24
  ]
32
25
  })
33
26
  export class DeleteCredentialComponent extends ComponentReference {
34
- kcContext =
35
- inject<Extract<KcContext, { pageId: "delete-credential.ftl" }>>(KC_CONTEXT);
27
+ kcContext = inject<Extract<KcContext, { pageId: 'delete-credential.ftl' }>>(KC_LOGIN_CONTEXT);
28
+ i18n = inject<I18n>(LOGIN_I18N);
36
29
  override doUseDefaultCss = inject<boolean>(USE_DEFAULT_CSS);
37
- override classes = inject<Partial<Record<ClassKey, string>>>(CLASSES);
30
+ override classes = inject<Partial<Record<ClassKey, string>>>(LOGIN_CLASSES);
38
31
  displayRequiredFields = input(false);
39
32
  documentTitle = input<string>();
40
33
  bodyClassName = input<string>();
@@ -2,24 +2,24 @@
2
2
  @let skipLink = kcContext.skipLink;
3
3
  @let client = kcContext.client;
4
4
  <kc-login-template [displayMessage]="false">
5
- <ng-container headerNode>
6
- {{ 'errorTitle' | msgStr }}
7
- </ng-container>
8
- <ng-container content>
9
- <div id="kc-error-message">
10
- <p
11
- class="instruction"
12
- [innerHTML]="message.summary | kcSanitize: 'html'"
13
- ></p>
14
- @if (!skipLink && !!client?.baseUrl) {
15
- <p>
16
- <a
17
- id="backToApplication"
18
- [href]="client.baseUrl"
19
- [innerHTML]="'backToApplication' | msgStr | kcSanitize: 'html'"
20
- ></a>
21
- </p>
22
- }
23
- </div>
24
- </ng-container>
5
+ <ng-container headerNode>
6
+ {{ i18n.msgStr('errorTitle') }}
7
+ </ng-container>
8
+ <ng-container content>
9
+ <div id="kc-error-message">
10
+ <p
11
+ class="instruction"
12
+ [innerHTML]="message.summary | kcSanitize: 'html'"
13
+ ></p>
14
+ @if (!skipLink && !!client?.baseUrl) {
15
+ <p>
16
+ <a
17
+ id="backToApplication"
18
+ [href]="client.baseUrl"
19
+ [innerHTML]="i18n.msgStr('backToApplication') | kcSanitize: 'html'"
20
+ ></a>
21
+ </p>
22
+ }
23
+ </div>
24
+ </ng-container>
25
25
  </kc-login-template>
@@ -1,21 +1,20 @@
1
- import { ChangeDetectionStrategy, Component, forwardRef, inject } from "@angular/core";
2
- import {
3
- CLASSES,
4
- KC_CONTEXT,
5
- USE_DEFAULT_CSS
6
- } from "@keycloakify/angular/lib/public-api";
7
- import { ClassKey } from "keycloakify/login/lib/kcClsx";
8
- import { KcContext } from "keycloakify/login/KcContext";
9
- import { ComponentReference } from "@keycloakify/angular/login/classes/component-reference.class";
10
- import { TemplateComponent } from "@keycloakify/angular/login/containers/template.component";
11
- import { KcSanitizePipe } from "@keycloakify/angular/login/pipes/kc-sanitize.pipe";
12
- import { MsgStrPipe } from "@keycloakify/angular/login/pipes/msg-str.pipe";
1
+ import { ChangeDetectionStrategy, Component, forwardRef, inject } from '@angular/core';
2
+ import { USE_DEFAULT_CSS } from '@keycloakify/angular/lib/tokens/use-default-css.token';
3
+ import { ComponentReference } from '@keycloakify/angular/login/classes/component-reference.class';
4
+ import { TemplateComponent } from '@keycloakify/angular/login/containers/template.component';
5
+ import { KcSanitizePipe } from '@keycloakify/angular/lib/pipes/kc-sanitize.pipe';
6
+ import { LOGIN_I18N } from '@keycloakify/angular/login/tokens/i18n.token';
7
+ import { type I18n } from '../../i18n';
8
+ import { LOGIN_CLASSES } from '@keycloakify/angular/login/tokens/classes.token';
9
+ import { KC_LOGIN_CONTEXT } from '@keycloakify/angular/login/tokens/kc-context.token';
10
+ import { type ClassKey } from 'keycloakify/login/lib/kcClsx';
11
+ import { type KcContext } from '../../KcContext';
13
12
 
14
13
  @Component({
15
14
  standalone: true,
16
- imports: [TemplateComponent, MsgStrPipe, KcSanitizePipe],
17
- selector: "kc-root",
18
- templateUrl: "error.component.html",
15
+ imports: [TemplateComponent, KcSanitizePipe],
16
+ selector: 'kc-root',
17
+ templateUrl: 'error.component.html',
19
18
  changeDetection: ChangeDetectionStrategy.OnPush,
20
19
  providers: [
21
20
  {
@@ -25,7 +24,8 @@ import { MsgStrPipe } from "@keycloakify/angular/login/pipes/msg-str.pipe";
25
24
  ]
26
25
  })
27
26
  export class ErrorComponent extends ComponentReference {
28
- kcContext = inject<Extract<KcContext, { pageId: "error.ftl" }>>(KC_CONTEXT);
27
+ kcContext = inject<Extract<KcContext, { pageId: 'error.ftl' }>>(KC_LOGIN_CONTEXT);
28
+ i18n = inject<I18n>(LOGIN_I18N);
29
29
  override doUseDefaultCss = inject<boolean>(USE_DEFAULT_CSS);
30
- override classes = inject<Partial<Record<ClassKey, string>>>(CLASSES);
30
+ override classes = inject<Partial<Record<ClassKey, string>>>(LOGIN_CLASSES);
31
31
  }
@@ -1,35 +1,35 @@
1
1
  @let logout = kcContext.logout;
2
2
  <kc-login-template
3
- [displayInfo]="displayInfo"
4
- [bodyClassName]="bodyClassName()"
5
- [displayMessage]="displayMessage"
6
- [displayRequiredFields]="displayRequiredFields()"
7
- [documentTitle]="'frontchannel-logout.title' | msgStr"
3
+ [displayInfo]="displayInfo"
4
+ [bodyClassName]="bodyClassName()"
5
+ [displayMessage]="displayMessage"
6
+ [displayRequiredFields]="displayRequiredFields()"
7
+ [documentTitle]="i18n.msgStr('frontchannel-logout.title')"
8
8
  >
9
- <ng-container headerNode>
10
- {{ 'frontchannel-logout.title' | msgStr }}
11
- </ng-container>
12
- <ng-container content>
13
- <p>{{ 'frontchannel-logout.message' | msgStr }}</p>
14
- <ul>
15
- @for (client of logout.clients; track client.name; let idx = $index) {
16
- <li>
17
- {{ client.name }}
18
- <iframe
19
- [src]="'client.frontChannelLogoutUrl' | kcSanitize: 'resourceUrl'"
20
- style="display: none"
21
- ></iframe>
22
- </li>
23
- }
24
- </ul>
25
- @if (logout.logoutRedirectUri) {
26
- <a
27
- id="continue"
28
- class="btn btn-primary"
29
- [href]="logout.logoutRedirectUri"
30
- >
31
- {{ 'doContinue' | msgStr }}
32
- </a>
33
- }
34
- </ng-container>
9
+ <ng-container headerNode>
10
+ {{ i18n.msgStr('frontchannel-logout.title') }}
11
+ </ng-container>
12
+ <ng-container content>
13
+ <p>{{ i18n.msgStr('frontchannel-logout.message') }}</p>
14
+ <ul>
15
+ @for (client of logout.clients; track client.name; let idx = $index) {
16
+ <li>
17
+ {{ client.name }}
18
+ <iframe
19
+ [src]="'client.frontChannelLogoutUrl' | kcSanitize: 'resourceUrl'"
20
+ style="display: none"
21
+ ></iframe>
22
+ </li>
23
+ }
24
+ </ul>
25
+ @if (logout.logoutRedirectUri) {
26
+ <a
27
+ id="continue"
28
+ class="btn btn-primary"
29
+ [href]="logout.logoutRedirectUri"
30
+ >
31
+ {{ i18n.msgStr('doContinue') }}
32
+ </a>
33
+ }
34
+ </ng-container>
35
35
  </kc-login-template>