verben-authentication-ui 1.0.12 → 1.0.13

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 (434) hide show
  1. package/esm2022/lib/components/auth-callback/auth-callback.component.mjs +57 -0
  2. package/esm2022/lib/components/auth-callback/auth-callback.module.mjs +18 -0
  3. package/esm2022/lib/components/button/button.component.mjs +46 -0
  4. package/esm2022/lib/components/button/button.module.mjs +20 -0
  5. package/esm2022/lib/components/forgot-password/ForgotPasswordData.mjs +2 -0
  6. package/esm2022/lib/components/forgot-password/forgot-password.component.mjs +92 -0
  7. package/esm2022/lib/components/forgot-password/forgot-password.module.mjs +34 -0
  8. package/esm2022/lib/components/mail/mail.component.mjs +69 -0
  9. package/esm2022/lib/components/mail/mail.module.mjs +21 -0
  10. package/esm2022/lib/components/mail-validation/mail-validation.component.mjs +108 -0
  11. package/esm2022/lib/components/mail-validation/mail-validation.module.mjs +34 -0
  12. package/esm2022/lib/components/o-auth/o-auth.component.mjs +107 -0
  13. package/esm2022/lib/components/o-auth/o-auth.module.mjs +19 -0
  14. package/esm2022/lib/components/otp-input/otp-input.component.mjs +86 -0
  15. package/esm2022/lib/components/otp-input/otp-input.module.mjs +23 -0
  16. package/esm2022/lib/components/reset-password/ResetPasswordData.mjs +2 -0
  17. package/esm2022/lib/components/reset-password/reset-password.component.mjs +108 -0
  18. package/esm2022/lib/components/reset-password/reset-password.module.mjs +34 -0
  19. package/esm2022/lib/components/role-control/ChildrenType.mjs +6 -0
  20. package/esm2022/lib/components/role-control/MappedRole.mjs +2 -0
  21. package/esm2022/lib/components/role-control/MappedRoleAction.mjs +2 -0
  22. package/esm2022/lib/components/role-control/MappedRoleContext.mjs +2 -0
  23. package/esm2022/lib/components/role-control/UIActions.mjs +7 -0
  24. package/esm2022/lib/components/role-control/UIs.mjs +40 -0
  25. package/esm2022/lib/components/role-control/base-table-style.mjs +53 -0
  26. package/esm2022/lib/components/role-control/role-control.component.mjs +1608 -0
  27. package/esm2022/lib/components/role-control/role-control.module.mjs +18 -0
  28. package/esm2022/lib/components/role-control/role-control.service.mjs +54 -0
  29. package/esm2022/lib/components/sign-in/sign-in.component.mjs +318 -0
  30. package/esm2022/lib/components/sign-in/sign-in.module.mjs +24 -0
  31. package/esm2022/lib/components/sign-up/sign-up.component.mjs +229 -0
  32. package/esm2022/lib/components/sign-up/sign-up.module.mjs +24 -0
  33. package/esm2022/lib/components/sso/base-table-style.mjs +53 -0
  34. package/esm2022/lib/components/sso/helper.mjs +16 -0
  35. package/esm2022/lib/components/sso/sso-form/sso-form.component.mjs +74 -0
  36. package/esm2022/lib/components/sso/sso.columns.mjs +29 -0
  37. package/esm2022/lib/components/sso/sso.component.mjs +236 -0
  38. package/esm2022/lib/components/sso/sso.module.mjs +63 -0
  39. package/esm2022/lib/components/two-factor-auth-otp/two-factor-auth-otp.component.mjs +209 -0
  40. package/esm2022/lib/components/two-factor-auth-otp/two-factor-auth-otp.module.mjs +22 -0
  41. package/esm2022/lib/components/two-factor-auth-setup/two-factor-auth-setup.component.mjs +90 -0
  42. package/esm2022/lib/components/two-factor-auth-setup/two-factor-auth-setup.module.mjs +19 -0
  43. package/esm2022/lib/components/user-management/base-table-style.mjs +53 -0
  44. package/esm2022/lib/components/user-management/services/user-management.service.mjs +88 -0
  45. package/esm2022/lib/components/user-management/user-management-form/use-management-form.component.mjs +73 -0
  46. package/esm2022/lib/components/user-management/user-management.columns.mjs +53 -0
  47. package/esm2022/lib/components/user-management/user-management.component.mjs +536 -0
  48. package/esm2022/lib/components/user-management/user-management.module.mjs +85 -0
  49. package/esm2022/lib/components/user-management/user-status-badge/user-status-badge.component.mjs +26 -0
  50. package/esm2022/lib/components/user-request/user-request.component.mjs +320 -0
  51. package/esm2022/lib/components/user-request/user-request.module.mjs +38 -0
  52. package/esm2022/lib/components/user-request-approval/access-request.columns.mjs +29 -0
  53. package/esm2022/lib/components/user-request-approval/base-table-style.mjs +53 -0
  54. package/esm2022/lib/components/user-request-approval/facades/user-access-request.facade.mjs +260 -0
  55. package/esm2022/lib/components/user-request-approval/helper.mjs +56 -0
  56. package/esm2022/lib/components/user-request-approval/services/user-access-request.service.mjs +93 -0
  57. package/esm2022/lib/components/user-request-approval/states/user-access-request.state.mjs +92 -0
  58. package/esm2022/lib/components/user-request-approval/user-access-request-status-badge/user-access-request-status-badge.component.mjs +26 -0
  59. package/esm2022/lib/components/user-request-approval/user-request-approval.component.mjs +271 -0
  60. package/esm2022/lib/components/user-request-approval/user-request-approval.module.mjs +83 -0
  61. package/esm2022/lib/components/user-request-approval/user-request-form/use-request-form.component.mjs +86 -0
  62. package/esm2022/lib/models/ApplicationRoleAction.mjs +2 -0
  63. package/esm2022/lib/models/ApplicationRoleContext.mjs +2 -0
  64. package/esm2022/lib/models/ErrorResponse.mjs +11 -0
  65. package/esm2022/lib/models/OAuthParam.mjs +2 -0
  66. package/esm2022/lib/models/OAuthType.mjs +9 -0
  67. package/esm2022/lib/models/PagedResult.mjs +2 -0
  68. package/esm2022/lib/models/PasswordRequestParam.mjs +2 -0
  69. package/esm2022/lib/models/PermissionConfig.mjs +2 -0
  70. package/esm2022/lib/models/ResponseKeyValue.mjs +2 -0
  71. package/esm2022/lib/models/Role.mjs +2 -0
  72. package/esm2022/lib/models/RoleAction.mjs +2 -0
  73. package/esm2022/lib/models/RoleContext.mjs +2 -0
  74. package/esm2022/lib/models/SearchDynamicWrapper.mjs +2 -0
  75. package/esm2022/lib/models/SearchOperator.mjs +6 -0
  76. package/esm2022/lib/models/SearchPropertySign.mjs +11 -0
  77. package/esm2022/lib/models/SearchPropertyValue.mjs +2 -0
  78. package/esm2022/lib/models/SearchPropertyValueType.mjs +11 -0
  79. package/esm2022/lib/models/SortDirection.mjs +7 -0
  80. package/esm2022/lib/models/Tag.mjs +2 -0
  81. package/esm2022/lib/models/TenantConfig.mjs +2 -0
  82. package/esm2022/lib/models/UserRequest.mjs +2 -0
  83. package/esm2022/lib/models/auth-mechanism.mjs +8 -0
  84. package/esm2022/lib/models/base.mjs +2 -0
  85. package/esm2022/lib/models/conditions.mjs +13 -0
  86. package/esm2022/lib/models/log-in.mjs +2 -0
  87. package/esm2022/lib/models/mainUser.mjs +2 -0
  88. package/esm2022/lib/models/oauth-resp.mjs +2 -0
  89. package/esm2022/lib/models/oauth-response.mjs +2 -0
  90. package/esm2022/lib/models/object-state.mjs +8 -0
  91. package/esm2022/lib/models/otpValue.mjs +2 -0
  92. package/esm2022/lib/models/paged.mjs +2 -0
  93. package/esm2022/lib/models/query-params.mjs +2 -0
  94. package/esm2022/lib/models/request-status.mjs +5 -0
  95. package/esm2022/lib/models/resend-otp-data.mjs +2 -0
  96. package/esm2022/lib/models/sign-up.mjs +2 -0
  97. package/esm2022/lib/models/single-sign-on.mjs +2 -0
  98. package/esm2022/lib/models/status.mjs +6 -0
  99. package/esm2022/lib/models/user-access-request-status.mjs +7 -0
  100. package/esm2022/lib/models/user-access-request.mjs +2 -0
  101. package/esm2022/lib/models/user.mjs +2 -0
  102. package/esm2022/lib/pipes/async-label.pipe.mjs +25 -0
  103. package/esm2022/lib/services/authorization.service.mjs +26 -0
  104. package/esm2022/lib/services/encryption.service.mjs +52 -0
  105. package/esm2022/lib/services/environment.service.mjs +26 -0
  106. package/esm2022/lib/services/http-web-request.service.mjs +85 -0
  107. package/esm2022/lib/services/label.service.mjs +134 -0
  108. package/esm2022/lib/services/util.service.mjs +55 -0
  109. package/esm2022/lib/shared/shared.module.mjs +84 -0
  110. package/esm2022/public-api.mjs +48 -0
  111. package/esm2022/verben-authentication-ui.mjs +5 -0
  112. package/fesm2022/verben-authentication-ui.mjs +6622 -0
  113. package/fesm2022/verben-authentication-ui.mjs.map +1 -0
  114. package/index.d.ts +5 -0
  115. package/lib/components/auth-callback/auth-callback.component.d.ts +17 -0
  116. package/lib/components/auth-callback/auth-callback.module.d.ts +8 -0
  117. package/lib/components/button/button.component.d.ts +17 -0
  118. package/lib/components/button/button.module.d.ts +10 -0
  119. package/{src/lib/components/forgot-password/ForgotPasswordData.ts → lib/components/forgot-password/ForgotPasswordData.d.ts} +1 -1
  120. package/lib/components/forgot-password/forgot-password.component.d.ts +30 -0
  121. package/lib/components/forgot-password/forgot-password.module.d.ts +10 -0
  122. package/lib/components/mail/mail.component.d.ts +32 -0
  123. package/lib/components/mail/mail.module.d.ts +11 -0
  124. package/lib/components/mail-validation/mail-validation.component.d.ts +42 -0
  125. package/lib/components/mail-validation/mail-validation.module.d.ts +10 -0
  126. package/lib/components/o-auth/o-auth.component.d.ts +30 -0
  127. package/lib/components/o-auth/o-auth.module.d.ts +9 -0
  128. package/lib/components/otp-input/otp-input.component.d.ts +21 -0
  129. package/lib/components/otp-input/otp-input.module.d.ts +13 -0
  130. package/lib/components/reset-password/ResetPasswordData.d.ts +5 -0
  131. package/lib/components/reset-password/reset-password.component.d.ts +30 -0
  132. package/lib/components/reset-password/reset-password.module.d.ts +10 -0
  133. package/lib/components/role-control/ChildrenType.d.ts +4 -0
  134. package/{src/lib/components/role-control/MappedRole.ts → lib/components/role-control/MappedRole.d.ts} +2 -3
  135. package/{src/lib/components/role-control/MappedRoleAction.ts → lib/components/role-control/MappedRoleAction.d.ts} +1 -2
  136. package/{src/lib/components/role-control/MappedRoleContext.ts → lib/components/role-control/MappedRoleContext.d.ts} +3 -4
  137. package/lib/components/role-control/UIActions.d.ts +5 -0
  138. package/lib/components/role-control/UIs.d.ts +38 -0
  139. package/lib/components/role-control/base-table-style.d.ts +1 -0
  140. package/lib/components/role-control/role-control.component.d.ts +131 -0
  141. package/lib/components/role-control/role-control.module.d.ts +8 -0
  142. package/lib/components/role-control/role-control.service.d.ts +9 -0
  143. package/lib/components/sign-in/sign-in.component.d.ts +95 -0
  144. package/lib/components/sign-in/sign-in.module.d.ts +13 -0
  145. package/lib/components/sign-up/sign-up.component.d.ts +68 -0
  146. package/lib/components/sign-up/sign-up.module.d.ts +13 -0
  147. package/lib/components/sso/base-table-style.d.ts +1 -0
  148. package/lib/components/sso/helper.d.ts +2 -0
  149. package/lib/components/sso/sso-form/sso-form.component.d.ts +21 -0
  150. package/lib/components/sso/sso.columns.d.ts +3 -0
  151. package/lib/components/sso/sso.component.d.ts +54 -0
  152. package/lib/components/sso/sso.module.d.ts +11 -0
  153. package/lib/components/two-factor-auth-otp/two-factor-auth-otp.component.d.ts +67 -0
  154. package/lib/components/two-factor-auth-otp/two-factor-auth-otp.module.d.ts +12 -0
  155. package/lib/components/two-factor-auth-setup/two-factor-auth-setup.component.d.ts +39 -0
  156. package/lib/components/two-factor-auth-setup/two-factor-auth-setup.module.d.ts +9 -0
  157. package/lib/components/user-management/base-table-style.d.ts +1 -0
  158. package/lib/components/user-management/services/user-management.service.d.ts +44 -0
  159. package/lib/components/user-management/user-management-form/use-management-form.component.d.ts +24 -0
  160. package/lib/components/user-management/user-management.columns.d.ts +3 -0
  161. package/lib/components/user-management/user-management.component.d.ts +134 -0
  162. package/lib/components/user-management/user-management.module.d.ts +14 -0
  163. package/lib/components/user-management/user-status-badge/user-status-badge.component.d.ts +12 -0
  164. package/lib/components/user-request/user-request.component.d.ts +80 -0
  165. package/lib/components/user-request/user-request.module.d.ts +11 -0
  166. package/lib/components/user-request-approval/access-request.columns.d.ts +3 -0
  167. package/lib/components/user-request-approval/base-table-style.d.ts +1 -0
  168. package/lib/components/user-request-approval/facades/user-access-request.facade.d.ts +39 -0
  169. package/lib/components/user-request-approval/helper.d.ts +7 -0
  170. package/lib/components/user-request-approval/services/user-access-request.service.d.ts +65 -0
  171. package/lib/components/user-request-approval/states/user-access-request.state.d.ts +35 -0
  172. package/lib/components/user-request-approval/user-access-request-status-badge/user-access-request-status-badge.component.d.ts +12 -0
  173. package/lib/components/user-request-approval/user-request-approval.component.d.ts +69 -0
  174. package/lib/components/user-request-approval/user-request-approval.module.d.ts +12 -0
  175. package/lib/components/user-request-approval/user-request-form/use-request-form.component.d.ts +25 -0
  176. package/lib/models/ApplicationRoleAction.d.ts +9 -0
  177. package/{src/lib/models/ApplicationRoleContext copy.ts → lib/models/ApplicationRoleContext.d.ts} +5 -6
  178. package/lib/models/ErrorResponse.d.ts +6 -0
  179. package/lib/models/OAuthParam.d.ts +9 -0
  180. package/lib/models/OAuthType.d.ts +7 -0
  181. package/lib/models/PagedResult.d.ts +9 -0
  182. package/lib/models/PasswordRequestParam.d.ts +5 -0
  183. package/{src/lib/models/PermissionConfig.ts → lib/models/PermissionConfig.d.ts} +3 -4
  184. package/lib/models/ResponseKeyValue.d.ts +5 -0
  185. package/{src/lib/models/Role.ts → lib/models/Role.d.ts} +5 -6
  186. package/lib/models/RoleAction.d.ts +10 -0
  187. package/lib/models/RoleContext.d.ts +10 -0
  188. package/{src/lib/models/SearchDynamicWrapper.ts → lib/models/SearchDynamicWrapper.d.ts} +2 -3
  189. package/lib/models/SearchOperator.d.ts +4 -0
  190. package/lib/models/SearchPropertySign.d.ts +9 -0
  191. package/{src/lib/models/SearchPropertyValue.ts → lib/models/SearchPropertyValue.d.ts} +6 -7
  192. package/lib/models/SearchPropertyValueType.d.ts +9 -0
  193. package/lib/models/SortDirection.d.ts +5 -0
  194. package/{src/lib/models/Tag.ts → lib/models/Tag.d.ts} +3 -4
  195. package/lib/models/TenantConfig.d.ts +18 -0
  196. package/lib/models/UserRequest.d.ts +32 -0
  197. package/lib/models/auth-mechanism.d.ts +14 -0
  198. package/lib/models/base.d.ts +12 -0
  199. package/lib/models/conditions.d.ts +11 -0
  200. package/lib/models/log-in.d.ts +8 -0
  201. package/{src/lib/models/mainUser.ts → lib/models/mainUser.d.ts} +2 -3
  202. package/lib/models/oauth-resp.d.ts +6 -0
  203. package/{src/lib/models/oauth-response.ts → lib/models/oauth-response.d.ts} +1 -1
  204. package/lib/models/object-state.d.ts +6 -0
  205. package/{src/lib/models/otpValue.ts → lib/models/otpValue.d.ts} +2 -4
  206. package/lib/models/paged.d.ts +9 -0
  207. package/lib/models/query-params.d.ts +8 -0
  208. package/lib/models/request-status.d.ts +3 -0
  209. package/lib/models/resend-otp-data.d.ts +8 -0
  210. package/lib/models/sign-up.d.ts +9 -0
  211. package/lib/models/single-sign-on.d.ts +7 -0
  212. package/lib/models/status.d.ts +4 -0
  213. package/lib/models/user-access-request-status.d.ts +5 -0
  214. package/{src/lib/models/user-access-request.ts → lib/models/user-access-request.d.ts} +4 -5
  215. package/lib/models/user.d.ts +18 -0
  216. package/lib/pipes/async-label.pipe.d.ts +11 -0
  217. package/lib/services/authorization.service.d.ts +14 -0
  218. package/lib/services/encryption.service.d.ts +13 -0
  219. package/lib/services/environment.service.d.ts +22 -0
  220. package/lib/services/http-web-request.service.d.ts +23 -0
  221. package/lib/services/label.service.d.ts +15 -0
  222. package/lib/services/util.service.d.ts +11 -0
  223. package/lib/shared/shared.module.d.ts +10 -0
  224. package/package.json +14 -10
  225. package/{src/public-api.ts → public-api.d.ts} +0 -24
  226. package/ng-package.json +0 -8
  227. package/src/lib/base/base-data.component.ts +0 -86
  228. package/src/lib/base/base-data.facade.ts +0 -157
  229. package/src/lib/base/base-data.service.ts +0 -49
  230. package/src/lib/base/base-data.state.ts +0 -94
  231. package/src/lib/base/models.ts +0 -14
  232. package/src/lib/components/auth-callback/auth-callback.component.css +0 -30
  233. package/src/lib/components/auth-callback/auth-callback.component.html +0 -6
  234. package/src/lib/components/auth-callback/auth-callback.component.spec.ts +0 -23
  235. package/src/lib/components/auth-callback/auth-callback.component.ts +0 -56
  236. package/src/lib/components/auth-callback/auth-callback.module.ts +0 -10
  237. package/src/lib/components/button/button.component.css +0 -3
  238. package/src/lib/components/button/button.component.html +0 -13
  239. package/src/lib/components/button/button.component.spec.ts +0 -23
  240. package/src/lib/components/button/button.component.ts +0 -24
  241. package/src/lib/components/button/button.module.ts +0 -11
  242. package/src/lib/components/forgot-password/forgot-password.component.css +0 -50
  243. package/src/lib/components/forgot-password/forgot-password.component.html +0 -38
  244. package/src/lib/components/forgot-password/forgot-password.component.spec.ts +0 -23
  245. package/src/lib/components/forgot-password/forgot-password.component.ts +0 -90
  246. package/src/lib/components/forgot-password/forgot-password.module.ts +0 -18
  247. package/src/lib/components/mail/mail.component.css +0 -0
  248. package/src/lib/components/mail/mail.component.html +0 -11
  249. package/src/lib/components/mail/mail.component.spec.ts +0 -23
  250. package/src/lib/components/mail/mail.component.ts +0 -47
  251. package/src/lib/components/mail/mail.module.ts +0 -13
  252. package/src/lib/components/mail-validation/mail-validation.component.css +0 -59
  253. package/src/lib/components/mail-validation/mail-validation.component.html +0 -37
  254. package/src/lib/components/mail-validation/mail-validation.component.spec.ts +0 -23
  255. package/src/lib/components/mail-validation/mail-validation.component.ts +0 -66
  256. package/src/lib/components/mail-validation/mail-validation.module.ts +0 -18
  257. package/src/lib/components/o-auth/o-auth.component.css +0 -26
  258. package/src/lib/components/o-auth/o-auth.component.html +0 -26
  259. package/src/lib/components/o-auth/o-auth.component.spec.ts +0 -23
  260. package/src/lib/components/o-auth/o-auth.component.ts +0 -115
  261. package/src/lib/components/o-auth/o-auth.module.ts +0 -11
  262. package/src/lib/components/otp-input/otp-input.component.css +0 -19
  263. package/src/lib/components/otp-input/otp-input.component.html +0 -15
  264. package/src/lib/components/otp-input/otp-input.component.spec.ts +0 -23
  265. package/src/lib/components/otp-input/otp-input.component.ts +0 -88
  266. package/src/lib/components/otp-input/otp-input.module.ts +0 -15
  267. package/src/lib/components/reset-password/ResetPasswordData.ts +0 -5
  268. package/src/lib/components/reset-password/reset-password.component.css +0 -29
  269. package/src/lib/components/reset-password/reset-password.component.html +0 -24
  270. package/src/lib/components/reset-password/reset-password.component.spec.ts +0 -23
  271. package/src/lib/components/reset-password/reset-password.component.ts +0 -108
  272. package/src/lib/components/reset-password/reset-password.module.ts +0 -18
  273. package/src/lib/components/role-control/ChildrenType.ts +0 -4
  274. package/src/lib/components/role-control/UIActions.ts +0 -5
  275. package/src/lib/components/role-control/UIs.ts +0 -38
  276. package/src/lib/components/role-control/base-table-style.ts +0 -52
  277. package/src/lib/components/role-control/role-control.component.css +0 -87
  278. package/src/lib/components/role-control/role-control.component.html +0 -603
  279. package/src/lib/components/role-control/role-control.component.spec.ts +0 -23
  280. package/src/lib/components/role-control/role-control.component.ts +0 -1884
  281. package/src/lib/components/role-control/role-control.module.ts +0 -10
  282. package/src/lib/components/role-control/role-control.service.spec.ts +0 -16
  283. package/src/lib/components/role-control/role-control.service.ts +0 -53
  284. package/src/lib/components/sign-in/sign-in.component.css +0 -21
  285. package/src/lib/components/sign-in/sign-in.component.html +0 -83
  286. package/src/lib/components/sign-in/sign-in.component.spec.ts +0 -23
  287. package/src/lib/components/sign-in/sign-in.component.ts +0 -267
  288. package/src/lib/components/sign-in/sign-in.module.ts +0 -17
  289. package/src/lib/components/sign-up/sign-up.component.css +0 -36
  290. package/src/lib/components/sign-up/sign-up.component.html +0 -132
  291. package/src/lib/components/sign-up/sign-up.component.spec.ts +0 -23
  292. package/src/lib/components/sign-up/sign-up.component.ts +0 -180
  293. package/src/lib/components/sign-up/sign-up.module.ts +0 -15
  294. package/src/lib/components/sso/base-table-style.ts +0 -52
  295. package/src/lib/components/sso/helper.ts +0 -17
  296. package/src/lib/components/sso/sso-form/sso-form.component.css +0 -13
  297. package/src/lib/components/sso/sso-form/sso-form.component.html +0 -109
  298. package/src/lib/components/sso/sso-form/sso-form.component.spec.ts +0 -23
  299. package/src/lib/components/sso/sso-form/sso-form.component.ts +0 -70
  300. package/src/lib/components/sso/sso.columns.ts +0 -32
  301. package/src/lib/components/sso/sso.component.css +0 -47
  302. package/src/lib/components/sso/sso.component.html +0 -208
  303. package/src/lib/components/sso/sso.component.spec.ts +0 -23
  304. package/src/lib/components/sso/sso.component.ts +0 -261
  305. package/src/lib/components/sso/sso.module.ts +0 -40
  306. package/src/lib/components/two-factor-auth-otp/two-factor-auth-otp.component.css +0 -8
  307. package/src/lib/components/two-factor-auth-otp/two-factor-auth-otp.component.html +0 -30
  308. package/src/lib/components/two-factor-auth-otp/two-factor-auth-otp.component.spec.ts +0 -23
  309. package/src/lib/components/two-factor-auth-otp/two-factor-auth-otp.component.ts +0 -155
  310. package/src/lib/components/two-factor-auth-otp/two-factor-auth-otp.module.ts +0 -15
  311. package/src/lib/components/two-factor-auth-setup/two-factor-auth-setup.component.css +0 -17
  312. package/src/lib/components/two-factor-auth-setup/two-factor-auth-setup.component.html +0 -45
  313. package/src/lib/components/two-factor-auth-setup/two-factor-auth-setup.component.spec.ts +0 -23
  314. package/src/lib/components/two-factor-auth-setup/two-factor-auth-setup.component.ts +0 -57
  315. package/src/lib/components/two-factor-auth-setup/two-factor-auth-setup.module.ts +0 -11
  316. package/src/lib/components/user-management/base-table-style.ts +0 -52
  317. package/src/lib/components/user-management/facades/user-management.facades.ts +0 -133
  318. package/src/lib/components/user-management/helper.ts +0 -38
  319. package/src/lib/components/user-management/index.ts +0 -4
  320. package/src/lib/components/user-management/services/user-management.service.spec.ts +0 -16
  321. package/src/lib/components/user-management/services/user-management.service.ts +0 -111
  322. package/src/lib/components/user-management/states/user-management.state.ts +0 -65
  323. package/src/lib/components/user-management/user-management-form/use-management-form.component.ts +0 -74
  324. package/src/lib/components/user-management/user-management-form/user-management-form.component.css +0 -0
  325. package/src/lib/components/user-management/user-management-form/user-management-form.component.html +0 -89
  326. package/src/lib/components/user-management/user-management-form/user-management-form.component.spec.ts +0 -23
  327. package/src/lib/components/user-management/user-management.columns.ts +0 -57
  328. package/src/lib/components/user-management/user-management.component.css +0 -31
  329. package/src/lib/components/user-management/user-management.component.html +0 -455
  330. package/src/lib/components/user-management/user-management.component.spec.ts +0 -23
  331. package/src/lib/components/user-management/user-management.component.ts +0 -626
  332. package/src/lib/components/user-management/user-management.module.ts +0 -60
  333. package/src/lib/components/user-management/user-status-badge/user-status-badge.component.css +0 -0
  334. package/src/lib/components/user-management/user-status-badge/user-status-badge.component.html +0 -8
  335. package/src/lib/components/user-management/user-status-badge/user-status-badge.component.spec.ts +0 -22
  336. package/src/lib/components/user-management/user-status-badge/user-status-badge.component.ts +0 -22
  337. package/src/lib/components/user-request/user-request.component.css +0 -91
  338. package/src/lib/components/user-request/user-request.component.html +0 -137
  339. package/src/lib/components/user-request/user-request.component.spec.ts +0 -23
  340. package/src/lib/components/user-request/user-request.component.ts +0 -306
  341. package/src/lib/components/user-request/user-request.module.ts +0 -20
  342. package/src/lib/components/user-request-approval/access-request.columns.ts +0 -31
  343. package/src/lib/components/user-request-approval/base-table-style.ts +0 -52
  344. package/src/lib/components/user-request-approval/facades/user-access-request.facade.ts +0 -324
  345. package/src/lib/components/user-request-approval/helper.ts +0 -61
  346. package/src/lib/components/user-request-approval/services/user-access-request.service.spec.ts +0 -16
  347. package/src/lib/components/user-request-approval/services/user-access-request.service.ts +0 -122
  348. package/src/lib/components/user-request-approval/states/user-access-request.state.ts +0 -109
  349. package/src/lib/components/user-request-approval/user-access-request-status-badge/user-access-request-status-badge.component.css +0 -0
  350. package/src/lib/components/user-request-approval/user-access-request-status-badge/user-access-request-status-badge.component.html +0 -8
  351. package/src/lib/components/user-request-approval/user-access-request-status-badge/user-access-request-status-badge.component.spec.ts +0 -23
  352. package/src/lib/components/user-request-approval/user-access-request-status-badge/user-access-request-status-badge.component.ts +0 -22
  353. package/src/lib/components/user-request-approval/user-request-approval.component.css +0 -6
  354. package/src/lib/components/user-request-approval/user-request-approval.component.html +0 -273
  355. package/src/lib/components/user-request-approval/user-request-approval.component.spec.ts +0 -23
  356. package/src/lib/components/user-request-approval/user-request-approval.component.ts +0 -328
  357. package/src/lib/components/user-request-approval/user-request-approval.module.ts +0 -56
  358. package/src/lib/components/user-request-approval/user-request-form/use-request-form.component.ts +0 -98
  359. package/src/lib/components/user-request-approval/user-request-form/user-request-form.component.css +0 -0
  360. package/src/lib/components/user-request-approval/user-request-form/user-request-form.component.html +0 -94
  361. package/src/lib/components/user-request-approval/user-request-form/user-request-form.component.spec.ts +0 -23
  362. package/src/lib/components/user-request-process/user-request-process.component.css +0 -0
  363. package/src/lib/components/user-request-process/user-request-process.component.html +0 -1
  364. package/src/lib/components/user-request-process/user-request-process.component.spec.ts +0 -23
  365. package/src/lib/components/user-request-process/user-request-process.component.ts +0 -12
  366. package/src/lib/components/user-request-process/user-request-process.module.ts +0 -12
  367. package/src/lib/models/ApplicationRoleAction.ts +0 -10
  368. package/src/lib/models/ApplicationRoleContext.ts +0 -10
  369. package/src/lib/models/ErrorResponse.ts +0 -7
  370. package/src/lib/models/FilterTypes.ts +0 -8
  371. package/src/lib/models/MailConfig.ts +0 -13
  372. package/src/lib/models/MessageConfig.ts +0 -5
  373. package/src/lib/models/MessageMedium.ts +0 -4
  374. package/src/lib/models/OAuthParam.ts +0 -10
  375. package/src/lib/models/OAuthType.ts +0 -7
  376. package/src/lib/models/PagedResult.ts +0 -9
  377. package/src/lib/models/PasswordRequestParam.ts +0 -5
  378. package/src/lib/models/PeriodMode.ts +0 -10
  379. package/src/lib/models/ReportSchedule.ts +0 -23
  380. package/src/lib/models/ReportType.ts +0 -5
  381. package/src/lib/models/ResponseKeyValue.ts +0 -5
  382. package/src/lib/models/RoleAction.ts +0 -11
  383. package/src/lib/models/RoleContext.ts +0 -11
  384. package/src/lib/models/SMSConfig.ts +0 -11
  385. package/src/lib/models/SearchOperator.ts +0 -4
  386. package/src/lib/models/SearchPropertySign.ts +0 -9
  387. package/src/lib/models/SearchPropertyValueType.ts +0 -9
  388. package/src/lib/models/SortDirection.ts +0 -5
  389. package/src/lib/models/TaskNotification.ts +0 -14
  390. package/src/lib/models/TaskNotificationMessageType.ts +0 -4
  391. package/src/lib/models/TaskNotificationType.ts +0 -4
  392. package/src/lib/models/Tenant.ts +0 -22
  393. package/src/lib/models/TenantConfig.ts +0 -19
  394. package/src/lib/models/UserRequest.ts +0 -38
  395. package/src/lib/models/auth-mechanism.ts +0 -15
  396. package/src/lib/models/base.ts +0 -13
  397. package/src/lib/models/conditions.ts +0 -11
  398. package/src/lib/models/log-in.ts +0 -8
  399. package/src/lib/models/oauth-resp.ts +0 -6
  400. package/src/lib/models/object-state.ts +0 -6
  401. package/src/lib/models/paged.ts +0 -9
  402. package/src/lib/models/query-params.ts +0 -9
  403. package/src/lib/models/request-status.ts +0 -4
  404. package/src/lib/models/resend-otp-data.ts +0 -8
  405. package/src/lib/models/resource.ts +0 -27
  406. package/src/lib/models/sign-up.ts +0 -11
  407. package/src/lib/models/single-sign-on.ts +0 -9
  408. package/src/lib/models/status.ts +0 -5
  409. package/src/lib/models/user-access-request-status.ts +0 -5
  410. package/src/lib/models/user-object-state.ts +0 -6
  411. package/src/lib/models/user.ts +0 -19
  412. package/src/lib/pipes/async-label.pipe.spec.ts +0 -8
  413. package/src/lib/pipes/async-label.pipe.ts +0 -20
  414. package/src/lib/services/authorization.service.spec.ts +0 -16
  415. package/src/lib/services/authorization.service.ts +0 -24
  416. package/src/lib/services/encryption.service.ts +0 -57
  417. package/src/lib/services/environment.service.spec.ts +0 -16
  418. package/src/lib/services/environment.service.ts +0 -30
  419. package/src/lib/services/http-web-request.service.spec.ts +0 -16
  420. package/src/lib/services/http-web-request.service.ts +0 -114
  421. package/src/lib/services/label.service.spec.ts +0 -16
  422. package/src/lib/services/label.service.ts +0 -177
  423. package/src/lib/services/util.service.spec.ts +0 -16
  424. package/src/lib/services/util.service.ts +0 -49
  425. package/src/lib/shared/shared.module.ts +0 -55
  426. package/src/styles.css +0 -96
  427. package/src/theme/tailwind-setup.css +0 -3
  428. package/src/theme/tailwind.css +0 -1035
  429. package/src/utils/components/base-data-view.component.ts +0 -131
  430. package/src/utils/models/DataViewConfig.ts +0 -19
  431. package/tailwind.config.js +0 -20
  432. package/tsconfig.lib.json +0 -15
  433. package/tsconfig.lib.prod.json +0 -11
  434. package/tsconfig.spec.json +0 -15
