artifactuse 0.4.1 → 0.4.2
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/react/index.js +2 -2
- package/dist/svelte/index.js +196 -196
- package/dist/vue/index.js +3 -3
- package/dist/vue2/index.js +3 -2
- package/package.json +1 -1
package/dist/react/index.js
CHANGED
|
@@ -920,7 +920,7 @@ function Za({
|
|
|
920
920
|
if (!a) return null;
|
|
921
921
|
let r = L(a);
|
|
922
922
|
return r && a._refreshToken && (r += (r.includes("?") ? "&" : "?") + "_t=" + a._refreshToken), r;
|
|
923
|
-
}, [a, L]), Re = N(() => a ? ha(a.language) : "plaintext", [a]), Se = N(() => Wt.includes(a == null ? void 0 : a.language), [a]), ae = N(() => Se ? a.language : null, [Se, a]), ze = N(() => ae !== "font" || !a ? null : "apfont_" + a.id, [ae, a]), qt = N(() => {
|
|
923
|
+
}, [a, L]), Re = N(() => a ? ha(a.language) : "plaintext", [a]), Se = N(() => Wt.includes(a == null ? void 0 : a.language) && !!(a != null && a.fileExtension), [a]), ae = N(() => Se ? a.language : null, [Se, a]), ze = N(() => ae !== "font" || !a ? null : "apfont_" + a.id, [ae, a]), qt = N(() => {
|
|
924
924
|
if (ae !== "binary" || !(a != null && a.code)) return "";
|
|
925
925
|
try {
|
|
926
926
|
const r = atob(a.code.slice(0, 684)), E = new Uint8Array(r.length);
|
|
@@ -1226,7 +1226,7 @@ function Za({
|
|
|
1226
1226
|
});
|
|
1227
1227
|
}, [mt]);
|
|
1228
1228
|
if (I(() => {
|
|
1229
|
-
a && (j.current && j.current.isPreviewable !== a.isPreviewable && (fe(!0), setTimeout(() => fe(!1), 150)), j.current = a, Wt.includes(a.language) && _("preview"), Lt(), oe(!0), ta(), lt());
|
|
1229
|
+
a && (j.current && j.current.isPreviewable !== a.isPreviewable && (fe(!0), setTimeout(() => fe(!1), 150)), j.current = a, Wt.includes(a.language) && a.fileExtension && _("preview"), Lt(), oe(!0), ta(), lt());
|
|
1230
1230
|
}, [a == null ? void 0 : a.id, Lt]), I(() => {
|
|
1231
1231
|
if (ae === "font" && ze && (a != null && a.code)) {
|
|
1232
1232
|
const r = `@font-face { font-family: "${ze}"; src: url("data:${Bt(a.fileExtension || "woff2")};base64,${a.code}"); }`;
|