"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("../../style/index.js"),c=require("../../node_modules/.pnpm/@ctrl_tinycolor@3.6.1/node_modules/@ctrl/tinycolor/dist/module/index.js"),s=i=>{const{componentCls:e,iconCls:o,uploadThumbnailSize:l,uploadProgressOffset:n}=i,t=`${e}-list`,r=`${t}-item`;return{[`${e}-wrapper`]:{[`${t}${t}-picture, ${t}${t}-picture-card`]:{[r]:{position:"relative",height:l+i.lineWidth*2+i.paddingXS*2,padding:i.paddingXS,border:`${i.lineWidth}px ${i.lineType} ${i.colorBorder}`,borderRadius:i.borderRadiusLG,"&:hover":{background:"transparent"},[`${r}-thumbnail`]:{...d.textEllipsis,width:l,height:l,lineHeight:`${l+i.paddingSM}px`,textAlign:"center",flex:"none",[o]:{fontSize:i.fontSizeHeading2,color:i.colorPrimary},img:{display:"block",width:"100%",height:"100%",overflow:"hidden"}},[`${r}-progress`]:{bottom:n,width:`calc(100% - ${i.paddingSM*2}px)`,marginTop:0,paddingInlineStart:l+i.paddingXS}},[`${r}-error`]:{borderColor:i.colorError,[`${r}-thumbnail ${o}`]:{"svg path[fill='#e6f7ff']":{fill:i.colorErrorBg},"svg path[fill='#1890ff']":{fill:i.colorError}}},[`${r}-uploading`]:{borderStyle:"dashed",[`${r}-name`]:{marginBottom:n}}}}}},p=i=>{const{componentCls:e,iconCls:o,fontSizeLG:l,colorTextLightSolid:n}=i,t=`${e}-list`,r=`${t}-item`,a=i.uploadPicCardSize;return{[`${e}-wrapper${e}-picture-card-wrapper`]:{...d.clearFix(),display:"inline-block",width:"100%",[`${e}${e}-select`]:{width:a,height:a,marginInlineEnd:i.marginXS,marginBottom:i.marginXS,textAlign:"center",verticalAlign:"top",backgroundColor:i.colorFillAlter,border:`${i.lineWidth}px dashed ${i.colorBorder}`,borderRadius:i.borderRadiusLG,cursor:"pointer",transition:`border-color ${i.motionDurationSlow}`,[`> ${e}`]:{display:"flex",alignItems:"center",justifyContent:"center",height:"100%",textAlign:"center"},[`&:not(${e}-disabled):hover`]:{borderColor:i.colorPrimary}},[`${t}${t}-picture-card`]:{[`${t}-item-container`]:{display:"inline-block",width:a,height:a,marginBlock:`0 ${i.marginXS}px`,marginInline:`0 ${i.marginXS}px`,verticalAlign:"top"},"&::after":{display:"none"},[r]:{height:"100%",margin:0,"&::before":{position:"absolute",zIndex:1,width:`calc(100% - ${i.paddingXS*2}px)`,height:`calc(100% - ${i.paddingXS*2}px)`,backgroundColor:i.colorBgMask,opacity:0,transition:`all ${i.motionDurationSlow}`,content:'" "'}},[`${r}:hover`]:{[`&::before, ${r}-actions`]:{opacity:1}},[`${r}-actions`]:{position:"absolute",insetInlineStart:0,zIndex:10,width:"100%",whiteSpace:"nowrap",textAlign:"center",opacity:0,transition:`all ${i.motionDurationSlow}`,[`${o}-eye, ${o}-download, ${o}-delete`]:{zIndex:10,width:l,margin:`0 ${i.marginXXS}px`,fontSize:l,cursor:"pointer",transition:`all ${i.motionDurationSlow}`}},[`${r}-actions, ${r}-actions:hover`]:{[`${o}-eye, ${o}-download, ${o}-delete`]:{color:new c.TinyColor(n).setAlpha(.65).toRgbString(),"&:hover":{color:n}}},[`${r}-thumbnail, ${r}-thumbnail img`]:{position:"static",display:"block",width:"100%",height:"100%",objectFit:"contain"},[`${r}-name`]:{display:"none",textAlign:"center"},[`${r}-file + ${r}-name`]:{position:"absolute",bottom:i.margin,display:"block",width:`calc(100% - ${i.paddingXS*2}px)`},[`${r}-uploading`]:{[`&${r}`]:{backgroundColor:i.colorFillAlter},[`&::before, ${o}-eye, ${o}-download, ${o}-delete`]:{display:"none"}},[`${r}-progress`]:{bottom:i.marginXL,width:`calc(100% - ${i.paddingXS*2}px)`,paddingInlineStart:0}}}}};exports.genPictureCardStyle=p;exports.genPictureStyle=s;
