diff --git a/src/controllers/popupController.js b/src/controllers/popupController.js deleted file mode 100644 index d844daf..0000000 --- a/src/controllers/popupController.js +++ /dev/null @@ -1,24 +0,0 @@ -/*Canopy - The next generation of stoner streaming software -Copyright (C) 2024-2025 Rainbownapkin and the TTN Community - -This program is free software: you can redistribute it and/or modify -it under the terms of the GNU Affero General Public License as -published by the Free Software Foundation, either version 3 of the -License, or (at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Affero General Public License for more details. - -You should have received a copy of the GNU Affero General Public License -along with this program. If not, see .*/ - -//root index functions -module.exports.get = async function(req, res){ - try{ - res.render(`partial/popup${req.url}`, {}); - }catch(err){ - return res.sendStatus(400); - } -} \ No newline at end of file diff --git a/src/routers/popupRouter.js b/src/routers/popupRouter.js deleted file mode 100644 index 55f3ba7..0000000 --- a/src/routers/popupRouter.js +++ /dev/null @@ -1,30 +0,0 @@ -/*Canopy - The next generation of stoner streaming software -Copyright (C) 2024-2025 Rainbownapkin and the TTN Community - -This program is free software: you can redistribute it and/or modify -it under the terms of the GNU Affero General Public License as -published by the Free Software Foundation, either version 3 of the -License, or (at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Affero General Public License for more details. - -You should have received a copy of the GNU Affero General Public License -along with this program. If not, see .*/ - -//npm imports -const { Router } = require('express'); - - -//local imports -const popupController = require("../controllers/popupController"); - -//globals -const router = Router(); - -//routing functions -router.get('/*', popupController.get); - -module.exports = router; diff --git a/src/server.js b/src/server.js index fdd9393..11f6c5f 100644 --- a/src/server.js +++ b/src/server.js @@ -58,7 +58,7 @@ const emailChangeRouter = require('./routers/emailChangeController'); //Panel const panelRouter = require('./routers/panelRouter'); //Popup -const popupRouter = require('./routers/popupRouter'); +//const popupRouter = require('./routers/popupRouter'); //Tooltip const tooltipRouter = require('./routers/tooltipRouter'); //Api @@ -161,7 +161,7 @@ app.use('/emailChange', emailChangeRouter); //Panel app.use('/panel', panelRouter); //Popup -app.use('/popup', popupRouter); +//app.use('/popup', popupRouter); //tooltip app.use('/tooltip', tooltipRouter); //Bot-Ready diff --git a/www/js/channel/panels/queuePanel/queuePanel.js b/www/js/channel/panels/queuePanel/queuePanel.js index 6372fca..0adb6da 100644 --- a/www/js/channel/panels/queuePanel/queuePanel.js +++ b/www/js/channel/panels/queuePanel/queuePanel.js @@ -603,7 +603,7 @@ class queuePanel extends panelObj{ //Create entry title const entryTitle = document.createElement('p'); - entryTitle.textContent = entry[1].title; + entryTitle.textContent = utils.unescapeEntities(entry[1].title); //Tooltip generation //tooltip div diff --git a/www/js/utils.js b/www/js/utils.js index 7191c1b..24da23d 100644 --- a/www/js/utils.js +++ b/www/js/utils.js @@ -1028,7 +1028,7 @@ class canopyAjaxUtils{ //Popup async getPopup(popup){ - var response = await fetch(`/popup/${popup}`,{ + var response = await fetch(`/popup/${popup}.html`,{ method: "GET" }); diff --git a/src/views/partial/popup/addToPlaylist.ejs b/www/popup/addToPlaylist.html similarity index 85% rename from src/views/partial/popup/addToPlaylist.ejs rename to www/popup/addToPlaylist.html index 8c875c3..e6a748f 100644 --- a/src/views/partial/popup/addToPlaylist.ejs +++ b/www/popup/addToPlaylist.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software + +
diff --git a/src/views/partial/popup/changeEmail.ejs b/www/popup/changeEmail.html similarity index 93% rename from src/views/partial/popup/changeEmail.ejs rename to www/popup/changeEmail.html index 6aaa253..74e9930 100644 --- a/src/views/partial/popup/changeEmail.ejs +++ b/www/popup/changeEmail.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software +
diff --git a/src/views/partial/popup/changePassword.ejs b/www/popup/changePassword.html similarity index 94% rename from src/views/partial/popup/changePassword.ejs rename to www/popup/changePassword.html index b726362..d3777b4 100644 --- a/src/views/partial/popup/changePassword.ejs +++ b/www/popup/changePassword.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software +
diff --git a/src/views/partial/popup/channelUserBan.ejs b/www/popup/channelUserBan.html similarity index 88% rename from src/views/partial/popup/channelUserBan.ejs rename to www/popup/channelUserBan.html index 039e972..f54a077 100644 --- a/src/views/partial/popup/channelUserBan.ejs +++ b/www/popup/channelUserBan.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software + +
diff --git a/src/views/partial/popup/clearMedia.ejs b/www/popup/clearMedia.html similarity index 94% rename from src/views/partial/popup/clearMedia.ejs rename to www/popup/clearMedia.html index 0b331cf..33c0592 100644 --- a/src/views/partial/popup/clearMedia.ejs +++ b/www/popup/clearMedia.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software +
diff --git a/src/views/partial/popup/newPlaylist.ejs b/www/popup/newPlaylist.html similarity index 94% rename from src/views/partial/popup/newPlaylist.ejs rename to www/popup/newPlaylist.html index d20f32f..14e4df5 100644 --- a/src/views/partial/popup/newPlaylist.ejs +++ b/www/popup/newPlaylist.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software +
diff --git a/src/views/partial/popup/nukeChannel.ejs b/www/popup/nukeChannel.html similarity index 93% rename from src/views/partial/popup/nukeChannel.ejs rename to www/popup/nukeChannel.html index 548081c..486e462 100644 --- a/src/views/partial/popup/nukeChannel.ejs +++ b/www/popup/nukeChannel.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software +
diff --git a/src/views/partial/popup/nukeUser.ejs b/www/popup/nukeUser.html similarity index 93% rename from src/views/partial/popup/nukeUser.ejs rename to www/popup/nukeUser.html index e332732..46eaa24 100644 --- a/src/views/partial/popup/nukeUser.ejs +++ b/www/popup/nukeUser.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software +
diff --git a/src/views/partial/popup/placeholder.ejs b/www/popup/placeholder.html similarity index 86% rename from src/views/partial/popup/placeholder.ejs rename to www/popup/placeholder.html index 67aa05d..64d79d2 100644 --- a/src/views/partial/popup/placeholder.ejs +++ b/www/popup/placeholder.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software +

