@aplus-frontend/ui
Version:
49 lines (48 loc) • 817 B
JavaScript
import { createVNode as r } from "vue";
import { ApImage as t } from "../../ap-image/index.mjs";
const a = {
format: [
// DPF
"pdf",
// 视频
"mp4",
"webm",
"ogg",
"ogv",
// 音频
"mp3",
"wav",
"ogg",
"oga",
"m4a",
"aac"
],
parser: ({
src: e
}) => r("iframe", {
src: e,
style: {
width: "100%",
height: "100%",
border: "none"
}
}, null)
}, i = {
format: ["jpg", "jpeg", "png", "gif", "webp", "svg", "bmp", "ico", "tiff", "tif", "avif", "heif", "heic"],
parser: ({
src: e
}) => r(t, {
src: e,
width: "100%",
height: "100%",
preview: !1,
style: {
"object-fit": "contain"
}
}, null)
}, g = [a, i];
export {
g as defaultParserPlugins,
a as iframeParser,
i as imgParser
};