@social-mail/social-mail-client 1.2.641 → 1.2.642
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/admin/AdminAppIndex.pack.js +481 -78
- package/dist/admin/AdminAppIndex.pack.js.map +1 -1
- package/dist/admin/AdminAppIndex.pack.min.js +6 -6
- package/dist/admin/AdminAppIndex.pack.min.js.map +1 -1
- package/dist/common/commands/CommonCommands.d.ts +3 -0
- package/dist/common/commands/CommonCommands.d.ts.map +1 -1
- package/dist/common/commands/CommonCommands.js +4 -0
- package/dist/common/commands/CommonCommands.js.map +1 -1
- package/dist/common/controls/phone-editor/PhoneEditor.d.ts +3 -0
- package/dist/common/controls/phone-editor/PhoneEditor.d.ts.map +1 -1
- package/dist/common/controls/phone-editor/PhoneEditor.js +25 -4
- package/dist/common/controls/phone-editor/PhoneEditor.js.map +1 -1
- package/dist/common/pages/stores/StoreDetailPage.js +1 -1
- package/dist/common/pages/stores/StoreDetailPage.js.map +1 -1
- package/dist/common/pages/stores/payment-gateway/PaymentGatewayEditorPage.d.ts +10 -0
- package/dist/common/pages/stores/payment-gateway/PaymentGatewayEditorPage.d.ts.map +1 -0
- package/dist/common/pages/stores/payment-gateway/PaymentGatewayEditorPage.js +87 -0
- package/dist/common/pages/stores/payment-gateway/PaymentGatewayEditorPage.js.map +1 -0
- package/dist/common/pages/stores/payment-gateway/PaymentGatewayListPage.d.ts +23 -0
- package/dist/common/pages/stores/payment-gateway/PaymentGatewayListPage.d.ts.map +1 -0
- package/dist/common/pages/stores/payment-gateway/PaymentGatewayListPage.js +129 -0
- package/dist/common/pages/stores/payment-gateway/PaymentGatewayListPage.js.map +1 -0
- package/dist/model/model.d.ts +36 -7
- package/dist/model/model.d.ts.map +1 -1
- package/dist/model/model.js +145 -20
- package/dist/model/model.js.map +1 -1
- package/dist/public/channel/ChannelView.pack.js +253 -76
- package/dist/public/channel/ChannelView.pack.js.map +1 -1
- package/dist/public/channel/ChannelView.pack.min.js +2 -2
- package/dist/public/channel/ChannelView.pack.min.js.map +1 -1
- package/dist/public/preview/zip/DownloadZip.pack.js +253 -76
- package/dist/public/preview/zip/DownloadZip.pack.js.map +1 -1
- package/dist/public/preview/zip/DownloadZip.pack.min.js +1 -1
- package/dist/public/preview/zip/DownloadZip.pack.min.js.map +1 -1
- package/dist/public/store/Store.d.ts +2 -2
- package/dist/public/store/Store.d.ts.map +1 -1
- package/dist/public/store/Store.js +29 -7
- package/dist/public/store/Store.js.map +1 -1
- package/dist/public/store/Store.pack.js +19797 -18064
- package/dist/public/store/Store.pack.js.map +1 -1
- package/dist/public/store/Store.pack.min.js +370 -161
- package/dist/public/store/Store.pack.min.js.map +1 -1
- package/dist/public/store/StoreItemDetailView.d.ts +1 -0
- package/dist/public/store/StoreItemDetailView.d.ts.map +1 -1
- package/dist/public/store/StoreItemDetailView.js +24 -8
- package/dist/public/store/StoreItemDetailView.js.map +1 -1
- package/dist/public/store/StoreItemListView.d.ts.map +1 -1
- package/dist/public/store/StoreItemListView.js +7 -4
- package/dist/public/store/StoreItemListView.js.map +1 -1
- package/dist/public/store/StoreUrlService.d.ts +22 -15
- package/dist/public/store/StoreUrlService.d.ts.map +1 -1
- package/dist/public/store/StoreUrlService.js +39 -12
- package/dist/public/store/StoreUrlService.js.map +1 -1
- package/dist/public/store/cart/ShoppingCart.pack.js +253 -76
- package/dist/public/store/cart/ShoppingCart.pack.js.map +1 -1
- package/dist/public/store/cart/ShoppingCart.pack.min.js +2 -2
- package/dist/public/store/cart/ShoppingCart.pack.min.js.map +1 -1
- package/dist/public/user/SiteLogin.d.ts +28 -0
- package/dist/public/user/SiteLogin.d.ts.map +1 -0
- package/dist/public/user/SiteLogin.js +231 -0
- package/dist/public/user/SiteLogin.js.map +1 -0
- package/dist/public/user/WebSiteUserService.d.ts +10 -0
- package/dist/public/user/WebSiteUserService.d.ts.map +1 -0
- package/dist/public/user/WebSiteUserService.js +52 -0
- package/dist/public/user/WebSiteUserService.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/web/AppIndex.pack.js +481 -78
- package/dist/web/AppIndex.pack.js.map +1 -1
- package/dist/web/AppIndex.pack.min.js +6 -6
- package/dist/web/AppIndex.pack.min.js.map +1 -1
- package/node_modules/@web-atoms/entity/dist/services/BaseEntityService.d.ts +1 -1
- package/node_modules/@web-atoms/entity/dist/services/BaseEntityService.d.ts.map +1 -1
- package/node_modules/@web-atoms/entity/dist/services/BaseEntityService.js +108 -56
- package/node_modules/@web-atoms/entity/dist/services/BaseEntityService.js.map +1 -1
- package/node_modules/@web-atoms/entity/dist/tsconfig.tsbuildinfo +1 -1
- package/node_modules/@web-atoms/entity/package.json +1 -1
- package/node_modules/@web-atoms/entity/src/services/BaseEntityService.ts +109 -54
- package/package.json +2 -2
- package/src/common/commands/CommonCommands.ts +5 -0
- package/src/common/controls/phone-editor/PhoneEditor.tsx +24 -1
- package/src/common/pages/stores/StoreDetailPage.tsx +1 -1
- package/src/common/pages/stores/payment-gateway/PaymentGatewayEditorPage.tsx +62 -0
- package/src/common/pages/stores/payment-gateway/PaymentGatewayListPage.tsx +94 -0
- package/src/model/model.ts +49 -14
- package/src/public/store/Store.tsx +18 -4
- package/src/public/store/StoreItemDetailView.tsx +17 -4
- package/src/public/store/StoreItemListView.tsx +4 -2
- package/src/public/store/StoreUrlService.ts +62 -27
- package/src/public/user/SiteLogin.tsx +251 -0
- package/src/public/user/WebSiteUserService.ts +39 -0
|
@@ -3,21 +3,28 @@ import { toBase36 } from "../../common/toBase36";
|
|
|
3
3
|
import { IStoreItem } from "../../model/model";
|
|
4
4
|
|
|
5
5
|
export type IStorePageParameters = {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
6
|
+
login?: {
|
|
7
|
+
storeID: any;
|
|
8
|
+
},
|
|
9
|
+
buy?: {
|
|
10
|
+
productID: any,
|
|
11
|
+
currency: string
|
|
12
|
+
},
|
|
13
|
+
detail?: {
|
|
14
|
+
storeID: any,
|
|
15
|
+
productID: any,
|
|
16
|
+
currency: any,
|
|
17
|
+
},
|
|
18
|
+
order?: {
|
|
19
|
+
storeID: any;
|
|
20
|
+
orderID: any;
|
|
21
|
+
}
|
|
22
|
+
orders?: {
|
|
23
|
+
storeID: any,
|
|
24
|
+
},
|
|
25
|
+
checkout?: {
|
|
26
|
+
orderID: any;
|
|
27
|
+
}
|
|
21
28
|
};
|
|
22
29
|
|
|
23
30
|
export const StoreUrlService = {
|
|
@@ -26,7 +33,7 @@ export const StoreUrlService = {
|
|
|
26
33
|
const storeID = toBase36(p.storeID);
|
|
27
34
|
const productID = toBase36(p.variantForID ?? p.storeItemID);
|
|
28
35
|
if (AppLocation.isLocalTesting) {
|
|
29
|
-
return `?detail
|
|
36
|
+
return `?detail=store/${storeID}/${productID}`;
|
|
30
37
|
}
|
|
31
38
|
return `/store/${storeID}/${productID}/${encodeURIComponent(p.name)}`;
|
|
32
39
|
},
|
|
@@ -42,29 +49,57 @@ export const StoreUrlService = {
|
|
|
42
49
|
}
|
|
43
50
|
|
|
44
51
|
const {
|
|
45
|
-
1:
|
|
46
|
-
2:
|
|
47
|
-
3:
|
|
52
|
+
1: root,
|
|
53
|
+
2: route,
|
|
54
|
+
3: p1,
|
|
55
|
+
4: p2
|
|
48
56
|
} = /^\/([^\/]+)\/([^\/]+)\/?([^\/]+)?\/?/.exec(pathname) ?? [];
|
|
49
57
|
|
|
58
|
+
if (root !== "store") {
|
|
59
|
+
return {};
|
|
60
|
+
}
|
|
61
|
+
|
|
50
62
|
switch(route) {
|
|
63
|
+
case "login":
|
|
64
|
+
return {
|
|
65
|
+
login: {
|
|
66
|
+
storeID: p1
|
|
67
|
+
}
|
|
68
|
+
};
|
|
69
|
+
case "orders":
|
|
70
|
+
return {
|
|
71
|
+
orders: {
|
|
72
|
+
storeID: p1
|
|
73
|
+
}
|
|
74
|
+
};
|
|
75
|
+
case "orders":
|
|
76
|
+
return {
|
|
77
|
+
order: {
|
|
78
|
+
storeID: p1,
|
|
79
|
+
orderID: p2
|
|
80
|
+
}
|
|
81
|
+
};
|
|
51
82
|
case "buy":
|
|
52
83
|
return {
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
84
|
+
buy: {
|
|
85
|
+
productID: p1,
|
|
86
|
+
currency: p2 || "INR"
|
|
87
|
+
}
|
|
56
88
|
};
|
|
57
89
|
case "checkout":
|
|
58
90
|
return {
|
|
59
|
-
|
|
60
|
-
|
|
91
|
+
checkout: {
|
|
92
|
+
orderID: p1
|
|
93
|
+
}
|
|
61
94
|
};
|
|
62
95
|
}
|
|
63
96
|
|
|
64
97
|
return {
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
98
|
+
detail: {
|
|
99
|
+
storeID: route,
|
|
100
|
+
productID: p1,
|
|
101
|
+
currency: p2 || "INR"
|
|
102
|
+
}
|
|
68
103
|
};
|
|
69
104
|
|
|
70
105
|
}
|
|
@@ -0,0 +1,251 @@
|
|
|
1
|
+
import Bind from "@web-atoms/core/dist/core/Bind";
|
|
2
|
+
import XNode from "@web-atoms/core/dist/core/XNode";
|
|
3
|
+
import styled from "@web-atoms/core/dist/style/styled";
|
|
4
|
+
import { AtomControl } from "@web-atoms/core/dist/web/controls/AtomControl";
|
|
5
|
+
import Form from "@web-atoms/web-controls/dist/basic/Form";
|
|
6
|
+
import FormField from "@web-atoms/web-controls/dist/basic/FormField";
|
|
7
|
+
import ToggleButtonBar from "@web-atoms/web-controls/dist/basic/ToggleButtonBar";
|
|
8
|
+
import PhoneEditor from "../../common/controls/phone-editor/PhoneEditor";
|
|
9
|
+
import { EmailIconButton, EmailIconTextButton, SaveIconTextButton, UploadIconButton } from "../../common/controls/buttons/IconButton";
|
|
10
|
+
import Action from "@web-atoms/core/dist/view-model/Action";
|
|
11
|
+
import InjectProperty from "@web-atoms/core/dist/core/InjectProperty";
|
|
12
|
+
import EntityService from "../../services/EntityService";
|
|
13
|
+
import { IVerificationToken, VerificationToken, VerificationTokenAddress } from "../../model/model";
|
|
14
|
+
import Loader from "../../common/controls/Loader";
|
|
15
|
+
import { AtomDisposableList } from "@web-atoms/core/dist/core/AtomDisposableList";
|
|
16
|
+
import { StringHelper } from "@web-atoms/core/dist/core/StringHelper";
|
|
17
|
+
import QRCodeControl from "../../common/controls/qrcode/QRCode";
|
|
18
|
+
|
|
19
|
+
styled.css `
|
|
20
|
+
position: absolute;
|
|
21
|
+
left: 0;
|
|
22
|
+
top: 0;
|
|
23
|
+
width: 100%;
|
|
24
|
+
height: 100vh;
|
|
25
|
+
|
|
26
|
+
background-color: canvas;
|
|
27
|
+
|
|
28
|
+
display: grid;
|
|
29
|
+
align-items: center;
|
|
30
|
+
justify-items: center;
|
|
31
|
+
|
|
32
|
+
`.installGlobal("site-login");
|
|
33
|
+
|
|
34
|
+
styled.css `
|
|
35
|
+
& [styler-layout=component] {
|
|
36
|
+
position: relative;
|
|
37
|
+
}
|
|
38
|
+
`.installGlobal("body");
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
export interface IVerification {
|
|
42
|
+
id: any;
|
|
43
|
+
accessCode: string;
|
|
44
|
+
code: string;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
export interface IUserModel {
|
|
48
|
+
emailAddress?: string;
|
|
49
|
+
phoneNumber?: string;
|
|
50
|
+
name?: string;
|
|
51
|
+
|
|
52
|
+
email?: IVerification;
|
|
53
|
+
phone?: IVerification;
|
|
54
|
+
captcha?: IVerification;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
const verifyModes = [
|
|
58
|
+
{ label: "Email", value: "email" },
|
|
59
|
+
{ label: "Cell Phone", value: "phone" }
|
|
60
|
+
];
|
|
61
|
+
|
|
62
|
+
export default class SiteLogin extends AtomControl {
|
|
63
|
+
|
|
64
|
+
@InjectProperty
|
|
65
|
+
entityService: EntityService;
|
|
66
|
+
|
|
67
|
+
model: IUserModel = { emailAddress: "", phoneNumber: "", name: "" };
|
|
68
|
+
|
|
69
|
+
verifyMode: string = "email";
|
|
70
|
+
|
|
71
|
+
constructor(app, e = document.createElement("site-login")) {
|
|
72
|
+
super(app, e);
|
|
73
|
+
this.element.setAttribute("site-login", "true");
|
|
74
|
+
this.pushInit();
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
async init() {
|
|
78
|
+
|
|
79
|
+
this.renderer = <div><Loader/></div>;
|
|
80
|
+
|
|
81
|
+
await this.verifyCaptcha();
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
async verifyCaptcha() {
|
|
85
|
+
|
|
86
|
+
const captcha = await this.entityService.save(VerificationToken.create({
|
|
87
|
+
type: "captcha"
|
|
88
|
+
}));
|
|
89
|
+
|
|
90
|
+
const { verificationID: id, accessCode } = captcha;
|
|
91
|
+
|
|
92
|
+
this.model.captcha = {
|
|
93
|
+
id,
|
|
94
|
+
accessCode,
|
|
95
|
+
code: ""
|
|
96
|
+
};
|
|
97
|
+
|
|
98
|
+
this.renderer = <div>
|
|
99
|
+
<Form>
|
|
100
|
+
<FormField label="Captcha">
|
|
101
|
+
<img src={`/api/users/captcha/${id}/${accessCode}`}/>
|
|
102
|
+
</FormField>
|
|
103
|
+
<FormField label="Enter 5 Digit Code">
|
|
104
|
+
<input
|
|
105
|
+
type="tel"
|
|
106
|
+
value={Bind.twoWaysImmediate(() => this.model.captcha.code)}/>
|
|
107
|
+
</FormField>
|
|
108
|
+
<div>
|
|
109
|
+
<UploadIconButton data-submit-event="verify-captcha"/>
|
|
110
|
+
</div>
|
|
111
|
+
</Form>
|
|
112
|
+
</div>;
|
|
113
|
+
|
|
114
|
+
await this.waitForEvents("verify-captcha");
|
|
115
|
+
|
|
116
|
+
const v = await this.entityService.invoke(VerificationToken, "verifyCode", captcha, id, accessCode, this.model.captcha.code);
|
|
117
|
+
if (!v.verified) {
|
|
118
|
+
alert("Verification failed, try again");
|
|
119
|
+
await this.verifyCaptcha();
|
|
120
|
+
return;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
await this.displayCheckUserExists();
|
|
124
|
+
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
|
|
128
|
+
async displayCheckUserExists() {
|
|
129
|
+
this.renderer = <div>
|
|
130
|
+
<Form>
|
|
131
|
+
<FormField label="Verify">
|
|
132
|
+
<ToggleButtonBar items={verifyModes} value={Bind.twoWaysImmediate(() => this.verifyMode)} />
|
|
133
|
+
</FormField>
|
|
134
|
+
<FormField label="Email" style-display={Bind.oneWay(() => this.verifyMode === "email")}>
|
|
135
|
+
<input value={this.model.emailAddress} />
|
|
136
|
+
</FormField>
|
|
137
|
+
<FormField label="Cell Phone" style-display={Bind.oneWay(() => this.verifyMode === "phone")}>
|
|
138
|
+
<PhoneEditor value={Bind.twoWaysImmediate(() => this.model.phoneNumber)} />
|
|
139
|
+
</FormField>
|
|
140
|
+
<div>
|
|
141
|
+
<EmailIconTextButton
|
|
142
|
+
data-submit-event="proceed-verification"
|
|
143
|
+
/>
|
|
144
|
+
</div>
|
|
145
|
+
</Form>
|
|
146
|
+
</div>;
|
|
147
|
+
|
|
148
|
+
await this.waitForEvents("proceed-verification");
|
|
149
|
+
|
|
150
|
+
const isEmail = this.verifyMode === "email";
|
|
151
|
+
|
|
152
|
+
const type = isEmail ? "email" : "sms";
|
|
153
|
+
|
|
154
|
+
const address = isEmail ? this.model.emailAddress : this.model.phoneNumber;
|
|
155
|
+
|
|
156
|
+
const ve = VerificationToken.create({
|
|
157
|
+
type: "email",
|
|
158
|
+
addresses: [
|
|
159
|
+
VerificationTokenAddress.create({
|
|
160
|
+
address
|
|
161
|
+
})
|
|
162
|
+
]
|
|
163
|
+
});
|
|
164
|
+
|
|
165
|
+
await this.entityService.save(ve, (c) => c.include((x) => x.addresses));
|
|
166
|
+
|
|
167
|
+
if (!isEmail) {
|
|
168
|
+
this.renderer = <div>
|
|
169
|
+
<QRCodeControl
|
|
170
|
+
smsConfig={ve.smsConfig}
|
|
171
|
+
/>
|
|
172
|
+
</div>;
|
|
173
|
+
|
|
174
|
+
for (let index = 0; index < 5; index++) {
|
|
175
|
+
const v = await this.entityService.query(VerificationToken, "get", ve.verificationID, ve.accessCode)
|
|
176
|
+
.firstOrDefault();
|
|
177
|
+
if (v.verified) {
|
|
178
|
+
ve.verified = true;
|
|
179
|
+
break;
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
if (!ve.verified) {
|
|
184
|
+
await this.displayCheckUserExists();
|
|
185
|
+
return;
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
@Action({ onEvent: "verify-email"})
|
|
192
|
+
async verifyEmail() {
|
|
193
|
+
|
|
194
|
+
const address = this.model.emailAddress;
|
|
195
|
+
|
|
196
|
+
const ve = VerificationToken.create({
|
|
197
|
+
type: "email",
|
|
198
|
+
addresses: [
|
|
199
|
+
VerificationTokenAddress.create({
|
|
200
|
+
address
|
|
201
|
+
})
|
|
202
|
+
]
|
|
203
|
+
});
|
|
204
|
+
await this.entityService.save(ve, (c) => c);
|
|
205
|
+
|
|
206
|
+
this.renderer = <div>
|
|
207
|
+
<Form>
|
|
208
|
+
<FormField label="Code">
|
|
209
|
+
|
|
210
|
+
</FormField>
|
|
211
|
+
</Form>
|
|
212
|
+
</div>;
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
@Action({ onEvent: "verify-phone"})
|
|
216
|
+
async verifyPhone() {
|
|
217
|
+
const address = this.model.emailAddress;
|
|
218
|
+
|
|
219
|
+
const ve = VerificationToken.create({
|
|
220
|
+
type: "email",
|
|
221
|
+
addresses: [
|
|
222
|
+
VerificationTokenAddress.create({
|
|
223
|
+
address
|
|
224
|
+
})
|
|
225
|
+
]
|
|
226
|
+
});
|
|
227
|
+
await this.entityService.save(ve, (c) => c);
|
|
228
|
+
|
|
229
|
+
this.renderer = <div>
|
|
230
|
+
<Form>
|
|
231
|
+
<FormField label="Code">
|
|
232
|
+
|
|
233
|
+
</FormField>
|
|
234
|
+
</Form>
|
|
235
|
+
</div>;
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
private waitForEvents<T = any>( ... names: string[]): Promise<CustomEvent<T>> {
|
|
239
|
+
return new Promise((resolve, reject) => {
|
|
240
|
+
|
|
241
|
+
const d = new AtomDisposableList();
|
|
242
|
+
for (const n of names) {
|
|
243
|
+
const name = StringHelper.fromHyphenToCamel(n);
|
|
244
|
+
d.add(this.bindEvent(this.element, name, (ce: CustomEvent) => {
|
|
245
|
+
d.dispose();
|
|
246
|
+
resolve(ce);
|
|
247
|
+
} ));
|
|
248
|
+
}
|
|
249
|
+
});
|
|
250
|
+
}
|
|
251
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import DISingleton from "@web-atoms/core/dist/di/DISingleton";
|
|
2
|
+
import { IUser, LoginSession } from "../../model/model";
|
|
3
|
+
import { Inject } from "@web-atoms/core/dist/di/Inject";
|
|
4
|
+
import EntityService from "../../services/EntityService";
|
|
5
|
+
import SocialMailApp from "../../common/SocialMailApp";
|
|
6
|
+
import SiteLogin from "./SiteLogin";
|
|
7
|
+
import { App } from "@web-atoms/core/dist/App";
|
|
8
|
+
|
|
9
|
+
@DISingleton()
|
|
10
|
+
export default class WebSiteUserService {
|
|
11
|
+
|
|
12
|
+
@Inject
|
|
13
|
+
entityService: EntityService;
|
|
14
|
+
|
|
15
|
+
@Inject
|
|
16
|
+
app: App;
|
|
17
|
+
|
|
18
|
+
user: IUser = null;
|
|
19
|
+
|
|
20
|
+
public async getUser() {
|
|
21
|
+
this.user ??= (await this.entityService.query(LoginSession, "currentUser").firstOrDefault())?.user;
|
|
22
|
+
SocialMailApp.user = this.user;
|
|
23
|
+
if (this.user?.userID) {
|
|
24
|
+
// let start syncing...
|
|
25
|
+
// this.app.resolve(LocalDbService).syncAll(this.user.userID).catch(console.error);
|
|
26
|
+
return this.user;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
// request login..
|
|
31
|
+
const sl = new SiteLogin(this.app);
|
|
32
|
+
|
|
33
|
+
const c = document.body.querySelector(`[styler-layout="component"]`) ?? document.body;
|
|
34
|
+
c.appendChild(sl.element);
|
|
35
|
+
|
|
36
|
+
return this.user;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
}
|