Skip to content

Commit

Permalink
Fixed eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
SebiWrn committed Jan 23, 2024
1 parent 10ed413 commit 392abb9
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
4 changes: 1 addition & 3 deletions web/ts/TUMLiveVjs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { loadAndSetTrackbars } from "./track-bars";

import { handleHotkeys } from "./hotkeys";
import dom = videojs.dom;
import {Event} from "video.js/dist/types/event-target";
import { Event } from "video.js/dist/types/event-target";

require("videojs-seek-buttons");
require("videojs-sprite-thumbnails");
Expand Down Expand Up @@ -255,7 +255,6 @@ export class SkipSilenceButton extends CustomButton {
buildCSSClass(): string {
return `vjs-skip-silence-control`;
}

}

// Should be changed when videojs fully supports typescript, but for now this works as a fix
Expand Down Expand Up @@ -318,7 +317,6 @@ export const skipSilence = function (options) {
}
};


/**
* @function watchProgress
* Saves and retrieves the watch progress of the user as a fraction of the total watch time
Expand Down
4 changes: 3 additions & 1 deletion web/ts/hotkeys.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import videojs from "video.js";
import KeyboardEvent from "video.js/dist/types/utils/events"
import Button from "video.js/dist/types/button";
import KeyboardEvent from "video.js/dist/types/utils/events";

// VideoJS uses `import * as keycode from "keycode";`
// However, keycode uses deprecated event.keyCode https://github.com/timoxley/keycode/issues/52
Expand Down Expand Up @@ -31,6 +32,7 @@ const matches = (match, player, event) =>
const getIcon = (icon, player, event) => (typeof icon === "function" ? icon(player, event) : icon);

const handleWithClick = (name) => (player, event) => {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const ButtonComponent = videojs.getComponent(name) as any;
ButtonComponent.prototype.handleClick.call(player, event);
};
Expand Down
2 changes: 1 addition & 1 deletion web/ts/stream-playlist.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export class StreamPlaylist {
}

public scrollSelectedIntoView() {
if(this.elem.querySelector(".--selected")) {
if (this.elem.querySelector(".--selected")) {
this.elem.querySelector(".--selected").scrollIntoView({ block: "center" });
}
}
Expand Down
2 changes: 1 addition & 1 deletion web/ts/video/watchers.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Player from "video.js/dist/types/player";
import Player from "video.js/dist/types/player";

/**
* Registers a time watcher that observes the time of the current player
Expand Down

0 comments on commit 392abb9

Please sign in to comment.