@descope/web-component 3.36.1 → 3.37.0
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/cjs/descope-wc/BaseDescopeWc.js +1 -1
- package/dist/cjs/descope-wc/DescopeWc.js +1 -1
- package/dist/cjs/descope-wc/DescopeWc.js.map +1 -1
- package/dist/cjs/helpers/conditions.js +1 -1
- package/dist/cjs/helpers/conditions.js.map +1 -1
- package/dist/cjs/helpers/templates.js +1 -1
- package/dist/cjs/helpers/templates.js.map +1 -1
- package/dist/cjs/types.js.map +1 -1
- package/dist/esm/descope-wc/BaseDescopeWc.js +1 -1
- package/dist/esm/descope-wc/DescopeWc.js +1 -1
- package/dist/esm/descope-wc/DescopeWc.js.map +1 -1
- package/dist/esm/helpers/conditions.js +1 -1
- package/dist/esm/helpers/conditions.js.map +1 -1
- package/dist/esm/helpers/templates.js +1 -1
- package/dist/esm/helpers/templates.js.map +1 -1
- package/dist/esm/types.js.map +1 -1
- package/dist/index.d.ts +50 -43
- package/dist/index.js +2 -2
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -4,7 +4,12 @@ import * as _descope_sdk_mixins_static_resources_mixin from '@descope/sdk-mixins
|
|
|
4
4
|
type SdkConfig = Parameters<typeof createSdk>[0];
|
|
5
5
|
type Sdk = ReturnType<typeof createSdk>;
|
|
6
6
|
type SdkFlowNext = Sdk['flow']['next'];
|
|
7
|
-
type
|
|
7
|
+
type ComponentsDynamicAttrs = {
|
|
8
|
+
attributes: Record<string, any>;
|
|
9
|
+
};
|
|
10
|
+
type ComponentsConfig = Record<string, any> & {
|
|
11
|
+
componentsDynamicAttrs?: Record<string, ComponentsDynamicAttrs>;
|
|
12
|
+
};
|
|
8
13
|
type CssVars = Record<string, any>;
|
|
9
14
|
type KeepArgsByIndex<F, Indices extends readonly number[]> = F extends (...args: infer A) => infer R ? (...args: PickArgsByIndex<A, Indices>) => R : never;
|
|
10
15
|
type PickArgsByIndex<All extends readonly any[], Indices extends readonly number[]> = {
|
|
@@ -124,6 +129,7 @@ interface ClientConditionResult {
|
|
|
124
129
|
screenId: string;
|
|
125
130
|
screenName: string;
|
|
126
131
|
clientScripts?: ClientScript[];
|
|
132
|
+
componentsConfig?: ComponentsConfig;
|
|
127
133
|
interactionId: string;
|
|
128
134
|
}
|
|
129
135
|
interface ClientCondition {
|
|
@@ -166,6 +172,7 @@ type FlowConfig = {
|
|
|
166
172
|
}
|
|
167
173
|
];
|
|
168
174
|
clientScripts?: ClientScript[];
|
|
175
|
+
componentsConfig?: ComponentsConfig;
|
|
169
176
|
};
|
|
170
177
|
interface ProjectConfiguration {
|
|
171
178
|
componentsVersion: string;
|
|
@@ -530,9 +537,9 @@ declare const BaseClass: {
|
|
|
530
537
|
focus(options?: FocusOptions): void;
|
|
531
538
|
};
|
|
532
539
|
} & (new (...params: any[]) => {
|
|
533
|
-
"__#
|
|
534
|
-
"__#
|
|
535
|
-
"__#
|
|
540
|
+
"__#27159@#lastBaseUrl"?: string;
|
|
541
|
+
"__#27159@#workingBaseUrl"?: string;
|
|
542
|
+
"__#27159@#getResourceUrls"(filename: string): (URL & {
|
|
536
543
|
baseUrl: string;
|
|
537
544
|
}) | (URL & {
|
|
538
545
|
baseUrl: string;
|
|
@@ -870,39 +877,39 @@ declare const BaseClass: {
|
|
|
870
877
|
blur(): void;
|
|
871
878
|
focus(options?: FocusOptions): void;
|
|
872
879
|
readonly projectId: string;
|
|
873
|
-
"__#
|
|
880
|
+
"__#27158@#handleError"(attrName: string, newValue: string): void;
|
|
874
881
|
init(): Promise<void>;
|
|
875
|
-
"__#
|
|
882
|
+
"__#27157@#observeMappings": {};
|
|
876
883
|
observeAttribute(attrName: string, onAttrChange: (attrName: string, value: string) => void): () => any;
|
|
877
884
|
observeAttributes(attrs: string[], cb: (attrName: string, value: string) => void): () => void;
|
|
878
|
-
"__#
|
|
879
|
-
"__#
|
|
880
|
-
"__#
|
|
885
|
+
"__#27156@#isInit": boolean;
|
|
886
|
+
"__#27155@#logger": _descope_sdk_mixins_static_resources_mixin.Logger;
|
|
887
|
+
"__#27155@#wrapLogger": ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger);
|
|
881
888
|
get logger(): _descope_sdk_mixins_static_resources_mixin.Logger;
|
|
882
889
|
set logger(logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>);
|
|
883
890
|
onLogEvent: ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void);
|
|
884
891
|
}) & (new (...params: any[]) => {
|
|
885
|
-
"__#
|
|
892
|
+
"__#27170@#globalStyleTag": HTMLStyleElement;
|
|
886
893
|
readonly theme: _descope_sdk_mixins_static_resources_mixin.ThemeOptions;
|
|
887
894
|
readonly styleId: string;
|
|
888
|
-
"__#
|
|
889
|
-
"__#
|
|
890
|
-
readonly "__#
|
|
891
|
-
"__#
|
|
892
|
-
"__#
|
|
893
|
-
"__#
|
|
895
|
+
"__#27170@#_themeResource": Promise<void | Record<string, any>>;
|
|
896
|
+
"__#27170@#fetchTheme"(): Promise<Record<string, any>>;
|
|
897
|
+
readonly "__#27170@#themeResource": Promise<void | Record<string, any>>;
|
|
898
|
+
"__#27170@#loadGlobalStyle"(): Promise<void>;
|
|
899
|
+
"__#27170@#loadComponentsStyle"(): Promise<void>;
|
|
900
|
+
"__#27170@#getFontsConfig"(): Promise<Record<string, {
|
|
894
901
|
url?: string;
|
|
895
902
|
}>>;
|
|
896
|
-
"__#
|
|
897
|
-
"__#
|
|
898
|
-
"__#
|
|
899
|
-
"__#
|
|
900
|
-
"__#
|
|
903
|
+
"__#27170@#loadFonts"(): Promise<void>;
|
|
904
|
+
"__#27170@#applyTheme"(): Promise<void>;
|
|
905
|
+
"__#27170@#onThemeChange": () => void;
|
|
906
|
+
"__#27170@#loadTheme"(): void;
|
|
907
|
+
"__#27170@#toggleOsThemeChangeListener": (listen: boolean) => void;
|
|
901
908
|
init(): Promise<void>;
|
|
902
|
-
"__#
|
|
909
|
+
"__#27157@#observeMappings": {};
|
|
903
910
|
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);
|
|
904
911
|
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);
|
|
905
|
-
"__#
|
|
912
|
+
"__#27156@#isInit": boolean;
|
|
906
913
|
connectedCallback: (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void) & (() => void);
|
|
907
914
|
accessKey: string;
|
|
908
915
|
readonly accessKeyLabel: string;
|
|
@@ -1229,24 +1236,24 @@ declare const BaseClass: {
|
|
|
1229
1236
|
tabIndex: number;
|
|
1230
1237
|
blur(): void;
|
|
1231
1238
|
focus(options?: FocusOptions): void;
|
|
1232
|
-
"__#
|
|
1233
|
-
"__#
|
|
1239
|
+
"__#27155@#logger": _descope_sdk_mixins_static_resources_mixin.Logger;
|
|
1240
|
+
"__#27155@#wrapLogger": ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger) & ((logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>) => _descope_sdk_mixins_static_resources_mixin.Logger);
|
|
1234
1241
|
get logger(): _descope_sdk_mixins_static_resources_mixin.Logger;
|
|
1235
1242
|
set logger(logger: Partial<_descope_sdk_mixins_static_resources_mixin.Logger>);
|
|
1236
1243
|
onLogEvent: ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void) & ((logLevel: "error" | "warn" | "info" | "debug", data: any[]) => void);
|
|
1237
1244
|
contentRootElement: HTMLElement;
|
|
1238
1245
|
rootElement: HTMLElement;
|
|
1239
1246
|
readonly config: Promise<_descope_sdk_mixins_static_resources_mixin.Config>;
|
|
1240
|
-
"__#
|
|
1241
|
-
"__#
|
|
1242
|
-
"__#
|
|
1243
|
-
"__#
|
|
1247
|
+
"__#27161@#configCacheClear": (() => void) & (() => void);
|
|
1248
|
+
"__#27161@#_configResource": Promise<_descope_sdk_mixins_static_resources_mixin.Config>;
|
|
1249
|
+
"__#27161@#fetchConfig": (() => Promise<_descope_sdk_mixins_static_resources_mixin.Config>) & (() => Promise<_descope_sdk_mixins_static_resources_mixin.Config>);
|
|
1250
|
+
"__#27160@#callbacks": Map<string, () => void> & Map<string, () => void>;
|
|
1244
1251
|
onReset: ((sectionId: string, callback: () => void | Promise<void>) => () => void) & ((sectionId: string, callback: () => void | Promise<void>) => () => void);
|
|
1245
1252
|
reset: ((...sectionIds: string[]) => Promise<void>) & ((...sectionIds: string[]) => Promise<void>);
|
|
1246
|
-
"__#
|
|
1247
|
-
"__#
|
|
1248
|
-
"__#
|
|
1249
|
-
"__#
|
|
1253
|
+
"__#27158@#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);
|
|
1254
|
+
"__#27159@#lastBaseUrl"?: string;
|
|
1255
|
+
"__#27159@#workingBaseUrl"?: string;
|
|
1256
|
+
"__#27159@#getResourceUrls": ((filename: string) => (URL & {
|
|
1250
1257
|
baseUrl: string;
|
|
1251
1258
|
}) | (URL & {
|
|
1252
1259
|
baseUrl: string;
|
|
@@ -1272,18 +1279,18 @@ declare const BaseClass: {
|
|
|
1272
1279
|
readonly baseStaticUrl: string;
|
|
1273
1280
|
readonly baseUrl: string;
|
|
1274
1281
|
readonly projectId: string;
|
|
1275
|
-
"__#
|
|
1276
|
-
"__#
|
|
1277
|
-
"__#
|
|
1278
|
-
"__#
|
|
1279
|
-
"__#
|
|
1280
|
-
"__#
|
|
1281
|
-
"__#
|
|
1282
|
-
"__#
|
|
1282
|
+
"__#27164@#errorCbsSym": symbol;
|
|
1283
|
+
"__#27164@#loadCbsSym": symbol;
|
|
1284
|
+
"__#27164@#getComponentsVersion"(): Promise<string>;
|
|
1285
|
+
"__#27164@#exposeAlternateEvents"(scriptEle: HTMLScriptElement): void;
|
|
1286
|
+
"__#27164@#handleFallbackScript"(errorCbs: ((error: string) => void)[], loadCbs: (() => void)[], elemId: string, scriptUrl: string): Promise<void>;
|
|
1287
|
+
"__#27164@#registerEvents"(scriptEle: HTMLScriptElement): void;
|
|
1288
|
+
"__#27164@#getDescopeUiLoadingScript"(): Promise<HTMLElement>;
|
|
1289
|
+
"__#27164@#descopeUi": Promise<any>;
|
|
1283
1290
|
readonly descopeUi: Promise<any>;
|
|
1284
|
-
"__#
|
|
1291
|
+
"__#27164@#loadDescopeUiComponent"(componentName: string): Promise<any>;
|
|
1285
1292
|
loadDescopeUiComponents(templateOrComponentNames: string[] | HTMLTemplateElement): Promise<any[]>;
|
|
1286
|
-
"__#
|
|
1293
|
+
"__#27164@#getDescopeUi"(): Promise<unknown>;
|
|
1287
1294
|
readonly baseCdnUrl: string;
|
|
1288
1295
|
}) & {
|
|
1289
1296
|
new (): HTMLElement;
|