'use strict';

Object.defineProperty(exports, '__esModule', { value: true });

var vue = require('vue');
require('../../../utils/index.js');
var collapse = require('./collapse.js');
var createNamespace = require('../../../utils/create-namespace.js');

"use strict";
var _sfc_main = /* @__PURE__ */ vue.defineComponent({
  ...{ name: "LlCollapsePanel" },
  __name: "collapse-panel",
  props: collapse.collapsePanelProps,
  setup(__props) {
    const bem = createNamespace.createNamespace("collapse-panel");
    const attrs = vue.useAttrs();
    return (_ctx, _cache) => {
      const _component_ll_icon = vue.resolveComponent("ll-icon");
      const _component_a_collapse_panel = vue.resolveComponent("a-collapse-panel");
      return vue.openBlock(), vue.createBlock(_component_a_collapse_panel, vue.mergeProps({
        collapsible: _ctx.disabled || void 0
      }, vue.unref(attrs), {
        class: vue.unref(bem).b()
      }), vue.createSlots({
        header: vue.withCtx(() => [
          _ctx.$slots.header ? vue.renderSlot(_ctx.$slots, "header", { key: 0 }) : (vue.openBlock(), vue.createElementBlock(
            vue.Fragment,
            { key: 1 },
            [
              _ctx.headerIcon.iconName ? (vue.openBlock(), vue.createBlock(_component_ll_icon, vue.mergeProps({ key: 0 }, _ctx.headerIcon, {
                style: {
                  marginRight: _ctx.iconSpace + "px"
                }
              }), null, 16, ["style"])) : vue.createCommentVNode("v-if", true),
              vue.createTextVNode(
                " " + vue.toDisplayString(_ctx.header),
                1
                /* TEXT */
              )
            ],
            64
            /* STABLE_FRAGMENT */
          ))
        ]),
        extra: vue.withCtx(() => [
          vue.renderSlot(_ctx.$slots, "extra")
        ]),
        _: 2
        /* DYNAMIC */
      }, [
        vue.renderList(Object.keys(_ctx.$slots).filter(
          (slot) => slot !== "extra" && slot !== "header"
        ), (item) => {
          return {
            name: item,
            fn: vue.withCtx((data) => [
              vue.renderSlot(_ctx.$slots, item, vue.normalizeProps(vue.guardReactiveProps(data || {})))
            ])
          };
        })
      ]), 1040, ["collapsible", "class"]);
    };
  }
});

exports.default = _sfc_main;
//# sourceMappingURL=collapse-panel.vue2.js.map
