const e=require("../../style/index.js"),t=require("../../theme/util/genComponentStyleHook.js"),n=require("../../theme/util/statistic.js");var r=e=>{let{listBorderedCls:t,componentCls:n,paddingLG:r,margin:i,padding:a,listItemPaddingSM:o,marginLG:s,borderRadiusLG:c}=e;return{[`${t}`]:{border:`${e.lineWidth}px ${e.lineType} ${e.colorBorder}`,borderRadius:c,[`${n}-header,${n}-footer,${n}-item`]:{paddingInline:r},[`${n}-pagination`]:{margin:`${i}px ${s}px`}},[`${t}${n}-sm`]:{[`${n}-item,${n}-header,${n}-footer`]:{padding:o}},[`${t}${n}-lg`]:{[`${n}-item,${n}-header,${n}-footer`]:{padding:`${a}px ${r}px`}}}},i=e=>{let{componentCls:t,screenSM:n,screenMD:r,marginLG:i,marginSM:a,margin:o}=e;return{[`@media screen and (max-width:${r})`]:{[`${t}`]:{[`${t}-item`]:{[`${t}-item-action`]:{marginInlineStart:i}}},[`${t}-vertical`]:{[`${t}-item`]:{[`${t}-item-extra`]:{marginInlineStart:i}}}},[`@media screen and (max-width: ${n})`]:{[`${t}`]:{[`${t}-item`]:{flexWrap:`wrap`,[`${t}-action`]:{marginInlineStart:a}}},[`${t}-vertical`]:{[`${t}-item`]:{flexWrap:`wrap-reverse`,[`${t}-item-main`]:{minWidth:e.contentWidth},[`${t}-item-extra`]:{margin:`auto auto ${o}px`}}}}}},a=t=>{let{componentCls:n,antCls:r,controlHeight:i,minHeight:a,paddingSM:o,marginLG:s,padding:c,listItemPadding:l,colorPrimary:u,listItemPaddingSM:d,listItemPaddingLG:f,paddingXS:p,margin:m,colorText:h,colorTextDescription:g,motionDurationSlow:_,lineWidth:v}=t;return{[`${n}`]:{...e.resetComponent(t),position:`relative`,"*":{outline:`none`},[`${n}-header, ${n}-footer`]:{background:`transparent`,paddingBlock:o},[`${n}-pagination`]:{marginBlockStart:s,textAlign:`end`,[`${r}-pagination-options`]:{textAlign:`start`}},[`${n}-spin`]:{minHeight:a,textAlign:`center`},[`${n}-items`]:{margin:0,padding:0,listStyle:`none`},[`${n}-item`]:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,padding:l,color:h,[`${n}-item-meta`]:{display:`flex`,flex:1,alignItems:`flex-start`,maxWidth:`100%`,[`${n}-item-meta-avatar`]:{marginInlineEnd:c},[`${n}-item-meta-content`]:{flex:`1 0`,width:0,color:h},[`${n}-item-meta-title`]:{marginBottom:t.marginXXS,color:h,fontSize:t.fontSize,lineHeight:t.lineHeight,"> a":{color:h,transition:`all ${_}`,"&:hover":{color:u}}},[`${n}-item-meta-description`]:{color:g,fontSize:t.fontSize,lineHeight:t.lineHeight}},[`${n}-item-action`]:{flex:`0 0 auto`,marginInlineStart:t.marginXXL,padding:0,fontSize:0,listStyle:`none`,"& > li":{position:`relative`,display:`inline-block`,padding:`0 ${p}px`,color:g,fontSize:t.fontSize,lineHeight:t.lineHeight,textAlign:`center`,"&:first-child":{paddingInlineStart:0}},[`${n}-item-action-split`]:{position:`absolute`,insetBlockStart:`50%`,insetInlineEnd:0,width:v,height:Math.ceil(t.fontSize*t.lineHeight)-t.marginXXS*2,transform:`translateY(-50%)`,backgroundColor:t.colorSplit}}},[`${n}-empty`]:{padding:`${c}px 0`,color:g,fontSize:t.fontSizeSM,textAlign:`center`},[`${n}-empty-text`]:{padding:c,color:t.colorTextDisabled,fontSize:t.fontSize,textAlign:`center`},[`${n}-item-no-flex`]:{display:`block`}},[`${n}-grid ${r}-col > ${n}-item`]:{display:`block`,maxWidth:`100%`,marginBlockEnd:m,paddingBlock:0,borderBlockEnd:`none`},[`${n}-vertical ${n}-item`]:{alignItems:`initial`,[`${n}-item-main`]:{display:`block`,flex:1},[`${n}-item-extra`]:{marginInlineStart:s},[`${n}-item-meta`]:{marginBlockEnd:c,[`${n}-item-meta-title`]:{marginBlockEnd:o,color:h,fontSize:t.fontSizeLG,lineHeight:t.lineHeightLG}},[`${n}-item-action`]:{marginBlockStart:c,marginInlineStart:`auto`,"> li":{padding:`0 ${c}px`,"&:first-child":{paddingInlineStart:0}}}},[`${n}-split ${n}-item`]:{borderBlockEnd:`${t.lineWidth}px ${t.lineType} ${t.colorSplit}`,"&:last-child":{borderBlockEnd:`none`}},[`${n}-split ${n}-header`]:{borderBlockEnd:`${t.lineWidth}px ${t.lineType} ${t.colorSplit}`},[`${n}-split${n}-empty ${n}-footer`]:{borderTop:`${t.lineWidth}px ${t.lineType} ${t.colorSplit}`},[`${n}-loading ${n}-spin-nested-loading`]:{minHeight:i},[`${n}-split${n}-something-after-last-item ${r}-spin-container > ${n}-items > ${n}-item:last-child`]:{borderBlockEnd:`${t.lineWidth}px ${t.lineType} ${t.colorSplit}`},[`${n}-lg ${n}-item`]:{padding:f},[`${n}-sm ${n}-item`]:{padding:d},[`${n}:not(${n}-vertical)`]:{[`${n}-item-no-flex`]:{[`${n}-item-action`]:{float:`right`}}}}},o=t.default(`List`,e=>{let t=n.merge(e,{listBorderedCls:`${e.componentCls}-bordered`,minHeight:e.controlHeightLG,listItemPadding:`${e.paddingContentVertical}px ${e.paddingContentHorizontalLG}px`,listItemPaddingSM:`${e.paddingContentVerticalSM}px ${e.paddingContentHorizontal}px`,listItemPaddingLG:`${e.paddingContentVerticalLG}px ${e.paddingContentHorizontalLG}px`});return[a(t),r(t),i(t)]},{contentWidth:220});exports.default=o;