xvai-loi 0.1.56 → 0.1.57
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/co.txt +1 -1
- package/package.json +1 -1
- package/xvai-loi.js +12 -3
package/co.txt
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
xvaiLoi111021
|
package/package.json
CHANGED
package/xvai-loi.js
CHANGED
|
@@ -11697,7 +11697,7 @@ function lapCuongMe(o) {
|
|
|
11697
11697
|
const ten2 = x.kieu + ":" + String(x.tu || "").toLocaleLowerCase("vi"), im0 = taiSan(ten2), co = !!im0 && !daAnh.has(im0) && !!daAnh.add(im0), chuK = hoa3(suaChu(sach2(x.chu || ""))).split(" ").slice(0, 4).join(" "), chu22 = hoa3(suaChu(sach2(x.chu2 || ""))).split(" ").slice(0, 4).join(" ");
|
|
11698
11698
|
const n0 = ung.length, n1 = loai.length, dV = co && im0.laVideo ? Math.min(2.8, Math.max(2, +im0.dai || 2.4)) : 0;
|
|
11699
11699
|
if (x.kieu === "anh" && dV) {
|
|
11700
|
-
de(f2, dV, { uuTien: UT.
|
|
11700
|
+
de(f2, dV, { uuTien: UT.so + 5, bo: "anh", ten: ten2, chu: chuK, chu2: chu22, keu: "whoosh", video: 1 }, 3, datAnh);
|
|
11701
11701
|
ghiL("video", { bo: "anh", f: f2, d: dV }, "kho video: ung vien clip " + dV.toFixed(1) + " s thay anh: " + String(x.tu || ""));
|
|
11702
11702
|
} else if (x.kieu === "anh") de(f2, (f2 < f1 ? 2 : 2.4) * kTram(), { uuTien: UT.anh, ...co ? [{ bo: "anh", ten: ten2, chu: chuK, chu2: chu22, keu: "whoosh" }, { bo: "chia", ten: ten2, chu: chuK, keu: "whoosh" }, { bo: "anh", ten: ten2, chu: chuK, chu2: chu22, pip: 1, keu: "whoosh" }][nAnh++ % 3] : { bo: "kinh", dong: [chuK, chu22].filter(Boolean), keu: "whoosh" } }, 3, datAnh);
|
|
11703
11703
|
else if (x.kieu === "vat") {
|
|
@@ -18724,6 +18724,15 @@ async function handleExport(currentProject, setExporting, setExportedBlob, addLo
|
|
|
18724
18724
|
if (mauPd && mauPd.doan && window.__xuatNhanh) {
|
|
18725
18725
|
setExporting({ percent: 1, step: "AI so\u1EA1n ti\xEAu \u0111\u1EC1 gi\u1EA5y x\xE9..." });
|
|
18726
18726
|
const kb = await kichBanDoan(window.__wsGocKB || currentProject.speechDraft?.analysis?.words || []);
|
|
18727
|
+
try {
|
|
18728
|
+
(kb?.muc || []).forEach((m) => {
|
|
18729
|
+
if (m && /^\s*(bước|mẹo|mục|cách|phần|điều|thói quen|lưu ý|việc)\s*(số\s*)?\d+\s*$/i.test(String(m.ten || "")) && String(m.mo || "").trim()) {
|
|
18730
|
+
const mo4 = String(m.mo).trim();
|
|
18731
|
+
m.ten = mo4.charAt(0).toLocaleUpperCase("vi") + mo4.slice(1);
|
|
18732
|
+
}
|
|
18733
|
+
});
|
|
18734
|
+
} catch (e) {
|
|
18735
|
+
}
|
|
18727
18736
|
if (String((() => {
|
|
18728
18737
|
try {
|
|
18729
18738
|
return localStorage.getItem("xvaiNguonTram");
|
|
@@ -20471,7 +20480,7 @@ async function napLoi(d) {
|
|
|
20471
20480
|
return "LOI: " + String(e && e.message || e).slice(0, 300);
|
|
20472
20481
|
}
|
|
20473
20482
|
}
|
|
20474
|
-
var LOI_URL = "https://cdn.jsdelivr.net/npm/xvai-loi@0.1.
|
|
20483
|
+
var LOI_URL = "https://cdn.jsdelivr.net/npm/xvai-loi@0.1.56/nap.js";
|
|
20475
20484
|
var TRONG_LOI = !!globalThis.__xvaiReact;
|
|
20476
20485
|
try {
|
|
20477
20486
|
if (!TRONG_LOI) setTimeout(() => {
|
|
@@ -20501,7 +20510,7 @@ function datCauLenh(a) {
|
|
|
20501
20510
|
on2 = true;
|
|
20502
20511
|
window.addEventListener("message", async (ev) => {
|
|
20503
20512
|
const d = ev.data;
|
|
20504
|
-
if (!d || d.
|
|
20513
|
+
if (!d || d.xvaiLoi111021 !== true) return;
|
|
20505
20514
|
const o = String(ev.origin || "");
|
|
20506
20515
|
if (!(o.indexOf("https://flow.google.com") === 0 || o.indexOf("https://labs.google") === 0)) return;
|
|
20507
20516
|
const tra = (kq) => {
|