import{isInRange as H}from"../utils/dateUtil.mjs";import{getValue as p}from"../utils/miscUtil.mjs";function M({cellPrefixCls:n,generateConfig:$,rangedValue:b,hoverRangedValue:j,isInView:R,isSameCell:g,offsetCell:k,today:F,value:G}){function J(o){const t=k(o,-1),d=k(o,1),r=p(b,0),h=p(b,1),a=p(j,0),v=p(j,1),N=H($,a,v,o);function E(y){return g(r,y)}function s(y){return g(h,y)}const q=g(a,o),z=g(v,o),A=(N||z)&&(!R(t)||s(t)),B=(N||q)&&(!R(d)||E(d));return{[`${n}-in-view`]:R(o),[`${n}-in-range`]:H($,r,h,o),[`${n}-range-start`]:E(o),[`${n}-range-end`]:s(o),[`${n}-range-start-single`]:E(o)&&!h,[`${n}-range-end-single`]:s(o)&&!r,[`${n}-range-start-near-hover`]:E(o)&&(g(t,a)||H($,a,v,t)),[`${n}-range-end-near-hover`]:s(o)&&(g(d,v)||H($,a,v,d)),[`${n}-range-hover`]:N,[`${n}-range-hover-start`]:q,[`${n}-range-hover-end`]:z,[`${n}-range-hover-edge-start`]:A,[`${n}-range-hover-edge-end`]:B,[`${n}-range-hover-edge-start-near-range`]:A&&g(t,h),[`${n}-range-hover-edge-end-near-range`]:B&&g(d,r),[`${n}-today`]:g(F,o),[`${n}-selected`]:g(G,o)}}return J}export{M as default};
