"use strict";
const vue = require("vue");
const dom = require("./dom-BgEUZpKg.js");
const useColorVariantClasses = require("./useColorVariantClasses-BjkZZDqD.js");
const useDefaults = require("./useDefaults-YXpmugKp.js");
const BImg_vue_vue_type_script_setup_true_lang = require("./BImg.vue_vue_type_script_setup_true_lang-3FYrkHVf.js");
const object = require("./object-DlOVrM-t.js");
const index = require("./index-C_bsiScj.js");
const _sfc_main$7 = /* @__PURE__ */ vue.defineComponent({
  __name: "BCardImg",
  props: {
    placement: { default: "top" },
    blank: { type: Boolean, default: void 0 },
    blankColor: { default: void 0 },
    block: { type: Boolean, default: void 0 },
    fluid: { type: Boolean, default: void 0 },
    fluidGrow: { type: Boolean, default: void 0 },
    height: { default: void 0 },
    tag: {},
    lazy: { type: Boolean, default: void 0 },
    sizes: { default: void 0 },
    src: { default: void 0 },
    srcset: { default: void 0 },
    thumbnail: { type: Boolean, default: void 0 },
    width: { default: void 0 },
    rounded: { type: [Boolean, String, Number], default: void 0 },
    roundedTop: { type: [Boolean, String, Number], default: void 0 },
    roundedBottom: { type: [Boolean, String, Number], default: void 0 },
    roundedStart: { type: [Boolean, String, Number], default: void 0 },
    roundedEnd: { type: [Boolean, String, Number], default: void 0 }
  },
  setup(__props) {
    const _props = __props;
    const props = useDefaults.useDefaults(_props, "BCardImg");
    const baseAlignmentClasses = vue.computed(() => ({
      "card-img-top": props.placement === "top",
      // TODO implement this class
      "card-img-end": props.placement === "end",
      "card-img-bottom": props.placement === "bottom",
      // TODO implement this class
      "card-img-start": props.placement === "start",
      "card-img": props.placement === "overlay"
    }));
    const computedImgProps = vue.computed(() => object.omit(props, ["placement"]));
    return (_ctx, _cache) => {
      return vue.openBlock(), vue.createBlock(BImg_vue_vue_type_script_setup_true_lang._sfc_main, vue.mergeProps(computedImgProps.value, { class: baseAlignmentClasses.value }), null, 16, ["class"]);
    };
  }
});
const _sfc_main$6 = /* @__PURE__ */ vue.defineComponent({
  __name: "BCardHeadFoot",
  props: {
    borderVariant: { default: null },
    tag: { default: "div" },
    text: { default: void 0 },
    variant: { default: null },
    bgVariant: { default: null },
    textVariant: { default: null }
  },
  setup(__props) {
    const props = __props;
    const computedClasses = useColorVariantClasses.useColorVariantClasses(props);
    return (_ctx, _cache) => {
      return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(__props.tag), {
        class: vue.normalizeClass(vue.unref(computedClasses))
      }, {
        default: vue.withCtx(() => [
          vue.renderSlot(_ctx.$slots, "default", {}, () => [
            vue.createTextVNode(vue.toDisplayString(__props.text), 1)
          ])
        ]),
        _: 3
      }, 8, ["class"]);
    };
  }
});
const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
  __name: "BCardHeader",
  props: {
    borderVariant: { default: void 0 },
    tag: { default: "div" },
    text: { default: void 0 },
    variant: { default: void 0 },
    bgVariant: { default: void 0 },
    textVariant: { default: void 0 }
  },
  setup(__props) {
    const _props = __props;
    const props = useDefaults.useDefaults(_props, "BCardHeader");
    return (_ctx, _cache) => {
      return vue.openBlock(), vue.createBlock(_sfc_main$6, vue.mergeProps({ class: "card-header" }, vue.unref(props)), {
        default: vue.withCtx(() => [
          vue.renderSlot(_ctx.$slots, "default")
        ]),
        _: 3
      }, 16);
    };
  }
});
const _sfc_main$4 = /* @__PURE__ */ vue.defineComponent({
  __name: "BCardTitle",
  props: {
    tag: { default: "h4" },
    text: { default: void 0 }
  },
  setup(__props) {
    const _props = __props;
    const props = useDefaults.useDefaults(_props, "BCardTitle");
    return (_ctx, _cache) => {
      return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(vue.unref(props).tag), { class: "card-title" }, {
        default: vue.withCtx(() => [
          vue.renderSlot(_ctx.$slots, "default", {}, () => [
            vue.createTextVNode(vue.toDisplayString(vue.unref(props).text), 1)
          ])
        ]),
        _: 3
      });
    };
  }
});
const _sfc_main$3 = /* @__PURE__ */ vue.defineComponent({
  __name: "BCardSubtitle",
  props: {
    text: { default: void 0 },
    tag: { default: "h6" },
    textVariant: { default: "body-secondary" }
  },
  setup(__props) {
    const _props = __props;
    const props = useDefaults.useDefaults(_props, "BCardSubtitle");
    const computedClasses = useColorVariantClasses.useColorVariantClasses(props);
    return (_ctx, _cache) => {
      return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(vue.unref(props).tag), {
        class: vue.normalizeClass(["card-subtitle mb-2", vue.unref(computedClasses)])
      }, {
        default: vue.withCtx(() => [
          vue.renderSlot(_ctx.$slots, "default", {}, () => [
            vue.createTextVNode(vue.toDisplayString(vue.unref(props).text), 1)
          ])
        ]),
        _: 3
      }, 8, ["class"]);
    };
  }
});
const _sfc_main$2 = /* @__PURE__ */ vue.defineComponent({
  __name: "BCardBody",
  props: {
    borderVariant: { default: null },
    overlay: { type: Boolean, default: false },
    subtitle: { default: void 0 },
    subtitleTag: { default: "h4" },
    subtitleTextVariant: { default: void 0 },
    tag: { default: "div" },
    text: { default: void 0 },
    title: { default: void 0 },
    titleTag: { default: "h4" },
    variant: { default: null },
    bgVariant: { default: null },
    textVariant: { default: null }
  },
  setup(__props) {
    const _props = __props;
    const props = useDefaults.useDefaults(_props, "BCardBody");
    const slots = vue.useSlots();
    const hasTitleSlot = vue.computed(() => !dom.isEmptySlot(slots.title));
    const hasSubtitleSlot = vue.computed(() => !dom.isEmptySlot(slots.subtitle));
    const colorClasses = useColorVariantClasses.useColorVariantClasses(props);
    const computedClasses = vue.computed(() => [
      colorClasses.value,
      props.overlay ? "card-img-overlay" : "card-body"
    ]);
    return (_ctx, _cache) => {
      return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(vue.unref(props).tag), {
        class: vue.normalizeClass(computedClasses.value)
      }, {
        default: vue.withCtx(() => [
          !!vue.unref(props).title || hasTitleSlot.value ? (vue.openBlock(), vue.createBlock(_sfc_main$4, {
            key: 0,
            tag: vue.unref(props).titleTag
          }, {
            default: vue.withCtx(() => [
              vue.renderSlot(_ctx.$slots, "title", {}, () => [
                vue.createTextVNode(vue.toDisplayString(vue.unref(props).title), 1)
              ])
            ]),
            _: 3
          }, 8, ["tag"])) : vue.createCommentVNode("", true),
          !!vue.unref(props).subtitle || hasSubtitleSlot.value ? (vue.openBlock(), vue.createBlock(_sfc_main$3, {
            key: 1,
            tag: vue.unref(props).subtitleTag,
            "text-variant": vue.unref(props).subtitleTextVariant
          }, {
            default: vue.withCtx(() => [
              vue.renderSlot(_ctx.$slots, "subtitle", {}, () => [
                vue.createTextVNode(vue.toDisplayString(vue.unref(props).subtitle), 1)
              ])
            ]),
            _: 3
          }, 8, ["tag", "text-variant"])) : vue.createCommentVNode("", true),
          vue.renderSlot(_ctx.$slots, "default", {}, () => [
            vue.createTextVNode(vue.toDisplayString(vue.unref(props).text), 1)
          ])
        ]),
        _: 3
      }, 8, ["class"]);
    };
  }
});
const _sfc_main$1 = /* @__PURE__ */ vue.defineComponent({
  __name: "BCardFooter",
  props: {
    borderVariant: { default: void 0 },
    tag: { default: "div" },
    text: { default: void 0 },
    variant: { default: void 0 },
    bgVariant: { default: void 0 },
    textVariant: { default: void 0 }
  },
  setup(__props) {
    const _props = __props;
    const props = useDefaults.useDefaults(_props, "BCardFooter");
    return (_ctx, _cache) => {
      return vue.openBlock(), vue.createBlock(_sfc_main$6, vue.mergeProps({ class: "card-footer" }, vue.unref(props)), {
        default: vue.withCtx(() => [
          vue.renderSlot(_ctx.$slots, "default", {}, () => [
            vue.createTextVNode(vue.toDisplayString(vue.unref(props).text), 1)
          ])
        ]),
        _: 3
      }, 16);
    };
  }
});
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
  __name: "BCard",
  props: {
    align: { default: void 0 },
    bodyBgVariant: { default: void 0 },
    bodyBorderVariant: { default: void 0 },
    bodyClass: { default: void 0 },
    bodyTag: { default: "div" },
    bodyText: { default: "" },
    bodyTextVariant: { default: void 0 },
    borderVariant: { default: null },
    footer: { default: void 0 },
    footerBgVariant: { default: void 0 },
    footerBorderVariant: { default: void 0 },
    footerClass: { default: void 0 },
    footerTag: { default: "div" },
    footerTextVariant: { default: void 0 },
    footerVariant: { default: null },
    header: { default: void 0 },
    headerBgVariant: { default: void 0 },
    headerBorderVariant: { default: void 0 },
    headerClass: { default: void 0 },
    headerTag: { default: "div" },
    headerTextVariant: { default: void 0 },
    headerVariant: { default: null },
    imgAlt: { default: void 0 },
    imgPlacement: { default: "top" },
    imgHeight: { default: void 0 },
    imgSrc: { default: void 0 },
    imgWidth: { default: void 0 },
    noBody: { type: Boolean, default: false },
    subtitle: { default: void 0 },
    subtitleTag: { default: "h6" },
    subtitleTextVariant: { default: "body-secondary" },
    tag: { default: "div" },
    title: { default: void 0 },
    titleTag: { default: "h4" },
    variant: { default: null },
    bgVariant: { default: null },
    textVariant: { default: null }
  },
  setup(__props) {
    const _props = __props;
    const props = useDefaults.useDefaults(_props, "BCard");
    const slots = vue.useSlots();
    const hasHeaderSlot = vue.computed(() => !dom.isEmptySlot(slots.header));
    const hasFooterSlot = vue.computed(() => !dom.isEmptySlot(slots.footer));
    const colorClasses = useColorVariantClasses.useColorVariantClasses(props);
    const computedClasses = vue.computed(() => [
      colorClasses.value,
      {
        [`text-${props.align}`]: props.align !== void 0,
        "flex-row": props.imgPlacement === "start",
        "flex-row-reverse": props.imgPlacement === "end"
      }
    ]);
    const imgAttr = vue.computed(() => ({
      src: props.imgSrc,
      alt: props.imgAlt,
      height: props.imgHeight,
      width: props.imgWidth,
      placement: props.imgPlacement
    }));
    const ReusableImg = index.createReusableTemplate();
    return (_ctx, _cache) => {
      return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(vue.unref(props).tag), {
        class: vue.normalizeClass(["card", computedClasses.value])
      }, {
        default: vue.withCtx(() => [
          vue.createVNode(vue.unref(ReusableImg).define, null, {
            default: vue.withCtx(() => [
              vue.renderSlot(_ctx.$slots, "img", {}, () => [
                vue.unref(props).imgSrc ? (vue.openBlock(), vue.createBlock(_sfc_main$7, vue.normalizeProps(vue.mergeProps({ key: 0 }, imgAttr.value)), null, 16)) : vue.createCommentVNode("", true)
              ])
            ]),
            _: 3
          }),
          vue.unref(props).imgPlacement !== "bottom" ? (vue.openBlock(), vue.createBlock(vue.unref(ReusableImg).reuse, { key: 0 })) : vue.createCommentVNode("", true),
          vue.unref(props).header || hasHeaderSlot.value ? (vue.openBlock(), vue.createBlock(_sfc_main$5, {
            key: 1,
            "bg-variant": vue.unref(props).headerBgVariant,
            variant: vue.unref(props).headerVariant,
            "border-variant": vue.unref(props).headerBorderVariant,
            tag: vue.unref(props).headerTag,
            "text-variant": vue.unref(props).headerTextVariant,
            class: vue.normalizeClass(vue.unref(props).headerClass)
          }, {
            default: vue.withCtx(() => [
              vue.renderSlot(_ctx.$slots, "header", {}, () => [
                vue.createTextVNode(vue.toDisplayString(vue.unref(props).header), 1)
              ])
            ]),
            _: 3
          }, 8, ["bg-variant", "variant", "border-variant", "tag", "text-variant", "class"])) : vue.createCommentVNode("", true),
          !vue.unref(props).noBody ? (vue.openBlock(), vue.createBlock(_sfc_main$2, {
            key: 2,
            overlay: vue.unref(props).imgPlacement === "overlay",
            "bg-variant": vue.unref(props).bodyBgVariant,
            "border-variant": vue.unref(props).bodyBorderVariant,
            tag: vue.unref(props).bodyTag,
            "text-variant": vue.unref(props).bodyTextVariant,
            subtitle: vue.unref(props).subtitle,
            "subtitle-tag": vue.unref(props).subtitleTag,
            "subtitle-text-variant": vue.unref(props).subtitleTextVariant,
            title: vue.unref(props).title,
            "title-tag": vue.unref(props).titleTag,
            class: vue.normalizeClass(vue.unref(props).bodyClass)
          }, {
            default: vue.withCtx(() => [
              vue.renderSlot(_ctx.$slots, "default", {}, () => [
                vue.createTextVNode(vue.toDisplayString(vue.unref(props).bodyText), 1)
              ])
            ]),
            _: 3
          }, 8, ["overlay", "bg-variant", "border-variant", "tag", "text-variant", "subtitle", "subtitle-tag", "subtitle-text-variant", "title", "title-tag", "class"])) : vue.renderSlot(_ctx.$slots, "default", { key: 3 }, () => [
            vue.createTextVNode(vue.toDisplayString(vue.unref(props).bodyText), 1)
          ]),
          vue.unref(props).footer || hasFooterSlot.value ? (vue.openBlock(), vue.createBlock(_sfc_main$1, {
            key: 4,
            "bg-variant": vue.unref(props).footerBgVariant,
            "border-variant": vue.unref(props).footerBorderVariant,
            variant: vue.unref(props).footerVariant,
            tag: vue.unref(props).footerTag,
            "text-variant": vue.unref(props).footerTextVariant,
            class: vue.normalizeClass(vue.unref(props).footerClass)
          }, {
            default: vue.withCtx(() => [
              vue.renderSlot(_ctx.$slots, "footer", {}, () => [
                vue.createTextVNode(vue.toDisplayString(vue.unref(props).footer), 1)
              ])
            ]),
            _: 3
          }, 8, ["bg-variant", "border-variant", "variant", "tag", "text-variant", "class"])) : vue.createCommentVNode("", true),
          vue.unref(props).imgPlacement === "bottom" ? (vue.openBlock(), vue.createBlock(vue.unref(ReusableImg).reuse, { key: 5 })) : vue.createCommentVNode("", true)
        ]),
        _: 3
      }, 8, ["class"]);
    };
  }
});
exports._sfc_main = _sfc_main;
exports._sfc_main$1 = _sfc_main$2;
exports._sfc_main$2 = _sfc_main$1;
exports._sfc_main$3 = _sfc_main$5;
exports._sfc_main$4 = _sfc_main$7;
exports._sfc_main$5 = _sfc_main$3;
exports._sfc_main$6 = _sfc_main$4;
//# sourceMappingURL=BCard.vue_vue_type_script_setup_true_lang-D_MdzqZw.js.map
