mine-h5-ui
Version:
一款轻量级、模块化基于 Vue3.x 的 H5 前端 UI 组件库 👍
56 lines (55 loc) • 1.84 kB
JavaScript
import { defineComponent as f, createElementBlock as i, openBlock as o, normalizeStyle as s, unref as r, Fragment as g, renderList as c, createElementVNode as u, toDisplayString as m } from "vue";
import { useHandler as h } from "./hooks.js";
/*!
* mine-h5-ui v2.15.0
* Copyright (c) 2025 biaov
* @license MIT
*/
const z = /* @__PURE__ */ f({
name: "MeDivider",
__name: "index",
props: {
list: { default: () => [] },
line: { default: () => ({
radius: 0,
color: "#dcdfe6",
size: 1
}) },
text: { default: () => ({
color: "#494949",
size: 14
}) },
left: {},
right: {},
width: {},
height: {},
origin: {}
},
setup(d) {
const a = d, { fieldsetList: l, curLine: t } = h(a);
return (e, $) => (o(), i("div", {
class: "me-divider",
style: s(`width:${e.width}px;height:${e.height}px;`)
}, [
r(l).length > 0 ? (o(!0), i(g, { key: 0 }, c(r(l), (n, p) => (o(), i("fieldset", {
class: "fieldset",
key: p,
style: s(`transform-origin:center ${e.origin}px;transform:translate(-50%, -50%) rotate(${n.deg}deg);border-top-width:${r(t).size}px;border-top-color:${r(t).color};border-radius: ${r(t).radius}px;`),
role: "presentation"
}, [
u("legend", {
class: "legend",
style: s(`margin-left:${e.left}px;margin-right:${e.right}px;color:${e.text.color};font-size:${e.text.size}px`)
}, m(n.text), 5)
], 4))), 128)) : (o(), i("fieldset", {
key: 1,
class: "fieldset",
style: s(`transform-origin:center ${e.origin}px;border-top-width:${r(t).size}px;border-top-color:${r(t).color};border-radius: ${r(t).radius}px;`),
role: "presentation"
}, null, 4))
], 4));
}
});
export {
z as default
};