import { defineComponent as m, unref as a, openBlock as o, createElementBlock as l, Fragment as n, createTextVNode as i, toDisplayString as d } from "vue";
import { isNil as r } from "lodash-unified";
import { getOptionValue as u, getOptionLabel as f } from "./helper.mjs";
const v = /* @__PURE__ */ m({
  name: "ApFieldCheckboxRead",
  __name: "read",
  props: {
    mode: { default: "edit" },
    class: {},
    style: {},
    emptyText: { default: "--" },
    customReadMode: {},
    defaultValue: {},
    value: {},
    onChange: {},
    "onUpdate:value": {},
    name: {},
    prefixCls: {},
    options: { default: () => [] },
    disabled: { type: Boolean, default: void 0 },
    id: {},
    request: {},
    vertical: { type: Boolean }
  },
  setup(e) {
    return (p, c) => a(r)(e.value) ? (o(), l(n, { key: 0 }, [
      i(d(e.emptyText), 1)
    ], 64)) : (o(), l(n, { key: 1 }, [
      i(d(e.options?.filter((t) => e.value.indexOf(a(u)(t)) > -1).map((t) => a(f)(t)).join("、") || e.emptyText), 1)
    ], 64));
  }
});
export {
  v as default
};
