reifyui 0.13.5 → 0.13.6
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.cjs +7 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +7 -3
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/components/FilePreview.jsx +3 -2
package/dist/index.js
CHANGED
|
@@ -2255,7 +2255,11 @@ var LANG = {
|
|
|
2255
2255
|
lua: "lua",
|
|
2256
2256
|
pl: "perl",
|
|
2257
2257
|
dockerfile: "dockerfile",
|
|
2258
|
-
diff: "diff"
|
|
2258
|
+
diff: "diff",
|
|
2259
|
+
md: "markdown",
|
|
2260
|
+
txt: "plaintext",
|
|
2261
|
+
log: "plaintext",
|
|
2262
|
+
csv: "plaintext"
|
|
2259
2263
|
};
|
|
2260
2264
|
var OFFICE = /* @__PURE__ */ new Set(["pptx", "ppt", "pptm", "odp", "doc", "docx", "odt", "rtf"]);
|
|
2261
2265
|
var SHEET = /* @__PURE__ */ new Set(["xls", "xlsx", "xlsm", "xlsb", "ods"]);
|
|
@@ -2429,8 +2433,8 @@ function FilePreview({
|
|
|
2429
2433
|
st.kind === "video" && st.objUrl && /* @__PURE__ */ jsx13("div", { className: "uic-fp-center", children: /* @__PURE__ */ jsx13("video", { className: "uic-fp-media", src: st.objUrl, controls: true }) }),
|
|
2430
2434
|
st.kind === "audio" && st.objUrl && /* @__PURE__ */ jsx13("div", { className: "uic-fp-center", children: /* @__PURE__ */ jsx13("audio", { src: st.objUrl, controls: true }) }),
|
|
2431
2435
|
st.kind === "markdown" && /* @__PURE__ */ jsx13("div", { className: "uic-fp-doc", children: renderMarkdown ? renderMarkdown(st.text || "") : /* @__PURE__ */ jsx13("pre", { className: "uic-fp-pre", children: st.text }) }),
|
|
2432
|
-
st.kind === "code" && /* @__PURE__ */ jsx13(CodeBlock, { code: st.text || "",
|
|
2433
|
-
st.kind === "html" && view === "source" && /* @__PURE__ */ jsx13(CodeBlock, { code: st.text || "",
|
|
2436
|
+
st.kind === "code" && /* @__PURE__ */ jsx13(CodeBlock, { code: st.text || "", language: LANG[extOf(name)] || "plaintext" }),
|
|
2437
|
+
st.kind === "html" && view === "source" && /* @__PURE__ */ jsx13(CodeBlock, { code: st.text || "", language: "xml" }),
|
|
2434
2438
|
st.kind === "html" && view === "preview" && // The page runs in its own origin with scripts only: a mockup's own script and styles
|
|
2435
2439
|
// work, and nothing in it can read the host page, its cookies or its storage.
|
|
2436
2440
|
/* @__PURE__ */ jsx13("iframe", { className: "uic-fp-frame", title: name, sandbox: "allow-scripts", srcDoc: st.text || "" }),
|