import "../../../../node_modules/.pnpm/vue@3.3.4/node_modules/vue/dist/vue.runtime.esm-bundler.mjs";
import { defineComponent, resolveComponent, openBlock, createElementBlock, createVNode, withCtx, createElementVNode as createBaseVNode, renderSlot, Fragment } from "../../../../node_modules/.pnpm/@vue_runtime-core@3.3.4/node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.mjs";
const _sfc_main = /* @__PURE__ */ defineComponent({
  __name: "CollapseItem",
  props: {
    name: {
      type: String,
      required: true
    },
    expanded: {
      type: Boolean,
      required: false,
      default: false
    }
  },
  setup(__props) {
    const click = (e) => {
      e.preventDefault();
      e.stopPropagation();
    };
    return (_ctx, _cache) => {
      const _component_n_divider = resolveComponent("n-divider");
      const _component_n_collapse_item = resolveComponent("n-collapse-item");
      const _component_n_collapse = resolveComponent("n-collapse");
      return openBlock(), createElementBlock(Fragment, null, [
        createVNode(_component_n_divider, { style: { "margin": "10px 0" } }),
        createVNode(_component_n_collapse, {
          "arrow-placement": "right",
          "default-expanded-names": __props.expanded ? __props.name : null,
          accordion: ""
        }, {
          "header-extra": withCtx(() => [
            createBaseVNode("div", { onClick: click }, [
              renderSlot(_ctx.$slots, "header")
            ])
          ]),
          default: withCtx(() => [
            createVNode(_component_n_collapse_item, {
              title: __props.name,
              name: __props.name
            }, {
              default: withCtx(() => [
                renderSlot(_ctx.$slots, "default")
              ]),
              _: 3
            }, 8, ["title", "name"])
          ]),
          _: 3
        }, 8, ["default-expanded-names"])
      ], 64);
    };
  }
});
export {
  _sfc_main as default
};
