@ehfuse/overlay-scrollbar 1.7.15 → 1.7.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.esm.js +1 -1
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/types.d.ts +9 -0
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -38,5 +38,5 @@
|
|
|
38
38
|
height: 0 !important;
|
|
39
39
|
}
|
|
40
40
|
${l}::-webkit-scrollbar-track { display: none !important; }
|
|
41
|
-
${l}::-webkit-scrollbar-thumb { display: none !important; }`,document.head.appendChild(r),()=>{document.getElementById(e)?.remove()}},[Q]),(0,y.jsxs)("div",{ref:$e,className:`overlay-scrollbar-wrapper ${d}`,onMouseLeave:It,style:{display:"flex",flexDirection:"column",position:"relative",minHeight:0,height:"100%",flex:"1 1 0%",overflow:"visible",...f},children:[wt&&(0,y.jsx)("div",{className:"overlay-scrollbar-pull-indicator",style:{position:"absolute",top:0,left:"50%",transform:`translate(-50%, ${We-
|
|
41
|
+
${l}::-webkit-scrollbar-thumb { display: none !important; }`,document.head.appendChild(r),()=>{document.getElementById(e)?.remove()}},[Q]),(0,y.jsxs)("div",{ref:$e,className:`overlay-scrollbar-wrapper ${d}`,onMouseLeave:It,style:{display:"flex",flexDirection:"column",position:"relative",minHeight:0,height:"100%",flex:"1 1 0%",overflow:"visible",...f},children:[wt&&(0,y.jsx)("div",{className:"overlay-scrollbar-pull-indicator",style:{position:"absolute",top:0,left:"50%",transform:`translate(-50%, ${We-68}px)`,transition:Te?"transform 0.15s ease-out":We===0?"transform 0.2s ease-out":"none",width:60,height:60,borderRadius:"50%",background:"#ffffff",boxShadow:"0 2px 8px rgba(0, 0, 0, 0.25)",display:"flex",alignItems:"center",justifyContent:"center",zIndex:1001,pointerEvents:"none",opacity:Te?1:Math.min(Oe*1.5,1)},children:Te?(0,y.jsx)("svg",{width:"36",height:"36",viewBox:"0 0 24 24",style:{animation:"overlay-scrollbar-ptr-spin 0.8s linear infinite"},children:(0,y.jsx)("circle",{cx:"12",cy:"12",r:"9",fill:"none",stroke:Ze,strokeWidth:"2.5",strokeLinecap:"round",strokeDasharray:"42",strokeDashoffset:"14"})}):(0,y.jsx)("svg",{width:"36",height:"36",viewBox:"0 0 24 24",style:{transform:`rotate(${Oe*270}deg)`,opacity:Oe>=1?1:.6},children:(0,y.jsx)("path",{d:"M17.65 6.35A7.958 7.958 0 0 0 12 4c-4.42 0-7.99 3.58-7.99 8s3.57 8 7.99 8c3.73 0 6.84-2.55 7.73-6h-2.08A5.99 5.99 0 0 1 12 18c-3.31 0-6-2.69-6-6s2.69-6 6-6c1.66 0 3.14.69 4.22 1.78L13 11h7V4l-2.35 2.35z",fill:Ze})})}),(0,y.jsx)("div",{ref:a,className:`overlay-scrollbar-container ${Q}`,tabIndex:-1,onMouseDown:Ft,style:{display:"flex",width:"100%",flex:"1 1 auto",minHeight:0,overflow:"auto",outline:"none",userSelect:j?"none":"auto",...m},children:(0,y.jsx)("div",{ref:de,className:"overlay-scrollbar-content",style:{flex:"1 1 0%",minHeight:0,display:"flex",flexDirection:"column",boxSizing:"border-box",...u},children:C})}),re&&ne&&(n.overflowY??!0)&&(0,y.jsxs)("div",{ref:fe,className:"overlay-scrollbar-track",onMouseEnter:()=>{w(),J.current=setTimeout(()=>{M(!0),J.current=null},100)},onMouseLeave:()=>{He(),N||v(s.delay)},style:{position:"absolute",top:0,right:0,width:`${R}px`,height:"100%",opacity:Me?1:0,transition:"opacity 0.2s ease-in-out",cursor:"pointer",zIndex:1e3,pointerEvents:"auto"},children:[n.visible&&(0,y.jsx)("div",{className:"overlay-scrollbar-track-background",onClick:e=>{e.preventDefault(),e.stopPropagation(),$t(e)},style:{position:"absolute",top:_?`${E.width+n.margin*2}px`:`${n.margin}px`,right:n.alignment==="outside"?"0px":`${(R-E.width)/2}px`,width:`${E.width}px`,height:_?`calc(100% - ${E.width*2+n.margin*4}px)`:`calc(100% - ${n.margin*2}px)`,backgroundColor:n.color,borderRadius:`${n.radius}px`,cursor:"pointer"}}),(0,y.jsx)("div",{ref:xt,className:"overlay-scrollbar-thumb",onMouseDown:Pt,onMouseEnter:()=>et(!0),onMouseLeave:()=>et(!1),style:{position:"absolute",top:`${(_?x+n.margin*2:n.margin)+Mt}px`,right:n.alignment==="outside"?"0px":`${(R-x)/2}px`,width:`${x}px`,height:`${Math.max(pe,_e)}px`,backgroundColor:Je||N?E.hoverColor:E.color,opacity:Je||N?E.hoverOpacity:E.opacity,borderRadius:`${E.radius}px`,cursor:"pointer",transition:"background-color 0.2s ease-in-out, opacity 0.2s ease-in-out"}})]}),re&&ne&&_&&(0,y.jsx)("div",{className:"overlay-scrollbar-up-arrow",onClick:Wt,onMouseEnter:()=>Se("up"),onMouseLeave:()=>Se(null),style:{position:"absolute",top:`${n.margin}px`,right:n.alignment==="outside"?"0px":`${(R-x)/2}px`,width:`${x}px`,height:`${x}px`,cursor:"pointer",display:"flex",alignItems:"center",justifyContent:"center",fontSize:`${Math.max(x*.75,8)}px`,color:Ee==="up"?z.hoverColor:z.color,userSelect:"none",zIndex:1001,opacity:Me?Ee==="up"?z.hoverOpacity:z.opacity:0,transition:"opacity 0.2s ease-in-out, color 0.15s ease-in-out"},children:"\u25B2"}),re&&ne&&_&&(0,y.jsx)("div",{className:"overlay-scrollbar-down-arrow",onClick:Ot,onMouseEnter:()=>Se("down"),onMouseLeave:()=>Se(null),style:{position:"absolute",bottom:`${n.margin}px`,right:n.alignment==="outside"?"0px":`${(R-x)/2}px`,width:`${x}px`,height:`${x}px`,cursor:"pointer",display:"flex",alignItems:"center",justifyContent:"center",fontSize:`${Math.max(x*.75,8)}px`,color:Ee==="down"?z.hoverColor:z.color,userSelect:"none",zIndex:1001,opacity:Me?Ee==="down"?z.hoverOpacity:z.opacity:0,transition:"opacity 0.2s ease-in-out, color 0.15s ease-in-out"},children:"\u25BC"}),re&&xe&&St&&(n.overflowX??!0)&&(0,y.jsxs)("div",{className:"overlay-scrollbar-horizontal-track",onMouseEnter:()=>{w(),J.current=setTimeout(()=>{M(!0),J.current=null},100)},onMouseLeave:()=>{He(),B||v(s.delay)},style:{position:"absolute",bottom:`${Lt}px`,left:0,width:"100%",height:`${R}px`,opacity:Me?1:0,transition:"opacity 0.2s ease-in-out",cursor:"pointer",zIndex:1e3,pointerEvents:"auto"},children:[n.visible&&(0,y.jsx)("div",{className:"overlay-scrollbar-horizontal-track-background",onClick:e=>{e.preventDefault(),e.stopPropagation(),zt(e)},style:{position:"absolute",bottom:n.alignment==="outside"?"0px":`${(R-x)/2}px`,left:`${n.margin}px`,right:ne?n.alignment==="outside"?`${R-n.margin}px`:`${R}px`:`${n.margin}px`,height:`${x}px`,backgroundColor:n.color,borderRadius:`${n.radius}px`,cursor:"pointer"}}),(0,y.jsx)("div",{className:"overlay-scrollbar-horizontal-thumb",onMouseDown:At,onMouseEnter:()=>nt(!0),onMouseLeave:()=>nt(!1),style:{position:"absolute",bottom:n.alignment==="outside"?"0px":`${(R-x)/2}px`,left:`${n.margin+Be}px`,right:ne?n.alignment==="outside"?`${R-n.margin}px`:`${R}px`:"auto",maxWidth:ne?n.alignment==="outside"?`calc(100% - ${n.margin+Be+R-n.margin}px)`:`calc(100% - ${n.margin+Be+R}px)`:"none",width:`${Math.max(Ne,50)}px`,height:`${x}px`,backgroundColor:rt||B?E.hoverColor:E.color,opacity:rt||B?E.hoverOpacity:E.opacity,borderRadius:`${E.radius}px`,cursor:"pointer",transition:"background-color 0.2s ease-in-out, opacity 0.2s ease-in-out"}})]}),q&&(0,y.jsx)("button",{type:"button","aria-label":"\uB9E8 \uC704\uB85C",onClick:()=>a.current?.scrollTo({top:0,behavior:"smooth"}),style:{position:"absolute",[Ie]:ue,bottom:ue,zIndex:1200,width:we,height:we,padding:0,display:"flex",alignItems:"center",justifyContent:"center",border:"none",borderRadius:"50%",backgroundColor:bt,color:gt,boxShadow:"0 3px 8px rgba(15, 23, 42, 0.28)",cursor:"pointer",opacity:Pe?1:0,transform:Pe?"translateY(0) scale(1)":"translateY(8px) scale(0.9)",pointerEvents:Pe?"auto":"none",transition:"opacity 0.2s ease, transform 0.2s ease"},children:(0,y.jsx)("svg",{width:Math.round(we*.5),height:Math.round(we*.5),viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2.4",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:(0,y.jsx)("polyline",{points:"18 15 12 9 6 15"})})})]})}),Ve=oo;
|
|
42
42
|
//# sourceMappingURL=index.js.map
|