@multiversx/sdk-web-wallet-cross-window-provider 0.1.3-alpha.4 → 0.1.3-alpha.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/out/CrossWindowProvider/CrossWindowProvider.js +27 -4
- package/out/CrossWindowProvider/CrossWindowProvider.js.map +1 -1
- package/out/CrossWindowProvider/PopupConsent/PopupConsent.d.ts +8 -11
- package/out/CrossWindowProvider/PopupConsent/PopupConsent.js +50 -74
- package/out/CrossWindowProvider/PopupConsent/PopupConsent.js.map +1 -1
- package/out/CrossWindowProvider/PopupConsent/constants.d.ts +1 -0
- package/out/CrossWindowProvider/PopupConsent/constants.js +5 -0
- package/out/CrossWindowProvider/PopupConsent/constants.js.map +1 -0
- package/out/CrossWindowProvider/PopupConsent/getStyles.js +13 -14
- package/out/CrossWindowProvider/PopupConsent/getStyles.js.map +1 -1
- package/out/CrossWindowProvider/tests/Cancel.test.js +1 -1
- package/out/CrossWindowProvider/tests/Cancel.test.js.map +1 -1
- package/package.json +3 -9
- package/out/CrossWindowProvider/CrossWindowProvider.mjs +0 -2
- package/out/CrossWindowProvider/CrossWindowProvider.mjs.map +0 -7
- package/out/CrossWindowProvider/PopupConsent/PopupConsent.mjs +0 -2
- package/out/CrossWindowProvider/PopupConsent/PopupConsent.mjs.map +0 -7
- package/out/CrossWindowProvider/PopupConsent/getStyles.mjs +0 -2
- package/out/CrossWindowProvider/PopupConsent/getStyles.mjs.map +0 -7
- package/out/CrossWindowProvider/PopupConsent/index.mjs +0 -2
- package/out/CrossWindowProvider/PopupConsent/index.mjs.map +0 -7
- package/out/CrossWindowProvider/index.mjs +0 -2
- package/out/CrossWindowProvider/index.mjs.map +0 -7
- package/out/WindowManager/WindowManager.mjs +0 -2
- package/out/WindowManager/WindowManager.mjs.map +0 -7
- package/out/WindowManager/index.mjs +0 -2
- package/out/WindowManager/index.mjs.map +0 -7
- package/out/__chunks__/chunk-67SNURO7.mjs +0 -133
- package/out/__chunks__/chunk-67SNURO7.mjs.map +0 -7
- package/out/__chunks__/chunk-7BAKJMGJ.mjs +0 -2
- package/out/__chunks__/chunk-7BAKJMGJ.mjs.map +0 -7
- package/out/__chunks__/chunk-7EG66KV4.mjs +0 -2
- package/out/__chunks__/chunk-7EG66KV4.mjs.map +0 -7
- package/out/__chunks__/chunk-ARPF4OON.mjs +0 -2
- package/out/__chunks__/chunk-ARPF4OON.mjs.map +0 -7
- package/out/__chunks__/chunk-CRKVTTK2.mjs +0 -2
- package/out/__chunks__/chunk-CRKVTTK2.mjs.map +0 -7
- package/out/__chunks__/chunk-IFJNPC67.mjs +0 -1
- package/out/__chunks__/chunk-IFJNPC67.mjs.map +0 -7
- package/out/__chunks__/chunk-ILRVZBDL.mjs +0 -2
- package/out/__chunks__/chunk-ILRVZBDL.mjs.map +0 -7
- package/out/__chunks__/chunk-LO6PRAW2.mjs +0 -2
- package/out/__chunks__/chunk-LO6PRAW2.mjs.map +0 -7
- package/out/__chunks__/chunk-MFDD33CC.mjs +0 -2
- package/out/__chunks__/chunk-MFDD33CC.mjs.map +0 -7
- package/out/__chunks__/chunk-P5U2NZJJ.mjs +0 -2
- package/out/__chunks__/chunk-P5U2NZJJ.mjs.map +0 -7
- package/out/__chunks__/chunk-PE2DWF25.mjs +0 -20
- package/out/__chunks__/chunk-PE2DWF25.mjs.map +0 -7
- package/out/__chunks__/chunk-UADEV64E.mjs +0 -2
- package/out/__chunks__/chunk-UADEV64E.mjs.map +0 -7
- package/out/__chunks__/chunk-UHIELAL2.mjs +0 -102
- package/out/__chunks__/chunk-UHIELAL2.mjs.map +0 -7
- package/out/__chunks__/chunk-X6LLUYE7.mjs +0 -2
- package/out/__chunks__/chunk-X6LLUYE7.mjs.map +0 -7
- package/out/errors.mjs +0 -2
- package/out/errors.mjs.map +0 -7
- package/out/index.mjs +0 -2
- package/out/index.mjs.map +0 -7
- package/out/test-utils/createMockTransaction.mjs +0 -2
- package/out/test-utils/createMockTransaction.mjs.map +0 -7
- package/out/test-utils/getWalletWindowMock.mjs +0 -2
- package/out/test-utils/getWalletWindowMock.mjs.map +0 -7
- package/out/test-utils/index.mjs +0 -2
- package/out/test-utils/index.mjs.map +0 -7
- package/out/test-utils/mockWindowManager.mjs +0 -2
- package/out/test-utils/mockWindowManager.mjs.map +0 -7
|
@@ -1,4 +1,27 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
2
25
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
26
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
27
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -13,9 +36,9 @@ exports.CrossWindowProvider = void 0;
|
|
|
13
36
|
const sdk_core_1 = require("@multiversx/sdk-core");
|
|
14
37
|
const crossWindowProviderConstants_1 = require("@multiversx/sdk-dapp-utils/out/constants/crossWindowProviderConstants");
|
|
15
38
|
const crossWindowProviderEnums_1 = require("@multiversx/sdk-dapp-utils/out/enums/crossWindowProviderEnums");
|
|
16
|
-
const errors_1 = require("../errors");
|
|
17
39
|
const WindowManager_1 = require("../WindowManager");
|
|
18
|
-
const
|
|
40
|
+
const errors_1 = require("../errors");
|
|
41
|
+
const constants_1 = require("./PopupConsent/constants");
|
|
19
42
|
class CrossWindowProvider {
|
|
20
43
|
constructor() {
|
|
21
44
|
this.account = { address: '' };
|
|
@@ -223,13 +246,13 @@ class CrossWindowProvider {
|
|
|
223
246
|
openPopupConsent() {
|
|
224
247
|
var _a, _b, _c;
|
|
225
248
|
return __awaiter(this, void 0, void 0, function* () {
|
|
226
|
-
require('./PopupConsent');
|
|
249
|
+
yield Promise.resolve().then(() => __importStar(require('./PopupConsent/PopupConsent')));
|
|
227
250
|
const dialog = (_a = crossWindowProviderConstants_1.safeWindow.document) === null || _a === void 0 ? void 0 : _a.createElement('div');
|
|
228
251
|
const document = crossWindowProviderConstants_1.safeWindow.document;
|
|
229
252
|
if (!this._shouldShowConsentPopup || !document || !dialog) {
|
|
230
253
|
return true;
|
|
231
254
|
}
|
|
232
|
-
const popup = (_b = crossWindowProviderConstants_1.safeWindow.document) === null || _b === void 0 ? void 0 : _b.createElement(
|
|
255
|
+
const popup = (_b = crossWindowProviderConstants_1.safeWindow.document) === null || _b === void 0 ? void 0 : _b.createElement(constants_1.confirmationDialogTag);
|
|
233
256
|
popup.walletUrl = this.windowManager.walletUrl;
|
|
234
257
|
(_c = crossWindowProviderConstants_1.safeWindow.document) === null || _c === void 0 ? void 0 : _c.body.appendChild(popup);
|
|
235
258
|
const popupConsentResponse = yield new Promise((resolve) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CrossWindowProvider.js","sourceRoot":"","sources":["../../src/CrossWindowProvider/CrossWindowProvider.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CrossWindowProvider.js","sourceRoot":"","sources":["../../src/CrossWindowProvider/CrossWindowProvider.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,mDAAoE;AACpE,wHAAmG;AACnG,4GAIuE;AACvE,oDAAiD;AACjD,sCAUmB;AAEnB,wDAAiE;AASjE,MAAa,mBAAmB;IAQ9B;QAPO,YAAO,GAA8B,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;QACpD,gBAAW,GAAG,KAAK,CAAC;QAGpB,gBAAW,GAAuB,SAAS,CAAC;QAC1C,4BAAuB,GAAG,KAAK,CAAC;QAGxC,IAAI,mBAAmB,CAAC,SAAS,EAAE;YACjC,MAAM,IAAI,+BAAsB,EAAE,CAAC;SACpC;QACD,IAAI,CAAC,aAAa,GAAG,6BAAa,CAAC,WAAW,EAAE,CAAC;QACjD,mBAAmB,CAAC,SAAS,GAAG,IAAI,CAAC;IACvC,CAAC;IAEM,yBAAyB,CAAC,UAAmB;QAClD,IAAI,CAAC,uBAAuB,GAAG,UAAU,CAAC;IAC5C,CAAC;IAEO,eAAe;QACrB,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,EAAE;YACzB,MAAM,IAAI,+BAAsB,EAAE,CAAC;SACpC;IACH,CAAC;IAEO,UAAU;QAChB,IAAI,CAAC,OAAO,GAAG,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;IACjC,CAAC;IAEM,MAAM,CAAC,WAAW;QACvB,OAAO,mBAAmB,CAAC,SAAS,CAAC;IACvC,CAAC;IAEM,UAAU,CAAC,OAAe;QAC/B,IAAI,CAAC,OAAO,CAAC,OAAO,GAAG,OAAO,CAAC;QAC/B,OAAO,mBAAmB,CAAC,SAAS,CAAC;IACvC,CAAC;IAEM,YAAY,CAAC,GAAW;QAC7B,IAAI,CAAC,aAAa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AAI,CAAC,MAAM,EAAE;gBACzD,OAAO,IAAI,CAAC;aACb;YAED,MAAM,KAAK,GAAG,MAAA,yCAAU,CAAC,QAAQ,0CAAE,aAAa,CAC9C,iCAAqB,CACN,CAAC;YAElB,KAAK,CAAC,SAAS,GAAG,IAAI,CAAC,aAAa,CAAC,SAAS,CAAC;YAE/C,MAAA,yCAAU,CAAC,QAAQ,0CAAE,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;YAE7C,MAAM,oBAAoB,GAAY,MAAM,IAAI,OAAO,CACrD,CAAC,OAAO,EAAE,EAAE;gBACV,KAAK,CAAC,SAAS,GAAG,GAAG,EAAE;;oBACrB,OAAO,CAAC,IAAI,CAAC,CAAC;oBACd,MAAA,yCAAU,CAAC,QAAQ,0CAAE,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;gBAC/C,CAAC,CAAC;gBACF,KAAK,CAAC,QAAQ,GAAG,GAAG,EAAE;;oBACpB,OAAO,CAAC,KAAK,CAAC,CAAC;oBACf,MAAA,yCAAU,CAAC,QAAQ,0CAAE,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;gBAC/C,CAAC,CAAC;YACJ,CAAC,CACF,CAAC;YAEF,IAAI,CAAC,uBAAuB,GAAG,KAAK,CAAC;YACrC,OAAO,oBAAoB,CAAC;;KAC7B;;AAjSc,6BAAS,GAAwB,IAAI,mBAAmB,EAAE,AAAjD,CAAkD;AAJ/D,kDAAmB"}
|
|
@@ -1,21 +1,18 @@
|
|
|
1
|
-
|
|
2
|
-
export declare const confirmationDialogTag = "mxcwp-confirmation-dialog";
|
|
3
|
-
export declare class PopupConsent extends LitElement {
|
|
4
|
-
id: string;
|
|
1
|
+
export declare class PopupConsent extends HTMLElement {
|
|
5
2
|
walletUrl: string;
|
|
6
|
-
|
|
3
|
+
identifier: string;
|
|
7
4
|
onCancel: () => void;
|
|
5
|
+
onConfirm: () => void;
|
|
6
|
+
constructor();
|
|
7
|
+
attributeChangedCallback(name: string, oldValue: string, newValue: string): void;
|
|
8
8
|
events: {
|
|
9
9
|
confirm: string;
|
|
10
10
|
cancel: string;
|
|
11
11
|
mounted: string;
|
|
12
12
|
};
|
|
13
|
-
|
|
14
|
-
dispatchAction
|
|
15
|
-
|
|
16
|
-
createRenderRoot(): this;
|
|
17
|
-
getTemplate: () => import("lit-html").TemplateResult<1>;
|
|
18
|
-
render(): import("lit-html").TemplateResult<1>;
|
|
13
|
+
private handleConfirmEvent;
|
|
14
|
+
private dispatchAction;
|
|
15
|
+
render(): void;
|
|
19
16
|
toggleEvents(action: 'removeEventListener' | 'addEventListener'): void;
|
|
20
17
|
connectedCallback(): void;
|
|
21
18
|
disconnectedCallback(): void;
|
|
@@ -1,32 +1,24 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
-
exports.PopupConsent =
|
|
3
|
+
exports.PopupConsent = void 0;
|
|
10
4
|
const crossWindowProviderConstants_1 = require("@multiversx/sdk-dapp-utils/out/constants/crossWindowProviderConstants");
|
|
11
|
-
const
|
|
12
|
-
const decorators_js_1 = require("lit/decorators.js");
|
|
5
|
+
const constants_1 = require("./constants");
|
|
13
6
|
const getStyles_1 = require("./getStyles");
|
|
14
|
-
|
|
15
|
-
class PopupConsent extends lit_1.LitElement {
|
|
7
|
+
class PopupConsent extends HTMLElement {
|
|
16
8
|
constructor() {
|
|
17
|
-
super(
|
|
18
|
-
this.id = exports.confirmationDialogTag;
|
|
9
|
+
super();
|
|
19
10
|
this.walletUrl = '';
|
|
20
|
-
this.
|
|
21
|
-
console.log('onConfirm');
|
|
22
|
-
};
|
|
11
|
+
this.identifier = constants_1.confirmationDialogTag;
|
|
23
12
|
this.onCancel = () => {
|
|
24
13
|
console.log('onCancel');
|
|
25
14
|
};
|
|
15
|
+
this.onConfirm = () => {
|
|
16
|
+
console.log('onConfirm');
|
|
17
|
+
};
|
|
26
18
|
this.events = {
|
|
27
|
-
confirm: `${this.
|
|
28
|
-
cancel: `${this.
|
|
29
|
-
mounted: `${this.
|
|
19
|
+
confirm: `${this.identifier}-confirm`,
|
|
20
|
+
cancel: `${this.identifier}-cancel`,
|
|
21
|
+
mounted: `${this.identifier}-mounted`
|
|
30
22
|
};
|
|
31
23
|
this.dispatchAction = (type) => {
|
|
32
24
|
const event = new CustomEvent(type, {
|
|
@@ -35,38 +27,12 @@ class PopupConsent extends lit_1.LitElement {
|
|
|
35
27
|
});
|
|
36
28
|
this.dispatchEvent(event);
|
|
37
29
|
};
|
|
38
|
-
this.getTemplate = () => (0, lit_1.html) `<style>
|
|
39
|
-
${(0, getStyles_1.getStyles)(this.id)}
|
|
40
|
-
</style>
|
|
41
|
-
<div id="${this.id}">
|
|
42
|
-
<div class="content">
|
|
43
|
-
<div class="body">
|
|
44
|
-
<div class="title">Confirm on MultiversX Wallet</div>
|
|
45
|
-
<div class="subtitle">Continue to ${this.walletUrl}</div>
|
|
46
|
-
<div class="actions-container">
|
|
47
|
-
<button
|
|
48
|
-
@click="${() => this.dispatchAction(this.events.cancel)}"
|
|
49
|
-
class="button"
|
|
50
|
-
data-testid="${this.events.cancel}-btn"
|
|
51
|
-
id="${this.events.cancel}-btn"
|
|
52
|
-
>
|
|
53
|
-
Cancel
|
|
54
|
-
</button>
|
|
55
|
-
<button
|
|
56
|
-
@click="${() => this.dispatchAction(this.events.confirm)}"
|
|
57
|
-
class="button btn-proceed"
|
|
58
|
-
data-testid="${this.events.confirm}-btn"
|
|
59
|
-
id="${this.events.confirm}-btn"
|
|
60
|
-
>
|
|
61
|
-
Continue →
|
|
62
|
-
</button>
|
|
63
|
-
</div>
|
|
64
|
-
</div>
|
|
65
|
-
</div>
|
|
66
|
-
</div>`;
|
|
67
30
|
}
|
|
68
|
-
|
|
69
|
-
|
|
31
|
+
attributeChangedCallback(name, oldValue, newValue) {
|
|
32
|
+
if (oldValue !== newValue) {
|
|
33
|
+
this[name.replace(/-./g, (x) => x[1].toUpperCase())] = newValue;
|
|
34
|
+
this.render();
|
|
35
|
+
}
|
|
70
36
|
}
|
|
71
37
|
handleConfirmEvent({ type }) {
|
|
72
38
|
switch (type) {
|
|
@@ -78,45 +44,55 @@ class PopupConsent extends lit_1.LitElement {
|
|
|
78
44
|
break;
|
|
79
45
|
}
|
|
80
46
|
}
|
|
81
|
-
// no shadow-root
|
|
82
|
-
createRenderRoot() {
|
|
83
|
-
return this;
|
|
84
|
-
}
|
|
85
47
|
render() {
|
|
86
|
-
|
|
48
|
+
this.innerHTML = `
|
|
49
|
+
<style>
|
|
50
|
+
${(0, getStyles_1.getStyles)(constants_1.confirmationDialogTag)}
|
|
51
|
+
</style>
|
|
52
|
+
<div id="${constants_1.confirmationDialogTag}">
|
|
53
|
+
<div class="content">
|
|
54
|
+
<div class="body">
|
|
55
|
+
<div class="title">Confirm on MultiversX Wallet</div>
|
|
56
|
+
<div class="subtitle">Continue to ${this.walletUrl}</div>
|
|
57
|
+
<div class="actions-container">
|
|
58
|
+
<button
|
|
59
|
+
class="button"
|
|
60
|
+
data-testid="${this.events.cancel}-btn"
|
|
61
|
+
id="${this.events.cancel}-btn"
|
|
62
|
+
>
|
|
63
|
+
Cancel
|
|
64
|
+
</button>
|
|
65
|
+
<button
|
|
66
|
+
class="button btn-proceed"
|
|
67
|
+
data-testid="${this.events.confirm}-btn"
|
|
68
|
+
id="${this.events.confirm}-btn"
|
|
69
|
+
>
|
|
70
|
+
Continue →
|
|
71
|
+
</button>
|
|
72
|
+
</div>
|
|
73
|
+
</div>
|
|
74
|
+
</div>
|
|
75
|
+
</div>
|
|
76
|
+
`;
|
|
87
77
|
}
|
|
88
78
|
toggleEvents(action) {
|
|
89
79
|
[this.events.cancel, this.events.confirm].forEach((event) => {
|
|
80
|
+
var _a;
|
|
81
|
+
(_a = this.querySelector(`#${event}-btn`)) === null || _a === void 0 ? void 0 : _a[action]('click', () => this.dispatchAction(event));
|
|
90
82
|
this[action](event, this.handleConfirmEvent);
|
|
91
83
|
});
|
|
92
84
|
}
|
|
93
85
|
connectedCallback() {
|
|
94
|
-
|
|
86
|
+
this.render();
|
|
95
87
|
this.toggleEvents('addEventListener');
|
|
96
88
|
}
|
|
97
89
|
disconnectedCallback() {
|
|
98
|
-
super.disconnectedCallback();
|
|
99
90
|
this.toggleEvents('removeEventListener');
|
|
100
91
|
}
|
|
101
92
|
}
|
|
102
|
-
__decorate([
|
|
103
|
-
(0, decorators_js_1.property)({ type: String })
|
|
104
|
-
], PopupConsent.prototype, "id", void 0);
|
|
105
|
-
__decorate([
|
|
106
|
-
(0, decorators_js_1.property)({ type: String })
|
|
107
|
-
], PopupConsent.prototype, "walletUrl", void 0);
|
|
108
|
-
__decorate([
|
|
109
|
-
(0, decorators_js_1.property)({ type: Function })
|
|
110
|
-
], PopupConsent.prototype, "onConfirm", void 0);
|
|
111
|
-
__decorate([
|
|
112
|
-
(0, decorators_js_1.property)({ type: Function })
|
|
113
|
-
], PopupConsent.prototype, "onCancel", void 0);
|
|
114
|
-
__decorate([
|
|
115
|
-
(0, decorators_js_1.property)({ type: Function })
|
|
116
|
-
], PopupConsent.prototype, "getTemplate", void 0);
|
|
117
93
|
exports.PopupConsent = PopupConsent;
|
|
118
94
|
const customElements = crossWindowProviderConstants_1.safeWindow === null || crossWindowProviderConstants_1.safeWindow === void 0 ? void 0 : crossWindowProviderConstants_1.safeWindow.customElements;
|
|
119
|
-
if (customElements && !customElements.get(
|
|
120
|
-
customElements.define(
|
|
95
|
+
if (customElements && !customElements.get(constants_1.confirmationDialogTag)) {
|
|
96
|
+
customElements.define(constants_1.confirmationDialogTag, PopupConsent);
|
|
121
97
|
}
|
|
122
98
|
//# sourceMappingURL=PopupConsent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PopupConsent.js","sourceRoot":"","sources":["../../../src/CrossWindowProvider/PopupConsent/PopupConsent.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"PopupConsent.js","sourceRoot":"","sources":["../../../src/CrossWindowProvider/PopupConsent/PopupConsent.ts"],"names":[],"mappings":";;;AAAA,wHAAmG;AACnG,2CAAoD;AACpD,2CAAwC;AAExC,MAAa,YAAa,SAAQ,WAAW;IAU3C;QACE,KAAK,EAAE,CAAC;QAVH,cAAS,GAAG,EAAE,CAAC;QACf,eAAU,GAAW,iCAAqB,CAAC;QAC3C,aAAQ,GAAG,GAAG,EAAE;YACrB,OAAO,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC;QAC1B,CAAC,CAAC;QACK,cAAS,GAAG,GAAG,EAAE;YACtB,OAAO,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC;QAC3B,CAAC,CAAC;QAaK,WAAM,GAAG;YACd,OAAO,EAAE,GAAG,IAAI,CAAC,UAAU,UAAU;YACrC,MAAM,EAAE,GAAG,IAAI,CAAC,UAAU,SAAS;YACnC,OAAO,EAAE,GAAG,IAAI,CAAC,UAAU,UAAU;SACtC,CAAC;QAaM,mBAAc,GAAG,CAAC,IAAY,EAAE,EAAE;YACxC,MAAM,KAAK,GAAG,IAAI,WAAW,CAAC,IAAI,EAAE;gBAClC,OAAO,EAAE,IAAI;gBACb,QAAQ,EAAE,IAAI,CAAC,mDAAmD;aACnE,CAAC,CAAC;YACH,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;QAC5B,CAAC,CAAC;IAhCF,CAAC;IAED,wBAAwB,CAAC,IAAY,EAAE,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,CAAC,kBAAmC,CAAC,CAAC;QAChE,CAAC,CAAC,CAAC;IACL,CAAC;IAED,iBAAiB;QACf,IAAI,CAAC,MAAM,EAAE,CAAC;QACd,IAAI,CAAC,YAAY,CAAC,kBAAkB,CAAC,CAAC;IACxC,CAAC;IAED,oBAAoB;QAClB,IAAI,CAAC,YAAY,CAAC,qBAAqB,CAAC,CAAC;IAC3C,CAAC;CACF;AA/FD,oCA+FC;AAED,MAAM,cAAc,GAAG,yCAAU,aAAV,yCAAU,uBAAV,yCAAU,CAAE,cAAc,CAAC;AAClD,IAAI,cAAc,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,iCAAqB,CAAC,EAAE;IAChE,cAAc,CAAC,MAAM,CAAC,iCAAqB,EAAE,YAAY,CAAC,CAAC;CAC5D"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const confirmationDialogTag = "mxcwp-confirmation-dialog";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../src/CrossWindowProvider/PopupConsent/constants.ts"],"names":[],"mappings":";;;AAAa,QAAA,qBAAqB,GAAG,2BAA2B,CAAC"}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.getStyles = void 0;
|
|
4
|
-
const
|
|
5
|
-
const getStyles = (dialogId) => `#${(0, lit_1.unsafeCSS)(dialogId)} {
|
|
4
|
+
const getStyles = (dialogId) => `#${dialogId} {
|
|
6
5
|
position: fixed;
|
|
7
6
|
z-index: 9999;
|
|
8
7
|
padding-top: 100px;
|
|
@@ -17,14 +16,14 @@ const getStyles = (dialogId) => `#${(0, lit_1.unsafeCSS)(dialogId)} {
|
|
|
17
16
|
align-items: center;
|
|
18
17
|
}
|
|
19
18
|
|
|
20
|
-
#${
|
|
19
|
+
#${dialogId}:modal {
|
|
21
20
|
max-width: 100vw;
|
|
22
21
|
width: 100vw;
|
|
23
22
|
max-height: 100vh;
|
|
24
23
|
height: 100vh;
|
|
25
24
|
}
|
|
26
25
|
|
|
27
|
-
#${
|
|
26
|
+
#${dialogId} .content {
|
|
28
27
|
background: #fff;
|
|
29
28
|
border-radius: 20px;
|
|
30
29
|
z-index: 9999;
|
|
@@ -35,21 +34,21 @@ const getStyles = (dialogId) => `#${(0, lit_1.unsafeCSS)(dialogId)} {
|
|
|
35
34
|
width: 100%;
|
|
36
35
|
}
|
|
37
36
|
|
|
38
|
-
#${
|
|
37
|
+
#${dialogId} .body {
|
|
39
38
|
padding: 50px 0;
|
|
40
39
|
color: #262525;
|
|
41
40
|
}
|
|
42
41
|
|
|
43
|
-
#${
|
|
42
|
+
#${dialogId} .title {
|
|
44
43
|
text-align: center;
|
|
45
44
|
font-size: 1.5rem;
|
|
46
45
|
}
|
|
47
|
-
#${
|
|
46
|
+
#${dialogId} .subtitle {
|
|
48
47
|
margin-top: 10px;
|
|
49
48
|
text-align: center;
|
|
50
49
|
}
|
|
51
50
|
|
|
52
|
-
#${
|
|
51
|
+
#${dialogId} .actions-container {
|
|
53
52
|
margin-top: 40px;
|
|
54
53
|
margin-bottom: 10px;
|
|
55
54
|
display: flex;
|
|
@@ -57,12 +56,12 @@ const getStyles = (dialogId) => `#${(0, lit_1.unsafeCSS)(dialogId)} {
|
|
|
57
56
|
gap: 20px;
|
|
58
57
|
}
|
|
59
58
|
|
|
60
|
-
#${
|
|
59
|
+
#${dialogId} .button {
|
|
61
60
|
max-width: 200px;
|
|
62
61
|
margin-top: 10px;
|
|
63
62
|
}
|
|
64
63
|
|
|
65
|
-
#${
|
|
64
|
+
#${dialogId} button {
|
|
66
65
|
border-radius: 8px;
|
|
67
66
|
border: 1px solid transparent;
|
|
68
67
|
padding: 0.6em 1.2em;
|
|
@@ -73,15 +72,15 @@ const getStyles = (dialogId) => `#${(0, lit_1.unsafeCSS)(dialogId)} {
|
|
|
73
72
|
cursor: pointer;
|
|
74
73
|
transition: border-color 0.25s;
|
|
75
74
|
}
|
|
76
|
-
#${
|
|
75
|
+
#${dialogId} button:hover {
|
|
77
76
|
border-color: #cacaca;
|
|
78
77
|
}
|
|
79
|
-
#${
|
|
80
|
-
#${
|
|
78
|
+
#${dialogId} button:focus,
|
|
79
|
+
#${dialogId} button:focus-visible {
|
|
81
80
|
outline: 4px auto -webkit-focus-ring-color;
|
|
82
81
|
}
|
|
83
82
|
|
|
84
|
-
#${
|
|
83
|
+
#${dialogId} .btn-proceed {
|
|
85
84
|
background-color: #262626;
|
|
86
85
|
color: #fff;
|
|
87
86
|
padding-left: 40px;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getStyles.js","sourceRoot":"","sources":["../../../src/CrossWindowProvider/PopupConsent/getStyles.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"getStyles.js","sourceRoot":"","sources":["../../../src/CrossWindowProvider/PopupConsent/getStyles.ts"],"names":[],"mappings":";;;AAAO,MAAM,SAAS,GAAG,CAAC,QAAgB,EAAE,EAAE,CAAC,IAAI,QAAQ;;;;;;;;;;;;;;;GAexD,QAAQ;;;;;;;GAOR,QAAQ;;;;;;;;;;;GAWR,QAAQ;;;;;GAKR,QAAQ;;;;GAIR,QAAQ;;;;;GAKR,QAAQ;;;;;;;;GAQR,QAAQ;;;;;GAKR,QAAQ;;;;;;;;;;;GAWR,QAAQ;;;GAGR,QAAQ;GACR,QAAQ;;;;GAIR,QAAQ;;;;;EAKT,CAAC;AApFU,QAAA,SAAS,aAoFnB"}
|
|
@@ -31,8 +31,8 @@ describe('CrossWindowProvider Login', () => {
|
|
|
31
31
|
it('should cancel an action correctly', () => __awaiter(void 0, void 0, void 0, function* () {
|
|
32
32
|
yield crossWindowProvider.init();
|
|
33
33
|
const result = yield crossWindowProvider.cancelAction();
|
|
34
|
-
// expect(result).toEqual({ payload: {} });
|
|
35
34
|
expect(result).toEqual(undefined);
|
|
35
|
+
// expect(result).toEqual({ payload: {} });
|
|
36
36
|
}));
|
|
37
37
|
});
|
|
38
38
|
//# sourceMappingURL=Cancel.test.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Cancel.test.js","sourceRoot":"","sources":["../../../src/CrossWindowProvider/tests/Cancel.test.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,iDAI0B;AAC1B,qEAAkE;AAClE,gEAA6D;AAE7D,QAAQ,CAAC,2BAA2B,EAAE,GAAG,EAAE;IACzC,IAAI,mBAAwC,CAAC;IAC7C,IAAI,gBAAsC,CAAC;IAC3C,IAAI,aAA+B,CAAC;IAEpC,UAAU,CAAC,GAAG,EAAE;QACd,gBAAgB,GAAG,IAAA,gCAAmB,GAAE,CAAC;QACzC,6BAAa,CAAC,WAAW,EAAE,CAAC,WAAW,GAAG,IAAI;aAC3C,EAAE,EAAE;aACJ,kBAAkB,CAAC,GAAG,EAAE,CAAC,CAAC;YACzB,OAAO,EAAE,EAAE;SACZ,CAAC,CAAC,CAAC;QAEN,mBAAmB,GAAG,yCAAmB,CAAC,WAAW,EAAE,CAAC;QACxD,IAAA,6BAAgB,GAAE,CAAC;QACnB,aAAa,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;QAC3C,aAAa,CAAC,kBAAkB,CAAC,GAAG,EAAE,CAAC,gBAAgB,CAAC,CAAC;IAC3D,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,mCAAmC,EAAE,GAAS,EAAE;QACjD,MAAM,mBAAmB,CAAC,IAAI,EAAE,CAAC;QACjC,MAAM,MAAM,GAAG,MAAM,mBAAmB,CAAC,YAAY,EAAE,CAAC;QACxD,
|
|
1
|
+
{"version":3,"file":"Cancel.test.js","sourceRoot":"","sources":["../../../src/CrossWindowProvider/tests/Cancel.test.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,iDAI0B;AAC1B,qEAAkE;AAClE,gEAA6D;AAE7D,QAAQ,CAAC,2BAA2B,EAAE,GAAG,EAAE;IACzC,IAAI,mBAAwC,CAAC;IAC7C,IAAI,gBAAsC,CAAC;IAC3C,IAAI,aAA+B,CAAC;IAEpC,UAAU,CAAC,GAAG,EAAE;QACd,gBAAgB,GAAG,IAAA,gCAAmB,GAAE,CAAC;QACzC,6BAAa,CAAC,WAAW,EAAE,CAAC,WAAW,GAAG,IAAI;aAC3C,EAAE,EAAE;aACJ,kBAAkB,CAAC,GAAG,EAAE,CAAC,CAAC;YACzB,OAAO,EAAE,EAAE;SACZ,CAAC,CAAC,CAAC;QAEN,mBAAmB,GAAG,yCAAmB,CAAC,WAAW,EAAE,CAAC;QACxD,IAAA,6BAAgB,GAAE,CAAC;QACnB,aAAa,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;QAC3C,aAAa,CAAC,kBAAkB,CAAC,GAAG,EAAE,CAAC,gBAAgB,CAAC,CAAC;IAC3D,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,mCAAmC,EAAE,GAAS,EAAE;QACjD,MAAM,mBAAmB,CAAC,IAAI,EAAE,CAAC;QACjC,MAAM,MAAM,GAAG,MAAM,mBAAmB,CAAC,YAAY,EAAE,CAAC;QACxD,MAAM,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;QAClC,2CAA2C;IAC7C,CAAC,CAAA,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@multiversx/sdk-web-wallet-cross-window-provider",
|
|
3
|
-
"version": "0.1.3-alpha.
|
|
3
|
+
"version": "0.1.3-alpha.6",
|
|
4
4
|
"description": "Signing provider for dApps: Cross Window",
|
|
5
5
|
"main": "out/index.js",
|
|
6
|
-
"module": "out/index.mjs",
|
|
7
6
|
"types": "out/index.d.js",
|
|
8
7
|
"files": [
|
|
9
8
|
"out/**/*"
|
|
@@ -12,9 +11,7 @@
|
|
|
12
11
|
"node": ">=18"
|
|
13
12
|
},
|
|
14
13
|
"scripts": {
|
|
15
|
-
"compile": "tsc
|
|
16
|
-
"build-esbuild": "rimraf out && node esbuild.js",
|
|
17
|
-
"build": "yarn build-esbuild && yarn compile",
|
|
14
|
+
"compile": "tsc -p tsconfig.json",
|
|
18
15
|
"pretest": "npm run compile",
|
|
19
16
|
"prepare": "npm run compile",
|
|
20
17
|
"lint": "eslint --fix --ext js,ts src",
|
|
@@ -28,7 +25,6 @@
|
|
|
28
25
|
"@types/node": "18.19.0",
|
|
29
26
|
"@typescript-eslint/eslint-plugin": "5.0.0",
|
|
30
27
|
"@typescript-eslint/parser": "5.14.0",
|
|
31
|
-
"esbuild": "^0.21.4",
|
|
32
28
|
"eslint": "8.24.0",
|
|
33
29
|
"eslint-config-prettier": "8.5.0",
|
|
34
30
|
"eslint-config-standard": "17.0.0",
|
|
@@ -42,13 +38,11 @@
|
|
|
42
38
|
"jest-environment-jsdom": "28.1.3",
|
|
43
39
|
"prettier": "3.1.0",
|
|
44
40
|
"ts-jest": "29.1.1",
|
|
45
|
-
"tsc-alias": "^1.8.10",
|
|
46
41
|
"typescript": "5.0.4"
|
|
47
42
|
},
|
|
48
43
|
"peerDependencies": {
|
|
49
44
|
"@multiversx/sdk-core": ">= 12.18.0",
|
|
50
|
-
"@multiversx/sdk-dapp-utils": ">= 0.0.1"
|
|
51
|
-
"lit": ">=3.1.2"
|
|
45
|
+
"@multiversx/sdk-dapp-utils": ">= 0.0.1"
|
|
52
46
|
},
|
|
53
47
|
"dependencies": {
|
|
54
48
|
"@types/jest": "^29.5.11",
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a}from"../__chunks__/chunk-MFDD33CC.mjs";import"../__chunks__/chunk-IFJNPC67.mjs";import"../__chunks__/chunk-ILRVZBDL.mjs";import"../__chunks__/chunk-7BAKJMGJ.mjs";import"../__chunks__/chunk-UHIELAL2.mjs";import"../__chunks__/chunk-X6LLUYE7.mjs";import"../__chunks__/chunk-67SNURO7.mjs";import"../__chunks__/chunk-CRKVTTK2.mjs";import"../__chunks__/chunk-PE2DWF25.mjs";import"../__chunks__/chunk-ARPF4OON.mjs";export{a as CrossWindowProvider};
|
|
2
|
-
//# sourceMappingURL=CrossWindowProvider.mjs.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a,b,c}from"../../__chunks__/chunk-UHIELAL2.mjs";import"../../__chunks__/chunk-X6LLUYE7.mjs";import"../../__chunks__/chunk-67SNURO7.mjs";import"../../__chunks__/chunk-ARPF4OON.mjs";c();export{b as PopupConsent,a as confirmationDialogTag};
|
|
2
|
-
//# sourceMappingURL=PopupConsent.mjs.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{b as c}from"../../__chunks__/chunk-7BAKJMGJ.mjs";import{a,b}from"../../__chunks__/chunk-UHIELAL2.mjs";import"../../__chunks__/chunk-X6LLUYE7.mjs";import"../../__chunks__/chunk-67SNURO7.mjs";import"../../__chunks__/chunk-ARPF4OON.mjs";c();export{b as PopupConsent,a as confirmationDialogTag};
|
|
2
|
-
//# sourceMappingURL=index.mjs.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import"../__chunks__/chunk-7EG66KV4.mjs";import{a as c}from"../__chunks__/chunk-MFDD33CC.mjs";import"../__chunks__/chunk-IFJNPC67.mjs";import"../__chunks__/chunk-ILRVZBDL.mjs";import"../__chunks__/chunk-7BAKJMGJ.mjs";import{a,b}from"../__chunks__/chunk-UHIELAL2.mjs";import"../__chunks__/chunk-X6LLUYE7.mjs";import"../__chunks__/chunk-67SNURO7.mjs";import"../__chunks__/chunk-CRKVTTK2.mjs";import"../__chunks__/chunk-PE2DWF25.mjs";import"../__chunks__/chunk-ARPF4OON.mjs";export{c as CrossWindowProvider,b as PopupConsent,a as confirmationDialogTag};
|
|
2
|
-
//# sourceMappingURL=index.mjs.map
|