oeos-components 0.2.70 → 0.2.71

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.
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as Q, h as V, shallowRef as w, inject as _, toRefs as X, computed as p, getCurrentInstance as ee, watch as E, watchEffect as P, onMounted as te, onBeforeUnmount as ne, isRef as oe, unref as se, nextTick as ae } from "vue";
2
- import { i as ie, t as le } from "./index-ChwDqYnV.js";
2
+ import { i as ie, t as le } from "./index-g-Ts_TxZ.js";
3
3
  const re = ["getWidth", "getHeight", "getDom", "getOption", "resize", "dispatchAction", "convertToPixel", "convertFromPixel", "containPixel", "getDataURL", "getConnectedDataURL", "appendData", "clear", "isDisposed", "dispose"];
4
4
  function ue(t) {
5
5
  return function() {
@@ -32435,13 +32435,23 @@ const tne = P({ name: "OInput" }), nne = P({ ...tne, props: { modelValue: { requ
32435
32435
  const M = Re("el-checkbox"), C = Re("el-button"), I = Re("el-option"), T = Re("el-select");
32436
32436
  return N(), B("div", { class: Pe(["o-select", { "has-title": s.title, "has-quick": s.showQuick && !h.value && l.value.length > 0 }]), style: Et({ ...Y(Vt)(s.width) }) }, [$e(Y(a3), { title: s.title, size: Y(o).size, titleAttrs: S.$attrs.titleAttrs ?? {} }, null, 8, ["title", "size", "titleAttrs"]), $e(T, Ve({ ref_key: "selectRef", ref: u, class: ["o-select__select", Y(sn)(l.value) && n.emptyColor ? "o-select__empty" : ""], modelValue: d.value, "onUpdate:modelValue": A[1] || (A[1] = (D) => d.value = D), placeholder: o.disabled ? s.disPlaceholder : o.placeholder || "请选择", "popper-class": "o-select__multiple-checkbox", multiple: n.multiple, onChange: b }, { clearable: !0, filterable: !0, ...Object.entries(S.$attrs).reduce((D, [E, O]) => (E !== "class" && E !== "style" && (D[E] = O), D), {}) }), Sp({ default: he(() => [n.multiple && s.showAll ? (N(), B("div", Ane, [$e(M, { indeterminate: f.value, modelValue: m.value, "onUpdate:modelValue": A[0] || (A[0] = (D) => m.value = D), onChange: g, class: "o-select__all-select f-st-ct" }, { default: he(() => [Mne]), _: 1 }, 8, ["indeterminate", "modelValue"]), $e(C, { type: "primary", onClick: yo(v, ["stop"]), size: "small", class: "reverse-select" }, { default: he(() => [At("反选")]), _: 1 })])) : Oe("", !0), (N(!0), B(mt, null, cn(l.value, (D, E) => (N(), ve(I, { key: n.type === "simple" ? D : D[s.value], label: n.type === "simple" ? D : x(D), value: n.type === "simple" ? D : D[s.value], disabled: n.optionsDisabled(D, E, l.value) }, { default: he(() => [be(S.$slots, "default", { options: l.value, item: D }, void 0, !0)]), _: 2 }, 1032, ["label", "value", "disabled"]))), 128))]), _: 2 }, [s.showPrefix ? { name: "prefix", fn: he(() => [be(S.$slots, "prefix", {}, () => [Array.isArray(d.value) ? (N(), B("span", bne, je(d.value.length) + "/" + je(l.value.length), 1)) : (N(), B("span", Sne, je(l.value.length) + "个", 1))], !0)]), key: "0" } : void 0, S.$slots.label ? { name: "label", fn: he((D) => [be(S.$slots, "label", ns(Tu(D)), void 0, !0)]), key: "1" } : void 0, cn(i.value, (D, E, O) => ({ name: E, fn: he(() => [be(S.$slots, E, Ve(D, { index: O }), void 0, !0)]) }))]), 1040, ["class", "modelValue", "placeholder", "multiple"]), n.showQuick && !h.value && l.value.length > 0 ? (N(), B("div", { key: 0, class: "o-select__select-box", onClick: y }, [k("img", { src: Y("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAA3tJREFUWEfFlzFo1GAUx/8vd4iCQ0eHigoOdetgwcFBQVC3ghVbcEhySSbFQYcWlLYotEMdRKckl3yD0IoVuqkg6OAg1MHNDoIVO3TsULDIXZ79ksslud6lufZssxyX+/K93/d/7/7vhXDIF+0lvmEY/bWArgA4ioA+CWGv7GUf+UxhAFU3VRCugjEcBk6uLeE5x3oCoJrmIOo0XFYC13XdNbmpahgXECjzAJ9OByGiTWZeA+iV8OypVgCtYj5kpvIOsBIvCcf5Ft/PKKDq1hTAkwBNCM+e1XRjjkH3m5sQFijgN77vLuadWKtYd5j5efs1NJ0GbgtARC6Y+xgYCTchWkAJ08IulmtVt8YBnmmekqgGQAD8q0QsYnV31ECsABHVmLkcfQaPhOfOdpPjGICAHyA6He4FLPqec7N1nw4pkIemGis8lM5XUYimAkTvoPAEBbQcQfBT33MfZGop/SWpgVCcdRDCYiFgrUTBdFq6PJg0gKja11XdGAdoRh6KGJc9z/7cqQgzucsEIYyJqrNQRAW1Yo6CMS9rya/apnxG083XjZpaEZ5zrj2AqvZR6chtZhzPBuJ14TmiSPB4jfSNssIfYtWkedVZ+SlTgdRhChtRN8E7rdUqlrPtHUZamQMFiFMDoOmeBwoQOqtusvwsK3xSpucwAP40eokm6yoEkD1A/lfBwbPW/2kvcp/eQ9OtZQafJ6K7ftV+EQLE3k2gr75nD/U6aBbAmAMp92KTixSQrRbw08XxPyF2OGFjwPgtfxCec6B10Qym6mZUHF04Xi9UagK0M4leBNhtj0SBxL9rJQrOpC1Uzn97sWKATmTyTdjk+t+XQoiNDs3I/A5gIN27Y2W6SU3K8doIEE1bbQF03brIhI9hwwBPyEFErVhvwXwtHtN2k1T+3mg8kwz0h+sZgwA31MgZyaK2Gc2B8UCCgGa6BUhDxiYXHUpeuwBEEFHvlhBgXmXgbDcKJC3ZGCdSHifjnYTIAYikIxWgU9KfEuqQPJO7vFSoljWAOibBPBo+CSyCaEO24lyA7EiWDRF7d15gTTNGWKEbYISBo+DRHJhMynljeePFpDUIEdf8qvOk9X4D+Nb2gNHPzC1TFK1CCcaE636JC7MWKAbyXkyKVHimwGL3TG5ugbAExvuivrEv31dVawAKX5JNLD3/dXOQfQF0E6jT2n+839ww67q/YQAAAABJRU5ErkJggg=="), alt: "", width: "12px" }, null, 8, Cne)])) : Oe("", !0)], 6);
32437
32437
  };
32438
- } }), Dne = ht(vt(Tne, [["__scopeId", "data-v-72a20849"]])), kne = P({ name: "OSwitch" }), Lne = P({ ...kne, setup(n) {
32439
- const { proxy: t } = Tt();
32440
- return (e, o) => {
32441
- const a = Re("el-switch");
32442
- return N(), ve(a, Ve(e.$attrs, { "inline-prompt": "", class: "o-custom-switch" }), null, 16);
32438
+ } }), Dne = ht(vt(Tne, [["__scopeId", "data-v-72a20849"]])), kne = P({ name: "OSwitch" }), Lne = P({ ...kne, props: { beforeChange: { type: Function } }, setup(n) {
32439
+ const { proxy: t } = Tt(), e = n, o = ye(!1), a = async () => {
32440
+ if (!e.beforeChange)
32441
+ return !0;
32442
+ try {
32443
+ return o.value = !0, await e.beforeChange(), !0;
32444
+ } catch {
32445
+ return !1;
32446
+ } finally {
32447
+ o.value = !1;
32448
+ }
32449
+ };
32450
+ return (r, i) => {
32451
+ const s = Re("el-switch");
32452
+ return N(), ve(s, Ve(r.$attrs, { "inline-prompt": "", class: "o-custom-switch", loading: o.value, "before-change": a }), null, 16, ["loading"]);
32443
32453
  };
32444
- } }), Ene = ht(vt(Lne, [["__scopeId", "data-v-40f94812"]])), l7 = P({ name: "RenderComp", props: { render: Function, scope: Object, row: Object, value: [Object, String, Number] }, render: (n) => n.render(n == null ? void 0 : n.row, n == null ? void 0 : n.scope, n == null ? void 0 : n.value) }), i3 = (n) => (Lh("data-v-af57a0bc"), n = n(), Eh(), n), Nne = { class: "o-table" }, One = i3(() => k("span", null, "序号", -1)), zne = ["onClick"], Vne = { key: 2 }, Bne = { key: 3 }, Pne = { key: 0, style: { height: "64px" } }, Rne = { class: "page-wrap" }, Hne = { class: "page-left" }, Fne = i3(() => k("span", null, "共", -1)), Gne = { class: "m-lr-5" }, Wne = i3(() => k("span", null, "项数据", -1)), Une = P({ name: "OTable" }), jne = P({ ...Une, props: { data: { type: Array, default: () => [] }, columns: { type: Array, default: () => [] }, showPage: { type: Boolean, default: !0 }, showIndex: { type: Boolean, default: !0 }, pageSize: { type: Number, default: 30 }, pageSizes: { type: Array, default: () => [10, 30, 50] }, total: { type: Number }, columnEmptyText: { type: String, default: "-" }, isLoading: { type: Boolean } }, emits: ["update"], setup(n, { emit: t }) {
32454
+ } }), Ene = ht(vt(Lne, [["__scopeId", "data-v-d2c75b49"]])), l7 = P({ name: "RenderComp", props: { render: Function, scope: Object, row: Object, value: [Object, String, Number] }, render: (n) => n.render(n == null ? void 0 : n.row, n == null ? void 0 : n.scope, n == null ? void 0 : n.value) }), i3 = (n) => (Lh("data-v-af57a0bc"), n = n(), Eh(), n), Nne = { class: "o-table" }, One = i3(() => k("span", null, "序号", -1)), zne = ["onClick"], Vne = { key: 2 }, Bne = { key: 3 }, Pne = { key: 0, style: { height: "64px" } }, Rne = { class: "page-wrap" }, Hne = { class: "page-left" }, Fne = i3(() => k("span", null, "共", -1)), Gne = { class: "m-lr-5" }, Wne = i3(() => k("span", null, "项数据", -1)), Une = P({ name: "OTable" }), jne = P({ ...Une, props: { data: { type: Array, default: () => [] }, columns: { type: Array, default: () => [] }, showPage: { type: Boolean, default: !0 }, showIndex: { type: Boolean, default: !0 }, pageSize: { type: Number, default: 30 }, pageSizes: { type: Array, default: () => [10, 30, 50] }, total: { type: Number }, columnEmptyText: { type: String, default: "-" }, isLoading: { type: Boolean } }, emits: ["update"], setup(n, { emit: t }) {
32445
32455
  const e = Ia(), o = n, a = ye(null), r = ie(() => o.total || o.data.length), i = ye(o.pageSize), s = t, l = ye([]);
32446
32456
  ct(() => o.columns, () => {
32447
32457
  l.value = o.columns.map((_) => {
@@ -33931,7 +33941,7 @@ const Boe = P({ name: "OText" }), Poe = P({ ...Boe, props: { lineClamp: { type:
33931
33941
  } }), cae = ht(vt(lae, [["__scopeId", "data-v-bb1c45a2"]]));
33932
33942
  qe([SC, xC, uC, JI, eT, Yg, nT, rv, oT, rT, pT, vT, Jl, wT, _T, ST, CT, IT, TT, ET, OT, Dy, ky, RT, Ly, Ey, HT, GT, FT]);
33933
33943
  const uae = { key: 1, class: "vChart-box" }, dae = P({ name: "OCountBar" }), pae = P({ ...dae, props: { data: { type: Array, default: () => [] } }, setup(n) {
33934
- const t = Jv(() => import("./index-oBb4sfr3.js")), e = n, o = ye(), a = ye(!1);
33944
+ const t = Jv(() => import("./index-CbJsMIfa.js")), e = n, o = ye(), a = ye(!1);
33935
33945
  let r = { tooltip: { trigger: "axis", formatter: (i) => {
33936
33946
  const s = i[0];
33937
33947
  return `${s.name}: ${Fn(s.value)}个 <br> 总大小: ${_a(i[1].value)}`;
@@ -34014,7 +34024,7 @@ const uae = { key: 1, class: "vChart-box" }, dae = P({ name: "OCountBar" }), pae
34014
34024
  return N(), ve(l, { class: "h-100%" }, { default: he(() => [$e(s, { class: "w-100%" }, { default: he(() => [(N(!0), B(mt, null, cn(o.value, (c, u) => (N(), ve(i, { key: u, label: c.label, value: c.value, style: Et({ background: c.style.background, fontSize: "12px" }), labelStyle: { color: c.style.color }, itemStyle: { minWidth: "100px" }, valueStyle: { color: c.style.color, fontSize: "16px" } }, { img: he(() => [k("div", Vae, [k("img", { src: c.src, class: "po-r", useResize: !0 }, null, 8, Bae)])]), _: 2 }, 1032, ["label", "value", "style", "labelStyle", "valueStyle"]))), 128))]), _: 1 })]), _: 1 });
34015
34025
  };
34016
34026
  } }), Rae = ht(vt(Pae, [["__scopeId", "data-v-203686cc"]])), Hae = { key: 1, class: "vChart-box" }, Fae = P({ name: "OQuotaPie", __name: "index", props: { used: { type: [String, Number], required: !0 }, total: { type: [String, Number], required: !0 }, type: { type: String, default: "used" }, text: { type: String, required: !0 } }, setup(n) {
34017
- const t = Jv(() => import("./index-oBb4sfr3.js")), { proxy: e } = Tt(), o = n, a = ye(!1), r = ye();
34027
+ const t = Jv(() => import("./index-CbJsMIfa.js")), { proxy: e } = Tt(), o = n, a = ye(!1), r = ye();
34018
34028
  ye([]);
34019
34029
  const i = ye(0), s = ye(0);
34020
34030
  let l = { title: { text: "", textStyle: { color: "blue", fontSize: 16 } }, legend: { top: "bottom", textStyle: { fontSize: 10 }, left: "center" }, tooltip: { trigger: "item", show: !1 }, toolbox: { show: !0, feature: { mark: { show: !0 } } }, series: [{ type: "pie", radius: ["70%", "90%"], center: ["50%", "50%"], label: { backgroundColor: "#F6F8FC", borderColor: "#8C8D8E", position: "inner", borderRadius: 4, textStyle: { fontSize: 12, color: "#e4393c" }, rich: { a: { color: "#6E7079", lineHeight: 22, fontSize: 10, align: "center" }, hr: { borderColor: "#8C8D8E", width: "100%", borderWidth: 1, height: 0 }, b: { color: "#4C5058", fontSize: 12, fontWeight: "bold", lineHeight: 33 } } }, itemStyle: { borderRadius: 8, color: function(c) {
@@ -34041,7 +34051,7 @@ ${o.text}`;
34041
34051
  };
34042
34052
  } }), Gae = ht(vt(Fae, [["__scopeId", "data-v-d220cfdc"]])), Sk = (n) => (Lh("data-v-0ed7c01a"), n = n(), Eh(), n), Wae = { class: "vChart-box" }, Uae = { class: "f w-100% list-container" }, jae = { class: "list" }, Yae = Sk(() => k("div", null, "使用量", -1)), Xae = { class: "num" }, Zae = { class: "list" }, qae = Sk(() => k("div", null, "总量", -1)), Qae = { class: "num" }, Kae = P({ name: "OUsedPie" }), Jae = P({ ...Kae, props: { used: { type: [Number, String], default: 0 }, total: { type: [Number, String], default: 0 }, options: { type: Object, default: () => {
34043
34053
  } } }, setup(n) {
34044
- const t = Jv(() => import("./index-oBb4sfr3.js")), e = n, o = ye(), a = ye("0%");
34054
+ const t = Jv(() => import("./index-CbJsMIfa.js")), e = n, o = ye(), a = ye("0%");
34045
34055
  let r = { tooltip: { trigger: "item", show: !1 }, series: [{ type: "pie", center: ["50%", "50%"], radius: ["65%", "85%"], clockwise: !0, avoidLabelOverlap: !0, hoverOffset: 15, itemStyle: { color: function(i) {
34046
34056
  return i.name === "使用量" ? Mu("--blue") : Mu("--green");
34047
34057
  } }, label: { show: !1, position: "outside", formatter: function(i) {
@@ -1,4 +1,4 @@
1
- import { $ as e, O as t, q as o, d as r, f as m, c as i, H as n, w as g, a as p, G as f, b as l, D as c, E as d, j as u, r as y, I as v, x as S, h, g as x, l as E, J as T, e as b, y as B, m as F, n as w, B as C, z as D, s as I, o as L, F as O, C as W, A as $, u as j, k, v as q, p as z } from "./index-ChwDqYnV.js";
1
+ import { $ as e, O as t, q as o, d as r, f as m, c as i, H as n, w as g, a as p, G as f, b as l, D as c, E as d, j as u, r as y, I as v, x as S, h, g as x, l as E, J as T, e as b, y as B, m as F, n as w, B as C, z as D, s as I, o as L, F as O, C as W, A as $, u as j, k, v as q, p as z } from "./index-g-Ts_TxZ.js";
2
2
  export {
3
3
  e as $toast,
4
4
  t as OSvg,