@notabene/javascript-sdk 1.34.0 → 2.0.0-next.3
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/.gitlab-ci.yml +12 -1
- package/.husky/commit-msg +0 -0
- package/.husky/pre-commit +0 -0
- package/.husky/pre-push +1 -1
- package/.vscode/extensions.json +1 -5
- package/.vscode/settings.json +4 -4
- package/.yarn/releases/yarn-berry.cjs +925 -0
- package/.yarnrc.yml +3 -0
- package/README.md +126 -69
- package/api-extractor.json +434 -0
- package/dist/notabene.cjs +1 -0
- package/dist/notabene.d.ts +678 -0
- package/dist/notabene.js +187 -0
- package/dist/tsdoc-metadata.json +11 -0
- package/eslint.config.js +24 -0
- package/etc/javascript-sdk.api.md +363 -0
- package/index.html +135 -0
- package/package.json +29 -54
- package/src/__tests__/notabene.test.ts +131 -0
- package/src/arbitraries.ts +13 -0
- package/src/components/EmbeddedComponent.ts +110 -0
- package/src/components/__tests__/EmbeddedComponent.test.ts +160 -0
- package/src/ivms/types.ts +2 -0
- package/src/notabene.ts +174 -290
- package/src/types.ts +380 -49
- package/src/utils/MessageEventManager.ts +55 -0
- package/src/utils/__tests__/MessageEventManager.test.ts +95 -0
- package/src/utils/arbitraries.ts +21 -0
- package/src/utils/caip.ts +16 -0
- package/src/utils/urls.ts +15 -0
- package/temp/javascript-sdk.api.json +3509 -0
- package/temp/javascript-sdk.api.md +363 -0
- package/ts-out/src/__tests__/notabene.test.d.ts +1 -0
- package/ts-out/src/__tests__/notabene.test.js +97 -0
- package/ts-out/src/arbitraries.d.ts +4 -0
- package/ts-out/src/arbitraries.js +8 -0
- package/ts-out/src/components/EmbeddedComponent.d.ts +25 -0
- package/ts-out/src/components/EmbeddedComponent.js +87 -0
- package/ts-out/src/components/__tests__/EmbeddedComponent.test.d.ts +1 -0
- package/ts-out/src/components/__tests__/EmbeddedComponent.test.js +132 -0
- package/ts-out/src/ivms/types.d.ts +252 -0
- package/ts-out/src/ivms/types.js +1 -0
- package/ts-out/src/notabene.d.ts +35 -0
- package/ts-out/src/notabene.js +60 -0
- package/ts-out/src/types.d.ts +357 -0
- package/ts-out/src/types.js +85 -0
- package/ts-out/src/utils/MessageEventManager.d.ts +12 -0
- package/ts-out/src/utils/MessageEventManager.js +45 -0
- package/ts-out/src/utils/__tests__/MessageEventManager.test.d.ts +1 -0
- package/ts-out/src/utils/__tests__/MessageEventManager.test.js +73 -0
- package/ts-out/src/utils/arbitraries.d.ts +6 -0
- package/ts-out/src/utils/arbitraries.js +7 -0
- package/ts-out/src/utils/caip.d.ts +13 -0
- package/ts-out/src/utils/caip.js +15 -0
- package/ts-out/src/utils/urls.d.ts +1 -0
- package/ts-out/src/utils/urls.js +14 -0
- package/ts-out/tsconfig.tsbuildinfo +1 -0
- package/tsconfig.json +15 -11
- package/tsconfig.tsbuildinfo +1 -0
- package/vite.config.js +13 -0
- package/.envrc.template +0 -1
- package/.eslintignore +0 -3
- package/.eslintrc.js +0 -13
- package/.nvmrc +0 -1
- package/.tool-versions +0 -3
- package/dist/es/index.js +0 -1
- package/dist/lib/index.js +0 -376
- package/jest.config.js +0 -5
- package/public/index.html +0 -93
- package/public/js/.gitkeep +0 -0
- package/src/lib/index.ts +0 -2
- package/src/module/index.ts +0 -10
- package/src/zoidComponentProps.ts +0 -81
package/src/notabene.ts
CHANGED
|
@@ -1,318 +1,202 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
import EmbeddedComponent from './components/EmbeddedComponent';
|
|
2
|
+
import type {
|
|
3
|
+
Agent,
|
|
4
|
+
AgentType,
|
|
5
|
+
CallbackOptions,
|
|
6
|
+
ComponentMessage,
|
|
7
|
+
Counterparty,
|
|
8
|
+
DeclarationProof,
|
|
9
|
+
Destination,
|
|
10
|
+
HostMessage,
|
|
11
|
+
IVMS101,
|
|
12
|
+
MicroTransferProof,
|
|
13
|
+
OwnershipProof,
|
|
14
|
+
PersonType,
|
|
15
|
+
ProofStatus,
|
|
16
|
+
ProofTypes,
|
|
17
|
+
ScreenshotProof,
|
|
18
|
+
SignatureProof,
|
|
19
|
+
Status,
|
|
10
20
|
Theme,
|
|
11
21
|
Transaction,
|
|
12
|
-
|
|
13
|
-
|
|
22
|
+
TransactionAsset,
|
|
23
|
+
VASP,
|
|
24
|
+
Wallet,
|
|
25
|
+
Withdrawal,
|
|
14
26
|
} from './types';
|
|
15
|
-
import {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
27
|
+
import { CMType, TransactionResponse } from './types';
|
|
28
|
+
import { encodeObjectToFragment } from './utils/urls';
|
|
29
|
+
|
|
30
|
+
export type {
|
|
31
|
+
CMType,
|
|
32
|
+
ComponentMessage,
|
|
33
|
+
EmbeddedComponent,
|
|
34
|
+
HostMessage,
|
|
35
|
+
Theme,
|
|
36
|
+
Counterparty,
|
|
37
|
+
Withdrawal,
|
|
38
|
+
Transaction,
|
|
39
|
+
TransactionResponse,
|
|
40
|
+
Destination as destination,
|
|
41
|
+
TransactionAsset,
|
|
42
|
+
SignatureProof,
|
|
43
|
+
ScreenshotProof,
|
|
44
|
+
MicroTransferProof,
|
|
45
|
+
DeclarationProof,
|
|
46
|
+
Notabene,
|
|
47
|
+
ProofStatus,
|
|
48
|
+
ProofTypes,
|
|
49
|
+
IVMS101,
|
|
50
|
+
PersonType,
|
|
51
|
+
Status,
|
|
52
|
+
VASP,
|
|
53
|
+
Wallet,
|
|
54
|
+
Agent,
|
|
55
|
+
AgentType,
|
|
56
|
+
OwnershipProof,
|
|
57
|
+
};
|
|
58
|
+
|
|
59
|
+
/**
|
|
60
|
+
* Configuration for the Notabene SDK
|
|
61
|
+
*
|
|
62
|
+
* @public
|
|
63
|
+
*/
|
|
64
|
+
export interface NotabeneConfig {
|
|
65
|
+
nodeUrl?: string;
|
|
66
|
+
authToken?: string;
|
|
67
|
+
uxUrl?: string;
|
|
24
68
|
theme?: Theme;
|
|
25
69
|
dictionary?: { [key: string]: string };
|
|
26
|
-
transactionTypeAllowed?: TransactionTypeAllowed;
|
|
27
|
-
nonCustodialDeclarationType?: NonCustodialDeclarationType;
|
|
28
|
-
beneficiaryDetails?: string[]; // @deprecated beneficiaryDetails - do not delete yet
|
|
29
|
-
fieldsProps?: FieldsProps;
|
|
30
|
-
fallbacks?: Fallback[];
|
|
31
|
-
optInFeatures?: OptInFeature[];
|
|
32
70
|
}
|
|
33
71
|
|
|
72
|
+
/**
|
|
73
|
+
* Primary constructor for Notabene UX elements
|
|
74
|
+
*
|
|
75
|
+
* @public
|
|
76
|
+
*/
|
|
77
|
+
|
|
34
78
|
export default class Notabene {
|
|
35
|
-
private
|
|
36
|
-
private
|
|
37
|
-
private
|
|
38
|
-
private
|
|
39
|
-
private
|
|
40
|
-
private widgetRendered: boolean;
|
|
41
|
-
private popupRendered: boolean;
|
|
42
|
-
private shouldBeDestroyed: boolean;
|
|
79
|
+
private nodeUrl?: string;
|
|
80
|
+
private authToken?: string;
|
|
81
|
+
private uxUrl: string;
|
|
82
|
+
private theme?: Theme;
|
|
83
|
+
private dictionary?: { [key: string]: string };
|
|
43
84
|
|
|
44
85
|
constructor(config: NotabeneConfig) {
|
|
45
|
-
this.
|
|
46
|
-
this.config.
|
|
47
|
-
|
|
48
|
-
this.
|
|
49
|
-
this.
|
|
50
|
-
this.shouldBeDestroyed = false;
|
|
51
|
-
this.popupRendered = false;
|
|
52
|
-
this.config.fallbacks = this.config.fallbacks || [
|
|
53
|
-
{ flow: 'WALLET_NOT_SUPPORTED', action: 'DECLARATION' },
|
|
54
|
-
];
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
/**
|
|
58
|
-
* Renders a new widget
|
|
59
|
-
* @param type - the type of widget to render
|
|
60
|
-
*/
|
|
61
|
-
public async renderWidget(
|
|
62
|
-
type: WidgetType = WidgetType.WITHDRAWAL
|
|
63
|
-
): Promise<void> {
|
|
64
|
-
this._renderWidget(type);
|
|
86
|
+
this.uxUrl = config.uxUrl || 'https://connect.notabene.id';
|
|
87
|
+
this.nodeUrl = config.nodeUrl;
|
|
88
|
+
this.authToken = config.authToken;
|
|
89
|
+
this.theme = config.theme;
|
|
90
|
+
this.dictionary = config.dictionary;
|
|
65
91
|
}
|
|
66
92
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
this.widget.updateProps({
|
|
81
|
-
transaction: this.tx,
|
|
82
|
-
type,
|
|
83
|
-
});
|
|
84
|
-
this.popup.updateProps({
|
|
85
|
-
transaction: this.tx,
|
|
86
|
-
type,
|
|
93
|
+
public componentUrl(
|
|
94
|
+
path: string,
|
|
95
|
+
value: Partial<Transaction>,
|
|
96
|
+
configuration?: any,
|
|
97
|
+
callbacks?: CallbackOptions,
|
|
98
|
+
): string {
|
|
99
|
+
const url = new URL(this.uxUrl);
|
|
100
|
+
url.pathname = path;
|
|
101
|
+
|
|
102
|
+
const hash = encodeObjectToFragment({
|
|
103
|
+
authToken: this.authToken,
|
|
104
|
+
value,
|
|
105
|
+
configuration,
|
|
87
106
|
});
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
await this.renderPopup();
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
private async renderPopup(): Promise<void> {
|
|
94
|
-
if (!this.popup) return;
|
|
107
|
+
url.hash = hash;
|
|
108
|
+
if (this.nodeUrl) url.searchParams.set('nodeUrl', this.nodeUrl);
|
|
95
109
|
|
|
96
|
-
if (
|
|
97
|
-
|
|
98
|
-
this.popupRendered = true;
|
|
110
|
+
if (this.theme) {
|
|
111
|
+
url.searchParams.set('theme', JSON.stringify(this.theme));
|
|
99
112
|
}
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
public async destroyWidget(): Promise<void> {
|
|
103
|
-
if (!this.widgetRendered || !this.popupRendered) {
|
|
104
|
-
this.shouldBeDestroyed = true;
|
|
105
|
-
return;
|
|
113
|
+
if (this.dictionary) {
|
|
114
|
+
url.searchParams.set('dictionary', JSON.stringify(this.dictionary));
|
|
106
115
|
}
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
public setTransaction(tx: Transaction) {
|
|
114
|
-
this.tx = tx;
|
|
115
|
-
if (this.widgetRendered) {
|
|
116
|
-
this.widget.updateProps({
|
|
117
|
-
transaction: tx,
|
|
118
|
-
});
|
|
119
|
-
this.popup.updateProps({
|
|
120
|
-
transaction: tx,
|
|
121
|
-
});
|
|
116
|
+
if (callbacks) {
|
|
117
|
+
if (callbacks.callback)
|
|
118
|
+
url.searchParams.set('callback_url', callbacks.callback);
|
|
119
|
+
if (callbacks.redirectUri)
|
|
120
|
+
url.searchParams.set('redirect_uri', callbacks.redirectUri);
|
|
122
121
|
}
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
private cleanUpDestroyedComponents() {
|
|
126
|
-
if (!this.shouldBeDestroyed) return;
|
|
127
|
-
this.destroyWidget();
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
private getWidgetUrl(): string {
|
|
131
|
-
const url = new URL(this.config.widget);
|
|
132
|
-
url.hash = `authToken=${this.config.authToken}`;
|
|
133
122
|
return url.toString();
|
|
134
123
|
}
|
|
135
124
|
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
125
|
+
public createComponent(
|
|
126
|
+
path: string,
|
|
127
|
+
value: Partial<Transaction>,
|
|
128
|
+
options?: any,
|
|
129
|
+
callbacks?: CallbackOptions,
|
|
130
|
+
) {
|
|
131
|
+
return new EmbeddedComponent(
|
|
132
|
+
this.componentUrl(path, value, options, callbacks),
|
|
133
|
+
value,
|
|
134
|
+
);
|
|
142
135
|
}
|
|
143
136
|
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
this.popup.updateProps({
|
|
151
|
-
error: err,
|
|
152
|
-
});
|
|
153
|
-
}
|
|
154
|
-
if (!err || !this.config.onError) return;
|
|
155
|
-
this.config.onError(err);
|
|
137
|
+
public createWithdrawalAssist(
|
|
138
|
+
value: Partial<Withdrawal>,
|
|
139
|
+
options?: any,
|
|
140
|
+
callbacks?: CallbackOptions,
|
|
141
|
+
) {
|
|
142
|
+
return this.createComponent('withdrawal-assist', value, options, callbacks);
|
|
156
143
|
}
|
|
157
144
|
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
tag: 'widget',
|
|
166
|
-
url: this.getWidgetUrl(),
|
|
167
|
-
dimensions: {
|
|
168
|
-
width: '100%',
|
|
169
|
-
height: '280px',
|
|
145
|
+
public decodeFragmentToObject(fragment: string): Record<string, string> {
|
|
146
|
+
const pairs = fragment.slice(1).split('&');
|
|
147
|
+
return pairs.reduce(
|
|
148
|
+
(obj, pair) => {
|
|
149
|
+
const [key, value] = pair.split('=');
|
|
150
|
+
obj[decodeURIComponent(key)] = decodeURIComponent(value);
|
|
151
|
+
return obj;
|
|
170
152
|
},
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
allow: 'usb *;bluetooth *',
|
|
174
|
-
},
|
|
175
|
-
},
|
|
176
|
-
props: widgetProps,
|
|
177
|
-
})({
|
|
178
|
-
vaspDID: this.config.vaspDID,
|
|
179
|
-
transaction: {},
|
|
180
|
-
theme: this.config.theme,
|
|
181
|
-
dictionary: this.config.dictionary,
|
|
182
|
-
transactionTypeAllowed: this.config.transactionTypeAllowed,
|
|
183
|
-
nonCustodialDeclarationType: this.config.nonCustodialDeclarationType,
|
|
184
|
-
beneficiaryDetails: this.config.beneficiaryDetails,
|
|
185
|
-
fieldsProps: this.config.fieldsProps,
|
|
186
|
-
fallbacks: this.config.fallbacks,
|
|
187
|
-
optInFeatures: this.config.optInFeatures,
|
|
188
|
-
onRequireAdditionalInformation: () => {
|
|
189
|
-
this.popup.updateProps({
|
|
190
|
-
popupOpen: true,
|
|
191
|
-
});
|
|
192
|
-
this.popup.show();
|
|
193
|
-
},
|
|
194
|
-
onValidStateChange: (isValid: boolean) => {
|
|
195
|
-
this.config.onValidStateChange(isValid);
|
|
196
|
-
},
|
|
197
|
-
error: this.error,
|
|
198
|
-
onError: (err: any) => {
|
|
199
|
-
this.handleError(err);
|
|
200
|
-
console.debug('Notabene: Error handler called');
|
|
201
|
-
},
|
|
202
|
-
storeTransaction: (tx: Transaction) => {
|
|
203
|
-
this.setTransaction(tx);
|
|
204
|
-
},
|
|
205
|
-
});
|
|
206
|
-
|
|
207
|
-
builtWidget.event.on(zoid.EVENT.RENDERED, () => {
|
|
208
|
-
this.widgetRendered = true;
|
|
209
|
-
this.cleanUpDestroyedComponents();
|
|
210
|
-
});
|
|
211
|
-
|
|
212
|
-
return builtWidget;
|
|
153
|
+
{} as Record<string, string>,
|
|
154
|
+
);
|
|
213
155
|
}
|
|
214
156
|
|
|
215
|
-
private
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
}
|
|
261
|
-
.nb-popup {
|
|
262
|
-
width: 100%;
|
|
263
|
-
height: 100%;
|
|
264
|
-
}
|
|
265
|
-
.nb-preloader {
|
|
266
|
-
display: none;
|
|
267
|
-
}
|
|
268
|
-
`
|
|
269
|
-
),
|
|
270
|
-
node(
|
|
271
|
-
'div',
|
|
272
|
-
{ class: 'nb-overlay' },
|
|
273
|
-
node('node', { el: frame, class: 'nb-popup' }),
|
|
274
|
-
node('node', { el: prerenderFrame, class: 'nb-preloader' })
|
|
275
|
-
)
|
|
276
|
-
).render(dom({ doc }));
|
|
277
|
-
},
|
|
278
|
-
})({
|
|
279
|
-
vaspDID: this.config.vaspDID,
|
|
280
|
-
transaction: this.tx,
|
|
281
|
-
beneficiaryDetails: this.config.beneficiaryDetails,
|
|
282
|
-
fieldsProps: this.config.fieldsProps,
|
|
283
|
-
storeTransaction: (tx: Transaction) => {
|
|
284
|
-
this.setTransaction(tx);
|
|
285
|
-
console.debug('Notabene: Transaction stored');
|
|
286
|
-
},
|
|
287
|
-
close: () => {
|
|
288
|
-
this.popup.close();
|
|
289
|
-
console.debug('Notabene: Popup closing');
|
|
290
|
-
},
|
|
291
|
-
setPopupOpen: (isOpen: boolean) => {
|
|
292
|
-
this.popup.updateProps({
|
|
293
|
-
popupOpen: isOpen,
|
|
294
|
-
});
|
|
295
|
-
},
|
|
296
|
-
error: this.error,
|
|
297
|
-
onError: (err: any) => {
|
|
298
|
-
this.handleError(err);
|
|
299
|
-
console.debug('Notabene: Error handler called');
|
|
300
|
-
},
|
|
301
|
-
popupOpen: false,
|
|
302
|
-
theme: this.config.theme,
|
|
303
|
-
dictionary: this.config.dictionary,
|
|
304
|
-
transactionTypeAllowed: this.config.transactionTypeAllowed,
|
|
305
|
-
nonCustodialDeclarationType: this.config.nonCustodialDeclarationType,
|
|
306
|
-
fallbacks: this.config.fallbacks,
|
|
307
|
-
optInFeatures: this.config.optInFeatures,
|
|
308
|
-
});
|
|
309
|
-
|
|
310
|
-
builtPopup.event.on(zoid.EVENT.RENDERED, () => {
|
|
311
|
-
this.popupRendered = true;
|
|
312
|
-
this.cleanUpDestroyedComponents();
|
|
313
|
-
});
|
|
314
|
-
return builtPopup;
|
|
315
|
-
}
|
|
157
|
+
// private openModal(url: string): void {
|
|
158
|
+
// if (this.modal) {
|
|
159
|
+
// this.closeModal();
|
|
160
|
+
// }
|
|
161
|
+
// this.modal = document.createElement('div');
|
|
162
|
+
// this.modal.style.position = 'fixed';
|
|
163
|
+
// this.modal.style.top = '0';
|
|
164
|
+
// this.modal.style.left = '0';
|
|
165
|
+
// this.modal.style.width = '100%';
|
|
166
|
+
// this.modal.style.height = '100%';
|
|
167
|
+
// this.modal.style.backgroundColor = 'rgba(0, 0, 0, 0.5)';
|
|
168
|
+
// this.modal.style.display = 'flex';
|
|
169
|
+
// this.modal.style.justifyContent = 'center';
|
|
170
|
+
// this.modal.style.alignItems = 'center';
|
|
171
|
+
// const iframe = document.createElement('iframe');
|
|
172
|
+
// iframe.src = url;
|
|
173
|
+
// iframe.setAttribute('allowtransparency', 'true');
|
|
174
|
+
// // iframe.allowtransparency = true;
|
|
175
|
+
// iframe.style.backgroundColor = 'transparent';
|
|
176
|
+
// iframe.style.width = '90%';
|
|
177
|
+
// iframe.style.height = '90%';
|
|
178
|
+
// iframe.style.border = 'none';
|
|
179
|
+
// iframe.style.overflow = 'hidden';
|
|
180
|
+
// this.modal.appendChild(iframe);
|
|
181
|
+
// document.body.appendChild(this.modal);
|
|
182
|
+
// this.modal.addEventListener('click', () => {
|
|
183
|
+
// console.log('click');
|
|
184
|
+
// this.closeModal();
|
|
185
|
+
// });
|
|
186
|
+
// document.addEventListener('keydown', ({ key }) => {
|
|
187
|
+
// console.log(`key: ${key}`);
|
|
188
|
+
// if (key === 'Escape') {
|
|
189
|
+
// console.log('esc');
|
|
190
|
+
// this.closeModal();
|
|
191
|
+
// }
|
|
192
|
+
// });
|
|
193
|
+
// }
|
|
194
|
+
|
|
195
|
+
// private closeModal(): void {
|
|
196
|
+
// if (this.modal) {
|
|
197
|
+
// console.log('this.closeModal');
|
|
198
|
+
// this.modal.remove();
|
|
199
|
+
// this.modal = undefined;
|
|
200
|
+
// }
|
|
201
|
+
// }
|
|
316
202
|
}
|
|
317
|
-
|
|
318
|
-
if (window) window.Notabene = Notabene;
|