schoolbox web extension :)
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

refactor: fix lint and check errors

willow 7c9536f7 094ff682

+5 -5
+1 -1
src/entrypoints/plugins/homepageSwitcher.ts
··· 2 2 import { definePlugin } from "@/utils/plugin"; 3 3 4 4 let logos: HTMLAnchorElement[] | null = null; 5 - let controller = new AbortController(); 5 + const controller = new AbortController(); 6 6 7 7 export default function init() { 8 8 definePlugin(
+1 -1
src/entrypoints/plugins/scrollPeriod.ts
··· 1 1 import { getCurrentPeriod } from "@/utils/periodUtils"; 2 2 import { definePlugin } from "@/utils/plugin"; 3 3 4 - let controller = new AbortController(); 5 4 let interval: number | null = null; 5 + const controller = new AbortController(); 6 6 7 7 export default function init() { 8 8 definePlugin(
+1
src/entrypoints/start.content.ts
··· 50 50 } 51 51 }; 52 52 53 + // @ts-expect-error unlisted CSS not a PublicPath 53 54 const injectThemes = () => injectStylesheet(browser.runtime.getURL(cssUrl), "themes"); 54 55 const uninjectThemes = () => uninjectStylesheet("themes"); 55 56
+2 -3
src/utils/index.ts
··· 92 92 } 93 93 } 94 94 95 - // eslint-disable-next-line @typescript-eslint/no-explicit-any 96 - export function injectStylesheet(url: any, id: string) { 95 + export function injectStylesheet(url: string, id: string) { 97 96 // check if stylesheet has already been injected 98 97 const existingLink = document.querySelector(dataAttr(`stylesheet-${id}`)); 99 98 if (existingLink) return; ··· 160 159 } 161 160 } 162 161 163 - export function hasChanged<T extends Record<string, unknown>>(newValue: T, oldValue: T, keys: (keyof T)[]) { 162 + export function hasChanged<T>(newValue: T, oldValue: T, keys: (keyof T)[]) { 164 163 const changed: (keyof T)[] = []; 165 164 166 165 for (const key in newValue) {