Fix all clippy lint errors

This commit is contained in:
Keavon Chambers
2021-12-30 23:05:54 -08:00
parent 401bba878a
commit 5a184a179c
18 changed files with 123 additions and 140 deletions
@@ -114,7 +114,7 @@ import { defineComponent, PropType } from "vue";
const lerp = (x: number, y: number, a: number) => x * (1 - a) + y * a;
// Convert the position of the handle (0-1) to the position on the track (0-1).
// This includes the 1/2 handle length gap of the possible handle positionson each side so the end of the handle doesn't go off the track.
// This includes the 1/2 handle length gap of the possible handle positionson each side so the end of the handle doesn't go off the track.
const handleToTrack = (handleLen: number, handlePos: number) => lerp(handleLen / 2, 1 - handleLen / 2, handlePos);
const pointerPosition = (direction: ScrollbarDirection, e: PointerEvent) => (direction === ScrollbarDirection.Vertical ? e.clientY : e.clientX);