@ctx-core/auth0-ui 11.0.23 → 12.1.1

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 (54) hide show
  1. package/CHANGELOG.md +38 -0
  2. package/COMMIT_EDITMSG +1 -0
  3. package/dist/app.html +13 -0
  4. package/dist/index.js +1 -5
  5. package/dist/index.js.map +1 -1
  6. package/dist/{auth0_ui_ctx_key.js → lib/auth0_ui_ctx_key.js} +0 -0
  7. package/dist/lib/auth0_ui_ctx_key.js.map +1 -0
  8. package/dist/{auth_script_html_.js → lib/auth_script_html_.js} +0 -0
  9. package/dist/lib/auth_script_html_.js.map +1 -0
  10. package/dist/{getContext_auth0_ui_ctx.js → lib/getContext_auth0_ui_ctx.js} +0 -0
  11. package/dist/lib/getContext_auth0_ui_ctx.js.map +1 -0
  12. package/dist/lib/index.js +6 -0
  13. package/dist/lib/index.js.map +1 -0
  14. package/dist/{ui → lib/ui}/Auth0.svelte +0 -0
  15. package/dist/{ui → lib/ui}/Auth0_Change_Password_Form.svelte +0 -0
  16. package/dist/{ui → lib/ui}/Auth0_Dialog_Close.svelte +0 -0
  17. package/dist/{ui → lib/ui}/Auth0_Forgot_Password_Check_Email_Form.svelte +0 -0
  18. package/dist/{ui → lib/ui}/Auth0_Forgot_Password_Form.svelte +0 -0
  19. package/dist/{ui → lib/ui}/Auth0_Login_Form.svelte +0 -0
  20. package/dist/{ui → lib/ui}/Auth0_Signup_Form.svelte +0 -0
  21. package/dist/{ui → lib/ui}/Auth0_c.js +0 -0
  22. package/dist/lib/ui/Auth0_c.js.map +1 -0
  23. package/dist/{ui → lib/ui}/index.js +0 -2
  24. package/dist/lib/ui/index.js.map +1 -0
  25. package/package.json +21 -17
  26. package/src/app.html +13 -0
  27. package/src/index.ts +1 -5
  28. package/src/{auth0_ui_ctx_key.ts → lib/auth0_ui_ctx_key.ts} +0 -0
  29. package/src/{auth_script_html_.ts → lib/auth_script_html_.ts} +0 -0
  30. package/src/{getContext_auth0_ui_ctx.ts → lib/getContext_auth0_ui_ctx.ts} +0 -0
  31. package/src/lib/index.ts +4 -0
  32. package/src/{ui → lib/ui}/Auth0.svelte +0 -0
  33. package/src/{ui → lib/ui}/Auth0_Change_Password_Form.svelte +0 -0
  34. package/src/{ui → lib/ui}/Auth0_Dialog_Close.svelte +0 -0
  35. package/src/{ui → lib/ui}/Auth0_Forgot_Password_Check_Email_Form.svelte +0 -0
  36. package/src/{ui → lib/ui}/Auth0_Forgot_Password_Form.svelte +0 -0
  37. package/src/{ui → lib/ui}/Auth0_Login_Form.svelte +0 -0
  38. package/src/{ui → lib/ui}/Auth0_Signup_Form.svelte +0 -0
  39. package/src/{ui → lib/ui}/Auth0_c.ts +0 -0
  40. package/src/{ui → lib/ui}/index.ts +0 -1
  41. package/svelte.config.js +18 -0
  42. package/dist/auth0_ui_Ctx.js +0 -3
  43. package/dist/auth0_ui_Ctx.js.map +0 -1
  44. package/dist/auth0_ui_ctx_I.generated.js +0 -5
  45. package/dist/auth0_ui_ctx_I.generated.js.map +0 -1
  46. package/dist/auth0_ui_ctx_key.js.map +0 -1
  47. package/dist/auth_script_html_.js.map +0 -1
  48. package/dist/getContext_auth0_ui_ctx.js.map +0 -1
  49. package/dist/ui/Auth0_Loggedin_If.svelte +0 -14
  50. package/dist/ui/Auth0_c.js.map +0 -1
  51. package/dist/ui/index.js.map +0 -1
  52. package/src/auth0_ui_Ctx.ts +0 -11
  53. package/src/auth0_ui_ctx_I.generated.ts +0 -7
  54. package/src/ui/Auth0_Loggedin_If.svelte +0 -14
package/CHANGELOG.md CHANGED
@@ -1,5 +1,43 @@
1
1
  # @ctx-core/auth0-ui
2
2
 
3
+ ## 12.1.1
4
+
5
+ ### Patch Changes
6
+
7
+ - package.json: - module
8
+ - Updated dependencies
9
+ - Updated dependencies
10
+ - Updated dependencies
11
+ - @ctx-core/object@22.0.0
12
+ - @ctx-core/auth0@27.0.0
13
+ - @ctx-core/auth0-management@7.0.0
14
+ - @ctx-core/dialog@16.0.0
15
+ - @ctx-core/dom@11.0.40
16
+ - @ctx-core/error@11.1.9
17
+ - @ctx-core/http@9.0.10
18
+ - @ctx-core/jwt@10.0.38
19
+ - @ctx-core/logger@9.0.32
20
+ - @ctx-core/store@27.0.46
21
+ - @ctx-core/fetch@11.0.93
22
+
23
+ ## 12.1.0
24
+
25
+ ### Minor Changes
26
+
27
+ - svelte-kit integration
28
+
29
+ ## 12.0.1
30
+
31
+ ### Patch Changes
32
+
33
+ - update dependencies
34
+
35
+ ## 12.0.0
36
+
37
+ ### Major Changes
38
+
39
+ - - Auth0_Loggedin_If
40
+
3
41
  ## 11.0.23
4
42
 
5
43
  ### Patch Changes
package/COMMIT_EDITMSG ADDED
@@ -0,0 +1 @@
1
+
package/dist/app.html ADDED
@@ -0,0 +1,13 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8" />
5
+ <meta name="description" content="" />
6
+ <link rel="icon" href="/favicon.png" />
7
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
8
+ %svelte.head%
9
+ </head>
10
+ <body>
11
+ <div id="svelte">%svelte.body%</div>
12
+ </body>
13
+ </html>
package/dist/index.js CHANGED
@@ -1,7 +1,3 @@
1
- export * from './auth0_ui_Ctx.js';
2
- export * from './auth0_ui_ctx_key.js';
3
- export * from './auth_script_html_.js';
4
- export * from './getContext_auth0_ui_ctx.js';
5
- export * from './ui/index.js';
1
+ export * from './lib/index.js';
6
2
 
