@tapni/auth 1.0.5 → 1.0.6-3.dev

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.
Files changed (78) hide show
  1. package/README.md +2 -0
  2. package/dist/.vite/manifest.json +16 -43
  3. package/dist/.well-known/assetlinks.json +10 -12
  4. package/dist/.well-known/microsoft-identity-association.json +5 -5
  5. package/dist/{Apps-DMds3Dv-.js → Apps-XNA4_3B4.js} +34 -34
  6. package/dist/Billing-Br0-fHed.js +256 -0
  7. package/dist/CustomApp-CrlbYDOm.js +83 -0
  8. package/dist/QR-Bvqb60-E.js +41 -0
  9. package/dist/TapniAuth.es.js +1 -1
  10. package/dist/TapniAuth.umd.js +49 -23
  11. package/dist/{install-L-cxSovH.js → install-7FOVy8Ol.js} +6267 -4743
  12. package/dist/site.webmanifest +11 -1
  13. package/dist/style.css +1 -1
  14. package/dist/{web-IFGkBi0t.js → web-UrTMimK1.js} +2 -2
  15. package/package.json +65 -55
  16. package/src/.prettierrc.json +16 -0
  17. package/src/App.vue +326 -269
  18. package/src/eslint.config.js +15 -0
  19. package/src/index.js +4 -0
  20. package/src/install.js +9 -10
  21. package/src/main.js +54 -57
  22. package/src/mixins/apple.mixin.js +56 -54
  23. package/src/mixins/auth.mixin.js +3 -2
  24. package/src/mixins/global.mixin.js +3 -3
  25. package/src/mixins/google.mixin.js +53 -54
  26. package/src/mixins/microsoft.mixin.js +2 -5
  27. package/src/mixins/okta.mixin.js +1 -1
  28. package/src/mixins/qr-auth.mixin.js +111 -107
  29. package/src/mixins/saml.mixin.js +82 -45
  30. package/src/router/index.js +6 -6
  31. package/src/routes.js +1 -1
  32. package/src/services/Api.js +56 -58
  33. package/src/services/AuthService.js +7 -9
  34. package/src/services/CompanyService.js +10 -10
  35. package/src/services/DeviceService.js +3 -3
  36. package/src/services/UserService.js +48 -45
  37. package/src/services/UtilService.js +317 -225
  38. package/src/store/auth.js +485 -549
  39. package/src/store/constants.js +2 -2
  40. package/src/store/event-bus.js +22 -22
  41. package/src/store/locales/cn.js +476 -458
  42. package/src/store/locales/de.js +478 -517
  43. package/src/store/locales/en.js +454 -513
  44. package/src/store/locales/es.js +477 -524
  45. package/src/store/locales/fr.js +477 -516
  46. package/src/store/locales/it.js +477 -514
  47. package/src/store/locales/ja.js +488 -0
  48. package/src/store/locales/kr.js +477 -491
  49. package/src/store/locales/lang.js +51 -43
  50. package/src/store/locales/pt.js +488 -0
  51. package/src/store/locales/sr.js +477 -492
  52. package/src/store/locales/tr.js +477 -487
  53. package/src/store/store.js +6 -6
  54. package/src/views/Account.vue +36 -8
  55. package/src/views/Billing.vue +464 -34
  56. package/src/views/Callback.vue +36 -33
  57. package/src/views/General.vue +151 -185
  58. package/src/views/Login.vue +2 -25
  59. package/src/views/Register.vue +2 -12
  60. package/src/views/Reset.vue +132 -135
  61. package/src/views/Security.vue +13 -7
  62. package/src/views/Verify.vue +153 -151
  63. package/src/views/Welcome.vue +85 -71
  64. package/dist/Account-Cuz87g_8.js +0 -153
  65. package/dist/Billing-BXlQEuNy.js +0 -113
  66. package/dist/CustomApp-CLCMXmMO.js +0 -83
  67. package/dist/General-dW73bMoR.js +0 -479
  68. package/dist/QR-D6ZGcPM0.js +0 -41
  69. package/dist/index.css +0 -193
  70. package/dist/web-AXRKjAOB.js +0 -92
  71. package/src/components/DELETE_Language.vue +0 -168
  72. package/src/components/DELETE_LinkIcon.vue +0 -288
  73. package/src/components/DELETE_ModalOverlay.vue +0 -68
  74. package/src/components/DELETE_OTP.vue +0 -105
  75. package/src/components/DELETE_SSO.vue +0 -120
  76. package/src/components/DELETE_SSOPick.vue +0 -166
  77. package/src/mixins/DELETE_mfa-auth.mixin.js +0 -53
  78. package/src/mixins/facebook.mixin.js +0 -78
