diff --git a/src/views/index.tsx b/src/views/index.tsx index 3cfe9717..55085876 100644 --- a/src/views/index.tsx +++ b/src/views/index.tsx @@ -7,6 +7,7 @@ import getSiteSupport, { SiteSupport } from './lib/getSiteSupport'; import PopupMain from './components/PopupMain'; const support = getSiteSupport(window.location.href); +console.log('support:', support); if (!support) { throw new Error('UT Registration Plus does not support this page, even though it should...'); diff --git a/src/views/lib/getSiteSupport.ts b/src/views/lib/getSiteSupport.ts index 9f5e0522..74154a0a 100644 --- a/src/views/lib/getSiteSupport.ts +++ b/src/views/lib/getSiteSupport.ts @@ -22,7 +22,7 @@ export default function getSiteSupport(url: string): SiteSupport | null { if (isExtensionPopup()) { return SiteSupport.EXTENSION_POPUP; } - if (isExtensionPage('MyCalendar.html')) { + if (isExtensionPage('my_calendar.html')) { return SiteSupport.MY_CALENDAR; } if (url.includes('utexas.collegescheduler.com')) { diff --git a/webpack/webpack.config.ts b/webpack/webpack.config.ts index 4221b9a0..90cf5bed 100644 --- a/webpack/webpack.config.ts +++ b/webpack/webpack.config.ts @@ -9,7 +9,7 @@ export interface Entries { content: string[]; background: string[]; popup: string[]; - myCalendar: string[]; + my_calendar: string[]; // only used in development debug?: string[]; } @@ -29,12 +29,12 @@ export default function config(mode: Environment, manifest: chrome.runtime.Manif const entry: Entries = { content: [path.resolve('src', 'views')], popup: [path.resolve('src', 'views')], - myCalendar: [path.resolve('src', 'views')], + my_calendar: [path.resolve('src', 'views')], background: [path.resolve('src', 'background', 'background')], }; // the entries that need an html file to be generated - const htmlEntries: EntryId[] = ['popup', 'myCalendar']; + const htmlEntries: EntryId[] = ['popup', 'my_calendar']; if (mode === 'development') { // create an html file for the debug entry @@ -45,7 +45,7 @@ export default function config(mode: Environment, manifest: chrome.runtime.Manif // we need to import react-devtools before the react code in development so that it can hook into react entry.content = [path.resolve('src', 'debug', 'reactDevtools'), ...entry.content]; entry.popup = [path.resolve('src', 'debug', 'reactDevtools'), ...entry.popup]; - entry.myCalendar = [path.resolve('src', 'debug', 'reactDevtools'), ...entry.myCalendar]; + entry.my_calendar = [path.resolve('src', 'debug', 'reactDevtools'), ...entry.my_calendar]; } /** @see https://webpack.js.org/configuration for documentation */