@tapni/auth 1.0.3 → 1.0.5
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/.vite/manifest.json +106 -0
- package/dist/Account-Cuz87g_8.js +153 -0
- package/dist/Apps-DMds3Dv-.js +109 -0
- package/dist/Billing-BXlQEuNy.js +113 -0
- package/dist/CustomApp-CLCMXmMO.js +83 -0
- package/dist/General-dW73bMoR.js +479 -0
- package/dist/QR-D6ZGcPM0.js +41 -0
- package/dist/TapniAuth.es.js +4 -0
- package/dist/TapniAuth.umd.js +141 -0
- package/dist/install-L-cxSovH.js +18465 -0
- package/dist/style.css +1 -0
- package/dist/web-AXRKjAOB.js +92 -0
- package/dist/web-IFGkBi0t.js +86 -0
- package/dist/web-LIfHmYL2.js +54 -0
- package/dist/web-XbruGdlD.js +121 -0
- package/package.json +1 -1
- package/src/App.vue +15 -2
- package/src/components/{SSO.vue → DELETE_SSO.vue} +1 -7
- package/src/main.js +0 -1
- package/src/mixins/microsoft.mixin.js +0 -3
- package/src/mixins/okta.mixin.js +1 -1
- package/src/mixins/saml.mixin.js +1 -1
- package/src/routes.js +6 -0
- package/src/services/AuthService.js +6 -0
- package/src/services/MetadataService.js +10 -0
- package/src/store/locales/en.js +2 -1
- package/src/views/Apps.vue +17 -30
- package/src/views/Billing.vue +108 -0
- package/src/views/CustomApp.vue +14 -39
- package/src/views/General.vue +5 -4
- package/src/views/Login.vue +194 -159
- package/src/views/Security.vue +1 -1
- package/dist/assets/Account-CElX1bG1.js +0 -1
- package/dist/assets/Apps-B-GkviQb.css +0 -1
- package/dist/assets/Apps-DH6XpQ6k.js +0 -1
- package/dist/assets/CustomApp-D-PMGrCn.js +0 -1
- package/dist/assets/CustomApp-x1ZBgKin.css +0 -1
- package/dist/assets/General-BD2qnORR.js +0 -1
- package/dist/assets/General-OSR9oXHj.css +0 -1
- package/dist/assets/Inter-ZO3WBJgw.ttf +0 -0
- package/dist/assets/QR-CpmQl6vr.js +0 -1
- package/dist/assets/fontawesome-webfont-CQDK8MU3.ttf +0 -0
- package/dist/assets/fontawesome-webfont-DXgy9qkh.svg +0 -2671
- package/dist/assets/fontawesome-webfont-G5YE5S7X.eot +0 -0
- package/dist/assets/index-CNOQuLc_.css +0 -1
- package/dist/assets/index-DXEfDC45.js +0 -176
- package/dist/assets/web-1uupGAU9.js +0 -5
- package/dist/assets/web-BMHaq5cV.js +0 -1
- package/dist/assets/web-CvQGphDR.js +0 -1
- package/dist/assets/web-DMittTOZ.js +0 -1
- package/dist/assets/web-DhQdITWf.js +0 -1
- package/dist/assets/web-EiIhTtxC.js +0 -1
- package/dist/assets/web-OwpPF4YF.js +0 -1
- package/dist/index.html +0 -36
- /package/src/components/{SSOPick.vue → DELETE_SSOPick.vue} +0 -0
package/dist/style.css
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.container{padding:10px 0 100px!important;display:flex;flex-direction:column;gap:10px}.settingsCard{background-color:#fff;padding:20px;border-radius:26px;align-items:center}.device{display:flex;align-items:center}h4{margin-left:20px;font-weight:700}.middle{flex:1}.left img{background-color:#f7f8f9;border-radius:20px;padding:10px}.divider{height:1px;background-color:#f0f0f0;margin:20px 0}.moreFooter{display:flex;align-items:center;justify-content:space-between;padding:0 10px}.settingRow{background-color:#f4f4f4;padding:10px 9px;border-radius:15px;cursor:pointer}.settingRow .firstRow,.settingRow .secondRow{display:flex;align-items:center;min-height:35px}.settingRow .firstRow h4{text-align:left;flex:1;margin-left:20px;font-weight:600;margin-bottom:0}.settingRow .secondRow{font-size:8px;margin-top:20px}.settingRow .secondRow p{flex:1;color:#999}.withBackground{background-color:#fff;border-radius:10px;padding:10px;width:50px}.ios-switch{position:relative;width:60px;padding-top:4px;padding-right:4px;margin-left:4px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none}.ios-switch-checkbox{display:none}.ios-switch-label{background-color:#e3e3e3;display:block;overflow:initial;cursor:pointer;height:30px;padding:0;line-height:20px;border:1px solid #e3e3e3;border-radius:25px;transition:all .25s ease}.ios-switch-label:before{content:"";display:block;width:30px;margin:0;position:absolute;top:0;bottom:0;right:24px;background-size:15px;background-repeat:no-repeat;background-position:center;border:2px solid #e3e3e3;border-radius:25px;transition:all .25s ease}.ios-switch-checkbox:checked+.ios-switch-label{background-color:#151515}.ios-switch-checkbox:checked+.ios-switch-label,.ios-switch-checkbox:checked+.ios-switch-label:before{border-color:#151515}.ios-switch-checkbox:checked+.ios-switch-label:before{right:-1px}.subheaderContainer{display:flex;align-items:center;position:relative;padding:15px 25px}.subheaderContainer .left-button{width:40px!important;height:40px!important;margin:0;border-radius:50%;background:#f4f4f4;display:flex;align-items:center;justify-content:center;position:absolute;left:20px}.subheaderContainer .button{width:40px!important;height:40px!important;margin:0;border-radius:50%;background:#f4f4f4;display:flex;align-items:center;justify-content:center;position:absolute}.subheaderContainer .button img{top:0!important;margin-right:3px!important}.subheaderContainer .left-button{left:20px}.subheaderContainer .right-button{right:20px}.transition-icon{transition:.5s}.rotate-icon{transform:translate(-50%,-50%) rotate(180deg)!important}.app-store-icon[data-v-7aad6400]{box-shadow:0 4px 10px #00000017;border-radius:12px}#codeInput[data-v-89d98ef3],#emailInput[data-v-89d98ef3]{text-align:center;padding-right:15%;font-size:17px}.firstRow img[data-v-5caa3239]{width:25px;height:25px;position:absolute;top:50%;right:0;transform:translate(-50%,-50%)}#emailInput[data-v-69a9cfa3]{text-align:center;padding-right:15%;font-size:17px}.fade-enter-to[data-v-e5fbde19]{opacity:1}.sso-img[data-v-6ebe2dcb]{margin:2px auto 0;width:35px}input[data-v-6ebe2dcb]{margin:0 auto;height:25px}.sso-img[data-v-767d5ebb]{margin:2px auto 0;width:35px}input[data-v-767d5ebb]{margin:0 auto;height:25px}.link-grid,.user-link-img{width:100%;display:inline-table;position:relative}.link-grid{width:30%;margin:1.6%;padding:1.6%}.link-grid .user-link-img img{border-radius:25%!important}.link-grid .edit-icon{border-radius:20px;right:-3%;top:-3%;position:absolute;z-index:3;max-width:23%;overflow:hidden;min-width:30px}.link-grid .direct-icon{border-radius:20px;left:-3%;top:-3%;position:absolute;z-index:555;max-width:23%;overflow:hidden;min-width:30px}.link-grid .link-text{min-height:20px;margin-top:3px!important;display:block;text-align:center;line-height:normal;overflow-wrap:anywhere}.link-list{width:93%;max-height:67px!important;margin:0 auto;display:flex;border-radius:15px!important;background-color:#fff;border:solid 1px #e8e8e8;position:relative;align-items:center}.link-list .user-link-img{display:inline-block;width:65px;border-radius:25%!important}.link-list .link-text{display:inline-block;padding:18px 0% 17px 10%;font-size:15px;font-weight:500;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;flex:1;text-align:left;border-radius:15px!important}.link-list .edit-icon{border-radius:20px;right:7%;top:30%;position:absolute;z-index:3;width:26px;overflow:hidden}.link-list .switching{width:45px}.link-list .direct-icon{border-radius:20px;left:-2%;top:-13%;position:absolute;z-index:555;width:26px;overflow:hidden}.small{width:22%!important;margin:2% 4% 0%;padding:0%}.small .link-text{margin-top:0!important;font-size:13px}.linkExternal{margin-right:20px;width:20px;display:inline-block!important;height:20px;background:#000;-webkit-mask:url(https://cdn.tapni.co/icons/link-external.svg) no-repeat center;mask:url(https://cdn.tapni.co/icons/link-external.svg) no-repeat center;transform:scale(1.5)}.user-img[data-v-ce677789]{margin:2px auto 0;width:65px}input[data-v-ce677789]{margin:0 auto;height:25px}html *{font-family:Inter,sans-serif}#bodyId{padding-top:3%;max-width:667px!important;margin:1.5% auto auto;height:95%!important;border-radius:20px}.action-block-top .default-text,.action-block-top .default-text:after{border-radius:50%;width:10em!important;height:10em!important}.action-block-top .default-text{margin:10px auto;font-size:3px;position:relative;text-indent:-9999em;border-left:.5em solid #000000;border-top:.5em solid rgba(0,0,0,.2);border-right:.5em solid rgba(0,0,0,.2);border-bottom:.5em solid rgba(0,0,0,.2);-webkit-transform:translateZ(0);-ms-transform:translateZ(0);transform:translateZ(0);-webkit-animation:load8 1.1s infinite linear;animation:load8 1.1s infinite linear}@-webkit-keyframes load8{0%{-webkit-transform:rotate(0deg);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes load8{0%{-webkit-transform:rotate(0deg);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}.smartbanner-ios{background:linear-gradient(to bottom,#f4f4f4,#f4f4f4);box-shadow:0 0 #fff;border-bottom:1px solid #dddddd}.smartbanner-icon{border-radius:16px}.smartbanner-ios .smartbanner-button{font-size:13px;padding:9px 0;height:40px;border-radius:13px;background:#f4f4f4;color:#0a99d2;border:none;box-shadow:none;text-transform:uppercase}.snack-body{display:none;border-radius:40px;font-size:15px!important}#errorSnack{background-color:#fee3e3!important;border:2px solid #edd9d9!important;color:#000}#successSnack{background-color:#eff5eb!important;border:2px solid #e3ecd7!important;color:#000}.grecaptcha-badge{visibility:hidden}.header-logo{position:absolute;left:50%;transform:translate(-50%,-50%);margin-top:0;z-index:2}.header-logo-img{height:40px;margin-top:10px}@media (max-width: 768px){#bodyId{margin-top:0;border-radius:0;height:100%!important}.header-logo{margin-top:15px}}.withBackground[data-v-2f7f5584],.withBackground[data-v-4d3e1bec],.withBackground[data-v-36b27d1f]{height:50px}[data-v-9dc93691] .vue-select{padding:5px 0}[data-v-9dc93691] .vue-select .dropdown-icon{color:#1d1d1d;width:25px!important;height:25px!important}[data-v-9dc93691] .vue-select .menu-option:hover{background-color:#d9d9d9}[data-v-9dc93691] .vue-select .menu-option.focused{background-color:#f4f4f4}[data-v-9dc93691] .vue-select .menu-option{border-bottom:1px solid #D9D9D9;font-size:15px;color:#151515}[data-v-9dc93691] .vue-select .menu-option:last-child{border-bottom:none}[data-v-9dc93691] .vue-select .menu{border-radius:10px;border:none}[data-v-9dc93691] .vue-select .control.focused{border:none;box-shadow:none}[data-v-9dc93691] .vue-select .control{min-height:54px!important;background-color:#f4f4f4;border:none;border-radius:10px}[data-v-9dc93691] .vue-select .menu-option.selected{background-color:#e4e4e4}[data-v-9dc93691] .vue-select .indicators-container{padding:5px 15px!important}[data-v-9dc93691] .vue-select .value-container{padding:5px 15px}[data-v-9dc93691] .vue-select .menu-option{background-color:#f4f4f4}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { WebPlugin as i } from "@capacitor/core";
|
|
2
|
+
class u extends i {
|
|
3
|
+
async initialize(e) {
|
|
4
|
+
const n = { version: "v17.0" };
|
|
5
|
+
return await this.loadScript(e.locale), FB.init(Object.assign(Object.assign({}, n), e));
|
|
6
|
+
}
|
|
7
|
+
loadScript(e) {
|
|
8
|
+
if (typeof document > "u")
|
|
9
|
+
return Promise.reject("document global not found");
|
|
10
|
+
const n = "fb";
|
|
11
|
+
if (document.getElementById(n))
|
|
12
|
+
return Promise.resolve();
|
|
13
|
+
const r = document.getElementsByTagName("head")[0], s = document.createElement("script");
|
|
14
|
+
return new Promise((o) => {
|
|
15
|
+
s.onload = () => o(), s.defer = !0, s.async = !0, s.id = n, s.src = `https://connect.facebook.net/${e ?? "en_US"}/sdk.js`, r.appendChild(s);
|
|
16
|
+
});
|
|
17
|
+
}
|
|
18
|
+
async login(e) {
|
|
19
|
+
return new Promise((n, t) => {
|
|
20
|
+
FB.login((r) => {
|
|
21
|
+
r.status === "connected" ? n({
|
|
22
|
+
accessToken: {
|
|
23
|
+
token: r.authResponse.accessToken
|
|
24
|
+
}
|
|
25
|
+
}) : t({
|
|
26
|
+
accessToken: {
|
|
27
|
+
token: null
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
}, { scope: e.permissions.join(",") });
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
async logout() {
|
|
34
|
+
return new Promise((e) => FB.logout(() => e()));
|
|
35
|
+
}
|
|
36
|
+
async reauthorize() {
|
|
37
|
+
return new Promise((e) => FB.reauthorize((n) => e(n)));
|
|
38
|
+
}
|
|
39
|
+
async getCurrentAccessToken() {
|
|
40
|
+
return new Promise((e, n) => {
|
|
41
|
+
FB.getLoginStatus((t) => {
|
|
42
|
+
if (t.status === "connected") {
|
|
43
|
+
const r = {
|
|
44
|
+
accessToken: {
|
|
45
|
+
applicationId: void 0,
|
|
46
|
+
declinedPermissions: [],
|
|
47
|
+
expires: void 0,
|
|
48
|
+
isExpired: void 0,
|
|
49
|
+
lastRefresh: void 0,
|
|
50
|
+
permissions: [],
|
|
51
|
+
token: t.authResponse.accessToken,
|
|
52
|
+
userId: t.authResponse.userID
|
|
53
|
+
}
|
|
54
|
+
};
|
|
55
|
+
e(r);
|
|
56
|
+
} else
|
|
57
|
+
n({
|
|
58
|
+
accessToken: {
|
|
59
|
+
token: null
|
|
60
|
+
}
|
|
61
|
+
});
|
|
62
|
+
});
|
|
63
|
+
});
|
|
64
|
+
}
|
|
65
|
+
async getProfile(e) {
|
|
66
|
+
const n = e.fields.join(",");
|
|
67
|
+
return new Promise((t, r) => {
|
|
68
|
+
FB.api("/me", { fields: n }, (s) => {
|
|
69
|
+
if (s.error) {
|
|
70
|
+
r(s.error.message);
|
|
71
|
+
return;
|
|
72
|
+
}
|
|
73
|
+
t(s);
|
|
74
|
+
});
|
|
75
|
+
});
|
|
76
|
+
}
|
|
77
|
+
async logEvent() {
|
|
78
|
+
return Promise.resolve();
|
|
79
|
+
}
|
|
80
|
+
async setAutoLogAppEventsEnabled() {
|
|
81
|
+
return Promise.resolve();
|
|
82
|
+
}
|
|
83
|
+
async setAdvertiserTrackingEnabled() {
|
|
84
|
+
return Promise.resolve();
|
|
85
|
+
}
|
|
86
|
+
async setAdvertiserIDCollectionEnabled() {
|
|
87
|
+
return Promise.resolve();
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
export {
|
|
91
|
+
u as FacebookLoginWeb
|
|
92
|
+
};
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
import { WebPlugin as c } from "@capacitor/core";
|
|
2
|
+
class g extends c {
|
|
3
|
+
constructor() {
|
|
4
|
+
super();
|
|
5
|
+
}
|
|
6
|
+
loadScript() {
|
|
7
|
+
if (typeof document > "u")
|
|
8
|
+
return;
|
|
9
|
+
const e = "gapi";
|
|
10
|
+
if (document == null ? void 0 : document.getElementById(e))
|
|
11
|
+
return;
|
|
12
|
+
const n = document.getElementsByTagName("head")[0], t = document.createElement("script");
|
|
13
|
+
t.type = "text/javascript", t.defer = !0, t.async = !0, t.id = e, t.onload = this.platformJsLoaded.bind(this), t.src = "https://apis.google.com/js/platform.js", n.appendChild(t);
|
|
14
|
+
}
|
|
15
|
+
initialize(e = {
|
|
16
|
+
clientId: "",
|
|
17
|
+
scopes: [],
|
|
18
|
+
grantOfflineAccess: !1
|
|
19
|
+
}) {
|
|
20
|
+
var s, n;
|
|
21
|
+
if (typeof window > "u")
|
|
22
|
+
return;
|
|
23
|
+
const t = (s = document.getElementsByName("google-signin-client_id")[0]) === null || s === void 0 ? void 0 : s.content, i = e.clientId || t || "";
|
|
24
|
+
i || console.warn("GoogleAuthPlugin - clientId is empty"), this.options = {
|
|
25
|
+
clientId: i,
|
|
26
|
+
grantOfflineAccess: (n = e.grantOfflineAccess) !== null && n !== void 0 ? n : !1,
|
|
27
|
+
scopes: e.scopes || []
|
|
28
|
+
}, this.gapiLoaded = new Promise((o) => {
|
|
29
|
+
window.gapiResolve = o, this.loadScript();
|
|
30
|
+
}), this.addUserChangeListener();
|
|
31
|
+
}
|
|
32
|
+
platformJsLoaded() {
|
|
33
|
+
gapi.load("auth2", () => {
|
|
34
|
+
const e = {
|
|
35
|
+
client_id: this.options.clientId,
|
|
36
|
+
plugin_name: "CodetrixStudioCapacitorGoogleAuth"
|
|
37
|
+
};
|
|
38
|
+
this.options.scopes.length && (e.scope = this.options.scopes.join(" ")), gapi.auth2.init(e), window.gapiResolve();
|
|
39
|
+
});
|
|
40
|
+
}
|
|
41
|
+
async signIn() {
|
|
42
|
+
return new Promise(async (e, s) => {
|
|
43
|
+
var n;
|
|
44
|
+
try {
|
|
45
|
+
let t;
|
|
46
|
+
const i = (n = this.options.grantOfflineAccess) !== null && n !== void 0 ? n : !1;
|
|
47
|
+
i ? t = (await gapi.auth2.getAuthInstance().grantOfflineAccess()).code : await gapi.auth2.getAuthInstance().signIn();
|
|
48
|
+
const o = gapi.auth2.getAuthInstance().currentUser.get();
|
|
49
|
+
i && await o.reloadAuthResponse();
|
|
50
|
+
const a = this.getUserFrom(o);
|
|
51
|
+
a.serverAuthCode = t, e(a);
|
|
52
|
+
} catch (t) {
|
|
53
|
+
s(t);
|
|
54
|
+
}
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
async refresh() {
|
|
58
|
+
const e = await gapi.auth2.getAuthInstance().currentUser.get().reloadAuthResponse();
|
|
59
|
+
return {
|
|
60
|
+
accessToken: e.access_token,
|
|
61
|
+
idToken: e.id_token,
|
|
62
|
+
refreshToken: ""
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
async signOut() {
|
|
66
|
+
return gapi.auth2.getAuthInstance().signOut();
|
|
67
|
+
}
|
|
68
|
+
async addUserChangeListener() {
|
|
69
|
+
await this.gapiLoaded, gapi.auth2.getAuthInstance().currentUser.listen((e) => {
|
|
70
|
+
this.notifyListeners("userChange", e.isSignedIn() ? this.getUserFrom(e) : null);
|
|
71
|
+
});
|
|
72
|
+
}
|
|
73
|
+
getUserFrom(e) {
|
|
74
|
+
const s = {}, n = e.getBasicProfile();
|
|
75
|
+
s.email = n.getEmail(), s.familyName = n.getFamilyName(), s.givenName = n.getGivenName(), s.id = n.getId(), s.imageUrl = n.getImageUrl(), s.name = n.getName();
|
|
76
|
+
const t = e.getAuthResponse(!0);
|
|
77
|
+
return s.authentication = {
|
|
78
|
+
accessToken: t.access_token,
|
|
79
|
+
idToken: t.id_token,
|
|
80
|
+
refreshToken: ""
|
|
81
|
+
}, s;
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
export {
|
|
85
|
+
g as GoogleAuthWeb
|
|
86
|
+
};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { WebPlugin as p } from "@capacitor/core";
|
|
2
|
+
class f extends p {
|
|
3
|
+
constructor() {
|
|
4
|
+
super(...arguments), this.group = "CapacitorStorage";
|
|
5
|
+
}
|
|
6
|
+
async configure({ group: e }) {
|
|
7
|
+
typeof e == "string" && (this.group = e);
|
|
8
|
+
}
|
|
9
|
+
async get(e) {
|
|
10
|
+
return { value: this.impl.getItem(this.applyPrefix(e.key)) };
|
|
11
|
+
}
|
|
12
|
+
async set(e) {
|
|
13
|
+
this.impl.setItem(this.applyPrefix(e.key), e.value);
|
|
14
|
+
}
|
|
15
|
+
async remove(e) {
|
|
16
|
+
this.impl.removeItem(this.applyPrefix(e.key));
|
|
17
|
+
}
|
|
18
|
+
async keys() {
|
|
19
|
+
return { keys: this.rawKeys().map((t) => t.substring(this.prefix.length)) };
|
|
20
|
+
}
|
|
21
|
+
async clear() {
|
|
22
|
+
for (const e of this.rawKeys())
|
|
23
|
+
this.impl.removeItem(e);
|
|
24
|
+
}
|
|
25
|
+
async migrate() {
|
|
26
|
+
var e;
|
|
27
|
+
const t = [], s = [], n = "_cap_", o = Object.keys(this.impl).filter((i) => i.indexOf(n) === 0);
|
|
28
|
+
for (const i of o) {
|
|
29
|
+
const r = i.substring(n.length), a = (e = this.impl.getItem(i)) !== null && e !== void 0 ? e : "", { value: l } = await this.get({ key: r });
|
|
30
|
+
typeof l == "string" ? s.push(r) : (await this.set({ key: r, value: a }), t.push(r));
|
|
31
|
+
}
|
|
32
|
+
return { migrated: t, existing: s };
|
|
33
|
+
}
|
|
34
|
+
async removeOld() {
|
|
35
|
+
const e = "_cap_", t = Object.keys(this.impl).filter((s) => s.indexOf(e) === 0);
|
|
36
|
+
for (const s of t)
|
|
37
|
+
this.impl.removeItem(s);
|
|
38
|
+
}
|
|
39
|
+
get impl() {
|
|
40
|
+
return window.localStorage;
|
|
41
|
+
}
|
|
42
|
+
get prefix() {
|
|
43
|
+
return this.group === "NativeStorage" ? "" : `${this.group}.`;
|
|
44
|
+
}
|
|
45
|
+
rawKeys() {
|
|
46
|
+
return Object.keys(this.impl).filter((e) => e.indexOf(this.prefix) === 0);
|
|
47
|
+
}
|
|
48
|
+
applyPrefix(e) {
|
|
49
|
+
return this.prefix + e;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
export {
|
|
53
|
+
f as PreferencesWeb
|
|
54
|
+
};
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
import { WebPlugin as j } from "@capacitor/core";
|
|
2
|
+
var w = { exports: {} };
|
|
3
|
+
/*!
|
|
4
|
+
* $script.js JS loader & dependency manager
|
|
5
|
+
* https://github.com/ded/script.js
|
|
6
|
+
* (c) Dustin Diaz 2014 | License MIT
|
|
7
|
+
*/
|
|
8
|
+
(function(y) {
|
|
9
|
+
(function(i, p) {
|
|
10
|
+
y.exports ? y.exports = p() : this[i] = p();
|
|
11
|
+
})("$script", function() {
|
|
12
|
+
var i = document, p = i.getElementsByTagName("head")[0], I = !1, m = "push", S = "readyState", A = "onreadystatechange", s = {}, o = {}, d = {}, f, v;
|
|
13
|
+
function g(e, t) {
|
|
14
|
+
for (var n = 0, u = e.length; n < u; ++n) if (!t(e[n])) return I;
|
|
15
|
+
return 1;
|
|
16
|
+
}
|
|
17
|
+
function h(e, t) {
|
|
18
|
+
g(e, function(n) {
|
|
19
|
+
return t(n), 1;
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
function l(e, t, n) {
|
|
23
|
+
e = e[m] ? e : [e];
|
|
24
|
+
var u = t && t.call, r = u ? t : n, N = u ? e.join("") : t, U = e.length;
|
|
25
|
+
function b(c) {
|
|
26
|
+
return c.call ? c() : s[c];
|
|
27
|
+
}
|
|
28
|
+
function _() {
|
|
29
|
+
if (!--U) {
|
|
30
|
+
s[N] = 1, r && r();
|
|
31
|
+
for (var c in o)
|
|
32
|
+
g(c.split("|"), b) && !h(o[c], b) && (o[c] = []);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
return setTimeout(function() {
|
|
36
|
+
h(e, function c(a, W) {
|
|
37
|
+
if (a === null) return _();
|
|
38
|
+
if (!W && !/^https?:\/\//.test(a) && f && (a = a.indexOf(".js") === -1 ? f + a + ".js" : f + a), d[a])
|
|
39
|
+
return d[a] == 2 ? _() : setTimeout(function() {
|
|
40
|
+
c(a, !0);
|
|
41
|
+
}, 0);
|
|
42
|
+
d[a] = 1, x(a, _);
|
|
43
|
+
});
|
|
44
|
+
}, 0), l;
|
|
45
|
+
}
|
|
46
|
+
function x(e, t) {
|
|
47
|
+
var n = i.createElement("script"), u;
|
|
48
|
+
n.onload = n.onerror = n[A] = function() {
|
|
49
|
+
n[S] && !/^c|loade/.test(n[S]) || u || (n.onload = n[A] = null, u = 1, d[e] = 2, t());
|
|
50
|
+
}, n.async = 1, n.src = v ? e + (e.indexOf("?") === -1 ? "?" : "&") + v : e, p.insertBefore(n, p.lastChild);
|
|
51
|
+
}
|
|
52
|
+
return l.get = x, l.order = function(e, t, n) {
|
|
53
|
+
(function u(r) {
|
|
54
|
+
r = e.shift(), e.length ? l(r, u) : l(r, t, n);
|
|
55
|
+
})();
|
|
56
|
+
}, l.path = function(e) {
|
|
57
|
+
f = e;
|
|
58
|
+
}, l.urlArgs = function(e) {
|
|
59
|
+
v = e;
|
|
60
|
+
}, l.ready = function(e, t, n) {
|
|
61
|
+
e = e[m] ? e : [e];
|
|
62
|
+
var u = [];
|
|
63
|
+
return !h(e, function(r) {
|
|
64
|
+
s[r] || u[m](r);
|
|
65
|
+
}) && g(e, function(r) {
|
|
66
|
+
return s[r];
|
|
67
|
+
}) ? t() : function(r) {
|
|
68
|
+
o[r] = o[r] || [], o[r][m](t), n && n(u);
|
|
69
|
+
}(e.join("|")), l;
|
|
70
|
+
}, l.done = function(e) {
|
|
71
|
+
l([null], e);
|
|
72
|
+
}, l;
|
|
73
|
+
});
|
|
74
|
+
})(w);
|
|
75
|
+
var z = w.exports;
|
|
76
|
+
class P extends j {
|
|
77
|
+
constructor() {
|
|
78
|
+
super({
|
|
79
|
+
name: "SignInWithApple",
|
|
80
|
+
platforms: ["web"]
|
|
81
|
+
}), this.appleScriptUrl = "https://appleid.cdn-apple.com/appleauth/static/jsapi/appleid/1/en_US/appleid.auth.js", this.isAppleScriptLoaded = !1;
|
|
82
|
+
}
|
|
83
|
+
async authorize(i) {
|
|
84
|
+
return new Promise((p, I) => {
|
|
85
|
+
i ? this.loadSignInWithAppleJS().then((m) => {
|
|
86
|
+
var S, A, s;
|
|
87
|
+
this.isAppleScriptLoaded = m, this.isAppleScriptLoaded ? (AppleID.auth.init({
|
|
88
|
+
clientId: i.clientId,
|
|
89
|
+
redirectURI: i.redirectURI,
|
|
90
|
+
scope: (S = i.scopes) !== null && S !== void 0 ? S : void 0,
|
|
91
|
+
state: (A = i.state) !== null && A !== void 0 ? A : void 0,
|
|
92
|
+
nonce: (s = i.nonce) !== null && s !== void 0 ? s : void 0,
|
|
93
|
+
usePopup: !0
|
|
94
|
+
}), AppleID.auth.signIn().then((o) => {
|
|
95
|
+
var d, f, v, g, h;
|
|
96
|
+
const l = {
|
|
97
|
+
response: {
|
|
98
|
+
user: null,
|
|
99
|
+
email: (d = o.user) === null || d === void 0 ? void 0 : d.email,
|
|
100
|
+
givenName: (v = (f = o.user) === null || f === void 0 ? void 0 : f.name) === null || v === void 0 ? void 0 : v.firstName,
|
|
101
|
+
familyName: (h = (g = o.user) === null || g === void 0 ? void 0 : g.name) === null || h === void 0 ? void 0 : h.lastName,
|
|
102
|
+
identityToken: o.authorization.id_token,
|
|
103
|
+
authorizationCode: o.authorization.code
|
|
104
|
+
}
|
|
105
|
+
};
|
|
106
|
+
p(l);
|
|
107
|
+
}).catch((o) => {
|
|
108
|
+
I(o);
|
|
109
|
+
})) : I("Unable to load Sign in with Apple JS framework.");
|
|
110
|
+
}) : I("No options were provided.");
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
loadSignInWithAppleJS() {
|
|
114
|
+
return new Promise((i) => {
|
|
115
|
+
this.isAppleScriptLoaded ? i(!0) : typeof window !== void 0 ? z.get(this.appleScriptUrl, () => i(!0)) : i(!1);
|
|
116
|
+
});
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
export {
|
|
120
|
+
P as SignInWithAppleWeb
|
|
121
|
+
};
|
package/package.json
CHANGED
package/src/App.vue
CHANGED
|
@@ -70,6 +70,7 @@ document.addEventListener('DOMContentLoaded', function() {
|
|
|
70
70
|
</template>
|
|
71
71
|
|
|
72
72
|
<script>
|
|
73
|
+
import "../public/index.css";
|
|
73
74
|
import AuthWelcome from "@/views/Welcome.vue";
|
|
74
75
|
import AuthLogin from "@/views/Login.vue";
|
|
75
76
|
import AuthRegister from "@/views/Register.vue";
|
|
@@ -78,8 +79,8 @@ import AuthSecurity from "@/views/Security.vue";
|
|
|
78
79
|
import AuthReset from "@/views/Reset.vue";
|
|
79
80
|
import AuthCallback from "@/views/Callback.vue";
|
|
80
81
|
import ModalOverlay from "@/components/DELETE_ModalOverlay.vue";
|
|
81
|
-
import SSO from "@/components/
|
|
82
|
-
import SSOPick from "@/components/
|
|
82
|
+
import SSO from "@/components/DELETE_SSO.vue";
|
|
83
|
+
import SSOPick from "@/components/DELETE_SSOPick.vue";
|
|
83
84
|
import {EventBus} from "./store/event-bus.js";
|
|
84
85
|
import AuthMixin from "@/mixins/auth.mixin.js";
|
|
85
86
|
import Language from "@/components/DELETE_Language.vue";
|
|
@@ -319,4 +320,16 @@ html * {
|
|
|
319
320
|
height: 40px;
|
|
320
321
|
margin-top: 10px;
|
|
321
322
|
}
|
|
323
|
+
|
|
324
|
+
@media (max-width: 768px) {
|
|
325
|
+
#bodyId {
|
|
326
|
+
margin-top: 0;
|
|
327
|
+
border-radius: 0;
|
|
328
|
+
height: 100%!important;
|
|
329
|
+
}
|
|
330
|
+
|
|
331
|
+
.header-logo {
|
|
332
|
+
margin-top: 15px;
|
|
333
|
+
}
|
|
334
|
+
}
|
|
322
335
|
</style>
|
|
@@ -91,18 +91,12 @@ export default {
|
|
|
91
91
|
if (!ssoTypes.length) {
|
|
92
92
|
this.forceClose();
|
|
93
93
|
return this.errorSnack(this.ssoLang[this.appLanguage].no_sso_logins);
|
|
94
|
-
} else
|
|
94
|
+
} else {
|
|
95
95
|
if (ssoTypes[0] === "azure")
|
|
96
96
|
this.microsoftLogin("sso", response.sso.azure.sso);
|
|
97
97
|
if (ssoTypes[0] === "okta") this.oktaLogin(response.sso.okta.sso);
|
|
98
98
|
if (ssoTypes[0] === "saml")
|
|
99
99
|
this.samlLogin(response.sso.saml.sso.loginUrl);
|
|
100
|
-
} else {
|
|
101
|
-
this.forceClose();
|
|
102
|
-
EventBus.$emit("toggleSSOPickModal", {
|
|
103
|
-
sso: response.sso,
|
|
104
|
-
email: this.email,
|
|
105
|
-
});
|
|
106
100
|
}
|
|
107
101
|
}
|
|
108
102
|
},
|
package/src/main.js
CHANGED
package/src/mixins/okta.mixin.js
CHANGED
|
@@ -121,7 +121,7 @@ export default {
|
|
|
121
121
|
window.opener.postMessage(postMessageData, location.origin);
|
|
122
122
|
window.close()
|
|
123
123
|
} else {
|
|
124
|
-
if(this.isNative && this.
|
|
124
|
+
if(this.isNative && this.isiOS) await Browser.close();
|
|
125
125
|
EventBus.$emit('ssoEvent', {name: 'setLoading', data: true})
|
|
126
126
|
if (code && clientID && domain) await this.exchangeCode({code, clientID, domain, platform});
|
|
127
127
|
localStorage.removeItem("pkce_code_verifier");
|
package/src/mixins/saml.mixin.js
CHANGED
|
@@ -68,7 +68,7 @@ export default {
|
|
|
68
68
|
window.opener.postMessage(postMessageData, location.origin);
|
|
69
69
|
window.close()
|
|
70
70
|
} else {
|
|
71
|
-
if(this.isNative && this.
|
|
71
|
+
if(this.isNative && this.isiOS) await Browser.close();
|
|
72
72
|
EventBus.$emit('ssoEvent', {name: 'setLoading', data: true})
|
|
73
73
|
if (this.$route.query.code) code = this.$route.query.code
|
|
74
74
|
|
package/src/routes.js
CHANGED
|
@@ -8,6 +8,7 @@ const Callback = () => import("./views/Callback.vue");
|
|
|
8
8
|
const QR = () => import("./views/QR.vue");
|
|
9
9
|
const Security = () => import("./views/Security.vue");
|
|
10
10
|
const Apps = () => import("./views/Apps.vue");
|
|
11
|
+
const Billing = () => import("./views/Billing.vue");
|
|
11
12
|
const CustomApp = () => import("./views/CustomApp.vue");
|
|
12
13
|
const General = () => import("./views/General.vue");
|
|
13
14
|
|
|
@@ -38,6 +39,11 @@ export default [
|
|
|
38
39
|
name: "AuthSecurity",
|
|
39
40
|
component: Security,
|
|
40
41
|
},
|
|
42
|
+
{
|
|
43
|
+
path: "/billing",
|
|
44
|
+
name: "AuthBilling",
|
|
45
|
+
component: Billing,
|
|
46
|
+
},
|
|
41
47
|
{
|
|
42
48
|
path: "/apps",
|
|
43
49
|
name: "AuthApps",
|
|
@@ -78,4 +78,10 @@ export default {
|
|
|
78
78
|
getAccountSettings() {
|
|
79
79
|
return api().get("/users/settings");
|
|
80
80
|
},
|
|
81
|
+
async getRecordById(data) {
|
|
82
|
+
return api().post("/objects/record/" + data.id, data);
|
|
83
|
+
},
|
|
84
|
+
async getRecords(data) {
|
|
85
|
+
return api().post("/objects/records", data);
|
|
86
|
+
}
|
|
81
87
|
}
|
package/src/store/locales/en.js
CHANGED
|
@@ -400,7 +400,7 @@ export default {
|
|
|
400
400
|
update_p3: "Please update the app to the newest version",
|
|
401
401
|
company_domain: "Your company domain",
|
|
402
402
|
search_company_domain: "Search your company domain",
|
|
403
|
-
enter_company_email: "Enter
|
|
403
|
+
enter_company_email: "Enter business email",
|
|
404
404
|
company_not_found: "Company not found",
|
|
405
405
|
ik_company_domain: "I know the company domain",
|
|
406
406
|
idk_company_domain: "I don't know the company domain",
|
|
@@ -523,6 +523,7 @@ export default {
|
|
|
523
523
|
general: "General",
|
|
524
524
|
general_p: "Manage your personal details & other preferences",
|
|
525
525
|
billing: "Billing",
|
|
526
|
+
billing_p: "Manage your subscriptions & payment profiles",
|
|
526
527
|
apps: "Apps",
|
|
527
528
|
apps_p: "View your active apps & explore other",
|
|
528
529
|
apps_my: "My apps",
|
package/src/views/Apps.vue
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
</a>
|
|
8
8
|
<div class="subheaderContainer full-top">
|
|
9
9
|
<!-- Back Button -->
|
|
10
|
-
<router-link to="/account" class="button gray-button pointer left-button">
|
|
10
|
+
<router-link v-if="!isModal" to="/account" class="button gray-button pointer left-button">
|
|
11
11
|
<img
|
|
12
12
|
:src="getIcon('arrow-gray-right.svg')"
|
|
13
13
|
height="20"
|
|
@@ -29,41 +29,17 @@
|
|
|
29
29
|
<div class="full-top">
|
|
30
30
|
<h3 v-if="false" class="full-top bold small-bottom">{{ssoLang[appLanguage].apps_my}}</h3>
|
|
31
31
|
|
|
32
|
-
<
|
|
32
|
+
<a v-for="app in apps" :key="app.id" :href="app.t_apps_url" target="_blank" class="settingRow half-bottom">
|
|
33
33
|
<div class="firstRow">
|
|
34
34
|
<img
|
|
35
|
-
:src="getIcon(
|
|
35
|
+
:src="getIcon(app.t_apps_icon)"
|
|
36
36
|
class="withBackground"
|
|
37
37
|
/>
|
|
38
|
-
<h4>
|
|
38
|
+
<h4>{{ app.t_apps_name }}</h4>
|
|
39
39
|
|
|
40
40
|
<img :src="getIcon('arrow-gray-right.svg')" />
|
|
41
41
|
</div>
|
|
42
|
-
</
|
|
43
|
-
|
|
44
|
-
<router-link to="/apps/mailsign" class="settingRow half-top">
|
|
45
|
-
<div class="firstRow">
|
|
46
|
-
<img
|
|
47
|
-
:src="getIcon('app-logo-mailsign.svg')"
|
|
48
|
-
class="withBackground"
|
|
49
|
-
/>
|
|
50
|
-
<h4>MailSign</h4>
|
|
51
|
-
|
|
52
|
-
<img :src="getIcon('arrow-gray-right.svg')" />
|
|
53
|
-
</div>
|
|
54
|
-
</router-link>
|
|
55
|
-
|
|
56
|
-
<router-link v-if="false" to="/apps/qrcodetoolkit" class="settingRow half-top">
|
|
57
|
-
<div class="firstRow">
|
|
58
|
-
<img
|
|
59
|
-
:src="getIcon('app-logo-qrcodetoolkit.svg')"
|
|
60
|
-
class="withBackground"
|
|
61
|
-
/>
|
|
62
|
-
<h4>QRCode Toolkit</h4>
|
|
63
|
-
|
|
64
|
-
<img :src="getIcon('arrow-gray-right.svg')" />
|
|
65
|
-
</div>
|
|
66
|
-
</router-link>
|
|
42
|
+
</a>
|
|
67
43
|
</div>
|
|
68
44
|
</div>
|
|
69
45
|
</div>
|
|
@@ -73,9 +49,10 @@
|
|
|
73
49
|
<script>
|
|
74
50
|
import AuthMixin from "../mixins/auth.mixin";
|
|
75
51
|
import {EventBus} from "@/store/event-bus.js";
|
|
52
|
+
import MetadataService from "@/services/MetadataService.js";
|
|
76
53
|
|
|
77
54
|
export default {
|
|
78
|
-
name: "
|
|
55
|
+
name: "AuthApps",
|
|
79
56
|
mixins: [AuthMixin],
|
|
80
57
|
props: {
|
|
81
58
|
payload: {
|
|
@@ -86,10 +63,20 @@ export default {
|
|
|
86
63
|
data () {
|
|
87
64
|
return {
|
|
88
65
|
loading: false,
|
|
66
|
+
apps: []
|
|
89
67
|
}
|
|
90
68
|
},
|
|
91
69
|
async mounted() {
|
|
92
70
|
if (!this.isLoggedIn) this.$router.push('/login');
|
|
71
|
+
|
|
72
|
+
const response = await MetadataService.getRecords({
|
|
73
|
+
objectId: '6dc545ea-2e2f-4720-b4fe-c5ebdd8af063',
|
|
74
|
+
query: {
|
|
75
|
+
fields: ['t_apps_name', 't_apps_icon', 't_apps_url'],
|
|
76
|
+
relations: []
|
|
77
|
+
}
|
|
78
|
+
})
|
|
79
|
+
this.apps = response.data.records;
|
|
93
80
|
},
|
|
94
81
|
methods: {
|
|
95
82
|
close () {
|