package/README.md CHANGED
@@ -25,7 +25,9 @@ npm run build
25
25
  ```sh
26
26
  npm run build-lib
27
27
  ```
28
+
28
29
  and then run
30
+
29
31
  ```sh
30
32
  npm publish
31
33
  ```
@@ -1,18 +1,15 @@
1
1
  {
2
- "_install-L-cxSovH.js": {
3
- "file": "install-L-cxSovH.js",
2
+ "_install-7FOVy8Ol.js": {
3
+ "file": "install-7FOVy8Ol.js",
4
4
  "name": "install",
5
5
  "dynamicImports": [
6
- "src/views/Account.vue",
7
6
  "src/views/QR.vue",
8
7
  "src/views/Apps.vue",
9
8
  "src/views/Billing.vue",
10
9
  "src/views/CustomApp.vue",
11
- "src/views/General.vue",
12
10
  "node_modules/@codetrix-studio/capacitor-google-auth/dist/esm/web.js",
13
- "node_modules/@capacitor-community/facebook-login/dist/esm/web.js",
14
11
  "node_modules/@capacitor-community/apple-sign-in/dist/esm/web.js",
15
- "node_modules/@capacitor/preferences/dist/esm/web.js"
12
+ "node_modules/@tapni/capacitor-reactive-localstorage-vue3/node_modules/@capacitor/preferences/dist/esm/web.js"
16
13
  ]
17
14
  },
18
15
  "node_modules/@capacitor-community/apple-sign-in/dist/esm/web.js": {
@@ -21,22 +18,16 @@
21
18
  "src": "node_modules/@capacitor-community/apple-sign-in/dist/esm/web.js",
22
19
  "isDynamicEntry": true
23
20
  },
24
- "node_modules/@capacitor-community/facebook-login/dist/esm/web.js": {
25
- "file": "web-AXRKjAOB.js",
21
+ "node_modules/@codetrix-studio/capacitor-google-auth/dist/esm/web.js": {
22
+ "file": "web-UrTMimK1.js",
26
23
  "name": "web",
27
- "src": "node_modules/@capacitor-community/facebook-login/dist/esm/web.js",
24
+ "src": "node_modules/@codetrix-studio/capacitor-google-auth/dist/esm/web.js",
28
25
  "isDynamicEntry": true
29
26
  },
30
- "node_modules/@capacitor/preferences/dist/esm/web.js": {
27
+ "node_modules/@tapni/capacitor-reactive-localstorage-vue3/node_modules/@capacitor/preferences/dist/esm/web.js": {
31
28
  "file": "web-LIfHmYL2.js",
32
29
  "name": "web",
33
- "src": "node_modules/@capacitor/preferences/dist/esm/web.js",
34
- "isDynamicEntry": true
35
- },
36
- "node_modules/@codetrix-studio/capacitor-google-auth/dist/esm/web.js": {
37
- "file": "web-IFGkBi0t.js",
38
- "name": "web",
39
- "src": "node_modules/@codetrix-studio/capacitor-google-auth/dist/esm/web.js",
30
+ "src": "node_modules/@tapni/capacitor-reactive-localstorage-vue3/node_modules/@capacitor/preferences/dist/esm/web.js",
40
31
  "isDynamicEntry": true
41
32
  },
42
33
  "src/install.js": {
@@ -45,58 +36,40 @@
45
36
  "src": "src/install.js",
46
37
  "isEntry": true
47
38
  },
48
- "src/views/Account.vue": {
49
- "file": "Account-Cuz87g_8.js",
50
- "name": "Account",
51
- "src": "src/views/Account.vue",
52
- "isDynamicEntry": true,
53
- "imports": [
54
- "_install-L-cxSovH.js"
55
- ]
56
- },
57
39
  "src/views/Apps.vue": {
58
- "file": "Apps-DMds3Dv-.js",
40
+ "file": "Apps-XNA4_3B4.js",
59
41
  "name": "Apps",
60
42
  "src": "src/views/Apps.vue",
61
43
  "isDynamicEntry": true,
62
44
  "imports": [
63
- "_install-L-cxSovH.js"
45
+ "_install-7FOVy8Ol.js"
64
46
  ]
65
47
  },
66
48
  "src/views/Billing.vue": {
67
- "file": "Billing-BXlQEuNy.js",
49
+ "file": "Billing-Br0-fHed.js",
68
50
  "name": "Billing",
69
51
  "src": "src/views/Billing.vue",
70
52
  "isDynamicEntry": true,
71
53
  "imports": [
72
- "_install-L-cxSovH.js"
54
+ "_install-7FOVy8Ol.js"
73
55
  ]
74
56
  },
75
57
  "src/views/CustomApp.vue": {
76
- "file": "CustomApp-CLCMXmMO.js",
58
+ "file": "CustomApp-CrlbYDOm.js",
77
59
  "name": "CustomApp",
78
60
  "src": "src/views/CustomApp.vue",
79
61
  "isDynamicEntry": true,
80
62
  "imports": [
81
- "_install-L-cxSovH.js"
82
- ]
83
- },
84
- "src/views/General.vue": {
85
- "file": "General-dW73bMoR.js",
86
- "name": "General",
87
- "src": "src/views/General.vue",
88
- "isDynamicEntry": true,
89
- "imports": [
90
- "_install-L-cxSovH.js"
63
+ "_install-7FOVy8Ol.js"
91
64
  ]
92
65
  },
93
66
  "src/views/QR.vue": {
94
- "file": "QR-D6ZGcPM0.js",
67
+ "file": "QR-Bvqb60-E.js",
95
68
  "name": "QR",
96
69
  "src": "src/views/QR.vue",
97
70
  "isDynamicEntry": true,
98
71
  "imports": [
99
- "_install-L-cxSovH.js"
72
+ "_install-7FOVy8Ol.js"
100
73
  ]
101
74
  },
102
75
  "style.css": {
@@ -1,12 +1,10 @@
1
- [{
2
- "relation": ["delegate_permission/common.handle_all_urls"],
3
- "target": {
4
- "namespace": "android_app",
5
- "package_name": "co.tapni.app",
6
- "sha256_cert_fingerprints":
7
- [
8
- "B5:E6:1C:2F:E6:57:A8:A8:53:E9:10:4D:40:7C:A4:1C:61:A6:05:B1:67:19:3B:87:BA:5D:FD:F7:62:1B:E7:94",
9
- "54:D6:D1:9A:91:74:AD:8E:51:C3:63:53:55:CB:A1:B3:D2:A4:79:AF:5E:93:A0:DC:9E:01:8A:4E:60:4D:C3:60"
10
- ]
11
- }
12
- }]
1
+ [
2
+ {
3
+ "relation": ["delegate_permission/common.handle_all_urls"],
4
+ "target": {
5
+ "namespace": "android_app",
6
+ "package_name": "co.tapni.app",
7
+ "sha256_cert_fingerprints": ["B5:E6:1C:2F:E6:57:A8:A8:53:E9:10:4D:40:7C:A4:1C:61:A6:05:B1:67:19:3B:87:BA:5D:FD:F7:62:1B:E7:94", "54:D6:D1:9A:91:74:AD:8E:51:C3:63:53:55:CB:A1:B3:D2:A4:79:AF:5E:93:A0:DC:9E:01:8A:4E:60:4D:C3:60"]
8
+ }
9
+ }
10
+ ]
@@ -1,7 +1,7 @@
1
1
  {
2
- "associatedApplications": [
3
- {
4
- "applicationId": "6c0662cb-3333-436d-a092-b5a37c50599e"
5
- }
6
- ]
2
+ "associatedApplications": [
3
+ {
4
+ "applicationId": "6c0662cb-3333-436d-a092-b5a37c50599e"
5
+ }
6
+ ]
7
7
  }
@@ -1,5 +1,5 @@
1
- import { a as l, _ as g, A as u, E as _ } from "./install-L-cxSovH.js";
2
- import { resolveComponent as h, openBlock as o, createElementBlock as n, createCommentVNode as a, createElementVNode as e, createBlock as f, withCtx as m, toDisplayString as r, Fragment as b, renderList as y, pushScopeId as v, popScopeId as w } from "vue";
1
+ import { a as l, _ as g, A as u, E as _ } from "./install-7FOVy8Ol.js";
2
+ import { resolveComponent as h, openBlock as o, createElementBlock as a, createElementVNode as e, createCommentVNode as r, createBlock as f, withCtx as m, toDisplayString as i, Fragment as b, renderList as y } from "vue";
3
3
  const k = {
4
4
  async getRecordById(t) {
5
5
  return l().post("/objects/record/" + t.id, t);
@@ -7,7 +7,7 @@ const k = {
7
7
  async getRecords(t) {
8
8
  return l().post("/objects/records", t);
9
9
  }
10
- }, I = {
10
+ }, v = {
11
11
  name: "AuthApps",
12
12
  mixins: [u],
13
13
  props: {
@@ -38,29 +38,29 @@ const k = {
38
38
  _.$emit("ssoEvent", { name: "toggleAuthModal", data: !0 });
39
39
  }
40
40
  }
41
- }, x = (t) => (v("data-v-2f7f5584"), t = t(), w(), t), A = { class: "page-login content-boxed content-boxed-padding" }, B = /* @__PURE__ */ x(() => /* @__PURE__ */ e("i", { class: "font-17 color-black" }, [
42
- /* @__PURE__ */ e("img", {
43
- src: "https://cdn.tapni.co/icons/down-arrow.png",
44
- class: "responsive-image",
45
- style: { width: "35%" }
46
- })
47
- ], -1)), L = [
48
- B
49
- ], C = { class: "subheaderContainer full-top" }, E = ["src"], M = {
41
+ }, w = { class: "page-login content-boxed content-boxed-padding" }, x = { class: "subheaderContainer full-top" }, I = ["src"], A = {
50
42
  class: "center-text",
51
43
  style: { "flex-grow": "1", "text-align": "center", margin: "0", "font-weight": "600" }
52
- }, R = { class: "container left-text" }, S = { class: "center-text" }, j = { class: "full-top" }, $ = ["href"], N = { class: "firstRow" }, V = ["src"], q = ["src"];
53
- function D(t, c, F, O, d, i) {
44
+ }, B = { class: "container left-text" }, L = { class: "center-text" }, C = { class: "full-top" }, E = ["href"], M = { class: "firstRow" }, R = ["src"], j = ["src"];
45
+ function $(t, n, N, S, d, c) {
54
46
  const p = h("router-link");
55
- return o(), n("div", A, [
56
- t.isModal ? (o(), n("a", {
47
+ return o(), a("div", w, [
48
+ t.isModal ? (o(), a("a", {
57
49
  key: 0,
58
- onClick: c[0] || (c[0] = (...s) => i.close && i.close(...s)),
50
+ onClick: n[0] || (n[0] = (...s) => c.close && c.close(...s)),
59
51
  class: "color-black pull-right pointer",
60
52
  style: { "margin-top": "0px", position: "absolute", right: "-20px", "text-align": "right" }
61
- }, L)) : a("", !0),
62
- e("div", C, [
63
- t.isModal ? a("", !0) : (o(), f(p, {
53
+ }, n[1] || (n[1] = [
54
+ e("i", { class: "font-17 color-black" }, [
55
+ e("img", {
56
+ src: "https://cdn.tapni.co/icons/down-arrow.png",
57
+ class: "responsive-image",
58
+ style: { width: "35%" }
59
+ })
60
+ ], -1)
61
+ ]))) : r("", !0),
62
+ e("div", x, [
63
+ t.isModal ? r("", !0) : (o(), f(p, {
64
64
  key: 0,
65
65
  to: "/account",
66
66
  class: "button gray-button pointer left-button"
@@ -72,38 +72,38 @@ function D(t, c, F, O, d, i) {
72
72
  width: "20",
73
73
  class: "btn-icon",
74
74
  style: { rotate: "180deg" }
75
- }, null, 8, E)
75
+ }, null, 8, I)
76
76
  ]),
77
77
  _: 1
78
78
  })),
79
- e("h2", M, r(t.ssoLang[t.appLanguage].apps), 1)
79
+ e("h2", A, i(t.ssoLang[t.appLanguage].apps), 1)
80
80
  ]),
81
- e("div", R, [
82
- e("p", S, r(t.ssoLang[t.appLanguage].apps_p), 1),
83
- e("div", j, [
84
- a("", !0),
85
- (o(!0), n(b, null, y(d.apps, (s) => (o(), n("a", {
81
+ e("div", B, [
82
+ e("p", L, i(t.ssoLang[t.appLanguage].apps_p), 1),
83
+ e("div", C, [
84
+ r("", !0),
85
+ (o(!0), a(b, null, y(d.apps, (s) => (o(), a("a", {
86
86
  key: s.id,
87
87
  href: s.t_apps_url,
88
88
  target: "_blank",
89
89
  class: "settingRow half-bottom"
90
90
  }, [
91
- e("div", N, [
91
+ e("div", M, [
92
92
  e("img", {
93
93
  src: t.getIcon(s.t_apps_icon),
94
94
  class: "withBackground"
95
- }, null, 8, V),
96
- e("h4", null, r(s.t_apps_name), 1),
95
+ }, null, 8, R),
96
+ e("h4", null, i(s.t_apps_name), 1),
97
97
  e("img", {
98
98
  src: t.getIcon("arrow-gray-right.svg")
99
- }, null, 8, q)
99
+ }, null, 8, j)
100
100
  ])
101
- ], 8, $))), 128))
101
+ ], 8, E))), 128))
102
102
  ])
103
103
  ])
104
104
  ]);
105
105
  }
106
- const H = /* @__PURE__ */ g(I, [["render", D], ["__scopeId", "data-v-2f7f5584"]]);
106
+ const D = /* @__PURE__ */ g(v, [["render", $], ["__scopeId", "data-v-2f7f5584"]]);
107
107
  export {
108
- H as default
108
+ D as default
109
109
  };
@@ -0,0 +1,256 @@
1
+ import { _ as m, A as f, E as u, a as y } from "./install-7FOVy8Ol.js";
2
+ import { resolveComponent as v, openBlock as a, createElementBlock as r, createElementVNode as e, createCommentVNode as d, createBlock as C, withCtx as _, toDisplayString as n, Fragment as k, renderList as w, normalizeClass as S, withModifiers as M, createTextVNode as b, withDirectives as x, vModelText as D } from "vue";
3
+ const E = {
4
+ name: "AuthBilling",
5
+ mixins: [f],
6
+ props: {
7
+ payload: {
8
+ type: Object,
9
+ default: {}
10
+ }
11
+ },
12
+ data() {
13
+ return {
14
+ loading: !1,
15
+ subscriptions: [],
16
+ showCancelModal: !1,
17
+ selectedSubscription: null,
18
+ cancelFeedback: ""
19
+ };
20
+ },
21
+ async mounted() {
22
+ this.isLoggedIn || this.$router.push("/login"), await this.getAccountSettings(), this.loadSubscriptions();
23
+ },
24
+ methods: {
25
+ close() {
26
+ u.$emit("ssoEvent", { name: "toggleAuthModal", data: !0 });
27
+ },
28
+ loadSubscriptions() {
29
+ if (this.account.billing) {
30
+ const t = this.account.billing, s = [];
31
+ for (const l in t)
32
+ l !== "region" && l !== "currency" && l !== "paymentProfiles" && typeof t[l] == "object" && t[l].subscriptionId && s.push(t[l]);
33
+ this.subscriptions = s;
34
+ }
35
+ },
36
+ formatCurrency(t, s) {
37
+ return `${{
38
+ EUR: "€",
39
+ USD: "$",
40
+ GBP: "£"
41
+ }[s == null ? void 0 : s.toUpperCase()] || s || ""}${(t == null ? void 0 : t.toFixed(2)) || "0.00"}`;
42
+ },
43
+ formatInterval(t) {
44
+ return t ? `per ${t}` : "";
45
+ },
46
+ formatDate(t) {
47
+ return t ? new Date(t * 1e3).toLocaleDateString("en-US", { year: "numeric", month: "short", day: "numeric" }) : "";
48
+ },
49
+ getStatusText(t) {
50
+ return {
51
+ trialing: "Trial",
52
+ active: "Active",
53
+ past_due: "Past Due",
54
+ canceled: "Canceled",
55
+ unpaid: "Unpaid"
56
+ }[t] || t;
57
+ },
58
+ getStatusClass(t) {
59
+ return `status-${t}`;
60
+ },
61
+ openCancelModal(t) {
62
+ this.selectedSubscription = t, this.showCancelModal = !0, this.cancelFeedback = "";
63
+ },
64
+ closeCancelModal() {
65
+ this.showCancelModal = !1, this.selectedSubscription = null, this.cancelFeedback = "";
66
+ },
67
+ async confirmCancel() {
68
+ var t, s;
69
+ if (this.selectedSubscription) {
70
+ if (this.selectedSubscription.paymentGateway === "revenuecat") {
71
+ u.$emit("ssoEvent", {
72
+ name: "subscriptionCancelled",
73
+ data: {
74
+ subscriptionId: this.selectedSubscription.subscriptionId,
75
+ paymentGateway: this.selectedSubscription.paymentGateway,
76
+ feedback: this.cancelFeedback
77
+ }
78
+ }), this.closeCancelModal();
79
+ return;
80
+ }
81
+ this.loading = !0;
82
+ try {
83
+ const l = await y(!1, "v2").post("checkout/cancel/" + this.selectedSubscription.subscriptionId, {
84
+ feedback: this.cancelFeedback
85
+ });
86
+ if (l.data.success)
87
+ u.$emit("showToast", {
88
+ type: "success",
89
+ message: "Subscription canceled successfully"
90
+ }), await this.getAccountSettings(), this.loadSubscriptions(), this.closeCancelModal();
91
+ else
92
+ throw new Error(l.data.message || "Failed to cancel subscription");
93
+ } catch (l) {
94
+ console.error("Error canceling subscription:", l), u.$emit("showToast", {
95
+ type: "error",
96
+ message: ((s = (t = l.response) == null ? void 0 : t.data) == null ? void 0 : s.message) || "Failed to cancel subscription. Please try again."
97
+ });
98
+ } finally {
99
+ this.loading = !1;
100
+ }
101
+ }
102
+ }
103
+ }
104
+ }, F = { class: "page-login content-boxed content-boxed-padding" }, I = { class: "subheaderContainer full-top" }, T = ["src"], A = {
105
+ class: "center-text",
106
+ style: { "flex-grow": "1", "text-align": "center", margin: "0", "font-weight": "600" }
107
+ }, B = { class: "container left-text" }, L = { class: "center-text" }, N = { class: "full-top" }, U = {
108
+ key: 0,
109
+ class: "no-subscriptions center-text full-top"
110
+ }, P = { key: 1 }, G = { class: "subscription-header" }, V = { class: "subscription-info" }, j = { class: "subscription-name" }, z = { class: "subscription-details" }, K = { class: "detail-row" }, O = { class: "detail-value" }, R = { class: "detail-row" }, W = { class: "detail-value" }, Y = { class: "detail-row" }, q = { class: "detail-value" }, H = {
111
+ key: 0,
112
+ class: "detail-row"
113
+ }, J = { class: "detail-value" }, Q = {
114
+ key: 1,
115
+ class: "detail-row"
116
+ }, X = { class: "detail-value" }, Z = {
117
+ key: 0,
118
+ class: "subscription-actions"
119
+ }, $ = ["onClick", "disabled"], ss = { class: "modal-content" }, es = { class: "modal-header" }, ts = { class: "modal-body" }, os = { class: "modal-text" }, is = { class: "feedback-section" }, ls = { class: "modal-footer" }, ns = ["disabled"];
120
+ function as(t, s, l, g, c, i) {
121
+ var p;
122
+ const h = v("router-link");
123
+ return a(), r("div", F, [
124
+ t.isModal ? (a(), r("a", {
125
+ key: 0,
126
+ onClick: s[0] || (s[0] = (...o) => i.close && i.close(...o)),
127
+ class: "color-black pull-right pointer",
128
+ style: { "margin-top": "0px", position: "absolute", right: "-20px", "text-align": "right" }
129
+ }, s[6] || (s[6] = [
130
+ e("i", { class: "font-17 color-black" }, [
131
+ e("img", {
132
+ src: "https://cdn.tapni.co/icons/down-arrow.png",
133
+ class: "responsive-image",
134
+ style: { width: "35%" }
135
+ })
136
+ ], -1)
137
+ ]))) : d("", !0),
138
+ e("div", I, [
139
+ t.isModal ? d("", !0) : (a(), C(h, {
140
+ key: 0,
141
+ to: "/account",
142
+ class: "button gray-button pointer left-button"
143
+ }, {
144
+ default: _(() => [
145
+ e("img", {
146
+ src: t.getIcon("arrow-gray-right.svg"),
147
+ height: "20",
148
+ width: "20",
149
+ class: "btn-icon",
150
+ style: { rotate: "180deg" }
151
+ }, null, 8, T)
152
+ ]),
153
+ _: 1
154
+ })),
155
+ e("h2", A, n(t.ssoLang[t.appLanguage].billing), 1)
156
+ ]),
157
+ e("div", B, [
158
+ e("p", L, n(t.ssoLang[t.appLanguage].billing_p), 1),
159
+ e("div", N, [
160
+ c.subscriptions.length === 0 ? (a(), r("div", U, s[7] || (s[7] = [
161
+ e("p", { class: "gray-text" }, "There are no active subscriptions at this point.", -1)
162
+ ]))) : (a(), r("div", P, [
163
+ (a(!0), r(k, null, w(c.subscriptions, (o) => (a(), r("div", {
164
+ key: o.subscriptionId,
165
+ class: "subscription-card half-bottom"
166
+ }, [
167
+ e("div", G, [
168
+ e("div", V, [
169
+ e("h3", j, n(o.subscriptionName), 1),
170
+ e("span", {
171
+ class: S(["subscription-status", i.getStatusClass(o.status)])
172
+ }, n(i.getStatusText(o.status)), 3)
173
+ ])
174
+ ]),
175
+ e("div", z, [
176
+ e("div", K, [
177
+ s[8] || (s[8] = e("span", { class: "detail-label" }, "Amount:", -1)),
178
+ e("span", O, n(i.formatCurrency(o.amount, o.currency)), 1)
179
+ ]),
180
+ e("div", R, [
181
+ s[9] || (s[9] = e("span", { class: "detail-label" }, "Billing:", -1)),
182
+ e("span", W, n(i.formatInterval(o.interval)), 1)
183
+ ]),
184
+ e("div", Y, [
185
+ s[10] || (s[10] = e("span", { class: "detail-label" }, "Licenses:", -1)),
186
+ e("span", q, n(o.licenses), 1)
187
+ ]),
188
+ o.isTrial ? (a(), r("div", H, [
189
+ s[11] || (s[11] = e("span", { class: "detail-label" }, "Trial Ends:", -1)),
190
+ e("span", J, n(i.formatDate(o.trialEnd)), 1)
191
+ ])) : o.endDate ? (a(), r("div", Q, [
192
+ s[12] || (s[12] = e("span", { class: "detail-label" }, "Next Billing:", -1)),
193
+ e("span", X, n(i.formatDate(o.endDate)), 1)
194
+ ])) : d("", !0)
195
+ ]),
196
+ o.status !== "canceled" ? (a(), r("div", Z, [
197
+ e("button", {
198
+ onClick: (cs) => i.openCancelModal(o),
199
+ class: "cancel-button",
200
+ disabled: c.loading
201
+ }, n(c.loading ? "Processing..." : "Cancel Subscription"), 9, $)
202
+ ])) : d("", !0)
203
+ ]))), 128))
204
+ ]))
205
+ ])
206
+ ]),
207
+ c.showCancelModal ? (a(), r("div", {
208
+ key: 1,
209
+ class: "modal-overlay",
210
+ onClick: s[5] || (s[5] = M((...o) => i.closeCancelModal && i.closeCancelModal(...o), ["self"]))
211
+ }, [
212
+ e("div", ss, [
213
+ e("div", es, [
214
+ s[13] || (s[13] = e("h3", null, "Cancel Subscription", -1)),
215
+ e("button", {
216
+ onClick: s[1] || (s[1] = (...o) => i.closeCancelModal && i.closeCancelModal(...o)),
217
+ class: "close-button"
218
+ }, "×")
219
+ ]),
220
+ e("div", ts, [
221
+ e("p", os, [
222
+ s[14] || (s[14] = b(" Are you sure you want to cancel your subscription to ")),
223
+ e("b", null, n((p = c.selectedSubscription) == null ? void 0 : p.subscriptionName), 1),
224
+ s[15] || (s[15] = b("? "))
225
+ ]),
226
+ e("div", is, [
227
+ s[16] || (s[16] = e("label", { class: "feedback-label" }, "We'd love to know why you're canceling (optional):", -1)),
228
+ x(e("textarea", {
229
+ "onUpdate:modelValue": s[2] || (s[2] = (o) => c.cancelFeedback = o),
230
+ class: "feedback-textarea",
231
+ placeholder: "Your feedback helps us improve our service...",
232
+ rows: "4"
233
+ }, null, 512), [
234
+ [D, c.cancelFeedback]
235
+ ])
236
+ ])
237
+ ]),
238
+ e("div", ls, [
239
+ e("button", {
240
+ onClick: s[3] || (s[3] = (...o) => i.closeCancelModal && i.closeCancelModal(...o)),
241
+ class: "button-secondary"
242
+ }, " Keep Subscription "),
243
+ e("button", {
244
+ onClick: s[4] || (s[4] = (...o) => i.confirmCancel && i.confirmCancel(...o)),
245
+ class: "button-danger",
246
+ disabled: c.loading
247
+ }, n(c.loading ? "Canceling..." : "Confirm Cancellation"), 9, ns)
248
+ ])
249
+ ])
250
+ ])) : d("", !0)
251
+ ]);
252
+ }
253
+ const us = /* @__PURE__ */ m(E, [["render", as], ["__scopeId", "data-v-2277e85c"]]);
254
+ export {
255
+ us as default
256
+ };
@@ -0,0 +1,83 @@
1
+ import { _ as d, A as u, b as g, E as m } from "./install-7FOVy8Ol.js";
2
+ import { resolveComponent as _, openBlock as s, createElementBlock as a, createElementVNode as t, createCommentVNode as r, createBlock as h, withCtx as f, toDisplayString as i } from "vue";
3
+ const y = {
4
+ name: "AuthCustomApp",
5
+ mixins: [u],
6
+ props: {
7
+ payload: {
8
+ type: Object,
9
+ default: {}
10
+ }
11
+ },
12
+ data() {
13
+ return {
14
+ loading: !1,
15
+ app: {}
16
+ };
17
+ },
18
+ async mounted() {
19
+ this.isLoggedIn || this.$router.push("/login");
20
+ const e = await g.getRecordById({
21
+ id: this.$route.params.app,
22
+ query: {
23
+ fields: ["t_apps_name", "t_apps_icon", "t_apps_url"],
24
+ relations: []
25
+ }
26
+ });
27
+ this.app = e.data.record;
28
+ },
29
+ methods: {
30
+ close() {
31
+ m.$emit("ssoEvent", { name: "toggleAuthModal", data: !0 });
32
+ }
33
+ }
34
+ }, b = { class: "page-login content-boxed content-boxed-padding" }, v = { class: "subheaderContainer full-top" }, x = ["src"], k = {
35
+ class: "center-text",
36
+ style: { "flex-grow": "1", "text-align": "center", margin: "0", "font-weight": "600" }
37
+ }, w = { class: "container left-text" }, A = { class: "center-text" };
38
+ function C(e, o, B, E, l, n) {
39
+ const p = _("router-link");
40
+ return s(), a("div", b, [
41
+ e.isModal ? (s(), a("a", {
42
+ key: 0,
43
+ onClick: o[0] || (o[0] = (...c) => n.close && n.close(...c)),
44
+ class: "color-black pull-right pointer",
45
+ style: { "margin-top": "0px", position: "absolute", right: "-20px", "text-align": "right" }
46
+ }, o[1] || (o[1] = [
47
+ t("i", { class: "font-17 color-black" }, [
48
+ t("img", {
49
+ src: "https://cdn.tapni.co/icons/down-arrow.png",
50
+ class: "responsive-image",
51
+ style: { width: "35%" }
52
+ })
53
+ ], -1)
54
+ ]))) : r("", !0),
55
+ t("div", v, [
56
+ e.isModal ? r("", !0) : (s(), h(p, {
57
+ key: 0,
58
+ to: "/apps",
59
+ class: "button gray-button pointer left-button"
60
+ }, {
61
+ default: f(() => [
62
+ t("img", {
63
+ src: e.getIcon("arrow-gray-right.svg"),
64
+ height: "20",
65
+ width: "20",
66
+ class: "btn-icon",
67
+ style: { rotate: "180deg" }
68
+ }, null, 8, x)
69
+ ]),
70
+ _: 1
71
+ })),
72
+ t("h2", k, i(l.app.t_apps_name), 1)
73
+ ]),
74
+ t("div", w, [
75
+ t("p", A, i(e.ssoLang[e.appLanguage].apps_p), 1),
76
+ o[2] || (o[2] = t("div", { class: "full-top" }, null, -1))
77
+ ])
78
+ ]);
79
+ }
80
+ const $ = /* @__PURE__ */ d(y, [["render", C], ["__scopeId", "data-v-36b27d1f"]]);
81
+ export {
82
+ $ as default
83
+ };
@@ -0,0 +1,41 @@
1
+ import { _ as s, A as i, Q as a } from "./install-7FOVy8Ol.js";
2
+ import { resolveComponent as r, openBlock as u, createElementBlock as p, createElementVNode as o, toDisplayString as t, createVNode as d, withCtx as g, createTextVNode as _ } from "vue";
3
+ const m = {
4
+ name: "AuthQR",
5
+ mixins: [i, a]
6
+ }, L = { class: "page-login content-boxed content-boxed-padding" }, h = { style: { "text-align": "center", width: "80%", margin: "0 auto", "margin-top": "130px" } }, b = { class: "center-text" }, f = { style: { margin: "0 auto", width: "85%", "text-align": "left" } }, y = { class: "center-text" };
7
+ function v(e, n, k, w, C, q) {
8
+ const l = r("router-link");
9
+ return u(), p("div", L, [
10
+ o("h5", h, t(e.ssoLang[e.appLanguage].use_tapni_on_the_web), 1),
11
+ n[6] || (n[6] = o("br", null, null, -1)),
12
+ o("div", b, [
13
+ n[3] || (n[3] = o("div", {
14
+ id: "qrCodeContainer",
15
+ class: "qrCodeRounded",
16
+ style: { "max-width": "100%" }
17
+ }, null, -1)),
18
+ n[4] || (n[4] = o("br", null, null, -1)),
19
+ n[5] || (n[5] = o("br", null, null, -1)),
20
+ o("div", f, [
21
+ o("h2", y, t(e.ssoLang[e.appLanguage].login_by_scanning_qr_code), 1),
22
+ n[0] || (n[0] = o("br", null, null, -1)),
23
+ o("h4", null, t(e.ssoLang[e.appLanguage].open_tapni_app_on_your_phone), 1),
24
+ o("h4", null, t(e.ssoLang[e.appLanguage].go_to_settings_link_a_device), 1),
25
+ o("h4", null, t(e.ssoLang[e.appLanguage].point_your_phone_at_this_qr_code), 1),
26
+ n[1] || (n[1] = o("br", null, null, -1)),
27
+ n[2] || (n[2] = o("br", null, null, -1))
28
+ ]),
29
+ d(l, { to: "/login" }, {
30
+ default: g(() => [
31
+ _(t(e.ssoLang[e.appLanguage].choose_other_login_methods), 1)
32
+ ]),
33
+ _: 1
34
+ })
35
+ ])
36
+ ]);
37
+ }
38
+ const Q = /* @__PURE__ */ s(m, [["render", v]]);
39
+ export {
40
+ Q as default
41
+ };
@@ -1,4 +1,4 @@
1
- import { i as f } from "./install-L-cxSovH.js";
1
+ import { i as f } from "./install-7FOVy8Ol.js";
2
2
  export {
3
3
  f as default
4
4
  };