aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/utils/pageUtils.ts
diff options
context:
space:
mode:
authorAjay <[email protected]>2022-12-24 00:54:56 -0500
committerAjay <[email protected]>2022-12-24 00:54:56 -0500
commit7dd2c9eb3e4af690024319f32a075fef90bb2d88 (patch)
tree77a3a04d46ae3ed04ace804945a9f6ca3fe7152f /src/utils/pageUtils.ts
parent7bf17e17461a1d8b3958cb0d9cda223808ebaadd (diff)
downloadSponsorBlock-7dd2c9eb3e4af690024319f32a075fef90bb2d88.tar.gz
SponsorBlock-7dd2c9eb3e4af690024319f32a075fef90bb2d88.zip
Move some generic functions to a new package
Diffstat (limited to 'src/utils/pageUtils.ts')
-rw-r--r--src/utils/pageUtils.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/utils/pageUtils.ts b/src/utils/pageUtils.ts
index 42766fef..beda1585 100644
--- a/src/utils/pageUtils.ts
+++ b/src/utils/pageUtils.ts
@@ -1,5 +1,5 @@
import { ActionType, Category, SponsorSourceType, SponsorTime, VideoID } from "../types";
-import { GenericUtils } from "./genericUtils";
+import { getFormattedTimeToSeconds } from "@ajayyy/maze-utils/lib/formating";
export function getControls(): HTMLElement {
const controlsSelectors = [
@@ -80,7 +80,7 @@ export function getExistingChapters(currentVideoID: VideoID, duration: number):
const timeElement = link.querySelector("#time") as HTMLElement;
const description = link.querySelector("#details h4") as HTMLElement;
if (timeElement && description?.innerText?.length > 0 && link.getAttribute("href")?.includes(currentVideoID)) {
- const time = GenericUtils.getFormattedTimeToSeconds(timeElement.innerText);
+ const time = getFormattedTimeToSeconds(timeElement.innerText);
if (time === null) return [];
if (lastSegment) {