|
@@ -792,6 +792,7 @@ export function init() {
|
|
|
console.log('init')
|
|
|
|
|
|
getDiscordAuthCode();
|
|
|
+ appendPopupPage();
|
|
|
|
|
|
let where = window.location.href.indexOf('twitter.com') < 0 && window.location.href.indexOf('facebook.com') < 0;
|
|
|
if (where) {
|
|
@@ -1350,6 +1351,26 @@ export const showPopupPage = (params = {}) => {
|
|
|
let overlay = document.getElementById('de-popup-overlay');
|
|
|
overlay.style.display = 'block';
|
|
|
|
|
|
+ let htmlDom = document.querySelector('html');
|
|
|
+ if(htmlDom) {
|
|
|
+ htmlDom.style.overflowY = 'hidden';
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ appendPopupPage();
|
|
|
+ iframe = document.getElementById('de-popup-page');
|
|
|
+ if(path) {
|
|
|
+ iframe.src = chrome.runtime.getURL('/iframe/popup-page.html') + `#${path}`;
|
|
|
+ }
|
|
|
+ iframe.style.transform = 'translateX(-' + 395 + 'px)';
|
|
|
+
|
|
|
+ chrome.runtime.sendMessage({
|
|
|
+ actionType: "CONTENT_POPUP_PAGE_SHOW",
|
|
|
+ data: { }
|
|
|
+ }, () => { });
|
|
|
+
|
|
|
+ let overlay = document.getElementById('de-popup-overlay');
|
|
|
+ overlay.style.display = 'block';
|
|
|
+
|
|
|
let htmlDom = document.querySelector('html');
|
|
|
if(htmlDom) {
|
|
|
htmlDom.style.overflowY = 'hidden';
|