@descope/user-profile-widget 0.0.5 → 0.0.6

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.
package/dist/esm/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
 
2
2
  /**
3
- * @descope/user-profile-widget v0.0.5
3
+ * @descope/user-profile-widget v0.0.6
4
4
  */
5
5
  import{createSingletonMixin as t,compose as e,createTemplate as i,kebabCase as s,withMemCache as o}from"@descope/sdk-helpers";import{__awaiter as n,__classPrivateFieldGet as r,__classPrivateFieldSet as a}from"tslib";import{projectIdMixin as d,observeAttributesMixin as l,loggerMixin as h,createValidateAttributesMixin as c,createStateManagementMixin as u,initLifecycleMixin as f,staticResourcesMixin as g,descopeUiMixin as p,initElementMixin as v,modalMixin as m,debuggerMixin as w,themeMixin as b}from"@descope/sdk-mixins";import{FlowDriver as y,AvatarDriver as R,UserAttributeDriver as W,UserAuthMethodDriver as k,ButtonDriver as M}from"@descope/sdk-component-drivers";import{createSelector as U}from"reselect";import{createAsyncThunk as j}from"@reduxjs/toolkit";import I from"@descope/web-js-sdk";import"@descope/core-js-sdk";import"@descope/web-component";const S=t=>t.me.data,A=U(S,(t=>t.picture)),C=U(S,(t=>t.email)),x=U(S,(t=>t.verifiedEmail)),q=U(S,(t=>t.name)),O=U(S,(t=>t.phone)),E=U(S,(t=>t.verifiedPhone)),P=U(S,(t=>t.webauthn));U(S,(t=>t.password));const D=t=>(...e)=>i=>{i.addCase(t.pending,((t,i)=>{e.forEach((({onPending:e})=>{null==e||e(t,i)}))})),i.addCase(t.fulfilled,((t,i)=>{e.forEach((({onFulfilled:e})=>{null==e||e(t,i)}))})),i.addCase(t.rejected,((t,i)=>{e.forEach((({onRejected:e})=>{null==e||e(t,i)}))}))},F=j("users/me",((t,{extra:{api:e}})=>e.user.me())),T=D(F)({onFulfilled:(t,e)=>{t.me.data=e.payload}},(N=t=>t.me,{onFulfilled:t=>{N(t).loading=!1},onPending:t=>{N(t).loading=!0,N(t).error=null},onRejected:(t,e)=>{N(t).loading=!1,N(t).error=e.error}}));var N;const $={action:F,reducer:T},L=j("users/logout",((t,{extra:{api:e}})=>e.user.logout())),H={action:L,reducer:D(L)({})},B={me:{loading:!1,error:null,data:{}}},K={me:"/v1/auth/me"},J=()=>n(void 0,void 0,void 0,(function*(){return new Promise((t=>{t({loginIds:["user@company.com"],externalIds:["user@company.com"],userId:"user-1",name:"Test User",email:"user@company.com",roleNames:["Role"],phone:"+1-202-555-010",verifiedEmail:!0,verifiedPhone:!0,userTenants:[],status:"enabled",editable:!0,createdTime:(new Date).getTime(),customAttributes:{},familyName:"",givenName:"",middleName:"",picture:"https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcSzmudcbKkbOue75DaM9HDDrt0W39SJLBH-3HPK3s-K1w&s",password:!0,SAML:!1,test:!1,TOTP:!1,webauthn:!0})}))})),V=({httpClient:t,mock:e})=>({me:()=>n(void 0,void 0,void 0,(function*(){if(e)return J();const i=yield t.get(K.me);return yield(t=>n(void 0,void 0,void 0,(function*(){const e=yield t.text(),i=JSON.parse(e);if(!t.ok){const e=`${i.errorDescription}${i.errorMessage?`: ${i.errorMessage}`:""}`;throw Error(e||`${t.status} ${t.statusText}`)}t.json=()=>Promise.resolve(i),t.text=()=>Promise.resolve(e)})))(i),i.json()}))}),z=t((t=>{var i,s,o,u;const f=e(d,l,h,c({tenant:c.missingAttrValidator}))(t);return u=class extends f{constructor(){super(...arguments),i.add(this),s.set(this,void 0)}get baseUrl(){return this.getAttribute("base-url")}get tenant(){return this.getAttribute("tenant")}get mock(){return this.getAttribute("mock")}get api(){return r(this,s,"f")||r(this,i,"m",o).call(this),r(this,s,"f")}init(){const t=Object.create(null,{init:{get:()=>super.init}});var e;return n(this,void 0,void 0,(function*(){yield null===(e=t.init)||void 0===e?void 0:e.call(this),this.observeAttributes(["project-id","base-url","tenant"],(()=>{r(this,s,"f")&&r(this,i,"m",o).call(this)}))}))}},s=new WeakMap,i=new WeakSet,o=function(){this.logger.debug("creating an sdk instance"),a(this,s,((t,e,i)=>{const s=I(Object.assign(Object.assign({},t),{persistTokens:!0}));return{user:Object.assign(Object.assign({},V({httpClient:s.httpClient,tenant:e,mock:i})),{logout:i?()=>n(void 0,void 0,void 0,(function*(){})):s.logout})}})({projectId:this.projectId,baseUrl:this.baseUrl},this.tenant,"true"===this.mock),"f")},u})),G=t((t=>{const i=e(u({name:"widget",initialState:B,reducers:{},extraReducers:t=>{$.reducer(t),H.reducer(t)},asyncActions:{getMe:$.action,logout:H.action}}),f,h,z)(t);return class extends i{constructor(...t){super(...t),this.state=B,this.subscribe((t=>{this.logger.debug("State update:",t),this.state=t}))}}})),Q=t((t=>{const i=e(g,c({"widget-id":c.missingAttrValidator}))(t);return class extends i{get widgetId(){return this.getAttribute("widget-id")}fetchWidgetPage(t){return n(this,void 0,void 0,(function*(){return(yield this.fetchStaticResource(`user-profile-widget/${this.widgetId}/${t}`,"text")).body}))}}})),X=t((t=>{var s,o,a;return a=class extends(e(h,f,p,v,Q,G)(t)){constructor(){super(...arguments),s.add(this)}onWidgetRootReady(){return n(this,void 0,void 0,(function*(){}))}init(){const t=Object.create(null,{init:{get:()=>super.init}});var e;return n(this,void 0,void 0,(function*(){yield null===(e=t.init)||void 0===e?void 0:e.call(this),yield Promise.all([this.actions.getMe(),r(this,s,"m",o).call(this)]),this.onWidgetRootReady()}))}},s=new WeakSet,o=function(){return n(this,void 0,void 0,(function*(){const t=i(yield this.fetchWidgetPage("root.html"));yield this.loadDescopeUiComponents(t),this.contentRootElement.append(t.content.cloneNode(!0))}))},a})),Y=(t={})=>{const e=i("<descope-wc></descope-wc>");return Object.entries(t).forEach((([t,i])=>{e.content.querySelector("descope-wc").setAttribute(s(t),i)})),e},Z=t((t=>{var i,s,d,l,c,u,f,g,p;return p=class extends(e(G,h,X,m)(t)){constructor(){super(...arguments),i.add(this),s.set(this,void 0),d.set(this,void 0),f.set(this,o((t=>{this.avatar.image=t}))),g.set(this,o((t=>{this.avatar.displayName=t})))}onWidgetRootReady(){const t=Object.create(null,{onWidgetRootReady:{get:()=>super.onWidgetRootReady}});var e;return n(this,void 0,void 0,(function*(){yield null===(e=t.onWidgetRootReady)||void 0===e?void 0:e.call(this),r(this,i,"m",u).call(this),r(this,i,"m",l).call(this),r(this,f,"f").call(this,A(this.state)),r(this,g,"f").call(this,q(this.state)),this.subscribe(r(this,f,"f").bind(this),A),this.subscribe(r(this,g,"f").bind(this),q)}))}},s=new WeakMap,d=new WeakMap,f=new WeakMap,g=new WeakMap,i=new WeakSet,l=function(){a(this,s,this.createModal({"data-id":"update-pic"}),"f"),a(this,d,new y((()=>{var t;return null===(t=r(this,s,"f").ele)||void 0===t?void 0:t.querySelector("descope-wc")}),{logger:this.logger}),"f"),r(this,s,"f").afterClose=r(this,i,"m",c).bind(this),r(this,i,"m",c).call(this)},c=function(){r(this,s,"f").setContent(Y({projectId:this.projectId,flowId:this.avatar.flowId,baseUrl:this.baseUrl})),r(this,d,"f").onSuccess((()=>{r(this,s,"f").close(),this.actions.getMe()}))},u=function(){this.avatar=new R((()=>{var t;return null===(t=this.shadowRoot)||void 0===t?void 0:t.querySelector("descope-avatar")}),{logger:this.logger}),this.avatar.onClick((()=>{r(this,s,"f").open()}))},p})),_=t((t=>{var i,s,d,l,c,u,f,g,p,v,w,b,R;return R=class extends(e(G,h,X,m)(t)){constructor(){super(...arguments),i.add(this),s.set(this,void 0),d.set(this,void 0),l.set(this,void 0),c.set(this,void 0),w.set(this,o((t=>{this.emailUserAttr.value=t}))),b.set(this,o((t=>{this.emailUserAttr.badgeLabel=t?"":"Unverified"})))}onWidgetRootReady(){const t=Object.create(null,{onWidgetRootReady:{get:()=>super.onWidgetRootReady}});var e;return n(this,void 0,void 0,(function*(){yield null===(e=t.onWidgetRootReady)||void 0===e?void 0:e.call(this),r(this,i,"m",v).call(this),r(this,i,"m",u).call(this),r(this,i,"m",g).call(this),r(this,w,"f").call(this,C(this.state)),r(this,b,"f").call(this,x(this.state)),this.subscribe(r(this,w,"f").bind(this),C),this.subscribe(r(this,b,"f").bind(this),x)}))}},s=new WeakMap,d=new WeakMap,l=new WeakMap,c=new WeakMap,w=new WeakMap,b=new WeakMap,i=new WeakSet,u=function(){a(this,s,this.createModal({"data-id":"edit-email"}),"f"),a(this,d,new y((()=>{var t;return null===(t=r(this,s,"f").ele)||void 0===t?void 0:t.querySelector("descope-wc")}),{logger:this.logger}),"f"),r(this,s,"f").afterClose=r(this,i,"m",f).bind(this),r(this,i,"m",f).call(this)},f=function(){r(this,s,"f").setContent(Y({projectId:this.projectId,flowId:this.emailUserAttr.editFlowId,baseUrl:this.baseUrl})),r(this,d,"f").onSuccess((()=>{r(this,s,"f").close(),this.actions.getMe()}))},g=function(){a(this,l,this.createModal({"data-id":"delete-email"}),"f"),a(this,c,new y((()=>{var t;return null===(t=r(this,l,"f").ele)||void 0===t?void 0:t.querySelector("descope-wc")}),{logger:this.logger}),"f"),r(this,l,"f").afterClose=r(this,i,"m",p).bind(this),r(this,i,"m",p).call(this)},p=function(){r(this,l,"f").setContent(Y({projectId:this.projectId,flowId:this.emailUserAttr.deleteFlowId,baseUrl:this.baseUrl})),r(this,c,"f").onSuccess((()=>{r(this,l,"f").close(),this.actions.getMe()}))},v=function(){this.emailUserAttr=new W((()=>{var t;return null===(t=this.shadowRoot)||void 0===t?void 0:t.querySelector('descope-user-attribute[data-id="email"]')}),{logger:this.logger}),this.emailUserAttr.onEditClick((()=>{r(this,s,"f").open()})),this.emailUserAttr.onDeleteClick((()=>{r(this,l,"f").open()}))},R})),tt=t((t=>{var i,s,d,l,c,u,f,g,p,v,w,b;return b=class extends(e(G,h,X,m)(t)){constructor(){super(...arguments),i.add(this),s.set(this,void 0),d.set(this,void 0),l.set(this,void 0),c.set(this,void 0),w.set(this,o((t=>{this.nameUserAttr.value=t})))}onWidgetRootReady(){const t=Object.create(null,{onWidgetRootReady:{get:()=>super.onWidgetRootReady}});var e;return n(this,void 0,void 0,(function*(){yield null===(e=t.onWidgetRootReady)||void 0===e?void 0:e.call(this),r(this,i,"m",v).call(this),r(this,i,"m",u).call(this),r(this,i,"m",g).call(this),r(this,w,"f").call(this,q(this.state)),this.subscribe(r(this,w,"f").bind(this),q)}))}},s=new WeakMap,d=new WeakMap,l=new WeakMap,c=new WeakMap,w=new WeakMap,i=new WeakSet,u=function(){a(this,s,this.createModal({"data-id":"edit-name"}),"f"),a(this,d,new y((()=>{var t;return null===(t=r(this,s,"f").ele)||void 0===t?void 0:t.querySelector("descope-wc")}),{logger:this.logger}),"f"),r(this,s,"f").afterClose=r(this,i,"m",f).bind(this),r(this,i,"m",f).call(this)},f=function(){r(this,s,"f").setContent(Y({projectId:this.projectId,flowId:this.nameUserAttr.editFlowId,baseUrl:this.baseUrl})),r(this,d,"f").onSuccess((()=>{r(this,s,"f").close(),this.actions.getMe()}))},g=function(){a(this,l,this.createModal({"data-id":"delete-name"}),"f"),a(this,c,new y((()=>{var t;return null===(t=r(this,l,"f").ele)||void 0===t?void 0:t.querySelector("descope-wc")}),{logger:this.logger}),"f"),r(this,l,"f").afterClose=r(this,i,"m",p).bind(this),r(this,i,"m",p).call(this)},p=function(){r(this,l,"f").setContent(Y({projectId:this.projectId,flowId:this.nameUserAttr.deleteFlowId,baseUrl:this.baseUrl})),r(this,c,"f").onSuccess((()=>{r(this,l,"f").close(),this.actions.getMe()}))},v=function(){this.nameUserAttr=new W((()=>{var t;return null===(t=this.shadowRoot)||void 0===t?void 0:t.querySelector('descope-user-attribute[data-id="name"]')}),{logger:this.logger}),this.nameUserAttr.onEditClick((()=>{r(this,s,"f").open()})),this.nameUserAttr.onDeleteClick((()=>{r(this,l,"f").open()}))},b})),et=t((t=>{var i,s,d,l,c,u,f,g,p,v,w,b,R;return R=class extends(e(G,h,X,m)(t)){constructor(){super(...arguments),i.add(this),s.set(this,void 0),d.set(this,void 0),l.set(this,void 0),c.set(this,void 0),w.set(this,o((t=>{this.phoneUserAttr.value=t}))),b.set(this,o((t=>{this.phoneUserAttr.badgeLabel=t?"":"Unverified"})))}onWidgetRootReady(){const t=Object.create(null,{onWidgetRootReady:{get:()=>super.onWidgetRootReady}});var e;return n(this,void 0,void 0,(function*(){yield null===(e=t.onWidgetRootReady)||void 0===e?void 0:e.call(this),r(this,i,"m",v).call(this),r(this,i,"m",u).call(this),r(this,i,"m",g).call(this),r(this,w,"f").call(this,O(this.state)),r(this,b,"f").call(this,E(this.state)),this.subscribe(r(this,w,"f").bind(this),O),this.subscribe(r(this,b,"f").bind(this),E)}))}},s=new WeakMap,d=new WeakMap,l=new WeakMap,c=new WeakMap,w=new WeakMap,b=new WeakMap,i=new WeakSet,u=function(){a(this,s,this.createModal({"data-id":"edit-phone"}),"f"),a(this,d,new y((()=>{var t;return null===(t=r(this,s,"f").ele)||void 0===t?void 0:t.querySelector("descope-wc")}),{logger:this.logger}),"f"),r(this,s,"f").afterClose=r(this,i,"m",f).bind(this),r(this,i,"m",f).call(this)},f=function(){r(this,s,"f").setContent(Y({projectId:this.projectId,flowId:this.phoneUserAttr.editFlowId,baseUrl:this.baseUrl})),r(this,d,"f").onSuccess((()=>{r(this,s,"f").close(),this.actions.getMe()}))},g=function(){a(this,l,this.createModal({"data-id":"delete-phone"}),"f"),a(this,c,new y((()=>{var t;return null===(t=r(this,l,"f").ele)||void 0===t?void 0:t.querySelector("descope-wc")}),{logger:this.logger}),"f"),r(this,l,"f").afterClose=r(this,i,"m",p).bind(this),r(this,i,"m",p).call(this)},p=function(){r(this,l,"f").setContent(Y({projectId:this.projectId,flowId:this.phoneUserAttr.deleteFlowId,baseUrl:this.baseUrl})),r(this,c,"f").onSuccess((()=>{r(this,l,"f").close(),this.actions.getMe()}))},v=function(){this.phoneUserAttr=new W((()=>{var t;return null===(t=this.shadowRoot)||void 0===t?void 0:t.querySelector('descope-user-attribute[data-id="phone"]')}),{logger:this.logger}),this.phoneUserAttr.onEditClick((()=>{r(this,s,"f").open()})),this.phoneUserAttr.onDeleteClick((()=>{r(this,l,"f").open()}))},R})),it=t((t=>{var i,s,d,l,c,u,f,g;return g=class extends(e(G,h,X,m)(t)){constructor(){super(...arguments),i.add(this),s.set(this,void 0),d.set(this,void 0),f.set(this,o((t=>{this.passkeyUserAuthMethod.fulfilled=t})))}onWidgetRootReady(){const t=Object.create(null,{onWidgetRootReady:{get:()=>super.onWidgetRootReady}});var e;return n(this,void 0,void 0,(function*(){yield null===(e=t.onWidgetRootReady)||void 0===e?void 0:e.call(this),r(this,i,"m",u).call(this),r(this,i,"m",l).call(this),r(this,f,"f").call(this,P(this.state)),this.subscribe(r(this,f,"f").bind(this),P)}))}},s=new WeakMap,d=new WeakMap,f=new WeakMap,i=new WeakSet,l=function(){a(this,s,this.createModal({"data-id":"passkey"}),"f"),a(this,d,new y((()=>{var t;return null===(t=r(this,s,"f").ele)||void 0===t?void 0:t.querySelector("descope-wc")}),{logger:this.logger}),"f"),r(this,s,"f").afterClose=r(this,i,"m",c).bind(this),r(this,i,"m",c).call(this)},c=function(){r(this,s,"f").setContent(Y({projectId:this.projectId,flowId:this.passkeyUserAuthMethod.flowId,baseUrl:this.baseUrl})),r(this,d,"f").onSuccess((()=>{r(this,s,"f").close(),this.actions.getMe()}))},u=function(){this.passkeyUserAuthMethod=new k((()=>{var t;return null===(t=this.shadowRoot)||void 0===t?void 0:t.querySelector('descope-user-auth-method[data-id="passkey"]')}),{logger:this.logger}),this.passkeyUserAuthMethod.onButtonClick((()=>{r(this,s,"f").open()}))},g})),st=t((t=>{var i,s,o,d,l,c,u;return u=class extends(e(G,h,X,m)(t)){constructor(){super(...arguments),i.add(this),s.set(this,void 0),o.set(this,void 0)}onWidgetRootReady(){const t=Object.create(null,{onWidgetRootReady:{get:()=>super.onWidgetRootReady}});var e;return n(this,void 0,void 0,(function*(){yield null===(e=t.onWidgetRootReady)||void 0===e?void 0:e.call(this),r(this,i,"m",c).call(this),r(this,i,"m",d).call(this)}))}},s=new WeakMap,o=new WeakMap,i=new WeakSet,d=function(){a(this,s,this.createModal({"data-id":"password"}),"f"),a(this,o,new y((()=>{var t;return null===(t=r(this,s,"f").ele)||void 0===t?void 0:t.querySelector("descope-wc")}),{logger:this.logger}),"f"),r(this,s,"f").afterClose=r(this,i,"m",l).bind(this),r(this,i,"m",l).call(this)},l=function(){r(this,s,"f").setContent(Y({projectId:this.projectId,flowId:this.passwordUserAuthMethod.flowId,baseUrl:this.baseUrl})),r(this,o,"f").onSuccess((()=>{r(this,s,"f").close()}))},c=function(){this.passwordUserAuthMethod=new k((()=>{var t;return null===(t=this.shadowRoot)||void 0===t?void 0:t.querySelector('descope-user-auth-method[data-id="password"]')}),{logger:this.logger}),this.passwordUserAuthMethod.onButtonClick((()=>{r(this,s,"f").open()}))},u})),ot=t((t=>{var i,s,o;return o=class extends(e(G,h,X,m)(t)){constructor(){super(...arguments),i.add(this)}onWidgetRootReady(){const t=Object.create(null,{onWidgetRootReady:{get:()=>super.onWidgetRootReady}});var e;return n(this,void 0,void 0,(function*(){yield null===(e=t.onWidgetRootReady)||void 0===e?void 0:e.call(this),r(this,i,"m",s).call(this)}))}},i=new WeakSet,s=function(){this.logout=new M((()=>{var t;return null===(t=this.shadowRoot)||void 0===t?void 0:t.querySelector('descope-button[data-id="logout"]')}),{logger:this.logger}),this.logout.onClick((()=>n(this,void 0,void 0,(function*(){yield this.actions.logout(),this.dispatchEvent(new CustomEvent("logout"))}))))},o})),nt=t((t=>class extends(e(w,b,Z,_,tt,et,it,st,ot)(t)){init(){const t=Object.create(null,{init:{get:()=>super.init}});var e;return n(this,void 0,void 0,(function*(){yield null===(e=t.init)||void 0===e?void 0:e.call(this)}))}})),rt=e((t=>class extends(nt(t)){}))(HTMLElement);customElements.define("descope-user-profile-widget",rt);export{rt as default};