@@ -1,90 +0,0 @@
1
- import { Component, EventEmitter, Input, Output } from '@angular/core';
2
- import {
3
- AbstractControl,
4
- FormBuilder,
5
- FormControl,
6
- FormGroup,
7
- ValidationErrors,
8
- Validators,
9
- } from '@angular/forms';
10
- import { ForgotPasswordData } from './ForgotPasswordData';
11
- import { HttpWebRequestService } from '../../services/http-web-request.service';
12
- import { ErrorResponse } from '../../models/ErrorResponse';
13
- import { ResponseKeyValue } from '../../models/ResponseKeyValue';
14
- import { UtilService } from '../../services/util.service';
15
- import { EnvironmentService } from '../../services/environment.service';
16
-
17
- @Component({
18
- selector: 'verben-forgot-password',
19
- templateUrl: './forgot-password.component.html',
20
- styleUrl: './forgot-password.component.css',
21
- })
22
- export class ForgotPasswordComponent {
23
- @Input() title: string = 'Forgot Password';
24
- @Input() subTitle: string = 'Enter the e-mail you used during registration';
25
- @Input() buttonCaption: string = 'Submit';
26
- @Input() buttonTextColor?: string;
27
- @Input() buttonBackgroundColor?: string;
28
- @Input() tenant: string = '';
29
-
30
- @Output() onSubmit: EventEmitter<ForgotPasswordData> = new EventEmitter();
31
- @Output() onSubmitEnd: EventEmitter<ResponseKeyValue | ErrorResponse> =
32
- new EventEmitter();
33
-
34
- forgotPasswordForm: FormGroup;
35
- isSubmitted: boolean = false;
36
-
37
- constructor(
38
- private fb: FormBuilder,
39
- private server: HttpWebRequestService,
40
- private utilService: UtilService
41
- ) {
42
- this.forgotPasswordForm = this.fb.group({
43
- Email: new FormControl<string | null>(null, [
44
- Validators.required,
45
- this.emailValidator.bind(this),
46
- ]),
47
- });
48
- }
49
-
50
- isValidEmail(mail: string): boolean {
51
- const emailPattern = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/;
52
- return emailPattern.test(mail);
53
- }
54
-
55
- emailValidator(control: AbstractControl): ValidationErrors | null {
56
- const value = control.value;
57
-
58
- if (this.isValidEmail(value) == false) {
59
- return { customValidation: true };
60
- }
61
-
62
- return null;
63
- }
64
-
65
- checkForm(): boolean {
66
- return this.forgotPasswordForm.valid;
67
- }
68
-
69
- async submit() {
70
- if (!this.checkForm()) {
71
- return;
72
- }
73
- var data: ForgotPasswordData = {
74
- Email: this.forgotPasswordForm.controls['Email'].value,
75
- };
76
- this.onSubmit.emit(data);
77
- this.utilService.sendBI(true);
78
- const res = await this.server.get(
79
- `User/PasswordChangeRequest/${data.Email}/${this.tenant}`
80
- );
81
- this.utilService.sendBI(false);
82
- if (res instanceof ErrorResponse) {
83
- this.onSubmitEnd.emit(res);
84
- } else {
85
- var result = res as ResponseKeyValue;
86
- this.onSubmitEnd.emit(result);
87
- this.isSubmitted = true;
88
- }
89
- }
90
- }
@@ -1,18 +0,0 @@
1
- import { NgModule } from '@angular/core';
2
- import { ForgotPasswordComponent } from './forgot-password.component';
3
- import { FormsModule, ReactiveFormsModule } from '@angular/forms';
4
- import { VerbenaButtonModule, VerbenaInputModule } from 'verben-ng-ui';
5
- import { CommonModule } from '@angular/common';
6
-
7
- @NgModule({
8
- declarations: [ForgotPasswordComponent],
9
- imports: [
10
- FormsModule,
11
- ReactiveFormsModule,
12
- VerbenaInputModule,
13
- VerbenaButtonModule,
14
- CommonModule,
15
- ],
16
- exports: [ForgotPasswordComponent],
17
- })
18
- export class ForgotPasswordModule {}
File without changes
@@ -1,11 +0,0 @@
1
- <section
2
- [ngStyle]="styles"
3
- class="{{ customClass }}"
4
- >
5
- <h3 class="{{headlingClass}}">Your e-mail has been verified!</h3>
6
- <lib-button
7
- text="Login"
8
- buttonClass=""
9
- (click)="goToLogin()"
10
- ></lib-button>
11
- </section>
@@ -1,23 +0,0 @@
1
- import { ComponentFixture, TestBed } from '@angular/core/testing';
2
-
3
- import { MailComponent } from './mail.component';
4
-
5
- describe('MailComponent', () => {
6
- let component: MailComponent;
7
- let fixture: ComponentFixture<MailComponent>;
8
-
9
- beforeEach(async () => {
10
- await TestBed.configureTestingModule({
11
- imports: [MailComponent]
12
- })
13
- .compileComponents();
14
-
15
- fixture = TestBed.createComponent(MailComponent);
16
- component = fixture.componentInstance;
17
- fixture.detectChanges();
18
- });
19
-
20
- it('should create', () => {
21
- expect(component).toBeTruthy();
22
- });
23
- });
@@ -1,47 +0,0 @@
1
- import { Component, EventEmitter, Input, Output } from '@angular/core';
2
-
3
-
4
- @Component({
5
- selector: 'verben-mail-message',
6
- templateUrl: './mail.component.html',
7
- styleUrl: './mail.component.css'
8
- })
9
-
10
-
11
- export class MailComponent {
12
- @Input() customClass: string = ''
13
- @Input() headlingClass: string = ''
14
- @Input() width: string = '';
15
- @Input() maxWidth: string = '';
16
- @Input() margin: string = '';
17
- @Input() pd: string = '';
18
- @Input() bgColor: string = '#fff';
19
- @Input() boxShadow: string = '4px 4px 4px rgba(0, 0, 0, 0.25)';
20
- @Input() border: string = '1px solid #66666680';
21
- @Input() borderRadius: string = '24px';
22
- @Input() textColor: string = '#333';
23
- @Input() height: string = 'auto';
24
-
25
- @Output() buttonClick = new EventEmitter();
26
-
27
- goToLogin(){
28
- this.buttonClick.emit()
29
- }
30
-
31
- get styles() {
32
- return {
33
- 'background-color': this.bgColor,
34
- 'box-shadow': this.boxShadow,
35
- 'border': this.border,
36
- 'border-radius': this.borderRadius,
37
- 'color': this.textColor,
38
- 'width': this.width,
39
- 'max-width':this.maxWidth,
40
- 'margin':this.margin,
41
- 'height': this.height,
42
- 'padding':this.pd
43
- };
44
- }
45
-
46
- }
47
-
@@ -1,13 +0,0 @@
1
- import { NgModule } from '@angular/core';
2
- import { CommonModule } from '@angular/common';
3
- import { FormsModule } from '@angular/forms';
4
- import { RouterLink} from '@angular/router';
5
- import { ButtonModule } from '../button/button.module';
6
- import { MailComponent } from './mail.component';
7
-
8
- @NgModule({
9
- declarations: [MailComponent],
10
- imports: [CommonModule, FormsModule,RouterLink,ButtonModule],
11
- exports: [MailComponent]
12
- })
13
- export class MailModule {}
@@ -1,59 +0,0 @@
1
- /* Container Styles */
2
- .flex {
3
- display: flex;
4
- }
5
- .overflow-hidden {
6
- overflow: hidden;
7
- }
8
- .h-full {
9
- height: 100%;
10
- }
11
-
12
- .underline {
13
- text-decoration: underline;
14
- }
15
-
16
- .mt-4 {
17
- margin-top: 1rem;
18
- }
19
- .resend{
20
- color: blue;
21
- }
22
- .space-y-4 > :not([hidden]) ~ :not([hidden]) {
23
- margin-top: 1rem;
24
- }
25
- .gap-1 > :not([hidden]) ~ :not([hidden]) {
26
- gap: 0.25rem;
27
- }
28
- .pt-3 {
29
- padding-top: 0.75rem;
30
- }
31
- .mt-5 {
32
- margin-top: 1.25rem;
33
- }
34
-
35
- /* Form and Input Styles */
36
- .border {
37
- border-width: 1px;
38
- }
39
-
40
- .rounded-xl {
41
- border-radius: 0.75rem;
42
- }
43
- .px-3 {
44
- padding-left: 0.75rem;
45
- padding-right: 0.75rem;
46
- }
47
- .py-3 {
48
- padding-top: 0.75rem;
49
- padding-bottom: 0.75rem;
50
- }
51
- .flex-col {
52
- flex-direction: column;
53
- }
54
- .w-full {
55
- width: 100%;
56
- }
57
-
58
-
59
-
@@ -1,37 +0,0 @@
1
- <section [ngStyle]="styles" class="{{ customClass }}">
2
- <div *ngIf="currentStep === 'linkSent'">
3
- <p [style.color]="textColor" [style.font-size]="textSize">
4
- Follow the link sent to your e-mail to verify your e-mail address
5
- </p>
6
- <p class="mt-4" (click)="handleResendOtp()">
7
- Didn't get a link? <a href="#" class="underline resend">Resend</a>
8
- </p>
9
- </div>
10
-
11
- <div *ngIf="currentStep === 'verified'">
12
- <p [style.color]="textColor" [style.font-size]="textSize">
13
- Your e-mail has been verified! You will be notified when your access has
14
- been authorized
15
- </p>
16
- </div>
17
-
18
- <div *ngIf="currentStep === 'accessGranted'">
19
- <p [style.color]="textColor" [style.font-size]="textSize">
20
- Your e-mail has been verified!
21
- </p>
22
- <div class="mt-4">
23
- <verbena-button
24
- [text]="text"
25
- [bgColor]="btnBgColor"
26
- [textColor]="color"
27
- [border]="btnBorder"
28
- [borderRadius]="btnBorderRadius"
29
- [pd]="btnPd"
30
- (click)="handleLogin()"
31
- [width]="btnWidth"
32
- textSize="'22px'"
33
- buttonClass="font-medium text-[22px] leading-[33px]"
34
- ></verbena-button>
35
- </div>
36
- </div>
37
- </section>
@@ -1,23 +0,0 @@
1
- import { ComponentFixture, TestBed } from '@angular/core/testing';
2
-
3
- import { MailValidationComponent } from './mail-validation.component';
4
-
5
- describe('MailValidationComponent', () => {
6
- let component: MailValidationComponent;
7
- let fixture: ComponentFixture<MailValidationComponent>;
8
-
9
- beforeEach(async () => {
10
- await TestBed.configureTestingModule({
11
- imports: [MailValidationComponent]
12
- })
13
- .compileComponents();
14
-
15
- fixture = TestBed.createComponent(MailValidationComponent);
16
- component = fixture.componentInstance;
17
- fixture.detectChanges();
18
- });
19
-
20
- it('should create', () => {
21
- expect(component).toBeTruthy();
22
- });
23
- });
@@ -1,66 +0,0 @@
1
- import { Component, EventEmitter, Input, Output } from '@angular/core';
2
-
3
- @Component({
4
- selector: 'lib-mail-validation',
5
- templateUrl: './mail-validation.component.html',
6
- styleUrls: ['./mail-validation.component.css']
7
- })
8
- export class MailValidationComponent {
9
- @Input() customClass: string = '';
10
- @Input() bgColor: string = '#fff';
11
- @Input() boxShadow: string = '4px 4px 4px rgba(0, 0, 0, 0.25)';
12
- @Input() border: string = '1px solid #66666680';
13
- @Input() borderRadius: string = '24px';
14
- @Input() textColor: string = '#666666';
15
- @Input() height: string = 'auto';
16
- @Input() pd: string = '32px 48px';
17
- @Input() width: string = '600px';
18
- @Input() text: string = 'Login';
19
- @Input() textAlign: string = 'center';
20
- @Input() color: string = 'black';
21
- @Input() textSize: string = '32px';
22
- @Input() btnBorder: string = '1px solid #FFE681';
23
- @Input() btnBorderRadius: string = "40px";
24
- @Input() btnBgColor: string = '#FFE681';
25
- @Input() btnWidth: string = '100%';
26
- @Input() btnPd: string = '7px 10px';
27
-
28
- @Output() resendOtp = new EventEmitter<void>();
29
- @Output() proceedToNextStep = new EventEmitter<'verified' | 'accessGranted'>();
30
- @Output() login = new EventEmitter<void>();
31
-
32
- currentStep: 'linkSent' | 'verified' | 'accessGranted' = 'linkSent';
33
-
34
- handleResendOtp() {
35
- this.resendOtp.emit();
36
- }
37
-
38
- goToNextStep() {
39
- switch (this.currentStep) {
40
- case 'linkSent':
41
- this.currentStep = 'verified';
42
- this.proceedToNextStep.emit(this.currentStep);
43
- break;
44
- case 'verified':
45
- this.currentStep = 'accessGranted';
46
- this.proceedToNextStep.emit(this.currentStep);
47
- break;
48
- }
49
- }
50
- get styles() {
51
- return {
52
- 'background-color': this.bgColor,
53
- 'box-shadow': this.boxShadow,
54
- 'border': this.border,
55
- 'border-radius': this.borderRadius,
56
- 'color': this.textColor,
57
- 'max-width': this.width,
58
- 'margin': '0 auto',
59
- 'height': this.height,
60
- 'padding': this.pd,
61
- };
62
- }
63
- handleLogin() {
64
- this.login.emit();
65
- }
66
- }
@@ -1,18 +0,0 @@
1
- import { NgModule } from '@angular/core';
2
- import { FormsModule, ReactiveFormsModule } from '@angular/forms';
3
- import { VerbenaButtonModule, VerbenaInputModule } from 'verben-ng-ui';
4
- import { CommonModule } from '@angular/common';
5
- import { MailValidationComponent } from './mail-validation.component';
6
-
7
- @NgModule({
8
- declarations: [MailValidationComponent],
9
- imports: [
10
- FormsModule,
11
- ReactiveFormsModule,
12
- VerbenaInputModule,
13
- VerbenaButtonModule,
14
- CommonModule,
15
- ],
16
- exports: [MailValidationComponent],
17
- })
18
- export class MailValidationModule {}
@@ -1,26 +0,0 @@
1
- hr {
2
- height: 1px;
3
- margin: 0;
4
- border:1px solid #66666640;
5
- flex:1
6
- }
7
-
8
- .OR{
9
- margin: 0 2px;
10
- color:#666666
11
- }
12
- .oauthWrapper{
13
- display: flex;
14
- flex-direction: column;
15
- gap:12px;
16
- }
17
- .btnWrapper{
18
- display: flex;
19
- flex-direction: column;
20
- gap:10px;
21
- }
22
- .OrFlexWrapper{
23
- display: flex;
24
- align-items: center;
25
- gap:8px;
26
- }
@@ -1,26 +0,0 @@
1
- <section class="oauthWrapper">
2
- <div class="OrFlexWrapper">
3
- <hr/>
4
- <span>OR</span>
5
- <hr/>
6
- </div>
7
- <div class="btnWrapper">
8
- <div *ngFor="let btn of authMechanisms, let i = index">
9
- <verbena-button
10
- [svg]="checkForValue(btn.AuthMechanism)"
11
- [svgHeight]="24"
12
- [svgWidth]="24"
13
- [text]="'Continue with ' + btn.AuthMechanism"
14
- bgColor="white"
15
- textColor="black"
16
- border="1px solid #333"
17
- borderRadius="40px"
18
- pd="10px 20px"
19
- width="100%"
20
- svgPosition="left"
21
- buttonClass="font-normal text-[24px] leading-[29.05px] text-[#333] mt-2"
22
- (click)="handleOauthClick(btn)"
23
- ></verbena-button>
24
- </div>
25
- </div>
26
- </section>
@@ -1,23 +0,0 @@
1
- import { ComponentFixture, TestBed } from '@angular/core/testing';
2
-
3
- import { OAuthComponent } from './o-auth.component';
4
-
5
- describe('OAuthComponent', () => {
6
- let component: OAuthComponent;
7
- let fixture: ComponentFixture<OAuthComponent>;
8
-
9
- beforeEach(async () => {
10
- await TestBed.configureTestingModule({
11
- imports: [OAuthComponent]
12
- })
13
- .compileComponents();
14
-
15
- fixture = TestBed.createComponent(OAuthComponent);
16
- component = fixture.componentInstance;
17
- fixture.detectChanges();
18
- });
19
-
20
- it('should create', () => {
21
- expect(component).toBeTruthy();
22
- });
23
- });
@@ -1,115 +0,0 @@
1
- import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';
2
- import { AuthMechanism, MechanismType } from '../../models/auth-mechanism';
3
- import { ActivatedRoute, Router } from '@angular/router';
4
- import { HttpWebRequestService } from '../../services/http-web-request.service';
5
- import { UtilService } from '../../services/util.service';
6
-
7
- declare global {
8
- interface Window {
9
- google: any;
10
- }
11
- }
12
-
13
- @Component({
14
- selector: 'verben-o-auth',
15
- templateUrl: './o-auth.component.html',
16
- styleUrl: './o-auth.component.css',
17
- })
18
- export class OAuthComponent implements OnInit {
19
- showGoogle: boolean = false;
20
- showMicrosoft: boolean = false;
21
- showApple: boolean = false;
22
- @Input() authMechanisms: AuthMechanism[] | null = null;
23
- @Output() emitMechanismFn = new EventEmitter<string>();
24
- page: string = '';
25
- type: string = '';
26
-
27
- constructor(private router: Router) {}
28
-
29
- ngOnInit(): void {
30
- this.loadPage();
31
- this.loadGoogleScript();
32
- if (this.authMechanisms !== null) {
33
- this.authMechanisms = this.authMechanisms.filter(
34
- (item) => item.AuthMechanism !== MechanismType.InApp
35
- );
36
- }
37
- }
38
-
39
- loadPage() {
40
- this.page = this.router.url;
41
- }
42
-
43
- loadGoogleScript(): void {
44
- if (!document.getElementById('google-jssdk')) {
45
- const script = document.createElement('script');
46
- script.src = 'https://accounts.google.com/gsi/client';
47
- script.id = 'google-jssdk';
48
- script.async = true;
49
- script.defer = true;
50
- script.onload = () => console.log('Google SDK loaded');
51
- script.onerror = () => console.log('Error loading Google SDK');
52
- document.head.appendChild(script);
53
- }
54
- }
55
-
56
- oAuthWithGoogle(data: AuthMechanism) {
57
- this.type = data.AuthMechanism;
58
- localStorage.setItem('type', JSON.stringify(this.type));
59
- const redirectUri = encodeURIComponent(data.RedirectUri);
60
- const scope = encodeURIComponent('openid email profile');
61
- const responseType = 'code';
62
- const state = encodeURIComponent(JSON.stringify({ returnTo: this.page }));
63
- const authUrl = `https://accounts.google.com/o/oauth2/v2/auth?client_id=${data.ClientId}&redirect_uri=${redirectUri}&response_type=${responseType}&scope=${scope}&state=${state}`;
64
- window.location.href = authUrl;
65
- }
66
-
67
- oAuthWithApple() {}
68
-
69
- oAuthWithMicrosoft(data: AuthMechanism) {
70
- this.type = data.AuthMechanism;
71
- const cleanUrl = window.location.href.split('?')[0];
72
- window.history.replaceState({}, document.title, cleanUrl); // Update the URL without reloading
73
- localStorage.setItem('type', JSON.stringify(this.type));
74
- const redirectUri = encodeURIComponent(data.RedirectUri);
75
- const scope = encodeURIComponent('openid email profile');
76
- const responseType = 'code';
77
- const state = encodeURIComponent(JSON.stringify({ returnTo: this.page }));
78
- // const authUrl = `https://login.microsoftonline.com/${data.TenantId}/oauth2/v2.0/authorize?client_id=${data.ClientId}&response_type=${responseType}&redirect_uri=${redirectUri}&response_mode=query&state=${state}`;
79
- const authUrl = `https://login.microsoftonline.com/common/oauth2/v2.0/authorize
80
- ?client_id=${data.ClientId}
81
- &response_type=${responseType}
82
- &redirect_uri=${redirectUri}&scope=${scope}
83
- &response_mode=query&state=${state}`;
84
- window.location.href = authUrl;
85
- }
86
-
87
- checkForValue(value: string) {
88
- switch (value) {
89
- case MechanismType.Google:
90
- return 'google-logo';
91
- case MechanismType.Apple:
92
- return 'apple-logo';
93
- case MechanismType.MicrosoftAD:
94
- return 'microsoft-logo';
95
- default:
96
- return '';
97
- }
98
- }
99
-
100
- handleOauthClick(value: AuthMechanism) {
101
- switch (value.AuthMechanism) {
102
- case MechanismType.Google:
103
- return this.oAuthWithGoogle(value);
104
- break;
105
- case MechanismType.Apple:
106
- return this.oAuthWithApple();
107
- break;
108
- case MechanismType.MicrosoftAD:
109
- return this.oAuthWithMicrosoft(value);
110
- break;
111
- default:
112
- return '';
113
- }
114
- }
115
- }
@@ -1,11 +0,0 @@
1
- import { NgModule } from '@angular/core';
2
- import { CommonModule } from '@angular/common';
3
- import { VerbenaButtonModule, VerbenaInputModule } from 'verben-ng-ui';
4
- import { OAuthComponent } from './o-auth.component';
5
-
6
- @NgModule({
7
- declarations: [OAuthComponent],
8
- imports: [CommonModule,VerbenaInputModule,VerbenaButtonModule],
9
- exports: [OAuthComponent]
10
- })
11
- export class OAuthModule {}
@@ -1,19 +0,0 @@
1
- .otp-container {
2
- display: flex;
3
- gap: 15px;
4
- }
5
-
6
- .otp-input {
7
- width: 50px;
8
- height: 46px;
9
- text-align: center;
10
- font-size: 1.5rem;
11
- border: 1px solid #66666658;
12
- border-radius: 12px;
13
- }
14
-
15
-
16
- .otp-input:focus {
17
- border-color: #FFE681;
18
- outline: none;
19
- }
@@ -1,15 +0,0 @@
1
- <form [formGroup]="otpForm" >
2
- <div formArrayName="otpArray" class="otp-container">
3
- <input
4
- *ngFor="let control of otpArray.controls; let i = index"
5
- [id]="'otp-input-' + i"
6
- class="otp-input {{otpClass}}"
7
- maxlength="1"
8
- (input)="handleInput($event, i)"
9
- (keydown)="handleKeydown($event, i)"
10
- (paste)="handlePaste($event)"
11
- [formControlName]="i"
12
- type="text"
13
- />
14
- </div>
15
- </form>
@@ -1,23 +0,0 @@
1
- import { ComponentFixture, TestBed } from '@angular/core/testing';
2
-
3
- import { OtpInputComponent } from './otp-input.component';
4
-
5
- describe('OtpInputComponent', () => {
6
- let component: OtpInputComponent;
7
- let fixture: ComponentFixture<OtpInputComponent>;
8
-
9
- beforeEach(async () => {
10
- await TestBed.configureTestingModule({
11
- imports: [OtpInputComponent]
12
- })
13
- .compileComponents();
14
-
15
- fixture = TestBed.createComponent(OtpInputComponent);
16
- component = fixture.componentInstance;
17
- fixture.detectChanges();
18
- });
19
-
20
- it('should create', () => {
21
- expect(component).toBeTruthy();
22
- });
23
- });