

<script>
/* eslint-disable */
// sd-skip-auto-import
import render from"../sd-component-render.vue";import runtimeUtil from"../runtime-util";import components from"./_import-components/sd-collapse-layout-render-import";export function processChildren(e,t){e.contents.forEach((e=>{if(e?.attrFD)t(e)}))}var _render=function e(){var t=this,r=t._self._c;return r("a-collapse",{class:t.$style.wrapper,attrs:{"default-active-key":t.field.attrFD.defaultExpanded?"default":void 0}},[r("a-collapse-panel",{key:"default",class:{[t.$style.hasError]:!t.validateStatus},attrs:{header:t.field.caption,"force-render":""}},t._l(t.field.contents,(function(e,t){return r("render",{key:t,attrs:{field:e}})})),1)],1)};var staticRenderFns=[];_render._withStripped=true;export default{name:"SdCollapseLayoutRender",components:{render:render,...components},props:{field:{type:Object,required:true}},data(){return{}},inject:["formValidateStatusMap"],computed:{fieldsInCollapse(){const e=[];runtimeUtil.processComponentAndChildren(this.field.contents,(t=>e.push(t.name)));return e},validateStatus(){return this.fieldsInCollapse.every((e=>false!==this.formValidateStatusMap[e]))}},methods:{},render:_render,staticRenderFns:staticRenderFns};</script>

<style module lang="scss">
@use '@/common/design' as *;
.wrapper {
  margin-bottom: $padding-lg;
}
.has-error:global(.ant-collapse-item:not(.ant-collapse-item-active) > .ant-collapse-header) {
  color: $error-color;
}
</style>
