@feedmepos/mf-connect 0.1.44-prod → 0.1.46-prod
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/{Analytic-B0XiTFW0.js → Analytic--PTYdTCz.js} +11 -11
- package/dist/{App-DYwp8qCw.js → App-CCFCux3P.js} +6 -6
- package/dist/{Bin-CP2Gnf8X.js → Bin-D3mLTCYx.js} +8 -8
- package/dist/{Broadcast-whyjKtYv.js → Broadcast-17Aiufxx.js} +9 -9
- package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-CsE4P6KH.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-CMVquBaq.js} +6 -6
- package/dist/{Card-SxPryyQO.js → Card-Bx26e5ll.js} +16 -16
- package/dist/{Collections-Dkf-TR25.js → Collections-B_lm_p0s.js} +7 -7
- package/dist/{Credit-Bj-7Jz42.js → Credit-Bfdh01Hf.js} +9 -9
- package/dist/{EditCampaignSheet.vue_vue_type_script_setup_true_lang-Awnb6_WY.js → EditCampaignSheet.vue_vue_type_script_setup_true_lang-DWNvRorl.js} +30 -29
- package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-bU1I3nrA.js → EffectSheet.vue_vue_type_style_index_0_lang-CkYlghNU.js} +6 -6
- package/dist/{Experience-B4E8LXJy.js → Experience-DScp4H4M.js} +9 -9
- package/dist/{Game-Bi1DKKvm.js → Game-Cn2BXwaA.js} +10 -10
- package/dist/{Index-Cd29HQE2.js → Index-BATr5dcp.js} +10 -10
- package/dist/{Marketing-BNFR4TEj.js → Marketing-B6lhSaKk.js} +6 -6
- package/dist/{Member-BSOaSzY-.js → Member-Cr_Ehw_n.js} +10 -10
- package/dist/{MemberList-B8YX0LEV.js → MemberList-B5ogB2E6.js} +26 -26
- package/dist/{MemberTransactions-D1L8Oiq7.js → MemberTransactions-YlC-iE41.js} +1 -1
- package/dist/MessageInput.vue_vue_type_script_setup_true_lang-nTBRadZx.js +60482 -0
- package/dist/{Mission-VypLwqvF.js → Mission-Bddme86f.js} +10 -10
- package/dist/{Overview-D0tAh1hu.js → Overview-BGOM1IKg.js} +18 -18
- package/dist/{Point-BAINqz6M.js → Point-vcnTW6lY.js} +9 -9
- package/dist/{Promotion-Dcsmyze_.js → Promotion-DuCvytdc.js} +10 -10
- package/dist/{Queue-CZYvfF1T.js → Queue-Cuw7WTP_.js} +10 -10
- package/dist/{Record-D9p7o-t8.js → Record-Dc6BPAGi.js} +8 -8
- package/dist/{Reward-CQlPwXV4.js → Reward-8MFxn8we.js} +15 -15
- package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-DW7Oz7dA.js → RewardGroup.vue_vue_type_script_setup_true_lang-8k-usg9S.js} +11 -11
- package/dist/{RuleGroup.vue_vue_type_script_setup_true_lang-P_XFI4p0.js → RuleGroup.vue_vue_type_script_setup_true_lang-DRCwMmo5.js} +13 -13
- package/dist/{Segment-CvS_Eo3s.js → Segment-BJm5XtlX.js} +22 -22
- package/dist/{SelectItems.vue_vue_type_script_setup_true_lang-r0RuzF7M.js → SelectItems.vue_vue_type_script_setup_true_lang-B2LYvXlN.js} +2 -2
- package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-BGpDmOf9.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-CaFLnq7P.js} +11 -11
- package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-CiwY7ouv.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-DLAqn-0P.js} +3 -3
- package/dist/{Setting-BS3IVD60.js → Setting-CUyfrLYA.js} +609 -605
- package/dist/{Store-C7DSctaq.js → Store-DdBnVwnq.js} +19 -19
- package/dist/{StoreRewards-Dr79Mpc7.js → StoreRewards-B_yzVh4Z.js} +13 -13
- package/dist/{StoreTransactions.vue_vue_type_script_setup_true_lang-CGX8BjZg.js → StoreTransactions.vue_vue_type_script_setup_true_lang-BPPoaGqc.js} +19 -19
- package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-D9fIum70.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-D0ae_2E5.js} +1 -1
- package/dist/{Tier-rIK0FZuo.js → Tier-BpQ8DXK4.js} +20 -20
- package/dist/{Title-x-uGaue9.js → Title-D6jghz1v.js} +19 -19
- package/dist/{Transaction-DUF6Fv4u.js → Transaction-BQWs-6G7.js} +2 -2
- package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-sTNrXsoh.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-C2dJuE64.js} +6 -6
- package/dist/{Voucher-DlDk466I.js → Voucher-DnL_66X2.js} +13 -13
- package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-BXfb3q80.js → VoucherEditor.vue_vue_type_script_setup_true_lang-naUCARDO.js} +10 -10
- package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-HCNzyNOp.js → ZodTextField.vue_vue_type_script_setup_true_lang-yj2c4i_u.js} +1 -1
- package/dist/{app-DzUknT2x.js → app-Cemiie6P.js} +30 -30
- package/dist/{app-DY9APO7j.js → app-Cwax62X-.js} +1 -1
- package/dist/app.js +1 -1
- package/dist/{business-DjsjI4kp.js → business-BTJVFnrW.js} +1 -1
- package/dist/{campaign-ZjD3chey.js → campaign-C34w0eci.js} +2 -2
- package/dist/{campaign-DfOj7zSn.js → campaign-XX6bwpYj.js} +9 -9
- package/dist/{campaign.enum-D3xo6Cks.js → campaign.enum-CTMwHgAV.js} +1 -1
- package/dist/{campaign.fn-By1DHCjK.js → campaign.fn-nJl0vZum.js} +89 -89
- package/dist/{collectible.enum-BpR3ioUe.js → collectible.enum-DpJV0kLI.js} +1 -1
- package/dist/{collection.fn-CIymOVNk.js → collection.fn-D5beOWlp.js} +2 -2
- package/dist/{dto-uRM5uaA_.js → dto-CCxjvwZe.js} +4 -4
- package/dist/{effect-DSFeDhhJ.js → effect-B9ryfTOn.js} +1 -1
- package/dist/{email-addresses-B3pZNcNt.js → email-addresses-Bn80jSud.js} +1 -1
- package/dist/{export-B9WfSHAt.js → export-CLB408ho.js} +3 -3
- package/dist/{helper-CCgGEtdx.js → helper-DgoAVTVe.js} +1 -1
- package/dist/{index-BmWqCJCi.js → index-B2BKFdEy.js} +1097 -1097
- package/dist/{index-BeYLK0K2.js → index-B9wdSOIQ.js} +11 -4
- package/dist/{index-BLWIwW6r.js → index-Blmkh0Ui.js} +5 -5
- package/dist/{index-C7OvCzb4.js → index-D90Ba87K.js} +1 -1
- package/dist/{index-lSAv8y7n.js → index-DCrV9spQ.js} +21 -10
- package/dist/{index-C5bUcLyZ.js → index-DUtQaOO2.js} +1 -1
- package/dist/{index-CXLJaee4.js → index-Djq2lySj.js} +1 -1
- package/dist/{index-JLJo07Rj.js → index-DsgbkezN.js} +1 -1
- package/dist/{index-B9JaqqtM.js → index-FMcRNPk_.js} +1 -1
- package/dist/{index-B06uxpDF.js → index-JY8MjiBK.js} +1095 -1091
- package/dist/{index-B8Qg-Ixj.js → index-KYo_FgI8.js} +3 -3
- package/dist/{index-BmS1egoc.js → index-bkL81TwC.js} +1 -1
- package/dist/{index-BTszUs2N.js → index-eiHOH5QM.js} +1 -1
- package/dist/{index-v_4sk2U_.js → index-t_4aIo1w.js} +2 -2
- package/dist/{index.esm2017-CJartb_e.js → index.esm2017-toVKAoKi.js} +59 -59
- package/dist/{loading-C9v97WxS.js → loading-vrEcUlJa.js} +1 -1
- package/dist/{membership-CXmxuzDB.js → membership-ChiyKtoA.js} +3 -3
- package/dist/{money-lLHkYDTU.js → money-tOAuywfS.js} +1 -1
- package/dist/{number-BFT1IBUD.js → number-DiXSJR50.js} +1 -1
- package/dist/objectid-C856JGM4.js +145 -0
- package/dist/{plugins-D1scPye4.js → plugins-p8ID0wqZ.js} +2 -2
- package/dist/{reward-clRs-T7e.js → reward-Bo4HsVNH.js} +1 -1
- package/dist/{rule-CiPYLle-.js → rule-LDThYbT7.js} +3 -3
- package/dist/{rule-builder-Dip7ySqF.js → rule-builder-7iBcFApT.js} +1 -1
- package/dist/style.css +4 -1
- package/dist/{template-Cjft7Yxd.js → template-C6cnCLah.js} +4 -4
- package/dist/{trigger-CEHnWaQ7.js → trigger-ZyJEZVxL.js} +4 -4
- package/dist/{user-WVLA3bdA.js → user-WDNaXiRu.js} +1 -1
- package/dist/{vue-i18n-h56mRikn.js → vue-i18n-BWI3POch.js} +317 -317
- package/dist/{xlsx-SS9sL5Pj.js → xlsx-JDV04zZH.js} +1 -1
- package/package.json +5 -1
- package/dist/MessageInput.vue_vue_type_script_setup_true_lang-DYoBeQwx.js +0 -455
- package/dist/objectid-G0S1Z8UI.js +0 -145
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
import { defineComponent as Xe, ref as
|
|
2
|
-
import { h as
|
|
3
|
-
import { Z as
|
|
4
|
-
import { useDialog as
|
|
5
|
-
import { u as
|
|
6
|
-
import { u as
|
|
7
|
-
import { u as
|
|
8
|
-
import { u as
|
|
9
|
-
import "./index-
|
|
10
|
-
import { s as
|
|
11
|
-
import { _ as
|
|
12
|
-
import { a as
|
|
13
|
-
import { _ as
|
|
14
|
-
import { M as
|
|
15
|
-
import { u as
|
|
16
|
-
import { useCoreStore as
|
|
17
|
-
import { m as
|
|
18
|
-
import { S as
|
|
19
|
-
import { o as
|
|
20
|
-
import { a as
|
|
21
|
-
var ie = {},
|
|
1
|
+
import { defineComponent as Xe, ref as z, computed as ge, onMounted as Ze, resolveComponent as F, openBlock as x, createBlock as me, withCtx as ne, createElementVNode as y, createVNode as S, unref as c, isRef as et, createElementBlock as q, Fragment as ue, toDisplayString as k, createTextVNode as oe, createCommentVNode as te, renderList as Ye } from "vue";
|
|
2
|
+
import { h as Et } from "./moment-BWErdI6_.js";
|
|
3
|
+
import { Z as je } from "./zod-Bg2FbC-D.js";
|
|
4
|
+
import { useDialog as tt } from "@feedmepos/ui-library";
|
|
5
|
+
import { u as At } from "./loading-vrEcUlJa.js";
|
|
6
|
+
import { u as Bt } from "./app-wDQR6dpb.js";
|
|
7
|
+
import { u as Ie, l as nt } from "./business-BTJVFnrW.js";
|
|
8
|
+
import { u as ot } from "./membership-ChiyKtoA.js";
|
|
9
|
+
import "./index-B2BKFdEy.js";
|
|
10
|
+
import { s as Mt, k as St } from "./index-Blmkh0Ui.js";
|
|
11
|
+
import { _ as It } from "./ImageInput.vue_vue_type_script_setup_true_lang-ByhTB9Ie.js";
|
|
12
|
+
import { a as rt, p as Pt, f as G } from "./plugins-p8ID0wqZ.js";
|
|
13
|
+
import { _ as Tt } from "./TargetLocationInput.vue_vue_type_script_setup_true_lang-D0ae_2E5.js";
|
|
14
|
+
import { M as Nt, _ as Ut } from "./MessageInput.vue_vue_type_script_setup_true_lang-nTBRadZx.js";
|
|
15
|
+
import { u as Lt } from "./vue-i18n-BWI3POch.js";
|
|
16
|
+
import { useCoreStore as Ft } from "@feedmepos/mf-common";
|
|
17
|
+
import { m as Je } from "./index-B9wdSOIQ.js";
|
|
18
|
+
import { S as qe } from "./index-JY8MjiBK.js";
|
|
19
|
+
import { o as Rt } from "./objectId-dwaoBfJX.js";
|
|
20
|
+
import { a as kt } from "./object-qECH92oz.js";
|
|
21
|
+
var ie = {}, Dt = function() {
|
|
22
22
|
return typeof Promise == "function" && Promise.prototype && Promise.prototype.then;
|
|
23
|
-
},
|
|
24
|
-
let
|
|
25
|
-
const
|
|
23
|
+
}, st = {}, U = {};
|
|
24
|
+
let Le;
|
|
25
|
+
const Vt = [
|
|
26
26
|
0,
|
|
27
27
|
// Not used
|
|
28
28
|
26,
|
|
@@ -66,38 +66,38 @@ const Dt = [
|
|
|
66
66
|
3532,
|
|
67
67
|
3706
|
|
68
68
|
];
|
|
69
|
-
|
|
69
|
+
U.getSymbolSize = function(e) {
|
|
70
70
|
if (!e) throw new Error('"version" cannot be null or undefined');
|
|
71
71
|
if (e < 1 || e > 40) throw new Error('"version" should be in range from 1 to 40');
|
|
72
72
|
return e * 4 + 17;
|
|
73
73
|
};
|
|
74
|
-
|
|
75
|
-
return
|
|
74
|
+
U.getSymbolTotalCodewords = function(e) {
|
|
75
|
+
return Vt[e];
|
|
76
76
|
};
|
|
77
|
-
|
|
77
|
+
U.getBCHDigit = function(t) {
|
|
78
78
|
let e = 0;
|
|
79
79
|
for (; t !== 0; )
|
|
80
80
|
e++, t >>>= 1;
|
|
81
81
|
return e;
|
|
82
82
|
};
|
|
83
|
-
|
|
83
|
+
U.setToSJISFunction = function(e) {
|
|
84
84
|
if (typeof e != "function")
|
|
85
85
|
throw new Error('"toSJISFunc" is not a valid function.');
|
|
86
|
-
|
|
86
|
+
Le = e;
|
|
87
87
|
};
|
|
88
|
-
|
|
89
|
-
return typeof
|
|
88
|
+
U.isKanjiModeEnabled = function() {
|
|
89
|
+
return typeof Le < "u";
|
|
90
90
|
};
|
|
91
|
-
|
|
92
|
-
return
|
|
91
|
+
U.toSJIS = function(e) {
|
|
92
|
+
return Le(e);
|
|
93
93
|
};
|
|
94
|
-
var
|
|
94
|
+
var ye = {};
|
|
95
95
|
(function(t) {
|
|
96
96
|
t.L = { bit: 1 }, t.M = { bit: 0 }, t.Q = { bit: 3 }, t.H = { bit: 2 };
|
|
97
|
-
function e(
|
|
98
|
-
if (typeof
|
|
97
|
+
function e(s) {
|
|
98
|
+
if (typeof s != "string")
|
|
99
99
|
throw new Error("Param is not a string");
|
|
100
|
-
switch (
|
|
100
|
+
switch (s.toLowerCase()) {
|
|
101
101
|
case "l":
|
|
102
102
|
case "low":
|
|
103
103
|
return t.L;
|
|
@@ -111,7 +111,7 @@ var pe = {};
|
|
|
111
111
|
case "high":
|
|
112
112
|
return t.H;
|
|
113
113
|
default:
|
|
114
|
-
throw new Error("Unknown EC Level: " +
|
|
114
|
+
throw new Error("Unknown EC Level: " + s);
|
|
115
115
|
}
|
|
116
116
|
}
|
|
117
117
|
t.isValid = function(r) {
|
|
@@ -125,7 +125,7 @@ var pe = {};
|
|
|
125
125
|
return o;
|
|
126
126
|
}
|
|
127
127
|
};
|
|
128
|
-
})(
|
|
128
|
+
})(ye);
|
|
129
129
|
function it() {
|
|
130
130
|
this.buffer = [], this.length = 0;
|
|
131
131
|
}
|
|
@@ -135,8 +135,8 @@ it.prototype = {
|
|
|
135
135
|
return (this.buffer[e] >>> 7 - t % 8 & 1) === 1;
|
|
136
136
|
},
|
|
137
137
|
put: function(t, e) {
|
|
138
|
-
for (let
|
|
139
|
-
this.putBit((t >>> e -
|
|
138
|
+
for (let s = 0; s < e; s++)
|
|
139
|
+
this.putBit((t >>> e - s - 1 & 1) === 1);
|
|
140
140
|
},
|
|
141
141
|
getLengthInBits: function() {
|
|
142
142
|
return this.length;
|
|
@@ -146,58 +146,58 @@ it.prototype = {
|
|
|
146
146
|
this.buffer.length <= e && this.buffer.push(0), t && (this.buffer[e] |= 128 >>> this.length % 8), this.length++;
|
|
147
147
|
}
|
|
148
148
|
};
|
|
149
|
-
var
|
|
150
|
-
function
|
|
149
|
+
var xt = it;
|
|
150
|
+
function ae(t) {
|
|
151
151
|
if (!t || t < 1)
|
|
152
152
|
throw new Error("BitMatrix size must be defined and greater than 0");
|
|
153
153
|
this.size = t, this.data = new Uint8Array(t * t), this.reservedBit = new Uint8Array(t * t);
|
|
154
154
|
}
|
|
155
|
-
|
|
155
|
+
ae.prototype.set = function(t, e, s, r) {
|
|
156
156
|
const o = t * this.size + e;
|
|
157
|
-
this.data[o] =
|
|
157
|
+
this.data[o] = s, r && (this.reservedBit[o] = !0);
|
|
158
158
|
};
|
|
159
|
-
|
|
159
|
+
ae.prototype.get = function(t, e) {
|
|
160
160
|
return this.data[t * this.size + e];
|
|
161
161
|
};
|
|
162
|
-
|
|
163
|
-
this.data[t * this.size + e] ^=
|
|
162
|
+
ae.prototype.xor = function(t, e, s) {
|
|
163
|
+
this.data[t * this.size + e] ^= s;
|
|
164
164
|
};
|
|
165
|
-
|
|
165
|
+
ae.prototype.isReserved = function(t, e) {
|
|
166
166
|
return this.reservedBit[t * this.size + e];
|
|
167
167
|
};
|
|
168
|
-
var
|
|
168
|
+
var $t = ae, at = {};
|
|
169
169
|
(function(t) {
|
|
170
|
-
const e =
|
|
170
|
+
const e = U.getSymbolSize;
|
|
171
171
|
t.getRowColCoords = function(r) {
|
|
172
172
|
if (r === 1) return [];
|
|
173
173
|
const o = Math.floor(r / 7) + 2, n = e(r), a = n === 145 ? 26 : Math.ceil((n - 13) / (2 * o - 2)) * 2, l = [n - 7];
|
|
174
|
-
for (let
|
|
175
|
-
l[
|
|
174
|
+
for (let i = 1; i < o - 1; i++)
|
|
175
|
+
l[i] = l[i - 1] - a;
|
|
176
176
|
return l.push(6), l.reverse();
|
|
177
177
|
}, t.getPositions = function(r) {
|
|
178
178
|
const o = [], n = t.getRowColCoords(r), a = n.length;
|
|
179
179
|
for (let l = 0; l < a; l++)
|
|
180
|
-
for (let
|
|
181
|
-
l === 0 &&
|
|
182
|
-
l === 0 &&
|
|
183
|
-
l === a - 1 &&
|
|
180
|
+
for (let i = 0; i < a; i++)
|
|
181
|
+
l === 0 && i === 0 || // top-left
|
|
182
|
+
l === 0 && i === a - 1 || // bottom-left
|
|
183
|
+
l === a - 1 && i === 0 || o.push([n[l], n[i]]);
|
|
184
184
|
return o;
|
|
185
185
|
};
|
|
186
|
-
})(
|
|
187
|
-
var
|
|
188
|
-
const
|
|
189
|
-
|
|
190
|
-
const
|
|
186
|
+
})(at);
|
|
187
|
+
var lt = {};
|
|
188
|
+
const zt = U.getSymbolSize, Ge = 7;
|
|
189
|
+
lt.getPositions = function(e) {
|
|
190
|
+
const s = zt(e);
|
|
191
191
|
return [
|
|
192
192
|
// top-left
|
|
193
193
|
[0, 0],
|
|
194
194
|
// top-right
|
|
195
|
-
[
|
|
195
|
+
[s - Ge, 0],
|
|
196
196
|
// bottom-left
|
|
197
|
-
[0,
|
|
197
|
+
[0, s - Ge]
|
|
198
198
|
];
|
|
199
199
|
};
|
|
200
|
-
var
|
|
200
|
+
var ct = {};
|
|
201
201
|
(function(t) {
|
|
202
202
|
t.Patterns = {
|
|
203
203
|
PATTERN000: 0,
|
|
@@ -221,41 +221,41 @@ var lt = {};
|
|
|
221
221
|
return t.isValid(o) ? parseInt(o, 10) : void 0;
|
|
222
222
|
}, t.getPenaltyN1 = function(o) {
|
|
223
223
|
const n = o.size;
|
|
224
|
-
let a = 0, l = 0,
|
|
224
|
+
let a = 0, l = 0, i = 0, u = null, f = null;
|
|
225
225
|
for (let A = 0; A < n; A++) {
|
|
226
|
-
l =
|
|
226
|
+
l = i = 0, u = f = null;
|
|
227
227
|
for (let m = 0; m < n; m++) {
|
|
228
228
|
let d = o.get(A, m);
|
|
229
|
-
d === u ? l++ : (l >= 5 && (a += e.N1 + (l - 5)), u = d, l = 1), d = o.get(m, A), d === f ?
|
|
229
|
+
d === u ? l++ : (l >= 5 && (a += e.N1 + (l - 5)), u = d, l = 1), d = o.get(m, A), d === f ? i++ : (i >= 5 && (a += e.N1 + (i - 5)), f = d, i = 1);
|
|
230
230
|
}
|
|
231
|
-
l >= 5 && (a += e.N1 + (l - 5)),
|
|
231
|
+
l >= 5 && (a += e.N1 + (l - 5)), i >= 5 && (a += e.N1 + (i - 5));
|
|
232
232
|
}
|
|
233
233
|
return a;
|
|
234
234
|
}, t.getPenaltyN2 = function(o) {
|
|
235
235
|
const n = o.size;
|
|
236
236
|
let a = 0;
|
|
237
237
|
for (let l = 0; l < n - 1; l++)
|
|
238
|
-
for (let
|
|
239
|
-
const u = o.get(l,
|
|
238
|
+
for (let i = 0; i < n - 1; i++) {
|
|
239
|
+
const u = o.get(l, i) + o.get(l, i + 1) + o.get(l + 1, i) + o.get(l + 1, i + 1);
|
|
240
240
|
(u === 4 || u === 0) && a++;
|
|
241
241
|
}
|
|
242
242
|
return a * e.N2;
|
|
243
243
|
}, t.getPenaltyN3 = function(o) {
|
|
244
244
|
const n = o.size;
|
|
245
|
-
let a = 0, l = 0,
|
|
245
|
+
let a = 0, l = 0, i = 0;
|
|
246
246
|
for (let u = 0; u < n; u++) {
|
|
247
|
-
l =
|
|
247
|
+
l = i = 0;
|
|
248
248
|
for (let f = 0; f < n; f++)
|
|
249
|
-
l = l << 1 & 2047 | o.get(u, f), f >= 10 && (l === 1488 || l === 93) && a++,
|
|
249
|
+
l = l << 1 & 2047 | o.get(u, f), f >= 10 && (l === 1488 || l === 93) && a++, i = i << 1 & 2047 | o.get(f, u), f >= 10 && (i === 1488 || i === 93) && a++;
|
|
250
250
|
}
|
|
251
251
|
return a * e.N3;
|
|
252
252
|
}, t.getPenaltyN4 = function(o) {
|
|
253
253
|
let n = 0;
|
|
254
254
|
const a = o.data.length;
|
|
255
|
-
for (let
|
|
255
|
+
for (let i = 0; i < a; i++) n += o.data[i];
|
|
256
256
|
return Math.abs(Math.ceil(n * 100 / a / 5) - 10) * e.N4;
|
|
257
257
|
};
|
|
258
|
-
function
|
|
258
|
+
function s(r, o, n) {
|
|
259
259
|
switch (r) {
|
|
260
260
|
case t.Patterns.PATTERN000:
|
|
261
261
|
return (o + n) % 2 === 0;
|
|
@@ -280,21 +280,21 @@ var lt = {};
|
|
|
280
280
|
t.applyMask = function(o, n) {
|
|
281
281
|
const a = n.size;
|
|
282
282
|
for (let l = 0; l < a; l++)
|
|
283
|
-
for (let
|
|
284
|
-
n.isReserved(
|
|
283
|
+
for (let i = 0; i < a; i++)
|
|
284
|
+
n.isReserved(i, l) || n.xor(i, l, s(o, i, l));
|
|
285
285
|
}, t.getBestMask = function(o, n) {
|
|
286
286
|
const a = Object.keys(t.Patterns).length;
|
|
287
|
-
let l = 0,
|
|
287
|
+
let l = 0, i = 1 / 0;
|
|
288
288
|
for (let u = 0; u < a; u++) {
|
|
289
289
|
n(u), t.applyMask(u, o);
|
|
290
290
|
const f = t.getPenaltyN1(o) + t.getPenaltyN2(o) + t.getPenaltyN3(o) + t.getPenaltyN4(o);
|
|
291
|
-
t.applyMask(u, o), f <
|
|
291
|
+
t.applyMask(u, o), f < i && (i = f, l = u);
|
|
292
292
|
}
|
|
293
293
|
return l;
|
|
294
294
|
};
|
|
295
|
-
})(
|
|
296
|
-
var
|
|
297
|
-
const
|
|
295
|
+
})(ct);
|
|
296
|
+
var we = {};
|
|
297
|
+
const K = ye, de = [
|
|
298
298
|
// L M Q H
|
|
299
299
|
1,
|
|
300
300
|
1,
|
|
@@ -456,7 +456,7 @@ const O = pe, ue = [
|
|
|
456
456
|
49,
|
|
457
457
|
68,
|
|
458
458
|
81
|
|
459
|
-
],
|
|
459
|
+
], fe = [
|
|
460
460
|
// L M Q H
|
|
461
461
|
7,
|
|
462
462
|
10,
|
|
@@ -619,55 +619,55 @@ const O = pe, ue = [
|
|
|
619
619
|
2040,
|
|
620
620
|
2430
|
|
621
621
|
];
|
|
622
|
-
|
|
623
|
-
switch (
|
|
624
|
-
case
|
|
625
|
-
return ue[(e - 1) * 4 + 0];
|
|
626
|
-
case O.M:
|
|
627
|
-
return ue[(e - 1) * 4 + 1];
|
|
628
|
-
case O.Q:
|
|
629
|
-
return ue[(e - 1) * 4 + 2];
|
|
630
|
-
case O.H:
|
|
631
|
-
return ue[(e - 1) * 4 + 3];
|
|
632
|
-
default:
|
|
633
|
-
return;
|
|
634
|
-
}
|
|
635
|
-
};
|
|
636
|
-
ye.getTotalCodewordsCount = function(e, i) {
|
|
637
|
-
switch (i) {
|
|
638
|
-
case O.L:
|
|
622
|
+
we.getBlocksCount = function(e, s) {
|
|
623
|
+
switch (s) {
|
|
624
|
+
case K.L:
|
|
639
625
|
return de[(e - 1) * 4 + 0];
|
|
640
|
-
case
|
|
626
|
+
case K.M:
|
|
641
627
|
return de[(e - 1) * 4 + 1];
|
|
642
|
-
case
|
|
628
|
+
case K.Q:
|
|
643
629
|
return de[(e - 1) * 4 + 2];
|
|
644
|
-
case
|
|
630
|
+
case K.H:
|
|
645
631
|
return de[(e - 1) * 4 + 3];
|
|
646
632
|
default:
|
|
647
633
|
return;
|
|
648
634
|
}
|
|
649
635
|
};
|
|
650
|
-
|
|
651
|
-
|
|
636
|
+
we.getTotalCodewordsCount = function(e, s) {
|
|
637
|
+
switch (s) {
|
|
638
|
+
case K.L:
|
|
639
|
+
return fe[(e - 1) * 4 + 0];
|
|
640
|
+
case K.M:
|
|
641
|
+
return fe[(e - 1) * 4 + 1];
|
|
642
|
+
case K.Q:
|
|
643
|
+
return fe[(e - 1) * 4 + 2];
|
|
644
|
+
case K.H:
|
|
645
|
+
return fe[(e - 1) * 4 + 3];
|
|
646
|
+
default:
|
|
647
|
+
return;
|
|
648
|
+
}
|
|
649
|
+
};
|
|
650
|
+
var ut = {}, be = {};
|
|
651
|
+
const re = new Uint8Array(512), he = new Uint8Array(256);
|
|
652
652
|
(function() {
|
|
653
653
|
let e = 1;
|
|
654
|
-
for (let
|
|
655
|
-
|
|
656
|
-
for (let
|
|
657
|
-
|
|
654
|
+
for (let s = 0; s < 255; s++)
|
|
655
|
+
re[s] = e, he[e] = s, e <<= 1, e & 256 && (e ^= 285);
|
|
656
|
+
for (let s = 255; s < 512; s++)
|
|
657
|
+
re[s] = re[s - 255];
|
|
658
658
|
})();
|
|
659
|
-
|
|
659
|
+
be.log = function(e) {
|
|
660
660
|
if (e < 1) throw new Error("log(" + e + ")");
|
|
661
|
-
return
|
|
661
|
+
return he[e];
|
|
662
662
|
};
|
|
663
|
-
|
|
664
|
-
return
|
|
663
|
+
be.exp = function(e) {
|
|
664
|
+
return re[e];
|
|
665
665
|
};
|
|
666
|
-
|
|
667
|
-
return e === 0 ||
|
|
666
|
+
be.mul = function(e, s) {
|
|
667
|
+
return e === 0 || s === 0 ? 0 : re[he[e] + he[s]];
|
|
668
668
|
};
|
|
669
669
|
(function(t) {
|
|
670
|
-
const e =
|
|
670
|
+
const e = be;
|
|
671
671
|
t.mul = function(r, o) {
|
|
672
672
|
const n = new Uint8Array(r.length + o.length - 1);
|
|
673
673
|
for (let a = 0; a < r.length; a++)
|
|
@@ -678,8 +678,8 @@ we.mul = function(e, i) {
|
|
|
678
678
|
let n = new Uint8Array(r);
|
|
679
679
|
for (; n.length - o.length >= 0; ) {
|
|
680
680
|
const a = n[0];
|
|
681
|
-
for (let
|
|
682
|
-
n[
|
|
681
|
+
for (let i = 0; i < o.length; i++)
|
|
682
|
+
n[i] ^= e.mul(o[i], a);
|
|
683
683
|
let l = 0;
|
|
684
684
|
for (; l < n.length && n[l] === 0; ) l++;
|
|
685
685
|
n = n.slice(l);
|
|
@@ -691,53 +691,53 @@ we.mul = function(e, i) {
|
|
|
691
691
|
o = t.mul(o, new Uint8Array([1, e.exp(n)]));
|
|
692
692
|
return o;
|
|
693
693
|
};
|
|
694
|
-
})(
|
|
695
|
-
const
|
|
696
|
-
function
|
|
694
|
+
})(ut);
|
|
695
|
+
const dt = ut;
|
|
696
|
+
function Fe(t) {
|
|
697
697
|
this.genPoly = void 0, this.degree = t, this.degree && this.initialize(this.degree);
|
|
698
698
|
}
|
|
699
|
-
|
|
700
|
-
this.degree = e, this.genPoly =
|
|
699
|
+
Fe.prototype.initialize = function(e) {
|
|
700
|
+
this.degree = e, this.genPoly = dt.generateECPolynomial(this.degree);
|
|
701
701
|
};
|
|
702
|
-
|
|
702
|
+
Fe.prototype.encode = function(e) {
|
|
703
703
|
if (!this.genPoly)
|
|
704
704
|
throw new Error("Encoder not initialized");
|
|
705
|
-
const
|
|
706
|
-
|
|
707
|
-
const r =
|
|
705
|
+
const s = new Uint8Array(e.length + this.degree);
|
|
706
|
+
s.set(e);
|
|
707
|
+
const r = dt.mod(s, this.genPoly), o = this.degree - r.length;
|
|
708
708
|
if (o > 0) {
|
|
709
709
|
const n = new Uint8Array(this.degree);
|
|
710
710
|
return n.set(r, o), n;
|
|
711
711
|
}
|
|
712
712
|
return r;
|
|
713
713
|
};
|
|
714
|
-
var
|
|
715
|
-
|
|
714
|
+
var Ht = Fe, ft = {}, O = {}, Re = {};
|
|
715
|
+
Re.isValid = function(e) {
|
|
716
716
|
return !isNaN(e) && e >= 1 && e <= 40;
|
|
717
717
|
};
|
|
718
718
|
var $ = {};
|
|
719
|
-
const
|
|
720
|
-
let
|
|
721
|
-
|
|
722
|
-
const
|
|
719
|
+
const mt = "[0-9]+", Kt = "[A-Z $%*+\\-./:]+";
|
|
720
|
+
let se = "(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";
|
|
721
|
+
se = se.replace(/u/g, "\\u");
|
|
722
|
+
const Ot = "(?:(?![A-Z0-9 $%*+\\-./:]|" + se + `)(?:.|[\r
|
|
723
723
|
]))+`;
|
|
724
|
-
$.KANJI = new RegExp(
|
|
724
|
+
$.KANJI = new RegExp(se, "g");
|
|
725
725
|
$.BYTE_KANJI = new RegExp("[^A-Z0-9 $%*+\\-./:]+", "g");
|
|
726
|
-
$.BYTE = new RegExp(
|
|
727
|
-
$.NUMERIC = new RegExp(
|
|
728
|
-
$.ALPHANUMERIC = new RegExp(
|
|
729
|
-
const
|
|
726
|
+
$.BYTE = new RegExp(Ot, "g");
|
|
727
|
+
$.NUMERIC = new RegExp(mt, "g");
|
|
728
|
+
$.ALPHANUMERIC = new RegExp(Kt, "g");
|
|
729
|
+
const Yt = new RegExp("^" + se + "$"), jt = new RegExp("^" + mt + "$"), Jt = new RegExp("^[A-Z0-9 $%*+\\-./:]+$");
|
|
730
730
|
$.testKanji = function(e) {
|
|
731
|
-
return
|
|
731
|
+
return Yt.test(e);
|
|
732
732
|
};
|
|
733
733
|
$.testNumeric = function(e) {
|
|
734
|
-
return
|
|
734
|
+
return jt.test(e);
|
|
735
735
|
};
|
|
736
736
|
$.testAlphanumeric = function(e) {
|
|
737
|
-
return
|
|
737
|
+
return Jt.test(e);
|
|
738
738
|
};
|
|
739
739
|
(function(t) {
|
|
740
|
-
const e =
|
|
740
|
+
const e = Re, s = $;
|
|
741
741
|
t.NUMERIC = {
|
|
742
742
|
id: "Numeric",
|
|
743
743
|
bit: 1,
|
|
@@ -762,7 +762,7 @@ $.testAlphanumeric = function(e) {
|
|
|
762
762
|
throw new Error("Invalid version: " + a);
|
|
763
763
|
return a >= 1 && a < 10 ? n.ccBits[0] : a < 27 ? n.ccBits[1] : n.ccBits[2];
|
|
764
764
|
}, t.getBestModeForData = function(n) {
|
|
765
|
-
return
|
|
765
|
+
return s.testNumeric(n) ? t.NUMERIC : s.testAlphanumeric(n) ? t.ALPHANUMERIC : s.testKanji(n) ? t.KANJI : t.BYTE;
|
|
766
766
|
}, t.toString = function(n) {
|
|
767
767
|
if (n && n.id) return n.id;
|
|
768
768
|
throw new Error("Invalid mode");
|
|
@@ -794,10 +794,10 @@ $.testAlphanumeric = function(e) {
|
|
|
794
794
|
return a;
|
|
795
795
|
}
|
|
796
796
|
};
|
|
797
|
-
})(
|
|
797
|
+
})(O);
|
|
798
798
|
(function(t) {
|
|
799
|
-
const e =
|
|
800
|
-
function
|
|
799
|
+
const e = U, s = we, r = ye, o = O, n = Re, a = 7973, l = e.getBCHDigit(a);
|
|
800
|
+
function i(m, d, v) {
|
|
801
801
|
for (let C = 1; C <= 40; C++)
|
|
802
802
|
if (d <= t.getCapacity(C, v, m))
|
|
803
803
|
return C;
|
|
@@ -808,8 +808,8 @@ $.testAlphanumeric = function(e) {
|
|
|
808
808
|
function f(m, d) {
|
|
809
809
|
let v = 0;
|
|
810
810
|
return m.forEach(function(C) {
|
|
811
|
-
const
|
|
812
|
-
v +=
|
|
811
|
+
const I = u(C.mode, d);
|
|
812
|
+
v += I + C.getBitsLength();
|
|
813
813
|
}), v;
|
|
814
814
|
}
|
|
815
815
|
function A(m, d) {
|
|
@@ -823,7 +823,7 @@ $.testAlphanumeric = function(e) {
|
|
|
823
823
|
if (!n.isValid(d))
|
|
824
824
|
throw new Error("Invalid QR Code version");
|
|
825
825
|
typeof C > "u" && (C = o.BYTE);
|
|
826
|
-
const
|
|
826
|
+
const I = e.getSymbolTotalCodewords(d), p = s.getTotalCodewordsCount(d, v), b = (I - p) * 8;
|
|
827
827
|
if (C === o.MIXED) return b;
|
|
828
828
|
const g = b - u(C, d);
|
|
829
829
|
switch (C) {
|
|
@@ -839,16 +839,16 @@ $.testAlphanumeric = function(e) {
|
|
|
839
839
|
}
|
|
840
840
|
}, t.getBestVersionForData = function(d, v) {
|
|
841
841
|
let C;
|
|
842
|
-
const
|
|
842
|
+
const I = r.from(v, r.M);
|
|
843
843
|
if (Array.isArray(d)) {
|
|
844
844
|
if (d.length > 1)
|
|
845
|
-
return A(d,
|
|
845
|
+
return A(d, I);
|
|
846
846
|
if (d.length === 0)
|
|
847
847
|
return 1;
|
|
848
848
|
C = d[0];
|
|
849
849
|
} else
|
|
850
850
|
C = d;
|
|
851
|
-
return
|
|
851
|
+
return i(C.mode, C.getLength(), I);
|
|
852
852
|
}, t.getEncodedBits = function(d) {
|
|
853
853
|
if (!n.isValid(d) || d < 7)
|
|
854
854
|
throw new Error("Invalid QR Code version");
|
|
@@ -857,20 +857,20 @@ $.testAlphanumeric = function(e) {
|
|
|
857
857
|
v ^= a << e.getBCHDigit(v) - l;
|
|
858
858
|
return d << 12 | v;
|
|
859
859
|
};
|
|
860
|
-
})(
|
|
861
|
-
var
|
|
862
|
-
const
|
|
863
|
-
|
|
864
|
-
const r = e.bit << 3 |
|
|
860
|
+
})(ft);
|
|
861
|
+
var gt = {};
|
|
862
|
+
const Pe = U, ht = 1335, qt = 21522, Qe = Pe.getBCHDigit(ht);
|
|
863
|
+
gt.getEncodedBits = function(e, s) {
|
|
864
|
+
const r = e.bit << 3 | s;
|
|
865
865
|
let o = r << 10;
|
|
866
|
-
for (;
|
|
867
|
-
o ^=
|
|
868
|
-
return (r << 10 | o) ^
|
|
866
|
+
for (; Pe.getBCHDigit(o) - Qe >= 0; )
|
|
867
|
+
o ^= ht << Pe.getBCHDigit(o) - Qe;
|
|
868
|
+
return (r << 10 | o) ^ qt;
|
|
869
869
|
};
|
|
870
|
-
var
|
|
871
|
-
const
|
|
870
|
+
var pt = {};
|
|
871
|
+
const Gt = O;
|
|
872
872
|
function Q(t) {
|
|
873
|
-
this.mode =
|
|
873
|
+
this.mode = Gt.NUMERIC, this.data = t.toString();
|
|
874
874
|
}
|
|
875
875
|
Q.getBitsLength = function(e) {
|
|
876
876
|
return 10 * Math.floor(e / 3) + (e % 3 ? e % 3 * 3 + 1 : 0);
|
|
@@ -882,14 +882,14 @@ Q.prototype.getBitsLength = function() {
|
|
|
882
882
|
return Q.getBitsLength(this.data.length);
|
|
883
883
|
};
|
|
884
884
|
Q.prototype.write = function(e) {
|
|
885
|
-
let
|
|
886
|
-
for (
|
|
887
|
-
r = this.data.substr(
|
|
888
|
-
const n = this.data.length -
|
|
889
|
-
n > 0 && (r = this.data.substr(
|
|
885
|
+
let s, r, o;
|
|
886
|
+
for (s = 0; s + 3 <= this.data.length; s += 3)
|
|
887
|
+
r = this.data.substr(s, 3), o = parseInt(r, 10), e.put(o, 10);
|
|
888
|
+
const n = this.data.length - s;
|
|
889
|
+
n > 0 && (r = this.data.substr(s), o = parseInt(r, 10), e.put(o, n * 3 + 1));
|
|
890
890
|
};
|
|
891
|
-
var
|
|
892
|
-
const
|
|
891
|
+
var Qt = Q;
|
|
892
|
+
const Wt = O, _e = [
|
|
893
893
|
"0",
|
|
894
894
|
"1",
|
|
895
895
|
"2",
|
|
@@ -936,126 +936,126 @@ const Qt = Y, Ce = [
|
|
|
936
936
|
"/",
|
|
937
937
|
":"
|
|
938
938
|
];
|
|
939
|
-
function
|
|
940
|
-
this.mode =
|
|
939
|
+
function W(t) {
|
|
940
|
+
this.mode = Wt.ALPHANUMERIC, this.data = t;
|
|
941
941
|
}
|
|
942
|
-
|
|
942
|
+
W.getBitsLength = function(e) {
|
|
943
943
|
return 11 * Math.floor(e / 2) + 6 * (e % 2);
|
|
944
944
|
};
|
|
945
|
-
|
|
945
|
+
W.prototype.getLength = function() {
|
|
946
946
|
return this.data.length;
|
|
947
947
|
};
|
|
948
|
-
|
|
949
|
-
return
|
|
948
|
+
W.prototype.getBitsLength = function() {
|
|
949
|
+
return W.getBitsLength(this.data.length);
|
|
950
950
|
};
|
|
951
|
-
|
|
952
|
-
let
|
|
953
|
-
for (
|
|
954
|
-
let r =
|
|
955
|
-
r +=
|
|
951
|
+
W.prototype.write = function(e) {
|
|
952
|
+
let s;
|
|
953
|
+
for (s = 0; s + 2 <= this.data.length; s += 2) {
|
|
954
|
+
let r = _e.indexOf(this.data[s]) * 45;
|
|
955
|
+
r += _e.indexOf(this.data[s + 1]), e.put(r, 11);
|
|
956
956
|
}
|
|
957
|
-
this.data.length % 2 && e.put(
|
|
957
|
+
this.data.length % 2 && e.put(_e.indexOf(this.data[s]), 6);
|
|
958
958
|
};
|
|
959
|
-
var Xt =
|
|
960
|
-
for (var
|
|
959
|
+
var Xt = W, Zt = function(e) {
|
|
960
|
+
for (var s = [], r = e.length, o = 0; o < r; o++) {
|
|
961
961
|
var n = e.charCodeAt(o);
|
|
962
962
|
if (n >= 55296 && n <= 56319 && r > o + 1) {
|
|
963
963
|
var a = e.charCodeAt(o + 1);
|
|
964
964
|
a >= 56320 && a <= 57343 && (n = (n - 55296) * 1024 + a - 56320 + 65536, o += 1);
|
|
965
965
|
}
|
|
966
966
|
if (n < 128) {
|
|
967
|
-
|
|
967
|
+
s.push(n);
|
|
968
968
|
continue;
|
|
969
969
|
}
|
|
970
970
|
if (n < 2048) {
|
|
971
|
-
|
|
971
|
+
s.push(n >> 6 | 192), s.push(n & 63 | 128);
|
|
972
972
|
continue;
|
|
973
973
|
}
|
|
974
974
|
if (n < 55296 || n >= 57344 && n < 65536) {
|
|
975
|
-
|
|
975
|
+
s.push(n >> 12 | 224), s.push(n >> 6 & 63 | 128), s.push(n & 63 | 128);
|
|
976
976
|
continue;
|
|
977
977
|
}
|
|
978
978
|
if (n >= 65536 && n <= 1114111) {
|
|
979
|
-
|
|
979
|
+
s.push(n >> 18 | 240), s.push(n >> 12 & 63 | 128), s.push(n >> 6 & 63 | 128), s.push(n & 63 | 128);
|
|
980
980
|
continue;
|
|
981
981
|
}
|
|
982
|
-
|
|
982
|
+
s.push(239, 191, 189);
|
|
983
983
|
}
|
|
984
|
-
return new Uint8Array(
|
|
984
|
+
return new Uint8Array(s).buffer;
|
|
985
985
|
};
|
|
986
|
-
const
|
|
987
|
-
function
|
|
988
|
-
this.mode =
|
|
986
|
+
const en = Zt, tn = O;
|
|
987
|
+
function X(t) {
|
|
988
|
+
this.mode = tn.BYTE, typeof t == "string" && (t = en(t)), this.data = new Uint8Array(t);
|
|
989
989
|
}
|
|
990
|
-
|
|
990
|
+
X.getBitsLength = function(e) {
|
|
991
991
|
return e * 8;
|
|
992
992
|
};
|
|
993
|
-
|
|
993
|
+
X.prototype.getLength = function() {
|
|
994
994
|
return this.data.length;
|
|
995
995
|
};
|
|
996
|
-
|
|
997
|
-
return
|
|
996
|
+
X.prototype.getBitsLength = function() {
|
|
997
|
+
return X.getBitsLength(this.data.length);
|
|
998
998
|
};
|
|
999
|
-
|
|
1000
|
-
for (let e = 0,
|
|
999
|
+
X.prototype.write = function(t) {
|
|
1000
|
+
for (let e = 0, s = this.data.length; e < s; e++)
|
|
1001
1001
|
t.put(this.data[e], 8);
|
|
1002
1002
|
};
|
|
1003
|
-
var
|
|
1004
|
-
const
|
|
1005
|
-
function
|
|
1006
|
-
this.mode =
|
|
1003
|
+
var nn = X;
|
|
1004
|
+
const on = O, rn = U;
|
|
1005
|
+
function Z(t) {
|
|
1006
|
+
this.mode = on.KANJI, this.data = t;
|
|
1007
1007
|
}
|
|
1008
|
-
|
|
1008
|
+
Z.getBitsLength = function(e) {
|
|
1009
1009
|
return e * 13;
|
|
1010
1010
|
};
|
|
1011
|
-
|
|
1011
|
+
Z.prototype.getLength = function() {
|
|
1012
1012
|
return this.data.length;
|
|
1013
1013
|
};
|
|
1014
|
-
|
|
1015
|
-
return
|
|
1014
|
+
Z.prototype.getBitsLength = function() {
|
|
1015
|
+
return Z.getBitsLength(this.data.length);
|
|
1016
1016
|
};
|
|
1017
|
-
|
|
1017
|
+
Z.prototype.write = function(t) {
|
|
1018
1018
|
let e;
|
|
1019
1019
|
for (e = 0; e < this.data.length; e++) {
|
|
1020
|
-
let
|
|
1021
|
-
if (
|
|
1022
|
-
|
|
1023
|
-
else if (
|
|
1024
|
-
|
|
1020
|
+
let s = rn.toSJIS(this.data[e]);
|
|
1021
|
+
if (s >= 33088 && s <= 40956)
|
|
1022
|
+
s -= 33088;
|
|
1023
|
+
else if (s >= 57408 && s <= 60351)
|
|
1024
|
+
s -= 49472;
|
|
1025
1025
|
else
|
|
1026
1026
|
throw new Error(
|
|
1027
1027
|
"Invalid SJIS character: " + this.data[e] + `
|
|
1028
1028
|
Make sure your charset is UTF-8`
|
|
1029
1029
|
);
|
|
1030
|
-
|
|
1030
|
+
s = (s >>> 8 & 255) * 192 + (s & 255), t.put(s, 13);
|
|
1031
1031
|
}
|
|
1032
1032
|
};
|
|
1033
|
-
var
|
|
1033
|
+
var sn = Z, yt = { exports: {} };
|
|
1034
1034
|
(function(t) {
|
|
1035
1035
|
var e = {
|
|
1036
|
-
single_source_shortest_paths: function(
|
|
1036
|
+
single_source_shortest_paths: function(s, r, o) {
|
|
1037
1037
|
var n = {}, a = {};
|
|
1038
1038
|
a[r] = 0;
|
|
1039
1039
|
var l = e.PriorityQueue.make();
|
|
1040
1040
|
l.push(r, 0);
|
|
1041
|
-
for (var
|
|
1042
|
-
|
|
1041
|
+
for (var i, u, f, A, m, d, v, C, I; !l.empty(); ) {
|
|
1042
|
+
i = l.pop(), u = i.value, A = i.cost, m = s[u] || {};
|
|
1043
1043
|
for (f in m)
|
|
1044
|
-
m.hasOwnProperty(f) && (d = m[f], v = A + d, C = a[f],
|
|
1044
|
+
m.hasOwnProperty(f) && (d = m[f], v = A + d, C = a[f], I = typeof a[f] > "u", (I || C > v) && (a[f] = v, l.push(f, v), n[f] = u));
|
|
1045
1045
|
}
|
|
1046
1046
|
if (typeof o < "u" && typeof a[o] > "u") {
|
|
1047
|
-
var
|
|
1048
|
-
throw new Error(
|
|
1047
|
+
var p = ["Could not find a path from ", r, " to ", o, "."].join("");
|
|
1048
|
+
throw new Error(p);
|
|
1049
1049
|
}
|
|
1050
1050
|
return n;
|
|
1051
1051
|
},
|
|
1052
|
-
extract_shortest_path_from_predecessor_list: function(
|
|
1052
|
+
extract_shortest_path_from_predecessor_list: function(s, r) {
|
|
1053
1053
|
for (var o = [], n = r; n; )
|
|
1054
|
-
o.push(n),
|
|
1054
|
+
o.push(n), s[n], n = s[n];
|
|
1055
1055
|
return o.reverse(), o;
|
|
1056
1056
|
},
|
|
1057
|
-
find_path: function(
|
|
1058
|
-
var n = e.single_source_shortest_paths(
|
|
1057
|
+
find_path: function(s, r, o) {
|
|
1058
|
+
var n = e.single_source_shortest_paths(s, r, o);
|
|
1059
1059
|
return e.extract_shortest_path_from_predecessor_list(
|
|
1060
1060
|
n,
|
|
1061
1061
|
o
|
|
@@ -1065,22 +1065,22 @@ var rn = W, pt = { exports: {} };
|
|
|
1065
1065
|
* A very naive priority queue implementation.
|
|
1066
1066
|
*/
|
|
1067
1067
|
PriorityQueue: {
|
|
1068
|
-
make: function(
|
|
1068
|
+
make: function(s) {
|
|
1069
1069
|
var r = e.PriorityQueue, o = {}, n;
|
|
1070
|
-
|
|
1070
|
+
s = s || {};
|
|
1071
1071
|
for (n in r)
|
|
1072
1072
|
r.hasOwnProperty(n) && (o[n] = r[n]);
|
|
1073
|
-
return o.queue = [], o.sorter =
|
|
1073
|
+
return o.queue = [], o.sorter = s.sorter || r.default_sorter, o;
|
|
1074
1074
|
},
|
|
1075
|
-
default_sorter: function(
|
|
1076
|
-
return
|
|
1075
|
+
default_sorter: function(s, r) {
|
|
1076
|
+
return s.cost - r.cost;
|
|
1077
1077
|
},
|
|
1078
1078
|
/**
|
|
1079
1079
|
* Add a new item to the queue and ensure the highest priority element
|
|
1080
1080
|
* is at the front of the queue.
|
|
1081
1081
|
*/
|
|
1082
|
-
push: function(
|
|
1083
|
-
var o = { value:
|
|
1082
|
+
push: function(s, r) {
|
|
1083
|
+
var o = { value: s, cost: r };
|
|
1084
1084
|
this.queue.push(o), this.queue.sort(this.sorter);
|
|
1085
1085
|
},
|
|
1086
1086
|
/**
|
|
@@ -1095,30 +1095,30 @@ var rn = W, pt = { exports: {} };
|
|
|
1095
1095
|
}
|
|
1096
1096
|
};
|
|
1097
1097
|
t.exports = e;
|
|
1098
|
-
})(
|
|
1099
|
-
var
|
|
1098
|
+
})(yt);
|
|
1099
|
+
var an = yt.exports;
|
|
1100
1100
|
(function(t) {
|
|
1101
|
-
const e =
|
|
1102
|
-
function u(
|
|
1103
|
-
return unescape(encodeURIComponent(
|
|
1101
|
+
const e = O, s = Qt, r = Xt, o = nn, n = sn, a = $, l = U, i = an;
|
|
1102
|
+
function u(p) {
|
|
1103
|
+
return unescape(encodeURIComponent(p)).length;
|
|
1104
1104
|
}
|
|
1105
|
-
function f(
|
|
1106
|
-
const
|
|
1105
|
+
function f(p, b, g) {
|
|
1106
|
+
const w = [];
|
|
1107
1107
|
let B;
|
|
1108
|
-
for (; (B =
|
|
1109
|
-
|
|
1108
|
+
for (; (B = p.exec(g)) !== null; )
|
|
1109
|
+
w.push({
|
|
1110
1110
|
data: B[0],
|
|
1111
1111
|
index: B.index,
|
|
1112
1112
|
mode: b,
|
|
1113
1113
|
length: B[0].length
|
|
1114
1114
|
});
|
|
1115
|
-
return
|
|
1115
|
+
return w;
|
|
1116
1116
|
}
|
|
1117
|
-
function A(
|
|
1118
|
-
const b = f(a.NUMERIC, e.NUMERIC,
|
|
1119
|
-
let
|
|
1120
|
-
return l.isKanjiModeEnabled() ? (
|
|
1121
|
-
return P.index -
|
|
1117
|
+
function A(p) {
|
|
1118
|
+
const b = f(a.NUMERIC, e.NUMERIC, p), g = f(a.ALPHANUMERIC, e.ALPHANUMERIC, p);
|
|
1119
|
+
let w, B;
|
|
1120
|
+
return l.isKanjiModeEnabled() ? (w = f(a.BYTE, e.BYTE, p), B = f(a.KANJI, e.KANJI, p)) : (w = f(a.BYTE_KANJI, e.BYTE, p), B = []), b.concat(g, w, B).sort(function(P, N) {
|
|
1121
|
+
return P.index - N.index;
|
|
1122
1122
|
}).map(function(P) {
|
|
1123
1123
|
return {
|
|
1124
1124
|
data: P.data,
|
|
@@ -1127,210 +1127,210 @@ var sn = pt.exports;
|
|
|
1127
1127
|
};
|
|
1128
1128
|
});
|
|
1129
1129
|
}
|
|
1130
|
-
function m(
|
|
1130
|
+
function m(p, b) {
|
|
1131
1131
|
switch (b) {
|
|
1132
1132
|
case e.NUMERIC:
|
|
1133
|
-
return
|
|
1133
|
+
return s.getBitsLength(p);
|
|
1134
1134
|
case e.ALPHANUMERIC:
|
|
1135
|
-
return r.getBitsLength(
|
|
1135
|
+
return r.getBitsLength(p);
|
|
1136
1136
|
case e.KANJI:
|
|
1137
|
-
return n.getBitsLength(
|
|
1137
|
+
return n.getBitsLength(p);
|
|
1138
1138
|
case e.BYTE:
|
|
1139
|
-
return o.getBitsLength(
|
|
1139
|
+
return o.getBitsLength(p);
|
|
1140
1140
|
}
|
|
1141
1141
|
}
|
|
1142
|
-
function d(
|
|
1143
|
-
return
|
|
1144
|
-
const
|
|
1145
|
-
return
|
|
1142
|
+
function d(p) {
|
|
1143
|
+
return p.reduce(function(b, g) {
|
|
1144
|
+
const w = b.length - 1 >= 0 ? b[b.length - 1] : null;
|
|
1145
|
+
return w && w.mode === g.mode ? (b[b.length - 1].data += g.data, b) : (b.push(g), b);
|
|
1146
1146
|
}, []);
|
|
1147
1147
|
}
|
|
1148
|
-
function v(
|
|
1148
|
+
function v(p) {
|
|
1149
1149
|
const b = [];
|
|
1150
|
-
for (let g = 0; g <
|
|
1151
|
-
const
|
|
1152
|
-
switch (
|
|
1150
|
+
for (let g = 0; g < p.length; g++) {
|
|
1151
|
+
const w = p[g];
|
|
1152
|
+
switch (w.mode) {
|
|
1153
1153
|
case e.NUMERIC:
|
|
1154
1154
|
b.push([
|
|
1155
|
-
|
|
1156
|
-
{ data:
|
|
1157
|
-
{ data:
|
|
1155
|
+
w,
|
|
1156
|
+
{ data: w.data, mode: e.ALPHANUMERIC, length: w.length },
|
|
1157
|
+
{ data: w.data, mode: e.BYTE, length: w.length }
|
|
1158
1158
|
]);
|
|
1159
1159
|
break;
|
|
1160
1160
|
case e.ALPHANUMERIC:
|
|
1161
1161
|
b.push([
|
|
1162
|
-
|
|
1163
|
-
{ data:
|
|
1162
|
+
w,
|
|
1163
|
+
{ data: w.data, mode: e.BYTE, length: w.length }
|
|
1164
1164
|
]);
|
|
1165
1165
|
break;
|
|
1166
1166
|
case e.KANJI:
|
|
1167
1167
|
b.push([
|
|
1168
|
-
|
|
1169
|
-
{ data:
|
|
1168
|
+
w,
|
|
1169
|
+
{ data: w.data, mode: e.BYTE, length: u(w.data) }
|
|
1170
1170
|
]);
|
|
1171
1171
|
break;
|
|
1172
1172
|
case e.BYTE:
|
|
1173
1173
|
b.push([
|
|
1174
|
-
{ data:
|
|
1174
|
+
{ data: w.data, mode: e.BYTE, length: u(w.data) }
|
|
1175
1175
|
]);
|
|
1176
1176
|
}
|
|
1177
1177
|
}
|
|
1178
1178
|
return b;
|
|
1179
1179
|
}
|
|
1180
|
-
function C(
|
|
1181
|
-
const g = {},
|
|
1180
|
+
function C(p, b) {
|
|
1181
|
+
const g = {}, w = { start: {} };
|
|
1182
1182
|
let B = ["start"];
|
|
1183
|
-
for (let
|
|
1184
|
-
const P =
|
|
1185
|
-
for (let
|
|
1186
|
-
const
|
|
1187
|
-
|
|
1188
|
-
for (let
|
|
1189
|
-
const
|
|
1190
|
-
g[
|
|
1183
|
+
for (let M = 0; M < p.length; M++) {
|
|
1184
|
+
const P = p[M], N = [];
|
|
1185
|
+
for (let D = 0; D < P.length; D++) {
|
|
1186
|
+
const L = P[D], Y = "" + M + D;
|
|
1187
|
+
N.push(Y), g[Y] = { node: L, lastCount: 0 }, w[Y] = {};
|
|
1188
|
+
for (let E = 0; E < B.length; E++) {
|
|
1189
|
+
const h = B[E];
|
|
1190
|
+
g[h] && g[h].node.mode === L.mode ? (w[h][Y] = m(g[h].lastCount + L.length, L.mode) - m(g[h].lastCount, L.mode), g[h].lastCount += L.length) : (g[h] && (g[h].lastCount = L.length), w[h][Y] = m(L.length, L.mode) + 4 + e.getCharCountIndicator(L.mode, b));
|
|
1191
1191
|
}
|
|
1192
1192
|
}
|
|
1193
|
-
B =
|
|
1193
|
+
B = N;
|
|
1194
1194
|
}
|
|
1195
|
-
for (let
|
|
1196
|
-
|
|
1197
|
-
return { map:
|
|
1195
|
+
for (let M = 0; M < B.length; M++)
|
|
1196
|
+
w[B[M]].end = 0;
|
|
1197
|
+
return { map: w, table: g };
|
|
1198
1198
|
}
|
|
1199
|
-
function
|
|
1199
|
+
function I(p, b) {
|
|
1200
1200
|
let g;
|
|
1201
|
-
const
|
|
1202
|
-
if (g = e.from(b,
|
|
1203
|
-
throw new Error('"' +
|
|
1204
|
-
Suggested mode is: ` + e.toString(
|
|
1201
|
+
const w = e.getBestModeForData(p);
|
|
1202
|
+
if (g = e.from(b, w), g !== e.BYTE && g.bit < w.bit)
|
|
1203
|
+
throw new Error('"' + p + '" cannot be encoded with mode ' + e.toString(g) + `.
|
|
1204
|
+
Suggested mode is: ` + e.toString(w));
|
|
1205
1205
|
switch (g === e.KANJI && !l.isKanjiModeEnabled() && (g = e.BYTE), g) {
|
|
1206
1206
|
case e.NUMERIC:
|
|
1207
|
-
return new
|
|
1207
|
+
return new s(p);
|
|
1208
1208
|
case e.ALPHANUMERIC:
|
|
1209
|
-
return new r(
|
|
1209
|
+
return new r(p);
|
|
1210
1210
|
case e.KANJI:
|
|
1211
|
-
return new n(
|
|
1211
|
+
return new n(p);
|
|
1212
1212
|
case e.BYTE:
|
|
1213
|
-
return new o(
|
|
1213
|
+
return new o(p);
|
|
1214
1214
|
}
|
|
1215
1215
|
}
|
|
1216
1216
|
t.fromArray = function(b) {
|
|
1217
|
-
return b.reduce(function(g,
|
|
1218
|
-
return typeof
|
|
1217
|
+
return b.reduce(function(g, w) {
|
|
1218
|
+
return typeof w == "string" ? g.push(I(w, null)) : w.data && g.push(I(w.data, w.mode)), g;
|
|
1219
1219
|
}, []);
|
|
1220
1220
|
}, t.fromString = function(b, g) {
|
|
1221
|
-
const
|
|
1222
|
-
for (let
|
|
1223
|
-
|
|
1224
|
-
return t.fromArray(d(
|
|
1221
|
+
const w = A(b, l.isKanjiModeEnabled()), B = v(w), M = C(B, g), P = i.find_path(M.map, "start", "end"), N = [];
|
|
1222
|
+
for (let D = 1; D < P.length - 1; D++)
|
|
1223
|
+
N.push(M.table[P[D]].node);
|
|
1224
|
+
return t.fromArray(d(N));
|
|
1225
1225
|
}, t.rawSplit = function(b) {
|
|
1226
1226
|
return t.fromArray(
|
|
1227
1227
|
A(b, l.isKanjiModeEnabled())
|
|
1228
1228
|
);
|
|
1229
1229
|
};
|
|
1230
|
-
})(
|
|
1231
|
-
const
|
|
1232
|
-
function
|
|
1233
|
-
const
|
|
1230
|
+
})(pt);
|
|
1231
|
+
const ve = U, Ee = ye, ln = xt, cn = $t, un = at, dn = lt, Te = ct, Ne = we, fn = Ht, pe = ft, mn = gt, gn = O, Ae = pt;
|
|
1232
|
+
function hn(t, e) {
|
|
1233
|
+
const s = t.size, r = dn.getPositions(e);
|
|
1234
1234
|
for (let o = 0; o < r.length; o++) {
|
|
1235
1235
|
const n = r[o][0], a = r[o][1];
|
|
1236
1236
|
for (let l = -1; l <= 7; l++)
|
|
1237
|
-
if (!(n + l <= -1 ||
|
|
1238
|
-
for (let
|
|
1239
|
-
a +
|
|
1237
|
+
if (!(n + l <= -1 || s <= n + l))
|
|
1238
|
+
for (let i = -1; i <= 7; i++)
|
|
1239
|
+
a + i <= -1 || s <= a + i || (l >= 0 && l <= 6 && (i === 0 || i === 6) || i >= 0 && i <= 6 && (l === 0 || l === 6) || l >= 2 && l <= 4 && i >= 2 && i <= 4 ? t.set(n + l, a + i, !0, !0) : t.set(n + l, a + i, !1, !0));
|
|
1240
1240
|
}
|
|
1241
1241
|
}
|
|
1242
|
-
function
|
|
1242
|
+
function pn(t) {
|
|
1243
1243
|
const e = t.size;
|
|
1244
|
-
for (let
|
|
1245
|
-
const r =
|
|
1246
|
-
t.set(
|
|
1244
|
+
for (let s = 8; s < e - 8; s++) {
|
|
1245
|
+
const r = s % 2 === 0;
|
|
1246
|
+
t.set(s, 6, r, !0), t.set(6, s, r, !0);
|
|
1247
1247
|
}
|
|
1248
1248
|
}
|
|
1249
|
-
function
|
|
1250
|
-
const
|
|
1251
|
-
for (let r = 0; r <
|
|
1252
|
-
const o =
|
|
1249
|
+
function yn(t, e) {
|
|
1250
|
+
const s = un.getPositions(e);
|
|
1251
|
+
for (let r = 0; r < s.length; r++) {
|
|
1252
|
+
const o = s[r][0], n = s[r][1];
|
|
1253
1253
|
for (let a = -2; a <= 2; a++)
|
|
1254
1254
|
for (let l = -2; l <= 2; l++)
|
|
1255
1255
|
a === -2 || a === 2 || l === -2 || l === 2 || a === 0 && l === 0 ? t.set(o + a, n + l, !0, !0) : t.set(o + a, n + l, !1, !0);
|
|
1256
1256
|
}
|
|
1257
1257
|
}
|
|
1258
|
-
function
|
|
1259
|
-
const
|
|
1258
|
+
function wn(t, e) {
|
|
1259
|
+
const s = t.size, r = pe.getEncodedBits(e);
|
|
1260
1260
|
let o, n, a;
|
|
1261
1261
|
for (let l = 0; l < 18; l++)
|
|
1262
|
-
o = Math.floor(l / 3), n = l % 3 +
|
|
1262
|
+
o = Math.floor(l / 3), n = l % 3 + s - 8 - 3, a = (r >> l & 1) === 1, t.set(o, n, a, !0), t.set(n, o, a, !0);
|
|
1263
1263
|
}
|
|
1264
|
-
function
|
|
1265
|
-
const r = t.size, o =
|
|
1264
|
+
function Be(t, e, s) {
|
|
1265
|
+
const r = t.size, o = mn.getEncodedBits(e, s);
|
|
1266
1266
|
let n, a;
|
|
1267
1267
|
for (n = 0; n < 15; n++)
|
|
1268
1268
|
a = (o >> n & 1) === 1, n < 6 ? t.set(n, 8, a, !0) : n < 8 ? t.set(n + 1, 8, a, !0) : t.set(r - 15 + n, 8, a, !0), n < 8 ? t.set(8, r - n - 1, a, !0) : n < 9 ? t.set(8, 15 - n - 1 + 1, a, !0) : t.set(8, 15 - n - 1, a, !0);
|
|
1269
1269
|
t.set(r - 8, 8, 1, !0);
|
|
1270
1270
|
}
|
|
1271
|
-
function
|
|
1272
|
-
const
|
|
1273
|
-
let r = -1, o =
|
|
1274
|
-
for (let l =
|
|
1271
|
+
function bn(t, e) {
|
|
1272
|
+
const s = t.size;
|
|
1273
|
+
let r = -1, o = s - 1, n = 7, a = 0;
|
|
1274
|
+
for (let l = s - 1; l > 0; l -= 2)
|
|
1275
1275
|
for (l === 6 && l--; ; ) {
|
|
1276
|
-
for (let
|
|
1277
|
-
if (!t.isReserved(o, l -
|
|
1276
|
+
for (let i = 0; i < 2; i++)
|
|
1277
|
+
if (!t.isReserved(o, l - i)) {
|
|
1278
1278
|
let u = !1;
|
|
1279
|
-
a < e.length && (u = (e[a] >>> n & 1) === 1), t.set(o, l -
|
|
1279
|
+
a < e.length && (u = (e[a] >>> n & 1) === 1), t.set(o, l - i, u), n--, n === -1 && (a++, n = 7);
|
|
1280
1280
|
}
|
|
1281
|
-
if (o += r, o < 0 ||
|
|
1281
|
+
if (o += r, o < 0 || s <= o) {
|
|
1282
1282
|
o -= r, r = -r;
|
|
1283
1283
|
break;
|
|
1284
1284
|
}
|
|
1285
1285
|
}
|
|
1286
1286
|
}
|
|
1287
|
-
function
|
|
1288
|
-
const r = new
|
|
1289
|
-
|
|
1290
|
-
r.put(
|
|
1287
|
+
function vn(t, e, s) {
|
|
1288
|
+
const r = new ln();
|
|
1289
|
+
s.forEach(function(i) {
|
|
1290
|
+
r.put(i.mode.bit, 4), r.put(i.getLength(), gn.getCharCountIndicator(i.mode, t)), i.write(r);
|
|
1291
1291
|
});
|
|
1292
|
-
const o =
|
|
1292
|
+
const o = ve.getSymbolTotalCodewords(t), n = Ne.getTotalCodewordsCount(t, e), a = (o - n) * 8;
|
|
1293
1293
|
for (r.getLengthInBits() + 4 <= a && r.put(0, 4); r.getLengthInBits() % 8 !== 0; )
|
|
1294
1294
|
r.putBit(0);
|
|
1295
1295
|
const l = (a - r.getLengthInBits()) / 8;
|
|
1296
|
-
for (let
|
|
1297
|
-
r.put(
|
|
1298
|
-
return
|
|
1296
|
+
for (let i = 0; i < l; i++)
|
|
1297
|
+
r.put(i % 2 ? 17 : 236, 8);
|
|
1298
|
+
return Cn(r, t, e);
|
|
1299
1299
|
}
|
|
1300
|
-
function
|
|
1301
|
-
const r =
|
|
1300
|
+
function Cn(t, e, s) {
|
|
1301
|
+
const r = ve.getSymbolTotalCodewords(e), o = Ne.getTotalCodewordsCount(e, s), n = r - o, a = Ne.getBlocksCount(e, s), l = r % a, i = a - l, u = Math.floor(r / a), f = Math.floor(n / a), A = f + 1, m = u - f, d = new fn(m);
|
|
1302
1302
|
let v = 0;
|
|
1303
|
-
const C = new Array(a),
|
|
1304
|
-
let
|
|
1303
|
+
const C = new Array(a), I = new Array(a);
|
|
1304
|
+
let p = 0;
|
|
1305
1305
|
const b = new Uint8Array(t.buffer);
|
|
1306
1306
|
for (let P = 0; P < a; P++) {
|
|
1307
|
-
const
|
|
1308
|
-
C[P] = b.slice(v, v +
|
|
1307
|
+
const N = P < i ? f : A;
|
|
1308
|
+
C[P] = b.slice(v, v + N), I[P] = d.encode(C[P]), v += N, p = Math.max(p, N);
|
|
1309
1309
|
}
|
|
1310
1310
|
const g = new Uint8Array(r);
|
|
1311
|
-
let
|
|
1312
|
-
for (B = 0; B <
|
|
1313
|
-
for (
|
|
1314
|
-
B < C[
|
|
1311
|
+
let w = 0, B, M;
|
|
1312
|
+
for (B = 0; B < p; B++)
|
|
1313
|
+
for (M = 0; M < a; M++)
|
|
1314
|
+
B < C[M].length && (g[w++] = C[M][B]);
|
|
1315
1315
|
for (B = 0; B < m; B++)
|
|
1316
|
-
for (
|
|
1317
|
-
g[
|
|
1316
|
+
for (M = 0; M < a; M++)
|
|
1317
|
+
g[w++] = I[M][B];
|
|
1318
1318
|
return g;
|
|
1319
1319
|
}
|
|
1320
|
-
function
|
|
1320
|
+
function _n(t, e, s, r) {
|
|
1321
1321
|
let o;
|
|
1322
1322
|
if (Array.isArray(t))
|
|
1323
|
-
o =
|
|
1323
|
+
o = Ae.fromArray(t);
|
|
1324
1324
|
else if (typeof t == "string") {
|
|
1325
1325
|
let u = e;
|
|
1326
1326
|
if (!u) {
|
|
1327
|
-
const f =
|
|
1328
|
-
u =
|
|
1327
|
+
const f = Ae.rawSplit(t);
|
|
1328
|
+
u = pe.getBestVersionForData(f, s);
|
|
1329
1329
|
}
|
|
1330
|
-
o =
|
|
1330
|
+
o = Ae.fromString(t, u || 40);
|
|
1331
1331
|
} else
|
|
1332
1332
|
throw new Error("Invalid data");
|
|
1333
|
-
const n =
|
|
1333
|
+
const n = pe.getBestVersionForData(o, s);
|
|
1334
1334
|
if (!n)
|
|
1335
1335
|
throw new Error("The amount of data is too big to be stored in a QR Code");
|
|
1336
1336
|
if (!e)
|
|
@@ -1342,32 +1342,32 @@ The chosen QR Code version cannot contain this amount of data.
|
|
|
1342
1342
|
Minimum version required to store current data is: ` + n + `.
|
|
1343
1343
|
`
|
|
1344
1344
|
);
|
|
1345
|
-
const a =
|
|
1346
|
-
return
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
)),
|
|
1350
|
-
modules:
|
|
1345
|
+
const a = vn(e, s, o), l = ve.getSymbolSize(e), i = new cn(l);
|
|
1346
|
+
return hn(i, e), pn(i), yn(i, e), Be(i, s, 0), e >= 7 && wn(i, e), bn(i, a), isNaN(r) && (r = Te.getBestMask(
|
|
1347
|
+
i,
|
|
1348
|
+
Be.bind(null, i, s)
|
|
1349
|
+
)), Te.applyMask(r, i), Be(i, s, r), {
|
|
1350
|
+
modules: i,
|
|
1351
1351
|
version: e,
|
|
1352
|
-
errorCorrectionLevel:
|
|
1352
|
+
errorCorrectionLevel: s,
|
|
1353
1353
|
maskPattern: r,
|
|
1354
1354
|
segments: o
|
|
1355
1355
|
};
|
|
1356
1356
|
}
|
|
1357
|
-
|
|
1357
|
+
st.create = function(e, s) {
|
|
1358
1358
|
if (typeof e > "u" || e === "")
|
|
1359
1359
|
throw new Error("No input text");
|
|
1360
|
-
let r =
|
|
1361
|
-
return typeof
|
|
1360
|
+
let r = Ee.M, o, n;
|
|
1361
|
+
return typeof s < "u" && (r = Ee.from(s.errorCorrectionLevel, Ee.M), o = pe.from(s.version), n = Te.from(s.maskPattern), s.toSJISFunc && ve.setToSJISFunction(s.toSJISFunc)), _n(e, o, r, n);
|
|
1362
1362
|
};
|
|
1363
|
-
var
|
|
1363
|
+
var wt = {}, ke = {};
|
|
1364
1364
|
(function(t) {
|
|
1365
|
-
function e(
|
|
1366
|
-
if (typeof
|
|
1365
|
+
function e(s) {
|
|
1366
|
+
if (typeof s == "number" && (s = s.toString()), typeof s != "string")
|
|
1367
1367
|
throw new Error("Color should be defined as hex string");
|
|
1368
|
-
let r =
|
|
1368
|
+
let r = s.slice().replace("#", "").split("");
|
|
1369
1369
|
if (r.length < 3 || r.length === 5 || r.length > 8)
|
|
1370
|
-
throw new Error("Invalid hex color: " +
|
|
1370
|
+
throw new Error("Invalid hex color: " + s);
|
|
1371
1371
|
(r.length === 3 || r.length === 4) && (r = Array.prototype.concat.apply([], r.map(function(n) {
|
|
1372
1372
|
return [n, n];
|
|
1373
1373
|
}))), r.length === 6 && r.push("F", "F");
|
|
@@ -1400,21 +1400,21 @@ var yt = {}, Fe = {};
|
|
|
1400
1400
|
const n = t.getScale(r, o);
|
|
1401
1401
|
return Math.floor((r + o.margin * 2) * n);
|
|
1402
1402
|
}, t.qrToImageData = function(r, o, n) {
|
|
1403
|
-
const a = o.modules.size, l = o.modules.data,
|
|
1403
|
+
const a = o.modules.size, l = o.modules.data, i = t.getScale(a, n), u = Math.floor((a + n.margin * 2) * i), f = n.margin * i, A = [n.color.light, n.color.dark];
|
|
1404
1404
|
for (let m = 0; m < u; m++)
|
|
1405
1405
|
for (let d = 0; d < u; d++) {
|
|
1406
1406
|
let v = (m * u + d) * 4, C = n.color.light;
|
|
1407
1407
|
if (m >= f && d >= f && m < u - f && d < u - f) {
|
|
1408
|
-
const
|
|
1409
|
-
C = A[l[
|
|
1408
|
+
const I = Math.floor((m - f) / i), p = Math.floor((d - f) / i);
|
|
1409
|
+
C = A[l[I * a + p] ? 1 : 0];
|
|
1410
1410
|
}
|
|
1411
1411
|
r[v++] = C.r, r[v++] = C.g, r[v++] = C.b, r[v] = C.a;
|
|
1412
1412
|
}
|
|
1413
1413
|
};
|
|
1414
|
-
})(
|
|
1414
|
+
})(ke);
|
|
1415
1415
|
(function(t) {
|
|
1416
|
-
const e =
|
|
1417
|
-
function
|
|
1416
|
+
const e = ke;
|
|
1417
|
+
function s(o, n, a) {
|
|
1418
1418
|
o.clearRect(0, 0, n.width, n.height), n.style || (n.style = {}), n.height = a, n.width = a, n.style.height = a + "px", n.style.width = a + "px";
|
|
1419
1419
|
}
|
|
1420
1420
|
function r() {
|
|
@@ -1425,102 +1425,102 @@ var yt = {}, Fe = {};
|
|
|
1425
1425
|
}
|
|
1426
1426
|
}
|
|
1427
1427
|
t.render = function(n, a, l) {
|
|
1428
|
-
let
|
|
1429
|
-
typeof
|
|
1430
|
-
const f = e.getImageWidth(n.modules.size,
|
|
1431
|
-
return e.qrToImageData(m.data, n,
|
|
1428
|
+
let i = l, u = a;
|
|
1429
|
+
typeof i > "u" && (!a || !a.getContext) && (i = a, a = void 0), a || (u = r()), i = e.getOptions(i);
|
|
1430
|
+
const f = e.getImageWidth(n.modules.size, i), A = u.getContext("2d"), m = A.createImageData(f, f);
|
|
1431
|
+
return e.qrToImageData(m.data, n, i), s(A, u, f), A.putImageData(m, 0, 0), u;
|
|
1432
1432
|
}, t.renderToDataURL = function(n, a, l) {
|
|
1433
|
-
let
|
|
1434
|
-
typeof
|
|
1435
|
-
const u = t.render(n, a,
|
|
1433
|
+
let i = l;
|
|
1434
|
+
typeof i > "u" && (!a || !a.getContext) && (i = a, a = void 0), i || (i = {});
|
|
1435
|
+
const u = t.render(n, a, i), f = i.type || "image/png", A = i.rendererOpts || {};
|
|
1436
1436
|
return u.toDataURL(f, A.quality);
|
|
1437
1437
|
};
|
|
1438
|
-
})(
|
|
1439
|
-
var
|
|
1440
|
-
const
|
|
1441
|
-
function
|
|
1442
|
-
const
|
|
1443
|
-
return
|
|
1438
|
+
})(wt);
|
|
1439
|
+
var bt = {};
|
|
1440
|
+
const En = ke;
|
|
1441
|
+
function We(t, e) {
|
|
1442
|
+
const s = t.a / 255, r = e + '="' + t.hex + '"';
|
|
1443
|
+
return s < 1 ? r + " " + e + '-opacity="' + s.toFixed(2).slice(1) + '"' : r;
|
|
1444
1444
|
}
|
|
1445
|
-
function
|
|
1445
|
+
function Me(t, e, s) {
|
|
1446
1446
|
let r = t + e;
|
|
1447
|
-
return typeof
|
|
1447
|
+
return typeof s < "u" && (r += " " + s), r;
|
|
1448
1448
|
}
|
|
1449
|
-
function
|
|
1449
|
+
function An(t, e, s) {
|
|
1450
1450
|
let r = "", o = 0, n = !1, a = 0;
|
|
1451
1451
|
for (let l = 0; l < t.length; l++) {
|
|
1452
|
-
const
|
|
1453
|
-
!
|
|
1452
|
+
const i = Math.floor(l % e), u = Math.floor(l / e);
|
|
1453
|
+
!i && !n && (n = !0), t[l] ? (a++, l > 0 && i > 0 && t[l - 1] || (r += n ? Me("M", i + s, 0.5 + u + s) : Me("m", o, 0), o = 0, n = !1), i + 1 < e && t[l + 1] || (r += Me("h", a), a = 0)) : o++;
|
|
1454
1454
|
}
|
|
1455
1455
|
return r;
|
|
1456
1456
|
}
|
|
1457
|
-
|
|
1458
|
-
const o =
|
|
1457
|
+
bt.render = function(e, s, r) {
|
|
1458
|
+
const o = En.getOptions(s), n = e.modules.size, a = e.modules.data, l = n + o.margin * 2, i = o.color.light.a ? "<path " + We(o.color.light, "fill") + ' d="M0 0h' + l + "v" + l + 'H0z"/>' : "", u = "<path " + We(o.color.dark, "stroke") + ' d="' + An(a, n, o.margin) + '"/>', f = 'viewBox="0 0 ' + l + " " + l + '"', m = '<svg xmlns="http://www.w3.org/2000/svg" ' + (o.width ? 'width="' + o.width + '" height="' + o.width + '" ' : "") + f + ' shape-rendering="crispEdges">' + i + u + `</svg>
|
|
1459
1459
|
`;
|
|
1460
1460
|
return typeof r == "function" && r(null, m), m;
|
|
1461
1461
|
};
|
|
1462
|
-
const
|
|
1463
|
-
function
|
|
1462
|
+
const Bn = Dt, Ue = st, vt = wt, Mn = bt;
|
|
1463
|
+
function De(t, e, s, r, o) {
|
|
1464
1464
|
const n = [].slice.call(arguments, 1), a = n.length, l = typeof n[a - 1] == "function";
|
|
1465
|
-
if (!l && !
|
|
1465
|
+
if (!l && !Bn())
|
|
1466
1466
|
throw new Error("Callback required as last argument");
|
|
1467
1467
|
if (l) {
|
|
1468
1468
|
if (a < 2)
|
|
1469
1469
|
throw new Error("Too few arguments provided");
|
|
1470
|
-
a === 2 ? (o =
|
|
1470
|
+
a === 2 ? (o = s, s = e, e = r = void 0) : a === 3 && (e.getContext && typeof o > "u" ? (o = r, r = void 0) : (o = r, r = s, s = e, e = void 0));
|
|
1471
1471
|
} else {
|
|
1472
1472
|
if (a < 1)
|
|
1473
1473
|
throw new Error("Too few arguments provided");
|
|
1474
|
-
return a === 1 ? (
|
|
1474
|
+
return a === 1 ? (s = e, e = r = void 0) : a === 2 && !e.getContext && (r = s, s = e, e = void 0), new Promise(function(i, u) {
|
|
1475
1475
|
try {
|
|
1476
|
-
const f =
|
|
1477
|
-
|
|
1476
|
+
const f = Ue.create(s, r);
|
|
1477
|
+
i(t(f, e, r));
|
|
1478
1478
|
} catch (f) {
|
|
1479
1479
|
u(f);
|
|
1480
1480
|
}
|
|
1481
1481
|
});
|
|
1482
1482
|
}
|
|
1483
1483
|
try {
|
|
1484
|
-
const
|
|
1485
|
-
o(null, t(
|
|
1486
|
-
} catch (
|
|
1487
|
-
o(
|
|
1484
|
+
const i = Ue.create(s, r);
|
|
1485
|
+
o(null, t(i, e, r));
|
|
1486
|
+
} catch (i) {
|
|
1487
|
+
o(i);
|
|
1488
1488
|
}
|
|
1489
1489
|
}
|
|
1490
|
-
ie.create =
|
|
1491
|
-
ie.toCanvas =
|
|
1492
|
-
ie.toDataURL =
|
|
1493
|
-
ie.toString =
|
|
1494
|
-
return
|
|
1490
|
+
ie.create = Ue.create;
|
|
1491
|
+
ie.toCanvas = De.bind(null, vt.render);
|
|
1492
|
+
ie.toDataURL = De.bind(null, vt.renderToDataURL);
|
|
1493
|
+
ie.toString = De.bind(null, function(t, e, s) {
|
|
1494
|
+
return Mn.render(t, s);
|
|
1495
1495
|
});
|
|
1496
|
-
async function
|
|
1496
|
+
async function Sn(t, e = 350) {
|
|
1497
1497
|
try {
|
|
1498
1498
|
return await ie.toDataURL(t, {
|
|
1499
1499
|
width: e,
|
|
1500
1500
|
margin: 0
|
|
1501
1501
|
});
|
|
1502
|
-
} catch (
|
|
1503
|
-
console.error(
|
|
1502
|
+
} catch (s) {
|
|
1503
|
+
console.error(s);
|
|
1504
1504
|
}
|
|
1505
1505
|
}
|
|
1506
|
-
var
|
|
1507
|
-
const
|
|
1508
|
-
/* @__PURE__ */
|
|
1509
|
-
/* @__PURE__ */
|
|
1510
|
-
], -1),
|
|
1506
|
+
var In = { authUrl: "https://portal-v2.feedmeapi.com/", slackWebhookUrl: "https://hooks.slack.com/services/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", appUrl: "member.feedme.cc", crmUrl: "crm.feedme.cc", paymentPortalUrl: "https://portal.feedme.cc/payment/payout-account", licensePortalUrl: "https://license.feedme.cc/", marketingV1Portal: "https://marketing-v1.feedme.cc" };
|
|
1507
|
+
const Pn = { class: "flex items-start" }, Tn = /* @__PURE__ */ y("div", null, [
|
|
1508
|
+
/* @__PURE__ */ y("div", { class: "fm-typo-en-title-sm-800" }, "Link device"),
|
|
1509
|
+
/* @__PURE__ */ y("div", { class: "fm-typo-en-body-sm-400" }, " Open your camera on your device to link counter app. ")
|
|
1510
|
+
], -1), Nn = { class: "flex flex-col gap-16 mt-16" }, Un = ["src"], Ln = /* @__PURE__ */ Xe({
|
|
1511
1511
|
__name: "LinkDeviceDialog",
|
|
1512
1512
|
setup(t) {
|
|
1513
|
-
const e =
|
|
1513
|
+
const e = Ie(), s = ot(), r = tt(), o = z(), n = z(), a = In.crmUrl, l = z(), i = ge(() => s.membership), u = ge(() => {
|
|
1514
1514
|
var m, d;
|
|
1515
|
-
return `https://${(m =
|
|
1515
|
+
return `https://${(m = i.value) != null && m.url ? i.value.url : (d = i.value) == null ? void 0 : d.business}.${a}`;
|
|
1516
1516
|
});
|
|
1517
1517
|
async function f(m) {
|
|
1518
|
-
const d = await
|
|
1518
|
+
const d = await nt.getOtp(m);
|
|
1519
1519
|
return `${u.value}?link-device=${d.otp}`;
|
|
1520
1520
|
}
|
|
1521
1521
|
async function A(m) {
|
|
1522
1522
|
const d = await f(m);
|
|
1523
|
-
l.value = d, o.value = await
|
|
1523
|
+
l.value = d, o.value = await Sn(d);
|
|
1524
1524
|
}
|
|
1525
1525
|
return Ze(async () => {
|
|
1526
1526
|
if (await e.readLocations(), !e.locations.length) {
|
|
@@ -1530,36 +1530,36 @@ const In = { class: "flex items-start" }, Pn = /* @__PURE__ */ w("div", null, [
|
|
|
1530
1530
|
const m = e.locations[0]._id;
|
|
1531
1531
|
n.value = m, await A(m);
|
|
1532
1532
|
}), (m, d) => {
|
|
1533
|
-
const v =
|
|
1534
|
-
return x(),
|
|
1535
|
-
default:
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1533
|
+
const v = F("FmIcon"), C = F("FmSelect"), I = F("FmButton"), p = F("FmCard");
|
|
1534
|
+
return x(), me(p, { class: "p-24 max-w-[350px]" }, {
|
|
1535
|
+
default: ne(() => [
|
|
1536
|
+
y("div", Pn, [
|
|
1537
|
+
Tn,
|
|
1538
|
+
S(v, {
|
|
1539
1539
|
name: "close",
|
|
1540
1540
|
onClick: d[0] || (d[0] = (b) => c(r).close()),
|
|
1541
1541
|
class: "cursor-pointer"
|
|
1542
1542
|
})
|
|
1543
1543
|
]),
|
|
1544
|
-
|
|
1545
|
-
|
|
1544
|
+
y("div", Nn, [
|
|
1545
|
+
S(C, {
|
|
1546
1546
|
modelValue: c(n),
|
|
1547
1547
|
"onUpdate:modelValue": [
|
|
1548
|
-
d[1] || (d[1] = (b) =>
|
|
1548
|
+
d[1] || (d[1] = (b) => et(n) ? n.value = b : null),
|
|
1549
1549
|
A
|
|
1550
1550
|
],
|
|
1551
1551
|
label: "Select Location",
|
|
1552
1552
|
items: c(e).locationItems.filter((b) => !!b.value)
|
|
1553
1553
|
}, null, 8, ["modelValue", "items"]),
|
|
1554
|
-
|
|
1554
|
+
y("img", {
|
|
1555
1555
|
src: c(o),
|
|
1556
1556
|
class: "aspect-square w-full"
|
|
1557
|
-
}, null, 8,
|
|
1558
|
-
I
|
|
1557
|
+
}, null, 8, Un),
|
|
1558
|
+
S(I, {
|
|
1559
1559
|
class: "mx-auto",
|
|
1560
1560
|
variant: "plain",
|
|
1561
1561
|
icon: "content_copy",
|
|
1562
|
-
onClick: d[2] || (d[2] = (b) => c(
|
|
1562
|
+
onClick: d[2] || (d[2] = (b) => c(rt)(c(l)))
|
|
1563
1563
|
})
|
|
1564
1564
|
])
|
|
1565
1565
|
]),
|
|
@@ -1568,26 +1568,26 @@ const In = { class: "flex items-start" }, Pn = /* @__PURE__ */ w("div", null, [
|
|
|
1568
1568
|
};
|
|
1569
1569
|
}
|
|
1570
1570
|
});
|
|
1571
|
-
var
|
|
1572
|
-
const
|
|
1571
|
+
var Se = { authUrl: "https://portal-v2.feedmeapi.com/", slackWebhookUrl: "https://hooks.slack.com/services/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", appUrl: "member.feedme.cc", crmUrl: "crm.feedme.cc", paymentPortalUrl: "https://portal.feedme.cc/payment/payout-account", licensePortalUrl: "https://license.feedme.cc/", marketingV1Portal: "https://marketing-v1.feedme.cc" };
|
|
1572
|
+
const Fn = { class: "hidden xs:flex items-center justify-between px-16 py-12 border-b border-fm-color-neutral-gray-100" }, Rn = { class: "fm-typo-en-title-md-800" }, kn = {
|
|
1573
1573
|
key: 0,
|
|
1574
1574
|
class: "px-24 gap-32 grid grid-cols-3 xs:pt-16"
|
|
1575
|
-
},
|
|
1576
|
-
/* @__PURE__ */
|
|
1577
|
-
/* @__PURE__ */
|
|
1578
|
-
], -1),
|
|
1575
|
+
}, Dn = { class: "col-span-2 flex flex-col xs:col-span-3 space-y-8" }, Vn = { class: "fm-typo-en-title-sm-800" }, xn = { class: "space-y-24" }, $n = { class: "space-y-8" }, zn = { class: "fm-typo-en-title-sm-800" }, Hn = { class: "fm-typo-body-lg-400" }, Kn = { class: "fm-typo-body-md-400 text-fm-color-typo-secondary" }, On = { class: "fm-typo-body-md-400 text-fm-color-typo-secondary" }, Yn = { class: "space-y-8" }, jn = { class: "fm-typo-en-title-sm-800 flex items-center gap-8" }, Jn = { class: "space-y-8" }, qn = /* @__PURE__ */ y("div", { class: "fm-typo-en-title-sm-800" }, "SMS", -1), Gn = { class: "space-y-8" }, Qn = /* @__PURE__ */ y("div", { class: "fm-typo-en-title-sm-800" }, "Email", -1), Wn = /* @__PURE__ */ y("div", { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, " Email address that will be used to send email broadcast ", -1), Xn = { class: "space-y-8" }, Zn = /* @__PURE__ */ y("div", { class: "fm-typo-en-title-sm-800" }, "Whatsapp Channel", -1), eo = /* @__PURE__ */ y("div", { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, " Whatsapp phone number that will be used to send whatsapp broadcast ", -1), to = { class: "space-y-8" }, no = /* @__PURE__ */ y("div", { class: "fm-typo-en-title-sm-800" }, [
|
|
1576
|
+
/* @__PURE__ */ oe(" Free Credit as Discount "),
|
|
1577
|
+
/* @__PURE__ */ y("span", { class: "fm-typo-en-body-md-400 text-fm-color-typo-error" }, "*POS v6.56 or above")
|
|
1578
|
+
], -1), oo = { class: "space-y-8" }, ro = { class: "fm-typo-en-title-sm-800 flex items-center gap-8" }, so = { class: "space-y-8" }, io = /* @__PURE__ */ y("div", { class: "fm-typo-en-title-sm-800" }, "Activation Location", -1), ao = { class: "flex justify-end pb-24" }, lo = { class: "col-span-1 space-y-8 xs:hidden" }, co = /* @__PURE__ */ y("div", { class: "fm-typo-en-body-lg-600" }, "Loyalty setting summary", -1), uo = /* @__PURE__ */ y("div", { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, " Name ", -1), fo = { class: "fm-typo-en-body-lg-600" }, mo = /* @__PURE__ */ y("div", { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, " Advertisement ", -1), go = { class: "fm-typo-en-body-lg-600" }, ho = /* @__PURE__ */ y("div", { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, " Free Credit as Discount ", -1), po = { class: "fm-typo-en-body-lg-600" }, yo = /* @__PURE__ */ y("div", { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, " Activated locations ", -1), wo = { class: "fm-typo-en-body-lg-600" }, xo = /* @__PURE__ */ Xe({
|
|
1579
1579
|
__name: "Setting",
|
|
1580
1580
|
setup(t) {
|
|
1581
|
-
const e =
|
|
1581
|
+
const e = Bt(), s = Ft(), r = Ie(), o = ot(), { global: n, minor: a } = At, l = tt(), i = z(), u = z(!1), f = z([]), A = z(null), m = Mt, d = [
|
|
1582
1582
|
(E) => !E || E.length >= 6 || "Invalid URL format, please enter at least 6 characters",
|
|
1583
1583
|
(E) => !E || new RegExp(/^[a-z0-9][a-z0-9\-]{4,}[a-z0-9]$/).test(E) || "Invalid URL format, url should start with a letter or number and can only include lowercase letters, numbers, or hyphens"
|
|
1584
|
-
], v =
|
|
1584
|
+
], v = Se.appUrl, C = ge(() => {
|
|
1585
1585
|
var E;
|
|
1586
|
-
return `https://${(E =
|
|
1587
|
-
}),
|
|
1588
|
-
var E,
|
|
1589
|
-
return Math.min((((
|
|
1590
|
-
}), { t: g } =
|
|
1586
|
+
return `https://${(E = i.value) == null ? void 0 : E.business}.${v}`;
|
|
1587
|
+
}), I = z(), p = z([]), b = ge(() => {
|
|
1588
|
+
var E, h;
|
|
1589
|
+
return Math.min((((h = (E = i.value) == null ? void 0 : E.advertisements) == null ? void 0 : h.length) ?? 0) + 1, 5);
|
|
1590
|
+
}), { t: g } = Lt(), w = s.currentCountry.value || "MY", B = [
|
|
1591
1591
|
"user.name",
|
|
1592
1592
|
"user.gender",
|
|
1593
1593
|
"user.birthday",
|
|
@@ -1595,25 +1595,25 @@ const Ln = { class: "hidden xs:flex items-center justify-between px-16 py-12 bor
|
|
|
1595
1595
|
"membership.url"
|
|
1596
1596
|
].filter(
|
|
1597
1597
|
(E) => {
|
|
1598
|
-
var
|
|
1599
|
-
return !((
|
|
1598
|
+
var h;
|
|
1599
|
+
return !((h = Nt[w]) != null && h.includes(E));
|
|
1600
1600
|
}
|
|
1601
1601
|
);
|
|
1602
|
-
async function
|
|
1602
|
+
async function M() {
|
|
1603
1603
|
l.open({
|
|
1604
1604
|
title: "",
|
|
1605
|
-
dialogComponent:
|
|
1605
|
+
dialogComponent: Ln,
|
|
1606
1606
|
closeButton: !1
|
|
1607
1607
|
});
|
|
1608
1608
|
}
|
|
1609
1609
|
async function P(E) {
|
|
1610
|
-
await
|
|
1610
|
+
await Pt.remove(
|
|
1611
1611
|
"Are you sure you want to unlink this device?",
|
|
1612
1612
|
"Unlink device",
|
|
1613
1613
|
"Unlink"
|
|
1614
1614
|
) && await a(
|
|
1615
1615
|
async () => {
|
|
1616
|
-
await
|
|
1616
|
+
await nt.unregisterDevice(E), await r.readLocationDevices();
|
|
1617
1617
|
},
|
|
1618
1618
|
{
|
|
1619
1619
|
message: "Unlinking device",
|
|
@@ -1621,26 +1621,26 @@ const Ln = { class: "hidden xs:flex items-center justify-between px-16 py-12 bor
|
|
|
1621
1621
|
}
|
|
1622
1622
|
);
|
|
1623
1623
|
}
|
|
1624
|
-
async function
|
|
1624
|
+
async function N() {
|
|
1625
1625
|
await a(
|
|
1626
1626
|
async () => {
|
|
1627
|
-
var
|
|
1628
|
-
const E =
|
|
1629
|
-
E.welcomeMessage && !((
|
|
1630
|
-
const
|
|
1631
|
-
|
|
1627
|
+
var le;
|
|
1628
|
+
const E = kt(i.value);
|
|
1629
|
+
E.welcomeMessage && !((le = E.welcomeMessage) != null && le.content) && (E.welcomeMessage.content = "Hi there, you have been invited to join our membership");
|
|
1630
|
+
const h = St.parse(E);
|
|
1631
|
+
I.value === null && h.image ? await G.delete(G.coverImagePath()) : I.value && (h.image = await G.update(
|
|
1632
1632
|
G.coverImagePath(),
|
|
1633
|
-
|
|
1634
|
-
)), u.value ?
|
|
1635
|
-
new Array(b.value - 1).fill(null).map(async (
|
|
1633
|
+
I.value
|
|
1634
|
+
)), u.value ? h.advertisements = (await Promise.all(
|
|
1635
|
+
new Array(b.value - 1).fill(null).map(async (V, H) => {
|
|
1636
1636
|
var ee;
|
|
1637
|
-
const j =
|
|
1637
|
+
const j = p.value[H];
|
|
1638
1638
|
return j ? await G.update(
|
|
1639
|
-
G.advertisementPath(
|
|
1639
|
+
G.advertisementPath(H, j),
|
|
1640
1640
|
j
|
|
1641
|
-
) : (ee =
|
|
1641
|
+
) : (ee = h.advertisements) == null ? void 0 : ee[H];
|
|
1642
1642
|
})
|
|
1643
|
-
)).filter((
|
|
1643
|
+
)).filter((V) => V) : h.advertisements = [], await Je.update(h), await o.readMembership(), i.value = o.membership;
|
|
1644
1644
|
},
|
|
1645
1645
|
{
|
|
1646
1646
|
message: "Updating membership",
|
|
@@ -1648,116 +1648,111 @@ const Ln = { class: "hidden xs:flex items-center justify-between px-16 py-12 bor
|
|
|
1648
1648
|
}
|
|
1649
1649
|
);
|
|
1650
1650
|
}
|
|
1651
|
-
async function
|
|
1652
|
-
const E = await
|
|
1653
|
-
console.log(E), f.value = E, A.value = E.find((
|
|
1651
|
+
async function D() {
|
|
1652
|
+
const E = await Je.getEmailAddresses();
|
|
1653
|
+
console.log(E), f.value = E, A.value = E.find((h) => h.default.includes("Marketing"));
|
|
1654
1654
|
}
|
|
1655
|
-
async function
|
|
1655
|
+
async function L() {
|
|
1656
1656
|
window.open(
|
|
1657
|
-
`${
|
|
1657
|
+
`${Se.licensePortalUrl}business/${qe.businessId}/settings`,
|
|
1658
1658
|
"_blank"
|
|
1659
1659
|
);
|
|
1660
1660
|
}
|
|
1661
|
+
async function Y() {
|
|
1662
|
+
const E = `${Se.licensePortalUrl}settings?businessId=${qe.businessId}`;
|
|
1663
|
+
console.log("Opening", E), window.open(E, "_blank");
|
|
1664
|
+
}
|
|
1661
1665
|
return Ze(async () => {
|
|
1662
1666
|
await n(async () => {
|
|
1663
|
-
var E,
|
|
1664
|
-
await r.readPremium(), await r.readLocations(), await r.readLocationDevices(), await o.readMembership(), await
|
|
1667
|
+
var E, h;
|
|
1668
|
+
await r.readPremium(), await r.readLocations(), await r.readLocationDevices(), await o.readMembership(), await D(), i.value = o.membership, u.value = (((E = i.value.advertisements) == null ? void 0 : E.length) ?? 0) > 0, p.value = ((h = i.value.advertisements) == null ? void 0 : h.map(() => null)) ?? [];
|
|
1665
1669
|
});
|
|
1666
|
-
}), (E,
|
|
1667
|
-
var
|
|
1668
|
-
const
|
|
1669
|
-
return x(), q(
|
|
1670
|
-
|
|
1670
|
+
}), (E, h) => {
|
|
1671
|
+
var Ve, xe, $e, ze, He, Ke, Oe;
|
|
1672
|
+
const le = F("FmPageHead"), V = F("FmButton"), H = F("FmTextField"), j = F("FmCard"), ee = F("FmPill"), Ce = F("FmSwitch"), Ct = F("FmSelect"), _t = F("FmMenuDivider");
|
|
1673
|
+
return x(), q(ue, null, [
|
|
1674
|
+
S(le, {
|
|
1671
1675
|
title: c(g)("connect.setting.title"),
|
|
1672
1676
|
class: "xs:hidden"
|
|
1673
1677
|
}, null, 8, ["title"]),
|
|
1674
|
-
|
|
1675
|
-
|
|
1676
|
-
|
|
1678
|
+
y("div", Fn, [
|
|
1679
|
+
y("div", Rn, k(c(g)("connect.setting.basicInfo.title")), 1),
|
|
1680
|
+
S(V, {
|
|
1677
1681
|
icon: "info",
|
|
1678
1682
|
variant: "tertiary"
|
|
1679
1683
|
})
|
|
1680
1684
|
]),
|
|
1681
|
-
c(
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
|
|
1685
|
-
|
|
1685
|
+
c(i) ? (x(), q("div", kn, [
|
|
1686
|
+
y("div", Dn, [
|
|
1687
|
+
y("div", Vn, k(c(g)("connect.setting.basicInfo.title")), 1),
|
|
1688
|
+
y("div", xn, [
|
|
1689
|
+
S(H, {
|
|
1686
1690
|
label: c(g)("connect.setting.basicInfo.membershipTitle"),
|
|
1687
|
-
modelValue: c(
|
|
1688
|
-
"onUpdate:modelValue":
|
|
1691
|
+
modelValue: c(i).name,
|
|
1692
|
+
"onUpdate:modelValue": h[0] || (h[0] = (_) => c(i).name = _)
|
|
1689
1693
|
}, null, 8, ["label", "modelValue"]),
|
|
1690
|
-
|
|
1694
|
+
S(H, {
|
|
1691
1695
|
disabled: !0,
|
|
1692
|
-
"model-value": c(
|
|
1696
|
+
"model-value": c(i).business,
|
|
1693
1697
|
rules: d,
|
|
1694
1698
|
required: !0,
|
|
1695
1699
|
label: c(g)("connect.setting.basicInfo.memberAppUrl"),
|
|
1696
1700
|
"helper-text": c(C),
|
|
1697
|
-
placeholder: c(
|
|
1698
|
-
"onUpdate:modelValue":
|
|
1701
|
+
placeholder: c(i).business.toString(),
|
|
1702
|
+
"onUpdate:modelValue": h[2] || (h[2] = (_) => c(i).url = _)
|
|
1699
1703
|
}, {
|
|
1700
|
-
prepend:
|
|
1701
|
-
|
|
1704
|
+
prepend: ne(() => [
|
|
1705
|
+
oe(" https:// ")
|
|
1702
1706
|
]),
|
|
1703
|
-
append:
|
|
1704
|
-
|
|
1705
|
-
|
|
1707
|
+
append: ne(() => [
|
|
1708
|
+
oe(" ." + k(c(v)) + " ", 1),
|
|
1709
|
+
S(V, {
|
|
1706
1710
|
icon: "content_copy",
|
|
1707
1711
|
variant: "tertiary",
|
|
1708
|
-
onClick:
|
|
1712
|
+
onClick: h[1] || (h[1] = (_) => c(rt)(c(C)))
|
|
1709
1713
|
})
|
|
1710
1714
|
]),
|
|
1711
1715
|
_: 1
|
|
1712
1716
|
}, 8, ["model-value", "label", "helper-text", "placeholder"]),
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
"aspect-ratio": "3/1",
|
|
1718
|
-
thumbnail: c(s).image || void 0,
|
|
1719
|
-
"onUpdate:file": y[3] || (y[3] = async (_) => {
|
|
1720
|
-
M.value = _, _ || (c(s).image = null);
|
|
1721
|
-
})
|
|
1722
|
-
}, null, 8, ["thumbnail"]),
|
|
1723
|
-
w("div", xn, [
|
|
1724
|
-
w("div", $n, D(c(g)("connect.setting.counterApp.title")), 1),
|
|
1725
|
-
I(z, {
|
|
1717
|
+
te("", !0),
|
|
1718
|
+
y("div", $n, [
|
|
1719
|
+
y("div", zn, k(c(g)("connect.setting.counterApp.title")), 1),
|
|
1720
|
+
S(V, {
|
|
1726
1721
|
variant: "plain",
|
|
1727
1722
|
icon: "link",
|
|
1728
1723
|
label: c(g)("connect.setting.counterApp.linkDevice"),
|
|
1729
|
-
onClick:
|
|
1724
|
+
onClick: M
|
|
1730
1725
|
}, null, 8, ["label"]),
|
|
1731
|
-
(x(!0), q(
|
|
1726
|
+
(x(!0), q(ue, null, Ye(c(r).locationDevices, (_, T) => (x(), me(j, {
|
|
1732
1727
|
key: T,
|
|
1733
1728
|
variant: "outlined",
|
|
1734
1729
|
class: "flex items-center justify-between px-16 py-12"
|
|
1735
1730
|
}, {
|
|
1736
|
-
default:
|
|
1737
|
-
|
|
1738
|
-
|
|
1739
|
-
|
|
1731
|
+
default: ne(() => [
|
|
1732
|
+
y("div", null, [
|
|
1733
|
+
y("p", Hn, k(_.name || `Device ${_._id}`), 1),
|
|
1734
|
+
y("p", Kn, " Activation date: " + k(c(Et)(c(Rt)(_._id.toString())).format(
|
|
1740
1735
|
"D MMM YYYY"
|
|
1741
1736
|
)), 1),
|
|
1742
|
-
|
|
1737
|
+
y("p", On, " Linked location: " + k(c(r).locations.find((R) => R._id == _.location).name), 1)
|
|
1743
1738
|
]),
|
|
1744
|
-
|
|
1739
|
+
S(V, {
|
|
1745
1740
|
icon: "link_off",
|
|
1746
1741
|
variant: "tertiary",
|
|
1747
|
-
onClick: (
|
|
1742
|
+
onClick: (R) => P(_._id)
|
|
1748
1743
|
}, null, 8, ["onClick"])
|
|
1749
1744
|
]),
|
|
1750
1745
|
_: 2
|
|
1751
1746
|
}, 1024))), 128))
|
|
1752
1747
|
]),
|
|
1753
|
-
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1748
|
+
y("div", Yn, [
|
|
1749
|
+
y("div", jn, [
|
|
1750
|
+
oe(" Advertisement "),
|
|
1751
|
+
S(ee, { variant: "premium" })
|
|
1757
1752
|
]),
|
|
1758
|
-
|
|
1753
|
+
S(Ce, {
|
|
1759
1754
|
modelValue: c(u),
|
|
1760
|
-
"onUpdate:modelValue":
|
|
1755
|
+
"onUpdate:modelValue": h[4] || (h[4] = (_) => et(u) ? u.value = _ : null),
|
|
1761
1756
|
label: "Advertisement",
|
|
1762
1757
|
sublabel: "This will be show on FeedMe ordering app",
|
|
1763
1758
|
"label-placement": "right",
|
|
@@ -1768,101 +1763,110 @@ const Ln = { class: "hidden xs:flex items-center justify-between px-16 py-12 bor
|
|
|
1768
1763
|
class: "flex items-center gap-8 flex-wrap xs:grid xs:grid-cols-2 xs:overflow-x-scroll xs:w-full",
|
|
1769
1764
|
key: c(b)
|
|
1770
1765
|
}, [
|
|
1771
|
-
(x(!0), q(
|
|
1772
|
-
var
|
|
1773
|
-
return x(),
|
|
1766
|
+
(x(!0), q(ue, null, Ye(c(b), (_, T) => {
|
|
1767
|
+
var R, J;
|
|
1768
|
+
return x(), me(It, {
|
|
1774
1769
|
class: "w-[200px]",
|
|
1775
1770
|
"image-fit": "cover",
|
|
1776
1771
|
label: "",
|
|
1777
1772
|
"aspect-ratio": "2/3",
|
|
1778
|
-
thumbnail: (J = (
|
|
1773
|
+
thumbnail: (J = (R = c(i)) == null ? void 0 : R.advertisements) == null ? void 0 : J[T],
|
|
1779
1774
|
accept: ".png, .jpg, .jpeg, .mp4, .gif",
|
|
1780
1775
|
"recommended-size": "Recommended 4:5 ratio / 1080px x 1350px",
|
|
1781
|
-
file: c(
|
|
1782
|
-
"onUpdate:file": (
|
|
1783
|
-
c(
|
|
1776
|
+
file: c(p)[T] ?? void 0,
|
|
1777
|
+
"onUpdate:file": (ce) => {
|
|
1778
|
+
c(i).advertisements || (c(i).advertisements = []), ce ? (c(i).advertisements[T] = "", c(p)[T] = ce) : (c(i).advertisements.splice(T, 1), c(p).splice(T, 1));
|
|
1784
1779
|
}
|
|
1785
1780
|
}, null, 8, ["thumbnail", "file", "onUpdate:file"]);
|
|
1786
1781
|
}), 256))
|
|
1787
|
-
])) :
|
|
1782
|
+
])) : te("", !0)
|
|
1788
1783
|
]),
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
"model-value": ((
|
|
1784
|
+
y("div", Jn, [
|
|
1785
|
+
qn,
|
|
1786
|
+
S(H, {
|
|
1787
|
+
"model-value": ((Ve = c(i)) == null ? void 0 : Ve.brand) || "",
|
|
1793
1788
|
"max-length": 15,
|
|
1794
1789
|
label: "Brand Name",
|
|
1795
1790
|
"show-word-count": "",
|
|
1796
|
-
"helper-text": `RM 0 ${((
|
|
1797
|
-
"onUpdate:modelValue":
|
|
1791
|
+
"helper-text": `RM 0 ${((xe = c(i)) == null ? void 0 : xe.brand) || ""}: YOUR CUSTOMER MESSAGE`,
|
|
1792
|
+
"onUpdate:modelValue": h[5] || (h[5] = (_) => c(i).brand = _)
|
|
1798
1793
|
}, null, 8, ["model-value", "helper-text"]),
|
|
1799
|
-
|
|
1800
|
-
modelValue: c(
|
|
1801
|
-
"onUpdate:modelValue":
|
|
1794
|
+
S(Ut, {
|
|
1795
|
+
modelValue: c(i).welcomeMessage,
|
|
1796
|
+
"onUpdate:modelValue": h[6] || (h[6] = (_) => c(i).welcomeMessage = _),
|
|
1802
1797
|
variables: c(B),
|
|
1803
1798
|
placeholder: "Hi there, you have been invited to join membership"
|
|
1804
1799
|
}, null, 8, ["modelValue", "variables"])
|
|
1805
1800
|
]),
|
|
1806
|
-
|
|
1807
|
-
Gn,
|
|
1801
|
+
y("div", Gn, [
|
|
1808
1802
|
Qn,
|
|
1809
|
-
|
|
1803
|
+
Wn,
|
|
1804
|
+
c(f).length ? te("", !0) : (x(), me(V, {
|
|
1810
1805
|
key: 0,
|
|
1811
|
-
onClick:
|
|
1806
|
+
onClick: L,
|
|
1812
1807
|
label: "Add new email address"
|
|
1813
1808
|
})),
|
|
1814
|
-
c(f).length ? (x(), q(
|
|
1815
|
-
|
|
1816
|
-
"model-value": ((
|
|
1809
|
+
c(f).length ? (x(), q(ue, { key: 1 }, [
|
|
1810
|
+
S(Ct, {
|
|
1811
|
+
"model-value": ((ze = ($e = c(i)) == null ? void 0 : $e.email) == null ? void 0 : ze.from) || null,
|
|
1817
1812
|
label: "From Address",
|
|
1818
1813
|
items: c(f).map((_) => ({
|
|
1819
1814
|
label: _.emailAddress,
|
|
1820
1815
|
value: _.emailAddress
|
|
1821
1816
|
})),
|
|
1822
1817
|
placeholder: c(A) ? c(A).emailAddress : "No email address available",
|
|
1823
|
-
"onUpdate:modelValue":
|
|
1824
|
-
var T,
|
|
1825
|
-
(T = c(
|
|
1818
|
+
"onUpdate:modelValue": h[7] || (h[7] = (_) => {
|
|
1819
|
+
var T, R;
|
|
1820
|
+
(T = c(i)) != null && T.email || (c(i).email = {
|
|
1826
1821
|
from: _,
|
|
1827
|
-
name: (
|
|
1828
|
-
}), c(
|
|
1822
|
+
name: (R = c(f).find((J) => J.emailAddress == _)) == null ? void 0 : R.name
|
|
1823
|
+
}), c(i).email.from = _ || null;
|
|
1829
1824
|
}),
|
|
1830
|
-
rules: [c(
|
|
1825
|
+
rules: [c(je).ruleAtPath(c(m), "email.from")]
|
|
1831
1826
|
}, null, 8, ["model-value", "items", "placeholder", "rules"]),
|
|
1832
|
-
|
|
1833
|
-
"model-value": ((
|
|
1827
|
+
S(H, {
|
|
1828
|
+
"model-value": ((Ke = (He = c(i)) == null ? void 0 : He.email) == null ? void 0 : Ke.name) || null,
|
|
1834
1829
|
label: "Sender name",
|
|
1835
1830
|
disabled: "",
|
|
1836
|
-
placeholder: ((
|
|
1837
|
-
"onUpdate:modelValue":
|
|
1831
|
+
placeholder: ((Oe = c(A)) == null ? void 0 : Oe.name) || null,
|
|
1832
|
+
"onUpdate:modelValue": h[8] || (h[8] = (_) => {
|
|
1838
1833
|
var T;
|
|
1839
|
-
(T = c(
|
|
1834
|
+
(T = c(i)) != null && T.email || (c(i).email = {
|
|
1840
1835
|
name: _
|
|
1841
|
-
}), c(
|
|
1836
|
+
}), c(i).email.name = _ || null;
|
|
1842
1837
|
}),
|
|
1843
|
-
rules: [c(
|
|
1838
|
+
rules: [c(je).ruleAtPath(c(m), "email.name")]
|
|
1844
1839
|
}, null, 8, ["model-value", "placeholder", "rules"])
|
|
1845
|
-
], 64)) :
|
|
1840
|
+
], 64)) : te("", !0)
|
|
1846
1841
|
]),
|
|
1847
|
-
|
|
1842
|
+
y("div", Xn, [
|
|
1848
1843
|
Zn,
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1844
|
+
eo,
|
|
1845
|
+
S(V, {
|
|
1846
|
+
label: "Manage Whatsapp Channel",
|
|
1847
|
+
icon: "open_in_new",
|
|
1848
|
+
onClick: h[9] || (h[9] = (_) => Y())
|
|
1849
|
+
})
|
|
1850
|
+
]),
|
|
1851
|
+
y("div", to, [
|
|
1852
|
+
no,
|
|
1853
|
+
S(Ce, {
|
|
1854
|
+
"model-value": c(i).freeCreditAsDiscount ?? !1,
|
|
1855
|
+
"onUpdate:modelValue": h[10] || (h[10] = (_) => c(i).freeCreditAsDiscount = _),
|
|
1852
1856
|
label: "Free Credit as Discount",
|
|
1853
1857
|
sublabel: "When enabled, this will allow free credit to be used as discount in the bill (POS >=v6.56)",
|
|
1854
1858
|
"label-placement": "right",
|
|
1855
1859
|
value: ""
|
|
1856
1860
|
}, null, 8, ["model-value"])
|
|
1857
1861
|
]),
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
+
y("div", oo, [
|
|
1863
|
+
y("div", ro, [
|
|
1864
|
+
oe(" Member Card "),
|
|
1865
|
+
S(ee, { variant: "premium" })
|
|
1862
1866
|
]),
|
|
1863
|
-
|
|
1864
|
-
"model-value": c(
|
|
1865
|
-
"onUpdate:modelValue":
|
|
1867
|
+
S(Ce, {
|
|
1868
|
+
"model-value": c(i).cardEnable ?? !1,
|
|
1869
|
+
"onUpdate:modelValue": h[11] || (h[11] = (_) => c(i).cardEnable = _),
|
|
1866
1870
|
label: "",
|
|
1867
1871
|
sublabel: "Allow member to bind card via member app",
|
|
1868
1872
|
"label-placement": "right",
|
|
@@ -1870,51 +1874,51 @@ const Ln = { class: "hidden xs:flex items-center justify-between px-16 py-12 bor
|
|
|
1870
1874
|
disabled: !c(r).isPremium
|
|
1871
1875
|
}, null, 8, ["model-value", "disabled"])
|
|
1872
1876
|
]),
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1877
|
+
y("div", so, [
|
|
1878
|
+
io,
|
|
1879
|
+
S(Tt, {
|
|
1876
1880
|
label: "Select restaurant",
|
|
1877
|
-
"model-value": c(
|
|
1878
|
-
"onUpdate:modelValue":
|
|
1881
|
+
"model-value": c(i).targetLocation ?? null,
|
|
1882
|
+
"onUpdate:modelValue": h[12] || (h[12] = (_) => c(i).targetLocation = _)
|
|
1879
1883
|
}, null, 8, ["model-value"])
|
|
1880
1884
|
]),
|
|
1881
|
-
|
|
1882
|
-
|
|
1885
|
+
y("div", ao, [
|
|
1886
|
+
S(V, {
|
|
1883
1887
|
label: "Update",
|
|
1884
1888
|
type: "button",
|
|
1885
|
-
onClick:
|
|
1889
|
+
onClick: N,
|
|
1886
1890
|
disabled: !!c(e).loadingQueue.length,
|
|
1887
1891
|
loading: !!c(e).loadingQueue.length
|
|
1888
1892
|
}, null, 8, ["disabled", "loading"])
|
|
1889
1893
|
])
|
|
1890
1894
|
])
|
|
1891
1895
|
]),
|
|
1892
|
-
|
|
1893
|
-
|
|
1896
|
+
y("div", lo, [
|
|
1897
|
+
S(j, {
|
|
1894
1898
|
variant: "outlined",
|
|
1895
1899
|
class: "flex flex-col p-24 gap-8"
|
|
1896
1900
|
}, {
|
|
1897
|
-
default:
|
|
1898
|
-
var _, T,
|
|
1901
|
+
default: ne(() => {
|
|
1902
|
+
var _, T, R;
|
|
1899
1903
|
return [
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
so,
|
|
1904
|
-
w("div", ao, D(c(s).name), 1)
|
|
1905
|
-
]),
|
|
1906
|
-
w("div", null, [
|
|
1907
|
-
lo,
|
|
1908
|
-
w("div", co, D((((_ = c(s).advertisements) == null ? void 0 : _.length) ?? 0) || "No advertisments"), 1)
|
|
1909
|
-
]),
|
|
1910
|
-
w("div", null, [
|
|
1904
|
+
co,
|
|
1905
|
+
S(_t, { class: "my-4" }),
|
|
1906
|
+
y("div", null, [
|
|
1911
1907
|
uo,
|
|
1912
|
-
|
|
1908
|
+
y("div", fo, k(c(i).name), 1)
|
|
1913
1909
|
]),
|
|
1914
|
-
|
|
1910
|
+
y("div", null, [
|
|
1915
1911
|
mo,
|
|
1916
|
-
|
|
1917
|
-
|
|
1912
|
+
y("div", go, k((((_ = c(i).advertisements) == null ? void 0 : _.length) ?? 0) || "No advertisments"), 1)
|
|
1913
|
+
]),
|
|
1914
|
+
y("div", null, [
|
|
1915
|
+
ho,
|
|
1916
|
+
y("div", po, k(c(i).freeCreditAsDiscount ? "Enabled" : "Disabled"), 1)
|
|
1917
|
+
]),
|
|
1918
|
+
y("div", null, [
|
|
1919
|
+
yo,
|
|
1920
|
+
y("div", wo, k(!c(i).targetLocation || c(i).targetLocation.length == c(Ie)().locations.length ? "All locations" : (R = (T = c(i)) == null ? void 0 : T.targetLocation) == null ? void 0 : R.map(
|
|
1921
|
+
(J) => c(r).locations.find((ce) => ce._id == J).name
|
|
1918
1922
|
).join(", ")), 1)
|
|
1919
1923
|
])
|
|
1920
1924
|
];
|
|
@@ -1922,11 +1926,11 @@ const Ln = { class: "hidden xs:flex items-center justify-between px-16 py-12 bor
|
|
|
1922
1926
|
_: 1
|
|
1923
1927
|
})
|
|
1924
1928
|
])
|
|
1925
|
-
])) :
|
|
1929
|
+
])) : te("", !0)
|
|
1926
1930
|
], 64);
|
|
1927
1931
|
};
|
|
1928
1932
|
}
|
|
1929
1933
|
});
|
|
1930
1934
|
export {
|
|
1931
|
-
|
|
1935
|
+
xo as default
|
|
1932
1936
|
};
|