mtranserver 4.0.20 → 4.0.21
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/core/engine.d.ts +2 -0
- package/dist/core/engine.d.ts.map +1 -1
- package/dist/icon-tjp1feba.png +0 -0
- package/dist/index-B7vzjIqN-ma6ncj8z.css +1 -0
- package/dist/index-D6lVFqDO-3a1nn40g.js +53 -0
- package/dist/{index-wzc7qnpt.html → index-g3cdpfvc.html} +2 -2
- package/dist/index.js +41 -63
- package/dist/index.js.map +4 -4
- package/dist/main.js +79 -101
- package/dist/main.js.map +8 -8
- package/package.json +3 -3
- package/dist/icon-2r5te9sp.png +0 -0
- package/dist/index-B5MwS93W-8btbkjwj.css +0 -1
- package/dist/index-CViVzJTS-xrkq8wea.js +0 -53
package/dist/main.js
CHANGED
|
@@ -46,7 +46,7 @@ var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
|
46
46
|
|
|
47
47
|
// node_modules/swagger-ui-dist/absolute-path.js
|
|
48
48
|
var require_absolute_path = __commonJS((exports, module) => {
|
|
49
|
-
var __dirname = "/
|
|
49
|
+
var __dirname = "/home/xxnuo/projects/MTran/MTranServer/node_modules/swagger-ui-dist";
|
|
50
50
|
var getAbsoluteFSPath = function() {
|
|
51
51
|
if (typeof module !== "undefined" && module.exports) {
|
|
52
52
|
return __require("path").resolve(__dirname);
|
|
@@ -1618,7 +1618,8 @@ class TranslationEngine {
|
|
|
1618
1618
|
if (options.html) {
|
|
1619
1619
|
processedText = this._sanitizeHTML(text);
|
|
1620
1620
|
}
|
|
1621
|
-
const { cleanText, replacements } = this.
|
|
1621
|
+
const { cleanText: placeholderText, replacements: placeholderReplacements } = this._hidePlaceholders(processedText, options);
|
|
1622
|
+
const { cleanText, replacements } = this._hideEmojis(placeholderText);
|
|
1622
1623
|
let translation;
|
|
1623
1624
|
try {
|
|
1624
1625
|
if (cleanText.length > this.maxLengthBreak) {
|
|
@@ -1634,6 +1635,7 @@ class TranslationEngine {
|
|
|
1634
1635
|
throw error2;
|
|
1635
1636
|
}
|
|
1636
1637
|
translation = this._restoreEmojis(translation, replacements);
|
|
1638
|
+
translation = this._restorePlaceholders(translation, placeholderReplacements);
|
|
1637
1639
|
return translation;
|
|
1638
1640
|
}
|
|
1639
1641
|
_sanitizeHTML(text) {
|
|
@@ -1790,6 +1792,30 @@ class TranslationEngine {
|
|
|
1790
1792
|
}
|
|
1791
1793
|
return result;
|
|
1792
1794
|
}
|
|
1795
|
+
_hidePlaceholders(text, options = {}) {
|
|
1796
|
+
const replacements = [];
|
|
1797
|
+
const used = new Set;
|
|
1798
|
+
const placeholderRegex = /(\{\d+\}|\[\d+\])/g;
|
|
1799
|
+
const cleanText = text.replace(placeholderRegex, (match) => {
|
|
1800
|
+
let placeholder = `__MTRAN_PH_${replacements.length}__`;
|
|
1801
|
+
let salt = 0;
|
|
1802
|
+
while (text.includes(placeholder) || used.has(placeholder)) {
|
|
1803
|
+
salt += 1;
|
|
1804
|
+
placeholder = `__MTRAN_PH_${replacements.length}_${salt}__`;
|
|
1805
|
+
}
|
|
1806
|
+
used.add(placeholder);
|
|
1807
|
+
replacements.push({ original: match, placeholder });
|
|
1808
|
+
return placeholder;
|
|
1809
|
+
});
|
|
1810
|
+
return { cleanText, replacements };
|
|
1811
|
+
}
|
|
1812
|
+
_restorePlaceholders(text, replacements) {
|
|
1813
|
+
let result = text;
|
|
1814
|
+
for (const { original, placeholder } of replacements) {
|
|
1815
|
+
result = result.split(placeholder).join(original);
|
|
1816
|
+
}
|
|
1817
|
+
return result;
|
|
1818
|
+
}
|
|
1793
1819
|
destroy() {
|
|
1794
1820
|
try {
|
|
1795
1821
|
if (this.model) {
|
|
@@ -4706,7 +4732,7 @@ var init_bergamot_translator = () => {};
|
|
|
4706
4732
|
|
|
4707
4733
|
// src/lib/cld2/cld2.js
|
|
4708
4734
|
var require_cld2 = __commonJS((exports, module) => {
|
|
4709
|
-
var __dirname = "/
|
|
4735
|
+
var __dirname = "/home/xxnuo/projects/MTran/MTranServer/src/lib/cld2", __filename = "/home/xxnuo/projects/MTran/MTranServer/src/lib/cld2/cld2.js";
|
|
4710
4736
|
var loadCLD2 = (() => {
|
|
4711
4737
|
var _scriptName = globalThis.document?.currentScript?.src;
|
|
4712
4738
|
return async function(moduleArg = {}) {
|
|
@@ -6171,11 +6197,11 @@ class Stack {
|
|
|
6171
6197
|
return this.heap[--this.length];
|
|
6172
6198
|
}
|
|
6173
6199
|
}
|
|
6174
|
-
var
|
|
6200
|
+
var perf, warned, PROCESS, emitWarning = (msg, type, code, fn) => {
|
|
6175
6201
|
typeof PROCESS.emitWarning === "function" ? PROCESS.emitWarning(msg, type, code, fn) : console.error(`[${code}] ${type}: ${msg}`);
|
|
6176
6202
|
}, AC, AS, shouldWarn = (code) => !warned.has(code), TYPE, isPosInt = (n) => n && n === Math.floor(n) && n > 0 && isFinite(n), getUintArray = (max) => !isPosInt(max) ? null : max <= Math.pow(2, 8) ? Uint8Array : max <= Math.pow(2, 16) ? Uint16Array : max <= Math.pow(2, 32) ? Uint32Array : max <= Number.MAX_SAFE_INTEGER ? ZeroArray : null, ZeroArray, LRUCache;
|
|
6177
6203
|
var init_esm2 = __esm(() => {
|
|
6178
|
-
|
|
6204
|
+
perf = typeof performance === "object" && performance && typeof performance.now === "function" ? performance : Date;
|
|
6179
6205
|
warned = new Set;
|
|
6180
6206
|
PROCESS = typeof process === "object" && !!process ? process : {};
|
|
6181
6207
|
AC = globalThis.AbortController;
|
|
@@ -6225,14 +6251,9 @@ var init_esm2 = __esm(() => {
|
|
|
6225
6251
|
#max;
|
|
6226
6252
|
#maxSize;
|
|
6227
6253
|
#dispose;
|
|
6228
|
-
#onInsert;
|
|
6229
6254
|
#disposeAfter;
|
|
6230
6255
|
#fetchMethod;
|
|
6231
6256
|
#memoMethod;
|
|
6232
|
-
#perf;
|
|
6233
|
-
get perf() {
|
|
6234
|
-
return this.#perf;
|
|
6235
|
-
}
|
|
6236
6257
|
ttl;
|
|
6237
6258
|
ttlResolution;
|
|
6238
6259
|
ttlAutopurge;
|
|
@@ -6262,16 +6283,13 @@ var init_esm2 = __esm(() => {
|
|
|
6262
6283
|
#sizes;
|
|
6263
6284
|
#starts;
|
|
6264
6285
|
#ttls;
|
|
6265
|
-
#autopurgeTimers;
|
|
6266
6286
|
#hasDispose;
|
|
6267
6287
|
#hasFetchMethod;
|
|
6268
6288
|
#hasDisposeAfter;
|
|
6269
|
-
#hasOnInsert;
|
|
6270
6289
|
static unsafeExposeInternals(c) {
|
|
6271
6290
|
return {
|
|
6272
6291
|
starts: c.#starts,
|
|
6273
6292
|
ttls: c.#ttls,
|
|
6274
|
-
autopurgeTimers: c.#autopurgeTimers,
|
|
6275
6293
|
sizes: c.#sizes,
|
|
6276
6294
|
keyMap: c.#keyMap,
|
|
6277
6295
|
keyList: c.#keyList,
|
|
@@ -6314,20 +6332,11 @@ var init_esm2 = __esm(() => {
|
|
|
6314
6332
|
get dispose() {
|
|
6315
6333
|
return this.#dispose;
|
|
6316
6334
|
}
|
|
6317
|
-
get onInsert() {
|
|
6318
|
-
return this.#onInsert;
|
|
6319
|
-
}
|
|
6320
6335
|
get disposeAfter() {
|
|
6321
6336
|
return this.#disposeAfter;
|
|
6322
6337
|
}
|
|
6323
6338
|
constructor(options) {
|
|
6324
|
-
const { max = 0, ttl, ttlResolution = 1, ttlAutopurge, updateAgeOnGet, updateAgeOnHas, allowStale, dispose,
|
|
6325
|
-
if (perf !== undefined) {
|
|
6326
|
-
if (typeof perf?.now !== "function") {
|
|
6327
|
-
throw new TypeError("perf option must have a now() method if specified");
|
|
6328
|
-
}
|
|
6329
|
-
}
|
|
6330
|
-
this.#perf = perf ?? defaultPerf;
|
|
6339
|
+
const { max = 0, ttl, ttlResolution = 1, ttlAutopurge, updateAgeOnGet, updateAgeOnHas, allowStale, dispose, disposeAfter, noDisposeOnSet, noUpdateTTL, maxSize = 0, maxEntrySize = 0, sizeCalculation, fetchMethod, memoMethod, noDeleteOnFetchRejection, noDeleteOnStaleGet, allowStaleOnFetchRejection, allowStaleOnFetchAbort, ignoreFetchAbort } = options;
|
|
6331
6340
|
if (max !== 0 && !isPosInt(max)) {
|
|
6332
6341
|
throw new TypeError("max option must be a nonnegative integer");
|
|
6333
6342
|
}
|
|
@@ -6369,9 +6378,6 @@ var init_esm2 = __esm(() => {
|
|
|
6369
6378
|
if (typeof dispose === "function") {
|
|
6370
6379
|
this.#dispose = dispose;
|
|
6371
6380
|
}
|
|
6372
|
-
if (typeof onInsert === "function") {
|
|
6373
|
-
this.#onInsert = onInsert;
|
|
6374
|
-
}
|
|
6375
6381
|
if (typeof disposeAfter === "function") {
|
|
6376
6382
|
this.#disposeAfter = disposeAfter;
|
|
6377
6383
|
this.#disposed = [];
|
|
@@ -6380,7 +6386,6 @@ var init_esm2 = __esm(() => {
|
|
|
6380
6386
|
this.#disposed = undefined;
|
|
6381
6387
|
}
|
|
6382
6388
|
this.#hasDispose = !!this.#dispose;
|
|
6383
|
-
this.#hasOnInsert = !!this.#onInsert;
|
|
6384
6389
|
this.#hasDisposeAfter = !!this.#disposeAfter;
|
|
6385
6390
|
this.noDisposeOnSet = !!noDisposeOnSet;
|
|
6386
6391
|
this.noUpdateTTL = !!noUpdateTTL;
|
|
@@ -6432,16 +6437,10 @@ var init_esm2 = __esm(() => {
|
|
|
6432
6437
|
const starts = new ZeroArray(this.#max);
|
|
6433
6438
|
this.#ttls = ttls;
|
|
6434
6439
|
this.#starts = starts;
|
|
6435
|
-
|
|
6436
|
-
this.#autopurgeTimers = purgeTimers;
|
|
6437
|
-
this.#setItemTTL = (index, ttl, start = this.#perf.now()) => {
|
|
6440
|
+
this.#setItemTTL = (index, ttl, start = perf.now()) => {
|
|
6438
6441
|
starts[index] = ttl !== 0 ? start : 0;
|
|
6439
6442
|
ttls[index] = ttl;
|
|
6440
|
-
if (
|
|
6441
|
-
clearTimeout(purgeTimers[index]);
|
|
6442
|
-
purgeTimers[index] = undefined;
|
|
6443
|
-
}
|
|
6444
|
-
if (ttl !== 0 && purgeTimers) {
|
|
6443
|
+
if (ttl !== 0 && this.ttlAutopurge) {
|
|
6445
6444
|
const t = setTimeout(() => {
|
|
6446
6445
|
if (this.#isStale(index)) {
|
|
6447
6446
|
this.#delete(this.#keyList[index], "expire");
|
|
@@ -6450,11 +6449,10 @@ var init_esm2 = __esm(() => {
|
|
|
6450
6449
|
if (t.unref) {
|
|
6451
6450
|
t.unref();
|
|
6452
6451
|
}
|
|
6453
|
-
purgeTimers[index] = t;
|
|
6454
6452
|
}
|
|
6455
6453
|
};
|
|
6456
6454
|
this.#updateItemAge = (index) => {
|
|
6457
|
-
starts[index] = ttls[index] !== 0 ?
|
|
6455
|
+
starts[index] = ttls[index] !== 0 ? perf.now() : 0;
|
|
6458
6456
|
};
|
|
6459
6457
|
this.#statusTTL = (status, index) => {
|
|
6460
6458
|
if (ttls[index]) {
|
|
@@ -6471,7 +6469,7 @@ var init_esm2 = __esm(() => {
|
|
|
6471
6469
|
};
|
|
6472
6470
|
let cachedNow = 0;
|
|
6473
6471
|
const getNow = () => {
|
|
6474
|
-
const n =
|
|
6472
|
+
const n = perf.now();
|
|
6475
6473
|
if (this.ttlResolution > 0) {
|
|
6476
6474
|
cachedNow = n;
|
|
6477
6475
|
const t = setTimeout(() => cachedNow = 0, this.ttlResolution);
|
|
@@ -6693,7 +6691,7 @@ var init_esm2 = __esm(() => {
|
|
|
6693
6691
|
const ttl = this.#ttls[i];
|
|
6694
6692
|
const start = this.#starts[i];
|
|
6695
6693
|
if (ttl && start) {
|
|
6696
|
-
const remain = ttl - (
|
|
6694
|
+
const remain = ttl - (perf.now() - start);
|
|
6697
6695
|
entry.ttl = remain;
|
|
6698
6696
|
entry.start = Date.now();
|
|
6699
6697
|
}
|
|
@@ -6714,7 +6712,7 @@ var init_esm2 = __esm(() => {
|
|
|
6714
6712
|
const entry = { value };
|
|
6715
6713
|
if (this.#ttls && this.#starts) {
|
|
6716
6714
|
entry.ttl = this.#ttls[i];
|
|
6717
|
-
const age =
|
|
6715
|
+
const age = perf.now() - this.#starts[i];
|
|
6718
6716
|
entry.start = Math.floor(Date.now() - age);
|
|
6719
6717
|
}
|
|
6720
6718
|
if (this.#sizes) {
|
|
@@ -6729,7 +6727,7 @@ var init_esm2 = __esm(() => {
|
|
|
6729
6727
|
for (const [key, entry] of arr) {
|
|
6730
6728
|
if (entry.start) {
|
|
6731
6729
|
const age = Date.now() - entry.start;
|
|
6732
|
-
entry.start =
|
|
6730
|
+
entry.start = perf.now() - age;
|
|
6733
6731
|
}
|
|
6734
6732
|
this.set(key, entry.value, entry);
|
|
6735
6733
|
}
|
|
@@ -6764,9 +6762,6 @@ var init_esm2 = __esm(() => {
|
|
|
6764
6762
|
if (status)
|
|
6765
6763
|
status.set = "add";
|
|
6766
6764
|
noUpdateTTL = false;
|
|
6767
|
-
if (this.#hasOnInsert) {
|
|
6768
|
-
this.#onInsert?.(v, k, "add");
|
|
6769
|
-
}
|
|
6770
6765
|
} else {
|
|
6771
6766
|
this.#moveToTail(index);
|
|
6772
6767
|
const oldVal = this.#valList[index];
|
|
@@ -6802,9 +6797,6 @@ var init_esm2 = __esm(() => {
|
|
|
6802
6797
|
} else if (status) {
|
|
6803
6798
|
status.set = "update";
|
|
6804
6799
|
}
|
|
6805
|
-
if (this.#hasOnInsert) {
|
|
6806
|
-
this.onInsert?.(v, k, v === oldVal ? "update" : "replace");
|
|
6807
|
-
}
|
|
6808
6800
|
}
|
|
6809
6801
|
if (ttl !== 0 && !this.#ttls) {
|
|
6810
6802
|
this.#initializeTTLTracking();
|
|
@@ -6863,10 +6855,6 @@ var init_esm2 = __esm(() => {
|
|
|
6863
6855
|
}
|
|
6864
6856
|
}
|
|
6865
6857
|
this.#removeItemSize(head);
|
|
6866
|
-
if (this.#autopurgeTimers?.[head]) {
|
|
6867
|
-
clearTimeout(this.#autopurgeTimers[head]);
|
|
6868
|
-
this.#autopurgeTimers[head] = undefined;
|
|
6869
|
-
}
|
|
6870
6858
|
if (free) {
|
|
6871
6859
|
this.#keyList[head] = undefined;
|
|
6872
6860
|
this.#valList[head] = undefined;
|
|
@@ -6949,10 +6937,9 @@ var init_esm2 = __esm(() => {
|
|
|
6949
6937
|
return fetchFail(ac.signal.reason);
|
|
6950
6938
|
}
|
|
6951
6939
|
const bf2 = p;
|
|
6952
|
-
|
|
6953
|
-
if (vl === p || ignoreAbort && updateCache && vl === undefined) {
|
|
6940
|
+
if (this.#valList[index] === p) {
|
|
6954
6941
|
if (v2 === undefined) {
|
|
6955
|
-
if (bf2.__staleWhileFetching
|
|
6942
|
+
if (bf2.__staleWhileFetching) {
|
|
6956
6943
|
this.#valList[index] = bf2.__staleWhileFetching;
|
|
6957
6944
|
} else {
|
|
6958
6945
|
this.#delete(k, "fetch");
|
|
@@ -7201,10 +7188,6 @@ var init_esm2 = __esm(() => {
|
|
|
7201
7188
|
if (this.#size !== 0) {
|
|
7202
7189
|
const index = this.#keyMap.get(k);
|
|
7203
7190
|
if (index !== undefined) {
|
|
7204
|
-
if (this.#autopurgeTimers?.[index]) {
|
|
7205
|
-
clearTimeout(this.#autopurgeTimers?.[index]);
|
|
7206
|
-
this.#autopurgeTimers[index] = undefined;
|
|
7207
|
-
}
|
|
7208
7191
|
deleted = true;
|
|
7209
7192
|
if (this.#size === 1) {
|
|
7210
7193
|
this.#clear(reason);
|
|
@@ -7272,11 +7255,6 @@ var init_esm2 = __esm(() => {
|
|
|
7272
7255
|
if (this.#ttls && this.#starts) {
|
|
7273
7256
|
this.#ttls.fill(0);
|
|
7274
7257
|
this.#starts.fill(0);
|
|
7275
|
-
for (const t of this.#autopurgeTimers ?? []) {
|
|
7276
|
-
if (t !== undefined)
|
|
7277
|
-
clearTimeout(t);
|
|
7278
|
-
}
|
|
7279
|
-
this.#autopurgeTimers?.fill(undefined);
|
|
7280
7258
|
}
|
|
7281
7259
|
if (this.#sizes) {
|
|
7282
7260
|
this.#sizes.fill(0);
|
|
@@ -24959,7 +24937,7 @@ globstar while`, file, fr, pattern, pr, swallowee);
|
|
|
24959
24937
|
|
|
24960
24938
|
// node_modules/typescript/lib/typescript.js
|
|
24961
24939
|
var require_typescript = __commonJS((exports, module) => {
|
|
24962
|
-
var __dirname = "/
|
|
24940
|
+
var __dirname = "/home/xxnuo/projects/MTran/MTranServer/node_modules/typescript/lib", __filename = "/home/xxnuo/projects/MTran/MTranServer/node_modules/typescript/lib/typescript.js";
|
|
24963
24941
|
/*! *****************************************************************************
|
|
24964
24942
|
Copyright (c) Microsoft Corporation. All rights reserved.
|
|
24965
24943
|
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|
@@ -193968,11 +193946,11 @@ var require_decoratorUtils = __commonJS((exports) => {
|
|
|
193968
193946
|
}
|
|
193969
193947
|
});
|
|
193970
193948
|
|
|
193971
|
-
// node_modules/
|
|
193949
|
+
// node_modules/lru-cache/dist/commonjs/index.js
|
|
193972
193950
|
var require_commonjs2 = __commonJS((exports) => {
|
|
193973
193951
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
193974
193952
|
exports.LRUCache = undefined;
|
|
193975
|
-
var
|
|
193953
|
+
var perf2 = typeof performance === "object" && performance && typeof performance.now === "function" ? performance : Date;
|
|
193976
193954
|
var warned2 = new Set;
|
|
193977
193955
|
var PROCESS2 = typeof process === "object" && !!process ? process : {};
|
|
193978
193956
|
var emitWarning2 = (msg, type, code, fn) => {
|
|
@@ -194244,7 +194222,7 @@ var require_commonjs2 = __commonJS((exports) => {
|
|
|
194244
194222
|
const starts = new ZeroArray2(this.#max);
|
|
194245
194223
|
this.#ttls = ttls;
|
|
194246
194224
|
this.#starts = starts;
|
|
194247
|
-
this.#setItemTTL = (index, ttl, start =
|
|
194225
|
+
this.#setItemTTL = (index, ttl, start = perf2.now()) => {
|
|
194248
194226
|
starts[index] = ttl !== 0 ? start : 0;
|
|
194249
194227
|
ttls[index] = ttl;
|
|
194250
194228
|
if (ttl !== 0 && this.ttlAutopurge) {
|
|
@@ -194259,7 +194237,7 @@ var require_commonjs2 = __commonJS((exports) => {
|
|
|
194259
194237
|
}
|
|
194260
194238
|
};
|
|
194261
194239
|
this.#updateItemAge = (index) => {
|
|
194262
|
-
starts[index] = ttls[index] !== 0 ?
|
|
194240
|
+
starts[index] = ttls[index] !== 0 ? perf2.now() : 0;
|
|
194263
194241
|
};
|
|
194264
194242
|
this.#statusTTL = (status, index) => {
|
|
194265
194243
|
if (ttls[index]) {
|
|
@@ -194276,7 +194254,7 @@ var require_commonjs2 = __commonJS((exports) => {
|
|
|
194276
194254
|
};
|
|
194277
194255
|
let cachedNow = 0;
|
|
194278
194256
|
const getNow = () => {
|
|
194279
|
-
const n =
|
|
194257
|
+
const n = perf2.now();
|
|
194280
194258
|
if (this.ttlResolution > 0) {
|
|
194281
194259
|
cachedNow = n;
|
|
194282
194260
|
const t = setTimeout(() => cachedNow = 0, this.ttlResolution);
|
|
@@ -194498,7 +194476,7 @@ var require_commonjs2 = __commonJS((exports) => {
|
|
|
194498
194476
|
const ttl = this.#ttls[i];
|
|
194499
194477
|
const start = this.#starts[i];
|
|
194500
194478
|
if (ttl && start) {
|
|
194501
|
-
const remain = ttl - (
|
|
194479
|
+
const remain = ttl - (perf2.now() - start);
|
|
194502
194480
|
entry.ttl = remain;
|
|
194503
194481
|
entry.start = Date.now();
|
|
194504
194482
|
}
|
|
@@ -194519,7 +194497,7 @@ var require_commonjs2 = __commonJS((exports) => {
|
|
|
194519
194497
|
const entry = { value };
|
|
194520
194498
|
if (this.#ttls && this.#starts) {
|
|
194521
194499
|
entry.ttl = this.#ttls[i];
|
|
194522
|
-
const age =
|
|
194500
|
+
const age = perf2.now() - this.#starts[i];
|
|
194523
194501
|
entry.start = Math.floor(Date.now() - age);
|
|
194524
194502
|
}
|
|
194525
194503
|
if (this.#sizes) {
|
|
@@ -194534,7 +194512,7 @@ var require_commonjs2 = __commonJS((exports) => {
|
|
|
194534
194512
|
for (const [key, entry] of arr) {
|
|
194535
194513
|
if (entry.start) {
|
|
194536
194514
|
const age = Date.now() - entry.start;
|
|
194537
|
-
entry.start =
|
|
194515
|
+
entry.start = perf2.now() - age;
|
|
194538
194516
|
}
|
|
194539
194517
|
this.set(key, entry.value, entry);
|
|
194540
194518
|
}
|
|
@@ -209037,7 +209015,7 @@ var require_routeGenerator = __commonJS((exports) => {
|
|
|
209037
209015
|
|
|
209038
209016
|
// node_modules/@tsoa/cli/dist/routeGeneration/defaultRouteGenerator.js
|
|
209039
209017
|
var require_defaultRouteGenerator = __commonJS((exports) => {
|
|
209040
|
-
var __dirname = "/
|
|
209018
|
+
var __dirname = "/home/xxnuo/projects/MTran/MTranServer/node_modules/@tsoa/cli/dist/routeGeneration";
|
|
209041
209019
|
var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) {
|
|
209042
209020
|
if (k2 === undefined)
|
|
209043
209021
|
k2 = k;
|
|
@@ -209163,7 +209141,7 @@ var require_defaultRouteGenerator = __commonJS((exports) => {
|
|
|
209163
209141
|
|
|
209164
209142
|
// node_modules/@tsoa/cli/dist/module/generate-routes.js
|
|
209165
209143
|
var require_generate_routes = __commonJS((exports) => {
|
|
209166
|
-
var __dirname = "/
|
|
209144
|
+
var __dirname = "/home/xxnuo/projects/MTran/MTranServer/node_modules/@tsoa/cli/dist/module";
|
|
209167
209145
|
var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) {
|
|
209168
209146
|
if (k2 === undefined)
|
|
209169
209147
|
k2 = k;
|
|
@@ -212092,7 +212070,7 @@ var require_require_directory = __commonJS((exports, module) => {
|
|
|
212092
212070
|
|
|
212093
212071
|
// node_modules/yargs/build/index.cjs
|
|
212094
212072
|
var require_build4 = __commonJS((exports, module) => {
|
|
212095
|
-
var __dirname = "/
|
|
212073
|
+
var __dirname = "/home/xxnuo/projects/MTran/MTranServer/node_modules/yargs/build";
|
|
212096
212074
|
var t = __require("assert");
|
|
212097
212075
|
|
|
212098
212076
|
class e extends Error {
|
|
@@ -214427,7 +214405,7 @@ __export(exports_version, {
|
|
|
214427
214405
|
function getVersion() {
|
|
214428
214406
|
return VERSION;
|
|
214429
214407
|
}
|
|
214430
|
-
var VERSION = "4.0.
|
|
214408
|
+
var VERSION = "4.0.21";
|
|
214431
214409
|
|
|
214432
214410
|
// src/server/index.ts
|
|
214433
214411
|
init_config();
|
|
@@ -216064,7 +216042,7 @@ var swagger_default = {
|
|
|
216064
216042
|
},
|
|
216065
216043
|
info: {
|
|
216066
216044
|
title: "MTranServer API",
|
|
216067
|
-
version: "4.0.
|
|
216045
|
+
version: "4.0.21",
|
|
216068
216046
|
description: "Translation server API",
|
|
216069
216047
|
license: {
|
|
216070
216048
|
name: "Apache-2.0"
|
|
@@ -216541,23 +216519,23 @@ import { dirname, resolve, isAbsolute } from "path";
|
|
|
216541
216519
|
import { fileURLToPath as fileURLToPath3 } from "url";
|
|
216542
216520
|
|
|
216543
216521
|
// ui/dist/icon.png
|
|
216544
|
-
var icon_default = "./icon-
|
|
216522
|
+
var icon_default = "./icon-tjp1feba.png";
|
|
216545
216523
|
|
|
216546
|
-
// ui/dist/index.
|
|
216547
|
-
var
|
|
216524
|
+
// ui/dist/assets/index-B7vzjIqN.css
|
|
216525
|
+
var index_B7vzjIqN_default = "./index-B7vzjIqN-ma6ncj8z.css";
|
|
216548
216526
|
|
|
216549
|
-
// ui/dist/assets/index-
|
|
216550
|
-
var
|
|
216527
|
+
// ui/dist/assets/index-D6lVFqDO.js
|
|
216528
|
+
var index_D6lVFqDO_default = "./index-D6lVFqDO-3a1nn40g.js";
|
|
216551
216529
|
|
|
216552
|
-
// ui/dist/
|
|
216553
|
-
var
|
|
216530
|
+
// ui/dist/index.html
|
|
216531
|
+
var dist_default = "./index-g3cdpfvc.html";
|
|
216554
216532
|
|
|
216555
216533
|
// src/assets/ui.ts
|
|
216556
216534
|
var assets = {
|
|
216557
216535
|
"/icon.png": icon_default,
|
|
216558
|
-
"/index.
|
|
216559
|
-
"/assets/index-
|
|
216560
|
-
"/
|
|
216536
|
+
"/assets/index-B7vzjIqN.css": index_B7vzjIqN_default,
|
|
216537
|
+
"/assets/index-D6lVFqDO.js": index_D6lVFqDO_default,
|
|
216538
|
+
"/index.html": dist_default
|
|
216561
216539
|
};
|
|
216562
216540
|
|
|
216563
216541
|
// src/middleware/ui.ts
|
|
@@ -216606,17 +216584,14 @@ import { readFile as readFile4 } from "fs/promises";
|
|
|
216606
216584
|
import { dirname as dirname2, resolve as resolve2, isAbsolute as isAbsolute2 } from "path";
|
|
216607
216585
|
import { fileURLToPath as fileURLToPath4 } from "url";
|
|
216608
216586
|
|
|
216609
|
-
// node_modules/swagger-ui-dist/
|
|
216610
|
-
var
|
|
216611
|
-
|
|
216612
|
-
// node_modules/swagger-ui-dist/swagger-ui.js
|
|
216613
|
-
var swagger_ui_default = "./swagger-ui-bycaq9jd.js";
|
|
216587
|
+
// node_modules/swagger-ui-dist/swagger-ui.css
|
|
216588
|
+
var swagger_ui_default = "./swagger-ui-bfxfcsxh.css";
|
|
216614
216589
|
|
|
216615
216590
|
// node_modules/swagger-ui-dist/oauth2-redirect.js
|
|
216616
216591
|
var oauth2_redirect_default = "./oauth2-redirect-bqxabm9x.js";
|
|
216617
216592
|
|
|
216618
|
-
// node_modules/swagger-ui-dist/swagger-
|
|
216619
|
-
var
|
|
216593
|
+
// node_modules/swagger-ui-dist/swagger-initializer.js
|
|
216594
|
+
var swagger_initializer_default = "./swagger-initializer-55m7yyx2.js";
|
|
216620
216595
|
|
|
216621
216596
|
// node_modules/swagger-ui-dist/swagger-ui-bundle.js
|
|
216622
216597
|
var swagger_ui_bundle_default = "./swagger-ui-bundle-a3dgbj09.js";
|
|
@@ -216624,21 +216599,24 @@ var swagger_ui_bundle_default = "./swagger-ui-bundle-a3dgbj09.js";
|
|
|
216624
216599
|
// node_modules/swagger-ui-dist/swagger-ui-standalone-preset.js
|
|
216625
216600
|
var swagger_ui_standalone_preset_default = "./swagger-ui-standalone-preset-9dtac9s6.js";
|
|
216626
216601
|
|
|
216627
|
-
// node_modules/swagger-ui-dist/swagger-
|
|
216628
|
-
var
|
|
216602
|
+
// node_modules/swagger-ui-dist/swagger-ui.js
|
|
216603
|
+
var swagger_ui_default2 = "./swagger-ui-bycaq9jd.js";
|
|
216604
|
+
|
|
216605
|
+
// node_modules/swagger-ui-dist/favicon-16x16.png
|
|
216606
|
+
var favicon_16x16_default = "./favicon-16x16-xwsy16sv.png";
|
|
216629
216607
|
|
|
216630
216608
|
// node_modules/swagger-ui-dist/favicon-32x32.png
|
|
216631
216609
|
var favicon_32x32_default = "./favicon-32x32-zstv2hmc.png";
|
|
216632
216610
|
|
|
216633
216611
|
// src/assets/swagger.ts
|
|
216634
216612
|
var swaggerAssets = {
|
|
216635
|
-
"/
|
|
216636
|
-
"/swagger-ui.js": swagger_ui_default,
|
|
216613
|
+
"/swagger-ui.css": swagger_ui_default,
|
|
216637
216614
|
"/oauth2-redirect.js": oauth2_redirect_default,
|
|
216638
|
-
"/swagger-
|
|
216615
|
+
"/swagger-initializer.js": swagger_initializer_default,
|
|
216639
216616
|
"/swagger-ui-bundle.js": swagger_ui_bundle_default,
|
|
216640
216617
|
"/swagger-ui-standalone-preset.js": swagger_ui_standalone_preset_default,
|
|
216641
|
-
"/swagger-
|
|
216618
|
+
"/swagger-ui.js": swagger_ui_default2,
|
|
216619
|
+
"/favicon-16x16.png": favicon_16x16_default,
|
|
216642
216620
|
"/favicon-32x32.png": favicon_32x32_default
|
|
216643
216621
|
};
|
|
216644
216622
|
|
|
@@ -216909,5 +216887,5 @@ run().catch((error2) => {
|
|
|
216909
216887
|
fatal("Failed to start server:", error2);
|
|
216910
216888
|
});
|
|
216911
216889
|
|
|
216912
|
-
//# debugId=
|
|
216890
|
+
//# debugId=062B031EBFA3540064756E2164756E21
|
|
216913
216891
|
//# sourceMappingURL=main.js.map
|