7
3
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/index.ts"],"sourcesContent":["export * from './auth0_ui_Ctx.js'\nexport * from './auth0_ui_ctx_key.js'\nexport * from './auth_script_html_.js'\nexport * from './getContext_auth0_ui_ctx.js'\nexport * from './ui/index.js'\n"],"names":[],"mappings":"cAAc,CAAmB;cACnB,CAAuB;cACvB,CAAwB;cACxB,CAA8B;cAC9B,CAAe"}
1
+ {"version":3,"sources":["../src/index.ts"],"sourcesContent":["export * from './lib/index.js'\n"],"names":[],"mappings":"cAAc,CAAgB"}
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/lib/auth0_ui_ctx_key.ts"],"sourcesContent":["export const auth0_ui_ctx_key = Symbol('auth0_ui_ctx')\n"],"names":["auth0_ui_ctx_key","Symbol"],"mappings":"AAAA,MAAM,CAAC,KAAK,CAACA,gBAAgB,GAAGC,MAAM,CAAC,CAAc"}
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/lib/auth_script_html_.ts"],"sourcesContent":["export function auth_script_html_():string {\n\treturn `\n<script>\n\t(function() {\n\t\tvar location = window.location\n\t\tvar search = location.search\n\t\tvar search_values = _values(search.substr(1))\n\t\tvar hash = location.hash\n\t\tvar auth0_token = _values(hash.substr(1))\n\t\tvar auth0_token_json = JSON.stringify(auth0_token)\n\t\tvar redirect_url =\n\t\t\t\t\tsearch_values\n\t\t\t\t\t&& search_values.redirect_url\n\t\tlocalStorage.setItem('auth0_token_json', auth0_token_json)\n\t\tif (redirect_url) {\n\t\t\tlocation.href = redirect_url\n\t\t}\n\t\tfunction _values(string) {\n\t\t\tvar segments = string.split('&')\n\t\t\tvar values = {}\n\t\t\tfor (var i=0; i < segments.length; i++) {\n\t\t\t\tvar pair = segments[i].split('=')\n\t\t\t\tvar key = decodeURIComponent(pair[0])\n\t\t\t\tvar value = decodeURIComponent(pair[1])\n\t\t\t\tvalues[key] = value\n\t\t\t}\n\t\t\treturn values\n\t\t}\n\t})()\n</script>\n\t`.trim()\n}\nexport {\n\tauth_script_html_ as _auth_script_html,\n\tauth_script_html_ as _html__script__auth,\n}\n"],"names":["auth_script_html_","trim","_auth_script_html","_html__script__auth"],"mappings":"AAAA,MAAM,UAAUA,iBAAiB,GAAU,CAAC;IAC3C,MAAM,EAAE,uwBA6BR,EAAEC,IAAI;AACP,CAAC;AACD,MAAM,GACLD,iBAAiB,IAAIE,iBAAiB,EACtCF,iBAAiB,IAAIG,mBAAmB"}
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/lib/getContext_auth0_ui_ctx.ts"],"sourcesContent":["import { getContext } from 'svelte'\nimport { auth0_ui_ctx_key } from './auth0_ui_ctx_key.js'\nexport function getContext_auth0_ui_ctx() {\n return getContext(auth0_ui_ctx_key)\n}\n"],"names":["getContext","auth0_ui_ctx_key","getContext_auth0_ui_ctx"],"mappings":"AAAA,MAAM,GAAGA,UAAU,QAAQ,CAAQ;AACnC,MAAM,GAAGC,gBAAgB,QAAQ,CAAuB;AACxD,MAAM,UAAUC,uBAAuB,GAAG,CAAC;IACzC,MAAM,CAACF,UAAU,CAACC,gBAAgB;AACpC,CAAC"}
@@ -0,0 +1,6 @@
1
+ export * from './auth0_ui_ctx_key.js';
2
+ export * from './auth_script_html_.js';
3
+ export * from './getContext_auth0_ui_ctx.js';
4
+ export * from './ui/index.js';
5
+
6
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/lib/index.ts"],"sourcesContent":["export * from './auth0_ui_ctx_key.js'\nexport * from './auth_script_html_.js'\nexport * from './getContext_auth0_ui_ctx.js'\nexport * from './ui/index.js'\n"],"names":[],"mappings":"cAAc,CAAuB;cACvB,CAAwB;cACxB,CAA8B;cAC9B,CAAe"}
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/lib/ui/Auth0_c.ts"],"sourcesContent":["import { onDestroy } from 'svelte'\nimport type {\n\tauth0_body__T, auth0_client_id_body_I, auth0_grant_type_body_I, login_data_I, logout_auth0_token_error_T,\n\topen_auth0_forgot_password_check_email_T, open_auth0_login_T, password_realm_body__T, password_realm_body_T,\n\tpost_auth0_auth_change_password_T, post_auth0_dbconnections_signup_T, post_auth0_oauth_token_body_I,\n\tpost_auth0_oauth_token_T, post_auth0_passwordless_start_body_T, post_auth0_passwordless_start_optional_body_T,\n\tpost_auth0_passwordless_start_T, signup_data_I\n} from '@ctx-core/auth0'\nimport {\n\tauth0_body__b, auth0_opened_class$_b, auth0_token_error$_b, auth0_token_json$_b, clear_auth0_token_error_b,\n\tclose_auth0_b, logout_auth0_token_error_b, open_auth0_forgot_password_check_email_b, open_auth0_login_b,\n\tpassword_realm_body__b, post_auth0_auth_change_password_b, post_auth0_dbconnections_signup_b,\n\tpost_auth0_oauth_token_b, post_auth0_passwordless_start_b, validate_auth0_change_password,\n\tvalidate_auth0_forgot_password, validate_auth0_signup\n} from '@ctx-core/auth0'\nimport { has_dom, dom_a_ } from '@ctx-core/dom'\nimport { noop } from '@ctx-core/function'\nimport { subscribe } from '@ctx-core/store'\nimport type { auth0_ui_Ctx } from '../auth0_ui_Ctx.js'\nexport class Auth0_c {\n\tconstructor(protected ctx:auth0_ui_Ctx) {}\n\treadonly login_auth0_body_ = auth0_body__b</*@formatter:off*/\n\t\tauth0_ui_Ctx,\n\t\t'login_auth0_body_',\n\t\tlogin_data_password_realm_body_I\n\t/*@formatter:on*/>(this.ctx, 'login_auth0_body_')\n\treadonly login_password_realm_body_ = password_realm_body__b</*@formatter:off*/\n\t\tauth0_ui_Ctx,\n\t\t'login_password_realm_body_',\n\t\tlogin_data_password_realm_body_I\n/*@formatter:on*/>(\n\t\tthis.ctx,\n\t\t'login_password_realm_body_',\n\t\tthis.login_auth0_body_\n\t)\n\treadonly signup_auth0_body_:auth0_body__T<signup_data_password_realm_body_I> = auth0_body__b</*@formatter:off*/\n\t\tauth0_ui_Ctx,\n\t\t'signup_auth0_body_',\n\t\tsignup_data_password_realm_body_I\n\t/*@formatter:on*/>(this.ctx, 'signup_auth0_body_')\n\treadonly signup_password_realm_body_:password_realm_body__T<signup_data_password_realm_body_I> = password_realm_body__b</*@formatter:off*/\n\t\tauth0_ui_Ctx,\n\t\t'signup_password_realm_body_fn',\n\t\tsignup_data_password_realm_body_I\n\t/*@formatter:on*/>(\n\t\tthis.ctx, 'signup_password_realm_body_fn', this.signup_auth0_body_\n\t)\n\treadonly auth0_opened_class = auth0_opened_class$_b(this.ctx)\n\treadonly auth0_token_json$ = auth0_token_json$_b(this.ctx)\n\treadonly auth0_token_error = auth0_token_error$_b(this.ctx)\n\treadonly clear_auth0_token_error = clear_auth0_token_error_b(this.ctx)\n\treadonly close_auth0 = close_auth0_b(this.ctx)\n\treadonly logout_auth0_token_error:logout_auth0_token_error_T = logout_auth0_token_error_b(this.ctx)\n\treadonly open_auth0_login:open_auth0_login_T = open_auth0_login_b(this.ctx)\n\treadonly open_auth0_forgot_password_check_email:open_auth0_forgot_password_check_email_T = open_auth0_forgot_password_check_email_b(this.ctx)\n\treadonly post_auth0_dbconnections_signup:post_auth0_dbconnections_signup_T = post_auth0_dbconnections_signup_b(this.ctx)\n\treadonly post_auth0_oauth_token:post_auth0_oauth_token_T = post_auth0_oauth_token_b(this.ctx)\n\treadonly post_auth0_auth_change_password:post_auth0_auth_change_password_T = post_auth0_auth_change_password_b(this.ctx)\n\treadonly post_auth0_passwordless_start:post_auth0_passwordless_start_T = post_auth0_passwordless_start_b(this.ctx)\n\treadonly onMount = async (root:HTMLElement)=>{\n\t\tif (has_dom) {\n\t\t\tconst unsubscribe =\n\t\t\t\tsubscribe(this.auth0_opened_class, ()=>this.schedule_forms_clear(root))\n\t\t\tonDestroy(unsubscribe)\n\t\t}\n\t}\n\treadonly login = async (data:login_data_I, schedule_forms_clear = ()=>{})=>{\n\t\tconst response = await this.post_auth0_oauth_token(\n\t\t\tthis.login_password_realm_body_(data)\n\t\t)\n\t\tif (response.ok) {\n\t\t\tconst auth0_token_json = await response.text()\n\t\t\tthis.auth0_token_json$.$ = auth0_token_json\n\t\t\tschedule_forms_clear()\n\t\t\tthis.close_auth0()\n\t\t} else {\n\t\t\tconst $auth_token_error = await response.json()\n\t\t\tthis.auth0_token_error.$ = $auth_token_error\n\t\t\tthis.logout_auth0_token_error($auth_token_error)\n\t\t}\n\t}\n\treadonly signup = async (data:signup_data_I, schedule_forms_clear = ()=>{})=>{\n\t\tconst response = await this.post_auth0_dbconnections_signup(this.signup_password_realm_body_(data))\n\t\tconst auth0_userinfo = await response.json()\n\t\tconst { statusCode } = auth0_userinfo\n\t\tif (statusCode) {\n\t\t\tconst {\n\t\t\t\tcode,\n\t\t\t\tdescription\n\t\t\t} = auth0_userinfo\n\t\t\tconst email =\n\t\t\t\tcode === 'user_exists'\n\t\t\t\t? 'This Email is already signed up'\n\t\t\t\t: description\n\t\t\tconst auth0_token_error = { email }\n\t\t\tthis.logout_auth0_token_error(auth0_token_error)\n\t\t\treturn\n\t\t}\n\t\tschedule_forms_clear()\n\t\tawait this.login({\n\t\t\tusername: data.email,\n\t\t\tpassword: data.password,\n\t\t}, schedule_forms_clear)\n\t}\n\treadonly change_password = async (form:{ password:string }, schedule_forms_clear = ()=>{})=>{\n\t\tconst { password } = form\n\t\tlet error\n\t\ttry {\n\t\t\tconst response = await this.post_auth0_auth_change_password(password)\n\t\t\tconst response_json = await response.json()\n\t\t\tif (!response.ok) {\n\t\t\t\tif (response.status == 401) {\n\t\t\t\t\tthis.open_auth0_login()\n\t\t\t\t\tconst auth0_token_error = { username: 'Authentication Error - Log in' }\n\t\t\t\t\tthis.logout_auth0_token_error(auth0_token_error)\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\terror = response_json.error || 'Error changing Password'\n\t\t\t}\n\t\t} catch (e:any) {\n\t\t\tconsole.warn(e)\n\t\t\terror = e.message\n\t\t}\n\t\tif (error) {\n\t\t\tconst auth0_token_error = { password: error }\n\t\t\tthis.logout_auth0_token_error(auth0_token_error)\n\t\t\treturn\n\t\t}\n\t\tschedule_forms_clear()\n\t\tthis.close_auth0()\n\t}\n\treadonly schedule_forms_clear_:(root:HTMLElement)=>void = (root:HTMLElement)=>{\n\t\treturn ()=>this.schedule_forms_clear(root)\n\t}\n\treadonly schedule_forms_clear = (root:HTMLElement)=>{\n\t\tsetTimeout(()=>{\n\t\t\tthis.clear_auth0_token_error()\n\t\t\tclear_inputs(dom_a_('input[type=text]', root))\n\t\t\tclear_inputs(dom_a_('input[type=password]', root))\n\t\t}, 100)\n\t}\n\treadonly onsubmit_signup = async (event:Event, ctx:onsubmit_signup_Ctx, schedule_forms_clear = ()=>{})=>{\n\t\tevent.preventDefault()\n\t\tconst {\n\t\t\temail_input,\n\t\t\tpassword_input,\n\t\t\tpassword_confirmation_input,\n\t\t} = ctx\n\t\tconst email = email_input.value\n\t\tconst password = password_input.value\n\t\tconst password_confirmation = password_confirmation_input.value\n\t\tconst auth0_token_error =\n\t\t\tvalidate_auth0_signup({\n\t\t\t\temail,\n\t\t\t\tpassword,\n\t\t\t\tpassword_confirmation\n\t\t\t})\n\t\tif (auth0_token_error) {\n\t\t\tthis.logout_auth0_token_error(auth0_token_error)\n\t\t\treturn false\n\t\t}\n\t\tawait this.signup({\n\t\t\temail,\n\t\t\tpassword\n\t\t}, schedule_forms_clear)\n\t\treturn\n\t}\n\treadonly onsubmit_login = async (event:Event, ctx:onsubmit_login_Ctx, schedule_forms_clear = ()=>{})=>{\n\t\tevent.preventDefault()\n\t\tconst { username_login_input, password_login_input } = ctx\n\t\tconst username = username_login_input.value\n\t\tconst password = password_login_input.value\n\t\tawait this.login({ username, password }, schedule_forms_clear)\n\t}\n\treadonly onsubmit_forgot_password = async (event:Event, ctx:onsubmit_forgot_password_Ctx)=>{\n\t\tevent.preventDefault()\n\t\tconst { email_input } = ctx\n\t\tconst email = email_input.value\n\t\tconst data:post_auth0_passwordless_start_optional_body_T = {\n\t\t\tconnection: 'email',\n\t\t\tsend: 'link',\n\t\t\temail\n\t\t}\n\t\tconst auth0_token_error = validate_auth0_forgot_password(data)\n\t\tif (auth0_token_error) {\n\t\t\tthis.logout_auth0_token_error(auth0_token_error)\n\t\t\treturn\n\t\t}\n\t\tawait this.post_auth0_passwordless_start(\n\t\t\tthis.login_auth0_body_(data) as post_auth0_passwordless_start_body_T\n\t\t)\n\t\tthis.open_auth0_forgot_password_check_email()\n\t}\n\treadonly onsubmit_change_password = async (\n\t\tevent:Event, ctx:onsubmit_change_password_Ctx, schedule_forms_clear = noop\n\t)=>{\n\t\tevent.preventDefault()\n\t\tconst {\n\t\t\tpassword_input,\n\t\t\tpassword_confirmation_input,\n\t\t} = ctx\n\t\tconst password = password_input.value\n\t\tconst password_confirmation = password_confirmation_input.value\n\t\tconst auth0_token_error =\n\t\t\tvalidate_auth0_change_password(\n\t\t\t\t{\n\t\t\t\t\tpassword,\n\t\t\t\t\tpassword_confirmation\n\t\t\t\t})\n\t\tif (auth0_token_error) {\n\t\t\tthis.logout_auth0_token_error(auth0_token_error)\n\t\t\tthrow auth0_token_error\n\t\t}\n\t\treturn await this.change_password({ password }, schedule_forms_clear)\n\t}\n\treadonly onclose = async (event:MouseEvent)=>{\n\t\tevent.preventDefault()\n\t\tthis.close_auth0()\n\t}\n}\nfunction clear_inputs(inputs:NodeList) {\n\tfor (let i = 0; i < inputs.length; i++) {\n\t\tconst input = inputs[i] as HTMLInputElement\n\t\tinput.value = ''\n\t}\n}\nexport interface signup_data_password_realm_body_I\n\textends signup_data_I,\n\t\tauth0_client_id_body_I,\n\t\tpost_auth0_passwordless_start_body_T,\n\t\tpassword_realm_body_T,\n\t\tauth0_grant_type_body_I,\n\t\tpost_auth0_oauth_token_body_I {}\nexport interface login_data_password_realm_body_I\n\textends login_data_I,\n\t\tauth0_client_id_body_I,\n\t\tpost_auth0_passwordless_start_body_T,\n\t\tpassword_realm_body_T,\n\t\tauth0_grant_type_body_I,\n\t\tpost_auth0_oauth_token_body_I {}\nexport interface onsubmit_change_password_Ctx {\n\tpassword_input:HTMLInputElement\n\tpassword_confirmation_input:HTMLInputElement\n}\nexport interface onsubmit_forgot_password_Ctx {\n\temail_input:HTMLInputElement\n}\nexport interface onsubmit_login_Ctx {\n\tusername_login_input:HTMLInputElement\n\tpassword_login_input:HTMLInputElement\n}\nexport interface onsubmit_signup_Ctx {\n\temail_input:HTMLInputElement\n\tpassword_input:HTMLInputElement\n\tpassword_confirmation_input:HTMLInputElement\n}\n"],"names":["onDestroy","auth0_body__b","auth0_opened_class$_b","auth0_token_error$_b","auth0_token_json$_b","clear_auth0_token_error_b","close_auth0_b","logout_auth0_token_error_b","open_auth0_forgot_password_check_email_b","open_auth0_login_b","password_realm_body__b","post_auth0_auth_change_password_b","post_auth0_dbconnections_signup_b","post_auth0_oauth_token_b","post_auth0_passwordless_start_b","validate_auth0_change_password","validate_auth0_forgot_password","validate_auth0_signup","has_dom","dom_a_","noop","subscribe","Auth0_c","login_auth0_body_","ctx","login_password_realm_body_","signup_auth0_body_","signup_password_realm_body_","auth0_opened_class","auth0_token_json$","auth0_token_error","clear_auth0_token_error","close_auth0","logout_auth0_token_error","open_auth0_login","open_auth0_forgot_password_check_email","post_auth0_dbconnections_signup","post_auth0_oauth_token","post_auth0_auth_change_password","post_auth0_passwordless_start","onMount","root","unsubscribe","schedule_forms_clear","login","data","response","ok","auth0_token_json","text","$","$auth_token_error","json","signup","auth0_userinfo","statusCode","code","description","email","username","password","change_password","form","error","response_json","status","e","console","warn","message","schedule_forms_clear_","setTimeout","clear_inputs","onsubmit_signup","event","preventDefault","email_input","password_input","password_confirmation_input","value","password_confirmation","onsubmit_login","username_login_input","password_login_input","onsubmit_forgot_password","connection","send","onsubmit_change_password","onclose","inputs","i","length","input"],"mappings":"AAAA,MAAM,GAAGA,SAAS,QAAQ,CAAQ;AAQlC,MAAM,GACLC,aAAa,EAAEC,qBAAqB,EAAEC,oBAAoB,EAAEC,mBAAmB,EAAEC,yBAAyB,EAC1GC,aAAa,EAAEC,0BAA0B,EAAEC,wCAAwC,EAAEC,kBAAkB,EACvGC,sBAAsB,EAAEC,iCAAiC,EAAEC,iCAAiC,EAC5FC,wBAAwB,EAAEC,+BAA+B,EAAEC,8BAA8B,EACzFC,8BAA8B,EAAEC,qBAAqB,QAC/C,CAAiB;AACxB,MAAM,GAAGC,OAAO,EAAEC,MAAM,QAAQ,CAAe;AAC/C,MAAM,GAAGC,IAAI,QAAQ,CAAoB;AACzC,MAAM,GAAGC,SAAS,QAAQ,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AM,CAACC,CAAC;QACtBE,KAAK,CAACb,KAAK,GAAG,CAAE;IACjB,CAAC;AACF,CAAC"}
@@ -6,7 +6,6 @@ import * as _Auth0_Forgot_Password_Check_Email_Form from './Auth0_Forgot_Passwor
6
6
  import * as _Auth0_Forgot_Password_Form from './Auth0_Forgot_Password_Form.svelte';
7
7
  import * as _Auth0_Login_Form from './Auth0_Login_Form.svelte';
8
8
  import * as _Auth0_Signup_Form from './Auth0_Signup_Form.svelte';
9
- import * as _Auth0_Loggedin_If from './Auth0_Loggedin_If.svelte';
10
9
  export { _Auth0 as Auth0 };
11
10
  export { _Auth0_Dialog_Close as Auth0_Dialog_Close };
12
11
  export { _Auth0_Change_Password_Form as Auth0_Change_Password_Form };
@@ -14,6 +13,5 @@ export { _Auth0_Forgot_Password_Check_Email_Form as Auth0_Forgot_Password_Check_
14
13
  export { _Auth0_Forgot_Password_Form as Auth0_Forgot_Password_Form };
15
14
  export { _Auth0_Login_Form as Auth0_Login_Form };
16
15
  export { _Auth0_Signup_Form as Auth0_Signup_Form };
17
- export { _Auth0_Loggedin_If as Auth0_Loggedin_If };
18
16
 
19
17
  //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/lib/ui/index.ts"],"sourcesContent":["import 'svelte'\nexport * as Auth0 from './Auth0.svelte'\nexport * as Auth0_Dialog_Close from './Auth0_Dialog_Close.svelte'\nexport * as Auth0_Change_Password_Form from './Auth0_Change_Password_Form.svelte'\nexport * as Auth0_Forgot_Password_Check_Email_Form from './Auth0_Forgot_Password_Check_Email_Form.svelte'\nexport * as Auth0_Forgot_Password_Form from './Auth0_Forgot_Password_Form.svelte'\nexport * as Auth0_Login_Form from './Auth0_Login_Form.svelte'\nexport * as Auth0_Signup_Form from './Auth0_Signup_Form.svelte'\n"],"names":["Auth0","Auth0_Dialog_Close","Auth0_Change_Password_Form","Auth0_Forgot_Password_Check_Email_Form","Auth0_Forgot_Password_Form","Auth0_Login_Form","Auth0_Signup_Form"],"mappings":"AAAA,MAAM,CAAC,CAAQ;YACHA,MAAK,MAAM,CAAgB;YAC3BC,mBAAkB,MAAM,CAA6B;YACrDC,2BAA0B,MAAM,CAAqC;YACrEC,uCAAsC,MAAM,CAAiD;YAC7FC,2BAA0B,MAAM,CAAqC;YACrEC,iBAAgB,MAAM,CAA2B;YACjDC,kBAAiB,MAAM,CAA4B;SANnDN,MAAK,IAALA,KAAK;SACLC,mBAAkB,IAAlBA,kBAAkB;SAClBC,2BAA0B,IAA1BA,0BAA0B;SAC1BC,uCAAsC,IAAtCA,sCAAsC;SACtCC,2BAA0B,IAA1BA,0BAA0B;SAC1BC,iBAAgB,IAAhBA,gBAAgB;SAChBC,kBAAiB,IAAjBA,iBAAiB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ctx-core/auth0-ui",
3
- "version": "11.0.23",
3
+ "version": "12.1.1",
4
4
  "description": "ctx-core auth0 ui component & express endpoints",
5
5
  "keywords": [
6
6
  "ctx-core",
@@ -17,8 +17,8 @@
17
17
  "license": "Apache-2.0",
18
18
  "author": "Brian Takita",
19
19
  "type": "module",
20
- "module": "./dist/index.js",
21
20
  "types": "./src/index.ts",
21
+ "svelte": "./src/index.js",
22
22
  "exports": {
23
23
  ".": {
24
24
  "import": "./dist/index.js"
@@ -26,31 +26,36 @@
26
26
  "./package.json": "./package.json"
27
27
  },
28
28
  "dependencies": {
29
- "@ctx-core/auth0": "^26.0.16",
30
- "@ctx-core/auth0-management": "^6.0.118",
31
- "@ctx-core/dialog": "^15.0.88",
32
- "@ctx-core/dom": "^11.0.39",
33
- "@ctx-core/error": "^11.1.8",
34
- "@ctx-core/fetch": "^11.0.92",
29
+ "@ctx-core/auth0": "^27.0.0",
30
+ "@ctx-core/auth0-management": "^7.0.0",
31
+ "@ctx-core/dialog": "^16.0.0",
32
+ "@ctx-core/dom": "^11.0.40",
33
+ "@ctx-core/error": "^11.1.9",
34
+ "@ctx-core/fetch": "^11.0.93",
35
35
  "@ctx-core/function": "^20.2.12",
36
- "@ctx-core/http": "^9.0.9",
37
- "@ctx-core/jwt": "^10.0.37",
38
- "@ctx-core/logger": "^9.0.28",
39
- "@ctx-core/object": "^21.0.30",
40
- "@ctx-core/store": "^27.0.45",
36
+ "@ctx-core/http": "^9.0.10",
37
+ "@ctx-core/jwt": "^10.0.38",
38
+ "@ctx-core/logger": "^9.0.32",
39
+ "@ctx-core/object": "^22.0.0",
40
+ "@ctx-core/store": "^27.0.46",
41
41
  "auth0-js": "^9.18.0",
42
42
  "jsonwebtoken": "^8.5.1",
43
43
  "polka": "^0.5.2"
44
44
  },
45
45
  "devDependencies": {
46
46
  "@ctx-core/ctx-core-package-tools": "^8.0.85",
47
- "@ctx-core/dev-tools": "^7.2.9",
47
+ "@sveltejs/adapter-auto": "next",
48
+ "@sveltejs/kit": "next",
48
49
  "@swc/cli": "^0.1.52",
49
50
  "@swc/core": "^1.2.118",
50
51
  "@types/jsonwebtoken": "^8.5.6",
51
52
  "@types/polka": "^0.5.3",
52
53
  "@types/trouter": "^3.1.0",
53
54
  "svelte": "3.44.2",
55
+ "svelte-check": "^2.2.10",
56
+ "svelte-preprocess": "^4.9.8",
57
+ "svelte2tsx": "^0.4.11",
58
+ "tslib": "^2.3.1",
54
59
  "typescript": "next"
55
60
  },
56
61
  "publishConfig": {
@@ -58,10 +63,9 @@
58
63
  "cache": "~/.npm"
59
64
  },
60
65
  "scripts": {
61
- "build": "npm run generate_ctx_I_file && npm run compile",
66
+ "build": "npm run compile",
62
67
  "clean": "rm -rf dist",
63
68
  "compile": "swc src --out-dir dist --copy-files --source-maps --config-file .swcrc",
64
- "exec": "$@",
65
- "generate_ctx_I_file": "swc $(./node_modules/.bin/generate_ctx_I_file | tail -n1) --out-dir dist --source-maps --config-file .swcrc"
69
+ "exec": "$@"
66
70
  }
67
71
  }
package/src/app.html ADDED
@@ -0,0 +1,13 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8" />
5
+ <meta name="description" content="" />
6
+ <link rel="icon" href="/favicon.png" />
7
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
8
+ %svelte.head%
9
+ </head>
10
+ <body>
11
+ <div id="svelte">%svelte.body%</div>
12
+ </body>
13
+ </html>
package/src/index.ts CHANGED
@@ -1,5 +1 @@
1
- export * from './auth0_ui_Ctx.js'
2
- export * from './auth0_ui_ctx_key.js'
3
- export * from './auth_script_html_.js'
4
- export * from './getContext_auth0_ui_ctx.js'
5
- export * from './ui/index.js'
1
+ export * from './lib/index.js'
@@ -0,0 +1,4 @@
1
+ export * from './auth0_ui_ctx_key.js'
2
+ export * from './auth_script_html_.js'
3
+ export * from './getContext_auth0_ui_ctx.js'
4
+ export * from './ui/index.js'
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -6,4 +6,3 @@ export * as Auth0_Forgot_Password_Check_Email_Form from './Auth0_Forgot_Password
6
6
  export * as Auth0_Forgot_Password_Form from './Auth0_Forgot_Password_Form.svelte'
7
7
  export * as Auth0_Login_Form from './Auth0_Login_Form.svelte'
8
8
  export * as Auth0_Signup_Form from './Auth0_Signup_Form.svelte'
9
- export * as Auth0_Loggedin_If from './Auth0_Loggedin_If.svelte'
@@ -0,0 +1,18 @@
1
+ import adapter from '@sveltejs/adapter-auto'
2
+ import preprocess from 'svelte-preprocess'
3
+ /** @type {import('@sveltejs/kit').Config} */
4
+ const config = {
5
+ // Consult https://github.com/sveltejs/svelte-preprocess
6
+ // for more information about preprocessors
7
+ preprocess: preprocess(),
8
+ kit: {
9
+ adapter: adapter(),
10
+ package: {
11
+ dir: 'dist',
12
+ emitTypes: false
13
+ },
14
+ // hydrate the <div id="svelte"> element in src/app.html
15
+ target: '#svelte'
16
+ }
17
+ }
18
+ export default config
@@ -1,3 +0,0 @@
1
- export { };
2
-
3
- //# sourceMappingURL=auth0_ui_Ctx.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/auth0_ui_Ctx.ts"],"sourcesContent":["import type { auth0_body__T, auth0_Ctx, password_realm_body__T } from '@ctx-core/auth0'\nimport type { auth0_ui_ctx_I } from './auth0_ui_ctx_I.generated.js'\nimport type {\n\tlogin_data_password_realm_body_I, signup_data_password_realm_body_I\n} from './ui/Auth0_c.js'\nexport interface auth0_ui_Ctx extends auth0_ui_ctx_I, auth0_Ctx {\n\tlogin_auth0_body_:auth0_body__T<login_data_password_realm_body_I>\n\tlogin_password_realm_body_:password_realm_body__T<login_data_password_realm_body_I>\n\tsignup_auth0_body_:auth0_body__T<signup_data_password_realm_body_I>\n\tsignup_password_realm_body_fn:password_realm_body__T<signup_data_password_realm_body_I>\n}\n"],"names":[],"mappings":"AAAA,MAAM"}
@@ -1,5 +0,0 @@
1
- /*
2
- * This file was generated by `npm run generate_ctx_I_file` in @ctx-core/dev-tools
3
- */ export { };
4
-
5
- //# sourceMappingURL=auth0_ui_ctx_I.generated.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/auth0_ui_ctx_I.generated.ts"],"sourcesContent":["/*\n * This file was generated by `npm run generate_ctx_I_file` in @ctx-core/dev-tools\n*/\n\nexport interface auth0_ui_ctx_I {\n\n}"],"names":[],"mappings":"AAAA,EAEE,AAFF;;AAEE,AAFF,EAEE,CAEF,MAAM"}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/auth0_ui_ctx_key.ts"],"sourcesContent":["export const auth0_ui_ctx_key = Symbol('auth0_ui_ctx')\n"],"names":["auth0_ui_ctx_key","Symbol"],"mappings":"AAAA,MAAM,CAAC,KAAK,CAACA,gBAAgB,GAAGC,MAAM,CAAC,CAAc"}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/auth_script_html_.ts"],"sourcesContent":["export function auth_script_html_():string {\n\treturn `\n<script>\n\t(function() {\n\t\tvar location = window.location\n\t\tvar search = location.search\n\t\tvar search_values = _values(search.substr(1))\n\t\tvar hash = location.hash\n\t\tvar auth0_token = _values(hash.substr(1))\n\t\tvar auth0_token_json = JSON.stringify(auth0_token)\n\t\tvar redirect_url =\n\t\t\t\t\tsearch_values\n\t\t\t\t\t&& search_values.redirect_url\n\t\tlocalStorage.setItem('auth0_token_json', auth0_token_json)\n\t\tif (redirect_url) {\n\t\t\tlocation.href = redirect_url\n\t\t}\n\t\tfunction _values(string) {\n\t\t\tvar segments = string.split('&')\n\t\t\tvar values = {}\n\t\t\tfor (var i=0; i < segments.length; i++) {\n\t\t\t\tvar pair = segments[i].split('=')\n\t\t\t\tvar key = decodeURIComponent(pair[0])\n\t\t\t\tvar value = decodeURIComponent(pair[1])\n\t\t\t\tvalues[key] = value\n\t\t\t}\n\t\t\treturn values\n\t\t}\n\t})()\n</script>\n\t`.trim()\n}\nexport {\n\tauth_script_html_ as _auth_script_html,\n\tauth_script_html_ as _html__script__auth,\n}\n"],"names":["auth_script_html_","trim","_auth_script_html","_html__script__auth"],"mappings":"AAAA,MAAM,UAAUA,iBAAiB,GAAU,CAAC;IAC3C,MAAM,EAAE,uwBA6BR,EAAEC,IAAI;AACP,CAAC;AACD,MAAM,GACLD,iBAAiB,IAAIE,iBAAiB,EACtCF,iBAAiB,IAAIG,mBAAmB"}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/getContext_auth0_ui_ctx.ts"],"sourcesContent":["import { getContext } from 'svelte'\nimport { auth0_ui_ctx_key } from './auth0_ui_ctx_key.js'\nexport function getContext_auth0_ui_ctx() {\n return getContext(auth0_ui_ctx_key)\n}\n"],"names":["getContext","auth0_ui_ctx_key","getContext_auth0_ui_ctx"],"mappings":"AAAA,MAAM,GAAGA,UAAU,QAAQ,CAAQ;AACnC,MAAM,GAAGC,gBAAgB,QAAQ,CAAuB;AACxD,MAAM,UAAUC,uBAAuB,GAAG,CAAC;IACzC,MAAM,CAACF,UAAU,CAACC,gBAAgB;AACpC,CAAC"}
@@ -1,14 +0,0 @@
1
- <script lang="ts">
2
- import { is_auth0_loggedin$_b, is_auth0_loggedout$_b, } from '@ctx-core/auth0'
3
- import type { auth0_ui_Ctx } from '../auth0_ui_Ctx.js'
4
- import { getContext_auth0_ui_ctx } from '../getContext_auth0_ui_ctx.js'
5
- const ctx = getContext_auth0_ui_ctx() as auth0_ui_Ctx
6
- const is_auth0_loggedin$ = is_auth0_loggedin$_b(ctx)
7
- const is_auth0_loggedout$ = is_auth0_loggedout$_b(ctx)
8
- </script>
9
-
10
- {#if $is_auth0_loggedin$}
11
- <slot name="loggedin"><slot></slot></slot>
12
- {:else if $is_auth0_loggedout$}
13
- <slot name="loggedout"></slot>
14
- {/if}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../src/ui/Auth0_c.ts"],"sourcesContent":["import { onDestroy } from 'svelte'\nimport type {\n\tauth0_body__T, auth0_client_id_body_I, auth0_grant_type_body_I, login_data_I, logout_auth0_token_error_T,\n\topen_auth0_forgot_password_check_email_T, open_auth0_login_T, password_realm_body__T, password_realm_body_T,\n\tpost_auth0_auth_change_password_T, post_auth0_dbconnections_signup_T, post_auth0_oauth_token_body_I,\n\tpost_auth0_oauth_token_T, post_auth0_passwordless_start_body_T, post_auth0_passwordless_start_optional_body_T,\n\tpost_auth0_passwordless_start_T, signup_data_I\n} from '@ctx-core/auth0'\nimport {\n\tauth0_body__b, auth0_opened_class$_b, auth0_token_error$_b, auth0_token_json$_b, clear_auth0_token_error_b,\n\tclose_auth0_b, logout_auth0_token_error_b, open_auth0_forgot_password_check_email_b, open_auth0_login_b,\n\tpassword_realm_body__b, post_auth0_auth_change_password_b, post_auth0_dbconnections_signup_b,\n\tpost_auth0_oauth_token_b, post_auth0_passwordless_start_b, validate_auth0_change_password,\n\tvalidate_auth0_forgot_password, validate_auth0_signup\n} from '@ctx-core/auth0'\nimport { has_dom, dom_a_ } from '@ctx-core/dom'\nimport { noop } from '@ctx-core/function'\nimport { subscribe } from '@ctx-core/store'\nimport type { auth0_ui_Ctx } from '../auth0_ui_Ctx.js'\nexport class Auth0_c {\n\tconstructor(protected ctx:auth0_ui_Ctx) {}\n\treadonly login_auth0_body_ = auth0_body__b</*@formatter:off*/\n\t\tauth0_ui_Ctx,\n\t\t'login_auth0_body_',\n\t\tlogin_data_password_realm_body_I\n\t/*@formatter:on*/>(this.ctx, 'login_auth0_body_')\n\treadonly login_password_realm_body_ = password_realm_body__b</*@formatter:off*/\n\t\tauth0_ui_Ctx,\n\t\t'login_password_realm_body_',\n\t\tlogin_data_password_realm_body_I\n/*@formatter:on*/>(\n\t\tthis.ctx,\n\t\t'login_password_realm_body_',\n\t\tthis.login_auth0_body_\n\t)\n\treadonly signup_auth0_body_:auth0_body__T<signup_data_password_realm_body_I> = auth0_body__b</*@formatter:off*/\n\t\tauth0_ui_Ctx,\n\t\t'signup_auth0_body_',\n\t\tsignup_data_password_realm_body_I\n\t/*@formatter:on*/>(this.ctx, 'signup_auth0_body_')\n\treadonly signup_password_realm_body_:password_realm_body__T<signup_data_password_realm_body_I> = password_realm_body__b</*@formatter:off*/\n\t\tauth0_ui_Ctx,\n\t\t'signup_password_realm_body_fn',\n\t\tsignup_data_password_realm_body_I\n\t/*@formatter:on*/>(\n\t\tthis.ctx, 'signup_password_realm_body_fn', this.signup_auth0_body_\n\t)\n\treadonly auth0_opened_class = auth0_opened_class$_b(this.ctx)\n\treadonly auth0_token_json$ = auth0_token_json$_b(this.ctx)\n\treadonly auth0_token_error = auth0_token_error$_b(this.ctx)\n\treadonly clear_auth0_token_error = clear_auth0_token_error_b(this.ctx)\n\treadonly close_auth0 = close_auth0_b(this.ctx)\n\treadonly logout_auth0_token_error:logout_auth0_token_error_T = logout_auth0_token_error_b(this.ctx)\n\treadonly open_auth0_login:open_auth0_login_T = open_auth0_login_b(this.ctx)\n\treadonly open_auth0_forgot_password_check_email:open_auth0_forgot_password_check_email_T = open_auth0_forgot_password_check_email_b(this.ctx)\n\treadonly post_auth0_dbconnections_signup:post_auth0_dbconnections_signup_T = post_auth0_dbconnections_signup_b(this.ctx)\n\treadonly post_auth0_oauth_token:post_auth0_oauth_token_T = post_auth0_oauth_token_b(this.ctx)\n\treadonly post_auth0_auth_change_password:post_auth0_auth_change_password_T = post_auth0_auth_change_password_b(this.ctx)\n\treadonly post_auth0_passwordless_start:post_auth0_passwordless_start_T = post_auth0_passwordless_start_b(this.ctx)\n\treadonly onMount = async (root:HTMLElement)=>{\n\t\tif (has_dom) {\n\t\t\tconst unsubscribe =\n\t\t\t\tsubscribe(this.auth0_opened_class, ()=>this.schedule_forms_clear(root))\n\t\t\tonDestroy(unsubscribe)\n\t\t}\n\t}\n\treadonly login = async (data:login_data_I, schedule_forms_clear = ()=>{})=>{\n\t\tconst response = await this.post_auth0_oauth_token(\n\t\t\tthis.login_password_realm_body_(data)\n\t\t)\n\t\tif (response.ok) {\n\t\t\tconst auth0_token_json = await response.text()\n\t\t\tthis.auth0_token_json$.$ = auth0_token_json\n\t\t\tschedule_forms_clear()\n\t\t\tthis.close_auth0()\n\t\t} else {\n\t\t\tconst $auth_token_error = await response.json()\n\t\t\tthis.auth0_token_error.$ = $auth_token_error\n\t\t\tthis.logout_auth0_token_error($auth_token_error)\n\t\t}\n\t}\n\treadonly signup = async (data:signup_data_I, schedule_forms_clear = ()=>{})=>{\n\t\tconst response = await this.post_auth0_dbconnections_signup(this.signup_password_realm_body_(data))\n\t\tconst auth0_userinfo = await response.json()\n\t\tconst { statusCode } = auth0_userinfo\n\t\tif (statusCode) {\n\t\t\tconst {\n\t\t\t\tcode,\n\t\t\t\tdescription\n\t\t\t} = auth0_userinfo\n\t\t\tconst email =\n\t\t\t\tcode === 'user_exists'\n\t\t\t\t? 'This Email is already signed up'\n\t\t\t\t: description\n\t\t\tconst auth0_token_error = { email }\n\t\t\tthis.logout_auth0_token_error(auth0_token_error)\n\t\t\treturn\n\t\t}\n\t\tschedule_forms_clear()\n\t\tawait this.login({\n\t\t\tusername: data.email,\n\t\t\tpassword: data.password,\n\t\t}, schedule_forms_clear)\n\t}\n\treadonly change_password = async (form:{ password:string }, schedule_forms_clear = ()=>{})=>{\n\t\tconst { password } = form\n\t\tlet error\n\t\ttry {\n\t\t\tconst response = await this.post_auth0_auth_change_password(password)\n\t\t\tconst response_json = await response.json()\n\t\t\tif (!response.ok) {\n\t\t\t\tif (response.status == 401) {\n\t\t\t\t\tthis.open_auth0_login()\n\t\t\t\t\tconst auth0_token_error = { username: 'Authentication Error - Log in' }\n\t\t\t\t\tthis.logout_auth0_token_error(auth0_token_error)\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\terror = response_json.error || 'Error changing Password'\n\t\t\t}\n\t\t} catch (e:any) {\n\t\t\tconsole.warn(e)\n\t\t\terror = e.message\n\t\t}\n\t\tif (error) {\n\t\t\tconst auth0_token_error = { password: error }\n\t\t\tthis.logout_auth0_token_error(auth0_token_error)\n\t\t\treturn\n\t\t}\n\t\tschedule_forms_clear()\n\t\tthis.close_auth0()\n\t}\n\treadonly schedule_forms_clear_:(root:HTMLElement)=>void = (root:HTMLElement)=>{\n\t\treturn ()=>this.schedule_forms_clear(root)\n\t}\n\treadonly schedule_forms_clear = (root:HTMLElement)=>{\n\t\tsetTimeout(()=>{\n\t\t\tthis.clear_auth0_token_error()\n\t\t\tclear_inputs(dom_a_('input[type=text]', root))\n\t\t\tclear_inputs(dom_a_('input[type=password]', root))\n\t\t}, 100)\n\t}\n\treadonly onsubmit_signup = async (event:Event, ctx:onsubmit_signup_Ctx, schedule_forms_clear = ()=>{})=>{\n\t\tevent.preventDefault()\n\t\tconst {\n\t\t\temail_input,\n\t\t\tpassword_input,\n\t\t\tpassword_confirmation_input,\n\t\t} = ctx\n\t\tconst email = email_input.value\n\t\tconst password = password_input.value\n\t\tconst password_confirmation = password_confirmation_input.value\n\t\tconst auth0_token_error =\n\t\t\tvalidate_auth0_signup({\n\t\t\t\temail,\n\t\t\t\tpassword,\n\t\t\t\tpassword_confirmation\n\t\t\t})\n\t\tif (auth0_token_error) {\n\t\t\tthis.logout_auth0_token_error(auth0_token_error)\n\t\t\treturn false\n\t\t}\n\t\tawait this.signup({\n\t\t\temail,\n\t\t\tpassword\n\t\t}, schedule_forms_clear)\n\t\treturn\n\t}\n\treadonly onsubmit_login = async (event:Event, ctx:onsubmit_login_Ctx, schedule_forms_clear = ()=>{})=>{\n\t\tevent.preventDefault()\n\t\tconst { username_login_input, password_login_input } = ctx\n\t\tconst username = username_login_input.value\n\t\tconst password = password_login_input.value\n\t\tawait this.login({ username, password }, schedule_forms_clear)\n\t}\n\treadonly onsubmit_forgot_password = async (event:Event, ctx:onsubmit_forgot_password_Ctx)=>{\n\t\tevent.preventDefault()\n\t\tconst { email_input } = ctx\n\t\tconst email = email_input.value\n\t\tconst data:post_auth0_passwordless_start_optional_body_T = {\n\t\t\tconnection: 'email',\n\t\t\tsend: 'link',\n\t\t\temail\n\t\t}\n\t\tconst auth0_token_error = validate_auth0_forgot_password(data)\n\t\tif (auth0_token_error) {\n\t\t\tthis.logout_auth0_token_error(auth0_token_error)\n\t\t\treturn\n\t\t}\n\t\tawait this.post_auth0_passwordless_start(\n\t\t\tthis.login_auth0_body_(data) as post_auth0_passwordless_start_body_T\n\t\t)\n\t\tthis.open_auth0_forgot_password_check_email()\n\t}\n\treadonly onsubmit_change_password = async (\n\t\tevent:Event, ctx:onsubmit_change_password_Ctx, schedule_forms_clear = noop\n\t)=>{\n\t\tevent.preventDefault()\n\t\tconst {\n\t\t\tpassword_input,\n\t\t\tpassword_confirmation_input,\n\t\t} = ctx\n\t\tconst password = password_input.value\n\t\tconst password_confirmation = password_confirmation_input.value\n\t\tconst auth0_token_error =\n\t\t\tvalidate_auth0_change_password(\n\t\t\t\t{\n\t\t\t\t\tpassword,\n\t\t\t\t\tpassword_confirmation\n\t\t\t\t})\n\t\tif (auth0_token_error) {\n\t\t\tthis.logout_auth0_token_error(auth0_token_error)\n\t\t\tthrow auth0_token_error\n\t\t}\n\t\treturn await this.change_password({ password }, schedule_forms_clear)\n\t}\n\treadonly onclose = async (event:MouseEvent)=>{\n\t\tevent.preventDefault()\n\t\tthis.close_auth0()\n\t}\n}\nfunction clear_inputs(inputs:NodeList) {\n\tfor (let i = 0; i < inputs.length; i++) {\n\t\tconst input = inputs[i] as HTMLInputElement\n\t\tinput.value = ''\n\t}\n}\nexport interface signup_data_password_realm_body_I\n\textends signup_data_I,\n\t\tauth0_client_id_body_I,\n\t\tpost_auth0_passwordless_start_body_T,\n\t\tpassword_realm_body_T,\n\t\tauth0_grant_type_body_I,\n\t\tpost_auth0_oauth_token_body_I {}\nexport interface login_data_password_realm_body_I\n\textends login_data_I,\n\t\tauth0_client_id_body_I,\n\t\tpost_auth0_passwordless_start_body_T,\n\t\tpassword_realm_body_T,\n\t\tauth0_grant_type_body_I,\n\t\tpost_auth0_oauth_token_body_I {}\nexport interface onsubmit_change_password_Ctx {\n\tpassword_input:HTMLInputElement\n\tpassword_confirmation_input:HTMLInputElement\n}\nexport interface onsubmit_forgot_password_Ctx {\n\temail_input:HTMLInputElement\n}\nexport interface onsubmit_login_Ctx {\n\tusername_login_input:HTMLInputElement\n\tpassword_login_input:HTMLInputElement\n}\nexport interface onsubmit_signup_Ctx {\n\temail_input:HTMLInputElement\n\tpassword_input:HTMLInputElement\n\tpassword_confirmation_input:HTMLInputElement\n}\n"],"names":["onDestroy","auth0_body__b","auth0_opened_class$_b","auth0_token_error$_b","auth0_token_json$_b","clear_auth0_token_error_b","close_auth0_b","logout_auth0_token_error_b","open_auth0_forgot_password_check_email_b","open_auth0_login_b","password_realm_body__b","post_auth0_auth_change_password_b","post_auth0_dbconnections_signup_b","post_auth0_oauth_token_b","post_auth0_passwordless_start_b","validate_auth0_change_password","validate_auth0_forgot_password","validate_auth0_signup","has_dom","dom_a_","noop","subscribe","Auth0_c","login_auth0_body_","ctx","login_password_realm_body_","signup_auth0_body_","signup_password_realm_body_","auth0_opened_class","auth0_token_json$","auth0_token_error","clear_auth0_token_error","close_auth0","logout_auth0_token_error","open_auth0_login","open_auth0_forgot_password_check_email","post_auth0_dbconnections_signup","post_auth0_oauth_token","post_auth0_auth_change_password","post_auth0_passwordless_start","onMount","root","unsubscribe","schedule_forms_clear","login","data","response","ok","auth0_token_json","text","$","$auth_token_error","json","signup","auth0_userinfo","statusCode","code","description","email","username","password","change_password","form","error","response_json","status","e","console","warn","message","schedule_forms_clear_","setTimeout","clear_inputs","onsubmit_signup","event","preventDefault","email_input","password_input","password_confirmation_input","value","password_confirmation","onsubmit_login","username_login_input","password_login_input","onsubmit_forgot_password","connection","send","onsubmit_change_password","onclose","inputs","i","length","input"],"mappings":"AAAA,MAAM,GAAGA,SAAS,QAAQ,CAAQ;AAQlC,MAAM,GACLC,aAAa,EAAEC,qBAAqB,EAAEC,oBAAoB,EAAEC,mBAAmB,EAAEC,yBAAyB,EAC1GC,aAAa,EAAEC,0BAA0B,EAAEC,wCAAwC,EAAEC,kBAAkB,EACvGC,sBAAsB,EAAEC,iCAAiC,EAAEC,iCAAiC,EAC5FC,wBAAwB,EAAEC,+BAA+B,EAAEC,8BAA8B,EACzFC,8BAA8B,EAAEC,qBAAqB,QAC/C,CAAiB;AACxB,MAAM,GAAGC,OAAO,EAAEC,MAAM,QAAQ,CAAe;AAC/C,MAAM,GAAGC,IAAI,QAAQ,CAAoB;AACzC,MAAM,GAAGC,SAAS,QAAQ,CAAiB;AAE3C,MAAM,OAAOC,OAAO;gBACG,IAAgB,CAAE,CAAC;aAAnB,GAAgB,GAAhB,IAAgB;QADhC,IAwMN,CAtMSC,iBAAiB,GAAGtB,aAAa,CAIvB,IAAI,CAACuB,GAAG,EAAE,CAAmB;QAN1C,IAwMN,CAjMSC,0BAA0B,GAAGf,sBAAsB,CAK3D,IAAI,CAACc,GAAG,EACR,CAA4B,6BAC5B,IAAI,CAACD,iBAAiB;QAdjB,IAwMN,CAxLSG,kBAAkB,GAAoDzB,aAAa,CAIzE,IAAI,CAACuB,GAAG,EAAE,CAAoB;QApB3C,IAwMN,CAnLSG,2BAA2B,GAA6DjB,sBAAsB,CAKtH,IAAI,CAACc,GAAG,EAAE,CAA+B,gCAAE,IAAI,CAACE,kBAAkB;QA1B7D,IAwMN,CA5KSE,kB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;YACrC,KAAK,CAACC,qBAAqB,GAAGF,2BAA2B,CAACC,KAAK;YAC/D,KAAK,CAACjD,iBAAiB,GACtBf,8BAA8B,CAC7B,CAAC;gBACA6C,QAAQ;gBACRoB,qBAAqB;YACtB,CAAC;YACH,EAAE,EAAElD,iBAAiB,EAAE,CAAC;gBACvB,IAAI,CAACG,wBAAwB,CAACH,iBAAiB;gBAC/C,KAAK,CAACA,iBAAiB;YACxB,CAAC;YACD,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC+B,eAAe,CAAC,CAAC;gBAACD,QAAQ;YAAC,CAAC,EAAEjB,oBAAoB;QACrE,CAAC;QAnMK,IAwMN,CAJS6C,OAAO,UAAUd,KAAgB,GAAG,CAAC;YAC7CA,KAAK,CAACC,cAAc;YACpB,IAAI,CAAC3C,WAAW;QACjB,CAAC;IAtMwC,CAAC;;SAwMlCwC,YAAY,CAACiB,MAAe,EAAE,CAAC;IACvC,GAAG,CAAE,GAAG,CAACC,CAAC,GAAG,CAAC,EAAEA,CAAC,GAAGD,MAAM,CAACE,MAAM,EAAED,CAAC,GAAI,CAAC;QACxC,KAAK,CAACE,KAAK,GAAGH,MAAM,CAACC,CAAC;QACtBE,KAAK,CAACb,KAAK,GAAG,CAAE;IACjB,CAAC;AACF,CAAC"}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../src/ui/index.ts"],"sourcesContent":["import 'svelte'\nexport * as Auth0 from './Auth0.svelte'\nexport * as Auth0_Dialog_Close from './Auth0_Dialog_Close.svelte'\nexport * as Auth0_Change_Password_Form from './Auth0_Change_Password_Form.svelte'\nexport * as Auth0_Forgot_Password_Check_Email_Form from './Auth0_Forgot_Password_Check_Email_Form.svelte'\nexport * as Auth0_Forgot_Password_Form from './Auth0_Forgot_Password_Form.svelte'\nexport * as Auth0_Login_Form from './Auth0_Login_Form.svelte'\nexport * as Auth0_Signup_Form from './Auth0_Signup_Form.svelte'\nexport * as Auth0_Loggedin_If from './Auth0_Loggedin_If.svelte'\n"],"names":["Auth0","Auth0_Dialog_Close","Auth0_Change_Password_Form","Auth0_Forgot_Password_Check_Email_Form","Auth0_Forgot_Password_Form","Auth0_Login_Form","Auth0_Signup_Form","Auth0_Loggedin_If"],"mappings":"AAAA,MAAM,CAAC,CAAQ;YACHA,MAAK,MAAM,CAAgB;YAC3BC,mBAAkB,MAAM,CAA6B;YACrDC,2BAA0B,MAAM,CAAqC;YACrEC,uCAAsC,MAAM,CAAiD;YAC7FC,2BAA0B,MAAM,CAAqC;YACrEC,iBAAgB,MAAM,CAA2B;YACjDC,kBAAiB,MAAM,CAA4B;YACnDC,kBAAiB,MAAM,CAA4B;SAPnDP,MAAK,IAALA,KAAK;SACLC,mBAAkB,IAAlBA,kBAAkB;SAClBC,2BAA0B,IAA1BA,0BAA0B;SAC1BC,uCAAsC,IAAtCA,sCAAsC;SACtCC,2BAA0B,IAA1BA,0BAA0B;SAC1BC,iBAAgB,IAAhBA,gBAAgB;SAChBC,kBAAiB,IAAjBA,iBAAiB;SACjBC,kBAAiB,IAAjBA,iBAAiB"}
@@ -1,11 +0,0 @@
1
- import type { auth0_body__T, auth0_Ctx, password_realm_body__T } from '@ctx-core/auth0'
2
- import type { auth0_ui_ctx_I } from './auth0_ui_ctx_I.generated.js'
3
- import type {
4
- login_data_password_realm_body_I, signup_data_password_realm_body_I
5
- } from './ui/Auth0_c.js'
6
- export interface auth0_ui_Ctx extends auth0_ui_ctx_I, auth0_Ctx {
7
- login_auth0_body_:auth0_body__T<login_data_password_realm_body_I>
8
- login_password_realm_body_:password_realm_body__T<login_data_password_realm_body_I>
9
- signup_auth0_body_:auth0_body__T<signup_data_password_realm_body_I>
10
- signup_password_realm_body_fn:password_realm_body__T<signup_data_password_realm_body_I>
11
- }
@@ -1,7 +0,0 @@
1
- /*
2
- * This file was generated by `npm run generate_ctx_I_file` in @ctx-core/dev-tools
3
- */
4
-
5
- export interface auth0_ui_ctx_I {
6
-
7
- }
@@ -1,14 +0,0 @@
1
- <script lang="ts">
2
- import { is_auth0_loggedin$_b, is_auth0_loggedout$_b, } from '@ctx-core/auth0'
3
- import type { auth0_ui_Ctx } from '../auth0_ui_Ctx.js'
4
- import { getContext_auth0_ui_ctx } from '../getContext_auth0_ui_ctx.js'
5
- const ctx = getContext_auth0_ui_ctx() as auth0_ui_Ctx
6
- const is_auth0_loggedin$ = is_auth0_loggedin$_b(ctx)
7
- const is_auth0_loggedout$ = is_auth0_loggedout$_b(ctx)
8
- </script>
9
-
10
- {#if $is_auth0_loggedin$}
11
- <slot name="loggedin"><slot></slot></slot>
12
- {:else if $is_auth0_loggedout$}
13
- <slot name="loggedout"></slot>
14
- {/if}