[O] Prevent scroll event propagation
This commit is contained in:
@@ -7,6 +7,7 @@ A cute, feature-rich file listing module to replace nginx's autoindex / fancyind
|
||||
|
||||
* [x] List files
|
||||
* [x] Show file icons
|
||||
* [x] Clickable, length-safe breadcrumb path
|
||||
|
||||
**TODO**
|
||||
|
||||
|
||||
@@ -57,6 +57,9 @@ export default function App() {
|
||||
// Handle wheel for breadcrumb
|
||||
function wheel(e: WheelEvent)
|
||||
{
|
||||
e.preventDefault()
|
||||
e.stopPropagation()
|
||||
|
||||
let direction = (e.detail < 0 || e.deltaY > 0) ? 1 : -1
|
||||
setBcLeft(clamp(bcLeft() + direction * 20, 0, bcMax))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user