+18
-16
lines changedFilter options
+18
-16
lines changed Original file line number Diff line number Diff line change
@@ -448,8 +448,9 @@ body.colorBlind #netFilteringDialog > .panes > .details > div[data-status="2"] b
448
448
background: white;
449
449
border: 1px solid gray;
450
450
bottom: 0;
451
-
box-sizing: border-box;
452
451
display: none;
452
+
max-height: 70vh;
453
+
min-width: 360px;
453
454
overflow: hidden;
454
455
position: fixed;
455
456
right: 0;
Original file line number Diff line number Diff line change
@@ -2323,7 +2323,7 @@ const popupManager = (( ) => {
2323
2323
2324
2324
const setTabId = function(tabId) {
2325
2325
if ( popup === null ) { return; }
2326
-
popup.setAttribute('src', 'popup.html?tabId=' + tabId);
2326
+
popup.setAttribute('src', 'popup-fenix.html?portrait=1&tabId=' + tabId);
2327
2327
};
2328
2328
2329
2329
const onTabIdChanged = function() {
Original file line number Diff line number Diff line change
@@ -1206,18 +1206,13 @@ const getPopupData = async function(tabId) {
1206
1206
/******************************************************************************/
1207
1207
1208
1208
// Popup DOM is assumed to be loaded at this point -- because this script
1209
-
// is loaded after everything else..
1209
+
// is loaded after everything else.
1210
1210
1211
1211
{
1212
-
// If there's no tab id specified in the query string,
1213
-
// it will default to current tab.
1214
-
let tabId = null;
1215
-
1216
-
// Extract the tab id of the page this popup is for
1217
-
const matches = self.location.search.match(/[\?&]tabId=([^&]+)/);
1218
-
if ( matches && matches.length === 2 ) {
1219
-
tabId = parseInt(matches[1], 10) || 0;
1220
-
}
1212
+
// Extract the tab id of the page for this popup. If there's no tab id
1213
+
// specified in the query string, it will default to current tab.
1214
+
const selfURL = new URL(self.location.href);
1215
+
const tabId = parseInt(selfURL.searchParams.get('tabId'), 10) || null;
1221
1216
1222
1217
const nextFrames = async n => {
1223
1218
for ( let i = 0; i < n; i++ ) {
@@ -1240,16 +1235,22 @@ const getPopupData = async function(tabId) {
1240
1235
// when testing against viewport width.
1241
1236
const checkViewport = async function() {
1242
1237
const root = document.querySelector(':root');
1243
-
if ( root.classList.contains('desktop') ) {
1238
+
if (
1239
+
root.classList.contains('mobile') ||
1240
+
selfURL.searchParams.get('portrait')
1241
+
) {
1242
+
root.classList.add('portrait');
1243
+
} else if ( root.classList.contains('desktop') ) {
1244
1244
await nextFrames(4);
1245
1245
const main = document.getElementById('main');
1246
1246
const firewall = document.getElementById('firewall');
1247
1247
const minWidth = (main.offsetWidth + firewall.offsetWidth) / 1.1;
1248
-
if ( window.innerWidth < minWidth ) {
1248
+
if (
1249
+
selfURL.searchParams.get('portrait') ||
1250
+
window.innerWidth < minWidth
1251
+
) {
1249
1252
root.classList.add('portrait');
1250
1253
}
1251
-
} else if ( root.classList.contains('mobile') ) {
1252
-
root.classList.add('portrait');
1253
1254
}
1254
1255
if ( root.classList.contains('portrait') ) {
1255
1256
const panes = document.getElementById('panes');
You can’t perform that action at this time.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4