import{resetComponent as e,textEllipsis as t}from"../../style/index.mjs";import n from"../../theme/util/genComponentStyleHook.mjs";import{genActiveStyle as r,genBasicInputStyle as i,genDisabledStyle as a,genPlaceholderStyle as o,genStatusStyle as s,initInputToken as c}from"../../input/style/index.mjs";var l=n=>{let{componentCls:c,colorTextDisabled:l,controlItemBgHover:u,controlPaddingHorizontal:d,colorText:f,motionDurationSlow:p,lineHeight:m,controlHeight:h,inputPaddingHorizontal:g,inputPaddingVertical:_,fontSize:v,colorBgElevated:y,borderRadiusLG:b,boxShadowSecondary:x}=n,S=Math.round((n.controlHeight-n.fontSize*n.lineHeight)/2);return{[c]:{...e(n),...i(n),position:`relative`,display:`inline-block`,height:`auto`,padding:0,overflow:`hidden`,lineHeight:m,whiteSpace:`pre-wrap`,verticalAlign:`bottom`,...s(n,c),"&-disabled":{"> textarea":{...a(n)}},"&-focused":{...r(n)},[`&-affix-wrapper ${c}-suffix`]:{position:`absolute`,top:0,insetInlineEnd:g,bottom:0,zIndex:1,display:`inline-flex`,alignItems:`center`,margin:`auto`},[`> textarea, ${c}-measure`]:{color:f,boxSizing:`border-box`,minHeight:h-2,margin:0,padding:`${_}px ${g}px`,overflow:`inherit`,overflowX:`hidden`,overflowY:`auto`,fontWeight:`inherit`,fontSize:`inherit`,fontFamily:`inherit`,fontStyle:`inherit`,fontVariant:`inherit`,fontSizeAdjust:`inherit`,fontStretch:`inherit`,lineHeight:`inherit`,direction:`inherit`,letterSpacing:`inherit`,whiteSpace:`inherit`,textAlign:`inherit`,verticalAlign:`top`,wordWrap:`break-word`,wordBreak:`inherit`,tabSize:`inherit`},"> textarea":{width:`100%`,border:`none`,outline:`none`,resize:`none`,backgroundColor:`inherit`,...o(n.colorTextPlaceholder)},[`${c}-measure`]:{position:`absolute`,top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,zIndex:-1,color:`transparent`,pointerEvents:`none`,"> span":{display:`inline-block`,minHeight:`1em`}},"&-dropdown":{...e(n),position:`absolute`,top:-9999,insetInlineStart:-9999,zIndex:n.zIndexPopup,boxSizing:`border-box`,fontSize:v,fontVariant:`initial`,backgroundColor:y,borderRadius:b,outline:`none`,boxShadow:x,"&-hidden":{display:`none`},[`${c}-dropdown-menu`]:{maxHeight:n.dropdownHeight,marginBottom:0,paddingInlineStart:0,overflow:`auto`,listStyle:`none`,outline:`none`,"&-item":{...t,position:`relative`,display:`block`,minWidth:n.controlItemWidth,padding:`${S}px ${d}px`,color:f,fontWeight:`normal`,lineHeight:m,cursor:`pointer`,transition:`background ${p} ease`,"&:hover":{backgroundColor:u},"&:first-child":{borderStartStartRadius:b,borderStartEndRadius:b,borderEndStartRadius:0,borderEndEndRadius:0},"&:last-child":{borderStartStartRadius:0,borderStartEndRadius:0,borderEndStartRadius:b,borderEndEndRadius:b},"&-disabled":{color:l,cursor:`not-allowed`,"&:hover":{color:l,backgroundColor:u,cursor:`not-allowed`}},"&-selected":{color:f,fontWeight:n.fontWeightStrong,backgroundColor:u},"&-active":{backgroundColor:u}}}}}}},u=n(`Mentions`,e=>[l(c(e))],e=>({dropdownHeight:250,controlItemWidth:100,zIndexPopup:e.zIndexPopupBase+50}));export{u as default};