This is a test popup!

\ No newline at end of file diff --git a/src/views/partial/popup/playlistDefaultTitles.ejs b/www/popup/playlistDefaultTitles.html similarity index 92% rename from src/views/partial/popup/playlistDefaultTitles.ejs rename to www/popup/playlistDefaultTitles.html index 087df4e..eb2011e 100644 --- a/src/views/partial/popup/playlistDefaultTitles.ejs +++ b/www/popup/playlistDefaultTitles.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software +
diff --git a/src/views/partial/popup/renamePlaylist.ejs b/www/popup/renamePlaylist.html similarity index 84% rename from src/views/partial/popup/renamePlaylist.ejs rename to www/popup/renamePlaylist.html index de5e2f7..1c4190a 100644 --- a/src/views/partial/popup/renamePlaylist.ejs +++ b/www/popup/renamePlaylist.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software + +
diff --git a/src/views/partial/popup/scheduleMedia.ejs b/www/popup/scheduleMedia.html similarity index 84% rename from src/views/partial/popup/scheduleMedia.ejs rename to www/popup/scheduleMedia.html index 3f83583..cb20cdd 100644 --- a/src/views/partial/popup/scheduleMedia.ejs +++ b/www/popup/scheduleMedia.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software + +
diff --git a/src/views/partial/popup/userBan.ejs b/www/popup/userBan.html similarity index 95% rename from src/views/partial/popup/userBan.ejs rename to www/popup/userBan.html index b3c91c4..4654fb0 100644 --- a/src/views/partial/popup/userBan.ejs +++ b/www/popup/userBan.html @@ -1,4 +1,4 @@ -<%# Canopy - The next generation of stoner streaming software +