bunch of misc changes

This commit is contained in:
Sriram Hariharan
2023-11-17 11:11:01 -06:00
parent 52431747ee
commit 56643f9753
11 changed files with 51 additions and 11 deletions

View File

@@ -1,4 +1,5 @@
import React from 'react';
import { background } from 'src/shared/messages';
import render from './lib/react';
import { ContextInvalidated, createShadowDOM, isExtensionPopup, onContextInvalidated } from 'chrome-extension-toolkit';
@@ -14,6 +15,11 @@ if (!support) {
throw new Error('UT Registration Plus does not support this page, even though it should...');
}
// if we are in an iframe, throw an error
if (window.self !== window.top) {
throw new Error('inside an iframe');
}
if (support === SiteSupport.EXTENSION_POPUP) {
render(<PopupMain />, document.getElementById('root'));
}