@emqx/shared-ui-utils 0.0.22 → 0.0.23
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/index.js +1161 -1141
- package/dist/index.umd.cjs +30 -25
- package/dist/useBatchSettings.d.ts +9 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var i = /* @__PURE__ */ ((e) => (e.All = "ALL", e.Read = "READ", e.Write = "WRITE", e.Describe = "DESCRIBE", e.Create = "CREATE", e.Delete = "DELETE", e.Alter = "ALTER", e))(i || {}), m$1 = /* @__PURE__ */ ((e) => (e.Allow = "ALLOW", e.Deny = "DENY", e))(m$1 || {}), o = /* @__PURE__ */ ((e) => (e.Topic = "TOPIC", e.Group = "GROUP", e.Cluster = "CLUSTER", e))(o || {}), r = /* @__PURE__ */ ((e) => (e.Webhook = "http", e.MQTT = "mqtt", e.InfluxDB = "influxdb", e.MySQL = "mysql", e.KafkaProducer = "kafka_producer", e.KafkaConsumer = "kafka_consumer", e.Redis = "redis", e.GCPProducer = "gcp_pubsub_producer", e.GCPConsumer = "gcp_pubsub_consumer", e.MongoDB = "mongodb", e.PgSQL = "pgsql", e.TimescaleDB = "timescale", e.MatrixDB = "matrix", e.TDengine = "tdengine", e.ClickHouse = "clickhouse", e.DynamoDB = "dynamo", e.Cassandra = "cassandra", e.MicrosoftSQLServer = "sqlserver", e.RocketMQ = "rocketmq", e.IoTDB = "iotdb", e.OpenTSDB = "opents", e.OracleDatabase = "oracle", e.RabbitMQ = "rabbitmq", e.Pulsar = "pulsar", e.HStream = "hstreamdb", e.AzureEventHubs = "azure_event_hub_producer", e.AmazonKinesis = "kinesis", e.GreptimeDB = "greptimedb", e.Confluent = "confluent_producer", e.SysKeeperProxy = "syskeeper_proxy", e.SysKeeperForwarder = "syskeeper_forwarder", e.Elasticsearch = "elasticsearch", e.S3 = "s3", e.AzureBlobStorage = "azure_blob_storage", e.Couchbase = "couchbase", e.Datalayers = "datalayers", e.Snowflake = "snowflake", e.Tablestore = "tablestore", e.DiskLog = "disk_log", e.S3Tables = "s3tables", e.Doris = "doris", e))(r || {}), a = /* @__PURE__ */ ((e) => (e.Message = "message", e.Event = "event", e))(a || {});
|
|
1
|
+
var i = /* @__PURE__ */ ((e) => (e.All = "ALL", e.Read = "READ", e.Write = "WRITE", e.Describe = "DESCRIBE", e.Create = "CREATE", e.Delete = "DELETE", e.Alter = "ALTER", e))(i || {}), m$1 = /* @__PURE__ */ ((e) => (e.Allow = "ALLOW", e.Deny = "DENY", e))(m$1 || {}), o = /* @__PURE__ */ ((e) => (e.Topic = "TOPIC", e.Group = "GROUP", e.Cluster = "CLUSTER", e))(o || {}), r = /* @__PURE__ */ ((e) => (e.Webhook = "http", e.MQTT = "mqtt", e.InfluxDB = "influxdb", e.MySQL = "mysql", e.KafkaProducer = "kafka_producer", e.KafkaConsumer = "kafka_consumer", e.Redis = "redis", e.GCPProducer = "gcp_pubsub_producer", e.GCPConsumer = "gcp_pubsub_consumer", e.MongoDB = "mongodb", e.PgSQL = "pgsql", e.TimescaleDB = "timescale", e.MatrixDB = "matrix", e.TDengine = "tdengine", e.ClickHouse = "clickhouse", e.DynamoDB = "dynamo", e.Cassandra = "cassandra", e.MicrosoftSQLServer = "sqlserver", e.RocketMQ = "rocketmq", e.IoTDB = "iotdb", e.OpenTSDB = "opents", e.OracleDatabase = "oracle", e.RabbitMQ = "rabbitmq", e.Pulsar = "pulsar", e.HStream = "hstreamdb", e.AzureEventHubs = "azure_event_hub_producer", e.AmazonKinesis = "kinesis", e.GreptimeDB = "greptimedb", e.Confluent = "confluent_producer", e.SysKeeperProxy = "syskeeper_proxy", e.SysKeeperForwarder = "syskeeper_forwarder", e.Elasticsearch = "elasticsearch", e.S3 = "s3", e.AzureBlobStorage = "azure_blob_storage", e.Couchbase = "couchbase", e.Datalayers = "datalayers", e.Snowflake = "snowflake", e.SnowflakeStreaming = "snowflake_streaming", e.Tablestore = "tablestore", e.DiskLog = "disk_log", e.S3Tables = "s3tables", e.Doris = "doris", e.BigQuery = "bigquery", e.AlloyDB = "alloydb", e.CockroachDB = "cockroachdb", e.Redshift = "redshift", e.AWSTimestream = "aws_timestream", e.EMQXTables = "emqx_tables", e))(r || {}), a = /* @__PURE__ */ ((e) => (e.Message = "message", e.Event = "event", e))(a || {});
|
|
2
2
|
const v$1 = "$bridges/", E = "ai_completion";
|
|
3
3
|
r.MQTT, r.RabbitMQ;
|
|
4
4
|
a.Event, a.Message;
|
|
@@ -62,8 +62,8 @@ const O = new RegExp(
|
|
|
62
62
|
const t = e.trim();
|
|
63
63
|
let n, s, c, l = null;
|
|
64
64
|
if (N.test(t) ? l = t.match(/(?<foreach>(.|\n)+)FROM(?<from>(.|\n)+)/) : l = t.match(withConditionSQLReg) || t.match(normalSQLReg), l) {
|
|
65
|
-
const { groups: C } = l, { foreach: A = "", select: L = "", from: B = "", where:
|
|
66
|
-
n = A || L.trim(), s = B.trim(),
|
|
65
|
+
const { groups: C } = l, { foreach: A = "", select: L = "", from: B = "", where: J = "" } = C || {};
|
|
66
|
+
n = A || L.trim(), s = B.trim(), J && (c = J.trim());
|
|
67
67
|
}
|
|
68
68
|
return {
|
|
69
69
|
fieldStr: n,
|
|
@@ -891,12 +891,12 @@ function generateCodeFrame(e, t = 0, n = e.length) {
|
|
|
891
891
|
l.push(`${L}${" ".repeat(3 - String(L).length)}| ${s[A]}`);
|
|
892
892
|
const B = s[A].length;
|
|
893
893
|
if (A === C) {
|
|
894
|
-
const
|
|
895
|
-
l.push(" | " + " ".repeat(
|
|
894
|
+
const J = t - (c - B) + 1, U = Math.max(1, n > c ? B - J : n - t);
|
|
895
|
+
l.push(" | " + " ".repeat(J) + "^".repeat(U));
|
|
896
896
|
} else if (A > C) {
|
|
897
897
|
if (n > c) {
|
|
898
|
-
const
|
|
899
|
-
l.push(" | " + "^".repeat(
|
|
898
|
+
const J = Math.max(Math.min(n - c, B), 1);
|
|
899
|
+
l.push(" | " + "^".repeat(J));
|
|
900
900
|
}
|
|
901
901
|
c += B + 1;
|
|
902
902
|
}
|
|
@@ -1025,38 +1025,38 @@ const RE_HTML_TAG = /<\/?[\w\s="/.':;#-\/]+>/, detectHtmlTag = (e) => RE_HTML_TA
|
|
|
1025
1025
|
function createScanner(e) {
|
|
1026
1026
|
const t = e;
|
|
1027
1027
|
let n = 0, s = 1, c = 1, l = 0;
|
|
1028
|
-
const C = (ie) => t[ie] === CHAR_CR && t[ie + 1] === CHAR_LF, A = (ie) => t[ie] === CHAR_LF, L = (ie) => t[ie] === CHAR_PS, B = (ie) => t[ie] === CHAR_LS,
|
|
1029
|
-
function
|
|
1030
|
-
return l = 0,
|
|
1028
|
+
const C = (ie) => t[ie] === CHAR_CR && t[ie + 1] === CHAR_LF, A = (ie) => t[ie] === CHAR_LF, L = (ie) => t[ie] === CHAR_PS, B = (ie) => t[ie] === CHAR_LS, J = (ie) => C(ie) || A(ie) || L(ie) || B(ie), U = () => n, V = () => s, X = () => c, ce = () => l, se = (ie) => C(ie) || L(ie) || B(ie) ? CHAR_LF : t[ie], ne = () => se(n), q = () => se(n + l);
|
|
1029
|
+
function Y() {
|
|
1030
|
+
return l = 0, J(n) && (s++, c = 0), C(n) && n++, n++, c++, t[n];
|
|
1031
1031
|
}
|
|
1032
|
-
function
|
|
1032
|
+
function oe() {
|
|
1033
1033
|
return C(n + l) && l++, l++, t[n + l];
|
|
1034
1034
|
}
|
|
1035
|
-
function
|
|
1035
|
+
function re() {
|
|
1036
1036
|
n = 0, s = 1, c = 1, l = 0;
|
|
1037
1037
|
}
|
|
1038
|
-
function
|
|
1038
|
+
function ae(ie = 0) {
|
|
1039
1039
|
l = ie;
|
|
1040
1040
|
}
|
|
1041
|
-
function
|
|
1041
|
+
function te() {
|
|
1042
1042
|
const ie = n + l;
|
|
1043
1043
|
for (; ie !== n; )
|
|
1044
|
-
|
|
1044
|
+
Y();
|
|
1045
1045
|
l = 0;
|
|
1046
1046
|
}
|
|
1047
1047
|
return {
|
|
1048
1048
|
index: U,
|
|
1049
1049
|
line: V,
|
|
1050
|
-
column:
|
|
1050
|
+
column: X,
|
|
1051
1051
|
peekOffset: ce,
|
|
1052
1052
|
charAt: se,
|
|
1053
|
-
currentChar:
|
|
1054
|
-
currentPeek:
|
|
1055
|
-
next:
|
|
1056
|
-
peek:
|
|
1057
|
-
reset:
|
|
1058
|
-
resetPeek:
|
|
1059
|
-
skipToPeek:
|
|
1053
|
+
currentChar: ne,
|
|
1054
|
+
currentPeek: q,
|
|
1055
|
+
next: Y,
|
|
1056
|
+
peek: oe,
|
|
1057
|
+
reset: re,
|
|
1058
|
+
resetPeek: ae,
|
|
1059
|
+
skipToPeek: te
|
|
1060
1060
|
};
|
|
1061
1061
|
}
|
|
1062
1062
|
const EOF = void 0, DOT = ".", LITERAL_DELIMITER = "'", ERROR_DOMAIN$3 = "tokenizer";
|
|
@@ -1073,23 +1073,23 @@ function createTokenizer(e, t = {}) {
|
|
|
1073
1073
|
braceNest: 0,
|
|
1074
1074
|
inLinked: !1,
|
|
1075
1075
|
text: ""
|
|
1076
|
-
}, B = () => L, { onError:
|
|
1077
|
-
function U(R, I, F, ...
|
|
1076
|
+
}, B = () => L, { onError: J } = t;
|
|
1077
|
+
function U(R, I, F, ...G) {
|
|
1078
1078
|
const j = B();
|
|
1079
|
-
if (I.column += F, I.offset += F,
|
|
1079
|
+
if (I.column += F, I.offset += F, J) {
|
|
1080
1080
|
const K = n ? createLocation(j.startLoc, I) : null, Z = createCompileError(R, K, {
|
|
1081
1081
|
domain: ERROR_DOMAIN$3,
|
|
1082
|
-
args:
|
|
1082
|
+
args: G
|
|
1083
1083
|
});
|
|
1084
|
-
|
|
1084
|
+
J(Z);
|
|
1085
1085
|
}
|
|
1086
1086
|
}
|
|
1087
1087
|
function V(R, I, F) {
|
|
1088
1088
|
R.endLoc = l(), R.currentType = I;
|
|
1089
|
-
const
|
|
1090
|
-
return n && (
|
|
1089
|
+
const G = { type: I };
|
|
1090
|
+
return n && (G.loc = createLocation(R.startLoc, R.endLoc)), F != null && (G.value = F), G;
|
|
1091
1091
|
}
|
|
1092
|
-
const
|
|
1092
|
+
const X = (R) => V(
|
|
1093
1093
|
R,
|
|
1094
1094
|
14
|
|
1095
1095
|
/* TokenTypes.EOF */
|
|
@@ -1103,11 +1103,11 @@ function createTokenizer(e, t = {}) {
|
|
|
1103
1103
|
I += R.currentPeek(), R.peek();
|
|
1104
1104
|
return I;
|
|
1105
1105
|
}
|
|
1106
|
-
function
|
|
1106
|
+
function ne(R) {
|
|
1107
1107
|
const I = se(R);
|
|
1108
1108
|
return R.skipToPeek(), I;
|
|
1109
1109
|
}
|
|
1110
|
-
function
|
|
1110
|
+
function q(R) {
|
|
1111
1111
|
if (R === EOF)
|
|
1112
1112
|
return !1;
|
|
1113
1113
|
const I = R.charCodeAt(0);
|
|
@@ -1115,71 +1115,71 @@ function createTokenizer(e, t = {}) {
|
|
|
1115
1115
|
I >= 65 && I <= 90 || // A-Z
|
|
1116
1116
|
I === 95;
|
|
1117
1117
|
}
|
|
1118
|
-
function
|
|
1118
|
+
function Y(R) {
|
|
1119
1119
|
if (R === EOF)
|
|
1120
1120
|
return !1;
|
|
1121
1121
|
const I = R.charCodeAt(0);
|
|
1122
1122
|
return I >= 48 && I <= 57;
|
|
1123
1123
|
}
|
|
1124
|
-
function
|
|
1124
|
+
function oe(R, I) {
|
|
1125
1125
|
const { currentType: F } = I;
|
|
1126
1126
|
if (F !== 2)
|
|
1127
1127
|
return !1;
|
|
1128
1128
|
se(R);
|
|
1129
|
-
const
|
|
1130
|
-
return R.resetPeek(),
|
|
1129
|
+
const G = q(R.currentPeek());
|
|
1130
|
+
return R.resetPeek(), G;
|
|
1131
1131
|
}
|
|
1132
|
-
function
|
|
1132
|
+
function re(R, I) {
|
|
1133
1133
|
const { currentType: F } = I;
|
|
1134
1134
|
if (F !== 2)
|
|
1135
1135
|
return !1;
|
|
1136
1136
|
se(R);
|
|
1137
|
-
const
|
|
1137
|
+
const G = R.currentPeek() === "-" ? R.peek() : R.currentPeek(), j = Y(G);
|
|
1138
1138
|
return R.resetPeek(), j;
|
|
1139
1139
|
}
|
|
1140
|
-
function
|
|
1140
|
+
function ae(R, I) {
|
|
1141
1141
|
const { currentType: F } = I;
|
|
1142
1142
|
if (F !== 2)
|
|
1143
1143
|
return !1;
|
|
1144
1144
|
se(R);
|
|
1145
|
-
const
|
|
1146
|
-
return R.resetPeek(),
|
|
1145
|
+
const G = R.currentPeek() === LITERAL_DELIMITER;
|
|
1146
|
+
return R.resetPeek(), G;
|
|
1147
1147
|
}
|
|
1148
|
-
function
|
|
1148
|
+
function te(R, I) {
|
|
1149
1149
|
const { currentType: F } = I;
|
|
1150
1150
|
if (F !== 8)
|
|
1151
1151
|
return !1;
|
|
1152
1152
|
se(R);
|
|
1153
|
-
const
|
|
1154
|
-
return R.resetPeek(),
|
|
1153
|
+
const G = R.currentPeek() === ".";
|
|
1154
|
+
return R.resetPeek(), G;
|
|
1155
1155
|
}
|
|
1156
1156
|
function ie(R, I) {
|
|
1157
1157
|
const { currentType: F } = I;
|
|
1158
1158
|
if (F !== 9)
|
|
1159
1159
|
return !1;
|
|
1160
1160
|
se(R);
|
|
1161
|
-
const
|
|
1162
|
-
return R.resetPeek(),
|
|
1161
|
+
const G = q(R.currentPeek());
|
|
1162
|
+
return R.resetPeek(), G;
|
|
1163
1163
|
}
|
|
1164
|
-
function
|
|
1164
|
+
function H(R, I) {
|
|
1165
1165
|
const { currentType: F } = I;
|
|
1166
1166
|
if (!(F === 8 || F === 12))
|
|
1167
1167
|
return !1;
|
|
1168
1168
|
se(R);
|
|
1169
|
-
const
|
|
1170
|
-
return R.resetPeek(),
|
|
1169
|
+
const G = R.currentPeek() === ":";
|
|
1170
|
+
return R.resetPeek(), G;
|
|
1171
1171
|
}
|
|
1172
1172
|
function $(R, I) {
|
|
1173
1173
|
const { currentType: F } = I;
|
|
1174
1174
|
if (F !== 10)
|
|
1175
1175
|
return !1;
|
|
1176
|
-
const
|
|
1176
|
+
const G = () => {
|
|
1177
1177
|
const K = R.currentPeek();
|
|
1178
|
-
return K === "{" ?
|
|
1179
|
-
}, j =
|
|
1178
|
+
return K === "{" ? q(R.peek()) : K === "@" || K === "%" || K === "|" || K === ":" || K === "." || K === CHAR_SP || !K ? !1 : K === CHAR_LF ? (R.peek(), G()) : q(K);
|
|
1179
|
+
}, j = G();
|
|
1180
1180
|
return R.resetPeek(), j;
|
|
1181
1181
|
}
|
|
1182
|
-
function
|
|
1182
|
+
function Q(R) {
|
|
1183
1183
|
se(R);
|
|
1184
1184
|
const I = R.currentPeek() === "|";
|
|
1185
1185
|
return R.resetPeek(), I;
|
|
@@ -1195,35 +1195,35 @@ function createTokenizer(e, t = {}) {
|
|
|
1195
1195
|
const F = (j = !1, K = "", Z = !1) => {
|
|
1196
1196
|
const z = R.currentPeek();
|
|
1197
1197
|
return z === "{" ? K === "%" ? !1 : j : z === "@" || !z ? K === "%" ? !0 : j : z === "%" ? (R.peek(), F(j, "%", !0)) : z === "|" ? K === "%" || Z ? !0 : !(K === CHAR_SP || K === CHAR_LF) : z === CHAR_SP ? (R.peek(), F(!0, CHAR_SP, Z)) : z === CHAR_LF ? (R.peek(), F(!0, CHAR_LF, Z)) : !0;
|
|
1198
|
-
},
|
|
1199
|
-
return I && R.resetPeek(),
|
|
1198
|
+
}, G = F();
|
|
1199
|
+
return I && R.resetPeek(), G;
|
|
1200
1200
|
}
|
|
1201
|
-
function
|
|
1201
|
+
function me(R, I) {
|
|
1202
1202
|
const F = R.currentChar();
|
|
1203
1203
|
return F === EOF ? EOF : I(F) ? (R.next(), F) : null;
|
|
1204
1204
|
}
|
|
1205
|
-
function
|
|
1206
|
-
return
|
|
1207
|
-
const
|
|
1208
|
-
return
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1205
|
+
function Oe(R) {
|
|
1206
|
+
return me(R, (F) => {
|
|
1207
|
+
const G = F.charCodeAt(0);
|
|
1208
|
+
return G >= 97 && G <= 122 || // a-z
|
|
1209
|
+
G >= 65 && G <= 90 || // A-Z
|
|
1210
|
+
G >= 48 && G <= 57 || // 0-9
|
|
1211
|
+
G === 95 || // _
|
|
1212
|
+
G === 36;
|
|
1213
1213
|
});
|
|
1214
1214
|
}
|
|
1215
1215
|
function Ae(R) {
|
|
1216
|
-
return
|
|
1217
|
-
const
|
|
1218
|
-
return
|
|
1216
|
+
return me(R, (F) => {
|
|
1217
|
+
const G = F.charCodeAt(0);
|
|
1218
|
+
return G >= 48 && G <= 57;
|
|
1219
1219
|
});
|
|
1220
1220
|
}
|
|
1221
1221
|
function Ce(R) {
|
|
1222
|
-
return
|
|
1223
|
-
const
|
|
1224
|
-
return
|
|
1225
|
-
|
|
1226
|
-
|
|
1222
|
+
return me(R, (F) => {
|
|
1223
|
+
const G = F.charCodeAt(0);
|
|
1224
|
+
return G >= 48 && G <= 57 || // 0-9
|
|
1225
|
+
G >= 65 && G <= 70 || // A-F
|
|
1226
|
+
G >= 97 && G <= 102;
|
|
1227
1227
|
});
|
|
1228
1228
|
}
|
|
1229
1229
|
function Ee(R) {
|
|
@@ -1233,7 +1233,7 @@ function createTokenizer(e, t = {}) {
|
|
|
1233
1233
|
return F;
|
|
1234
1234
|
}
|
|
1235
1235
|
function Re(R) {
|
|
1236
|
-
|
|
1236
|
+
ne(R);
|
|
1237
1237
|
const I = R.currentChar();
|
|
1238
1238
|
return I !== "%" && U(CompileErrorCodes.EXPECTED_TOKEN, l(), 0, I), R.next(), "%";
|
|
1239
1239
|
}
|
|
@@ -1252,7 +1252,7 @@ function createTokenizer(e, t = {}) {
|
|
|
1252
1252
|
if (de(R))
|
|
1253
1253
|
I += F, R.next();
|
|
1254
1254
|
else {
|
|
1255
|
-
if (
|
|
1255
|
+
if (Q(R))
|
|
1256
1256
|
break;
|
|
1257
1257
|
I += F, R.next();
|
|
1258
1258
|
}
|
|
@@ -1262,22 +1262,22 @@ function createTokenizer(e, t = {}) {
|
|
|
1262
1262
|
return I;
|
|
1263
1263
|
}
|
|
1264
1264
|
function Fe(R) {
|
|
1265
|
-
|
|
1265
|
+
ne(R);
|
|
1266
1266
|
let I = "", F = "";
|
|
1267
|
-
for (; I =
|
|
1267
|
+
for (; I = Oe(R); )
|
|
1268
1268
|
F += I;
|
|
1269
1269
|
return R.currentChar() === EOF && U(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE, l(), 0), F;
|
|
1270
1270
|
}
|
|
1271
1271
|
function ke(R) {
|
|
1272
|
-
|
|
1272
|
+
ne(R);
|
|
1273
1273
|
let I = "";
|
|
1274
1274
|
return R.currentChar() === "-" ? (R.next(), I += `-${Ee(R)}`) : I += Ee(R), R.currentChar() === EOF && U(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE, l(), 0), I;
|
|
1275
1275
|
}
|
|
1276
1276
|
function he(R) {
|
|
1277
|
-
|
|
1277
|
+
ne(R), ce(R, "'");
|
|
1278
1278
|
let I = "", F = "";
|
|
1279
|
-
const
|
|
1280
|
-
for (; I =
|
|
1279
|
+
const G = (K) => K !== LITERAL_DELIMITER && K !== CHAR_LF;
|
|
1280
|
+
for (; I = me(R, G); )
|
|
1281
1281
|
I === "\\" ? F += Le(R) : F += I;
|
|
1282
1282
|
const j = R.currentChar();
|
|
1283
1283
|
return j === CHAR_LF || j === EOF ? (U(CompileErrorCodes.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER, l(), 0), j === CHAR_LF && (R.next(), ce(R, "'")), F) : (ce(R, "'"), F);
|
|
@@ -1298,46 +1298,46 @@ function createTokenizer(e, t = {}) {
|
|
|
1298
1298
|
}
|
|
1299
1299
|
function fe(R, I, F) {
|
|
1300
1300
|
ce(R, I);
|
|
1301
|
-
let
|
|
1301
|
+
let G = "";
|
|
1302
1302
|
for (let j = 0; j < F; j++) {
|
|
1303
1303
|
const K = Ce(R);
|
|
1304
1304
|
if (!K) {
|
|
1305
|
-
U(CompileErrorCodes.INVALID_UNICODE_ESCAPE_SEQUENCE, l(), 0, `\\${I}${
|
|
1305
|
+
U(CompileErrorCodes.INVALID_UNICODE_ESCAPE_SEQUENCE, l(), 0, `\\${I}${G}${R.currentChar()}`);
|
|
1306
1306
|
break;
|
|
1307
1307
|
}
|
|
1308
|
-
|
|
1308
|
+
G += K;
|
|
1309
1309
|
}
|
|
1310
|
-
return `\\${I}${
|
|
1310
|
+
return `\\${I}${G}`;
|
|
1311
1311
|
}
|
|
1312
1312
|
function Pe(R) {
|
|
1313
|
-
|
|
1313
|
+
ne(R);
|
|
1314
1314
|
let I = "", F = "";
|
|
1315
|
-
const
|
|
1316
|
-
for (; I =
|
|
1315
|
+
const G = (j) => j !== "{" && j !== "}" && j !== CHAR_SP && j !== CHAR_LF;
|
|
1316
|
+
for (; I = me(R, G); )
|
|
1317
1317
|
F += I;
|
|
1318
1318
|
return F;
|
|
1319
1319
|
}
|
|
1320
1320
|
function Me(R) {
|
|
1321
1321
|
let I = "", F = "";
|
|
1322
|
-
for (; I =
|
|
1322
|
+
for (; I = Oe(R); )
|
|
1323
1323
|
F += I;
|
|
1324
1324
|
return F;
|
|
1325
1325
|
}
|
|
1326
1326
|
function De(R) {
|
|
1327
|
-
const I = (F = !1,
|
|
1327
|
+
const I = (F = !1, G) => {
|
|
1328
1328
|
const j = R.currentChar();
|
|
1329
|
-
return j === "{" || j === "%" || j === "@" || j === "|" || j === "(" || j === ")" || !j || j === CHAR_SP ?
|
|
1329
|
+
return j === "{" || j === "%" || j === "@" || j === "|" || j === "(" || j === ")" || !j || j === CHAR_SP ? G : j === CHAR_LF || j === DOT ? (G += j, R.next(), I(F, G)) : (G += j, R.next(), I(!0, G));
|
|
1330
1330
|
};
|
|
1331
1331
|
return I(!1, "");
|
|
1332
1332
|
}
|
|
1333
1333
|
function Ie(R) {
|
|
1334
|
-
|
|
1334
|
+
ne(R);
|
|
1335
1335
|
const I = ce(
|
|
1336
1336
|
R,
|
|
1337
1337
|
"|"
|
|
1338
1338
|
/* TokenChars.Pipe */
|
|
1339
1339
|
);
|
|
1340
|
-
return
|
|
1340
|
+
return ne(R), I;
|
|
1341
1341
|
}
|
|
1342
1342
|
function be(R, I) {
|
|
1343
1343
|
let F = null;
|
|
@@ -1348,30 +1348,30 @@ function createTokenizer(e, t = {}) {
|
|
|
1348
1348
|
2,
|
|
1349
1349
|
"{"
|
|
1350
1350
|
/* TokenChars.BraceLeft */
|
|
1351
|
-
),
|
|
1351
|
+
), ne(R), I.braceNest++, F;
|
|
1352
1352
|
case "}":
|
|
1353
1353
|
return I.braceNest > 0 && I.currentType === 2 && U(CompileErrorCodes.EMPTY_PLACEHOLDER, l(), 0), R.next(), F = V(
|
|
1354
1354
|
I,
|
|
1355
1355
|
3,
|
|
1356
1356
|
"}"
|
|
1357
1357
|
/* TokenChars.BraceRight */
|
|
1358
|
-
), I.braceNest--, I.braceNest > 0 &&
|
|
1358
|
+
), I.braceNest--, I.braceNest > 0 && ne(R), I.inLinked && I.braceNest === 0 && (I.inLinked = !1), F;
|
|
1359
1359
|
case "@":
|
|
1360
|
-
return I.braceNest > 0 && U(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE, l(), 0), F = D(R, I) ||
|
|
1360
|
+
return I.braceNest > 0 && U(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE, l(), 0), F = D(R, I) || X(I), I.braceNest = 0, F;
|
|
1361
1361
|
default: {
|
|
1362
1362
|
let j = !0, K = !0, Z = !0;
|
|
1363
|
-
if (
|
|
1363
|
+
if (Q(R))
|
|
1364
1364
|
return I.braceNest > 0 && U(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE, l(), 0), F = V(I, 1, Ie(R)), I.braceNest = 0, I.inLinked = !1, F;
|
|
1365
1365
|
if (I.braceNest > 0 && (I.currentType === 5 || I.currentType === 6 || I.currentType === 7))
|
|
1366
1366
|
return U(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE, l(), 0), I.braceNest = 0, M(R, I);
|
|
1367
|
-
if (j =
|
|
1368
|
-
return F = V(I, 5, Fe(R)),
|
|
1369
|
-
if (K =
|
|
1370
|
-
return F = V(I, 6, ke(R)),
|
|
1371
|
-
if (Z =
|
|
1372
|
-
return F = V(I, 7, he(R)),
|
|
1367
|
+
if (j = oe(R, I))
|
|
1368
|
+
return F = V(I, 5, Fe(R)), ne(R), F;
|
|
1369
|
+
if (K = re(R, I))
|
|
1370
|
+
return F = V(I, 6, ke(R)), ne(R), F;
|
|
1371
|
+
if (Z = ae(R, I))
|
|
1372
|
+
return F = V(I, 7, he(R)), ne(R), F;
|
|
1373
1373
|
if (!j && !K && !Z)
|
|
1374
|
-
return F = V(I, 13, Pe(R)), U(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER, l(), 0, F.value),
|
|
1374
|
+
return F = V(I, 13, Pe(R)), U(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER, l(), 0, F.value), ne(R), F;
|
|
1375
1375
|
break;
|
|
1376
1376
|
}
|
|
1377
1377
|
}
|
|
@@ -1379,32 +1379,32 @@ function createTokenizer(e, t = {}) {
|
|
|
1379
1379
|
}
|
|
1380
1380
|
function D(R, I) {
|
|
1381
1381
|
const { currentType: F } = I;
|
|
1382
|
-
let
|
|
1382
|
+
let G = null;
|
|
1383
1383
|
const j = R.currentChar();
|
|
1384
1384
|
switch ((F === 8 || F === 9 || F === 12 || F === 10) && (j === CHAR_LF || j === CHAR_SP) && U(CompileErrorCodes.INVALID_LINKED_FORMAT, l(), 0), j) {
|
|
1385
1385
|
case "@":
|
|
1386
|
-
return R.next(),
|
|
1386
|
+
return R.next(), G = V(
|
|
1387
1387
|
I,
|
|
1388
1388
|
8,
|
|
1389
1389
|
"@"
|
|
1390
1390
|
/* TokenChars.LinkedAlias */
|
|
1391
|
-
), I.inLinked = !0,
|
|
1391
|
+
), I.inLinked = !0, G;
|
|
1392
1392
|
case ".":
|
|
1393
|
-
return
|
|
1393
|
+
return ne(R), R.next(), V(
|
|
1394
1394
|
I,
|
|
1395
1395
|
9,
|
|
1396
1396
|
"."
|
|
1397
1397
|
/* TokenChars.LinkedDot */
|
|
1398
1398
|
);
|
|
1399
1399
|
case ":":
|
|
1400
|
-
return
|
|
1400
|
+
return ne(R), R.next(), V(
|
|
1401
1401
|
I,
|
|
1402
1402
|
10,
|
|
1403
1403
|
":"
|
|
1404
1404
|
/* TokenChars.LinkedDelimiter */
|
|
1405
1405
|
);
|
|
1406
1406
|
default:
|
|
1407
|
-
return
|
|
1407
|
+
return Q(R) ? (G = V(I, 1, Ie(R)), I.braceNest = 0, I.inLinked = !1, G) : te(R, I) || H(R, I) ? (ne(R), D(R, I)) : ie(R, I) ? (ne(R), V(I, 12, Me(R))) : $(R, I) ? (ne(R), j === "{" ? be(R, I) || G : V(I, 11, De(R))) : (F === 8 && U(CompileErrorCodes.INVALID_LINKED_FORMAT, l(), 0), I.braceNest = 0, I.inLinked = !1, M(R, I));
|
|
1408
1408
|
}
|
|
1409
1409
|
}
|
|
1410
1410
|
function M(R, I) {
|
|
@@ -1413,12 +1413,12 @@ function createTokenizer(e, t = {}) {
|
|
|
1413
1413
|
/* TokenTypes.EOF */
|
|
1414
1414
|
};
|
|
1415
1415
|
if (I.braceNest > 0)
|
|
1416
|
-
return be(R, I) ||
|
|
1416
|
+
return be(R, I) || X(I);
|
|
1417
1417
|
if (I.inLinked)
|
|
1418
|
-
return D(R, I) ||
|
|
1418
|
+
return D(R, I) || X(I);
|
|
1419
1419
|
switch (R.currentChar()) {
|
|
1420
1420
|
case "{":
|
|
1421
|
-
return be(R, I) ||
|
|
1421
|
+
return be(R, I) || X(I);
|
|
1422
1422
|
case "}":
|
|
1423
1423
|
return U(CompileErrorCodes.UNBALANCED_CLOSING_BRACE, l(), 0), R.next(), V(
|
|
1424
1424
|
I,
|
|
@@ -1427,9 +1427,9 @@ function createTokenizer(e, t = {}) {
|
|
|
1427
1427
|
/* TokenChars.BraceRight */
|
|
1428
1428
|
);
|
|
1429
1429
|
case "@":
|
|
1430
|
-
return D(R, I) ||
|
|
1430
|
+
return D(R, I) || X(I);
|
|
1431
1431
|
default: {
|
|
1432
|
-
if (
|
|
1432
|
+
if (Q(R))
|
|
1433
1433
|
return F = V(I, 1, Ie(R)), I.braceNest = 0, I.inLinked = !1, F;
|
|
1434
1434
|
const { isModulo: j, hasSpace: K } = pe(R);
|
|
1435
1435
|
if (j)
|
|
@@ -1442,8 +1442,8 @@ function createTokenizer(e, t = {}) {
|
|
|
1442
1442
|
return F;
|
|
1443
1443
|
}
|
|
1444
1444
|
function W() {
|
|
1445
|
-
const { currentType: R, offset: I, startLoc: F, endLoc:
|
|
1446
|
-
return L.lastType = R, L.lastOffset = I, L.lastStartLoc = F, L.lastEndLoc =
|
|
1445
|
+
const { currentType: R, offset: I, startLoc: F, endLoc: G } = L;
|
|
1446
|
+
return L.lastType = R, L.lastOffset = I, L.lastStartLoc = F, L.lastEndLoc = G, L.offset = c(), L.startLoc = l(), s.currentChar() === EOF ? V(
|
|
1447
1447
|
L,
|
|
1448
1448
|
14
|
|
1449
1449
|
/* TokenTypes.EOF */
|
|
@@ -1471,134 +1471,134 @@ function fromEscapeSequence(e, t, n) {
|
|
|
1471
1471
|
}
|
|
1472
1472
|
function createParser(e = {}) {
|
|
1473
1473
|
const t = e.location !== !1, { onError: n } = e;
|
|
1474
|
-
function s(
|
|
1475
|
-
const
|
|
1476
|
-
if (
|
|
1477
|
-
const ie = t ? createLocation(
|
|
1474
|
+
function s(q, Y, oe, re, ...ae) {
|
|
1475
|
+
const te = q.currentPosition();
|
|
1476
|
+
if (te.offset += re, te.column += re, n) {
|
|
1477
|
+
const ie = t ? createLocation(oe, te) : null, H = createCompileError(Y, ie, {
|
|
1478
1478
|
domain: ERROR_DOMAIN$2,
|
|
1479
|
-
args:
|
|
1479
|
+
args: ae
|
|
1480
1480
|
});
|
|
1481
|
-
n(
|
|
1481
|
+
n(H);
|
|
1482
1482
|
}
|
|
1483
1483
|
}
|
|
1484
|
-
function c(
|
|
1485
|
-
const
|
|
1486
|
-
return t && (
|
|
1484
|
+
function c(q, Y, oe) {
|
|
1485
|
+
const re = { type: q };
|
|
1486
|
+
return t && (re.start = Y, re.end = Y, re.loc = { start: oe, end: oe }), re;
|
|
1487
1487
|
}
|
|
1488
|
-
function l(
|
|
1489
|
-
|
|
1488
|
+
function l(q, Y, oe, re) {
|
|
1489
|
+
re && (q.type = re), t && (q.end = Y, q.loc && (q.loc.end = oe));
|
|
1490
1490
|
}
|
|
1491
|
-
function C(
|
|
1492
|
-
const
|
|
1493
|
-
return
|
|
1491
|
+
function C(q, Y) {
|
|
1492
|
+
const oe = q.context(), re = c(3, oe.offset, oe.startLoc);
|
|
1493
|
+
return re.value = Y, l(re, q.currentOffset(), q.currentPosition()), re;
|
|
1494
1494
|
}
|
|
1495
|
-
function A(
|
|
1496
|
-
const
|
|
1497
|
-
return
|
|
1495
|
+
function A(q, Y) {
|
|
1496
|
+
const oe = q.context(), { lastOffset: re, lastStartLoc: ae } = oe, te = c(5, re, ae);
|
|
1497
|
+
return te.index = parseInt(Y, 10), q.nextToken(), l(te, q.currentOffset(), q.currentPosition()), te;
|
|
1498
1498
|
}
|
|
1499
|
-
function L(
|
|
1500
|
-
const
|
|
1501
|
-
return
|
|
1499
|
+
function L(q, Y) {
|
|
1500
|
+
const oe = q.context(), { lastOffset: re, lastStartLoc: ae } = oe, te = c(4, re, ae);
|
|
1501
|
+
return te.key = Y, q.nextToken(), l(te, q.currentOffset(), q.currentPosition()), te;
|
|
1502
1502
|
}
|
|
1503
|
-
function B(
|
|
1504
|
-
const
|
|
1505
|
-
return
|
|
1503
|
+
function B(q, Y) {
|
|
1504
|
+
const oe = q.context(), { lastOffset: re, lastStartLoc: ae } = oe, te = c(9, re, ae);
|
|
1505
|
+
return te.value = Y.replace(KNOWN_ESCAPES, fromEscapeSequence), q.nextToken(), l(te, q.currentOffset(), q.currentPosition()), te;
|
|
1506
1506
|
}
|
|
1507
|
-
function q
|
|
1508
|
-
const
|
|
1509
|
-
return
|
|
1510
|
-
nextConsumeToken:
|
|
1511
|
-
node:
|
|
1512
|
-
}) : (
|
|
1513
|
-
node:
|
|
1507
|
+
function J(q) {
|
|
1508
|
+
const Y = q.nextToken(), oe = q.context(), { lastOffset: re, lastStartLoc: ae } = oe, te = c(8, re, ae);
|
|
1509
|
+
return Y.type !== 12 ? (s(q, CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_MODIFIER, oe.lastStartLoc, 0), te.value = "", l(te, re, ae), {
|
|
1510
|
+
nextConsumeToken: Y,
|
|
1511
|
+
node: te
|
|
1512
|
+
}) : (Y.value == null && s(q, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, oe.lastStartLoc, 0, getTokenCaption(Y)), te.value = Y.value || "", l(te, q.currentOffset(), q.currentPosition()), {
|
|
1513
|
+
node: te
|
|
1514
1514
|
});
|
|
1515
1515
|
}
|
|
1516
|
-
function U(
|
|
1517
|
-
const
|
|
1518
|
-
return
|
|
1516
|
+
function U(q, Y) {
|
|
1517
|
+
const oe = q.context(), re = c(7, oe.offset, oe.startLoc);
|
|
1518
|
+
return re.value = Y, l(re, q.currentOffset(), q.currentPosition()), re;
|
|
1519
1519
|
}
|
|
1520
|
-
function V(
|
|
1521
|
-
const
|
|
1522
|
-
let
|
|
1523
|
-
if (
|
|
1524
|
-
const
|
|
1525
|
-
|
|
1520
|
+
function V(q) {
|
|
1521
|
+
const Y = q.context(), oe = c(6, Y.offset, Y.startLoc);
|
|
1522
|
+
let re = q.nextToken();
|
|
1523
|
+
if (re.type === 9) {
|
|
1524
|
+
const ae = J(q);
|
|
1525
|
+
oe.modifier = ae.node, re = ae.nextConsumeToken || q.nextToken();
|
|
1526
1526
|
}
|
|
1527
|
-
switch (
|
|
1527
|
+
switch (re.type !== 10 && s(q, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, Y.lastStartLoc, 0, getTokenCaption(re)), re = q.nextToken(), re.type === 2 && (re = q.nextToken()), re.type) {
|
|
1528
1528
|
case 11:
|
|
1529
|
-
|
|
1529
|
+
re.value == null && s(q, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, Y.lastStartLoc, 0, getTokenCaption(re)), oe.key = U(q, re.value || "");
|
|
1530
1530
|
break;
|
|
1531
1531
|
case 5:
|
|
1532
|
-
|
|
1532
|
+
re.value == null && s(q, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, Y.lastStartLoc, 0, getTokenCaption(re)), oe.key = L(q, re.value || "");
|
|
1533
1533
|
break;
|
|
1534
1534
|
case 6:
|
|
1535
|
-
|
|
1535
|
+
re.value == null && s(q, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, Y.lastStartLoc, 0, getTokenCaption(re)), oe.key = A(q, re.value || "");
|
|
1536
1536
|
break;
|
|
1537
1537
|
case 7:
|
|
1538
|
-
|
|
1538
|
+
re.value == null && s(q, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, Y.lastStartLoc, 0, getTokenCaption(re)), oe.key = B(q, re.value || "");
|
|
1539
1539
|
break;
|
|
1540
1540
|
default: {
|
|
1541
|
-
s(
|
|
1542
|
-
const
|
|
1543
|
-
return
|
|
1544
|
-
nextConsumeToken:
|
|
1545
|
-
node:
|
|
1541
|
+
s(q, CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_KEY, Y.lastStartLoc, 0);
|
|
1542
|
+
const ae = q.context(), te = c(7, ae.offset, ae.startLoc);
|
|
1543
|
+
return te.value = "", l(te, ae.offset, ae.startLoc), oe.key = te, l(oe, ae.offset, ae.startLoc), {
|
|
1544
|
+
nextConsumeToken: re,
|
|
1545
|
+
node: oe
|
|
1546
1546
|
};
|
|
1547
1547
|
}
|
|
1548
1548
|
}
|
|
1549
|
-
return l(
|
|
1550
|
-
node:
|
|
1549
|
+
return l(oe, q.currentOffset(), q.currentPosition()), {
|
|
1550
|
+
node: oe
|
|
1551
1551
|
};
|
|
1552
1552
|
}
|
|
1553
|
-
function
|
|
1554
|
-
const
|
|
1555
|
-
|
|
1556
|
-
let
|
|
1553
|
+
function X(q) {
|
|
1554
|
+
const Y = q.context(), oe = Y.currentType === 1 ? q.currentOffset() : Y.offset, re = Y.currentType === 1 ? Y.endLoc : Y.startLoc, ae = c(2, oe, re);
|
|
1555
|
+
ae.items = [];
|
|
1556
|
+
let te = null;
|
|
1557
1557
|
do {
|
|
1558
|
-
const $ =
|
|
1559
|
-
switch (
|
|
1558
|
+
const $ = te || q.nextToken();
|
|
1559
|
+
switch (te = null, $.type) {
|
|
1560
1560
|
case 0:
|
|
1561
|
-
$.value == null && s(
|
|
1561
|
+
$.value == null && s(q, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, Y.lastStartLoc, 0, getTokenCaption($)), ae.items.push(C(q, $.value || ""));
|
|
1562
1562
|
break;
|
|
1563
1563
|
case 6:
|
|
1564
|
-
$.value == null && s(
|
|
1564
|
+
$.value == null && s(q, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, Y.lastStartLoc, 0, getTokenCaption($)), ae.items.push(A(q, $.value || ""));
|
|
1565
1565
|
break;
|
|
1566
1566
|
case 5:
|
|
1567
|
-
$.value == null && s(
|
|
1567
|
+
$.value == null && s(q, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, Y.lastStartLoc, 0, getTokenCaption($)), ae.items.push(L(q, $.value || ""));
|
|
1568
1568
|
break;
|
|
1569
1569
|
case 7:
|
|
1570
|
-
$.value == null && s(
|
|
1570
|
+
$.value == null && s(q, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, Y.lastStartLoc, 0, getTokenCaption($)), ae.items.push(B(q, $.value || ""));
|
|
1571
1571
|
break;
|
|
1572
1572
|
case 8: {
|
|
1573
|
-
const
|
|
1574
|
-
|
|
1573
|
+
const Q = V(q);
|
|
1574
|
+
ae.items.push(Q.node), te = Q.nextConsumeToken || null;
|
|
1575
1575
|
break;
|
|
1576
1576
|
}
|
|
1577
1577
|
}
|
|
1578
|
-
} while (
|
|
1579
|
-
const ie =
|
|
1580
|
-
return l(
|
|
1581
|
-
}
|
|
1582
|
-
function ce(
|
|
1583
|
-
const
|
|
1584
|
-
let
|
|
1585
|
-
const ie = c(1,
|
|
1586
|
-
ie.cases = [], ie.cases.push(
|
|
1578
|
+
} while (Y.currentType !== 14 && Y.currentType !== 1);
|
|
1579
|
+
const ie = Y.currentType === 1 ? Y.lastOffset : q.currentOffset(), H = Y.currentType === 1 ? Y.lastEndLoc : q.currentPosition();
|
|
1580
|
+
return l(ae, ie, H), ae;
|
|
1581
|
+
}
|
|
1582
|
+
function ce(q, Y, oe, re) {
|
|
1583
|
+
const ae = q.context();
|
|
1584
|
+
let te = re.items.length === 0;
|
|
1585
|
+
const ie = c(1, Y, oe);
|
|
1586
|
+
ie.cases = [], ie.cases.push(re);
|
|
1587
1587
|
do {
|
|
1588
|
-
const
|
|
1589
|
-
|
|
1590
|
-
} while (
|
|
1591
|
-
return
|
|
1588
|
+
const H = X(q);
|
|
1589
|
+
te || (te = H.items.length === 0), ie.cases.push(H);
|
|
1590
|
+
} while (ae.currentType !== 14);
|
|
1591
|
+
return te && s(q, CompileErrorCodes.MUST_HAVE_MESSAGES_IN_PLURAL, oe, 0), l(ie, q.currentOffset(), q.currentPosition()), ie;
|
|
1592
1592
|
}
|
|
1593
|
-
function se(
|
|
1594
|
-
const
|
|
1595
|
-
return
|
|
1593
|
+
function se(q) {
|
|
1594
|
+
const Y = q.context(), { offset: oe, startLoc: re } = Y, ae = X(q);
|
|
1595
|
+
return Y.currentType === 14 ? ae : ce(q, oe, re, ae);
|
|
1596
1596
|
}
|
|
1597
|
-
function
|
|
1598
|
-
const
|
|
1599
|
-
return t &&
|
|
1597
|
+
function ne(q) {
|
|
1598
|
+
const Y = createTokenizer(q, assign({}, e)), oe = Y.context(), re = c(0, oe.offset, oe.startLoc);
|
|
1599
|
+
return t && re.loc && (re.loc.source = q), re.body = se(Y), e.onCacheKey && (re.cacheKey = e.onCacheKey(q)), oe.currentType !== 14 && s(Y, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, oe.lastStartLoc, 0, q[oe.offset] || ""), l(re, Y.currentOffset(), Y.currentPosition()), re;
|
|
1600
1600
|
}
|
|
1601
|
-
return { parse:
|
|
1601
|
+
return { parse: ne };
|
|
1602
1602
|
}
|
|
1603
1603
|
function getTokenCaption(e) {
|
|
1604
1604
|
if (e.type === 14)
|
|
@@ -1760,31 +1760,31 @@ function createCodeGenerator(e, t) {
|
|
|
1760
1760
|
};
|
|
1761
1761
|
C && e.loc && (A.source = e.loc.source);
|
|
1762
1762
|
const L = () => A;
|
|
1763
|
-
function B(
|
|
1764
|
-
A.code +=
|
|
1763
|
+
function B(ne, q) {
|
|
1764
|
+
A.code += ne;
|
|
1765
1765
|
}
|
|
1766
|
-
function
|
|
1767
|
-
const
|
|
1768
|
-
B(l ?
|
|
1766
|
+
function J(ne, q = !0) {
|
|
1767
|
+
const Y = q ? c : "";
|
|
1768
|
+
B(l ? Y + " ".repeat(ne) : Y);
|
|
1769
1769
|
}
|
|
1770
|
-
function U(
|
|
1771
|
-
const
|
|
1772
|
-
|
|
1770
|
+
function U(ne = !0) {
|
|
1771
|
+
const q = ++A.indentLevel;
|
|
1772
|
+
ne && J(q);
|
|
1773
1773
|
}
|
|
1774
|
-
function V(
|
|
1775
|
-
const
|
|
1776
|
-
|
|
1774
|
+
function V(ne = !0) {
|
|
1775
|
+
const q = --A.indentLevel;
|
|
1776
|
+
ne && J(q);
|
|
1777
1777
|
}
|
|
1778
|
-
function
|
|
1779
|
-
|
|
1778
|
+
function X() {
|
|
1779
|
+
J(A.indentLevel);
|
|
1780
1780
|
}
|
|
1781
1781
|
return {
|
|
1782
1782
|
context: L,
|
|
1783
1783
|
push: B,
|
|
1784
1784
|
indent: U,
|
|
1785
1785
|
deindent: V,
|
|
1786
|
-
newline:
|
|
1787
|
-
helper: (
|
|
1786
|
+
newline: X,
|
|
1787
|
+
helper: (ne) => `_${ne}`,
|
|
1788
1788
|
needIndent: () => A.needIndent
|
|
1789
1789
|
};
|
|
1790
1790
|
}
|
|
@@ -1884,11 +1884,11 @@ const generate = (e, t = {}) => {
|
|
|
1884
1884
|
needIndent: C
|
|
1885
1885
|
});
|
|
1886
1886
|
L.push(n === "normal" ? "function __msg__ (ctx) {" : "(ctx) => {"), L.indent(C), A.length > 0 && (L.push(`const { ${join(A.map((U) => `${U}: _${U}`), ", ")} } = ctx`), L.newline()), L.push("return "), generateNode(L, e), L.deindent(C), L.push("}"), delete e.helpers;
|
|
1887
|
-
const { code: B, map:
|
|
1887
|
+
const { code: B, map: J } = L.context();
|
|
1888
1888
|
return {
|
|
1889
1889
|
ast: e,
|
|
1890
1890
|
code: B,
|
|
1891
|
-
map:
|
|
1891
|
+
map: J ? J.toJSON() : void 0
|
|
1892
1892
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
1893
1893
|
};
|
|
1894
1894
|
};
|
|
@@ -2104,7 +2104,7 @@ function formatSubPath(e) {
|
|
|
2104
2104
|
}
|
|
2105
2105
|
function parse$1(e) {
|
|
2106
2106
|
const t = [];
|
|
2107
|
-
let n = -1, s = 0, c = 0, l, C, A, L, B,
|
|
2107
|
+
let n = -1, s = 0, c = 0, l, C, A, L, B, J, U;
|
|
2108
2108
|
const V = [];
|
|
2109
2109
|
V[
|
|
2110
2110
|
0
|
|
@@ -2142,7 +2142,7 @@ function parse$1(e) {
|
|
|
2142
2142
|
]();
|
|
2143
2143
|
}
|
|
2144
2144
|
};
|
|
2145
|
-
function
|
|
2145
|
+
function X() {
|
|
2146
2146
|
const ce = e[n + 1];
|
|
2147
2147
|
if (s === 5 && ce === "'" || s === 6 && ce === '"')
|
|
2148
2148
|
return n++, A = "\\" + ce, V[
|
|
@@ -2151,8 +2151,8 @@ function parse$1(e) {
|
|
|
2151
2151
|
](), !0;
|
|
2152
2152
|
}
|
|
2153
2153
|
for (; s !== null; )
|
|
2154
|
-
if (n++, l = e[n], !(l === "\\" &&
|
|
2155
|
-
if (L = getPathCharType(l), U = pathStateMachine[s], B = U[L] || U.l || 8, B === 8 || (s = B[0], B[1] !== void 0 && (
|
|
2154
|
+
if (n++, l = e[n], !(l === "\\" && X())) {
|
|
2155
|
+
if (L = getPathCharType(l), U = pathStateMachine[s], B = U[L] || U.l || 8, B === 8 || (s = B[0], B[1] !== void 0 && (J = V[B[1]], J && (A = l, J() === !1))))
|
|
2156
2156
|
return;
|
|
2157
2157
|
if (s === 7)
|
|
2158
2158
|
return t;
|
|
@@ -2190,34 +2190,34 @@ function normalizeNamed(e, t) {
|
|
|
2190
2190
|
t.count || (t.count = e), t.n || (t.n = e);
|
|
2191
2191
|
}
|
|
2192
2192
|
function createMessageContext(e = {}) {
|
|
2193
|
-
const t = e.locale, n = getPluralIndex(e), s = isObject$2(e.pluralRules) && isString$2(t) && isFunction$1(e.pluralRules[t]) ? e.pluralRules[t] : pluralDefault, c = isObject$2(e.pluralRules) && isString$2(t) && isFunction$1(e.pluralRules[t]) ? pluralDefault : void 0, l = (
|
|
2193
|
+
const t = e.locale, n = getPluralIndex(e), s = isObject$2(e.pluralRules) && isString$2(t) && isFunction$1(e.pluralRules[t]) ? e.pluralRules[t] : pluralDefault, c = isObject$2(e.pluralRules) && isString$2(t) && isFunction$1(e.pluralRules[t]) ? pluralDefault : void 0, l = (q) => q[s(n, q.length, c)], C = e.list || [], A = (q) => C[q], L = e.named || {};
|
|
2194
2194
|
isNumber(e.pluralIndex) && normalizeNamed(n, L);
|
|
2195
|
-
const B = (
|
|
2196
|
-
function q
|
|
2197
|
-
const
|
|
2198
|
-
return
|
|
2195
|
+
const B = (q) => L[q];
|
|
2196
|
+
function J(q) {
|
|
2197
|
+
const Y = isFunction$1(e.messages) ? e.messages(q) : isObject$2(e.messages) ? e.messages[q] : !1;
|
|
2198
|
+
return Y || (e.parent ? e.parent.message(q) : DEFAULT_MESSAGE);
|
|
2199
2199
|
}
|
|
2200
|
-
const U = (
|
|
2200
|
+
const U = (q) => e.modifiers ? e.modifiers[q] : DEFAULT_MODIFIER, V = isPlainObject$1(e.processor) && isFunction$1(e.processor.normalize) ? e.processor.normalize : DEFAULT_NORMALIZE, X = isPlainObject$1(e.processor) && isFunction$1(e.processor.interpolate) ? e.processor.interpolate : DEFAULT_INTERPOLATE, ce = isPlainObject$1(e.processor) && isString$2(e.processor.type) ? e.processor.type : DEFAULT_MESSAGE_DATA_TYPE, ne = {
|
|
2201
2201
|
list: A,
|
|
2202
2202
|
named: B,
|
|
2203
2203
|
plural: l,
|
|
2204
|
-
linked: (
|
|
2205
|
-
const [
|
|
2206
|
-
let
|
|
2207
|
-
|
|
2208
|
-
const ie = q
|
|
2204
|
+
linked: (q, ...Y) => {
|
|
2205
|
+
const [oe, re] = Y;
|
|
2206
|
+
let ae = "text", te = "";
|
|
2207
|
+
Y.length === 1 ? isObject$2(oe) ? (te = oe.modifier || te, ae = oe.type || ae) : isString$2(oe) && (te = oe || te) : Y.length === 2 && (isString$2(oe) && (te = oe || te), isString$2(re) && (ae = re || ae));
|
|
2208
|
+
const ie = J(q)(ne), H = (
|
|
2209
2209
|
// The message in vnode resolved with linked are returned as an array by processor.nomalize
|
|
2210
|
-
|
|
2210
|
+
ae === "vnode" && isArray$1(ie) && te ? ie[0] : ie
|
|
2211
2211
|
);
|
|
2212
|
-
return
|
|
2212
|
+
return te ? U(te)(H, ae) : H;
|
|
2213
2213
|
},
|
|
2214
|
-
message:
|
|
2214
|
+
message: J,
|
|
2215
2215
|
type: ce,
|
|
2216
|
-
interpolate:
|
|
2216
|
+
interpolate: X,
|
|
2217
2217
|
normalize: V,
|
|
2218
2218
|
values: assign$1({}, C, L)
|
|
2219
2219
|
};
|
|
2220
|
-
return
|
|
2220
|
+
return ne;
|
|
2221
2221
|
}
|
|
2222
2222
|
let devtools = null;
|
|
2223
2223
|
function setDevToolsHook(e) {
|
|
@@ -2385,9 +2385,9 @@ const setFallbackContext = (e) => {
|
|
|
2385
2385
|
}, getFallbackContext = () => _fallbackContext;
|
|
2386
2386
|
let _cid = 0;
|
|
2387
2387
|
function createCoreContext(e = {}) {
|
|
2388
|
-
const t = isFunction$1(e.onWarn) ? e.onWarn : warn$2, n = isString$2(e.version) ? e.version : VERSION$1, s = isString$2(e.locale) || isFunction$1(e.locale) ? e.locale : DEFAULT_LOCALE, c = isFunction$1(s) ? DEFAULT_LOCALE : s, l = isArray$1(e.fallbackLocale) || isPlainObject$1(e.fallbackLocale) || isString$2(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : c, C = isPlainObject$1(e.messages) ? e.messages : { [c]: {} }, A = isPlainObject$1(e.datetimeFormats) ? e.datetimeFormats : { [c]: {} }, L = isPlainObject$1(e.numberFormats) ? e.numberFormats : { [c]: {} }, B = assign$1({}, e.modifiers || {}, getDefaultLinkedModifiers()),
|
|
2388
|
+
const t = isFunction$1(e.onWarn) ? e.onWarn : warn$2, n = isString$2(e.version) ? e.version : VERSION$1, s = isString$2(e.locale) || isFunction$1(e.locale) ? e.locale : DEFAULT_LOCALE, c = isFunction$1(s) ? DEFAULT_LOCALE : s, l = isArray$1(e.fallbackLocale) || isPlainObject$1(e.fallbackLocale) || isString$2(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : c, C = isPlainObject$1(e.messages) ? e.messages : { [c]: {} }, A = isPlainObject$1(e.datetimeFormats) ? e.datetimeFormats : { [c]: {} }, L = isPlainObject$1(e.numberFormats) ? e.numberFormats : { [c]: {} }, B = assign$1({}, e.modifiers || {}, getDefaultLinkedModifiers()), J = e.pluralRules || {}, U = isFunction$1(e.missing) ? e.missing : null, V = isBoolean(e.missingWarn) || isRegExp(e.missingWarn) ? e.missingWarn : !0, X = isBoolean(e.fallbackWarn) || isRegExp(e.fallbackWarn) ? e.fallbackWarn : !0, ce = !!e.fallbackFormat, se = !!e.unresolving, ne = isFunction$1(e.postTranslation) ? e.postTranslation : null, q = isPlainObject$1(e.processor) ? e.processor : null, Y = isBoolean(e.warnHtmlMessage) ? e.warnHtmlMessage : !0, oe = !!e.escapeParameter, re = isFunction$1(e.messageCompiler) ? e.messageCompiler : _compiler;
|
|
2389
2389
|
process.env.NODE_ENV !== "production" && isFunction$1(e.messageCompiler) && warnOnce(getWarnMessage$1(CoreWarnCodes.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER));
|
|
2390
|
-
const
|
|
2390
|
+
const ae = isFunction$1(e.messageResolver) ? e.messageResolver : _resolver || resolveWithKeyValue, te = isFunction$1(e.localeFallbacker) ? e.localeFallbacker : _fallbacker || fallbackWithSimple, ie = isObject$2(e.fallbackContext) ? e.fallbackContext : void 0, H = e, $ = isObject$2(H.__datetimeFormatters) ? H.__datetimeFormatters : /* @__PURE__ */ new Map(), Q = isObject$2(H.__numberFormatters) ? H.__numberFormatters : /* @__PURE__ */ new Map(), pe = isObject$2(H.__meta) ? H.__meta : {};
|
|
2391
2391
|
_cid++;
|
|
2392
2392
|
const de = {
|
|
2393
2393
|
version: n,
|
|
@@ -2396,24 +2396,24 @@ function createCoreContext(e = {}) {
|
|
|
2396
2396
|
fallbackLocale: l,
|
|
2397
2397
|
messages: C,
|
|
2398
2398
|
modifiers: B,
|
|
2399
|
-
pluralRules:
|
|
2399
|
+
pluralRules: J,
|
|
2400
2400
|
missing: U,
|
|
2401
2401
|
missingWarn: V,
|
|
2402
|
-
fallbackWarn:
|
|
2402
|
+
fallbackWarn: X,
|
|
2403
2403
|
fallbackFormat: ce,
|
|
2404
2404
|
unresolving: se,
|
|
2405
|
-
postTranslation:
|
|
2406
|
-
processor:
|
|
2407
|
-
warnHtmlMessage:
|
|
2408
|
-
escapeParameter:
|
|
2409
|
-
messageCompiler:
|
|
2410
|
-
messageResolver:
|
|
2411
|
-
localeFallbacker:
|
|
2405
|
+
postTranslation: ne,
|
|
2406
|
+
processor: q,
|
|
2407
|
+
warnHtmlMessage: Y,
|
|
2408
|
+
escapeParameter: oe,
|
|
2409
|
+
messageCompiler: re,
|
|
2410
|
+
messageResolver: ae,
|
|
2411
|
+
localeFallbacker: te,
|
|
2412
2412
|
fallbackContext: ie,
|
|
2413
2413
|
onWarn: t,
|
|
2414
2414
|
__meta: pe
|
|
2415
2415
|
};
|
|
2416
|
-
return de.datetimeFormats = A, de.numberFormats = L, de.__datetimeFormatters = $, de.__numberFormatters =
|
|
2416
|
+
return de.datetimeFormats = A, de.numberFormats = L, de.__datetimeFormatters = $, de.__numberFormatters = Q, process.env.NODE_ENV !== "production" && (de.__v_emitter = H.__v_emitter != null ? H.__v_emitter : void 0), (process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__) && initI18nDevTools(de, n, pe), de;
|
|
2417
2417
|
}
|
|
2418
2418
|
function isTranslateFallbackWarn(e, t) {
|
|
2419
2419
|
return e instanceof RegExp ? e.test(t) : e;
|
|
@@ -2553,33 +2553,33 @@ function compile(e, t) {
|
|
|
2553
2553
|
}
|
|
2554
2554
|
const NOOP_MESSAGE_FUNCTION = () => "", isMessageFunction = (e) => isFunction$1(e);
|
|
2555
2555
|
function translate(e, ...t) {
|
|
2556
|
-
const { fallbackFormat: n, postTranslation: s, unresolving: c, messageCompiler: l, fallbackLocale: C, messages: A } = e, [L, B] = parseTranslateArgs(...t),
|
|
2556
|
+
const { fallbackFormat: n, postTranslation: s, unresolving: c, messageCompiler: l, fallbackLocale: C, messages: A } = e, [L, B] = parseTranslateArgs(...t), J = isBoolean(B.missingWarn) ? B.missingWarn : e.missingWarn, U = isBoolean(B.fallbackWarn) ? B.fallbackWarn : e.fallbackWarn, V = isBoolean(B.escapeParameter) ? B.escapeParameter : e.escapeParameter, X = !!B.resolvedMessage, ce = isString$2(B.default) || isBoolean(B.default) ? isBoolean(B.default) ? l ? L : () => L : B.default : n ? l ? L : () => L : "", se = n || ce !== "", ne = getLocale(e, B);
|
|
2557
2557
|
V && escapeParams(B);
|
|
2558
|
-
let [
|
|
2558
|
+
let [q, Y, oe] = X ? [
|
|
2559
2559
|
L,
|
|
2560
|
-
|
|
2561
|
-
A[
|
|
2562
|
-
] : resolveMessageFormat(e, L,
|
|
2563
|
-
if (!
|
|
2560
|
+
ne,
|
|
2561
|
+
A[ne] || {}
|
|
2562
|
+
] : resolveMessageFormat(e, L, ne, C, U, J), re = q, ae = L;
|
|
2563
|
+
if (!X && !(isString$2(re) || isMessageAST(re) || isMessageFunction(re)) && se && (re = ce, ae = re), !X && (!(isString$2(re) || isMessageAST(re) || isMessageFunction(re)) || !isString$2(Y)))
|
|
2564
2564
|
return c ? NOT_REOSLVED : L;
|
|
2565
|
-
if (process.env.NODE_ENV !== "production" && isString$2(
|
|
2565
|
+
if (process.env.NODE_ENV !== "production" && isString$2(re) && e.messageCompiler == null)
|
|
2566
2566
|
return warn$2(`The message format compilation is not supported in this build. Because message compiler isn't included. You need to pre-compilation all message format. So translate function return '${L}'.`), L;
|
|
2567
|
-
let
|
|
2567
|
+
let te = !1;
|
|
2568
2568
|
const ie = () => {
|
|
2569
|
-
|
|
2570
|
-
},
|
|
2571
|
-
if (
|
|
2572
|
-
return
|
|
2573
|
-
const $ = getMessageContextOptions(e,
|
|
2569
|
+
te = !0;
|
|
2570
|
+
}, H = isMessageFunction(re) ? re : compileMessageFormat(e, L, Y, re, ae, ie);
|
|
2571
|
+
if (te)
|
|
2572
|
+
return re;
|
|
2573
|
+
const $ = getMessageContextOptions(e, Y, oe, B), Q = createMessageContext($), pe = evaluateMessage(e, H, Q), de = s ? s(pe, L) : pe;
|
|
2574
2574
|
if (process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__) {
|
|
2575
|
-
const
|
|
2575
|
+
const me = {
|
|
2576
2576
|
timestamp: Date.now(),
|
|
2577
|
-
key: isString$2(L) ? L : isMessageFunction(
|
|
2578
|
-
locale:
|
|
2579
|
-
format: isString$2(
|
|
2577
|
+
key: isString$2(L) ? L : isMessageFunction(re) ? re.key : "",
|
|
2578
|
+
locale: Y || (isMessageFunction(re) ? re.locale : ""),
|
|
2579
|
+
format: isString$2(re) ? re : isMessageFunction(re) ? re.source : "",
|
|
2580
2580
|
message: de
|
|
2581
2581
|
};
|
|
2582
|
-
|
|
2582
|
+
me.meta = assign$1({}, e.__meta, /* @__PURE__ */ getAdditionalMeta() || {}), translateDevTools(me);
|
|
2583
2583
|
}
|
|
2584
2584
|
return de;
|
|
2585
2585
|
}
|
|
@@ -2589,48 +2589,48 @@ function escapeParams(e) {
|
|
|
2589
2589
|
});
|
|
2590
2590
|
}
|
|
2591
2591
|
function resolveMessageFormat(e, t, n, s, c, l) {
|
|
2592
|
-
const { messages: C, onWarn: A, messageResolver: L, localeFallbacker: B } = e,
|
|
2593
|
-
let U = {}, V,
|
|
2594
|
-
const
|
|
2595
|
-
for (let
|
|
2596
|
-
if (V = se = q
|
|
2592
|
+
const { messages: C, onWarn: A, messageResolver: L, localeFallbacker: B } = e, J = B(e, s, n);
|
|
2593
|
+
let U = {}, V, X = null, ce = n, se = null;
|
|
2594
|
+
const ne = "translate";
|
|
2595
|
+
for (let q = 0; q < J.length; q++) {
|
|
2596
|
+
if (V = se = J[q], process.env.NODE_ENV !== "production" && n !== V && isTranslateFallbackWarn(c, t) && A(getWarnMessage$1(CoreWarnCodes.FALLBACK_TO_TRANSLATE, {
|
|
2597
2597
|
key: t,
|
|
2598
2598
|
target: V
|
|
2599
2599
|
})), process.env.NODE_ENV !== "production" && n !== V) {
|
|
2600
|
-
const
|
|
2601
|
-
|
|
2602
|
-
type:
|
|
2600
|
+
const te = e.__v_emitter;
|
|
2601
|
+
te && te.emit("fallback", {
|
|
2602
|
+
type: ne,
|
|
2603
2603
|
key: t,
|
|
2604
2604
|
from: ce,
|
|
2605
2605
|
to: se,
|
|
2606
|
-
groupId: `${
|
|
2606
|
+
groupId: `${ne}:${t}`
|
|
2607
2607
|
});
|
|
2608
2608
|
}
|
|
2609
2609
|
U = C[V] || {};
|
|
2610
|
-
let
|
|
2611
|
-
if (process.env.NODE_ENV !== "production" && inBrowser && (
|
|
2612
|
-
const
|
|
2613
|
-
ie &&
|
|
2610
|
+
let Y = null, oe, re;
|
|
2611
|
+
if (process.env.NODE_ENV !== "production" && inBrowser && (Y = window.performance.now(), oe = "intlify-message-resolve-start", re = "intlify-message-resolve-end", mark && mark(oe)), (X = L(U, t)) === null && (X = U[t]), process.env.NODE_ENV !== "production" && inBrowser) {
|
|
2612
|
+
const te = window.performance.now(), ie = e.__v_emitter;
|
|
2613
|
+
ie && Y && X && ie.emit("message-resolve", {
|
|
2614
2614
|
type: "message-resolve",
|
|
2615
2615
|
key: t,
|
|
2616
|
-
message:
|
|
2617
|
-
time:
|
|
2618
|
-
groupId: `${
|
|
2619
|
-
}),
|
|
2616
|
+
message: X,
|
|
2617
|
+
time: te - Y,
|
|
2618
|
+
groupId: `${ne}:${t}`
|
|
2619
|
+
}), oe && re && mark && measure && (mark(re), measure("intlify message resolve", oe, re));
|
|
2620
2620
|
}
|
|
2621
|
-
if (isString$2(
|
|
2621
|
+
if (isString$2(X) || isMessageAST(X) || isMessageFunction(X))
|
|
2622
2622
|
break;
|
|
2623
|
-
const
|
|
2623
|
+
const ae = handleMissing(
|
|
2624
2624
|
e,
|
|
2625
2625
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
2626
2626
|
t,
|
|
2627
2627
|
V,
|
|
2628
2628
|
l,
|
|
2629
|
-
|
|
2629
|
+
ne
|
|
2630
2630
|
);
|
|
2631
|
-
|
|
2631
|
+
ae !== t && (X = ae), ce = se;
|
|
2632
2632
|
}
|
|
2633
|
-
return [
|
|
2633
|
+
return [X, V, U];
|
|
2634
2634
|
}
|
|
2635
2635
|
function compileMessageFormat(e, t, n, s, c, l) {
|
|
2636
2636
|
const { messageCompiler: C, warnHtmlMessage: A } = e;
|
|
@@ -2642,17 +2642,17 @@ function compileMessageFormat(e, t, n, s, c, l) {
|
|
|
2642
2642
|
const V = () => s;
|
|
2643
2643
|
return V.locale = n, V.key = t, V;
|
|
2644
2644
|
}
|
|
2645
|
-
let L = null, B,
|
|
2646
|
-
process.env.NODE_ENV !== "production" && inBrowser && (L = window.performance.now(), B = "intlify-message-compilation-start",
|
|
2645
|
+
let L = null, B, J;
|
|
2646
|
+
process.env.NODE_ENV !== "production" && inBrowser && (L = window.performance.now(), B = "intlify-message-compilation-start", J = "intlify-message-compilation-end", mark && mark(B));
|
|
2647
2647
|
const U = C(s, getCompileContext(e, n, c, s, A, l));
|
|
2648
2648
|
if (process.env.NODE_ENV !== "production" && inBrowser) {
|
|
2649
|
-
const V = window.performance.now(),
|
|
2650
|
-
|
|
2649
|
+
const V = window.performance.now(), X = e.__v_emitter;
|
|
2650
|
+
X && L && X.emit("message-compilation", {
|
|
2651
2651
|
type: "message-compilation",
|
|
2652
2652
|
message: s,
|
|
2653
2653
|
time: V - L,
|
|
2654
2654
|
groupId: `translate:${t}`
|
|
2655
|
-
}), B &&
|
|
2655
|
+
}), B && J && mark && measure && (mark(J), measure("intlify message compilation", B, J));
|
|
2656
2656
|
}
|
|
2657
2657
|
return U.locale = n, U.key = t, U.source = s, U;
|
|
2658
2658
|
}
|
|
@@ -2685,8 +2685,8 @@ function getCompileContext(e, t, n, s, c, l) {
|
|
|
2685
2685
|
warnHtmlMessage: c,
|
|
2686
2686
|
onError: (C) => {
|
|
2687
2687
|
if (l && l(C), process.env.NODE_ENV !== "production") {
|
|
2688
|
-
const A = getSourceForCodeFrame(s), L = `Message compilation error: ${C.message}`, B = C.location && A && generateCodeFrame(A, C.location.start.offset, C.location.end.offset),
|
|
2689
|
-
|
|
2688
|
+
const A = getSourceForCodeFrame(s), L = `Message compilation error: ${C.message}`, B = C.location && A && generateCodeFrame(A, C.location.start.offset, C.location.end.offset), J = e.__v_emitter;
|
|
2689
|
+
J && A && J.emit("compile-error", {
|
|
2690
2690
|
message: A,
|
|
2691
2691
|
error: C.message,
|
|
2692
2692
|
start: C.location && C.location.start.offset,
|
|
@@ -2707,22 +2707,22 @@ function getSourceForCodeFrame(e) {
|
|
|
2707
2707
|
return e.loc.source;
|
|
2708
2708
|
}
|
|
2709
2709
|
function getMessageContextOptions(e, t, n, s) {
|
|
2710
|
-
const { modifiers: c, pluralRules: l, messageResolver: C, fallbackLocale: A, fallbackWarn: L, missingWarn: B, fallbackContext:
|
|
2710
|
+
const { modifiers: c, pluralRules: l, messageResolver: C, fallbackLocale: A, fallbackWarn: L, missingWarn: B, fallbackContext: J } = e, V = {
|
|
2711
2711
|
locale: t,
|
|
2712
2712
|
modifiers: c,
|
|
2713
2713
|
pluralRules: l,
|
|
2714
|
-
messages: (
|
|
2715
|
-
let ce = C(n,
|
|
2716
|
-
if (ce == null &&
|
|
2717
|
-
const [, , se] = resolveMessageFormat(
|
|
2718
|
-
ce = C(se,
|
|
2714
|
+
messages: (X) => {
|
|
2715
|
+
let ce = C(n, X);
|
|
2716
|
+
if (ce == null && J) {
|
|
2717
|
+
const [, , se] = resolveMessageFormat(J, X, t, A, L, B);
|
|
2718
|
+
ce = C(se, X);
|
|
2719
2719
|
}
|
|
2720
2720
|
if (isString$2(ce) || isMessageAST(ce)) {
|
|
2721
2721
|
let se = !1;
|
|
2722
|
-
const
|
|
2722
|
+
const q = compileMessageFormat(e, X, t, ce, X, () => {
|
|
2723
2723
|
se = !0;
|
|
2724
2724
|
});
|
|
2725
|
-
return se ? NOOP_MESSAGE_FUNCTION :
|
|
2725
|
+
return se ? NOOP_MESSAGE_FUNCTION : q;
|
|
2726
2726
|
} else
|
|
2727
2727
|
return isMessageFunction(ce) ? ce : NOOP_MESSAGE_FUNCTION;
|
|
2728
2728
|
}
|
|
@@ -2737,7 +2737,7 @@ function datetime(e, ...t) {
|
|
|
2737
2737
|
const { datetimeFormats: n, unresolving: s, fallbackLocale: c, onWarn: l, localeFallbacker: C } = e, { __datetimeFormatters: A } = e;
|
|
2738
2738
|
if (process.env.NODE_ENV !== "production" && !Availabilities.dateTimeFormat)
|
|
2739
2739
|
return l(getWarnMessage$1(CoreWarnCodes.CANNOT_FORMAT_DATE)), MISSING_RESOLVE_VALUE;
|
|
2740
|
-
const [L, B,
|
|
2740
|
+
const [L, B, J, U] = parseDateTimeArgs(...t), V = isBoolean(J.missingWarn) ? J.missingWarn : e.missingWarn, X = isBoolean(J.fallbackWarn) ? J.fallbackWarn : e.fallbackWarn, ce = !!J.part, se = getLocale(e, J), ne = C(
|
|
2741
2741
|
e,
|
|
2742
2742
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
2743
2743
|
c,
|
|
@@ -2745,32 +2745,32 @@ function datetime(e, ...t) {
|
|
|
2745
2745
|
);
|
|
2746
2746
|
if (!isString$2(L) || L === "")
|
|
2747
2747
|
return new Intl.DateTimeFormat(se, U).format(B);
|
|
2748
|
-
let
|
|
2749
|
-
const
|
|
2750
|
-
for (let $ = 0; $ <
|
|
2751
|
-
if (
|
|
2748
|
+
let q = {}, Y, oe = null, re = se, ae = null;
|
|
2749
|
+
const te = "datetime format";
|
|
2750
|
+
for (let $ = 0; $ < ne.length; $++) {
|
|
2751
|
+
if (Y = ae = ne[$], process.env.NODE_ENV !== "production" && se !== Y && isTranslateFallbackWarn(X, L) && l(getWarnMessage$1(CoreWarnCodes.FALLBACK_TO_DATE_FORMAT, {
|
|
2752
2752
|
key: L,
|
|
2753
|
-
target:
|
|
2754
|
-
})), process.env.NODE_ENV !== "production" && se !==
|
|
2755
|
-
const
|
|
2756
|
-
|
|
2757
|
-
type:
|
|
2753
|
+
target: Y
|
|
2754
|
+
})), process.env.NODE_ENV !== "production" && se !== Y) {
|
|
2755
|
+
const Q = e.__v_emitter;
|
|
2756
|
+
Q && Q.emit("fallback", {
|
|
2757
|
+
type: te,
|
|
2758
2758
|
key: L,
|
|
2759
|
-
from:
|
|
2760
|
-
to:
|
|
2761
|
-
groupId: `${
|
|
2759
|
+
from: re,
|
|
2760
|
+
to: ae,
|
|
2761
|
+
groupId: `${te}:${L}`
|
|
2762
2762
|
});
|
|
2763
2763
|
}
|
|
2764
|
-
if (
|
|
2764
|
+
if (q = n[Y] || {}, oe = q[L], isPlainObject$1(oe))
|
|
2765
2765
|
break;
|
|
2766
|
-
handleMissing(e, L,
|
|
2766
|
+
handleMissing(e, L, Y, V, te), re = ae;
|
|
2767
2767
|
}
|
|
2768
|
-
if (!isPlainObject$1(
|
|
2768
|
+
if (!isPlainObject$1(oe) || !isString$2(Y))
|
|
2769
2769
|
return s ? NOT_REOSLVED : L;
|
|
2770
|
-
let ie = `${
|
|
2770
|
+
let ie = `${Y}__${L}`;
|
|
2771
2771
|
isEmptyObject(U) || (ie = `${ie}__${JSON.stringify(U)}`);
|
|
2772
|
-
let
|
|
2773
|
-
return
|
|
2772
|
+
let H = A.get(ie);
|
|
2773
|
+
return H || (H = new Intl.DateTimeFormat(Y, assign$1({}, oe, U)), A.set(ie, H)), ce ? H.formatToParts(B) : H.format(B);
|
|
2774
2774
|
}
|
|
2775
2775
|
const DATETIME_FORMAT_OPTIONS_KEYS = [
|
|
2776
2776
|
"localeMatcher",
|
|
@@ -2831,7 +2831,7 @@ function number(e, ...t) {
|
|
|
2831
2831
|
const { numberFormats: n, unresolving: s, fallbackLocale: c, onWarn: l, localeFallbacker: C } = e, { __numberFormatters: A } = e;
|
|
2832
2832
|
if (process.env.NODE_ENV !== "production" && !Availabilities.numberFormat)
|
|
2833
2833
|
return l(getWarnMessage$1(CoreWarnCodes.CANNOT_FORMAT_NUMBER)), MISSING_RESOLVE_VALUE;
|
|
2834
|
-
const [L, B,
|
|
2834
|
+
const [L, B, J, U] = parseNumberArgs(...t), V = isBoolean(J.missingWarn) ? J.missingWarn : e.missingWarn, X = isBoolean(J.fallbackWarn) ? J.fallbackWarn : e.fallbackWarn, ce = !!J.part, se = getLocale(e, J), ne = C(
|
|
2835
2835
|
e,
|
|
2836
2836
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
2837
2837
|
c,
|
|
@@ -2839,32 +2839,32 @@ function number(e, ...t) {
|
|
|
2839
2839
|
);
|
|
2840
2840
|
if (!isString$2(L) || L === "")
|
|
2841
2841
|
return new Intl.NumberFormat(se, U).format(B);
|
|
2842
|
-
let
|
|
2843
|
-
const
|
|
2844
|
-
for (let $ = 0; $ <
|
|
2845
|
-
if (
|
|
2842
|
+
let q = {}, Y, oe = null, re = se, ae = null;
|
|
2843
|
+
const te = "number format";
|
|
2844
|
+
for (let $ = 0; $ < ne.length; $++) {
|
|
2845
|
+
if (Y = ae = ne[$], process.env.NODE_ENV !== "production" && se !== Y && isTranslateFallbackWarn(X, L) && l(getWarnMessage$1(CoreWarnCodes.FALLBACK_TO_NUMBER_FORMAT, {
|
|
2846
2846
|
key: L,
|
|
2847
|
-
target:
|
|
2848
|
-
})), process.env.NODE_ENV !== "production" && se !==
|
|
2849
|
-
const
|
|
2850
|
-
|
|
2851
|
-
type:
|
|
2847
|
+
target: Y
|
|
2848
|
+
})), process.env.NODE_ENV !== "production" && se !== Y) {
|
|
2849
|
+
const Q = e.__v_emitter;
|
|
2850
|
+
Q && Q.emit("fallback", {
|
|
2851
|
+
type: te,
|
|
2852
2852
|
key: L,
|
|
2853
|
-
from:
|
|
2854
|
-
to:
|
|
2855
|
-
groupId: `${
|
|
2853
|
+
from: re,
|
|
2854
|
+
to: ae,
|
|
2855
|
+
groupId: `${te}:${L}`
|
|
2856
2856
|
});
|
|
2857
2857
|
}
|
|
2858
|
-
if (
|
|
2858
|
+
if (q = n[Y] || {}, oe = q[L], isPlainObject$1(oe))
|
|
2859
2859
|
break;
|
|
2860
|
-
handleMissing(e, L,
|
|
2860
|
+
handleMissing(e, L, Y, V, te), re = ae;
|
|
2861
2861
|
}
|
|
2862
|
-
if (!isPlainObject$1(
|
|
2862
|
+
if (!isPlainObject$1(oe) || !isString$2(Y))
|
|
2863
2863
|
return s ? NOT_REOSLVED : L;
|
|
2864
|
-
let ie = `${
|
|
2864
|
+
let ie = `${Y}__${L}`;
|
|
2865
2865
|
isEmptyObject(U) || (ie = `${ie}__${JSON.stringify(U)}`);
|
|
2866
|
-
let
|
|
2867
|
-
return
|
|
2866
|
+
let H = A.get(ie);
|
|
2867
|
+
return H || (H = new Intl.NumberFormat(Y, assign$1({}, oe, U)), A.set(ie, H)), ce ? H.formatToParts(B) : H.format(B);
|
|
2868
2868
|
}
|
|
2869
2869
|
const NUMBER_FORMAT_OPTIONS_KEYS = [
|
|
2870
2870
|
"localeMatcher",
|
|
@@ -3340,9 +3340,9 @@ function trigger(e, t, n, s, c, l) {
|
|
|
3340
3340
|
else {
|
|
3341
3341
|
const L = isArray(e), B = L && isIntegerKey(n);
|
|
3342
3342
|
if (L && n === "length") {
|
|
3343
|
-
const
|
|
3343
|
+
const J = Number(s);
|
|
3344
3344
|
C.forEach((U, V) => {
|
|
3345
|
-
(V === "length" || V === ARRAY_ITERATE_KEY || !isSymbol(V) && V >=
|
|
3345
|
+
(V === "length" || V === ARRAY_ITERATE_KEY || !isSymbol(V) && V >= J) && A(U);
|
|
3346
3346
|
});
|
|
3347
3347
|
} else
|
|
3348
3348
|
switch ((n !== void 0 || C.has(void 0)) && A(C.get(n)), B && A(C.get(ARRAY_ITERATE_KEY)), t) {
|
|
@@ -3475,8 +3475,8 @@ function apply$1(e, t, n, s, c, l) {
|
|
|
3475
3475
|
} : n.length > 2 && (B = function(U, V) {
|
|
3476
3476
|
return n.call(this, U, V, e);
|
|
3477
3477
|
}));
|
|
3478
|
-
const
|
|
3479
|
-
return A && c ? c(
|
|
3478
|
+
const J = L.call(C, B, s);
|
|
3479
|
+
return A && c ? c(J) : J;
|
|
3480
3480
|
}
|
|
3481
3481
|
function reduce(e, t, n, s) {
|
|
3482
3482
|
const c = shallowReadArray(e);
|
|
@@ -3598,7 +3598,7 @@ class ReadonlyReactiveHandler extends BaseReactiveHandler {
|
|
|
3598
3598
|
const mutableHandlers = /* @__PURE__ */ new MutableReactiveHandler(), readonlyHandlers = /* @__PURE__ */ new ReadonlyReactiveHandler(), shallowReadonlyHandlers = /* @__PURE__ */ new ReadonlyReactiveHandler(!0), toShallow = (e) => e, getProto = (e) => Reflect.getPrototypeOf(e);
|
|
3599
3599
|
function createIterableMethod(e, t, n) {
|
|
3600
3600
|
return function(...s) {
|
|
3601
|
-
const c = this.__v_raw, l = toRaw(c), C = isMap(l), A = e === "entries" || e === Symbol.iterator && C, L = e === "keys" && C, B = c[e](...s),
|
|
3601
|
+
const c = this.__v_raw, l = toRaw(c), C = isMap(l), A = e === "entries" || e === Symbol.iterator && C, L = e === "keys" && C, B = c[e](...s), J = n ? toShallow : t ? toReadonly : toReactive;
|
|
3602
3602
|
return !t && track(
|
|
3603
3603
|
l,
|
|
3604
3604
|
"iterate",
|
|
@@ -3608,7 +3608,7 @@ function createIterableMethod(e, t, n) {
|
|
|
3608
3608
|
next() {
|
|
3609
3609
|
const { value: U, done: V } = B.next();
|
|
3610
3610
|
return V ? { value: U, done: V } : {
|
|
3611
|
-
value: A ? [
|
|
3611
|
+
value: A ? [J(U[0]), J(U[1])] : J(U),
|
|
3612
3612
|
done: V
|
|
3613
3613
|
};
|
|
3614
3614
|
},
|
|
@@ -3653,7 +3653,7 @@ function createInstrumentations(e, t) {
|
|
|
3653
3653
|
},
|
|
3654
3654
|
forEach(c, l) {
|
|
3655
3655
|
const C = this, A = C.__v_raw, L = toRaw(A), B = t ? toShallow : e ? toReadonly : toReactive;
|
|
3656
|
-
return !e && track(L, "iterate", ITERATE_KEY), A.forEach((
|
|
3656
|
+
return !e && track(L, "iterate", ITERATE_KEY), A.forEach((J, U) => c.call(l, B(J), B(U), C));
|
|
3657
3657
|
}
|
|
3658
3658
|
};
|
|
3659
3659
|
return extend(
|
|
@@ -3674,15 +3674,15 @@ function createInstrumentations(e, t) {
|
|
|
3674
3674
|
const C = toRaw(this), { has: A, get: L } = getProto(C);
|
|
3675
3675
|
let B = A.call(C, c);
|
|
3676
3676
|
B ? process.env.NODE_ENV !== "production" && checkIdentityKeys(C, A, c) : (c = toRaw(c), B = A.call(C, c));
|
|
3677
|
-
const
|
|
3678
|
-
return C.set(c, l), B ? hasChanged(l,
|
|
3677
|
+
const J = L.call(C, c);
|
|
3678
|
+
return C.set(c, l), B ? hasChanged(l, J) && trigger(C, "set", c, l, J) : trigger(C, "add", c, l), this;
|
|
3679
3679
|
},
|
|
3680
3680
|
delete(c) {
|
|
3681
3681
|
const l = toRaw(this), { has: C, get: A } = getProto(l);
|
|
3682
3682
|
let L = C.call(l, c);
|
|
3683
3683
|
L ? process.env.NODE_ENV !== "production" && checkIdentityKeys(l, C, c) : (c = toRaw(c), L = C.call(l, c));
|
|
3684
|
-
const B = A ? A.call(l, c) : void 0,
|
|
3685
|
-
return L && trigger(l, "delete", c, void 0, B),
|
|
3684
|
+
const B = A ? A.call(l, c) : void 0, J = l.delete(c);
|
|
3685
|
+
return L && trigger(l, "delete", c, void 0, B), J;
|
|
3686
3686
|
},
|
|
3687
3687
|
clear() {
|
|
3688
3688
|
const c = toRaw(this), l = c.size !== 0, C = process.env.NODE_ENV !== "production" ? isMap(c) ? new Map(c) : new Set(c) : void 0, A = c.clear();
|
|
@@ -3904,71 +3904,71 @@ function onWatcherCleanup(e, t = !1, n = activeWatcher) {
|
|
|
3904
3904
|
);
|
|
3905
3905
|
}
|
|
3906
3906
|
function watch$1(e, t, n = EMPTY_OBJ) {
|
|
3907
|
-
const { immediate: s, deep: c, once: l, scheduler: C, augmentJob: A, call: L } = n, B = (
|
|
3907
|
+
const { immediate: s, deep: c, once: l, scheduler: C, augmentJob: A, call: L } = n, B = (ae) => {
|
|
3908
3908
|
(n.onWarn || warn)(
|
|
3909
3909
|
"Invalid watch source: ",
|
|
3910
|
-
|
|
3910
|
+
ae,
|
|
3911
3911
|
"A watch source can only be a getter/effect function, a ref, a reactive object, or an array of these types."
|
|
3912
3912
|
);
|
|
3913
|
-
},
|
|
3914
|
-
let U, V,
|
|
3915
|
-
if (isRef(e) ? (V = () => e.value, se = isShallow(e)) : isReactive(e) ? (V = () =>
|
|
3916
|
-
if (isRef(
|
|
3917
|
-
return
|
|
3918
|
-
if (isReactive(
|
|
3919
|
-
return
|
|
3920
|
-
if (isFunction(
|
|
3921
|
-
return L ? L(
|
|
3922
|
-
process.env.NODE_ENV !== "production" && B(
|
|
3913
|
+
}, J = (ae) => c ? ae : isShallow(ae) || c === !1 || c === 0 ? traverse(ae, 1) : traverse(ae);
|
|
3914
|
+
let U, V, X, ce, se = !1, ne = !1;
|
|
3915
|
+
if (isRef(e) ? (V = () => e.value, se = isShallow(e)) : isReactive(e) ? (V = () => J(e), se = !0) : isArray(e) ? (ne = !0, se = e.some((ae) => isReactive(ae) || isShallow(ae)), V = () => e.map((ae) => {
|
|
3916
|
+
if (isRef(ae))
|
|
3917
|
+
return ae.value;
|
|
3918
|
+
if (isReactive(ae))
|
|
3919
|
+
return J(ae);
|
|
3920
|
+
if (isFunction(ae))
|
|
3921
|
+
return L ? L(ae, 2) : ae();
|
|
3922
|
+
process.env.NODE_ENV !== "production" && B(ae);
|
|
3923
3923
|
})) : isFunction(e) ? t ? V = L ? () => L(e, 2) : e : V = () => {
|
|
3924
|
-
if (
|
|
3924
|
+
if (X) {
|
|
3925
3925
|
pauseTracking();
|
|
3926
3926
|
try {
|
|
3927
|
-
|
|
3927
|
+
X();
|
|
3928
3928
|
} finally {
|
|
3929
3929
|
resetTracking();
|
|
3930
3930
|
}
|
|
3931
3931
|
}
|
|
3932
|
-
const
|
|
3932
|
+
const ae = activeWatcher;
|
|
3933
3933
|
activeWatcher = U;
|
|
3934
3934
|
try {
|
|
3935
3935
|
return L ? L(e, 3, [ce]) : e(ce);
|
|
3936
3936
|
} finally {
|
|
3937
|
-
activeWatcher =
|
|
3937
|
+
activeWatcher = ae;
|
|
3938
3938
|
}
|
|
3939
3939
|
} : (V = NOOP, process.env.NODE_ENV !== "production" && B(e)), t && c) {
|
|
3940
|
-
const
|
|
3941
|
-
V = () => traverse(
|
|
3940
|
+
const ae = V, te = c === !0 ? 1 / 0 : c;
|
|
3941
|
+
V = () => traverse(ae(), te);
|
|
3942
3942
|
}
|
|
3943
|
-
const
|
|
3944
|
-
U.stop(),
|
|
3943
|
+
const q = getCurrentScope(), Y = () => {
|
|
3944
|
+
U.stop(), q && q.active && remove(q.effects, U);
|
|
3945
3945
|
};
|
|
3946
3946
|
if (l && t) {
|
|
3947
|
-
const
|
|
3948
|
-
t = (...
|
|
3949
|
-
|
|
3947
|
+
const ae = t;
|
|
3948
|
+
t = (...te) => {
|
|
3949
|
+
ae(...te), Y();
|
|
3950
3950
|
};
|
|
3951
3951
|
}
|
|
3952
|
-
let
|
|
3953
|
-
const
|
|
3954
|
-
if (!(!(U.flags & 1) || !U.dirty && !
|
|
3952
|
+
let oe = ne ? new Array(e.length).fill(INITIAL_WATCHER_VALUE) : INITIAL_WATCHER_VALUE;
|
|
3953
|
+
const re = (ae) => {
|
|
3954
|
+
if (!(!(U.flags & 1) || !U.dirty && !ae))
|
|
3955
3955
|
if (t) {
|
|
3956
|
-
const
|
|
3957
|
-
if (c || se || (
|
|
3958
|
-
|
|
3956
|
+
const te = U.run();
|
|
3957
|
+
if (c || se || (ne ? te.some((ie, H) => hasChanged(ie, oe[H])) : hasChanged(te, oe))) {
|
|
3958
|
+
X && X();
|
|
3959
3959
|
const ie = activeWatcher;
|
|
3960
3960
|
activeWatcher = U;
|
|
3961
3961
|
try {
|
|
3962
|
-
const
|
|
3963
|
-
|
|
3962
|
+
const H = [
|
|
3963
|
+
te,
|
|
3964
3964
|
// pass undefined as the old value when it's changed for the first time
|
|
3965
|
-
|
|
3965
|
+
oe === INITIAL_WATCHER_VALUE ? void 0 : ne && oe[0] === INITIAL_WATCHER_VALUE ? [] : oe,
|
|
3966
3966
|
ce
|
|
3967
3967
|
];
|
|
3968
|
-
L ? L(t, 3,
|
|
3968
|
+
L ? L(t, 3, H) : (
|
|
3969
3969
|
// @ts-expect-error
|
|
3970
|
-
t(...
|
|
3971
|
-
),
|
|
3970
|
+
t(...H)
|
|
3971
|
+
), oe = te;
|
|
3972
3972
|
} finally {
|
|
3973
3973
|
activeWatcher = ie;
|
|
3974
3974
|
}
|
|
@@ -3976,17 +3976,17 @@ function watch$1(e, t, n = EMPTY_OBJ) {
|
|
|
3976
3976
|
} else
|
|
3977
3977
|
U.run();
|
|
3978
3978
|
};
|
|
3979
|
-
return A && A(
|
|
3980
|
-
const
|
|
3981
|
-
if (
|
|
3979
|
+
return A && A(re), U = new ReactiveEffect(V), U.scheduler = C ? () => C(re, !1) : re, ce = (ae) => onWatcherCleanup(ae, !1, U), X = U.onStop = () => {
|
|
3980
|
+
const ae = cleanupMap.get(U);
|
|
3981
|
+
if (ae) {
|
|
3982
3982
|
if (L)
|
|
3983
|
-
L(
|
|
3983
|
+
L(ae, 4);
|
|
3984
3984
|
else
|
|
3985
|
-
for (const
|
|
3986
|
-
|
|
3985
|
+
for (const te of ae)
|
|
3986
|
+
te();
|
|
3987
3987
|
cleanupMap.delete(U);
|
|
3988
3988
|
}
|
|
3989
|
-
}, process.env.NODE_ENV !== "production" && (U.onTrack = n.onTrack, U.onTrigger = n.onTrigger), t ? s ?
|
|
3989
|
+
}, process.env.NODE_ENV !== "production" && (U.onTrack = n.onTrack, U.onTrigger = n.onTrigger), t ? s ? re(!0) : oe = U.run() : C ? C(re.bind(null, !0), !0) : U.run(), Y.pause = U.pause.bind(U), Y.resume = U.resume.bind(U), Y.stop = Y, Y;
|
|
3990
3990
|
}
|
|
3991
3991
|
function traverse(e, t = 1 / 0, n) {
|
|
3992
3992
|
if (t <= 0 || !isObject(e) || e.__v_skip || (n = n || /* @__PURE__ */ new Set(), n.has(e)))
|
|
@@ -4155,10 +4155,10 @@ function handleError(e, t, n, s = !0) {
|
|
|
4155
4155
|
let A = t.parent;
|
|
4156
4156
|
const L = t.proxy, B = process.env.NODE_ENV !== "production" ? ErrorTypeStrings$1[n] : `https://vuejs.org/error-reference/#runtime-${n}`;
|
|
4157
4157
|
for (; A; ) {
|
|
4158
|
-
const
|
|
4159
|
-
if (
|
|
4160
|
-
for (let U = 0; U <
|
|
4161
|
-
if (
|
|
4158
|
+
const J = A.ec;
|
|
4159
|
+
if (J) {
|
|
4160
|
+
for (let U = 0; U < J.length; U++)
|
|
4161
|
+
if (J[U](e, L, B) === !1)
|
|
4162
4162
|
return;
|
|
4163
4163
|
}
|
|
4164
4164
|
A = A.parent;
|
|
@@ -4404,9 +4404,9 @@ const createHook = (e) => (t, n = currentInstance) => {
|
|
|
4404
4404
|
return !0;
|
|
4405
4405
|
let B;
|
|
4406
4406
|
if (t[0] !== "$") {
|
|
4407
|
-
const
|
|
4408
|
-
if (
|
|
4409
|
-
switch (
|
|
4407
|
+
const X = C[t];
|
|
4408
|
+
if (X !== void 0)
|
|
4409
|
+
switch (X) {
|
|
4410
4410
|
case 1:
|
|
4411
4411
|
return s[t];
|
|
4412
4412
|
case 2:
|
|
@@ -4432,10 +4432,10 @@ const createHook = (e) => (t, n = currentInstance) => {
|
|
|
4432
4432
|
(!__VUE_OPTIONS_API__ || shouldCacheAccess) && (C[t] = 0);
|
|
4433
4433
|
}
|
|
4434
4434
|
}
|
|
4435
|
-
const
|
|
4435
|
+
const J = publicPropertiesMap[t];
|
|
4436
4436
|
let U, V;
|
|
4437
|
-
if (
|
|
4438
|
-
return t === "$attrs" ? (track(e.attrs, "get", ""), process.env.NODE_ENV !== "production" && void 0) : process.env.NODE_ENV !== "production" && t === "$slots" && track(e, "get", t),
|
|
4437
|
+
if (J)
|
|
4438
|
+
return t === "$attrs" ? (track(e.attrs, "get", ""), process.env.NODE_ENV !== "production" && void 0) : process.env.NODE_ENV !== "production" && t === "$slots" && track(e, "get", t), J(e);
|
|
4439
4439
|
if (
|
|
4440
4440
|
// css module (injected by vue-loader)
|
|
4441
4441
|
(U = A.__cssModules) && (U = U[t])
|
|
@@ -4630,23 +4630,23 @@ function doWatch(e, t, n = EMPTY_OBJ) {
|
|
|
4630
4630
|
let B;
|
|
4631
4631
|
if (isInSSRComponentSetup) {
|
|
4632
4632
|
if (l === "sync") {
|
|
4633
|
-
const
|
|
4634
|
-
B =
|
|
4633
|
+
const X = useSSRContext();
|
|
4634
|
+
B = X.__watcherHandles || (X.__watcherHandles = []);
|
|
4635
4635
|
} else if (!L) {
|
|
4636
|
-
const
|
|
4636
|
+
const X = () => {
|
|
4637
4637
|
};
|
|
4638
|
-
return
|
|
4638
|
+
return X.stop = NOOP, X.resume = NOOP, X.pause = NOOP, X;
|
|
4639
4639
|
}
|
|
4640
4640
|
}
|
|
4641
|
-
const
|
|
4642
|
-
A.call = (
|
|
4641
|
+
const J = currentInstance;
|
|
4642
|
+
A.call = (X, ce, se) => callWithAsyncErrorHandling(X, J, ce, se);
|
|
4643
4643
|
let U = !1;
|
|
4644
|
-
l === "post" ? A.scheduler = (
|
|
4645
|
-
queuePostRenderEffect(
|
|
4646
|
-
} : l !== "sync" && (U = !0, A.scheduler = (
|
|
4647
|
-
ce ?
|
|
4648
|
-
}), A.augmentJob = (
|
|
4649
|
-
t && (
|
|
4644
|
+
l === "post" ? A.scheduler = (X) => {
|
|
4645
|
+
queuePostRenderEffect(X, J && J.suspense);
|
|
4646
|
+
} : l !== "sync" && (U = !0, A.scheduler = (X, ce) => {
|
|
4647
|
+
ce ? X() : queueJob(X);
|
|
4648
|
+
}), A.augmentJob = (X) => {
|
|
4649
|
+
t && (X.flags |= 4), U && (X.flags |= 2, J && (X.id = J.uid, X.i = J));
|
|
4650
4650
|
};
|
|
4651
4651
|
const V = watch$1(e, t, A);
|
|
4652
4652
|
return isInSSRComponentSetup && (B ? B.push(V) : L && V()), V;
|
|
@@ -4762,7 +4762,7 @@ function guardReactiveProps(e) {
|
|
|
4762
4762
|
return e ? isProxy(e) || isInternalObject(e) ? extend({}, e) : e : null;
|
|
4763
4763
|
}
|
|
4764
4764
|
function cloneVNode(e, t, n = !1, s = !1) {
|
|
4765
|
-
const { props: c, ref: l, patchFlag: C, children: A, transition: L } = e, B = t ? mergeProps(c || {}, t) : c,
|
|
4765
|
+
const { props: c, ref: l, patchFlag: C, children: A, transition: L } = e, B = t ? mergeProps(c || {}, t) : c, J = {
|
|
4766
4766
|
__v_isVNode: !0,
|
|
4767
4767
|
__v_skip: !0,
|
|
4768
4768
|
type: e.type,
|
|
@@ -4806,9 +4806,9 @@ function cloneVNode(e, t, n = !1, s = !1) {
|
|
|
4806
4806
|
ce: e.ce
|
|
4807
4807
|
};
|
|
4808
4808
|
return L && s && setTransitionHooks(
|
|
4809
|
-
|
|
4810
|
-
L.clone(
|
|
4811
|
-
),
|
|
4809
|
+
J,
|
|
4810
|
+
L.clone(J)
|
|
4811
|
+
), J;
|
|
4812
4812
|
}
|
|
4813
4813
|
function deepCloneVNode(e) {
|
|
4814
4814
|
const t = cloneVNode(e);
|
|
@@ -4943,7 +4943,7 @@ function initCustomFormatter() {
|
|
|
4943
4943
|
return isObject(U) ? U.__isVue ? ["div", e, "VueInstance"] : isRef(U) ? [
|
|
4944
4944
|
"div",
|
|
4945
4945
|
{},
|
|
4946
|
-
["span", e,
|
|
4946
|
+
["span", e, J(U)],
|
|
4947
4947
|
"<",
|
|
4948
4948
|
// avoid debugger accessing value affecting behavior
|
|
4949
4949
|
A("_value" in U ? U._value : U),
|
|
@@ -4979,8 +4979,8 @@ function initCustomFormatter() {
|
|
|
4979
4979
|
function l(U) {
|
|
4980
4980
|
const V = [];
|
|
4981
4981
|
U.type.props && U.props && V.push(C("props", toRaw(U.props))), U.setupState !== EMPTY_OBJ && V.push(C("setup", U.setupState)), U.data !== EMPTY_OBJ && V.push(C("data", toRaw(U.data)));
|
|
4982
|
-
const
|
|
4983
|
-
|
|
4982
|
+
const X = L(U, "computed");
|
|
4983
|
+
X && V.push(C("computed", X));
|
|
4984
4984
|
const ce = L(U, "inject");
|
|
4985
4985
|
return ce && V.push(C("injected", ce)), V.push([
|
|
4986
4986
|
"div",
|
|
@@ -5011,11 +5011,11 @@ function initCustomFormatter() {
|
|
|
5011
5011
|
{
|
|
5012
5012
|
style: "padding-left:1.25em"
|
|
5013
5013
|
},
|
|
5014
|
-
...Object.keys(V).map((
|
|
5014
|
+
...Object.keys(V).map((X) => [
|
|
5015
5015
|
"div",
|
|
5016
5016
|
{},
|
|
5017
|
-
["span", s,
|
|
5018
|
-
A(V[
|
|
5017
|
+
["span", s, X + ": "],
|
|
5018
|
+
A(V[X], !1)
|
|
5019
5019
|
])
|
|
5020
5020
|
]
|
|
5021
5021
|
] : ["span", {}];
|
|
@@ -5024,20 +5024,20 @@ function initCustomFormatter() {
|
|
|
5024
5024
|
return typeof U == "number" ? ["span", t, U] : typeof U == "string" ? ["span", n, JSON.stringify(U)] : typeof U == "boolean" ? ["span", s, U] : isObject(U) ? ["object", { object: V ? toRaw(U) : U }] : ["span", n, String(U)];
|
|
5025
5025
|
}
|
|
5026
5026
|
function L(U, V) {
|
|
5027
|
-
const
|
|
5028
|
-
if (isFunction(
|
|
5027
|
+
const X = U.type;
|
|
5028
|
+
if (isFunction(X))
|
|
5029
5029
|
return;
|
|
5030
5030
|
const ce = {};
|
|
5031
5031
|
for (const se in U.ctx)
|
|
5032
|
-
B(
|
|
5032
|
+
B(X, se, V) && (ce[se] = U.ctx[se]);
|
|
5033
5033
|
return ce;
|
|
5034
5034
|
}
|
|
5035
|
-
function B(U, V,
|
|
5036
|
-
const ce = U[
|
|
5037
|
-
if (isArray(ce) && ce.includes(V) || isObject(ce) && V in ce || U.extends && B(U.extends, V,
|
|
5035
|
+
function B(U, V, X) {
|
|
5036
|
+
const ce = U[X];
|
|
5037
|
+
if (isArray(ce) && ce.includes(V) || isObject(ce) && V in ce || U.extends && B(U.extends, V, X) || U.mixins && U.mixins.some((se) => B(se, V, X)))
|
|
5038
5038
|
return !0;
|
|
5039
5039
|
}
|
|
5040
|
-
function
|
|
5040
|
+
function J(U) {
|
|
5041
5041
|
return isShallow(U) ? "ShallowRef" : U.effect ? "ComputedRef" : "Ref";
|
|
5042
5042
|
}
|
|
5043
5043
|
window.devtoolsFormatters ? window.devtoolsFormatters.push(c) : window.devtoolsFormatters = [c];
|
|
@@ -5335,45 +5335,45 @@ function createComposer(e = {}, t) {
|
|
|
5335
5335
|
const B = C(
|
|
5336
5336
|
// prettier-ignore
|
|
5337
5337
|
n && L ? n.locale.value : isString$2(e.locale) ? e.locale : DEFAULT_LOCALE
|
|
5338
|
-
),
|
|
5338
|
+
), J = C(
|
|
5339
5339
|
// prettier-ignore
|
|
5340
5340
|
n && L ? n.fallbackLocale.value : isString$2(e.fallbackLocale) || isArray$1(e.fallbackLocale) || isPlainObject$1(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : B.value
|
|
5341
|
-
), U = C(getLocaleMessages(B.value, e)), V = C(isPlainObject$1(e.datetimeFormats) ? e.datetimeFormats : { [B.value]: {} }),
|
|
5342
|
-
let ce = n ? n.missingWarn : isBoolean(e.missingWarn) || isRegExp(e.missingWarn) ? e.missingWarn : !0, se = n ? n.fallbackWarn : isBoolean(e.fallbackWarn) || isRegExp(e.fallbackWarn) ? e.fallbackWarn : !0,
|
|
5341
|
+
), U = C(getLocaleMessages(B.value, e)), V = C(isPlainObject$1(e.datetimeFormats) ? e.datetimeFormats : { [B.value]: {} }), X = C(isPlainObject$1(e.numberFormats) ? e.numberFormats : { [B.value]: {} });
|
|
5342
|
+
let ce = n ? n.missingWarn : isBoolean(e.missingWarn) || isRegExp(e.missingWarn) ? e.missingWarn : !0, se = n ? n.fallbackWarn : isBoolean(e.fallbackWarn) || isRegExp(e.fallbackWarn) ? e.fallbackWarn : !0, ne = n ? n.fallbackRoot : isBoolean(e.fallbackRoot) ? e.fallbackRoot : !0, q = !!e.fallbackFormat, Y = isFunction$1(e.missing) ? e.missing : null, oe = isFunction$1(e.missing) ? defineCoreMissingHandler(e.missing) : null, re = isFunction$1(e.postTranslation) ? e.postTranslation : null, ae = n ? n.warnHtmlMessage : isBoolean(e.warnHtmlMessage) ? e.warnHtmlMessage : !0, te = !!e.escapeParameter;
|
|
5343
5343
|
const ie = n ? n.modifiers : isPlainObject$1(e.modifiers) ? e.modifiers : {};
|
|
5344
|
-
let
|
|
5344
|
+
let H = e.pluralRules || n && n.pluralRules, $;
|
|
5345
5345
|
$ = (() => {
|
|
5346
5346
|
c && setFallbackContext(null);
|
|
5347
5347
|
const ee = {
|
|
5348
5348
|
version: VERSION,
|
|
5349
5349
|
locale: B.value,
|
|
5350
|
-
fallbackLocale:
|
|
5350
|
+
fallbackLocale: J.value,
|
|
5351
5351
|
messages: U.value,
|
|
5352
5352
|
modifiers: ie,
|
|
5353
|
-
pluralRules:
|
|
5354
|
-
missing:
|
|
5353
|
+
pluralRules: H,
|
|
5354
|
+
missing: oe === null ? void 0 : oe,
|
|
5355
5355
|
missingWarn: ce,
|
|
5356
5356
|
fallbackWarn: se,
|
|
5357
|
-
fallbackFormat:
|
|
5357
|
+
fallbackFormat: q,
|
|
5358
5358
|
unresolving: !0,
|
|
5359
|
-
postTranslation:
|
|
5360
|
-
warnHtmlMessage:
|
|
5361
|
-
escapeParameter:
|
|
5359
|
+
postTranslation: re === null ? void 0 : re,
|
|
5360
|
+
warnHtmlMessage: ae,
|
|
5361
|
+
escapeParameter: te,
|
|
5362
5362
|
messageResolver: e.messageResolver,
|
|
5363
5363
|
messageCompiler: e.messageCompiler,
|
|
5364
5364
|
__meta: { framework: "vue" }
|
|
5365
5365
|
};
|
|
5366
|
-
ee.datetimeFormats = V.value, ee.numberFormats =
|
|
5366
|
+
ee.datetimeFormats = V.value, ee.numberFormats = X.value, ee.__datetimeFormatters = isPlainObject$1($) ? $.__datetimeFormatters : void 0, ee.__numberFormatters = isPlainObject$1($) ? $.__numberFormatters : void 0, process.env.NODE_ENV !== "production" && (ee.__v_emitter = isPlainObject$1($) ? $.__v_emitter : void 0);
|
|
5367
5367
|
const le = createCoreContext(ee);
|
|
5368
5368
|
return c && setFallbackContext(le), le;
|
|
5369
|
-
})(), updateFallbackLocale($, B.value,
|
|
5369
|
+
})(), updateFallbackLocale($, B.value, J.value);
|
|
5370
5370
|
function pe() {
|
|
5371
5371
|
return [
|
|
5372
5372
|
B.value,
|
|
5373
|
-
|
|
5373
|
+
J.value,
|
|
5374
5374
|
U.value,
|
|
5375
5375
|
V.value,
|
|
5376
|
-
|
|
5376
|
+
X.value
|
|
5377
5377
|
];
|
|
5378
5378
|
}
|
|
5379
5379
|
const de = computed({
|
|
@@ -5381,28 +5381,28 @@ function createComposer(e = {}, t) {
|
|
|
5381
5381
|
set: (ee) => {
|
|
5382
5382
|
B.value = ee, $.locale = B.value;
|
|
5383
5383
|
}
|
|
5384
|
-
}),
|
|
5385
|
-
get: () =>
|
|
5384
|
+
}), me = computed({
|
|
5385
|
+
get: () => J.value,
|
|
5386
5386
|
set: (ee) => {
|
|
5387
|
-
|
|
5387
|
+
J.value = ee, $.fallbackLocale = J.value, updateFallbackLocale($, B.value, ee);
|
|
5388
5388
|
}
|
|
5389
|
-
}),
|
|
5389
|
+
}), Oe = computed(() => U.value), Ae = /* @__PURE__ */ computed(() => V.value), Ce = /* @__PURE__ */ computed(() => X.value);
|
|
5390
5390
|
function Ee() {
|
|
5391
|
-
return isFunction$1(
|
|
5391
|
+
return isFunction$1(re) ? re : null;
|
|
5392
5392
|
}
|
|
5393
5393
|
function Re(ee) {
|
|
5394
|
-
|
|
5394
|
+
re = ee, $.postTranslation = ee;
|
|
5395
5395
|
}
|
|
5396
5396
|
function Te() {
|
|
5397
|
-
return
|
|
5397
|
+
return Y;
|
|
5398
5398
|
}
|
|
5399
5399
|
function Fe(ee) {
|
|
5400
|
-
ee !== null && (
|
|
5400
|
+
ee !== null && (oe = defineCoreMissingHandler(ee)), Y = ee, $.missing = oe;
|
|
5401
5401
|
}
|
|
5402
5402
|
function ke(ee, le) {
|
|
5403
5403
|
return ee !== "translate" || !le.resolvedMessage;
|
|
5404
5404
|
}
|
|
5405
|
-
const he = (ee, le,
|
|
5405
|
+
const he = (ee, le, ve, we, je, Be) => {
|
|
5406
5406
|
pe();
|
|
5407
5407
|
let xe;
|
|
5408
5408
|
try {
|
|
@@ -5410,22 +5410,22 @@ function createComposer(e = {}, t) {
|
|
|
5410
5410
|
} finally {
|
|
5411
5411
|
process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, c || ($.fallbackContext = void 0);
|
|
5412
5412
|
}
|
|
5413
|
-
if (
|
|
5414
|
-
isNumber(xe) && xe === NOT_REOSLVED ||
|
|
5413
|
+
if (ve !== "translate exists" && // for not `te` (e.g `t`)
|
|
5414
|
+
isNumber(xe) && xe === NOT_REOSLVED || ve === "translate exists" && !xe) {
|
|
5415
5415
|
const [$e, We] = le();
|
|
5416
|
-
if (process.env.NODE_ENV !== "production" && n && isString$2($e) && ke(
|
|
5416
|
+
if (process.env.NODE_ENV !== "production" && n && isString$2($e) && ke(ve, We) && (ne && (isTranslateFallbackWarn(se, $e) || isTranslateMissingWarn(ce, $e)) && warn$2(getWarnMessage(I18nWarnCodes.FALLBACK_TO_ROOT, {
|
|
5417
5417
|
key: $e,
|
|
5418
|
-
type:
|
|
5418
|
+
type: ve
|
|
5419
5419
|
})), process.env.NODE_ENV !== "production")) {
|
|
5420
5420
|
const { __v_emitter: Ve } = $;
|
|
5421
|
-
Ve &&
|
|
5422
|
-
type:
|
|
5421
|
+
Ve && ne && Ve.emit("fallback", {
|
|
5422
|
+
type: ve,
|
|
5423
5423
|
key: $e,
|
|
5424
5424
|
to: "global",
|
|
5425
|
-
groupId: `${
|
|
5425
|
+
groupId: `${ve}:${$e}`
|
|
5426
5426
|
});
|
|
5427
5427
|
}
|
|
5428
|
-
return n &&
|
|
5428
|
+
return n && ne ? we(n) : je($e);
|
|
5429
5429
|
} else {
|
|
5430
5430
|
if (Be(xe))
|
|
5431
5431
|
return xe;
|
|
@@ -5436,10 +5436,10 @@ function createComposer(e = {}, t) {
|
|
|
5436
5436
|
return he((le) => Reflect.apply(translate, null, [le, ...ee]), () => parseTranslateArgs(...ee), "translate", (le) => Reflect.apply(le.t, le, [...ee]), (le) => le, (le) => isString$2(le));
|
|
5437
5437
|
}
|
|
5438
5438
|
function fe(...ee) {
|
|
5439
|
-
const [le,
|
|
5439
|
+
const [le, ve, we] = ee;
|
|
5440
5440
|
if (we && !isObject$2(we))
|
|
5441
5441
|
throw createI18nError(I18nErrorCodes.INVALID_ARGUMENT);
|
|
5442
|
-
return Le(le,
|
|
5442
|
+
return Le(le, ve, assign$1({ resolvedMessage: !0 }, we || {}));
|
|
5443
5443
|
}
|
|
5444
5444
|
function Pe(...ee) {
|
|
5445
5445
|
return he((le) => Reflect.apply(datetime, null, [le, ...ee]), () => parseDateTimeArgs(...ee), "datetime format", (le) => Reflect.apply(le.d, le, [...ee]), () => MISSING_RESOLVE_VALUE, (le) => isString$2(le));
|
|
@@ -5458,14 +5458,14 @@ function createComposer(e = {}, t) {
|
|
|
5458
5458
|
function D(...ee) {
|
|
5459
5459
|
return he(
|
|
5460
5460
|
(le) => {
|
|
5461
|
-
let
|
|
5461
|
+
let ve;
|
|
5462
5462
|
const we = le;
|
|
5463
5463
|
try {
|
|
5464
|
-
we.processor = be,
|
|
5464
|
+
we.processor = be, ve = Reflect.apply(translate, null, [we, ...ee]);
|
|
5465
5465
|
} finally {
|
|
5466
5466
|
we.processor = null;
|
|
5467
5467
|
}
|
|
5468
|
-
return
|
|
5468
|
+
return ve;
|
|
5469
5469
|
},
|
|
5470
5470
|
() => parseTranslateArgs(...ee),
|
|
5471
5471
|
"translate",
|
|
@@ -5498,21 +5498,21 @@ function createComposer(e = {}, t) {
|
|
|
5498
5498
|
);
|
|
5499
5499
|
}
|
|
5500
5500
|
function R(ee) {
|
|
5501
|
-
|
|
5501
|
+
H = ee, $.pluralRules = H;
|
|
5502
5502
|
}
|
|
5503
5503
|
function I(ee, le) {
|
|
5504
5504
|
return he(() => {
|
|
5505
5505
|
if (!ee)
|
|
5506
5506
|
return !1;
|
|
5507
|
-
const
|
|
5507
|
+
const ve = isString$2(le) ? le : B.value, we = j(ve), je = $.messageResolver(we, ee);
|
|
5508
5508
|
return A ? je != null : isMessageAST(je) || isMessageFunction(je) || isString$2(je);
|
|
5509
|
-
}, () => [ee], "translate exists", (
|
|
5509
|
+
}, () => [ee], "translate exists", (ve) => Reflect.apply(ve.te, ve, [ee, le]), NOOP_RETURN_FALSE, (ve) => isBoolean(ve));
|
|
5510
5510
|
}
|
|
5511
5511
|
function F(ee) {
|
|
5512
5512
|
let le = null;
|
|
5513
|
-
const
|
|
5514
|
-
for (let we = 0; we <
|
|
5515
|
-
const je = U.value[
|
|
5513
|
+
const ve = fallbackWithLocaleChain($, J.value, B.value);
|
|
5514
|
+
for (let we = 0; we < ve.length; we++) {
|
|
5515
|
+
const je = U.value[ve[we]] || {}, Be = $.messageResolver(je, ee);
|
|
5516
5516
|
if (Be != null) {
|
|
5517
5517
|
le = Be;
|
|
5518
5518
|
break;
|
|
@@ -5520,7 +5520,7 @@ function createComposer(e = {}, t) {
|
|
|
5520
5520
|
}
|
|
5521
5521
|
return le;
|
|
5522
5522
|
}
|
|
5523
|
-
function
|
|
5523
|
+
function G(ee) {
|
|
5524
5524
|
const le = F(ee);
|
|
5525
5525
|
return le ?? (n ? n.tm(ee) || {} : {});
|
|
5526
5526
|
}
|
|
@@ -5529,20 +5529,20 @@ function createComposer(e = {}, t) {
|
|
|
5529
5529
|
}
|
|
5530
5530
|
function K(ee, le) {
|
|
5531
5531
|
if (l) {
|
|
5532
|
-
const
|
|
5533
|
-
for (const we in
|
|
5534
|
-
hasOwn$1(
|
|
5535
|
-
le =
|
|
5532
|
+
const ve = { [ee]: le };
|
|
5533
|
+
for (const we in ve)
|
|
5534
|
+
hasOwn$1(ve, we) && handleFlatJson(ve[we]);
|
|
5535
|
+
le = ve[ee];
|
|
5536
5536
|
}
|
|
5537
5537
|
U.value[ee] = le, $.messages = U.value;
|
|
5538
5538
|
}
|
|
5539
5539
|
function Z(ee, le) {
|
|
5540
5540
|
U.value[ee] = U.value[ee] || {};
|
|
5541
|
-
const
|
|
5541
|
+
const ve = { [ee]: le };
|
|
5542
5542
|
if (l)
|
|
5543
|
-
for (const we in
|
|
5544
|
-
hasOwn$1(
|
|
5545
|
-
le =
|
|
5543
|
+
for (const we in ve)
|
|
5544
|
+
hasOwn$1(ve, we) && handleFlatJson(ve[we]);
|
|
5545
|
+
le = ve[ee], deepCopy(le, U.value[ee]), $.messages = U.value;
|
|
5546
5546
|
}
|
|
5547
5547
|
function z(ee) {
|
|
5548
5548
|
return V.value[ee] || {};
|
|
@@ -5550,42 +5550,42 @@ function createComposer(e = {}, t) {
|
|
|
5550
5550
|
function ue(ee, le) {
|
|
5551
5551
|
V.value[ee] = le, $.datetimeFormats = V.value, clearDateTimeFormat($, ee, le);
|
|
5552
5552
|
}
|
|
5553
|
-
function
|
|
5553
|
+
function ge(ee, le) {
|
|
5554
5554
|
V.value[ee] = assign$1(V.value[ee] || {}, le), $.datetimeFormats = V.value, clearDateTimeFormat($, ee, le);
|
|
5555
5555
|
}
|
|
5556
5556
|
function _e(ee) {
|
|
5557
|
-
return
|
|
5557
|
+
return X.value[ee] || {};
|
|
5558
5558
|
}
|
|
5559
5559
|
function ye(ee, le) {
|
|
5560
|
-
|
|
5560
|
+
X.value[ee] = le, $.numberFormats = X.value, clearNumberFormat($, ee, le);
|
|
5561
5561
|
}
|
|
5562
5562
|
function Se(ee, le) {
|
|
5563
|
-
|
|
5563
|
+
X.value[ee] = assign$1(X.value[ee] || {}, le), $.numberFormats = X.value, clearNumberFormat($, ee, le);
|
|
5564
5564
|
}
|
|
5565
5565
|
composerID++, n && inBrowser && (watch(n.locale, (ee) => {
|
|
5566
|
-
L && (B.value = ee, $.locale = ee, updateFallbackLocale($, B.value,
|
|
5566
|
+
L && (B.value = ee, $.locale = ee, updateFallbackLocale($, B.value, J.value));
|
|
5567
5567
|
}), watch(n.fallbackLocale, (ee) => {
|
|
5568
|
-
L && (
|
|
5568
|
+
L && (J.value = ee, $.fallbackLocale = ee, updateFallbackLocale($, B.value, J.value));
|
|
5569
5569
|
}));
|
|
5570
5570
|
const Ne = {
|
|
5571
5571
|
id: composerID,
|
|
5572
5572
|
locale: de,
|
|
5573
|
-
fallbackLocale:
|
|
5573
|
+
fallbackLocale: me,
|
|
5574
5574
|
get inheritLocale() {
|
|
5575
5575
|
return L;
|
|
5576
5576
|
},
|
|
5577
5577
|
set inheritLocale(ee) {
|
|
5578
|
-
L = ee, ee && n && (B.value = n.locale.value,
|
|
5578
|
+
L = ee, ee && n && (B.value = n.locale.value, J.value = n.fallbackLocale.value, updateFallbackLocale($, B.value, J.value));
|
|
5579
5579
|
},
|
|
5580
5580
|
get availableLocales() {
|
|
5581
5581
|
return Object.keys(U.value).sort();
|
|
5582
5582
|
},
|
|
5583
|
-
messages:
|
|
5583
|
+
messages: Oe,
|
|
5584
5584
|
get modifiers() {
|
|
5585
5585
|
return ie;
|
|
5586
5586
|
},
|
|
5587
5587
|
get pluralRules() {
|
|
5588
|
-
return
|
|
5588
|
+
return H || {};
|
|
5589
5589
|
},
|
|
5590
5590
|
get isGlobal() {
|
|
5591
5591
|
return c;
|
|
@@ -5603,28 +5603,28 @@ function createComposer(e = {}, t) {
|
|
|
5603
5603
|
se = ee, $.fallbackWarn = se;
|
|
5604
5604
|
},
|
|
5605
5605
|
get fallbackRoot() {
|
|
5606
|
-
return
|
|
5606
|
+
return ne;
|
|
5607
5607
|
},
|
|
5608
5608
|
set fallbackRoot(ee) {
|
|
5609
|
-
|
|
5609
|
+
ne = ee;
|
|
5610
5610
|
},
|
|
5611
5611
|
get fallbackFormat() {
|
|
5612
|
-
return
|
|
5612
|
+
return q;
|
|
5613
5613
|
},
|
|
5614
5614
|
set fallbackFormat(ee) {
|
|
5615
|
-
|
|
5615
|
+
q = ee, $.fallbackFormat = q;
|
|
5616
5616
|
},
|
|
5617
5617
|
get warnHtmlMessage() {
|
|
5618
|
-
return
|
|
5618
|
+
return ae;
|
|
5619
5619
|
},
|
|
5620
5620
|
set warnHtmlMessage(ee) {
|
|
5621
|
-
|
|
5621
|
+
ae = ee, $.warnHtmlMessage = ee;
|
|
5622
5622
|
},
|
|
5623
5623
|
get escapeParameter() {
|
|
5624
|
-
return
|
|
5624
|
+
return te;
|
|
5625
5625
|
},
|
|
5626
5626
|
set escapeParameter(ee) {
|
|
5627
|
-
|
|
5627
|
+
te = ee, $.escapeParameter = ee;
|
|
5628
5628
|
},
|
|
5629
5629
|
t: Le,
|
|
5630
5630
|
getLocaleMessage: j,
|
|
@@ -5636,31 +5636,31 @@ function createComposer(e = {}, t) {
|
|
|
5636
5636
|
setMissingHandler: Fe,
|
|
5637
5637
|
[SetPluralRulesSymbol]: R
|
|
5638
5638
|
};
|
|
5639
|
-
return Ne.datetimeFormats = Ae, Ne.numberFormats = Ce, Ne.rt = fe, Ne.te = I, Ne.tm =
|
|
5639
|
+
return Ne.datetimeFormats = Ae, Ne.numberFormats = Ce, Ne.rt = fe, Ne.te = I, Ne.tm = G, Ne.d = Pe, Ne.n = Me, Ne.getDateTimeFormat = z, Ne.setDateTimeFormat = ue, Ne.mergeDateTimeFormat = ge, Ne.getNumberFormat = _e, Ne.setNumberFormat = ye, Ne.mergeNumberFormat = Se, Ne[InejctWithOptionSymbol] = s, Ne[TranslateVNodeSymbol] = D, Ne[DatetimePartsSymbol] = W, Ne[NumberPartsSymbol] = M, process.env.NODE_ENV !== "production" && (Ne[EnableEmitter] = (ee) => {
|
|
5640
5640
|
$.__v_emitter = ee;
|
|
5641
5641
|
}, Ne[DisableEmitter] = () => {
|
|
5642
5642
|
$.__v_emitter = void 0;
|
|
5643
5643
|
}), Ne;
|
|
5644
5644
|
}
|
|
5645
5645
|
function convertComposerOptions(e) {
|
|
5646
|
-
const t = isString$2(e.locale) ? e.locale : DEFAULT_LOCALE, n = isString$2(e.fallbackLocale) || isArray$1(e.fallbackLocale) || isPlainObject$1(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : t, s = isFunction$1(e.missing) ? e.missing : void 0, c = isBoolean(e.silentTranslationWarn) || isRegExp(e.silentTranslationWarn) ? !e.silentTranslationWarn : !0, l = isBoolean(e.silentFallbackWarn) || isRegExp(e.silentFallbackWarn) ? !e.silentFallbackWarn : !0, C = isBoolean(e.fallbackRoot) ? e.fallbackRoot : !0, A = !!e.formatFallbackMessages, L = isPlainObject$1(e.modifiers) ? e.modifiers : {}, B = e.pluralizationRules,
|
|
5646
|
+
const t = isString$2(e.locale) ? e.locale : DEFAULT_LOCALE, n = isString$2(e.fallbackLocale) || isArray$1(e.fallbackLocale) || isPlainObject$1(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : t, s = isFunction$1(e.missing) ? e.missing : void 0, c = isBoolean(e.silentTranslationWarn) || isRegExp(e.silentTranslationWarn) ? !e.silentTranslationWarn : !0, l = isBoolean(e.silentFallbackWarn) || isRegExp(e.silentFallbackWarn) ? !e.silentFallbackWarn : !0, C = isBoolean(e.fallbackRoot) ? e.fallbackRoot : !0, A = !!e.formatFallbackMessages, L = isPlainObject$1(e.modifiers) ? e.modifiers : {}, B = e.pluralizationRules, J = isFunction$1(e.postTranslation) ? e.postTranslation : void 0, U = isString$2(e.warnHtmlInMessage) ? e.warnHtmlInMessage !== "off" : !0, V = !!e.escapeParameterHtml, X = isBoolean(e.sync) ? e.sync : !0;
|
|
5647
5647
|
process.env.NODE_ENV !== "production" && e.formatter && warn$2(getWarnMessage(I18nWarnCodes.NOT_SUPPORTED_FORMATTER)), process.env.NODE_ENV !== "production" && e.preserveDirectiveContent && warn$2(getWarnMessage(I18nWarnCodes.NOT_SUPPORTED_PRESERVE_DIRECTIVE));
|
|
5648
5648
|
let ce = e.messages;
|
|
5649
5649
|
if (isPlainObject$1(e.sharedMessages)) {
|
|
5650
|
-
const
|
|
5651
|
-
ce = Object.keys(
|
|
5652
|
-
const
|
|
5653
|
-
return assign$1(
|
|
5650
|
+
const te = e.sharedMessages;
|
|
5651
|
+
ce = Object.keys(te).reduce((H, $) => {
|
|
5652
|
+
const Q = H[$] || (H[$] = {});
|
|
5653
|
+
return assign$1(Q, te[$]), H;
|
|
5654
5654
|
}, ce || {});
|
|
5655
5655
|
}
|
|
5656
|
-
const { __i18n: se, __root:
|
|
5656
|
+
const { __i18n: se, __root: ne, __injectWithOption: q } = e, Y = e.datetimeFormats, oe = e.numberFormats, re = e.flatJson, ae = e.translateExistCompatible;
|
|
5657
5657
|
return {
|
|
5658
5658
|
locale: t,
|
|
5659
5659
|
fallbackLocale: n,
|
|
5660
5660
|
messages: ce,
|
|
5661
|
-
flatJson:
|
|
5662
|
-
datetimeFormats:
|
|
5663
|
-
numberFormats:
|
|
5661
|
+
flatJson: re,
|
|
5662
|
+
datetimeFormats: Y,
|
|
5663
|
+
numberFormats: oe,
|
|
5664
5664
|
missing: s,
|
|
5665
5665
|
missingWarn: c,
|
|
5666
5666
|
fallbackWarn: l,
|
|
@@ -5668,15 +5668,15 @@ function convertComposerOptions(e) {
|
|
|
5668
5668
|
fallbackFormat: A,
|
|
5669
5669
|
modifiers: L,
|
|
5670
5670
|
pluralRules: B,
|
|
5671
|
-
postTranslation:
|
|
5671
|
+
postTranslation: J,
|
|
5672
5672
|
warnHtmlMessage: U,
|
|
5673
5673
|
escapeParameter: V,
|
|
5674
5674
|
messageResolver: e.messageResolver,
|
|
5675
|
-
inheritLocale:
|
|
5676
|
-
translateExistCompatible:
|
|
5675
|
+
inheritLocale: X,
|
|
5676
|
+
translateExistCompatible: ae,
|
|
5677
5677
|
__i18n: se,
|
|
5678
|
-
__root:
|
|
5679
|
-
__injectWithOption:
|
|
5678
|
+
__root: ne,
|
|
5679
|
+
__injectWithOption: q
|
|
5680
5680
|
};
|
|
5681
5681
|
}
|
|
5682
5682
|
function createVueI18n(e = {}, t) {
|
|
@@ -5801,13 +5801,13 @@ function createVueI18n(e = {}, t) {
|
|
|
5801
5801
|
// t
|
|
5802
5802
|
t(...l) {
|
|
5803
5803
|
const [C, A, L] = l, B = {};
|
|
5804
|
-
let
|
|
5804
|
+
let J = null, U = null;
|
|
5805
5805
|
if (!isString$2(C))
|
|
5806
5806
|
throw createI18nError(I18nErrorCodes.INVALID_ARGUMENT);
|
|
5807
5807
|
const V = C;
|
|
5808
|
-
return isString$2(A) ? B.locale = A : isArray$1(A) ?
|
|
5808
|
+
return isString$2(A) ? B.locale = A : isArray$1(A) ? J = A : isPlainObject$1(A) && (U = A), isArray$1(L) ? J = L : isPlainObject$1(L) && (U = L), Reflect.apply(n.t, n, [
|
|
5809
5809
|
V,
|
|
5810
|
-
|
|
5810
|
+
J || U || {},
|
|
5811
5811
|
B
|
|
5812
5812
|
]);
|
|
5813
5813
|
},
|
|
@@ -5817,13 +5817,13 @@ function createVueI18n(e = {}, t) {
|
|
|
5817
5817
|
// tc
|
|
5818
5818
|
tc(...l) {
|
|
5819
5819
|
const [C, A, L] = l, B = { plural: 1 };
|
|
5820
|
-
let
|
|
5820
|
+
let J = null, U = null;
|
|
5821
5821
|
if (!isString$2(C))
|
|
5822
5822
|
throw createI18nError(I18nErrorCodes.INVALID_ARGUMENT);
|
|
5823
5823
|
const V = C;
|
|
5824
|
-
return isString$2(A) ? B.locale = A : isNumber(A) ? B.plural = A : isArray$1(A) ?
|
|
5824
|
+
return isString$2(A) ? B.locale = A : isNumber(A) ? B.plural = A : isArray$1(A) ? J = A : isPlainObject$1(A) && (U = A), isString$2(L) ? B.locale = L : isArray$1(L) ? J = L : isPlainObject$1(L) && (U = L), Reflect.apply(n.t, n, [
|
|
5825
5825
|
V,
|
|
5826
|
-
|
|
5826
|
+
J || U || {},
|
|
5827
5827
|
B
|
|
5828
5828
|
]);
|
|
5829
5829
|
},
|
|
@@ -5949,8 +5949,8 @@ const TranslationImpl = /* @__PURE__ */ defineComponent({
|
|
|
5949
5949
|
return () => {
|
|
5950
5950
|
const l = Object.keys(n).filter((U) => U !== "_"), C = {};
|
|
5951
5951
|
e.locale && (C.locale = e.locale), e.plural !== void 0 && (C.plural = isString$2(e.plural) ? +e.plural : e.plural);
|
|
5952
|
-
const A = getInterpolateArg(t, l), L = c[TranslateVNodeSymbol](e.keypath, A, C), B = assign$1({}, s),
|
|
5953
|
-
return h(
|
|
5952
|
+
const A = getInterpolateArg(t, l), L = c[TranslateVNodeSymbol](e.keypath, A, C), B = assign$1({}, s), J = isString$2(e.tag) || isObject$2(e.tag) ? e.tag : getFragmentableTag();
|
|
5953
|
+
return h(J, B, L);
|
|
5954
5954
|
};
|
|
5955
5955
|
}
|
|
5956
5956
|
}), Translation = TranslationImpl;
|
|
@@ -5962,15 +5962,15 @@ function renderFormatter(e, t, n, s) {
|
|
|
5962
5962
|
return () => {
|
|
5963
5963
|
const C = { part: !0 };
|
|
5964
5964
|
let A = {};
|
|
5965
|
-
e.locale && (C.locale = e.locale), isString$2(e.format) ? C.key = e.format : isObject$2(e.format) && (isString$2(e.format.key) && (C.key = e.format.key), A = Object.keys(e.format).reduce((V,
|
|
5965
|
+
e.locale && (C.locale = e.locale), isString$2(e.format) ? C.key = e.format : isObject$2(e.format) && (isString$2(e.format.key) && (C.key = e.format.key), A = Object.keys(e.format).reduce((V, X) => n.includes(X) ? assign$1({}, V, { [X]: e.format[X] }) : V, {}));
|
|
5966
5966
|
const L = s(e.value, C, A);
|
|
5967
5967
|
let B = [C.key];
|
|
5968
|
-
isArray$1(L) ? B = L.map((V,
|
|
5969
|
-
const ce = c[V.type], se = ce ? ce({ [V.type]: V.value, index:
|
|
5970
|
-
return isVNode(se) && (se[0].key = `${V.type}-${
|
|
5968
|
+
isArray$1(L) ? B = L.map((V, X) => {
|
|
5969
|
+
const ce = c[V.type], se = ce ? ce({ [V.type]: V.value, index: X, parts: L }) : [V.value];
|
|
5970
|
+
return isVNode(se) && (se[0].key = `${V.type}-${X}`), se;
|
|
5971
5971
|
}) : isString$2(L) && (B = [L]);
|
|
5972
|
-
const
|
|
5973
|
-
return h(U,
|
|
5972
|
+
const J = assign$1({}, l), U = isString$2(e.tag) || isObject$2(e.tag) ? e.tag : getFragmentableTag();
|
|
5973
|
+
return h(U, J, B);
|
|
5974
5974
|
};
|
|
5975
5975
|
}
|
|
5976
5976
|
const NumberFormatImpl = /* @__PURE__ */ defineComponent({
|
|
@@ -6036,12 +6036,12 @@ function vTDirective(e) {
|
|
|
6036
6036
|
const { instance: A, modifiers: L, value: B } = C;
|
|
6037
6037
|
if (!A || !A.$)
|
|
6038
6038
|
throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);
|
|
6039
|
-
const
|
|
6039
|
+
const J = getComposer$2(e, A.$);
|
|
6040
6040
|
process.env.NODE_ENV !== "production" && L.preserve && warn$2(getWarnMessage(I18nWarnCodes.NOT_SUPPORTED_PRESERVE));
|
|
6041
6041
|
const U = parseValue(B);
|
|
6042
6042
|
return [
|
|
6043
|
-
Reflect.apply(
|
|
6044
|
-
|
|
6043
|
+
Reflect.apply(J.t, J, [...makeParams(U)]),
|
|
6044
|
+
J
|
|
6045
6045
|
];
|
|
6046
6046
|
};
|
|
6047
6047
|
return {
|
|
@@ -6428,8 +6428,8 @@ function createI18n(e = {}, t) {
|
|
|
6428
6428
|
function B(V) {
|
|
6429
6429
|
return l.get(V) || null;
|
|
6430
6430
|
}
|
|
6431
|
-
function
|
|
6432
|
-
l.set(V,
|
|
6431
|
+
function J(V, X) {
|
|
6432
|
+
l.set(V, X);
|
|
6433
6433
|
}
|
|
6434
6434
|
function U(V) {
|
|
6435
6435
|
l.delete(V);
|
|
@@ -6445,28 +6445,28 @@ function createI18n(e = {}, t) {
|
|
|
6445
6445
|
return c;
|
|
6446
6446
|
},
|
|
6447
6447
|
// install plugin
|
|
6448
|
-
async install(
|
|
6449
|
-
if ((process.env.NODE_ENV !== "production" || __VUE_PROD_DEVTOOLS__) && (
|
|
6450
|
-
const
|
|
6451
|
-
V.__composerExtend =
|
|
6448
|
+
async install(X, ...ce) {
|
|
6449
|
+
if ((process.env.NODE_ENV !== "production" || __VUE_PROD_DEVTOOLS__) && (X.__VUE_I18N__ = V), X.__VUE_I18N_SYMBOL__ = L, X.provide(X.__VUE_I18N_SYMBOL__, V), isPlainObject$1(ce[0])) {
|
|
6450
|
+
const q = ce[0];
|
|
6451
|
+
V.__composerExtend = q.__composerExtend, V.__vueI18nExtend = q.__vueI18nExtend;
|
|
6452
6452
|
}
|
|
6453
6453
|
let se = null;
|
|
6454
|
-
!n && s && (se = injectGlobalFields(
|
|
6455
|
-
const
|
|
6456
|
-
if (
|
|
6457
|
-
se && se(), V.dispose(),
|
|
6454
|
+
!n && s && (se = injectGlobalFields(X, V.global)), __VUE_I18N_FULL_INSTALL__ && apply(X, V, ...ce), __VUE_I18N_LEGACY_API__ && n && X.mixin(defineMixin(A, A.__composer, V));
|
|
6455
|
+
const ne = X.unmount;
|
|
6456
|
+
if (X.unmount = () => {
|
|
6457
|
+
se && se(), V.dispose(), ne();
|
|
6458
6458
|
}, process.env.NODE_ENV !== "production" || __VUE_PROD_DEVTOOLS__) {
|
|
6459
|
-
if (!await enableDevTools(
|
|
6459
|
+
if (!await enableDevTools(X, V))
|
|
6460
6460
|
throw createI18nError(I18nErrorCodes.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN);
|
|
6461
|
-
const
|
|
6461
|
+
const Y = createEmitter();
|
|
6462
6462
|
if (n) {
|
|
6463
|
-
const
|
|
6464
|
-
|
|
6463
|
+
const oe = A;
|
|
6464
|
+
oe.__enableEmitter && oe.__enableEmitter(Y);
|
|
6465
6465
|
} else {
|
|
6466
|
-
const
|
|
6467
|
-
|
|
6466
|
+
const oe = A;
|
|
6467
|
+
oe[EnableEmitter] && oe[EnableEmitter](Y);
|
|
6468
6468
|
}
|
|
6469
|
-
|
|
6469
|
+
Y.on("*", addTimelineEvent);
|
|
6470
6470
|
}
|
|
6471
6471
|
},
|
|
6472
6472
|
// global accessor
|
|
@@ -6481,7 +6481,7 @@ function createI18n(e = {}, t) {
|
|
|
6481
6481
|
// @internal
|
|
6482
6482
|
__getInstance: B,
|
|
6483
6483
|
// @internal
|
|
6484
|
-
__setInstance:
|
|
6484
|
+
__setInstance: J,
|
|
6485
6485
|
// @internal
|
|
6486
6486
|
__deleteInstance: U
|
|
6487
6487
|
};
|
|
@@ -6583,13 +6583,13 @@ function useI18nForLegacy(e, t, n, s = {}) {
|
|
|
6583
6583
|
), L = ref(
|
|
6584
6584
|
// prettier-ignore
|
|
6585
6585
|
!c || C ? n.fallbackLocale.value : isString$2(s.fallbackLocale) || isArray$1(s.fallbackLocale) || isPlainObject$1(s.fallbackLocale) || s.fallbackLocale === !1 ? s.fallbackLocale : A.value
|
|
6586
|
-
), B = ref(getLocaleMessages(A.value, s)),
|
|
6587
|
-
function
|
|
6586
|
+
), B = ref(getLocaleMessages(A.value, s)), J = ref(isPlainObject$1(s.datetimeFormats) ? s.datetimeFormats : { [A.value]: {} }), U = ref(isPlainObject$1(s.numberFormats) ? s.numberFormats : { [A.value]: {} }), V = c ? n.missingWarn : isBoolean(s.missingWarn) || isRegExp(s.missingWarn) ? s.missingWarn : !0, X = c ? n.fallbackWarn : isBoolean(s.fallbackWarn) || isRegExp(s.fallbackWarn) ? s.fallbackWarn : !0, ce = c ? n.fallbackRoot : isBoolean(s.fallbackRoot) ? s.fallbackRoot : !0, se = !!s.fallbackFormat, ne = isFunction$1(s.missing) ? s.missing : null, q = isFunction$1(s.postTranslation) ? s.postTranslation : null, Y = c ? n.warnHtmlMessage : isBoolean(s.warnHtmlMessage) ? s.warnHtmlMessage : !0, oe = !!s.escapeParameter, re = c ? n.modifiers : isPlainObject$1(s.modifiers) ? s.modifiers : {}, ae = s.pluralRules || c && n.pluralRules;
|
|
6587
|
+
function te() {
|
|
6588
6588
|
return [
|
|
6589
6589
|
A.value,
|
|
6590
6590
|
L.value,
|
|
6591
6591
|
B.value,
|
|
6592
|
-
|
|
6592
|
+
J.value,
|
|
6593
6593
|
U.value
|
|
6594
6594
|
];
|
|
6595
6595
|
}
|
|
@@ -6598,26 +6598,26 @@ function useI18nForLegacy(e, t, n, s = {}) {
|
|
|
6598
6598
|
set: (I) => {
|
|
6599
6599
|
l.value && (l.value.locale.value = I), A.value = I;
|
|
6600
6600
|
}
|
|
6601
|
-
}),
|
|
6601
|
+
}), H = computed({
|
|
6602
6602
|
get: () => l.value ? l.value.fallbackLocale.value : L.value,
|
|
6603
6603
|
set: (I) => {
|
|
6604
6604
|
l.value && (l.value.fallbackLocale.value = I), L.value = I;
|
|
6605
6605
|
}
|
|
6606
|
-
}), $ = computed(() => l.value ? l.value.messages.value : B.value),
|
|
6606
|
+
}), $ = computed(() => l.value ? l.value.messages.value : B.value), Q = computed(() => J.value), pe = computed(() => U.value);
|
|
6607
6607
|
function de() {
|
|
6608
|
-
return l.value ? l.value.getPostTranslationHandler() :
|
|
6608
|
+
return l.value ? l.value.getPostTranslationHandler() : q;
|
|
6609
6609
|
}
|
|
6610
|
-
function
|
|
6610
|
+
function me(I) {
|
|
6611
6611
|
l.value && l.value.setPostTranslationHandler(I);
|
|
6612
6612
|
}
|
|
6613
|
-
function
|
|
6614
|
-
return l.value ? l.value.getMissingHandler() :
|
|
6613
|
+
function Oe() {
|
|
6614
|
+
return l.value ? l.value.getMissingHandler() : ne;
|
|
6615
6615
|
}
|
|
6616
6616
|
function Ae(I) {
|
|
6617
6617
|
l.value && l.value.setMissingHandler(I);
|
|
6618
6618
|
}
|
|
6619
6619
|
function Ce(I) {
|
|
6620
|
-
return
|
|
6620
|
+
return te(), I();
|
|
6621
6621
|
}
|
|
6622
6622
|
function Ee(...I) {
|
|
6623
6623
|
return l.value ? Ce(() => Reflect.apply(l.value.t, null, [...I])) : Ce(() => "");
|
|
@@ -6650,7 +6650,7 @@ function useI18nForLegacy(e, t, n, s = {}) {
|
|
|
6650
6650
|
return l.value ? l.value.getDateTimeFormat(I) : {};
|
|
6651
6651
|
}
|
|
6652
6652
|
function De(I, F) {
|
|
6653
|
-
l.value && (l.value.setDateTimeFormat(I, F),
|
|
6653
|
+
l.value && (l.value.setDateTimeFormat(I, F), J.value[I] = F);
|
|
6654
6654
|
}
|
|
6655
6655
|
function Ie(I, F) {
|
|
6656
6656
|
l.value && l.value.mergeDateTimeFormat(I, F);
|
|
@@ -6669,9 +6669,9 @@ function useI18nForLegacy(e, t, n, s = {}) {
|
|
|
6669
6669
|
return l.value ? l.value.id : -1;
|
|
6670
6670
|
},
|
|
6671
6671
|
locale: ie,
|
|
6672
|
-
fallbackLocale:
|
|
6672
|
+
fallbackLocale: H,
|
|
6673
6673
|
messages: $,
|
|
6674
|
-
datetimeFormats:
|
|
6674
|
+
datetimeFormats: Q,
|
|
6675
6675
|
numberFormats: pe,
|
|
6676
6676
|
get inheritLocale() {
|
|
6677
6677
|
return l.value ? l.value.inheritLocale : C;
|
|
@@ -6683,10 +6683,10 @@ function useI18nForLegacy(e, t, n, s = {}) {
|
|
|
6683
6683
|
return l.value ? l.value.availableLocales : Object.keys(B.value);
|
|
6684
6684
|
},
|
|
6685
6685
|
get modifiers() {
|
|
6686
|
-
return l.value ? l.value.modifiers :
|
|
6686
|
+
return l.value ? l.value.modifiers : re;
|
|
6687
6687
|
},
|
|
6688
6688
|
get pluralRules() {
|
|
6689
|
-
return l.value ? l.value.pluralRules :
|
|
6689
|
+
return l.value ? l.value.pluralRules : ae;
|
|
6690
6690
|
},
|
|
6691
6691
|
get isGlobal() {
|
|
6692
6692
|
return l.value ? l.value.isGlobal : !1;
|
|
@@ -6698,7 +6698,7 @@ function useI18nForLegacy(e, t, n, s = {}) {
|
|
|
6698
6698
|
l.value && (l.value.missingWarn = I);
|
|
6699
6699
|
},
|
|
6700
6700
|
get fallbackWarn() {
|
|
6701
|
-
return l.value ? l.value.fallbackWarn :
|
|
6701
|
+
return l.value ? l.value.fallbackWarn : X;
|
|
6702
6702
|
},
|
|
6703
6703
|
set fallbackWarn(I) {
|
|
6704
6704
|
l.value && (l.value.missingWarn = I);
|
|
@@ -6716,21 +6716,21 @@ function useI18nForLegacy(e, t, n, s = {}) {
|
|
|
6716
6716
|
l.value && (l.value.fallbackFormat = I);
|
|
6717
6717
|
},
|
|
6718
6718
|
get warnHtmlMessage() {
|
|
6719
|
-
return l.value ? l.value.warnHtmlMessage :
|
|
6719
|
+
return l.value ? l.value.warnHtmlMessage : Y;
|
|
6720
6720
|
},
|
|
6721
6721
|
set warnHtmlMessage(I) {
|
|
6722
6722
|
l.value && (l.value.warnHtmlMessage = I);
|
|
6723
6723
|
},
|
|
6724
6724
|
get escapeParameter() {
|
|
6725
|
-
return l.value ? l.value.escapeParameter :
|
|
6725
|
+
return l.value ? l.value.escapeParameter : oe;
|
|
6726
6726
|
},
|
|
6727
6727
|
set escapeParameter(I) {
|
|
6728
6728
|
l.value && (l.value.escapeParameter = I);
|
|
6729
6729
|
},
|
|
6730
6730
|
t: Ee,
|
|
6731
6731
|
getPostTranslationHandler: de,
|
|
6732
|
-
setPostTranslationHandler:
|
|
6733
|
-
getMissingHandler:
|
|
6732
|
+
setPostTranslationHandler: me,
|
|
6733
|
+
getMissingHandler: Oe,
|
|
6734
6734
|
setMissingHandler: Ae,
|
|
6735
6735
|
rt: Re,
|
|
6736
6736
|
d: Te,
|
|
@@ -6750,17 +6750,17 @@ function useI18nForLegacy(e, t, n, s = {}) {
|
|
|
6750
6750
|
function R(I) {
|
|
6751
6751
|
I.locale.value = A.value, I.fallbackLocale.value = L.value, Object.keys(B.value).forEach((F) => {
|
|
6752
6752
|
I.mergeLocaleMessage(F, B.value[F]);
|
|
6753
|
-
}), Object.keys(
|
|
6754
|
-
I.mergeDateTimeFormat(F,
|
|
6753
|
+
}), Object.keys(J.value).forEach((F) => {
|
|
6754
|
+
I.mergeDateTimeFormat(F, J.value[F]);
|
|
6755
6755
|
}), Object.keys(U.value).forEach((F) => {
|
|
6756
6756
|
I.mergeNumberFormat(F, U.value[F]);
|
|
6757
|
-
}), I.escapeParameter =
|
|
6757
|
+
}), I.escapeParameter = oe, I.fallbackFormat = se, I.fallbackRoot = ce, I.fallbackWarn = X, I.missingWarn = V, I.warnHtmlMessage = Y;
|
|
6758
6758
|
}
|
|
6759
6759
|
return onBeforeMount(() => {
|
|
6760
6760
|
if (e.proxy == null || e.proxy.$i18n == null)
|
|
6761
6761
|
throw createI18nError(I18nErrorCodes.NOT_AVAILABLE_COMPOSITION_IN_LEGACY);
|
|
6762
6762
|
const I = l.value = e.proxy.$i18n.__composer;
|
|
6763
|
-
t === "global" ? (A.value = I.locale.value, L.value = I.fallbackLocale.value, B.value = I.messages.value,
|
|
6763
|
+
t === "global" ? (A.value = I.locale.value, L.value = I.fallbackLocale.value, B.value = I.messages.value, J.value = I.datetimeFormats.value, U.value = I.numberFormats.value) : c && R(I);
|
|
6764
6764
|
}), W;
|
|
6765
6765
|
}
|
|
6766
6766
|
const globalExportProps = [
|
|
@@ -6859,44 +6859,44 @@ License: MIT
|
|
|
6859
6859
|
(function(n, s) {
|
|
6860
6860
|
e.exports = s();
|
|
6861
6861
|
})(commonjsGlobal, function n() {
|
|
6862
|
-
var s = typeof self < "u" ? self : typeof window < "u" ? window : s !== void 0 ? s : {}, c = !s.document && !!s.postMessage, l = s.IS_PAPA_WORKER || !1, C = {}, A = 0, L = { parse: function(
|
|
6863
|
-
var
|
|
6864
|
-
if (ie(
|
|
6862
|
+
var s = typeof self < "u" ? self : typeof window < "u" ? window : s !== void 0 ? s : {}, c = !s.document && !!s.postMessage, l = s.IS_PAPA_WORKER || !1, C = {}, A = 0, L = { parse: function(H, $) {
|
|
6863
|
+
var Q = ($ = $ || {}).dynamicTyping || !1;
|
|
6864
|
+
if (ie(Q) && ($.dynamicTypingFunction = Q, Q = {}), $.dynamicTyping = Q, $.transform = !!ie($.transform) && $.transform, $.worker && L.WORKERS_SUPPORTED) {
|
|
6865
6865
|
var pe = function() {
|
|
6866
6866
|
if (!L.WORKERS_SUPPORTED)
|
|
6867
6867
|
return !1;
|
|
6868
|
-
var
|
|
6869
|
-
return
|
|
6868
|
+
var me = (Ae = s.URL || s.webkitURL || null, Ce = n.toString(), L.BLOB_URL || (L.BLOB_URL = Ae.createObjectURL(new Blob(["var global = (function() { if (typeof self !== 'undefined') { return self; } if (typeof window !== 'undefined') { return window; } if (typeof global !== 'undefined') { return global; } return {}; })(); global.IS_PAPA_WORKER=true; ", "(", Ce, ")();"], { type: "text/javascript" })))), Oe = new s.Worker(me), Ae, Ce;
|
|
6869
|
+
return Oe.onmessage = Y, Oe.id = A++, C[Oe.id] = Oe;
|
|
6870
6870
|
}();
|
|
6871
|
-
return pe.userStep = $.step, pe.userChunk = $.chunk, pe.userComplete = $.complete, pe.userError = $.error, $.step = ie($.step), $.chunk = ie($.chunk), $.complete = ie($.complete), $.error = ie($.error), delete $.worker, void pe.postMessage({ input:
|
|
6871
|
+
return pe.userStep = $.step, pe.userChunk = $.chunk, pe.userComplete = $.complete, pe.userError = $.error, $.step = ie($.step), $.chunk = ie($.chunk), $.complete = ie($.complete), $.error = ie($.error), delete $.worker, void pe.postMessage({ input: H, config: $, workerId: pe.id });
|
|
6872
6872
|
}
|
|
6873
6873
|
var de = null;
|
|
6874
|
-
return L.NODE_STREAM_INPUT, typeof
|
|
6875
|
-
return
|
|
6876
|
-
}(
|
|
6877
|
-
}, unparse: function(
|
|
6878
|
-
var
|
|
6879
|
-
`,
|
|
6874
|
+
return L.NODE_STREAM_INPUT, typeof H == "string" ? (H = function(me) {
|
|
6875
|
+
return me.charCodeAt(0) === 65279 ? me.slice(1) : me;
|
|
6876
|
+
}(H), de = $.download ? new U($) : new X($)) : H.readable === !0 && ie(H.read) && ie(H.on) ? de = new ce($) : (s.File && H instanceof File || H instanceof Object) && (de = new V($)), de.stream(H);
|
|
6877
|
+
}, unparse: function(H, $) {
|
|
6878
|
+
var Q = !1, pe = !0, de = ",", me = `\r
|
|
6879
|
+
`, Oe = '"', Ae = Oe + Oe, Ce = !1, Ee = null, Re = !1;
|
|
6880
6880
|
(function() {
|
|
6881
6881
|
if (typeof $ == "object") {
|
|
6882
6882
|
if (typeof $.delimiter != "string" || L.BAD_DELIMITERS.filter(function(he) {
|
|
6883
6883
|
return $.delimiter.indexOf(he) !== -1;
|
|
6884
|
-
}).length || (de = $.delimiter), (typeof $.quotes == "boolean" || typeof $.quotes == "function" || Array.isArray($.quotes)) && (
|
|
6884
|
+
}).length || (de = $.delimiter), (typeof $.quotes == "boolean" || typeof $.quotes == "function" || Array.isArray($.quotes)) && (Q = $.quotes), typeof $.skipEmptyLines != "boolean" && typeof $.skipEmptyLines != "string" || (Ce = $.skipEmptyLines), typeof $.newline == "string" && (me = $.newline), typeof $.quoteChar == "string" && (Oe = $.quoteChar), typeof $.header == "boolean" && (pe = $.header), Array.isArray($.columns)) {
|
|
6885
6885
|
if ($.columns.length === 0)
|
|
6886
6886
|
throw new Error("Option columns is empty");
|
|
6887
6887
|
Ee = $.columns;
|
|
6888
6888
|
}
|
|
6889
|
-
$.escapeChar !== void 0 && (Ae = $.escapeChar +
|
|
6889
|
+
$.escapeChar !== void 0 && (Ae = $.escapeChar + Oe), (typeof $.escapeFormulae == "boolean" || $.escapeFormulae instanceof RegExp) && (Re = $.escapeFormulae instanceof RegExp ? $.escapeFormulae : /^[=+\-@\t\r].*$/);
|
|
6890
6890
|
}
|
|
6891
6891
|
})();
|
|
6892
|
-
var Te = new RegExp(
|
|
6893
|
-
if (typeof
|
|
6894
|
-
if (!
|
|
6895
|
-
return Fe(null,
|
|
6896
|
-
if (typeof
|
|
6897
|
-
return Fe(Ee || Object.keys(
|
|
6898
|
-
} else if (typeof
|
|
6899
|
-
return typeof
|
|
6892
|
+
var Te = new RegExp(ne(Oe), "g");
|
|
6893
|
+
if (typeof H == "string" && (H = JSON.parse(H)), Array.isArray(H)) {
|
|
6894
|
+
if (!H.length || Array.isArray(H[0]))
|
|
6895
|
+
return Fe(null, H, Ce);
|
|
6896
|
+
if (typeof H[0] == "object")
|
|
6897
|
+
return Fe(Ee || Object.keys(H[0]), H, Ce);
|
|
6898
|
+
} else if (typeof H == "object")
|
|
6899
|
+
return typeof H.data == "string" && (H.data = JSON.parse(H.data)), Array.isArray(H.data) && (H.fields || (H.fields = H.meta && H.meta.fields || Ee), H.fields || (H.fields = Array.isArray(H.data[0]) ? H.fields : typeof H.data[0] == "object" ? Object.keys(H.data[0]) : []), Array.isArray(H.data[0]) || typeof H.data[0] == "object" || (H.data = [H.data])), Fe(H.fields || [], H.data || [], Ce);
|
|
6900
6900
|
throw new Error("Unable to serialize unrecognized input");
|
|
6901
6901
|
function Fe(he, Le, fe) {
|
|
6902
6902
|
var Pe = "";
|
|
@@ -6905,7 +6905,7 @@ License: MIT
|
|
|
6905
6905
|
if (Me && pe) {
|
|
6906
6906
|
for (var Ie = 0; Ie < he.length; Ie++)
|
|
6907
6907
|
0 < Ie && (Pe += de), Pe += ke(he[Ie], Ie);
|
|
6908
|
-
0 < Le.length && (Pe +=
|
|
6908
|
+
0 < Le.length && (Pe += me);
|
|
6909
6909
|
}
|
|
6910
6910
|
for (var be = 0; be < Le.length; be++) {
|
|
6911
6911
|
var D = Me ? he.length : Le[be].length, M = !1, W = Me ? Object.keys(Le[be]).length === 0 : Le[be].length === 0;
|
|
@@ -6917,12 +6917,12 @@ License: MIT
|
|
|
6917
6917
|
M = R.join("").trim() === "";
|
|
6918
6918
|
}
|
|
6919
6919
|
if (!M) {
|
|
6920
|
-
for (var
|
|
6921
|
-
0 <
|
|
6922
|
-
var j = Me && De ? he[
|
|
6923
|
-
Pe += ke(Le[be][j],
|
|
6920
|
+
for (var G = 0; G < D; G++) {
|
|
6921
|
+
0 < G && !W && (Pe += de);
|
|
6922
|
+
var j = Me && De ? he[G] : G;
|
|
6923
|
+
Pe += ke(Le[be][j], G);
|
|
6924
6924
|
}
|
|
6925
|
-
be < Le.length - 1 && (!fe || 0 < D && !W) && (Pe +=
|
|
6925
|
+
be < Le.length - 1 && (!fe || 0 < D && !W) && (Pe += me);
|
|
6926
6926
|
}
|
|
6927
6927
|
}
|
|
6928
6928
|
return Pe;
|
|
@@ -6935,33 +6935,33 @@ License: MIT
|
|
|
6935
6935
|
var fe = !1;
|
|
6936
6936
|
Re && typeof he == "string" && Re.test(he) && (he = "'" + he, fe = !0);
|
|
6937
6937
|
var Pe = he.toString().replace(Te, Ae);
|
|
6938
|
-
return (fe = fe ||
|
|
6938
|
+
return (fe = fe || Q === !0 || typeof Q == "function" && Q(he, Le) || Array.isArray(Q) && Q[Le] || function(Me, De) {
|
|
6939
6939
|
for (var Ie = 0; Ie < De.length; Ie++)
|
|
6940
6940
|
if (-1 < Me.indexOf(De[Ie]))
|
|
6941
6941
|
return !0;
|
|
6942
6942
|
return !1;
|
|
6943
|
-
}(Pe, L.BAD_DELIMITERS) || -1 < Pe.indexOf(de) || Pe.charAt(0) === " " || Pe.charAt(Pe.length - 1) === " ") ?
|
|
6943
|
+
}(Pe, L.BAD_DELIMITERS) || -1 < Pe.indexOf(de) || Pe.charAt(0) === " " || Pe.charAt(Pe.length - 1) === " ") ? Oe + Pe + Oe : Pe;
|
|
6944
6944
|
}
|
|
6945
6945
|
} };
|
|
6946
6946
|
if (L.RECORD_SEP = String.fromCharCode(30), L.UNIT_SEP = String.fromCharCode(31), L.BYTE_ORDER_MARK = "\uFEFF", L.BAD_DELIMITERS = ["\r", `
|
|
6947
|
-
`, '"', L.BYTE_ORDER_MARK], L.WORKERS_SUPPORTED = !c && !!s.Worker, L.NODE_STREAM_INPUT = 1, L.LocalChunkSize = 10485760, L.RemoteChunkSize = 5242880, L.DefaultDelimiter = ",", L.Parser =
|
|
6947
|
+
`, '"', L.BYTE_ORDER_MARK], L.WORKERS_SUPPORTED = !c && !!s.Worker, L.NODE_STREAM_INPUT = 1, L.LocalChunkSize = 10485760, L.RemoteChunkSize = 5242880, L.DefaultDelimiter = ",", L.Parser = q, L.ParserHandle = se, L.NetworkStreamer = U, L.FileStreamer = V, L.StringStreamer = X, L.ReadableStreamStreamer = ce, s.jQuery) {
|
|
6948
6948
|
var B = s.jQuery;
|
|
6949
|
-
B.fn.parse = function(
|
|
6950
|
-
var $ =
|
|
6951
|
-
return this.each(function(
|
|
6949
|
+
B.fn.parse = function(H) {
|
|
6950
|
+
var $ = H.config || {}, Q = [];
|
|
6951
|
+
return this.each(function(me) {
|
|
6952
6952
|
if (!(B(this).prop("tagName").toUpperCase() === "INPUT" && B(this).attr("type").toLowerCase() === "file" && s.FileReader) || !this.files || this.files.length === 0)
|
|
6953
6953
|
return !0;
|
|
6954
|
-
for (var
|
|
6955
|
-
|
|
6954
|
+
for (var Oe = 0; Oe < this.files.length; Oe++)
|
|
6955
|
+
Q.push({ file: this.files[Oe], inputElem: this, instanceConfig: B.extend({}, $) });
|
|
6956
6956
|
}), pe(), this;
|
|
6957
6957
|
function pe() {
|
|
6958
|
-
if (
|
|
6959
|
-
var
|
|
6960
|
-
if (ie(
|
|
6961
|
-
var Re =
|
|
6958
|
+
if (Q.length !== 0) {
|
|
6959
|
+
var me, Oe, Ae, Ce, Ee = Q[0];
|
|
6960
|
+
if (ie(H.before)) {
|
|
6961
|
+
var Re = H.before(Ee.file, Ee.inputElem);
|
|
6962
6962
|
if (typeof Re == "object") {
|
|
6963
6963
|
if (Re.action === "abort")
|
|
6964
|
-
return
|
|
6964
|
+
return me = "AbortError", Oe = Ee.file, Ae = Ee.inputElem, Ce = Re.reason, void (ie(H.error) && H.error({ name: me }, Oe, Ae, Ce));
|
|
6965
6965
|
if (Re.action === "skip")
|
|
6966
6966
|
return void de();
|
|
6967
6967
|
typeof Re.config == "object" && (Ee.instanceConfig = B.extend(Ee.instanceConfig, Re.config));
|
|
@@ -6973,18 +6973,18 @@ License: MIT
|
|
|
6973
6973
|
ie(Te) && Te(Fe, Ee.file, Ee.inputElem), de();
|
|
6974
6974
|
}, L.parse(Ee.file, Ee.instanceConfig);
|
|
6975
6975
|
} else
|
|
6976
|
-
ie(
|
|
6976
|
+
ie(H.complete) && H.complete();
|
|
6977
6977
|
}
|
|
6978
6978
|
function de() {
|
|
6979
|
-
|
|
6979
|
+
Q.splice(0, 1), pe();
|
|
6980
6980
|
}
|
|
6981
6981
|
};
|
|
6982
6982
|
}
|
|
6983
|
-
function
|
|
6983
|
+
function J(H) {
|
|
6984
6984
|
this._handle = null, this._finished = !1, this._completed = !1, this._halted = !1, this._input = null, this._baseIndex = 0, this._partialLine = "", this._rowCount = 0, this._start = 0, this._nextChunk = null, this.isFirstChunk = !0, this._completeResults = { data: [], errors: [], meta: {} }, (function($) {
|
|
6985
|
-
var
|
|
6986
|
-
|
|
6987
|
-
}).call(this,
|
|
6985
|
+
var Q = ae($);
|
|
6986
|
+
Q.chunkSize = parseInt(Q.chunkSize), $.step || $.chunk || (Q.chunkSize = null), this._handle = new se(Q), (this._handle.streamer = this)._config = Q;
|
|
6987
|
+
}).call(this, H), this.parseChunk = function($, Q) {
|
|
6988
6988
|
if (this.isFirstChunk && ie(this._config.beforeFirstChunk)) {
|
|
6989
6989
|
var pe = this._config.beforeFirstChunk($);
|
|
6990
6990
|
pe !== void 0 && ($ = pe);
|
|
@@ -6992,41 +6992,41 @@ License: MIT
|
|
|
6992
6992
|
this.isFirstChunk = !1, this._halted = !1;
|
|
6993
6993
|
var de = this._partialLine + $;
|
|
6994
6994
|
this._partialLine = "";
|
|
6995
|
-
var
|
|
6995
|
+
var me = this._handle.parse(de, this._baseIndex, !this._finished);
|
|
6996
6996
|
if (!this._handle.paused() && !this._handle.aborted()) {
|
|
6997
|
-
var
|
|
6998
|
-
this._finished || (this._partialLine = de.substring(
|
|
6997
|
+
var Oe = me.meta.cursor;
|
|
6998
|
+
this._finished || (this._partialLine = de.substring(Oe - this._baseIndex), this._baseIndex = Oe), me && me.data && (this._rowCount += me.data.length);
|
|
6999
6999
|
var Ae = this._finished || this._config.preview && this._rowCount >= this._config.preview;
|
|
7000
7000
|
if (l)
|
|
7001
|
-
s.postMessage({ results:
|
|
7002
|
-
else if (ie(this._config.chunk) && !
|
|
7003
|
-
if (this._config.chunk(
|
|
7001
|
+
s.postMessage({ results: me, workerId: L.WORKER_ID, finished: Ae });
|
|
7002
|
+
else if (ie(this._config.chunk) && !Q) {
|
|
7003
|
+
if (this._config.chunk(me, this._handle), this._handle.paused() || this._handle.aborted())
|
|
7004
7004
|
return void (this._halted = !0);
|
|
7005
|
-
|
|
7005
|
+
me = void 0, this._completeResults = void 0;
|
|
7006
7006
|
}
|
|
7007
|
-
return this._config.step || this._config.chunk || (this._completeResults.data = this._completeResults.data.concat(
|
|
7007
|
+
return this._config.step || this._config.chunk || (this._completeResults.data = this._completeResults.data.concat(me.data), this._completeResults.errors = this._completeResults.errors.concat(me.errors), this._completeResults.meta = me.meta), this._completed || !Ae || !ie(this._config.complete) || me && me.meta.aborted || (this._config.complete(this._completeResults, this._input), this._completed = !0), Ae || me && me.meta.paused || this._nextChunk(), me;
|
|
7008
7008
|
}
|
|
7009
7009
|
this._halted = !0;
|
|
7010
7010
|
}, this._sendError = function($) {
|
|
7011
7011
|
ie(this._config.error) ? this._config.error($) : l && this._config.error && s.postMessage({ workerId: L.WORKER_ID, error: $, finished: !1 });
|
|
7012
7012
|
};
|
|
7013
7013
|
}
|
|
7014
|
-
function U(
|
|
7014
|
+
function U(H) {
|
|
7015
7015
|
var $;
|
|
7016
|
-
(
|
|
7016
|
+
(H = H || {}).chunkSize || (H.chunkSize = L.RemoteChunkSize), J.call(this, H), this._nextChunk = c ? function() {
|
|
7017
7017
|
this._readChunk(), this._chunkLoaded();
|
|
7018
7018
|
} : function() {
|
|
7019
7019
|
this._readChunk();
|
|
7020
|
-
}, this.stream = function(
|
|
7021
|
-
this._input =
|
|
7020
|
+
}, this.stream = function(Q) {
|
|
7021
|
+
this._input = Q, this._nextChunk();
|
|
7022
7022
|
}, this._readChunk = function() {
|
|
7023
7023
|
if (this._finished)
|
|
7024
7024
|
this._chunkLoaded();
|
|
7025
7025
|
else {
|
|
7026
|
-
if ($ = new XMLHttpRequest(), this._config.withCredentials && ($.withCredentials = this._config.withCredentials), c || ($.onload =
|
|
7027
|
-
var
|
|
7028
|
-
for (var pe in
|
|
7029
|
-
$.setRequestHeader(pe,
|
|
7026
|
+
if ($ = new XMLHttpRequest(), this._config.withCredentials && ($.withCredentials = this._config.withCredentials), c || ($.onload = te(this._chunkLoaded, this), $.onerror = te(this._chunkError, this)), $.open(this._config.downloadRequestBody ? "POST" : "GET", this._input, !c), this._config.downloadRequestHeaders) {
|
|
7027
|
+
var Q = this._config.downloadRequestHeaders;
|
|
7028
|
+
for (var pe in Q)
|
|
7029
|
+
$.setRequestHeader(pe, Q[pe]);
|
|
7030
7030
|
}
|
|
7031
7031
|
if (this._config.chunkSize) {
|
|
7032
7032
|
var de = this._start + this._config.chunkSize - 1;
|
|
@@ -7034,106 +7034,106 @@ License: MIT
|
|
|
7034
7034
|
}
|
|
7035
7035
|
try {
|
|
7036
7036
|
$.send(this._config.downloadRequestBody);
|
|
7037
|
-
} catch (
|
|
7038
|
-
this._chunkError(
|
|
7037
|
+
} catch (me) {
|
|
7038
|
+
this._chunkError(me.message);
|
|
7039
7039
|
}
|
|
7040
7040
|
c && $.status === 0 && this._chunkError();
|
|
7041
7041
|
}
|
|
7042
7042
|
}, this._chunkLoaded = function() {
|
|
7043
|
-
$.readyState === 4 && ($.status < 200 || 400 <= $.status ? this._chunkError() : (this._start += this._config.chunkSize ? this._config.chunkSize : $.responseText.length, this._finished = !this._config.chunkSize || this._start >= function(
|
|
7044
|
-
var pe =
|
|
7043
|
+
$.readyState === 4 && ($.status < 200 || 400 <= $.status ? this._chunkError() : (this._start += this._config.chunkSize ? this._config.chunkSize : $.responseText.length, this._finished = !this._config.chunkSize || this._start >= function(Q) {
|
|
7044
|
+
var pe = Q.getResponseHeader("Content-Range");
|
|
7045
7045
|
return pe === null ? -1 : parseInt(pe.substring(pe.lastIndexOf("/") + 1));
|
|
7046
7046
|
}($), this.parseChunk($.responseText)));
|
|
7047
|
-
}, this._chunkError = function(
|
|
7048
|
-
var pe = $.statusText ||
|
|
7047
|
+
}, this._chunkError = function(Q) {
|
|
7048
|
+
var pe = $.statusText || Q;
|
|
7049
7049
|
this._sendError(new Error(pe));
|
|
7050
7050
|
};
|
|
7051
7051
|
}
|
|
7052
|
-
function V(
|
|
7053
|
-
var $,
|
|
7054
|
-
(
|
|
7052
|
+
function V(H) {
|
|
7053
|
+
var $, Q;
|
|
7054
|
+
(H = H || {}).chunkSize || (H.chunkSize = L.LocalChunkSize), J.call(this, H);
|
|
7055
7055
|
var pe = typeof FileReader < "u";
|
|
7056
7056
|
this.stream = function(de) {
|
|
7057
|
-
this._input = de,
|
|
7057
|
+
this._input = de, Q = de.slice || de.webkitSlice || de.mozSlice, pe ? (($ = new FileReader()).onload = te(this._chunkLoaded, this), $.onerror = te(this._chunkError, this)) : $ = new FileReaderSync(), this._nextChunk();
|
|
7058
7058
|
}, this._nextChunk = function() {
|
|
7059
7059
|
this._finished || this._config.preview && !(this._rowCount < this._config.preview) || this._readChunk();
|
|
7060
7060
|
}, this._readChunk = function() {
|
|
7061
7061
|
var de = this._input;
|
|
7062
7062
|
if (this._config.chunkSize) {
|
|
7063
|
-
var
|
|
7064
|
-
de =
|
|
7063
|
+
var me = Math.min(this._start + this._config.chunkSize, this._input.size);
|
|
7064
|
+
de = Q.call(de, this._start, me);
|
|
7065
7065
|
}
|
|
7066
|
-
var
|
|
7067
|
-
pe || this._chunkLoaded({ target: { result:
|
|
7066
|
+
var Oe = $.readAsText(de, this._config.encoding);
|
|
7067
|
+
pe || this._chunkLoaded({ target: { result: Oe } });
|
|
7068
7068
|
}, this._chunkLoaded = function(de) {
|
|
7069
7069
|
this._start += this._config.chunkSize, this._finished = !this._config.chunkSize || this._start >= this._input.size, this.parseChunk(de.target.result);
|
|
7070
7070
|
}, this._chunkError = function() {
|
|
7071
7071
|
this._sendError($.error);
|
|
7072
7072
|
};
|
|
7073
7073
|
}
|
|
7074
|
-
function
|
|
7074
|
+
function X(H) {
|
|
7075
7075
|
var $;
|
|
7076
|
-
|
|
7077
|
-
return $ =
|
|
7076
|
+
J.call(this, H = H || {}), this.stream = function(Q) {
|
|
7077
|
+
return $ = Q, this._nextChunk();
|
|
7078
7078
|
}, this._nextChunk = function() {
|
|
7079
7079
|
if (!this._finished) {
|
|
7080
|
-
var
|
|
7081
|
-
return pe ? (
|
|
7080
|
+
var Q, pe = this._config.chunkSize;
|
|
7081
|
+
return pe ? (Q = $.substring(0, pe), $ = $.substring(pe)) : (Q = $, $ = ""), this._finished = !$, this.parseChunk(Q);
|
|
7082
7082
|
}
|
|
7083
7083
|
};
|
|
7084
7084
|
}
|
|
7085
|
-
function ce(
|
|
7086
|
-
|
|
7087
|
-
var $ = [],
|
|
7085
|
+
function ce(H) {
|
|
7086
|
+
J.call(this, H = H || {});
|
|
7087
|
+
var $ = [], Q = !0, pe = !1;
|
|
7088
7088
|
this.pause = function() {
|
|
7089
|
-
|
|
7089
|
+
J.prototype.pause.apply(this, arguments), this._input.pause();
|
|
7090
7090
|
}, this.resume = function() {
|
|
7091
|
-
|
|
7091
|
+
J.prototype.resume.apply(this, arguments), this._input.resume();
|
|
7092
7092
|
}, this.stream = function(de) {
|
|
7093
7093
|
this._input = de, this._input.on("data", this._streamData), this._input.on("end", this._streamEnd), this._input.on("error", this._streamError);
|
|
7094
7094
|
}, this._checkIsFinished = function() {
|
|
7095
7095
|
pe && $.length === 1 && (this._finished = !0);
|
|
7096
7096
|
}, this._nextChunk = function() {
|
|
7097
|
-
this._checkIsFinished(), $.length ? this.parseChunk($.shift()) :
|
|
7098
|
-
}, this._streamData =
|
|
7097
|
+
this._checkIsFinished(), $.length ? this.parseChunk($.shift()) : Q = !0;
|
|
7098
|
+
}, this._streamData = te(function(de) {
|
|
7099
7099
|
try {
|
|
7100
|
-
$.push(typeof de == "string" ? de : de.toString(this._config.encoding)),
|
|
7101
|
-
} catch (
|
|
7102
|
-
this._streamError(
|
|
7100
|
+
$.push(typeof de == "string" ? de : de.toString(this._config.encoding)), Q && (Q = !1, this._checkIsFinished(), this.parseChunk($.shift()));
|
|
7101
|
+
} catch (me) {
|
|
7102
|
+
this._streamError(me);
|
|
7103
7103
|
}
|
|
7104
|
-
}, this), this._streamError =
|
|
7104
|
+
}, this), this._streamError = te(function(de) {
|
|
7105
7105
|
this._streamCleanUp(), this._sendError(de);
|
|
7106
|
-
}, this), this._streamEnd =
|
|
7106
|
+
}, this), this._streamEnd = te(function() {
|
|
7107
7107
|
this._streamCleanUp(), pe = !0, this._streamData("");
|
|
7108
|
-
}, this), this._streamCleanUp =
|
|
7108
|
+
}, this), this._streamCleanUp = te(function() {
|
|
7109
7109
|
this._input.removeListener("data", this._streamData), this._input.removeListener("end", this._streamEnd), this._input.removeListener("error", this._streamError);
|
|
7110
7110
|
}, this);
|
|
7111
7111
|
}
|
|
7112
|
-
function se(
|
|
7113
|
-
var $,
|
|
7114
|
-
if (ie(
|
|
7115
|
-
var Le =
|
|
7116
|
-
|
|
7112
|
+
function se(H) {
|
|
7113
|
+
var $, Q, pe, de = Math.pow(2, 53), me = -de, Oe = /^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/, Ae = /^((\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z)))$/, Ce = this, Ee = 0, Re = 0, Te = !1, Fe = !1, ke = [], he = { data: [], errors: [], meta: {} };
|
|
7114
|
+
if (ie(H.step)) {
|
|
7115
|
+
var Le = H.step;
|
|
7116
|
+
H.step = function(be) {
|
|
7117
7117
|
if (he = be, Me())
|
|
7118
7118
|
Pe();
|
|
7119
7119
|
else {
|
|
7120
7120
|
if (Pe(), he.data.length === 0)
|
|
7121
7121
|
return;
|
|
7122
|
-
Ee += be.data.length,
|
|
7122
|
+
Ee += be.data.length, H.preview && Ee > H.preview ? Q.abort() : (he.data = he.data[0], Le(he, Ce));
|
|
7123
7123
|
}
|
|
7124
7124
|
};
|
|
7125
7125
|
}
|
|
7126
7126
|
function fe(be) {
|
|
7127
|
-
return
|
|
7127
|
+
return H.skipEmptyLines === "greedy" ? be.join("").trim() === "" : be.length === 1 && be[0].length === 0;
|
|
7128
7128
|
}
|
|
7129
7129
|
function Pe() {
|
|
7130
|
-
return he && pe && (Ie("Delimiter", "UndetectableDelimiter", "Unable to auto-detect delimiting character; defaulted to '" + L.DefaultDelimiter + "'"), pe = !1),
|
|
7130
|
+
return he && pe && (Ie("Delimiter", "UndetectableDelimiter", "Unable to auto-detect delimiting character; defaulted to '" + L.DefaultDelimiter + "'"), pe = !1), H.skipEmptyLines && (he.data = he.data.filter(function(be) {
|
|
7131
7131
|
return !fe(be);
|
|
7132
7132
|
})), Me() && function() {
|
|
7133
7133
|
if (!he)
|
|
7134
7134
|
return;
|
|
7135
7135
|
function be(M, W) {
|
|
7136
|
-
ie(
|
|
7136
|
+
ie(H.transformHeader) && (M = H.transformHeader(M, W)), ke.push(M);
|
|
7137
7137
|
}
|
|
7138
7138
|
if (Array.isArray(he.data[0])) {
|
|
7139
7139
|
for (var D = 0; Me() && D < he.data.length; D++)
|
|
@@ -7142,28 +7142,28 @@ License: MIT
|
|
|
7142
7142
|
} else
|
|
7143
7143
|
he.data.forEach(be);
|
|
7144
7144
|
}(), function() {
|
|
7145
|
-
if (!he || !
|
|
7145
|
+
if (!he || !H.header && !H.dynamicTyping && !H.transform)
|
|
7146
7146
|
return he;
|
|
7147
7147
|
function be(M, W) {
|
|
7148
|
-
var R, I =
|
|
7148
|
+
var R, I = H.header ? {} : [];
|
|
7149
7149
|
for (R = 0; R < M.length; R++) {
|
|
7150
|
-
var F = R,
|
|
7151
|
-
|
|
7150
|
+
var F = R, G = M[R];
|
|
7151
|
+
H.header && (F = R >= ke.length ? "__parsed_extra" : ke[R]), H.transform && (G = H.transform(G, F)), G = De(F, G), F === "__parsed_extra" ? (I[F] = I[F] || [], I[F].push(G)) : I[F] = G;
|
|
7152
7152
|
}
|
|
7153
|
-
return
|
|
7153
|
+
return H.header && (R > ke.length ? Ie("FieldMismatch", "TooManyFields", "Too many fields: expected " + ke.length + " fields but parsed " + R, Re + W) : R < ke.length && Ie("FieldMismatch", "TooFewFields", "Too few fields: expected " + ke.length + " fields but parsed " + R, Re + W)), I;
|
|
7154
7154
|
}
|
|
7155
7155
|
var D = 1;
|
|
7156
|
-
return !he.data.length || Array.isArray(he.data[0]) ? (he.data = he.data.map(be), D = he.data.length) : he.data = be(he.data, 0),
|
|
7156
|
+
return !he.data.length || Array.isArray(he.data[0]) ? (he.data = he.data.map(be), D = he.data.length) : he.data = be(he.data, 0), H.header && he.meta && (he.meta.fields = ke), Re += D, he;
|
|
7157
7157
|
}();
|
|
7158
7158
|
}
|
|
7159
7159
|
function Me() {
|
|
7160
|
-
return
|
|
7160
|
+
return H.header && ke.length === 0;
|
|
7161
7161
|
}
|
|
7162
7162
|
function De(be, D) {
|
|
7163
|
-
return M = be,
|
|
7164
|
-
if (
|
|
7163
|
+
return M = be, H.dynamicTypingFunction && H.dynamicTyping[M] === void 0 && (H.dynamicTyping[M] = H.dynamicTypingFunction(M)), (H.dynamicTyping[M] || H.dynamicTyping) === !0 ? D === "true" || D === "TRUE" || D !== "false" && D !== "FALSE" && (function(W) {
|
|
7164
|
+
if (Oe.test(W)) {
|
|
7165
7165
|
var R = parseFloat(W);
|
|
7166
|
-
if (
|
|
7166
|
+
if (me < R && R < de)
|
|
7167
7167
|
return !0;
|
|
7168
7168
|
}
|
|
7169
7169
|
return !1;
|
|
@@ -7175,61 +7175,61 @@ License: MIT
|
|
|
7175
7175
|
W !== void 0 && (R.row = W), he.errors.push(R);
|
|
7176
7176
|
}
|
|
7177
7177
|
this.parse = function(be, D, M) {
|
|
7178
|
-
var W =
|
|
7179
|
-
if (
|
|
7178
|
+
var W = H.quoteChar || '"';
|
|
7179
|
+
if (H.newline || (H.newline = function(F, G) {
|
|
7180
7180
|
F = F.substring(0, 1048576);
|
|
7181
|
-
var j = new RegExp(
|
|
7181
|
+
var j = new RegExp(ne(G) + "([^]*?)" + ne(G), "gm"), K = (F = F.replace(j, "")).split("\r"), Z = F.split(`
|
|
7182
7182
|
`), z = 1 < Z.length && Z[0].length < K[0].length;
|
|
7183
7183
|
if (K.length === 1 || z)
|
|
7184
7184
|
return `
|
|
7185
7185
|
`;
|
|
7186
|
-
for (var ue = 0,
|
|
7187
|
-
K[
|
|
7186
|
+
for (var ue = 0, ge = 0; ge < K.length; ge++)
|
|
7187
|
+
K[ge][0] === `
|
|
7188
7188
|
` && ue++;
|
|
7189
7189
|
return ue >= K.length / 2 ? `\r
|
|
7190
7190
|
` : "\r";
|
|
7191
|
-
}(be, W)), pe = !1,
|
|
7192
|
-
ie(
|
|
7191
|
+
}(be, W)), pe = !1, H.delimiter)
|
|
7192
|
+
ie(H.delimiter) && (H.delimiter = H.delimiter(be), he.meta.delimiter = H.delimiter);
|
|
7193
7193
|
else {
|
|
7194
|
-
var R = function(F,
|
|
7195
|
-
var z, ue,
|
|
7194
|
+
var R = function(F, G, j, K, Z) {
|
|
7195
|
+
var z, ue, ge, _e;
|
|
7196
7196
|
Z = Z || [",", " ", "|", ";", L.RECORD_SEP, L.UNIT_SEP];
|
|
7197
7197
|
for (var ye = 0; ye < Z.length; ye++) {
|
|
7198
7198
|
var Se = Z[ye], Ne = 0, ee = 0, le = 0;
|
|
7199
|
-
|
|
7200
|
-
for (var
|
|
7201
|
-
if (j && fe(
|
|
7199
|
+
ge = void 0;
|
|
7200
|
+
for (var ve = new q({ comments: K, delimiter: Se, newline: G, preview: 10 }).parse(F), we = 0; we < ve.data.length; we++)
|
|
7201
|
+
if (j && fe(ve.data[we]))
|
|
7202
7202
|
le++;
|
|
7203
7203
|
else {
|
|
7204
|
-
var je =
|
|
7205
|
-
ee += je,
|
|
7204
|
+
var je = ve.data[we].length;
|
|
7205
|
+
ee += je, ge !== void 0 ? 0 < je && (Ne += Math.abs(je - ge), ge = je) : ge = je;
|
|
7206
7206
|
}
|
|
7207
|
-
0 <
|
|
7207
|
+
0 < ve.data.length && (ee /= ve.data.length - le), (ue === void 0 || Ne <= ue) && (_e === void 0 || _e < ee) && 1.99 < ee && (ue = Ne, z = Se, _e = ee);
|
|
7208
7208
|
}
|
|
7209
|
-
return { successful: !!(
|
|
7210
|
-
}(be,
|
|
7211
|
-
R.successful ?
|
|
7209
|
+
return { successful: !!(H.delimiter = z), bestDelimiter: z };
|
|
7210
|
+
}(be, H.newline, H.skipEmptyLines, H.comments, H.delimitersToGuess);
|
|
7211
|
+
R.successful ? H.delimiter = R.bestDelimiter : (pe = !0, H.delimiter = L.DefaultDelimiter), he.meta.delimiter = H.delimiter;
|
|
7212
7212
|
}
|
|
7213
|
-
var I =
|
|
7214
|
-
return
|
|
7213
|
+
var I = ae(H);
|
|
7214
|
+
return H.preview && H.header && I.preview++, $ = be, Q = new q(I), he = Q.parse($, D, M), Pe(), Te ? { meta: { paused: !0 } } : he || { meta: { paused: !1 } };
|
|
7215
7215
|
}, this.paused = function() {
|
|
7216
7216
|
return Te;
|
|
7217
7217
|
}, this.pause = function() {
|
|
7218
|
-
Te = !0,
|
|
7218
|
+
Te = !0, Q.abort(), $ = ie(H.chunk) ? "" : $.substring(Q.getCharIndex());
|
|
7219
7219
|
}, this.resume = function() {
|
|
7220
7220
|
Ce.streamer._halted ? (Te = !1, Ce.streamer.parseChunk($, !0)) : setTimeout(Ce.resume, 3);
|
|
7221
7221
|
}, this.aborted = function() {
|
|
7222
7222
|
return Fe;
|
|
7223
7223
|
}, this.abort = function() {
|
|
7224
|
-
Fe = !0,
|
|
7224
|
+
Fe = !0, Q.abort(), he.meta.aborted = !0, ie(H.complete) && H.complete(he), $ = "";
|
|
7225
7225
|
};
|
|
7226
7226
|
}
|
|
7227
|
-
function
|
|
7228
|
-
return
|
|
7227
|
+
function ne(H) {
|
|
7228
|
+
return H.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
7229
7229
|
}
|
|
7230
|
-
function
|
|
7231
|
-
var $,
|
|
7232
|
-
if (
|
|
7230
|
+
function q(H) {
|
|
7231
|
+
var $, Q = (H = H || {}).delimiter, pe = H.newline, de = H.comments, me = H.step, Oe = H.preview, Ae = H.fastMode, Ce = $ = H.quoteChar === void 0 || H.quoteChar === null ? '"' : H.quoteChar;
|
|
7232
|
+
if (H.escapeChar !== void 0 && (Ce = H.escapeChar), (typeof Q != "string" || -1 < L.BAD_DELIMITERS.indexOf(Q)) && (Q = ","), de === Q)
|
|
7233
7233
|
throw new Error("Comment character same as delimiter");
|
|
7234
7234
|
de === !0 ? de = "#" : (typeof de != "string" || -1 < L.BAD_DELIMITERS.indexOf(de)) && (de = !1), pe !== `
|
|
7235
7235
|
` && pe !== "\r" && pe !== `\r
|
|
@@ -7239,22 +7239,22 @@ License: MIT
|
|
|
7239
7239
|
this.parse = function(Te, Fe, ke) {
|
|
7240
7240
|
if (typeof Te != "string")
|
|
7241
7241
|
throw new Error("Input must be a string");
|
|
7242
|
-
var he = Te.length, Le =
|
|
7242
|
+
var he = Te.length, Le = Q.length, fe = pe.length, Pe = de.length, Me = ie(me), De = [], Ie = [], be = [], D = Ee = 0;
|
|
7243
7243
|
if (!Te)
|
|
7244
7244
|
return Be();
|
|
7245
|
-
if (
|
|
7246
|
-
var M = Te.split(pe)[0].split(
|
|
7245
|
+
if (H.header && !Fe) {
|
|
7246
|
+
var M = Te.split(pe)[0].split(Q), W = [], R = {}, I = !1;
|
|
7247
7247
|
for (var F in M) {
|
|
7248
|
-
var
|
|
7249
|
-
ie(
|
|
7250
|
-
var j =
|
|
7251
|
-
for (0 < K && (I = !0, j =
|
|
7248
|
+
var G = M[F];
|
|
7249
|
+
ie(H.transformHeader) && (G = H.transformHeader(G, F));
|
|
7250
|
+
var j = G, K = R[G] || 0;
|
|
7251
|
+
for (0 < K && (I = !0, j = G + "_" + K), R[G] = K + 1; W.includes(j); )
|
|
7252
7252
|
j = j + "_" + K;
|
|
7253
7253
|
W.push(j);
|
|
7254
7254
|
}
|
|
7255
7255
|
if (I) {
|
|
7256
7256
|
var Z = Te.split(pe);
|
|
7257
|
-
Z[0] = W.join(
|
|
7257
|
+
Z[0] = W.join(Q), Te = Z.join(pe);
|
|
7258
7258
|
}
|
|
7259
7259
|
}
|
|
7260
7260
|
if (Ae || Ae !== !1 && Te.indexOf($) === -1) {
|
|
@@ -7265,30 +7265,30 @@ License: MIT
|
|
|
7265
7265
|
return Be();
|
|
7266
7266
|
if (!de || be.substring(0, Pe) !== de) {
|
|
7267
7267
|
if (Me) {
|
|
7268
|
-
if (De = [], le(be.split(
|
|
7268
|
+
if (De = [], le(be.split(Q)), xe(), Re)
|
|
7269
7269
|
return Be();
|
|
7270
7270
|
} else
|
|
7271
|
-
le(be.split(
|
|
7272
|
-
if (
|
|
7273
|
-
return De = De.slice(0,
|
|
7271
|
+
le(be.split(Q));
|
|
7272
|
+
if (Oe && Oe <= ue)
|
|
7273
|
+
return De = De.slice(0, Oe), Be(!0);
|
|
7274
7274
|
}
|
|
7275
7275
|
}
|
|
7276
7276
|
return Be();
|
|
7277
7277
|
}
|
|
7278
|
-
for (var
|
|
7278
|
+
for (var ge = Te.indexOf(Q, Ee), _e = Te.indexOf(pe, Ee), ye = new RegExp(ne(Ce) + ne($), "g"), Se = Te.indexOf($, Ee); ; )
|
|
7279
7279
|
if (Te[Ee] !== $)
|
|
7280
7280
|
if (de && be.length === 0 && Te.substring(Ee, Ee + Pe) === de) {
|
|
7281
7281
|
if (_e === -1)
|
|
7282
7282
|
return Be();
|
|
7283
|
-
Ee = _e + fe, _e = Te.indexOf(pe, Ee),
|
|
7284
|
-
} else if (
|
|
7285
|
-
be.push(Te.substring(Ee,
|
|
7283
|
+
Ee = _e + fe, _e = Te.indexOf(pe, Ee), ge = Te.indexOf(Q, Ee);
|
|
7284
|
+
} else if (ge !== -1 && (ge < _e || _e === -1))
|
|
7285
|
+
be.push(Te.substring(Ee, ge)), Ee = ge + Le, ge = Te.indexOf(Q, Ee);
|
|
7286
7286
|
else {
|
|
7287
7287
|
if (_e === -1)
|
|
7288
7288
|
break;
|
|
7289
7289
|
if (be.push(Te.substring(Ee, _e)), je(_e + fe), Me && (xe(), Re))
|
|
7290
7290
|
return Be();
|
|
7291
|
-
if (
|
|
7291
|
+
if (Oe && De.length >= Oe)
|
|
7292
7292
|
return Be(!0);
|
|
7293
7293
|
}
|
|
7294
7294
|
else
|
|
@@ -7299,17 +7299,17 @@ License: MIT
|
|
|
7299
7299
|
return we(Te.substring(Ee, Se).replace(ye, $));
|
|
7300
7300
|
if ($ !== Ce || Te[Se + 1] !== Ce) {
|
|
7301
7301
|
if ($ === Ce || Se === 0 || Te[Se - 1] !== Ce) {
|
|
7302
|
-
|
|
7303
|
-
var Ne =
|
|
7304
|
-
if (Te.substr(Se + 1 + Ne, Le) ===
|
|
7305
|
-
be.push(Te.substring(Ee, Se).replace(ye, $)), Te[Ee = Se + 1 + Ne + Le] !== $ && (Se = Te.indexOf($, Ee)),
|
|
7302
|
+
ge !== -1 && ge < Se + 1 && (ge = Te.indexOf(Q, Se + 1)), _e !== -1 && _e < Se + 1 && (_e = Te.indexOf(pe, Se + 1));
|
|
7303
|
+
var Ne = ve(_e === -1 ? ge : Math.min(ge, _e));
|
|
7304
|
+
if (Te.substr(Se + 1 + Ne, Le) === Q) {
|
|
7305
|
+
be.push(Te.substring(Ee, Se).replace(ye, $)), Te[Ee = Se + 1 + Ne + Le] !== $ && (Se = Te.indexOf($, Ee)), ge = Te.indexOf(Q, Ee), _e = Te.indexOf(pe, Ee);
|
|
7306
7306
|
break;
|
|
7307
7307
|
}
|
|
7308
|
-
var ee =
|
|
7308
|
+
var ee = ve(_e);
|
|
7309
7309
|
if (Te.substring(Se + 1 + ee, Se + 1 + ee + fe) === pe) {
|
|
7310
|
-
if (be.push(Te.substring(Ee, Se).replace(ye, $)), je(Se + 1 + ee + fe),
|
|
7310
|
+
if (be.push(Te.substring(Ee, Se).replace(ye, $)), je(Se + 1 + ee + fe), ge = Te.indexOf(Q, Ee), Se = Te.indexOf($, Ee), Me && (xe(), Re))
|
|
7311
7311
|
return Be();
|
|
7312
|
-
if (
|
|
7312
|
+
if (Oe && De.length >= Oe)
|
|
7313
7313
|
return Be(!0);
|
|
7314
7314
|
break;
|
|
7315
7315
|
}
|
|
@@ -7322,7 +7322,7 @@ License: MIT
|
|
|
7322
7322
|
function le($e) {
|
|
7323
7323
|
De.push($e), D = Ee;
|
|
7324
7324
|
}
|
|
7325
|
-
function
|
|
7325
|
+
function ve($e) {
|
|
7326
7326
|
var We = 0;
|
|
7327
7327
|
if ($e !== -1) {
|
|
7328
7328
|
var Ve = Te.substring(Se + 1, $e);
|
|
@@ -7337,10 +7337,10 @@ License: MIT
|
|
|
7337
7337
|
Ee = $e, le(be), be = [], _e = Te.indexOf(pe, Ee);
|
|
7338
7338
|
}
|
|
7339
7339
|
function Be($e) {
|
|
7340
|
-
return { data: De, errors: Ie, meta: { delimiter:
|
|
7340
|
+
return { data: De, errors: Ie, meta: { delimiter: Q, linebreak: pe, aborted: Re, truncated: !!$e, cursor: D + (Fe || 0) } };
|
|
7341
7341
|
}
|
|
7342
7342
|
function xe() {
|
|
7343
|
-
|
|
7343
|
+
me(Be()), De = [], Ie = [];
|
|
7344
7344
|
}
|
|
7345
7345
|
}, this.abort = function() {
|
|
7346
7346
|
Re = !0;
|
|
@@ -7348,55 +7348,55 @@ License: MIT
|
|
|
7348
7348
|
return Ee;
|
|
7349
7349
|
};
|
|
7350
7350
|
}
|
|
7351
|
-
function
|
|
7352
|
-
var $ =
|
|
7351
|
+
function Y(H) {
|
|
7352
|
+
var $ = H.data, Q = C[$.workerId], pe = !1;
|
|
7353
7353
|
if ($.error)
|
|
7354
|
-
|
|
7354
|
+
Q.userError($.error, $.file);
|
|
7355
7355
|
else if ($.results && $.results.data) {
|
|
7356
7356
|
var de = { abort: function() {
|
|
7357
|
-
pe = !0,
|
|
7358
|
-
}, pause:
|
|
7359
|
-
if (ie(
|
|
7360
|
-
for (var
|
|
7357
|
+
pe = !0, oe($.workerId, { data: [], errors: [], meta: { aborted: !0 } });
|
|
7358
|
+
}, pause: re, resume: re };
|
|
7359
|
+
if (ie(Q.userStep)) {
|
|
7360
|
+
for (var me = 0; me < $.results.data.length && (Q.userStep({ data: $.results.data[me], errors: $.results.errors, meta: $.results.meta }, de), !pe); me++)
|
|
7361
7361
|
;
|
|
7362
7362
|
delete $.results;
|
|
7363
7363
|
} else
|
|
7364
|
-
ie(
|
|
7364
|
+
ie(Q.userChunk) && (Q.userChunk($.results, de, $.file), delete $.results);
|
|
7365
7365
|
}
|
|
7366
|
-
$.finished && !pe &&
|
|
7366
|
+
$.finished && !pe && oe($.workerId, $.results);
|
|
7367
7367
|
}
|
|
7368
|
-
function
|
|
7369
|
-
var
|
|
7370
|
-
ie(
|
|
7368
|
+
function oe(H, $) {
|
|
7369
|
+
var Q = C[H];
|
|
7370
|
+
ie(Q.userComplete) && Q.userComplete($), Q.terminate(), delete C[H];
|
|
7371
7371
|
}
|
|
7372
|
-
function
|
|
7372
|
+
function re() {
|
|
7373
7373
|
throw new Error("Not implemented.");
|
|
7374
7374
|
}
|
|
7375
|
-
function
|
|
7376
|
-
if (typeof
|
|
7377
|
-
return
|
|
7378
|
-
var $ = Array.isArray(
|
|
7379
|
-
for (var
|
|
7380
|
-
$[
|
|
7375
|
+
function ae(H) {
|
|
7376
|
+
if (typeof H != "object" || H === null)
|
|
7377
|
+
return H;
|
|
7378
|
+
var $ = Array.isArray(H) ? [] : {};
|
|
7379
|
+
for (var Q in H)
|
|
7380
|
+
$[Q] = ae(H[Q]);
|
|
7381
7381
|
return $;
|
|
7382
7382
|
}
|
|
7383
|
-
function
|
|
7383
|
+
function te(H, $) {
|
|
7384
7384
|
return function() {
|
|
7385
|
-
|
|
7385
|
+
H.apply($, arguments);
|
|
7386
7386
|
};
|
|
7387
7387
|
}
|
|
7388
|
-
function ie(
|
|
7389
|
-
return typeof
|
|
7388
|
+
function ie(H) {
|
|
7389
|
+
return typeof H == "function";
|
|
7390
7390
|
}
|
|
7391
|
-
return l && (s.onmessage = function(
|
|
7392
|
-
var $ =
|
|
7391
|
+
return l && (s.onmessage = function(H) {
|
|
7392
|
+
var $ = H.data;
|
|
7393
7393
|
if (L.WORKER_ID === void 0 && $ && (L.WORKER_ID = $.workerId), typeof $.input == "string")
|
|
7394
7394
|
s.postMessage({ workerId: L.WORKER_ID, results: L.parse($.input, $.config), finished: !0 });
|
|
7395
7395
|
else if (s.File && $.input instanceof File || $.input instanceof Object) {
|
|
7396
|
-
var
|
|
7397
|
-
|
|
7396
|
+
var Q = L.parse($.input, $.config);
|
|
7397
|
+
Q && s.postMessage({ workerId: L.WORKER_ID, results: Q, finished: !0 });
|
|
7398
7398
|
}
|
|
7399
|
-
}), (U.prototype = Object.create(
|
|
7399
|
+
}), (U.prototype = Object.create(J.prototype)).constructor = U, (V.prototype = Object.create(J.prototype)).constructor = V, (X.prototype = Object.create(X.prototype)).constructor = X, (ce.prototype = Object.create(J.prototype)).constructor = ce, L;
|
|
7400
7400
|
});
|
|
7401
7401
|
})(papaparse_min);
|
|
7402
7402
|
var papaparse_minExports = papaparse_min.exports;
|
|
@@ -7456,84 +7456,104 @@ temp,\${payload.temp},
|
|
|
7456
7456
|
hum,\${payload.hum},
|
|
7457
7457
|
precip,\${payload.precip}i,"${n("datalayersTemplateRemark")}"
|
|
7458
7458
|
`
|
|
7459
|
-
}
|
|
7459
|
+
}, l = `Column Category,Timestamp,Measurement,Data Type,Value,Remarks (Optional)
|
|
7460
|
+
tag,now,temp,float,\${payload.temp},"${n("iotdbTemplateRemark")}"
|
|
7461
|
+
field,now,hum,float,\${payload.hum},
|
|
7462
|
+
attribute,now,status,boolean,\${payload.status},
|
|
7463
|
+
attribute,now,clientid,text,\${clientid},
|
|
7464
|
+
`;
|
|
7460
7465
|
return {
|
|
7461
7466
|
filenameMap: s,
|
|
7462
7467
|
templateContentMap: c,
|
|
7463
|
-
|
|
7464
|
-
|
|
7465
|
-
|
|
7466
|
-
|
|
7468
|
+
getTemplateContent: (V, X) => V === "iotdb" ? X ? l : c.iotdb : c[V],
|
|
7469
|
+
handleDownloadTemp: (V, X) => {
|
|
7470
|
+
if (V) {
|
|
7471
|
+
const ce = new Blob([V], { type: "text/csv" });
|
|
7472
|
+
createDownloadBlobLink(ce, `${X}_template.csv`);
|
|
7467
7473
|
} else
|
|
7468
7474
|
console.error("Template is empty");
|
|
7469
7475
|
},
|
|
7470
|
-
readFileAndParse: async (
|
|
7471
|
-
const
|
|
7472
|
-
|
|
7473
|
-
if (!
|
|
7474
|
-
return
|
|
7475
|
-
const
|
|
7476
|
-
|
|
7477
|
-
},
|
|
7478
|
-
|
|
7479
|
-
},
|
|
7480
|
-
|
|
7481
|
-
},
|
|
7476
|
+
readFileAndParse: async (V, X) => new Promise((ce, se) => {
|
|
7477
|
+
const ne = new FileReader();
|
|
7478
|
+
ne.onload = (q) => {
|
|
7479
|
+
if (!q.target)
|
|
7480
|
+
return se(new Error("FileReader event target is null"));
|
|
7481
|
+
const Y = q.target.result, oe = Papa.parse(Y, { skipEmptyLines: "greedy" });
|
|
7482
|
+
oe.errors.length > 0 && se(new Error("Failed to parse CSV data: " + oe.errors[0].message)), oe.data.length > X + 1 ? se(new Error(n("uploadMaxRowsError", { max: X }))) : ce(oe.data);
|
|
7483
|
+
}, ne.onerror = () => {
|
|
7484
|
+
se(new Error("An error occurred while reading the file"));
|
|
7485
|
+
}, ne.onabort = () => {
|
|
7486
|
+
se(new Error("File reading was aborted"));
|
|
7487
|
+
}, ne.readAsText(V);
|
|
7482
7488
|
}),
|
|
7483
|
-
processIoTDBData: (
|
|
7489
|
+
processIoTDBData: (V, X) => new Promise((ce, se) => {
|
|
7484
7490
|
try {
|
|
7485
|
-
const
|
|
7486
|
-
(
|
|
7487
|
-
).map((
|
|
7488
|
-
|
|
7489
|
-
|
|
7490
|
-
|
|
7491
|
+
const ne = ["boolean", "int32", "int64", "float", "double", "text"], q = (ae) => ne.includes(ae), Y = ["tag", "field", "attribute"], oe = (ae) => Y.includes(ae), re = V.slice(1).filter(
|
|
7492
|
+
(ae) => ae.length >= 4 && ae.slice(0, 4).every((te) => te && te.trim() !== "")
|
|
7493
|
+
).map((ae) => {
|
|
7494
|
+
if (X) {
|
|
7495
|
+
const [Q, pe, de, me, Oe] = ae;
|
|
7496
|
+
if (!q(me))
|
|
7497
|
+
throw new Error(`Invalid data type: ${me}`);
|
|
7498
|
+
if (!oe(Q))
|
|
7499
|
+
throw new Error(`Invalid column category: ${Q}`);
|
|
7500
|
+
return {
|
|
7501
|
+
column_category: Q,
|
|
7502
|
+
timestamp: pe,
|
|
7503
|
+
measurement: de,
|
|
7504
|
+
data_type: me,
|
|
7505
|
+
value: Oe
|
|
7506
|
+
};
|
|
7507
|
+
}
|
|
7508
|
+
const [te, ie, H, $] = ae;
|
|
7509
|
+
if (!q(H))
|
|
7510
|
+
throw new Error(`Invalid data type: ${H}`);
|
|
7491
7511
|
return {
|
|
7492
|
-
timestamp:
|
|
7493
|
-
measurement:
|
|
7494
|
-
data_type:
|
|
7495
|
-
value:
|
|
7512
|
+
timestamp: te,
|
|
7513
|
+
measurement: ie,
|
|
7514
|
+
data_type: H,
|
|
7515
|
+
value: $
|
|
7496
7516
|
};
|
|
7497
7517
|
});
|
|
7498
|
-
|
|
7499
|
-
} catch (
|
|
7500
|
-
|
|
7518
|
+
ce(re);
|
|
7519
|
+
} catch (ne) {
|
|
7520
|
+
se(ne);
|
|
7501
7521
|
}
|
|
7502
7522
|
}),
|
|
7503
|
-
processTDengineData: (
|
|
7523
|
+
processTDengineData: (V) => new Promise((X, ce) => {
|
|
7504
7524
|
try {
|
|
7505
|
-
const
|
|
7506
|
-
for (let
|
|
7507
|
-
const [
|
|
7508
|
-
if (!
|
|
7525
|
+
const se = "<table>", ne = [], q = [];
|
|
7526
|
+
for (let oe = 1; oe < V.length; oe++) {
|
|
7527
|
+
const [re, ae, te] = V[oe];
|
|
7528
|
+
if (!re || !ae)
|
|
7509
7529
|
continue;
|
|
7510
|
-
|
|
7511
|
-
const
|
|
7512
|
-
if (
|
|
7513
|
-
|
|
7514
|
-
else if (
|
|
7515
|
-
|
|
7530
|
+
ne.push(re);
|
|
7531
|
+
const ie = ["true", "TRUE", "1", "", void 0].includes(te == null ? void 0 : te.trim()), H = ["false", "FALSE", "0"].includes(te == null ? void 0 : te.trim());
|
|
7532
|
+
if (ie)
|
|
7533
|
+
q.push(`'${ae}'`);
|
|
7534
|
+
else if (H)
|
|
7535
|
+
q.push(ae);
|
|
7516
7536
|
else
|
|
7517
7537
|
throw new Error(n("invalidIsCharFlag", { isChar: te }));
|
|
7518
7538
|
}
|
|
7519
|
-
const
|
|
7539
|
+
const Y = `insert into ${se}(${ne.join(", ")}) values (${q.join(
|
|
7520
7540
|
", "
|
|
7521
7541
|
)})`;
|
|
7522
|
-
|
|
7523
|
-
} catch (
|
|
7524
|
-
|
|
7542
|
+
X(Y);
|
|
7543
|
+
} catch (se) {
|
|
7544
|
+
ce(se);
|
|
7525
7545
|
}
|
|
7526
7546
|
}),
|
|
7527
|
-
processInfluxDBData: (
|
|
7547
|
+
processInfluxDBData: (V) => new Promise((X, ce) => {
|
|
7528
7548
|
try {
|
|
7529
|
-
const
|
|
7530
|
-
for (let
|
|
7531
|
-
const [
|
|
7532
|
-
!
|
|
7549
|
+
const se = [];
|
|
7550
|
+
for (let ne = 1; ne < V.length; ne++) {
|
|
7551
|
+
const [q, Y] = V[ne];
|
|
7552
|
+
!q || !Y || se.push({ key: q, value: Y });
|
|
7533
7553
|
}
|
|
7534
|
-
|
|
7535
|
-
} catch (
|
|
7536
|
-
|
|
7554
|
+
X(se);
|
|
7555
|
+
} catch (se) {
|
|
7556
|
+
ce(se);
|
|
7537
7557
|
}
|
|
7538
7558
|
})
|
|
7539
7559
|
};
|
|
@@ -7598,9 +7618,9 @@ precip,\${payload.precip}i,"${n("datalayersTemplateRemark")}"
|
|
|
7598
7618
|
var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exports: {} };
|
|
7599
7619
|
(function(e) {
|
|
7600
7620
|
(function(t) {
|
|
7601
|
-
var n, s = /^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i, c = Math.ceil, l = Math.floor, C = "[BigNumber Error] ", A = C + "Number primitive has more than 15 significant digits: ", L = 1e14, B = 14,
|
|
7602
|
-
function ce(
|
|
7603
|
-
var ie,
|
|
7621
|
+
var n, s = /^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i, c = Math.ceil, l = Math.floor, C = "[BigNumber Error] ", A = C + "Number primitive has more than 15 significant digits: ", L = 1e14, B = 14, J = 9007199254740991, U = [1, 10, 100, 1e3, 1e4, 1e5, 1e6, 1e7, 1e8, 1e9, 1e10, 1e11, 1e12, 1e13], V = 1e7, X = 1e9;
|
|
7622
|
+
function ce(te) {
|
|
7623
|
+
var ie, H, $, Q = fe.prototype = { constructor: fe, toString: null, valueOf: null }, pe = new fe(1), de = 20, me = 4, Oe = -7, Ae = 21, Ce = -1e7, Ee = 1e7, Re = !1, Te = 1, Fe = 0, ke = {
|
|
7604
7624
|
prefix: "",
|
|
7605
7625
|
groupSize: 3,
|
|
7606
7626
|
secondaryGroupSize: 0,
|
|
@@ -7612,7 +7632,7 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7612
7632
|
suffix: ""
|
|
7613
7633
|
}, he = "0123456789abcdefghijklmnopqrstuvwxyz", Le = !0;
|
|
7614
7634
|
function fe(D, M) {
|
|
7615
|
-
var W, R, I, F,
|
|
7635
|
+
var W, R, I, F, G, j, K, Z, z = this;
|
|
7616
7636
|
if (!(z instanceof fe))
|
|
7617
7637
|
return new fe(D, M);
|
|
7618
7638
|
if (M == null) {
|
|
@@ -7622,7 +7642,7 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7622
7642
|
}
|
|
7623
7643
|
if ((j = typeof D == "number") && D * 0 == 0) {
|
|
7624
7644
|
if (z.s = 1 / D < 0 ? (D = -D, -1) : 1, D === ~~D) {
|
|
7625
|
-
for (F = 0,
|
|
7645
|
+
for (F = 0, G = D; G >= 10; G /= 10, F++)
|
|
7626
7646
|
;
|
|
7627
7647
|
F > Ee ? z.c = z.e = null : (z.e = F, z.c = [D]);
|
|
7628
7648
|
return;
|
|
@@ -7633,10 +7653,10 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7633
7653
|
return $(z, Z, j);
|
|
7634
7654
|
z.s = Z.charCodeAt(0) == 45 ? (Z = Z.slice(1), -1) : 1;
|
|
7635
7655
|
}
|
|
7636
|
-
(F = Z.indexOf(".")) > -1 && (Z = Z.replace(".", "")), (
|
|
7656
|
+
(F = Z.indexOf(".")) > -1 && (Z = Z.replace(".", "")), (G = Z.search(/e/i)) > 0 ? (F < 0 && (F = G), F += +Z.slice(G + 1), Z = Z.substring(0, G)) : F < 0 && (F = Z.length);
|
|
7637
7657
|
} else {
|
|
7638
|
-
if (
|
|
7639
|
-
return z = new fe(D), Ie(z, de + z.e + 1,
|
|
7658
|
+
if (Y(M, 2, he.length, "Base"), M == 10 && Le)
|
|
7659
|
+
return z = new fe(D), Ie(z, de + z.e + 1, me);
|
|
7640
7660
|
if (Z = String(D), j = typeof D == "number") {
|
|
7641
7661
|
if (D * 0 != 0)
|
|
7642
7662
|
return $(z, Z, j, M);
|
|
@@ -7644,40 +7664,40 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7644
7664
|
throw Error(A + D);
|
|
7645
7665
|
} else
|
|
7646
7666
|
z.s = Z.charCodeAt(0) === 45 ? (Z = Z.slice(1), -1) : 1;
|
|
7647
|
-
for (W = he.slice(0, M), F =
|
|
7648
|
-
if (W.indexOf(R = Z.charAt(
|
|
7667
|
+
for (W = he.slice(0, M), F = G = 0, K = Z.length; G < K; G++)
|
|
7668
|
+
if (W.indexOf(R = Z.charAt(G)) < 0) {
|
|
7649
7669
|
if (R == ".") {
|
|
7650
|
-
if (
|
|
7670
|
+
if (G > F) {
|
|
7651
7671
|
F = K;
|
|
7652
7672
|
continue;
|
|
7653
7673
|
}
|
|
7654
7674
|
} else if (!I && (Z == Z.toUpperCase() && (Z = Z.toLowerCase()) || Z == Z.toLowerCase() && (Z = Z.toUpperCase()))) {
|
|
7655
|
-
I = !0,
|
|
7675
|
+
I = !0, G = -1, F = 0;
|
|
7656
7676
|
continue;
|
|
7657
7677
|
}
|
|
7658
7678
|
return $(z, String(D), j, M);
|
|
7659
7679
|
}
|
|
7660
|
-
j = !1, Z =
|
|
7680
|
+
j = !1, Z = H(Z, M, 10, z.s), (F = Z.indexOf(".")) > -1 ? Z = Z.replace(".", "") : F = Z.length;
|
|
7661
7681
|
}
|
|
7662
|
-
for (
|
|
7682
|
+
for (G = 0; Z.charCodeAt(G) === 48; G++)
|
|
7663
7683
|
;
|
|
7664
7684
|
for (K = Z.length; Z.charCodeAt(--K) === 48; )
|
|
7665
7685
|
;
|
|
7666
|
-
if (Z = Z.slice(
|
|
7667
|
-
if (K -=
|
|
7686
|
+
if (Z = Z.slice(G, ++K)) {
|
|
7687
|
+
if (K -= G, j && fe.DEBUG && K > 15 && (D > J || D !== l(D)))
|
|
7668
7688
|
throw Error(A + z.s * D);
|
|
7669
|
-
if ((F = F -
|
|
7689
|
+
if ((F = F - G - 1) > Ee)
|
|
7670
7690
|
z.c = z.e = null;
|
|
7671
7691
|
else if (F < Ce)
|
|
7672
7692
|
z.c = [z.e = 0];
|
|
7673
7693
|
else {
|
|
7674
|
-
if (z.e = F, z.c = [],
|
|
7675
|
-
for (
|
|
7676
|
-
z.c.push(+Z.slice(
|
|
7677
|
-
|
|
7694
|
+
if (z.e = F, z.c = [], G = (F + 1) % B, F < 0 && (G += B), G < K) {
|
|
7695
|
+
for (G && z.c.push(+Z.slice(0, G)), K -= B; G < K; )
|
|
7696
|
+
z.c.push(+Z.slice(G, G += B));
|
|
7697
|
+
G = B - (Z = Z.slice(G)).length;
|
|
7678
7698
|
} else
|
|
7679
|
-
|
|
7680
|
-
for (;
|
|
7699
|
+
G -= K;
|
|
7700
|
+
for (; G--; Z += "0")
|
|
7681
7701
|
;
|
|
7682
7702
|
z.c.push(+Z);
|
|
7683
7703
|
}
|
|
@@ -7688,10 +7708,10 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7688
7708
|
var M, W;
|
|
7689
7709
|
if (D != null)
|
|
7690
7710
|
if (typeof D == "object") {
|
|
7691
|
-
if (D.hasOwnProperty(M = "DECIMAL_PLACES") && (W = D[M],
|
|
7711
|
+
if (D.hasOwnProperty(M = "DECIMAL_PLACES") && (W = D[M], Y(W, 0, X, M), de = W), D.hasOwnProperty(M = "ROUNDING_MODE") && (W = D[M], Y(W, 0, 8, M), me = W), D.hasOwnProperty(M = "EXPONENTIAL_AT") && (W = D[M], W && W.pop ? (Y(W[0], -X, 0, M), Y(W[1], 0, X, M), Oe = W[0], Ae = W[1]) : (Y(W, -X, X, M), Oe = -(Ae = W < 0 ? -W : W))), D.hasOwnProperty(M = "RANGE"))
|
|
7692
7712
|
if (W = D[M], W && W.pop)
|
|
7693
|
-
|
|
7694
|
-
else if (
|
|
7713
|
+
Y(W[0], -X, -1, M), Y(W[1], 1, X, M), Ce = W[0], Ee = W[1];
|
|
7714
|
+
else if (Y(W, -X, X, M), W)
|
|
7695
7715
|
Ce = -(Ee = W < 0 ? -W : W);
|
|
7696
7716
|
else
|
|
7697
7717
|
throw Error(C + M + " cannot be zero: " + W);
|
|
@@ -7706,7 +7726,7 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7706
7726
|
Re = W;
|
|
7707
7727
|
else
|
|
7708
7728
|
throw Error(C + M + " not true or false: " + W);
|
|
7709
|
-
if (D.hasOwnProperty(M = "MODULO_MODE") && (W = D[M],
|
|
7729
|
+
if (D.hasOwnProperty(M = "MODULO_MODE") && (W = D[M], Y(W, 0, 9, M), Te = W), D.hasOwnProperty(M = "POW_PRECISION") && (W = D[M], Y(W, 0, X, M), Fe = W), D.hasOwnProperty(M = "FORMAT"))
|
|
7710
7730
|
if (W = D[M], typeof W == "object")
|
|
7711
7731
|
ke = W;
|
|
7712
7732
|
else
|
|
@@ -7720,8 +7740,8 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7720
7740
|
throw Error(C + "Object expected: " + D);
|
|
7721
7741
|
return {
|
|
7722
7742
|
DECIMAL_PLACES: de,
|
|
7723
|
-
ROUNDING_MODE:
|
|
7724
|
-
EXPONENTIAL_AT: [
|
|
7743
|
+
ROUNDING_MODE: me,
|
|
7744
|
+
EXPONENTIAL_AT: [Oe, Ae],
|
|
7725
7745
|
RANGE: [Ce, Ee],
|
|
7726
7746
|
CRYPTO: Re,
|
|
7727
7747
|
MODULO_MODE: Te,
|
|
@@ -7737,7 +7757,7 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7737
7757
|
var M, W, R = D.c, I = D.e, F = D.s;
|
|
7738
7758
|
e:
|
|
7739
7759
|
if ({}.toString.call(R) == "[object Array]") {
|
|
7740
|
-
if ((F === 1 || F === -1) && I >= -
|
|
7760
|
+
if ((F === 1 || F === -1) && I >= -X && I <= X && I === l(I)) {
|
|
7741
7761
|
if (R[0] === 0) {
|
|
7742
7762
|
if (I === 0 && R.length === 1)
|
|
7743
7763
|
return !0;
|
|
@@ -7765,22 +7785,22 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7765
7785
|
return (Math.random() * 1073741824 | 0) * 8388608 + (Math.random() * 8388608 | 0);
|
|
7766
7786
|
};
|
|
7767
7787
|
return function(W) {
|
|
7768
|
-
var R, I, F,
|
|
7769
|
-
if (W == null ? W = de :
|
|
7788
|
+
var R, I, F, G, j, K = 0, Z = [], z = new fe(pe);
|
|
7789
|
+
if (W == null ? W = de : Y(W, 0, X), G = c(W / B), Re)
|
|
7770
7790
|
if (crypto.getRandomValues) {
|
|
7771
|
-
for (R = crypto.getRandomValues(new Uint32Array(
|
|
7791
|
+
for (R = crypto.getRandomValues(new Uint32Array(G *= 2)); K < G; )
|
|
7772
7792
|
j = R[K] * 131072 + (R[K + 1] >>> 11), j >= 9e15 ? (I = crypto.getRandomValues(new Uint32Array(2)), R[K] = I[0], R[K + 1] = I[1]) : (Z.push(j % 1e14), K += 2);
|
|
7773
|
-
K =
|
|
7793
|
+
K = G / 2;
|
|
7774
7794
|
} else if (crypto.randomBytes) {
|
|
7775
|
-
for (R = crypto.randomBytes(
|
|
7795
|
+
for (R = crypto.randomBytes(G *= 7); K < G; )
|
|
7776
7796
|
j = (R[K] & 31) * 281474976710656 + R[K + 1] * 1099511627776 + R[K + 2] * 4294967296 + R[K + 3] * 16777216 + (R[K + 4] << 16) + (R[K + 5] << 8) + R[K + 6], j >= 9e15 ? crypto.randomBytes(7).copy(R, K) : (Z.push(j % 1e14), K += 7);
|
|
7777
|
-
K =
|
|
7797
|
+
K = G / 7;
|
|
7778
7798
|
} else
|
|
7779
7799
|
throw Re = !1, Error(C + "crypto unavailable");
|
|
7780
7800
|
if (!Re)
|
|
7781
|
-
for (; K <
|
|
7801
|
+
for (; K < G; )
|
|
7782
7802
|
j = M(), j < 9e15 && (Z[K++] = j % 1e14);
|
|
7783
|
-
for (
|
|
7803
|
+
for (G = Z[--K], W %= B, G && W && (j = U[B - W], Z[K] = l(G / j) * j); Z[K] === 0; Z.pop(), K--)
|
|
7784
7804
|
;
|
|
7785
7805
|
if (K < 0)
|
|
7786
7806
|
Z = [F = 0];
|
|
@@ -7797,30 +7817,30 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7797
7817
|
for (var D = 1, M = arguments, W = new fe(M[0]); D < M.length; )
|
|
7798
7818
|
W = W.plus(M[D++]);
|
|
7799
7819
|
return W;
|
|
7800
|
-
},
|
|
7820
|
+
}, H = function() {
|
|
7801
7821
|
var D = "0123456789";
|
|
7802
7822
|
function M(W, R, I, F) {
|
|
7803
|
-
for (var
|
|
7823
|
+
for (var G, j = [0], K, Z = 0, z = W.length; Z < z; ) {
|
|
7804
7824
|
for (K = j.length; K--; j[K] *= R)
|
|
7805
7825
|
;
|
|
7806
|
-
for (j[0] += F.indexOf(W.charAt(Z++)),
|
|
7807
|
-
j[
|
|
7826
|
+
for (j[0] += F.indexOf(W.charAt(Z++)), G = 0; G < j.length; G++)
|
|
7827
|
+
j[G] > I - 1 && (j[G + 1] == null && (j[G + 1] = 0), j[G + 1] += j[G] / I | 0, j[G] %= I);
|
|
7808
7828
|
}
|
|
7809
7829
|
return j.reverse();
|
|
7810
7830
|
}
|
|
7811
|
-
return function(W, R, I, F,
|
|
7812
|
-
var j, K, Z, z, ue,
|
|
7813
|
-
for (Se >= 0 && (z = Fe, Fe = 0, W = W.replace(".", ""), ye = new fe(R),
|
|
7814
|
-
|
|
7831
|
+
return function(W, R, I, F, G) {
|
|
7832
|
+
var j, K, Z, z, ue, ge, _e, ye, Se = W.indexOf("."), Ne = de, ee = me;
|
|
7833
|
+
for (Se >= 0 && (z = Fe, Fe = 0, W = W.replace(".", ""), ye = new fe(R), ge = ye.pow(W.length - Se), Fe = z, ye.c = M(
|
|
7834
|
+
ae(ne(ge.c), ge.e, "0"),
|
|
7815
7835
|
10,
|
|
7816
7836
|
I,
|
|
7817
7837
|
D
|
|
7818
|
-
), ye.e = ye.c.length), _e = M(W, R, I,
|
|
7838
|
+
), ye.e = ye.c.length), _e = M(W, R, I, G ? (j = he, D) : (j = D, he)), Z = z = _e.length; _e[--z] == 0; _e.pop())
|
|
7819
7839
|
;
|
|
7820
7840
|
if (!_e[0])
|
|
7821
7841
|
return j.charAt(0);
|
|
7822
|
-
if (Se < 0 ? --Z : (
|
|
7823
|
-
W = ue ?
|
|
7842
|
+
if (Se < 0 ? --Z : (ge.c = _e, ge.e = Z, ge.s = F, ge = ie(ge, ye, Ne, ee, I), _e = ge.c, ue = ge.r, Z = ge.e), K = Z + Ne + 1, Se = _e[K], z = I / 2, ue = ue || K < 0 || _e[K + 1] != null, ue = ee < 4 ? (Se != null || ue) && (ee == 0 || ee == (ge.s < 0 ? 3 : 2)) : Se > z || Se == z && (ee == 4 || ue || ee == 6 && _e[K - 1] & 1 || ee == (ge.s < 0 ? 8 : 7)), K < 1 || !_e[0])
|
|
7843
|
+
W = ue ? ae(j.charAt(1), -Ne, j.charAt(0)) : j.charAt(0);
|
|
7824
7844
|
else {
|
|
7825
7845
|
if (_e.length = K, ue)
|
|
7826
7846
|
for (--I; ++_e[--K] > I; )
|
|
@@ -7829,21 +7849,21 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7829
7849
|
;
|
|
7830
7850
|
for (Se = 0, W = ""; Se <= z; W += j.charAt(_e[Se++]))
|
|
7831
7851
|
;
|
|
7832
|
-
W =
|
|
7852
|
+
W = ae(W, Z, j.charAt(0));
|
|
7833
7853
|
}
|
|
7834
7854
|
return W;
|
|
7835
7855
|
};
|
|
7836
7856
|
}(), ie = function() {
|
|
7837
7857
|
function D(R, I, F) {
|
|
7838
|
-
var
|
|
7858
|
+
var G, j, K, Z, z = 0, ue = R.length, ge = I % V, _e = I / V | 0;
|
|
7839
7859
|
for (R = R.slice(); ue--; )
|
|
7840
|
-
K = R[ue] % V, Z = R[ue] / V | 0,
|
|
7860
|
+
K = R[ue] % V, Z = R[ue] / V | 0, G = _e * K + Z * ge, j = ge * K + G % V * V + z, z = (j / F | 0) + (G / V | 0) + _e * Z, R[ue] = j % F;
|
|
7841
7861
|
return z && (R = [z].concat(R)), R;
|
|
7842
7862
|
}
|
|
7843
|
-
function M(R, I, F,
|
|
7863
|
+
function M(R, I, F, G) {
|
|
7844
7864
|
var j, K;
|
|
7845
|
-
if (F !=
|
|
7846
|
-
K = F >
|
|
7865
|
+
if (F != G)
|
|
7866
|
+
K = F > G ? 1 : -1;
|
|
7847
7867
|
else
|
|
7848
7868
|
for (j = K = 0; j < F; j++)
|
|
7849
7869
|
if (R[j] != I[j]) {
|
|
@@ -7852,14 +7872,14 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7852
7872
|
}
|
|
7853
7873
|
return K;
|
|
7854
7874
|
}
|
|
7855
|
-
function W(R, I, F,
|
|
7875
|
+
function W(R, I, F, G) {
|
|
7856
7876
|
for (var j = 0; F--; )
|
|
7857
|
-
R[F] -= j, j = R[F] < I[F] ? 1 : 0, R[F] = j *
|
|
7877
|
+
R[F] -= j, j = R[F] < I[F] ? 1 : 0, R[F] = j * G + R[F] - I[F];
|
|
7858
7878
|
for (; !R[0] && R.length > 1; R.splice(0, 1))
|
|
7859
7879
|
;
|
|
7860
7880
|
}
|
|
7861
|
-
return function(R, I, F,
|
|
7862
|
-
var K, Z, z, ue,
|
|
7881
|
+
return function(R, I, F, G, j) {
|
|
7882
|
+
var K, Z, z, ue, ge, _e, ye, Se, Ne, ee, le, ve, we, je, Be, xe, $e, We = R.s == I.s ? 1 : -1, Ve = R.c, Ue = I.c;
|
|
7863
7883
|
if (!Ve || !Ve[0] || !Ue || !Ue[0])
|
|
7864
7884
|
return new fe(
|
|
7865
7885
|
// Return NaN if either NaN, or both Infinity or 0.
|
|
@@ -7873,45 +7893,45 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7873
7893
|
if (Ue[z] > (Ve[z] || 0) && Z--, We < 0)
|
|
7874
7894
|
Ne.push(1), ue = !0;
|
|
7875
7895
|
else {
|
|
7876
|
-
for (je = Ve.length, xe = Ue.length, z = 0, We += 2,
|
|
7896
|
+
for (je = Ve.length, xe = Ue.length, z = 0, We += 2, ge = l(j / (Ue[0] + 1)), ge > 1 && (Ue = D(Ue, ge, j), Ve = D(Ve, ge, j), xe = Ue.length, je = Ve.length), we = xe, ee = Ve.slice(0, xe), le = ee.length; le < xe; ee[le++] = 0)
|
|
7877
7897
|
;
|
|
7878
7898
|
$e = Ue.slice(), $e = [0].concat($e), Be = Ue[0], Ue[1] >= j / 2 && Be++;
|
|
7879
7899
|
do {
|
|
7880
|
-
if (
|
|
7881
|
-
if (
|
|
7882
|
-
for (
|
|
7883
|
-
|
|
7900
|
+
if (ge = 0, K = M(Ue, ee, xe, le), K < 0) {
|
|
7901
|
+
if (ve = ee[0], xe != le && (ve = ve * j + (ee[1] || 0)), ge = l(ve / Be), ge > 1)
|
|
7902
|
+
for (ge >= j && (ge = j - 1), _e = D(Ue, ge, j), ye = _e.length, le = ee.length; M(_e, ee, ye, le) == 1; )
|
|
7903
|
+
ge--, W(_e, xe < ye ? $e : Ue, ye, j), ye = _e.length, K = 1;
|
|
7884
7904
|
else
|
|
7885
|
-
|
|
7905
|
+
ge == 0 && (K = ge = 1), _e = Ue.slice(), ye = _e.length;
|
|
7886
7906
|
if (ye < le && (_e = [0].concat(_e)), W(ee, _e, le, j), le = ee.length, K == -1)
|
|
7887
7907
|
for (; M(Ue, ee, xe, le) < 1; )
|
|
7888
|
-
|
|
7908
|
+
ge++, W(ee, xe < le ? $e : Ue, le, j), le = ee.length;
|
|
7889
7909
|
} else
|
|
7890
|
-
K === 0 && (
|
|
7891
|
-
Ne[z++] =
|
|
7910
|
+
K === 0 && (ge++, ee = [0]);
|
|
7911
|
+
Ne[z++] = ge, ee[0] ? ee[le++] = Ve[we] || 0 : (ee = [Ve[we]], le = 1);
|
|
7892
7912
|
} while ((we++ < je || ee[0] != null) && We--);
|
|
7893
7913
|
ue = ee[0] != null, Ne[0] || Ne.splice(0, 1);
|
|
7894
7914
|
}
|
|
7895
7915
|
if (j == L) {
|
|
7896
7916
|
for (z = 1, We = Ne[0]; We >= 10; We /= 10, z++)
|
|
7897
7917
|
;
|
|
7898
|
-
Ie(Se, F + (Se.e = z + Z * B - 1) + 1,
|
|
7918
|
+
Ie(Se, F + (Se.e = z + Z * B - 1) + 1, G, ue);
|
|
7899
7919
|
} else
|
|
7900
7920
|
Se.e = Z, Se.r = +ue;
|
|
7901
7921
|
return Se;
|
|
7902
7922
|
};
|
|
7903
7923
|
}();
|
|
7904
7924
|
function Pe(D, M, W, R) {
|
|
7905
|
-
var I, F,
|
|
7906
|
-
if (W == null ? W =
|
|
7925
|
+
var I, F, G, j, K;
|
|
7926
|
+
if (W == null ? W = me : Y(W, 0, 8), !D.c)
|
|
7907
7927
|
return D.toString();
|
|
7908
|
-
if (I = D.c[0],
|
|
7909
|
-
K =
|
|
7910
|
-
else if (D = Ie(new fe(D), M, W), F = D.e, K =
|
|
7928
|
+
if (I = D.c[0], G = D.e, M == null)
|
|
7929
|
+
K = ne(D.c), K = R == 1 || R == 2 && (G <= Oe || G >= Ae) ? re(K, G) : ae(K, G, "0");
|
|
7930
|
+
else if (D = Ie(new fe(D), M, W), F = D.e, K = ne(D.c), j = K.length, R == 1 || R == 2 && (M <= F || F <= Oe)) {
|
|
7911
7931
|
for (; j < M; K += "0", j++)
|
|
7912
7932
|
;
|
|
7913
|
-
K =
|
|
7914
|
-
} else if (M -=
|
|
7933
|
+
K = re(K, F);
|
|
7934
|
+
} else if (M -= G, K = ae(K, F, "0"), F + 1 > j) {
|
|
7915
7935
|
if (--M > 0)
|
|
7916
7936
|
for (K += "."; M--; K += "0")
|
|
7917
7937
|
;
|
|
@@ -7922,7 +7942,7 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7922
7942
|
}
|
|
7923
7943
|
function Me(D, M) {
|
|
7924
7944
|
for (var W, R, I = 1, F = new fe(D[0]); I < D.length; I++)
|
|
7925
|
-
R = new fe(D[I]), (!R.s || (W =
|
|
7945
|
+
R = new fe(D[I]), (!R.s || (W = q(F, R)) === M || W === 0 && F.s === M) && (F = R);
|
|
7926
7946
|
return F;
|
|
7927
7947
|
}
|
|
7928
7948
|
function De(D, M, W) {
|
|
@@ -7934,54 +7954,54 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7934
7954
|
}
|
|
7935
7955
|
$ = function() {
|
|
7936
7956
|
var D = /^(-?)0([xbo])(?=\w[\w.]*$)/i, M = /^([^.]+)\.$/, W = /^\.([^.]+)$/, R = /^-?(Infinity|NaN)$/, I = /^\s*\+(?=[\w.])|^\s+|\s+$/g;
|
|
7937
|
-
return function(F,
|
|
7938
|
-
var Z, z = j ?
|
|
7957
|
+
return function(F, G, j, K) {
|
|
7958
|
+
var Z, z = j ? G : G.replace(I, "");
|
|
7939
7959
|
if (R.test(z))
|
|
7940
7960
|
F.s = isNaN(z) ? null : z < 0 ? -1 : 1;
|
|
7941
7961
|
else {
|
|
7942
|
-
if (!j && (z = z.replace(D, function(ue,
|
|
7943
|
-
return Z = (_e = _e.toLowerCase()) == "x" ? 16 : _e == "b" ? 2 : 8, !K || K == Z ?
|
|
7944
|
-
}), K && (Z = K, z = z.replace(M, "$1").replace(W, "0.$1")),
|
|
7962
|
+
if (!j && (z = z.replace(D, function(ue, ge, _e) {
|
|
7963
|
+
return Z = (_e = _e.toLowerCase()) == "x" ? 16 : _e == "b" ? 2 : 8, !K || K == Z ? ge : ue;
|
|
7964
|
+
}), K && (Z = K, z = z.replace(M, "$1").replace(W, "0.$1")), G != z))
|
|
7945
7965
|
return new fe(z, Z);
|
|
7946
7966
|
if (fe.DEBUG)
|
|
7947
|
-
throw Error(C + "Not a" + (K ? " base " + K : "") + " number: " +
|
|
7967
|
+
throw Error(C + "Not a" + (K ? " base " + K : "") + " number: " + G);
|
|
7948
7968
|
F.s = null;
|
|
7949
7969
|
}
|
|
7950
7970
|
F.c = F.e = null;
|
|
7951
7971
|
};
|
|
7952
7972
|
}();
|
|
7953
7973
|
function Ie(D, M, W, R) {
|
|
7954
|
-
var I, F,
|
|
7974
|
+
var I, F, G, j, K, Z, z, ue = D.c, ge = U;
|
|
7955
7975
|
if (ue) {
|
|
7956
7976
|
e: {
|
|
7957
7977
|
for (I = 1, j = ue[0]; j >= 10; j /= 10, I++)
|
|
7958
7978
|
;
|
|
7959
7979
|
if (F = M - I, F < 0)
|
|
7960
|
-
F += B,
|
|
7980
|
+
F += B, G = M, K = ue[Z = 0], z = l(K / ge[I - G - 1] % 10);
|
|
7961
7981
|
else if (Z = c((F + 1) / B), Z >= ue.length)
|
|
7962
7982
|
if (R) {
|
|
7963
7983
|
for (; ue.length <= Z; ue.push(0))
|
|
7964
7984
|
;
|
|
7965
|
-
K = z = 0, I = 1, F %= B,
|
|
7985
|
+
K = z = 0, I = 1, F %= B, G = F - B + 1;
|
|
7966
7986
|
} else
|
|
7967
7987
|
break e;
|
|
7968
7988
|
else {
|
|
7969
7989
|
for (K = j = ue[Z], I = 1; j >= 10; j /= 10, I++)
|
|
7970
7990
|
;
|
|
7971
|
-
F %= B,
|
|
7991
|
+
F %= B, G = F - B + I, z = G < 0 ? 0 : l(K / ge[I - G - 1] % 10);
|
|
7972
7992
|
}
|
|
7973
7993
|
if (R = R || M < 0 || // Are there any non-zero digits after the rounding digit?
|
|
7974
7994
|
// The expression n % pows10[d - j - 1] returns all digits of n to the right
|
|
7975
7995
|
// of the digit at j, e.g. if n is 908714 and j is 2, the expression gives 714.
|
|
7976
|
-
ue[Z + 1] != null || (
|
|
7977
|
-
(F > 0 ?
|
|
7978
|
-
return ue.length = 0, R ? (M -= D.e + 1, ue[0] =
|
|
7979
|
-
if (F == 0 ? (ue.length = Z, j = 1, Z--) : (ue.length = Z + 1, j =
|
|
7996
|
+
ue[Z + 1] != null || (G < 0 ? K : K % ge[I - G - 1]), R = W < 4 ? (z || R) && (W == 0 || W == (D.s < 0 ? 3 : 2)) : z > 5 || z == 5 && (W == 4 || R || W == 6 && // Check whether the digit to the left of the rounding digit is odd.
|
|
7997
|
+
(F > 0 ? G > 0 ? K / ge[I - G] : 0 : ue[Z - 1]) % 10 & 1 || W == (D.s < 0 ? 8 : 7)), M < 1 || !ue[0])
|
|
7998
|
+
return ue.length = 0, R ? (M -= D.e + 1, ue[0] = ge[(B - M % B) % B], D.e = -M || 0) : ue[0] = D.e = 0, D;
|
|
7999
|
+
if (F == 0 ? (ue.length = Z, j = 1, Z--) : (ue.length = Z + 1, j = ge[B - F], ue[Z] = G > 0 ? l(K / ge[I - G] % ge[G]) * j : 0), R)
|
|
7980
8000
|
for (; ; )
|
|
7981
8001
|
if (Z == 0) {
|
|
7982
|
-
for (F = 1,
|
|
8002
|
+
for (F = 1, G = ue[0]; G >= 10; G /= 10, F++)
|
|
7983
8003
|
;
|
|
7984
|
-
for (
|
|
8004
|
+
for (G = ue[0] += j, j = 1; G >= 10; G /= 10, j++)
|
|
7985
8005
|
;
|
|
7986
8006
|
F != j && (D.e++, ue[0] == L && (ue[0] = 1));
|
|
7987
8007
|
break;
|
|
@@ -7999,43 +8019,43 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
7999
8019
|
}
|
|
8000
8020
|
function be(D) {
|
|
8001
8021
|
var M, W = D.e;
|
|
8002
|
-
return W === null ? D.toString() : (M =
|
|
8022
|
+
return W === null ? D.toString() : (M = ne(D.c), M = W <= Oe || W >= Ae ? re(M, W) : ae(M, W, "0"), D.s < 0 ? "-" + M : M);
|
|
8003
8023
|
}
|
|
8004
|
-
return
|
|
8024
|
+
return Q.absoluteValue = Q.abs = function() {
|
|
8005
8025
|
var D = new fe(this);
|
|
8006
8026
|
return D.s < 0 && (D.s = 1), D;
|
|
8007
|
-
},
|
|
8008
|
-
return
|
|
8009
|
-
},
|
|
8027
|
+
}, Q.comparedTo = function(D, M) {
|
|
8028
|
+
return q(this, new fe(D, M));
|
|
8029
|
+
}, Q.decimalPlaces = Q.dp = function(D, M) {
|
|
8010
8030
|
var W, R, I, F = this;
|
|
8011
8031
|
if (D != null)
|
|
8012
|
-
return
|
|
8032
|
+
return Y(D, 0, X), M == null ? M = me : Y(M, 0, 8), Ie(new fe(F), D + F.e + 1, M);
|
|
8013
8033
|
if (!(W = F.c))
|
|
8014
8034
|
return null;
|
|
8015
8035
|
if (R = ((I = W.length - 1) - se(this.e / B)) * B, I = W[I])
|
|
8016
8036
|
for (; I % 10 == 0; I /= 10, R--)
|
|
8017
8037
|
;
|
|
8018
8038
|
return R < 0 && (R = 0), R;
|
|
8019
|
-
},
|
|
8020
|
-
return ie(this, new fe(D, M), de,
|
|
8021
|
-
},
|
|
8039
|
+
}, Q.dividedBy = Q.div = function(D, M) {
|
|
8040
|
+
return ie(this, new fe(D, M), de, me);
|
|
8041
|
+
}, Q.dividedToIntegerBy = Q.idiv = function(D, M) {
|
|
8022
8042
|
return ie(this, new fe(D, M), 0, 1);
|
|
8023
|
-
},
|
|
8024
|
-
var W, R, I, F,
|
|
8043
|
+
}, Q.exponentiatedBy = Q.pow = function(D, M) {
|
|
8044
|
+
var W, R, I, F, G, j, K, Z, z, ue = this;
|
|
8025
8045
|
if (D = new fe(D), D.c && !D.isInteger())
|
|
8026
8046
|
throw Error(C + "Exponent not an integer: " + be(D));
|
|
8027
8047
|
if (M != null && (M = new fe(M)), j = D.e > 14, !ue.c || !ue.c[0] || ue.c[0] == 1 && !ue.e && ue.c.length == 1 || !D.c || !D.c[0])
|
|
8028
|
-
return z = new fe(Math.pow(+be(ue), j ? D.s * (2 -
|
|
8048
|
+
return z = new fe(Math.pow(+be(ue), j ? D.s * (2 - oe(D)) : +be(D))), M ? z.mod(M) : z;
|
|
8029
8049
|
if (K = D.s < 0, M) {
|
|
8030
8050
|
if (M.c ? !M.c[0] : !M.s)
|
|
8031
8051
|
return new fe(NaN);
|
|
8032
8052
|
R = !K && ue.isInteger() && M.isInteger(), R && (ue = ue.mod(M));
|
|
8033
8053
|
} else {
|
|
8034
8054
|
if (D.e > 9 && (ue.e > 0 || ue.e < -1 || (ue.e == 0 ? ue.c[0] > 1 || j && ue.c[1] >= 24e7 : ue.c[0] < 8e13 || j && ue.c[0] <= 9999975e7)))
|
|
8035
|
-
return F = ue.s < 0 &&
|
|
8055
|
+
return F = ue.s < 0 && oe(D) ? -0 : 0, ue.e > -1 && (F = 1 / F), new fe(K ? 1 / F : F);
|
|
8036
8056
|
Fe && (F = c(Fe / B + 2));
|
|
8037
8057
|
}
|
|
8038
|
-
for (j ? (W = new fe(0.5), K && (D.s = 1), Z =
|
|
8058
|
+
for (j ? (W = new fe(0.5), K && (D.s = 1), Z = oe(D)) : (I = Math.abs(+be(D)), Z = I % 2), z = new fe(pe); ; ) {
|
|
8039
8059
|
if (Z) {
|
|
8040
8060
|
if (z = z.times(ue), !z.c)
|
|
8041
8061
|
break;
|
|
@@ -8046,7 +8066,7 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
8046
8066
|
break;
|
|
8047
8067
|
Z = I % 2;
|
|
8048
8068
|
} else if (D = D.times(W), Ie(D, D.e + 1, 1), D.e > 14)
|
|
8049
|
-
Z =
|
|
8069
|
+
Z = oe(D);
|
|
8050
8070
|
else {
|
|
8051
8071
|
if (I = +be(D), I === 0)
|
|
8052
8072
|
break;
|
|
@@ -8054,46 +8074,46 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
8054
8074
|
}
|
|
8055
8075
|
ue = ue.times(ue), F ? ue.c && ue.c.length > F && (ue.c.length = F) : R && (ue = ue.mod(M));
|
|
8056
8076
|
}
|
|
8057
|
-
return R ? z : (K && (z = pe.div(z)), M ? z.mod(M) : F ? Ie(z, Fe,
|
|
8058
|
-
},
|
|
8077
|
+
return R ? z : (K && (z = pe.div(z)), M ? z.mod(M) : F ? Ie(z, Fe, me, G) : z);
|
|
8078
|
+
}, Q.integerValue = function(D) {
|
|
8059
8079
|
var M = new fe(this);
|
|
8060
|
-
return D == null ? D =
|
|
8061
|
-
},
|
|
8062
|
-
return
|
|
8063
|
-
},
|
|
8080
|
+
return D == null ? D = me : Y(D, 0, 8), Ie(M, M.e + 1, D);
|
|
8081
|
+
}, Q.isEqualTo = Q.eq = function(D, M) {
|
|
8082
|
+
return q(this, new fe(D, M)) === 0;
|
|
8083
|
+
}, Q.isFinite = function() {
|
|
8064
8084
|
return !!this.c;
|
|
8065
|
-
},
|
|
8066
|
-
return
|
|
8067
|
-
},
|
|
8068
|
-
return (M =
|
|
8069
|
-
},
|
|
8085
|
+
}, Q.isGreaterThan = Q.gt = function(D, M) {
|
|
8086
|
+
return q(this, new fe(D, M)) > 0;
|
|
8087
|
+
}, Q.isGreaterThanOrEqualTo = Q.gte = function(D, M) {
|
|
8088
|
+
return (M = q(this, new fe(D, M))) === 1 || M === 0;
|
|
8089
|
+
}, Q.isInteger = function() {
|
|
8070
8090
|
return !!this.c && se(this.e / B) > this.c.length - 2;
|
|
8071
|
-
},
|
|
8072
|
-
return
|
|
8073
|
-
},
|
|
8074
|
-
return (M =
|
|
8075
|
-
},
|
|
8091
|
+
}, Q.isLessThan = Q.lt = function(D, M) {
|
|
8092
|
+
return q(this, new fe(D, M)) < 0;
|
|
8093
|
+
}, Q.isLessThanOrEqualTo = Q.lte = function(D, M) {
|
|
8094
|
+
return (M = q(this, new fe(D, M))) === -1 || M === 0;
|
|
8095
|
+
}, Q.isNaN = function() {
|
|
8076
8096
|
return !this.s;
|
|
8077
|
-
},
|
|
8097
|
+
}, Q.isNegative = function() {
|
|
8078
8098
|
return this.s < 0;
|
|
8079
|
-
},
|
|
8099
|
+
}, Q.isPositive = function() {
|
|
8080
8100
|
return this.s > 0;
|
|
8081
|
-
},
|
|
8101
|
+
}, Q.isZero = function() {
|
|
8082
8102
|
return !!this.c && this.c[0] == 0;
|
|
8083
|
-
},
|
|
8084
|
-
var W, R, I, F,
|
|
8103
|
+
}, Q.minus = function(D, M) {
|
|
8104
|
+
var W, R, I, F, G = this, j = G.s;
|
|
8085
8105
|
if (D = new fe(D, M), M = D.s, !j || !M)
|
|
8086
8106
|
return new fe(NaN);
|
|
8087
8107
|
if (j != M)
|
|
8088
|
-
return D.s = -M,
|
|
8089
|
-
var K =
|
|
8108
|
+
return D.s = -M, G.plus(D);
|
|
8109
|
+
var K = G.e / B, Z = D.e / B, z = G.c, ue = D.c;
|
|
8090
8110
|
if (!K || !Z) {
|
|
8091
8111
|
if (!z || !ue)
|
|
8092
|
-
return z ? (D.s = -M, D) : new fe(ue ?
|
|
8112
|
+
return z ? (D.s = -M, D) : new fe(ue ? G : NaN);
|
|
8093
8113
|
if (!z[0] || !ue[0])
|
|
8094
|
-
return ue[0] ? (D.s = -M, D) : new fe(z[0] ?
|
|
8114
|
+
return ue[0] ? (D.s = -M, D) : new fe(z[0] ? G : (
|
|
8095
8115
|
// IEEE 754 (2008) 6.3: n - n = -0 when rounding to -Infinity
|
|
8096
|
-
|
|
8116
|
+
me == 3 ? -0 : 0
|
|
8097
8117
|
));
|
|
8098
8118
|
}
|
|
8099
8119
|
if (K = se(K), Z = se(Z), z = z.slice(), j = K - Z) {
|
|
@@ -8119,50 +8139,50 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
8119
8139
|
}
|
|
8120
8140
|
for (; z[0] == 0; z.splice(0, 1), --Z)
|
|
8121
8141
|
;
|
|
8122
|
-
return z[0] ? De(D, z, Z) : (D.s =
|
|
8123
|
-
},
|
|
8142
|
+
return z[0] ? De(D, z, Z) : (D.s = me == 3 ? -1 : 1, D.c = [D.e = 0], D);
|
|
8143
|
+
}, Q.modulo = Q.mod = function(D, M) {
|
|
8124
8144
|
var W, R, I = this;
|
|
8125
8145
|
return D = new fe(D, M), !I.c || !D.s || D.c && !D.c[0] ? new fe(NaN) : !D.c || I.c && !I.c[0] ? new fe(I) : (Te == 9 ? (R = D.s, D.s = 1, W = ie(I, D, 0, 3), D.s = R, W.s *= R) : W = ie(I, D, 0, Te), D = I.minus(W.times(D)), !D.c[0] && Te == 1 && (D.s = I.s), D);
|
|
8126
|
-
},
|
|
8127
|
-
var W, R, I, F,
|
|
8128
|
-
if (!le || !
|
|
8129
|
-
return !ee.s || !D.s || le && !le[0] && !
|
|
8130
|
-
for (R = se(ee.e / B) + se(D.e / B), D.s *= ee.s, K = le.length, ue =
|
|
8146
|
+
}, Q.multipliedBy = Q.times = function(D, M) {
|
|
8147
|
+
var W, R, I, F, G, j, K, Z, z, ue, ge, _e, ye, Se, Ne, ee = this, le = ee.c, ve = (D = new fe(D, M)).c;
|
|
8148
|
+
if (!le || !ve || !le[0] || !ve[0])
|
|
8149
|
+
return !ee.s || !D.s || le && !le[0] && !ve || ve && !ve[0] && !le ? D.c = D.e = D.s = null : (D.s *= ee.s, !le || !ve ? D.c = D.e = null : (D.c = [0], D.e = 0)), D;
|
|
8150
|
+
for (R = se(ee.e / B) + se(D.e / B), D.s *= ee.s, K = le.length, ue = ve.length, K < ue && (ye = le, le = ve, ve = ye, I = K, K = ue, ue = I), I = K + ue, ye = []; I--; ye.push(0))
|
|
8131
8151
|
;
|
|
8132
8152
|
for (Se = L, Ne = V, I = ue; --I >= 0; ) {
|
|
8133
|
-
for (W = 0,
|
|
8134
|
-
Z = le[--
|
|
8153
|
+
for (W = 0, ge = ve[I] % Ne, _e = ve[I] / Ne | 0, G = K, F = I + G; F > I; )
|
|
8154
|
+
Z = le[--G] % Ne, z = le[G] / Ne | 0, j = _e * Z + z * ge, Z = ge * Z + j % Ne * Ne + ye[F] + W, W = (Z / Se | 0) + (j / Ne | 0) + _e * z, ye[F--] = Z % Se;
|
|
8135
8155
|
ye[F] = W;
|
|
8136
8156
|
}
|
|
8137
8157
|
return W ? ++R : ye.splice(0, 1), De(D, ye, R);
|
|
8138
|
-
},
|
|
8158
|
+
}, Q.negated = function() {
|
|
8139
8159
|
var D = new fe(this);
|
|
8140
8160
|
return D.s = -D.s || null, D;
|
|
8141
|
-
},
|
|
8161
|
+
}, Q.plus = function(D, M) {
|
|
8142
8162
|
var W, R = this, I = R.s;
|
|
8143
8163
|
if (D = new fe(D, M), M = D.s, !I || !M)
|
|
8144
8164
|
return new fe(NaN);
|
|
8145
8165
|
if (I != M)
|
|
8146
8166
|
return D.s = -M, R.minus(D);
|
|
8147
|
-
var F = R.e / B,
|
|
8148
|
-
if (!F || !
|
|
8167
|
+
var F = R.e / B, G = D.e / B, j = R.c, K = D.c;
|
|
8168
|
+
if (!F || !G) {
|
|
8149
8169
|
if (!j || !K)
|
|
8150
8170
|
return new fe(I / 0);
|
|
8151
8171
|
if (!j[0] || !K[0])
|
|
8152
8172
|
return K[0] ? D : new fe(j[0] ? R : I * 0);
|
|
8153
8173
|
}
|
|
8154
|
-
if (F = se(F),
|
|
8155
|
-
for (I > 0 ? (
|
|
8174
|
+
if (F = se(F), G = se(G), j = j.slice(), I = F - G) {
|
|
8175
|
+
for (I > 0 ? (G = F, W = K) : (I = -I, W = j), W.reverse(); I--; W.push(0))
|
|
8156
8176
|
;
|
|
8157
8177
|
W.reverse();
|
|
8158
8178
|
}
|
|
8159
8179
|
for (I = j.length, M = K.length, I - M < 0 && (W = K, K = j, j = W, M = I), I = 0; M; )
|
|
8160
8180
|
I = (j[--M] = j[M] + K[M] + I) / L | 0, j[M] = L === j[M] ? 0 : j[M] % L;
|
|
8161
|
-
return I && (j = [I].concat(j), ++
|
|
8162
|
-
},
|
|
8181
|
+
return I && (j = [I].concat(j), ++G), De(D, j, G);
|
|
8182
|
+
}, Q.precision = Q.sd = function(D, M) {
|
|
8163
8183
|
var W, R, I, F = this;
|
|
8164
8184
|
if (D != null && D !== !!D)
|
|
8165
|
-
return
|
|
8185
|
+
return Y(D, 1, X), M == null ? M = me : Y(M, 0, 8), Ie(new fe(F), D, M);
|
|
8166
8186
|
if (!(W = F.c))
|
|
8167
8187
|
return null;
|
|
8168
8188
|
if (I = W.length - 1, R = I * B + 1, I = W[I]) {
|
|
@@ -8172,15 +8192,15 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
8172
8192
|
;
|
|
8173
8193
|
}
|
|
8174
8194
|
return D && F.e + 1 > R && (R = F.e + 1), R;
|
|
8175
|
-
},
|
|
8176
|
-
return
|
|
8177
|
-
},
|
|
8178
|
-
var D, M, W, R, I, F = this,
|
|
8179
|
-
if (j !== 1 || !
|
|
8180
|
-
return new fe(!j || j < 0 && (!
|
|
8181
|
-
if (j = Math.sqrt(+be(F)), j == 0 || j == 1 / 0 ? (M =
|
|
8195
|
+
}, Q.shiftedBy = function(D) {
|
|
8196
|
+
return Y(D, -J, J), this.times("1e" + D);
|
|
8197
|
+
}, Q.squareRoot = Q.sqrt = function() {
|
|
8198
|
+
var D, M, W, R, I, F = this, G = F.c, j = F.s, K = F.e, Z = de + 4, z = new fe("0.5");
|
|
8199
|
+
if (j !== 1 || !G || !G[0])
|
|
8200
|
+
return new fe(!j || j < 0 && (!G || G[0]) ? NaN : G ? F : 1 / 0);
|
|
8201
|
+
if (j = Math.sqrt(+be(F)), j == 0 || j == 1 / 0 ? (M = ne(G), (M.length + K) % 2 == 0 && (M += "0"), j = Math.sqrt(+M), K = se((K + 1) / 2) - (K < 0 || K % 2), j == 1 / 0 ? M = "5e" + K : (M = j.toExponential(), M = M.slice(0, M.indexOf("e") + 1) + K), W = new fe(M)) : W = new fe(j + ""), W.c[0]) {
|
|
8182
8202
|
for (K = W.e, j = K + Z, j < 3 && (j = 0); ; )
|
|
8183
|
-
if (I = W, W = z.times(I.plus(ie(F, I, Z, 1))),
|
|
8203
|
+
if (I = W, W = z.times(I.plus(ie(F, I, Z, 1))), ne(I.c).slice(0, j) === (M = ne(W.c)).slice(0, j))
|
|
8184
8204
|
if (W.e < K && --j, M = M.slice(j - 3, j + 1), M == "9999" || !R && M == "4999") {
|
|
8185
8205
|
if (!R && (Ie(I, I.e + de + 2, 0), I.times(I).eq(F))) {
|
|
8186
8206
|
W = I;
|
|
@@ -8192,23 +8212,23 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
8192
8212
|
break;
|
|
8193
8213
|
}
|
|
8194
8214
|
}
|
|
8195
|
-
return Ie(W, W.e + de + 1,
|
|
8196
|
-
},
|
|
8197
|
-
return D != null && (
|
|
8198
|
-
},
|
|
8199
|
-
return D != null && (
|
|
8200
|
-
},
|
|
8215
|
+
return Ie(W, W.e + de + 1, me, D);
|
|
8216
|
+
}, Q.toExponential = function(D, M) {
|
|
8217
|
+
return D != null && (Y(D, 0, X), D++), Pe(this, D, M, 1);
|
|
8218
|
+
}, Q.toFixed = function(D, M) {
|
|
8219
|
+
return D != null && (Y(D, 0, X), D = D + this.e + 1), Pe(this, D, M);
|
|
8220
|
+
}, Q.toFormat = function(D, M, W) {
|
|
8201
8221
|
var R, I = this;
|
|
8202
8222
|
if (W == null)
|
|
8203
8223
|
D != null && M && typeof M == "object" ? (W = M, M = null) : D && typeof D == "object" ? (W = D, D = M = null) : W = ke;
|
|
8204
8224
|
else if (typeof W != "object")
|
|
8205
8225
|
throw Error(C + "Argument not an object: " + W);
|
|
8206
8226
|
if (R = I.toFixed(D, M), I.c) {
|
|
8207
|
-
var F,
|
|
8227
|
+
var F, G = R.split("."), j = +W.groupSize, K = +W.secondaryGroupSize, Z = W.groupSeparator || "", z = G[0], ue = G[1], ge = I.s < 0, _e = ge ? z.slice(1) : z, ye = _e.length;
|
|
8208
8228
|
if (K && (F = j, j = K, K = F, ye -= F), j > 0 && ye > 0) {
|
|
8209
8229
|
for (F = ye % j || j, z = _e.substr(0, F); F < ye; F += j)
|
|
8210
8230
|
z += Z + _e.substr(F, j);
|
|
8211
|
-
K > 0 && (z += Z + _e.slice(F)),
|
|
8231
|
+
K > 0 && (z += Z + _e.slice(F)), ge && (z = "-" + z);
|
|
8212
8232
|
}
|
|
8213
8233
|
R = ue ? z + (W.decimalSeparator || "") + ((K = +W.fractionGroupSize) ? ue.replace(
|
|
8214
8234
|
new RegExp("\\d{" + K + "}\\B", "g"),
|
|
@@ -8216,83 +8236,83 @@ var jsonBigint = { exports: {} }, stringify = { exports: {} }, bignumber = { exp
|
|
|
8216
8236
|
) : ue) : z;
|
|
8217
8237
|
}
|
|
8218
8238
|
return (W.prefix || "") + R + (W.suffix || "");
|
|
8219
|
-
},
|
|
8220
|
-
var M, W, R, I, F,
|
|
8239
|
+
}, Q.toFraction = function(D) {
|
|
8240
|
+
var M, W, R, I, F, G, j, K, Z, z, ue, ge, _e = this, ye = _e.c;
|
|
8221
8241
|
if (D != null && (j = new fe(D), !j.isInteger() && (j.c || j.s !== 1) || j.lt(pe)))
|
|
8222
8242
|
throw Error(C + "Argument " + (j.isInteger() ? "out of range: " : "not an integer: ") + be(j));
|
|
8223
8243
|
if (!ye)
|
|
8224
8244
|
return new fe(_e);
|
|
8225
|
-
for (M = new fe(pe), Z = W = new fe(pe), R = K = new fe(pe),
|
|
8245
|
+
for (M = new fe(pe), Z = W = new fe(pe), R = K = new fe(pe), ge = ne(ye), F = M.e = ge.length - _e.e - 1, M.c[0] = U[(G = F % B) < 0 ? B + G : G], D = !D || j.comparedTo(M) > 0 ? F > 0 ? M : Z : j, G = Ee, Ee = 1 / 0, j = new fe(ge), K.c[0] = 0; z = ie(j, M, 0, 1), I = W.plus(z.times(R)), I.comparedTo(D) != 1; )
|
|
8226
8246
|
W = R, R = I, Z = K.plus(z.times(I = Z)), K = I, M = j.minus(z.times(I = M)), j = I;
|
|
8227
|
-
return I = ie(D.minus(W), R, 0, 1), K = K.plus(I.times(Z)), W = W.plus(I.times(R)), K.s = Z.s = _e.s, F = F * 2, ue = ie(Z, R, F,
|
|
8228
|
-
ie(K, W, F,
|
|
8229
|
-
) < 1 ? [Z, R] : [K, W], Ee =
|
|
8230
|
-
},
|
|
8247
|
+
return I = ie(D.minus(W), R, 0, 1), K = K.plus(I.times(Z)), W = W.plus(I.times(R)), K.s = Z.s = _e.s, F = F * 2, ue = ie(Z, R, F, me).minus(_e).abs().comparedTo(
|
|
8248
|
+
ie(K, W, F, me).minus(_e).abs()
|
|
8249
|
+
) < 1 ? [Z, R] : [K, W], Ee = G, ue;
|
|
8250
|
+
}, Q.toNumber = function() {
|
|
8231
8251
|
return +be(this);
|
|
8232
|
-
},
|
|
8233
|
-
return D != null &&
|
|
8234
|
-
},
|
|
8252
|
+
}, Q.toPrecision = function(D, M) {
|
|
8253
|
+
return D != null && Y(D, 1, X), Pe(this, D, M, 2);
|
|
8254
|
+
}, Q.toString = function(D) {
|
|
8235
8255
|
var M, W = this, R = W.s, I = W.e;
|
|
8236
|
-
return I === null ? R ? (M = "Infinity", R < 0 && (M = "-" + M)) : M = "NaN" : (D == null ? M = I <=
|
|
8237
|
-
},
|
|
8256
|
+
return I === null ? R ? (M = "Infinity", R < 0 && (M = "-" + M)) : M = "NaN" : (D == null ? M = I <= Oe || I >= Ae ? re(ne(W.c), I) : ae(ne(W.c), I, "0") : D === 10 && Le ? (W = Ie(new fe(W), de + I + 1, me), M = ae(ne(W.c), W.e, "0")) : (Y(D, 2, he.length, "Base"), M = H(ae(ne(W.c), I, "0"), 10, D, R, !0)), R < 0 && W.c[0] && (M = "-" + M)), M;
|
|
8257
|
+
}, Q.valueOf = Q.toJSON = function() {
|
|
8238
8258
|
return be(this);
|
|
8239
|
-
},
|
|
8259
|
+
}, Q._isBigNumber = !0, te != null && fe.set(te), fe;
|
|
8240
8260
|
}
|
|
8241
|
-
function se(
|
|
8242
|
-
var ie =
|
|
8243
|
-
return
|
|
8261
|
+
function se(te) {
|
|
8262
|
+
var ie = te | 0;
|
|
8263
|
+
return te > 0 || te === ie ? ie : ie - 1;
|
|
8244
8264
|
}
|
|
8245
|
-
function
|
|
8246
|
-
for (var ie,
|
|
8247
|
-
for (ie =
|
|
8265
|
+
function ne(te) {
|
|
8266
|
+
for (var ie, H, $ = 1, Q = te.length, pe = te[0] + ""; $ < Q; ) {
|
|
8267
|
+
for (ie = te[$++] + "", H = B - ie.length; H--; ie = "0" + ie)
|
|
8248
8268
|
;
|
|
8249
8269
|
pe += ie;
|
|
8250
8270
|
}
|
|
8251
|
-
for (
|
|
8271
|
+
for (Q = pe.length; pe.charCodeAt(--Q) === 48; )
|
|
8252
8272
|
;
|
|
8253
|
-
return pe.slice(0,
|
|
8273
|
+
return pe.slice(0, Q + 1 || 1);
|
|
8254
8274
|
}
|
|
8255
|
-
function
|
|
8256
|
-
var
|
|
8257
|
-
if (!de || !
|
|
8275
|
+
function q(te, ie) {
|
|
8276
|
+
var H, $, Q = te.c, pe = ie.c, de = te.s, me = ie.s, Oe = te.e, Ae = ie.e;
|
|
8277
|
+
if (!de || !me)
|
|
8258
8278
|
return null;
|
|
8259
|
-
if (
|
|
8260
|
-
return
|
|
8261
|
-
if (de !=
|
|
8279
|
+
if (H = Q && !Q[0], $ = pe && !pe[0], H || $)
|
|
8280
|
+
return H ? $ ? 0 : -me : de;
|
|
8281
|
+
if (de != me)
|
|
8262
8282
|
return de;
|
|
8263
|
-
if (
|
|
8264
|
-
return $ ? 0 : !
|
|
8283
|
+
if (H = de < 0, $ = Oe == Ae, !Q || !pe)
|
|
8284
|
+
return $ ? 0 : !Q ^ H ? 1 : -1;
|
|
8265
8285
|
if (!$)
|
|
8266
|
-
return
|
|
8267
|
-
for (
|
|
8268
|
-
if (
|
|
8269
|
-
return
|
|
8270
|
-
return
|
|
8286
|
+
return Oe > Ae ^ H ? 1 : -1;
|
|
8287
|
+
for (me = (Oe = Q.length) < (Ae = pe.length) ? Oe : Ae, de = 0; de < me; de++)
|
|
8288
|
+
if (Q[de] != pe[de])
|
|
8289
|
+
return Q[de] > pe[de] ^ H ? 1 : -1;
|
|
8290
|
+
return Oe == Ae ? 0 : Oe > Ae ^ H ? 1 : -1;
|
|
8271
8291
|
}
|
|
8272
|
-
function
|
|
8273
|
-
if (
|
|
8274
|
-
throw Error(C + ($ || "Argument") + (typeof
|
|
8292
|
+
function Y(te, ie, H, $) {
|
|
8293
|
+
if (te < ie || te > H || te !== l(te))
|
|
8294
|
+
throw Error(C + ($ || "Argument") + (typeof te == "number" ? te < ie || te > H ? " out of range: " : " not an integer: " : " not a primitive number: ") + String(te));
|
|
8275
8295
|
}
|
|
8276
|
-
function
|
|
8277
|
-
var ie =
|
|
8278
|
-
return se(
|
|
8296
|
+
function oe(te) {
|
|
8297
|
+
var ie = te.c.length - 1;
|
|
8298
|
+
return se(te.e / B) == ie && te.c[ie] % 2 != 0;
|
|
8279
8299
|
}
|
|
8280
|
-
function te
|
|
8281
|
-
return (
|
|
8300
|
+
function re(te, ie) {
|
|
8301
|
+
return (te.length > 1 ? te.charAt(0) + "." + te.slice(1) : te) + (ie < 0 ? "e" : "e+") + ie;
|
|
8282
8302
|
}
|
|
8283
|
-
function
|
|
8284
|
-
var $,
|
|
8303
|
+
function ae(te, ie, H) {
|
|
8304
|
+
var $, Q;
|
|
8285
8305
|
if (ie < 0) {
|
|
8286
|
-
for (
|
|
8306
|
+
for (Q = H + "."; ++ie; Q += H)
|
|
8287
8307
|
;
|
|
8288
|
-
|
|
8289
|
-
} else if ($ =
|
|
8290
|
-
for (
|
|
8308
|
+
te = Q + te;
|
|
8309
|
+
} else if ($ = te.length, ++ie > $) {
|
|
8310
|
+
for (Q = H, ie -= $; --ie; Q += H)
|
|
8291
8311
|
;
|
|
8292
|
-
|
|
8312
|
+
te += Q;
|
|
8293
8313
|
} else
|
|
8294
|
-
ie < $ && (
|
|
8295
|
-
return
|
|
8314
|
+
ie < $ && (te = te.slice(0, ie) + "." + te.slice(ie));
|
|
8315
|
+
return te;
|
|
8296
8316
|
}
|
|
8297
8317
|
n = ce(), n.default = n.BigNumber = n, e.exports ? e.exports = n : (t || (t = typeof self < "u" && self ? self : window), t.BigNumber = n);
|
|
8298
8318
|
})(commonjsGlobal);
|
|
@@ -8311,58 +8331,58 @@ var bignumberExports = bignumber.exports;
|
|
|
8311
8331
|
'"': '\\"',
|
|
8312
8332
|
"\\": "\\\\"
|
|
8313
8333
|
}, A;
|
|
8314
|
-
function L(
|
|
8315
|
-
return s.lastIndex = 0, s.test(
|
|
8334
|
+
function L(J) {
|
|
8335
|
+
return s.lastIndex = 0, s.test(J) ? '"' + J.replace(s, function(U) {
|
|
8316
8336
|
var V = C[U];
|
|
8317
8337
|
return typeof V == "string" ? V : "\\u" + ("0000" + U.charCodeAt(0).toString(16)).slice(-4);
|
|
8318
|
-
}) + '"' : '"' +
|
|
8338
|
+
}) + '"' : '"' + J + '"';
|
|
8319
8339
|
}
|
|
8320
|
-
function B(
|
|
8321
|
-
var V,
|
|
8322
|
-
switch (
|
|
8340
|
+
function B(J, U) {
|
|
8341
|
+
var V, X, ce, se, ne = c, q, Y = U[J], oe = Y != null && (Y instanceof t || t.isBigNumber(Y));
|
|
8342
|
+
switch (Y && typeof Y == "object" && typeof Y.toJSON == "function" && (Y = Y.toJSON(J)), typeof A == "function" && (Y = A.call(U, J, Y)), typeof Y) {
|
|
8323
8343
|
case "string":
|
|
8324
|
-
return
|
|
8344
|
+
return oe ? Y : L(Y);
|
|
8325
8345
|
case "number":
|
|
8326
|
-
return isFinite(
|
|
8346
|
+
return isFinite(Y) ? String(Y) : "null";
|
|
8327
8347
|
case "boolean":
|
|
8328
8348
|
case "null":
|
|
8329
8349
|
case "bigint":
|
|
8330
|
-
return String(
|
|
8350
|
+
return String(Y);
|
|
8331
8351
|
case "object":
|
|
8332
|
-
if (!
|
|
8352
|
+
if (!Y)
|
|
8333
8353
|
return "null";
|
|
8334
|
-
if (c += l,
|
|
8335
|
-
for (se =
|
|
8336
|
-
|
|
8337
|
-
return ce =
|
|
8338
|
-
` + c +
|
|
8354
|
+
if (c += l, q = [], Object.prototype.toString.apply(Y) === "[object Array]") {
|
|
8355
|
+
for (se = Y.length, V = 0; V < se; V += 1)
|
|
8356
|
+
q[V] = B(V, Y) || "null";
|
|
8357
|
+
return ce = q.length === 0 ? "[]" : c ? `[
|
|
8358
|
+
` + c + q.join(`,
|
|
8339
8359
|
` + c) + `
|
|
8340
|
-
` +
|
|
8360
|
+
` + ne + "]" : "[" + q.join(",") + "]", c = ne, ce;
|
|
8341
8361
|
}
|
|
8342
8362
|
if (A && typeof A == "object")
|
|
8343
8363
|
for (se = A.length, V = 0; V < se; V += 1)
|
|
8344
|
-
typeof A[V] == "string" && (
|
|
8364
|
+
typeof A[V] == "string" && (X = A[V], ce = B(X, Y), ce && q.push(L(X) + (c ? ": " : ":") + ce));
|
|
8345
8365
|
else
|
|
8346
|
-
Object.keys(
|
|
8347
|
-
var
|
|
8348
|
-
|
|
8366
|
+
Object.keys(Y).forEach(function(re) {
|
|
8367
|
+
var ae = B(re, Y);
|
|
8368
|
+
ae && q.push(L(re) + (c ? ": " : ":") + ae);
|
|
8349
8369
|
});
|
|
8350
|
-
return ce =
|
|
8351
|
-
` + c +
|
|
8370
|
+
return ce = q.length === 0 ? "{}" : c ? `{
|
|
8371
|
+
` + c + q.join(`,
|
|
8352
8372
|
` + c) + `
|
|
8353
|
-
` +
|
|
8373
|
+
` + ne + "}" : "{" + q.join(",") + "}", c = ne, ce;
|
|
8354
8374
|
}
|
|
8355
8375
|
}
|
|
8356
|
-
typeof n.stringify != "function" && (n.stringify = function(
|
|
8357
|
-
var
|
|
8376
|
+
typeof n.stringify != "function" && (n.stringify = function(J, U, V) {
|
|
8377
|
+
var X;
|
|
8358
8378
|
if (c = "", l = "", typeof V == "number")
|
|
8359
|
-
for (
|
|
8379
|
+
for (X = 0; X < V; X += 1)
|
|
8360
8380
|
l += " ";
|
|
8361
8381
|
else
|
|
8362
8382
|
typeof V == "string" && (l = V);
|
|
8363
8383
|
if (A = U, U && typeof U != "function" && (typeof U != "object" || typeof U.length != "number"))
|
|
8364
8384
|
throw new Error("JSON.stringify");
|
|
8365
|
-
return B("", { "":
|
|
8385
|
+
return B("", { "": J });
|
|
8366
8386
|
});
|
|
8367
8387
|
})();
|
|
8368
8388
|
})(stringify);
|
|
@@ -8417,39 +8437,39 @@ var json_parse$1 = function(e) {
|
|
|
8417
8437
|
}, A = function(se) {
|
|
8418
8438
|
return se && se !== s && C("Expected '" + se + "' instead of '" + s + "'"), s = l.charAt(n), n += 1, s;
|
|
8419
8439
|
}, L = function() {
|
|
8420
|
-
var se,
|
|
8421
|
-
for (s === "-" && (
|
|
8422
|
-
|
|
8440
|
+
var se, ne = "";
|
|
8441
|
+
for (s === "-" && (ne = "-", A("-")); s >= "0" && s <= "9"; )
|
|
8442
|
+
ne += s, A();
|
|
8423
8443
|
if (s === ".")
|
|
8424
|
-
for (
|
|
8425
|
-
|
|
8444
|
+
for (ne += "."; A() && s >= "0" && s <= "9"; )
|
|
8445
|
+
ne += s;
|
|
8426
8446
|
if (s === "e" || s === "E")
|
|
8427
|
-
for (
|
|
8428
|
-
|
|
8429
|
-
if (se = +
|
|
8447
|
+
for (ne += s, A(), (s === "-" || s === "+") && (ne += s, A()); s >= "0" && s <= "9"; )
|
|
8448
|
+
ne += s, A();
|
|
8449
|
+
if (se = +ne, !isFinite(se))
|
|
8430
8450
|
C("Bad number");
|
|
8431
8451
|
else
|
|
8432
|
-
return BigNumber == null && (BigNumber = bignumberExports),
|
|
8452
|
+
return BigNumber == null && (BigNumber = bignumberExports), ne.length > 15 ? t.storeAsString ? ne : t.useNativeBigInt ? BigInt(ne) : new BigNumber(ne) : t.alwaysParseAsBig ? t.useNativeBigInt ? BigInt(se) : new BigNumber(se) : se;
|
|
8433
8453
|
}, B = function() {
|
|
8434
|
-
var se,
|
|
8454
|
+
var se, ne, q = "", Y;
|
|
8435
8455
|
if (s === '"')
|
|
8436
|
-
for (var
|
|
8456
|
+
for (var oe = n; A(); ) {
|
|
8437
8457
|
if (s === '"')
|
|
8438
|
-
return n - 1 >
|
|
8458
|
+
return n - 1 > oe && (q += l.substring(oe, n - 1)), A(), q;
|
|
8439
8459
|
if (s === "\\") {
|
|
8440
|
-
if (n - 1 >
|
|
8441
|
-
for (
|
|
8442
|
-
|
|
8443
|
-
|
|
8460
|
+
if (n - 1 > oe && (q += l.substring(oe, n - 1)), A(), s === "u") {
|
|
8461
|
+
for (Y = 0, ne = 0; ne < 4 && (se = parseInt(A(), 16), !!isFinite(se)); ne += 1)
|
|
8462
|
+
Y = Y * 16 + se;
|
|
8463
|
+
q += String.fromCharCode(Y);
|
|
8444
8464
|
} else if (typeof c[s] == "string")
|
|
8445
|
-
|
|
8465
|
+
q += c[s];
|
|
8446
8466
|
else
|
|
8447
8467
|
break;
|
|
8448
|
-
|
|
8468
|
+
oe = n;
|
|
8449
8469
|
}
|
|
8450
8470
|
}
|
|
8451
8471
|
C("Bad string");
|
|
8452
|
-
},
|
|
8472
|
+
}, J = function() {
|
|
8453
8473
|
for (; s && s <= " "; )
|
|
8454
8474
|
A();
|
|
8455
8475
|
}, U = function() {
|
|
@@ -8462,37 +8482,37 @@ var json_parse$1 = function(e) {
|
|
|
8462
8482
|
return A("n"), A("u"), A("l"), A("l"), null;
|
|
8463
8483
|
}
|
|
8464
8484
|
C("Unexpected '" + s + "'");
|
|
8465
|
-
}, V,
|
|
8485
|
+
}, V, X = function() {
|
|
8466
8486
|
var se = [];
|
|
8467
8487
|
if (s === "[") {
|
|
8468
|
-
if (A("["),
|
|
8488
|
+
if (A("["), J(), s === "]")
|
|
8469
8489
|
return A("]"), se;
|
|
8470
8490
|
for (; s; ) {
|
|
8471
|
-
if (se.push(V()),
|
|
8491
|
+
if (se.push(V()), J(), s === "]")
|
|
8472
8492
|
return A("]"), se;
|
|
8473
|
-
A(","),
|
|
8493
|
+
A(","), J();
|
|
8474
8494
|
}
|
|
8475
8495
|
}
|
|
8476
8496
|
C("Bad array");
|
|
8477
8497
|
}, ce = function() {
|
|
8478
|
-
var se,
|
|
8498
|
+
var se, ne = /* @__PURE__ */ Object.create(null);
|
|
8479
8499
|
if (s === "{") {
|
|
8480
|
-
if (A("{"),
|
|
8481
|
-
return A("}"),
|
|
8500
|
+
if (A("{"), J(), s === "}")
|
|
8501
|
+
return A("}"), ne;
|
|
8482
8502
|
for (; s; ) {
|
|
8483
|
-
if (se = B(),
|
|
8484
|
-
return A("}"),
|
|
8485
|
-
A(","),
|
|
8503
|
+
if (se = B(), J(), A(":"), t.strict === !0 && Object.hasOwnProperty.call(ne, se) && C('Duplicate key "' + se + '"'), suspectProtoRx.test(se) === !0 ? t.protoAction === "error" ? C("Object contains forbidden prototype property") : t.protoAction === "ignore" ? V() : ne[se] = V() : suspectConstructorRx.test(se) === !0 ? t.constructorAction === "error" ? C("Object contains forbidden constructor property") : t.constructorAction === "ignore" ? V() : ne[se] = V() : ne[se] = V(), J(), s === "}")
|
|
8504
|
+
return A("}"), ne;
|
|
8505
|
+
A(","), J();
|
|
8486
8506
|
}
|
|
8487
8507
|
}
|
|
8488
8508
|
C("Bad object");
|
|
8489
8509
|
};
|
|
8490
8510
|
return V = function() {
|
|
8491
|
-
switch (
|
|
8511
|
+
switch (J(), s) {
|
|
8492
8512
|
case "{":
|
|
8493
8513
|
return ce();
|
|
8494
8514
|
case "[":
|
|
8495
|
-
return
|
|
8515
|
+
return X();
|
|
8496
8516
|
case '"':
|
|
8497
8517
|
return B();
|
|
8498
8518
|
case "-":
|
|
@@ -8500,14 +8520,14 @@ var json_parse$1 = function(e) {
|
|
|
8500
8520
|
default:
|
|
8501
8521
|
return s >= "0" && s <= "9" ? L() : U();
|
|
8502
8522
|
}
|
|
8503
|
-
}, function(se,
|
|
8504
|
-
var
|
|
8505
|
-
return l = se + "", n = 0, s = " ",
|
|
8506
|
-
var
|
|
8507
|
-
return
|
|
8508
|
-
|
|
8509
|
-
}),
|
|
8510
|
-
}({ "":
|
|
8523
|
+
}, function(se, ne) {
|
|
8524
|
+
var q;
|
|
8525
|
+
return l = se + "", n = 0, s = " ", q = V(), J(), s && C("Syntax error"), typeof ne == "function" ? function Y(oe, re) {
|
|
8526
|
+
var ae, te = oe[re];
|
|
8527
|
+
return te && typeof te == "object" && Object.keys(te).forEach(function(ie) {
|
|
8528
|
+
ae = Y(te, ie), ae !== void 0 ? te[ie] = ae : delete te[ie];
|
|
8529
|
+
}), ne.call(oe, re, te);
|
|
8530
|
+
}({ "": q }, "") : q;
|
|
8511
8531
|
};
|
|
8512
8532
|
}, parse = json_parse$1, json_stringify = stringifyExports.stringify, json_parse = parse;
|
|
8513
8533
|
jsonBigint.exports = function(e) {
|
|
@@ -8603,30 +8623,30 @@ var hoconParser = { exports: {} };
|
|
|
8603
8623
|
var index = 0, result = readHocon(text);
|
|
8604
8624
|
return handleSubtitutions(result);
|
|
8605
8625
|
function readHocon(e) {
|
|
8606
|
-
for (var t = !1, n = "", s = !1, c = !1, l = !1, C = !1, A = !1, L = !1, B = !1,
|
|
8626
|
+
for (var t = !1, n = "", s = !1, c = !1, l = !1, C = !1, A = !1, L = !1, B = !1, J = !1, U = "", V = "", X = {}; index < e.length; ) {
|
|
8607
8627
|
var ce = e[index];
|
|
8608
|
-
if (index++, L && !
|
|
8628
|
+
if (index++, L && !J) {
|
|
8609
8629
|
(ce === "\r" || ce === `
|
|
8610
8630
|
`) && (L = !1);
|
|
8611
8631
|
continue;
|
|
8612
8632
|
}
|
|
8613
8633
|
if (!s && ce === '"' && index + 1 < e.length && e[index] === '"' && e[index + 1] === '"') {
|
|
8614
|
-
if (
|
|
8615
|
-
|
|
8634
|
+
if (J) {
|
|
8635
|
+
ne(), J = !1, t = !1, C = !1, index += 2;
|
|
8616
8636
|
continue;
|
|
8617
8637
|
}
|
|
8618
|
-
|
|
8638
|
+
J = !0, t = !0, C = !0, index += 2;
|
|
8619
8639
|
continue;
|
|
8620
8640
|
}
|
|
8621
|
-
if (!s && !
|
|
8641
|
+
if (!s && !J && (ce === "'" || ce === '"')) {
|
|
8622
8642
|
if (t && n === ce) {
|
|
8623
|
-
C ?
|
|
8643
|
+
C ? ne() : C = !0, t = !1;
|
|
8624
8644
|
continue;
|
|
8625
8645
|
}
|
|
8626
8646
|
t = !0, n = ce;
|
|
8627
8647
|
continue;
|
|
8628
8648
|
}
|
|
8629
|
-
if (
|
|
8649
|
+
if (J && se(ce)) {
|
|
8630
8650
|
V += ce;
|
|
8631
8651
|
continue;
|
|
8632
8652
|
}
|
|
@@ -8655,7 +8675,7 @@ var hoconParser = { exports: {} };
|
|
|
8655
8675
|
if (l && C) {
|
|
8656
8676
|
if (V === "")
|
|
8657
8677
|
continue;
|
|
8658
|
-
|
|
8678
|
+
ne();
|
|
8659
8679
|
continue;
|
|
8660
8680
|
}
|
|
8661
8681
|
if (!U)
|
|
@@ -8665,14 +8685,14 @@ var hoconParser = { exports: {} };
|
|
|
8665
8685
|
continue;
|
|
8666
8686
|
}
|
|
8667
8687
|
if (C && V) {
|
|
8668
|
-
|
|
8688
|
+
ne();
|
|
8669
8689
|
continue;
|
|
8670
8690
|
}
|
|
8671
8691
|
continue;
|
|
8672
8692
|
}
|
|
8673
8693
|
case "{": {
|
|
8674
8694
|
if (c || l || U) {
|
|
8675
|
-
index--, U = U.trim(), V = readHocon(e),
|
|
8695
|
+
index--, U = U.trim(), V = readHocon(e), ne();
|
|
8676
8696
|
continue;
|
|
8677
8697
|
}
|
|
8678
8698
|
c = !0;
|
|
@@ -8682,10 +8702,10 @@ var hoconParser = { exports: {} };
|
|
|
8682
8702
|
if (!c)
|
|
8683
8703
|
throw "What";
|
|
8684
8704
|
if (V)
|
|
8685
|
-
|
|
8705
|
+
ne();
|
|
8686
8706
|
else if (U)
|
|
8687
8707
|
return U;
|
|
8688
|
-
return
|
|
8708
|
+
return X;
|
|
8689
8709
|
}
|
|
8690
8710
|
case ":":
|
|
8691
8711
|
case "=": {
|
|
@@ -8695,25 +8715,25 @@ var hoconParser = { exports: {} };
|
|
|
8695
8715
|
continue;
|
|
8696
8716
|
}
|
|
8697
8717
|
case ",": {
|
|
8698
|
-
C && V &&
|
|
8718
|
+
C && V && ne();
|
|
8699
8719
|
continue;
|
|
8700
8720
|
}
|
|
8701
8721
|
case "[": {
|
|
8702
8722
|
if (c || l || U) {
|
|
8703
|
-
index--, V = readHocon(e),
|
|
8723
|
+
index--, V = readHocon(e), ne();
|
|
8704
8724
|
continue;
|
|
8705
8725
|
}
|
|
8706
|
-
C = !0, l = !0,
|
|
8726
|
+
C = !0, l = !0, X = [];
|
|
8707
8727
|
continue;
|
|
8708
8728
|
}
|
|
8709
8729
|
case "]": {
|
|
8710
8730
|
if (!l)
|
|
8711
8731
|
throw "not in an array";
|
|
8712
|
-
return V && (V = V.trim(),
|
|
8732
|
+
return V && (V = V.trim(), ne()), X;
|
|
8713
8733
|
}
|
|
8714
8734
|
case "$": {
|
|
8715
8735
|
if (!V) {
|
|
8716
|
-
V = "${" + readHocon(e) + "}",
|
|
8736
|
+
V = "${" + readHocon(e) + "}", ne();
|
|
8717
8737
|
continue;
|
|
8718
8738
|
}
|
|
8719
8739
|
break;
|
|
@@ -8737,18 +8757,18 @@ var hoconParser = { exports: {} };
|
|
|
8737
8757
|
throw "Expected closing curly bracket";
|
|
8738
8758
|
if (l)
|
|
8739
8759
|
throw "Expected closing square bracket";
|
|
8740
|
-
return C &&
|
|
8741
|
-
function se(
|
|
8742
|
-
return ['"', "\\"].indexOf(
|
|
8760
|
+
return C && ne(), X;
|
|
8761
|
+
function se(q) {
|
|
8762
|
+
return ['"', "\\"].indexOf(q) !== -1;
|
|
8743
8763
|
}
|
|
8744
|
-
function
|
|
8745
|
-
var
|
|
8746
|
-
if (!l &&
|
|
8747
|
-
var
|
|
8748
|
-
te
|
|
8764
|
+
function ne(oe, re) {
|
|
8765
|
+
var oe = oe || U, re = re || X, ae = oe.indexOf(".");
|
|
8766
|
+
if (!l && ae > 0) {
|
|
8767
|
+
var te = oe.substring(0, ae);
|
|
8768
|
+
re[te] = re[te] || {}, ne(oe.substring(ae + 1), re[te]);
|
|
8749
8769
|
return;
|
|
8750
8770
|
}
|
|
8751
|
-
!t && typeof V == "string" && (/^\d+$/.test(V) ? V = parseInt(V) : /^\d+\.\d+$/.test(V) ? V = parseFloat(V) : V === "true" ? V = !0 : V === "false" ? V = !1 : V === "null" && (V = null)), l ?
|
|
8771
|
+
!t && typeof V == "string" && (/^\d+$/.test(V) ? V = parseInt(V) : /^\d+\.\d+$/.test(V) ? V = parseFloat(V) : V === "true" ? V = !0 : V === "false" ? V = !1 : V === "null" && (V = null)), l ? re.push(V) : (typeof re[oe] == "object" && typeof V == "object" ? extend(re[oe], V) : re[oe] = V, C = !1), A = !1, U = "", V = "";
|
|
8752
8772
|
}
|
|
8753
8773
|
}
|
|
8754
8774
|
function handleSubtitutions(mainObj, intermidiateObj, loops) {
|
|
@@ -8787,7 +8807,7 @@ const parseHoconToObject = /* @__PURE__ */ getDefaultExportFromCjs(hoconParserEx
|
|
|
8787
8807
|
if (isEmptyObj(e))
|
|
8788
8808
|
return "{}";
|
|
8789
8809
|
const n = " ".repeat(t), s = " ".repeat(t + 1), c = (A, L) => typeof A == "string" ? `"${A.replace(/\\/g, "\\\\").replace(/"/g, '\\"').replace(/\n/g, "\\n")}"` : A == null ? "null" : Array.isArray(A) ? A.length === 0 ? "[]" : `[
|
|
8790
|
-
${A.map((
|
|
8810
|
+
${A.map((J) => `${" ".repeat(L + 1)}${c(J, L + 1)}`).join(`,
|
|
8791
8811
|
`)}
|
|
8792
8812
|
${" ".repeat(L)}]` : typeof A == "object" ? objectToHocon(A, L) : String(A);
|
|
8793
8813
|
return `{
|