6
6
  //# sourceMappingURL=index.js.map
package/dist/index.d.ts CHANGED
@@ -18,7 +18,7 @@ declare const UserProfileWidget: {
18
18
  logout: _descope_sdk_component_drivers.ButtonDriver;
19
19
  "__#13@#initLogout"(): void;
20
20
  onWidgetRootReady: (() => Promise<void>) & (() => Promise<void>) & (() => Promise<void>) & (() => Promise<void>) & (() => Promise<void>) & (() => Promise<void>) & (() => Promise<void>);
21
- "__#12030@#ModalDriverWrapper": new (refOrRefFn: Element | (() => HTMLElement), config: {
21
+ "__#12031@#ModalDriverWrapper": new (refOrRefFn: Element | (() => HTMLElement), config: {
22
22
  logger: {
23
23
  error(...data: any[]): void;
24
24
  warn(...data: any[]): void;
@@ -27,7 +27,7 @@ declare const UserProfileWidget: {
27
27
  };
28
28
  }) => {
29
29
  setContent(template: HTMLTemplateElement): void;
30
- "__#12029@#private": any;
30
+ "__#12030@#private": any;
31
31
  beforeOpen: () => void | Promise<void>;
32
32
  afterClose: () => void;
33
33
  nodeName: string;
@@ -35,7 +35,7 @@ declare const UserProfileWidget: {
35
35
  open(): Promise<void>;
36
36
  reset(): void;
37
37
  remove(): void;
38
- "__#12027@#private": any;
38
+ "__#12028@#private": any;
39
39
  logger: {
40
40
  error(...data: any[]): void;
41
41
  warn(...data: any[]): void;
@@ -46,21 +46,21 @@ declare const UserProfileWidget: {
46
46
  readonly ele: Element;
47
47
  };
48
48
  createModal(config?: Record<string, string>): _descope_sdk_component_drivers.ModalDriver;
49
- "__#12026@#errorCbsSym": symbol;
50
- "__#12026@#loadCbsSym": symbol;
51
- "__#12026@#getComponentsVersion": (() => Promise<any>) & (() => Promise<any>) & (() => Promise<any>);
52
- "__#12026@#exposeAlternateEvents": ((scriptEle: HTMLScriptElement) => void) & ((scriptEle: HTMLScriptElement) => void) & ((scriptEle: HTMLScriptElement) => void);
53
- "__#12026@#handleFallbackScript": ((errorCbs: ((error: string) => void)[], loadCbs: (() => void)[]) => Promise<void>) & ((errorCbs: ((error: string) => void)[], loadCbs: (() => void)[]) => Promise<void>) & ((errorCbs: ((error: string) => void)[], loadCbs: (() => void)[]) => Promise<void>);
54
- "__#12026@#registerEvents": ((scriptEle: HTMLScriptElement) => void) & ((scriptEle: HTMLScriptElement) => void) & ((scriptEle: HTMLScriptElement) => void);
55
- "__#12026@#getDescopeUiLoadingScript": (() => Promise<HTMLElement>) & (() => Promise<HTMLElement>) & (() => Promise<HTMLElement>);
56
- "__#12026@#descopeUi": Promise<any>;
49
+ "__#12027@#errorCbsSym": symbol;
50
+ "__#12027@#loadCbsSym": symbol;
51
+ "__#12027@#getComponentsVersion": (() => Promise<any>) & (() => Promise<any>) & (() => Promise<any>);
52
+ "__#12027@#exposeAlternateEvents": ((scriptEle: HTMLScriptElement) => void) & ((scriptEle: HTMLScriptElement) => void) & ((scriptEle: HTMLScriptElement) => void);
53
+ "__#12027@#handleFallbackScript": ((errorCbs: ((error: string) => void)[], loadCbs: (() => void)[]) => Promise<void>) & ((errorCbs: ((error: string) => void)[], loadCbs: (() => void)[]) => Promise<void>) & ((errorCbs: ((error: string) => void)[], loadCbs: (() => void)[]) => Promise<void>);
54
+ "__#12027@#registerEvents": ((scriptEle: HTMLScriptElement) => void) & ((scriptEle: HTMLScriptElement) => void) & ((scriptEle: HTMLScriptElement) => void);
55
+ "__#12027@#getDescopeUiLoadingScript": (() => Promise<HTMLElement>) & (() => Promise<HTMLElement>) & (() => Promise<HTMLElement>);
56
+ "__#12027@#descopeUi": Promise<any>;
57
57
  readonly descopeUi: Promise<any>;
58
- "__#12026@#loadDescopeUiComponent": ((componentName: string) => Promise<any>) & ((componentName: string) => Promise<any>) & ((componentName: string) => Promise<any>);
58
+ "__#12027@#loadDescopeUiComponent": ((componentName: string) => Promise<any>) & ((componentName: string) => Promise<any>) & ((componentName: string) => Promise<any>);
59
59
  loadDescopeUiComponents: ((templateOrComponentNames: string[] | HTMLTemplateElement) => Promise<any[]>) & ((templateOrComponentNames: string[] | HTMLTemplateElement) => Promise<any[]>) & ((templateOrComponentNames: string[] | HTMLTemplateElement) => Promise<any[]>);
60
- "__#12026@#getDescopeUi": (() => Promise<unknown>) & (() => Promise<unknown>) & (() => Promise<unknown>);
60
+ "__#12027@#getDescopeUi": (() => Promise<unknown>) & (() => Promise<unknown>) & (() => Promise<unknown>);
61
61
  readonly config: any;
62
- "__#12023@#_configResource": any;
63
- "__#12023@#fetchConfig": (() => Promise<{
62
+ "__#12024@#_configResource": any;
63
+ "__#12024@#fetchConfig": (() => Promise<{
64
64
  projectConfig: _descope_sdk_mixins.ProjectConfiguration;
65
65
  executionContext: {
66
66
  geo: string;
@@ -101,11 +101,11 @@ declare const UserProfileWidget: {
101
101
  headers: Record<string, string>;
102
102
  }>);
103
103
  readonly projectId: string;
104
- "__#12022@#handleError": ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void);
105
- "__#12021@#observeMappings": {};
104
+ "__#12023@#handleError": ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void) & ((attrName: string, newValue: string) => void);
105
+ "__#12022@#observeMappings": {};
106
106
  observeAttribute: ((attrName: string, onAttrChange: (attrName: string, value: string) => void) => () => any) & ((attrName: string, onAttrChange: (attrName: string, value: string) => void) => () => any) & ((attrName: string, onAttrChange: (attrName: string, value: string) => void) => () => any) & ((attrName: string, onAttrChange: (attrName: string, value: string) => void) => () => any) & ((attrName: string, onAttrChange: (attrName: string, value: string) => void) => () => any) & ((attrName: string, onAttrChange: (attrName: string, value: string) => void) => () => any) & ((attrName: string, onAttrChange: (attrName: string, value: string) => void) => () => any) & ((attrName: string, onAttrChange: (attrName: string, value: string) => void) => () => any) & ((attrName: string, onAttrChange: (attrName: string, value: string) => void) => () => any) & ((attrName: string, onAttrChange: (attrName: string, value: string) => void) => () => any) & ((attrName: string, onAttrChange: (attrName: string, value: string) => void) => () => any);
107
107
  observeAttributes: ((attrs: string[], cb: (attrName: string, value: string) => void) => () => void) & ((attrs: string[], cb: (attrName: string, value: string) => void) => () => void) & ((attrs: string[], cb: (attrName: string, value: string) => void) => () => void) & ((attrs: string[], cb: (attrName: string, value: string) => void) => () => void) & ((attrs: string[], cb: (attrName: string, value: string) => void) => () => void) & ((attrs: string[], cb: (attrName: string, value: string) => void) => () => void) & ((attrs: string[], cb: (attrName: string, value: string) => void) => () => void) & ((attrs: string[], cb: (attrName: string, value: string) => void) => () => void) & ((attrs: string[], cb: (attrName: string, value: string) => void) => () => void) & ((attrs: string[], cb: (attrName: string, value: string) => void) => () => void) & ((attrs: string[], cb: (attrName: string, value: string) => void) => () => void);
108
- "__#12020@#isInit": boolean;
108
+ "__#12021@#isInit": boolean;
109
109
  connectedCallback: (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & {
110
110
  (): void;
111
111
  (): void;
@@ -862,13 +862,13 @@ declare const UserProfileWidget: {
862
862
  tabIndex: number;
863
863
  blur: (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void);
864
864
  focus: ((options?: FocusOptions) => void) & ((options?: FocusOptions) => void) & ((options?: FocusOptions) => void) & ((options?: FocusOptions) => void) & ((options?: FocusOptions) => void) & ((options?: FocusOptions) => void) & ((options?: FocusOptions) => void) & ((options?: FocusOptions) => void) & ((options?: FocusOptions) => void) & ((options?: FocusOptions) => void) & ((options?: FocusOptions) => void) & ((options?: FocusOptions) => void) & ((options?: FocusOptions) => void);
865
- "__#12019@#logger": {
865
+ "__#12020@#logger": {
866
866
  error(...data: any[]): void;
867
867
  warn(...data: any[]): void;
868
868
  info(...data: any[]): void;
869
869
  debug(...data: any[]): void;
870
870
  };
871
- "__#12019@#wrapLogger": ((logger: Partial<{
871
+ "__#12020@#wrapLogger": ((logger: Partial<{
872
872
  error(...data: any[]): void;
873
873
  warn(...data: any[]): void;
874
874
  info(...data: any[]): void;
@@ -1767,14 +1767,14 @@ declare const UserProfileWidget: {
1767
1767
  "__#7@#onPictureUpdate": (picture: any) => void;
1768
1768
  "__#7@#onNameUpdate": (name: any) => void;
1769
1769
  readonly theme: _descope_sdk_mixins.ThemeOptions;
1770
- "__#12032@#_themeResource": Promise<void | Record<string, any>>;
1771
- "__#12032@#fetchTheme"(): Promise<Record<string, any>>;
1772
- readonly "__#12032@#themeResource": Promise<void | Record<string, any>>;
1773
- "__#12032@#loadGlobalStyle"(): Promise<void>;
1774
- "__#12032@#loadComponentsStyle"(): Promise<void>;
1775
- "__#12032@#loadFonts"(): Promise<void>;
1776
- "__#12032@#applyTheme"(): Promise<void>;
1777
- "__#12025@#debuggerEle": HTMLElement & {
1770
+ "__#12033@#_themeResource": Promise<void | Record<string, any>>;
1771
+ "__#12033@#fetchTheme"(): Promise<Record<string, any>>;
1772
+ readonly "__#12033@#themeResource": Promise<void | Record<string, any>>;
1773
+ "__#12033@#loadGlobalStyle"(): Promise<void>;
1774
+ "__#12033@#loadComponentsStyle"(): Promise<void>;
1775
+ "__#12033@#loadFonts"(): Promise<void>;
1776
+ "__#12033@#applyTheme"(): Promise<void>;
1777
+ "__#12026@#debuggerEle": HTMLElement & {
1778
1778
  updateData: (data: {
1779
1779
  title: string;
1780
1780
  description?: string;
@@ -1783,11 +1783,11 @@ declare const UserProfileWidget: {
1783
1783
  description?: string;
1784
1784
  }[]) => void;
1785
1785
  };
1786
- "__#12025@#disableDebugger"(): void;
1787
- "__#12025@#enableDebugger"(): Promise<void>;
1786
+ "__#12026@#disableDebugger"(): void;
1787
+ "__#12026@#enableDebugger"(): Promise<void>;
1788
1788
  readonly debug: boolean;
1789
- "__#12025@#handleDebugMode"(): void;
1790
- "__#12025@#updateDebuggerMessages"(title: string, description: string): void;
1789
+ "__#12026@#handleDebugMode"(): void;
1790
+ "__#12026@#updateDebuggerMessages"(title: string, description: string): void;
1791
1791
  };
1792
1792
  };
1793
1793