@verdocs/web-sdk 2.3.33 → 2.3.34

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.
@@ -5,6 +5,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
5
5
  const index = require('./index-5463795e.js');
6
6
  require('./Types-f89f9116.js');
7
7
  const VerdocsEndpoint = require('./VerdocsEndpoint-8f298664.js');
8
+ const TemplateFieldStore = require('./TemplateFieldStore-ecf695a7.js');
8
9
  const TemplateRoleStore = require('./TemplateRoleStore-e17bb006.js');
9
10
  const TemplateStore = require('./TemplateStore-e62c16a8.js');
10
11
  const utils = require('./utils-ac526133.js');
@@ -16,7 +17,6 @@ const TemplateDocuments = require('./TemplateDocuments-e2e0e6b7.js');
16
17
  const Icons = require('./Icons-3286d014.js');
17
18
  const Toast = require('./Toast-06880504.js');
18
19
  require('./index-f712049c.js');
19
- require('./TemplateFieldStore-ecf695a7.js');
20
20
  require('./_commonjsHelpers-1fbbf0eb.js');
21
21
  require('./Files-4bdc0c0f.js');
22
22
  require('./Types-fb95ed6b.js');
@@ -55,6 +55,7 @@ const VerdocsPreview = class {
55
55
  index.registerInstance(this, hostRef);
56
56
  this.sdkError = index.createEvent(this, "sdkError", 7);
57
57
  this.templateStore = null;
58
+ this.fieldStore = null;
58
59
  this.roleStore = null;
59
60
  this.endpoint = VerdocsEndpoint.VerdocsEndpoint.getDefault();
60
61
  this.templateId = null;
@@ -72,8 +73,9 @@ const VerdocsPreview = class {
72
73
  return;
73
74
  }
74
75
  this.templateStore = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
76
+ this.fieldStore = TemplateFieldStore.getTemplateFieldStore(this.templateId);
75
77
  this.roleStore = TemplateRoleStore.getTemplateRoleStore(this.templateId);
76
- console.log(`[PREVIEW] Loading template ${this.templateId}`, this.endpoint.session);
78
+ console.log('[PREVIEW] Loadied template', this.templateStore.state, this.roleStore.get('roles'), this.fieldStore.get('fields'));
77
79
  }
78
80
  catch (e) {
79
81
  console.log('[PREVIEW] Error with preview session', e);
@@ -1,5 +1,6 @@
1
1
  import { VerdocsEndpoint } from '@verdocs/js-sdk';
2
2
  import { h } from '@stencil/core';
3
+ import { getTemplateFieldStore } from '../../../utils/TemplateFieldStore';
3
4
  import { getTemplateRoleStore } from '../../../utils/TemplateRoleStore';
4
5
  import { getTemplateStore } from '../../../utils/TemplateStore';
5
6
  import { renderDocumentField } from '../../../utils/utils';
@@ -13,6 +14,7 @@ import { SDKError } from '../../../utils/errors';
13
14
  export class VerdocsPreview {
14
15
  constructor() {
15
16
  this.templateStore = null;
17
+ this.fieldStore = null;
16
18
  this.roleStore = null;
17
19
  this.endpoint = VerdocsEndpoint.getDefault();
18
20
  this.templateId = null;
@@ -30,8 +32,9 @@ export class VerdocsPreview {
30
32
  return;
31
33
  }
32
34
  this.templateStore = await getTemplateStore(this.endpoint, this.templateId, false);
35
+ this.fieldStore = getTemplateFieldStore(this.templateId);
33
36
  this.roleStore = getTemplateRoleStore(this.templateId);
34
- console.log(`[PREVIEW] Loading template ${this.templateId}`, this.endpoint.session);
37
+ console.log('[PREVIEW] Loadied template', this.templateStore.state, this.roleStore.get('roles'), this.fieldStore.get('fields'));
35
38
  }
36
39
  catch (e) {
37
40
  console.log('[PREVIEW] Error with preview session', e);
@@ -1,6 +1,7 @@
1
1
  import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
2
2
  import './Types.js';
3
3
  import { V as VerdocsEndpoint } from './VerdocsEndpoint.js';
4
+ import { g as getTemplateFieldStore } from './TemplateFieldStore.js';
4
5
  import { g as getTemplateRoleStore } from './TemplateRoleStore.js';
5
6
  import { g as getTemplateStore } from './TemplateStore.js';
6
7
  import { r as renderDocumentField } from './utils.js';
@@ -16,6 +17,7 @@ const VerdocsPreview = /*@__PURE__*/ proxyCustomElement(class extends HTMLElemen
16
17
  this.__registerHost();
17
18
  this.sdkError = createEvent(this, "sdkError", 7);
18
19
  this.templateStore = null;
20
+ this.fieldStore = null;
19
21
  this.roleStore = null;
20
22
  this.endpoint = VerdocsEndpoint.getDefault();
21
23
  this.templateId = null;
@@ -33,8 +35,9 @@ const VerdocsPreview = /*@__PURE__*/ proxyCustomElement(class extends HTMLElemen
33
35
  return;
34
36
  }
35
37
  this.templateStore = await getTemplateStore(this.endpoint, this.templateId, false);
38
+ this.fieldStore = getTemplateFieldStore(this.templateId);
36
39
  this.roleStore = getTemplateRoleStore(this.templateId);
37
- console.log(`[PREVIEW] Loading template ${this.templateId}`, this.endpoint.session);
40
+ console.log('[PREVIEW] Loadied template', this.templateStore.state, this.roleStore.get('roles'), this.fieldStore.get('fields'));
38
41
  }
39
42
  catch (e) {
40
43
  console.log('[PREVIEW] Error with preview session', e);