Bug 1881094 - 4. remove and revise prettier exclusions for firefox-android r=android-reviewers,frontend-codestyle-reviewers,gl,webcompat-reviewers,twisniewski

- remove the firefox-android exclusions from .prettierignore
 - add a few specific exclusions to .prettierignore for files with existing errors
 - add a few specific entries to Generated.txt and ThirdPartyPaths.txt
 - add `initial_experiments.json` to the list of generated files: these are updated from Nimbus
 - run `mach lint --fix --linter=eslint -- mobile/android` to generate all the formatting changes

Differential Revision: https://phabricator.services.mozilla.com/D206915
This commit is contained in:
Geoff Brown 2024-05-07 20:24:38 +00:00
parent 9857880129
commit 6356370a37
89 changed files with 19328 additions and 27178 deletions

View file

@ -905,7 +905,12 @@ layout/style/test/test_mql_event_listener_leaks.html
layout/style/test/test_pointer-events.html layout/style/test/test_pointer-events.html
layout/style/test/test_reframe_image_loading.html layout/style/test/test_reframe_image_loading.html
layout/tables/test/test_bug337124.html layout/tables/test/test_bug337124.html
mobile/android/android-components/docs/_includes/footer.html
mobile/android/android-components/docs/_includes/head.html
mobile/android/android-components/docs/_layouts/home.html
mobile/android/components/extensions/test/mochitest/file_dummy.html mobile/android/components/extensions/test/mochitest/file_dummy.html
mobile/android/fenix/app/src/androidTest/assets/pages/htmlControls.html
mobile/android/fenix/app/src/androidTest/assets/pages/trackingPage.html
mobile/android/geckoview/src/androidTest/assets/www/accessibility/test-headings.html mobile/android/geckoview/src/androidTest/assets/www/accessibility/test-headings.html
mobile/android/geckoview/src/androidTest/assets/www/autoplay.html mobile/android/geckoview/src/androidTest/assets/www/autoplay.html
mobile/android/geckoview/src/androidTest/assets/www/badVideoPath.html mobile/android/geckoview/src/androidTest/assets/www/badVideoPath.html
@ -1149,14 +1154,6 @@ mobile/android/docs/geckoview/assets/js/search-data.json
# Uses `#filter substitution` # Uses `#filter substitution`
mobile/android/app/geckoview-prefs.js mobile/android/app/geckoview-prefs.js
# TODO - Bug 1881094: temporarily ignored for firefox-android migration
mobile/android/android-components/
mobile/android/fenix/
mobile/android/focus-android/
mobile/android/docs/_includes/
mobile/android/docs/_layouts/
mobile/android/docs/assets/js/icon-js.js
# Not much JS to lint and non-standard at that # Not much JS to lint and non-standard at that
mobile/android/installer/ mobile/android/installer/
mobile/android/locales/ mobile/android/locales/
@ -1385,6 +1382,9 @@ media/openmax_il/
media/webrtc/signaling/gtest/MockCall.h media/webrtc/signaling/gtest/MockCall.h
mfbt/double-conversion/double-conversion/ mfbt/double-conversion/double-conversion/
mfbt/lz4/.* mfbt/lz4/.*
mobile/android/android-components/components/feature/readerview/src/main/assets/extensions/readerview/readability/JSDOMParser-0.4.2.js
mobile/android/android-components/components/feature/readerview/src/main/assets/extensions/readerview/readability/readability-0.4.2.js
mobile/android/android-components/components/feature/readerview/src/main/assets/extensions/readerview/readability/readability-readerable-0.4.2.js
mobile/android/exoplayer2/ mobile/android/exoplayer2/
modules/brotli/ modules/brotli/
modules/fdlibm/ modules/fdlibm/
@ -1484,8 +1484,6 @@ dom/tests/ajax/mochikit/
intl/components/src/UnicodeScriptCodes.h intl/components/src/UnicodeScriptCodes.h
intl/unicharutil/util/nsSpecialCasingData.cpp intl/unicharutil/util/nsSpecialCasingData.cpp
intl/unicharutil/util/nsUnicodePropertyData.cpp intl/unicharutil/util/nsUnicodePropertyData.cpp
mobile/locales/l10n-changesets.json
mobile/locales/l10n-onchange-changesets.json
mobile/android/**/.build-cache mobile/android/**/.build-cache
mobile/android/**/.gradle mobile/android/**/.gradle
mobile/android/**/build mobile/android/**/build
@ -1493,6 +1491,12 @@ mobile/android/**/bin
mobile/android/**/generated mobile/android/**/generated
mobile/android/**\/local.properties mobile/android/**\/local.properties
mobile/android/**\/manifest.json mobile/android/**\/manifest.json
mobile/android/android-components/components/feature/search/src/main/assets/search/search_telemetry_v2.json
mobile/android/android-components/samples/glean/src/main/res/raw/initial_experiments.json
mobile/android/fenix/app/src/debug/res/raw/initial_experiments.json
mobile/android/fenix/app/src/main/res/raw/initial_experiments.json
mobile/locales/l10n-changesets.json
mobile/locales/l10n-onchange-changesets.json
node_modules/ node_modules/
python/mozperftest/mozperftest/tests/data/ python/mozperftest/mozperftest/tests/data/
security/manager/tools/KnownRootHashes.json security/manager/tools/KnownRootHashes.json

View file

@ -6,37 +6,41 @@
* Handles the parsing of the ErrorPages URI and then passes them to injectValues * Handles the parsing of the ErrorPages URI and then passes them to injectValues
*/ */
function parseQuery(queryString) { function parseQuery(queryString) {
if (queryString[0] === '?') { if (queryString[0] === "?") {
queryString = queryString.substr(1); queryString = queryString.substr(1);
} }
const query = Object.fromEntries(new URLSearchParams(queryString).entries()); const query = Object.fromEntries(new URLSearchParams(queryString).entries());
injectValues(query) injectValues(query);
updateShowSSL(query) updateShowSSL(query);
updateShowHSTS(query) updateShowHSTS(query);
}; }
/** /**
* Updates the HTML elements based on the queryMap * Updates the HTML elements based on the queryMap
*/ */
function injectValues(queryMap) { function injectValues(queryMap) {
const tryAgainButton = document.getElementById('errorTryAgain') const tryAgainButton = document.getElementById("errorTryAgain");
const continueHttpButton = document.getElementById("continueHttp") const continueHttpButton = document.getElementById("continueHttp");
// Go through each element and inject the values // Go through each element and inject the values
document.title = queryMap.title document.title = queryMap.title;
tryAgainButton.innerHTML = queryMap.button tryAgainButton.innerHTML = queryMap.button;
continueHttpButton.innerHTML = queryMap.continueHttpButton continueHttpButton.innerHTML = queryMap.continueHttpButton;
document.getElementById('errorTitleText').innerHTML = queryMap.title document.getElementById("errorTitleText").innerHTML = queryMap.title;
document.getElementById('errorShortDesc').innerHTML = queryMap.description document.getElementById("errorShortDesc").innerHTML = queryMap.description;
document.getElementById('advancedButton').innerHTML = queryMap.badCertAdvanced document.getElementById("advancedButton").innerHTML =
document.getElementById('badCertTechnicalInfo').innerHTML = queryMap.badCertTechInfo queryMap.badCertAdvanced;
document.getElementById('advancedPanelBackButton').innerHTML = queryMap.badCertGoBack document.getElementById("badCertTechnicalInfo").innerHTML =
document.getElementById('advancedPanelAcceptButton').innerHTML = queryMap.badCertAcceptTemporary queryMap.badCertTechInfo;
document.getElementById('advancedPanelAcceptButton').s = queryMap.badCertAcceptTemporary document.getElementById("advancedPanelBackButton").innerHTML =
queryMap.badCertGoBack;
document.getElementById("advancedPanelAcceptButton").innerHTML =
queryMap.badCertAcceptTemporary;
document.getElementById("advancedPanelAcceptButton").s =
queryMap.badCertAcceptTemporary;
// If no image is passed in, remove the element so as not to leave an empty iframe // If no image is passed in, remove the element so as not to leave an empty iframe
const errorImage = document.getElementById('errorImage'); const errorImage = document.getElementById("errorImage");
if (!queryMap.image) { if (!queryMap.image) {
errorImage.remove(); errorImage.remove();
} else { } else {
@ -46,9 +50,9 @@ function injectValues(queryMap) {
if (queryMap.showContinueHttp === "true") { if (queryMap.showContinueHttp === "true") {
// On the "HTTPS-Only" error page "Try again" doesn't make sense since reloading the page // On the "HTTPS-Only" error page "Try again" doesn't make sense since reloading the page
// will just show an error page again. // will just show an error page again.
tryAgainButton.style.display = 'none'; tryAgainButton.style.display = "none";
} else { } else {
continueHttpButton.style.display = 'none'; continueHttpButton.style.display = "none";
} }
} }
@ -61,12 +65,12 @@ function updateShowSSL(queryMap) {
/** @type {'true' | 'false'} */ /** @type {'true' | 'false'} */
const showSSL = queryMap.showSSL; const showSSL = queryMap.showSSL;
if (typeof document.addCertException === "undefined") { if (typeof document.addCertException === "undefined") {
document.getElementById('advancedButton').style.display='none'; document.getElementById("advancedButton").style.display = "none";
} else { } else {
if (showSSL === 'true') { if (showSSL === "true") {
document.getElementById('advancedButton').style.display='block'; document.getElementById("advancedButton").style.display = "block";
} else { } else {
document.getElementById('advancedButton').style.display='none'; document.getElementById("advancedButton").style.display = "none";
} }
} }
} }
@ -76,9 +80,9 @@ function updateShowSSL(queryMap) {
*/ */
function updateShowHSTS(queryMap) { function updateShowHSTS(queryMap) {
const showHSTS = queryMap.showHSTS; const showHSTS = queryMap.showHSTS;
if (showHSTS === 'true') { if (showHSTS === "true") {
document.getElementById('advancedButton').style.display='block'; document.getElementById("advancedButton").style.display = "block";
document.getElementById('advancedPanelAcceptButton').style.display='none'; document.getElementById("advancedPanelAcceptButton").style.display = "none";
} }
} }
@ -87,9 +91,9 @@ function updateShowHSTS(queryMap) {
*/ */
function toggleAdvanced() { function toggleAdvanced() {
if (advancedVisible) { if (advancedVisible) {
document.getElementById('badCertAdvancedPanel').style.display='none'; document.getElementById("badCertAdvancedPanel").style.display = "none";
} else { } else {
document.getElementById('badCertAdvancedPanel').style.display='block'; document.getElementById("badCertAdvancedPanel").style.display = "block";
} }
advancedVisible = !advancedVisible; advancedVisible = !advancedVisible;
} }
@ -102,21 +106,31 @@ async function acceptAndContinue(temporary) {
await document.addCertException(temporary); await document.addCertException(temporary);
location.reload(); location.reload();
} catch (error) { } catch (error) {
console.error("Unexpected error: " + error) console.error("Unexpected error: " + error);
} }
} }
document.addEventListener('DOMContentLoaded', function () { document.addEventListener("DOMContentLoaded", function () {
if (window.history.length == 1) { if (window.history.length == 1) {
document.getElementById('advancedPanelBackButton').style.display = 'none'; document.getElementById("advancedPanelBackButton").style.display = "none";
} else { } else {
document.getElementById('advancedPanelBackButton').addEventListener('click', () => window.history.back()); document
.getElementById("advancedPanelBackButton")
.addEventListener("click", () => window.history.back());
} }
document.getElementById('errorTryAgain').addEventListener('click', () => window.location.reload()); document
document.getElementById('advancedButton').addEventListener('click', toggleAdvanced); .getElementById("errorTryAgain")
document.getElementById('advancedPanelAcceptButton').addEventListener('click', () => acceptAndContinue(true)); .addEventListener("click", () => window.location.reload());
document.getElementById('continueHttp').addEventListener('click', () => document.reloadWithHttpsOnlyException()); document
.getElementById("advancedButton")
.addEventListener("click", toggleAdvanced);
document
.getElementById("advancedPanelAcceptButton")
.addEventListener("click", () => acceptAndContinue(true));
document
.getElementById("continueHttp")
.addEventListener("click", () => document.reloadWithHttpsOnlyException());
}); });
parseQuery(document.documentURI); parseQuery(document.documentURI);

View file

@ -6,16 +6,18 @@
<html xmlns="http://www.w3.org/1999/xhtml"> <html xmlns="http://www.w3.org/1999/xhtml">
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8" />
<meta name="viewport" content="width=device-width; user-scalable=false;" /> <meta name="viewport" content="width=device-width; user-scalable=false;" />
<meta http-equiv="Content-Security-Policy" content="default-src resource:; object-src 'none'" /> <meta
<link rel="stylesheet" type="text/css" href="error_style.css"> http-equiv="Content-Security-Policy"
content="default-src resource:; object-src 'none'"
/>
<link rel="stylesheet" type="text/css" href="error_style.css" />
</head> </head>
<body id="errorPage" dir="auto"> <body id="errorPage" dir="auto">
<!-- PAGE CONTAINER (for styling purposes only) --> <!-- PAGE CONTAINER (for styling purposes only) -->
<div id="errorPageContainer"> <div id="errorPageContainer">
<!-- Error Image --> <!-- Error Image -->
<iframe id="errorImage" src="" frameborder="0"></iframe> <iframe id="errorImage" src="" frameborder="0"></iframe>
@ -41,16 +43,24 @@
<div id="advancedPanelContainer"> <div id="advancedPanelContainer">
<div id="badCertAdvancedPanel" class="advanced-panel"> <div id="badCertAdvancedPanel" class="advanced-panel">
<p id="badCertTechnicalInfo"></p> <p id="badCertTechnicalInfo"></p>
<div id="advancedPanelBackButtonContainer" class="advancedPanelButtonContainer"> <div
id="advancedPanelBackButtonContainer"
class="advancedPanelButtonContainer"
>
<button id="advancedPanelBackButton"></button> <button id="advancedPanelBackButton"></button>
</div> </div>
<div id="advancedPanelAcceptButtonContainer" class="advancedPanelButtonContainer"> <div
<button id="advancedPanelAcceptButton" class="buttonSecondary"></button> id="advancedPanelAcceptButtonContainer"
class="advancedPanelButtonContainer"
>
<button
id="advancedPanelAcceptButton"
class="buttonSecondary"
></button>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</body> </body>
<!-- Each consumer that uses a unique HTML error page must implement a parsing script--> <!-- Each consumer that uses a unique HTML error page must implement a parsing script-->

View file

@ -12,70 +12,71 @@
*/ */
function sizesToList(sizes) { function sizesToList(sizes) {
if (sizes == null) { if (sizes == null) {
return [] return [];
} }
if (!(sizes instanceof DOMTokenList)) { if (!(sizes instanceof DOMTokenList)) {
return [] return [];
} }
return Array.from(sizes) return Array.from(sizes);
} }
function collect_link_icons(icons, rel) { function collect_link_icons(icons, rel) {
document.querySelectorAll('link[rel="' + rel + '"]').forEach( document
function(currentValue, currentIndex, listObj) { .querySelectorAll('link[rel="' + rel + '"]')
.forEach(function (currentValue, currentIndex, listObj) {
icons.push({ icons.push({
'type': rel, type: rel,
'href': currentValue.href, href: currentValue.href,
'sizes': sizesToList(currentValue.sizes), sizes: sizesToList(currentValue.sizes),
'mimeType': currentValue.type mimeType: currentValue.type,
});
}); });
})
} }
function collect_meta_property_icons(icons, property) { function collect_meta_property_icons(icons, property) {
document.querySelectorAll('meta[property="' + property + '"]').forEach( document
function(currentValue, currentIndex, listObj) { .querySelectorAll('meta[property="' + property + '"]')
.forEach(function (currentValue, currentIndex, listObj) {
icons.push({ icons.push({
'type': property, type: property,
'href': currentValue.content href: currentValue.content,
}) });
} });
)
} }
function collect_meta_name_icons(icons, name) { function collect_meta_name_icons(icons, name) {
document.querySelectorAll('meta[name="' + name + '"]').forEach( document
function(currentValue, currentIndex, listObj) { .querySelectorAll('meta[name="' + name + '"]')
.forEach(function (currentValue, currentIndex, listObj) {
icons.push({ icons.push({
'type': name, type: name,
'href': currentValue.content href: currentValue.content,
}) });
} });
)
} }
let icons = []; let icons = [];
collect_link_icons(icons, 'icon'); collect_link_icons(icons, "icon");
collect_link_icons(icons, 'shortcut icon'); collect_link_icons(icons, "shortcut icon");
collect_link_icons(icons, 'fluid-icon') collect_link_icons(icons, "fluid-icon");
collect_link_icons(icons, 'apple-touch-icon') collect_link_icons(icons, "apple-touch-icon");
collect_link_icons(icons, 'image_src') collect_link_icons(icons, "image_src");
collect_link_icons(icons, 'apple-touch-icon image_src') collect_link_icons(icons, "apple-touch-icon image_src");
collect_link_icons(icons, 'apple-touch-icon-precomposed') collect_link_icons(icons, "apple-touch-icon-precomposed");
collect_meta_property_icons(icons, 'og:image') collect_meta_property_icons(icons, "og:image");
collect_meta_property_icons(icons, 'og:image:url') collect_meta_property_icons(icons, "og:image:url");
collect_meta_property_icons(icons, 'og:image:secure_url') collect_meta_property_icons(icons, "og:image:secure_url");
collect_meta_name_icons(icons, 'twitter:image') collect_meta_name_icons(icons, "twitter:image");
collect_meta_name_icons(icons, 'msapplication-TileImage') collect_meta_name_icons(icons, "msapplication-TileImage");
let message = { let message = {
'url': document.location.href, url: document.location.href,
'icons': icons icons: icons,
} };
browser.runtime.sendNativeMessage("MozacBrowserIcons", message); browser.runtime.sendNativeMessage("MozacBrowserIcons", message);

View file

@ -5,33 +5,42 @@
"display": "standalone", "display": "standalone",
"background_color": "#ffffff", "background_color": "#ffffff",
"description": "A simply readable Hacker News app.", "description": "A simply readable Hacker News app.",
"icons": [{ "icons": [
{
"src": "images/touch/homescreen48.png", "src": "images/touch/homescreen48.png",
"sizes": "48x48", "sizes": "48x48",
"type": "image/png" "type": "image/png"
}, { },
{
"src": "images/touch/homescreen72.png", "src": "images/touch/homescreen72.png",
"sizes": "72x72", "sizes": "72x72",
"type": "image/png" "type": "image/png"
}, { },
{
"src": "images/touch/homescreen96.png", "src": "images/touch/homescreen96.png",
"sizes": "96x96", "sizes": "96x96",
"type": "image/png" "type": "image/png"
}, { },
{
"src": "images/touch/homescreen144.png", "src": "images/touch/homescreen144.png",
"sizes": "144x144", "sizes": "144x144",
"type": "image/png" "type": "image/png"
}, { },
{
"src": "images/touch/homescreen168.png", "src": "images/touch/homescreen168.png",
"sizes": "168x168", "sizes": "168x168",
"type": "image/png" "type": "image/png"
}, { },
{
"src": "images/touch/homescreen192.png", "src": "images/touch/homescreen192.png",
"sizes": "192x192", "sizes": "192x192",
"type": "image/png" "type": "image/png"
}], }
"related_applications": [{ ],
"related_applications": [
{
"platform": "play", "platform": "play",
"url": "https://play.google.com/store/apps/details?id=cheeaun.hackerweb" "url": "https://play.google.com/store/apps/details?id=cheeaun.hackerweb"
}] }
]
} }

View file

@ -4,17 +4,21 @@
"name": "Super Racer 3000", "name": "Super Racer 3000",
"description": "The ultimate futuristic racing game from the future!", "description": "The ultimate futuristic racing game from the future!",
"short_name": "Racer3K", "short_name": "Racer3K",
"icons": [{ "icons": [
{
"src": "icon/lowres.webp", "src": "icon/lowres.webp",
"sizes": "64x64", "sizes": "64x64",
"type": "image/webp" "type": "image/webp"
},{ },
{
"src": "icon/lowres.png", "src": "icon/lowres.png",
"sizes": "64x64" "sizes": "64x64"
}, { },
{
"src": "icon/hd_hi", "src": "icon/hd_hi",
"sizes": "128x128" "sizes": "128x128"
}], }
],
"scope": "/racer/", "scope": "/racer/",
"start_url": "/racer/start.html", "start_url": "/racer/start.html",
"display": "fullscreen", "display": "fullscreen",
@ -26,26 +30,34 @@
"scope": "/racer/", "scope": "/racer/",
"update_via_cache": "none" "update_via_cache": "none"
}, },
"screenshots": [{ "screenshots": [
{
"src": "screenshots/in-game-1x.jpg", "src": "screenshots/in-game-1x.jpg",
"sizes": "640x480", "sizes": "640x480",
"type": "image/jpeg" "type": "image/jpeg"
},{ },
{
"src": "screenshots/in-game-2x.jpg", "src": "screenshots/in-game-2x.jpg",
"sizes": "1280x920", "sizes": "1280x920",
"type": "image/jpeg" "type": "image/jpeg"
}], }
"related_applications": [{ ],
"related_applications": [
{
"platform": "play", "platform": "play",
"url": "https://play.google.com/store/apps/details?id=com.example.app1", "url": "https://play.google.com/store/apps/details?id=com.example.app1",
"id": "com.example.app1", "id": "com.example.app1",
"min_version": "2", "min_version": "2",
"fingerprints": [{ "fingerprints": [
{
"type": "sha256_cert", "type": "sha256_cert",
"value": "92:5A:39:05:C5:B9:EA:BC:71:48:5F:F2" "value": "92:5A:39:05:C5:B9:EA:BC:71:48:5F:F2"
}] }
}, { ]
},
{
"platform": "itunes", "platform": "itunes",
"url": "https://itunes.apple.com/app/example-app1/id123456789" "url": "https://itunes.apple.com/app/example-app1/id123456789"
}] }
]
} }

View file

@ -1 +1,28 @@
{"background_color":"#ffffff","description":"It's what's happening. From breaking news and entertainment, sports and politics, to big events and everyday interests.","display":"standalone","gcm_sender_id":"49625052041","gcm_user_visible_only":true,"icons":[{"src":"https://abs.twimg.com/responsive-web/web/icon-default.604e2486a34a2f6e1.png","sizes":"192x192","type":"image/png"},{"src":"https://abs.twimg.com/responsive-web/web/icon-default.604e2486a34a2f6e1.png","sizes":"512x512","type":"image/png"}],"name":"Twitter","share_target":{"action":"compose/tweet","params":{"title":"title","text":"text","url":"url"}},"short_name":"Twitter","start_url":"/","theme_color":"#ffffff","scope":"/"} {
"background_color": "#ffffff",
"description": "It's what's happening. From breaking news and entertainment, sports and politics, to big events and everyday interests.",
"display": "standalone",
"gcm_sender_id": "49625052041",
"gcm_user_visible_only": true,
"icons": [
{
"src": "https://abs.twimg.com/responsive-web/web/icon-default.604e2486a34a2f6e1.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "https://abs.twimg.com/responsive-web/web/icon-default.604e2486a34a2f6e1.png",
"sizes": "512x512",
"type": "image/png"
}
],
"name": "Twitter",
"share_target": {
"action": "compose/tweet",
"params": { "title": "title", "text": "text", "url": "url" }
},
"short_name": "Twitter",
"start_url": "/",
"theme_color": "#ffffff",
"scope": "/"
}

View file

@ -13,9 +13,9 @@ Handle messages from native application, register content script for specific ur
port.onMessage.addListener(event => { port.onMessage.addListener(event => {
if (event.type == "overrideFxAServer") { if (event.type == "overrideFxAServer") {
browser.contentScripts.register({ browser.contentScripts.register({
"matches": [ event.url+"/*" ], matches: [event.url + "/*"],
"js": [{file: "fxawebchannel.js"}], js: [{ file: "fxawebchannel.js" }],
"runAt": "document_start" runAt: "document_start",
}); });
port.disconnect(); port.disconnect();
} }

View file

@ -10,16 +10,18 @@ let port = browser.runtime.connectNative("mozacWebchannel");
/* /*
Handle messages from native application, dispatch them to FxA via an event. Handle messages from native application, dispatch them to FxA via an event.
*/ */
port.onMessage.addListener((event) => { port.onMessage.addListener(event => {
window.dispatchEvent(new CustomEvent('WebChannelMessageToContent', { window.dispatchEvent(
detail: JSON.stringify(event) new CustomEvent("WebChannelMessageToContent", {
})); detail: JSON.stringify(event),
})
);
}); });
/* /*
Handle messages from FxA. Messages are posted to the native application for processing. Handle messages from FxA. Messages are posted to the native application for processing.
*/ */
window.addEventListener('WebChannelMessageToChrome', function (e) { window.addEventListener("WebChannelMessageToChrome", function (e) {
const detail = JSON.parse(e.detail); const detail = JSON.parse(e.detail);
port.postMessage(detail); port.postMessage(detail);
}); });

View file

@ -17,12 +17,8 @@
], ],
"average_daily_users": 6229783, "average_daily_users": 6229783,
"categories": { "categories": {
"android": [ "android": ["security-privacy"],
"security-privacy" "firefox": ["privacy-security"]
],
"firefox": [
"privacy-security"
]
}, },
"contributions_url": "", "contributions_url": "",
"created": "2015-04-25T07:26:22Z", "created": "2015-04-25T07:26:22Z",
@ -110,93 +106,54 @@
{ {
"id": 238546, "id": 238546,
"caption": "The popup panel: default mode", "caption": "The popup panel: default mode",
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238546.png?modified=1622132421", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238546.png?modified=1622132421",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238546.jpg?modified=1622132421" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238546.jpg?modified=1622132421"
}, },
{ {
"id": 238548, "id": 238548,
"caption": "The dashboard: stock filter lists", "caption": "The dashboard: stock filter lists",
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238548.png?modified=1622132423", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238548.png?modified=1622132423",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238548.jpg?modified=1622132423" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238548.jpg?modified=1622132423"
}, },
{ {
"id": 238547, "id": 238547,
"caption": "The popup panel: default-deny mode", "caption": "The popup panel: default-deny mode",
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238547.png?modified=1622132425", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238547.png?modified=1622132425",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238547.jpg?modified=1622132425" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238547.jpg?modified=1622132425"
}, },
{ {
"id": 238549, "id": 238549,
"caption": "The dashboard: settings", "caption": "The dashboard: settings",
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238549.png?modified=1622132426", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238549.png?modified=1622132426",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238549.jpg?modified=1622132426" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238549.jpg?modified=1622132426"
}, },
{ {
"id": 238552, "id": 238552,
"caption": "The popup panel in Firefox Preview: default mode with more blocking options revealed", "caption": "The popup panel in Firefox Preview: default mode with more blocking options revealed",
"image_size": [ "image_size": [970, 1800],
970,
1800
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238552.png?modified=1622132430", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238552.png?modified=1622132430",
"thumbnail_size": [ "thumbnail_size": [216, 400],
216,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238552.jpg?modified=1622132430" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238552.jpg?modified=1622132430"
}, },
{ {
"id": 230370, "id": 230370,
"caption": "The unified logger tells you all that uBO is seeing and doing", "caption": "The unified logger tells you all that uBO is seeing and doing",
"image_size": [ "image_size": [800, 600],
800,
600
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/230/230370.png?modified=1622132432", "image_url": "https://addons.mozilla.org/user-media/previews/full/230/230370.png?modified=1622132432",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/230/230370.jpg?modified=1622132432" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/230/230370.jpg?modified=1622132432"
} }
], ],
"promoted": { "promoted": {
"apps": [ "apps": ["firefox", "android"],
"firefox",
"android"
],
"category": "recommended" "category": "recommended"
}, },
"ratings": { "ratings": {

View file

@ -17,12 +17,8 @@
], ],
"average_daily_users": 6229783, "average_daily_users": 6229783,
"categories": { "categories": {
"android": [ "android": ["security-privacy"],
"security-privacy" "firefox": ["privacy-security"]
],
"firefox": [
"privacy-security"
]
}, },
"contributions_url": "", "contributions_url": "",
"created": "2015-04-25T07:26:22Z", "created": "2015-04-25T07:26:22Z",
@ -192,15 +188,9 @@
"caption": { "caption": {
"en-US": "The popup panel: default mode" "en-US": "The popup panel: default mode"
}, },
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238546.png?modified=1622132421", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238546.png?modified=1622132421",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238546.jpg?modified=1622132421" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238546.jpg?modified=1622132421"
}, },
{ {
@ -208,15 +198,9 @@
"caption": { "caption": {
"en-US": "The dashboard: stock filter lists" "en-US": "The dashboard: stock filter lists"
}, },
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238548.png?modified=1622132423", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238548.png?modified=1622132423",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238548.jpg?modified=1622132423" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238548.jpg?modified=1622132423"
}, },
{ {
@ -224,15 +208,9 @@
"caption": { "caption": {
"en-US": "The popup panel: default-deny mode" "en-US": "The popup panel: default-deny mode"
}, },
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238547.png?modified=1622132425", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238547.png?modified=1622132425",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238547.jpg?modified=1622132425" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238547.jpg?modified=1622132425"
}, },
{ {
@ -240,15 +218,9 @@
"caption": { "caption": {
"en-US": "The dashboard: settings" "en-US": "The dashboard: settings"
}, },
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238549.png?modified=1622132426", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238549.png?modified=1622132426",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238549.jpg?modified=1622132426" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238549.jpg?modified=1622132426"
}, },
{ {
@ -256,15 +228,9 @@
"caption": { "caption": {
"en-US": "The popup panel in Firefox Preview: default mode with more blocking options revealed" "en-US": "The popup panel in Firefox Preview: default mode with more blocking options revealed"
}, },
"image_size": [ "image_size": [970, 1800],
970,
1800
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238552.png?modified=1622132430", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238552.png?modified=1622132430",
"thumbnail_size": [ "thumbnail_size": [216, 400],
216,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238552.jpg?modified=1622132430" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238552.jpg?modified=1622132430"
}, },
{ {
@ -272,23 +238,14 @@
"caption": { "caption": {
"en-US": "The unified logger tells you all that uBO is seeing and doing" "en-US": "The unified logger tells you all that uBO is seeing and doing"
}, },
"image_size": [ "image_size": [800, 600],
800,
600
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/230/230370.png?modified=1622132432", "image_url": "https://addons.mozilla.org/user-media/previews/full/230/230370.png?modified=1622132432",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/230/230370.jpg?modified=1622132432" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/230/230370.jpg?modified=1622132432"
} }
], ],
"promoted": { "promoted": {
"apps": [ "apps": ["firefox", "android"],
"firefox",
"android"
],
"category": "recommended" "category": "recommended"
}, },
"ratings": { "ratings": {
@ -378,12 +335,8 @@
], ],
"average_daily_users": 111124, "average_daily_users": 111124,
"categories": { "categories": {
"android": [ "android": ["other"],
"other" "firefox": ["search-tools"]
],
"firefox": [
"search-tools"
]
}, },
"contributions_url": "", "contributions_url": "",
"created": "2017-10-31T15:35:56Z", "created": "2017-10-31T15:35:56Z",
@ -653,9 +606,7 @@
}, },
"previews": [], "previews": [],
"promoted": { "promoted": {
"apps": [ "apps": ["android"],
"android"
],
"category": "recommended" "category": "recommended"
}, },
"ratings": { "ratings": {

View file

@ -17,12 +17,8 @@
], ],
"average_daily_users": 6229783, "average_daily_users": 6229783,
"categories": { "categories": {
"android": [ "android": ["security-privacy"],
"security-privacy" "firefox": ["privacy-security"]
],
"firefox": [
"privacy-security"
]
}, },
"contributions_url": "", "contributions_url": "",
"created": "2015-04-25T07:26:22Z", "created": "2015-04-25T07:26:22Z",
@ -192,15 +188,9 @@
"caption": { "caption": {
"en-US": "The popup panel: default mode" "en-US": "The popup panel: default mode"
}, },
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238546.png?modified=1622132421", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238546.png?modified=1622132421",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238546.jpg?modified=1622132421" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238546.jpg?modified=1622132421"
}, },
{ {
@ -208,15 +198,9 @@
"caption": { "caption": {
"en-US": "The dashboard: stock filter lists" "en-US": "The dashboard: stock filter lists"
}, },
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238548.png?modified=1622132423", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238548.png?modified=1622132423",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238548.jpg?modified=1622132423" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238548.jpg?modified=1622132423"
}, },
{ {
@ -224,15 +208,9 @@
"caption": { "caption": {
"en-US": "The popup panel: default-deny mode" "en-US": "The popup panel: default-deny mode"
}, },
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238547.png?modified=1622132425", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238547.png?modified=1622132425",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238547.jpg?modified=1622132425" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238547.jpg?modified=1622132425"
}, },
{ {
@ -240,15 +218,9 @@
"caption": { "caption": {
"en-US": "The dashboard: settings" "en-US": "The dashboard: settings"
}, },
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238549.png?modified=1622132426", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238549.png?modified=1622132426",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238549.jpg?modified=1622132426" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238549.jpg?modified=1622132426"
}, },
{ {
@ -256,15 +228,9 @@
"caption": { "caption": {
"en-US": "The popup panel in Firefox Preview: default mode with more blocking options revealed" "en-US": "The popup panel in Firefox Preview: default mode with more blocking options revealed"
}, },
"image_size": [ "image_size": [970, 1800],
970,
1800
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238552.png?modified=1622132430", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238552.png?modified=1622132430",
"thumbnail_size": [ "thumbnail_size": [216, 400],
216,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238552.jpg?modified=1622132430" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238552.jpg?modified=1622132430"
}, },
{ {
@ -272,23 +238,14 @@
"caption": { "caption": {
"en-US": "The unified logger tells you all that uBO is seeing and doing" "en-US": "The unified logger tells you all that uBO is seeing and doing"
}, },
"image_size": [ "image_size": [800, 600],
800,
600
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/230/230370.png?modified=1622132432", "image_url": "https://addons.mozilla.org/user-media/previews/full/230/230370.png?modified=1622132432",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/230/230370.jpg?modified=1622132432" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/230/230370.jpg?modified=1622132432"
} }
], ],
"promoted": { "promoted": {
"apps": [ "apps": ["firefox", "android"],
"firefox",
"android"
],
"category": "recommended" "category": "recommended"
}, },
"ratings": { "ratings": {

View file

@ -18,12 +18,8 @@
], ],
"average_daily_users": 6229783, "average_daily_users": 6229783,
"categories": { "categories": {
"android": [ "android": ["security-privacy"],
"security-privacy" "firefox": ["privacy-security"]
],
"firefox": [
"privacy-security"
]
}, },
"contributions_url": "", "contributions_url": "",
"created": "2015-04-25T07:26:22Z", "created": "2015-04-25T07:26:22Z",
@ -193,15 +189,9 @@
"caption": { "caption": {
"en-US": "The popup panel: default mode" "en-US": "The popup panel: default mode"
}, },
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238546.png?modified=1622132421", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238546.png?modified=1622132421",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238546.jpg?modified=1622132421" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238546.jpg?modified=1622132421"
}, },
{ {
@ -209,15 +199,9 @@
"caption": { "caption": {
"en-US": "The dashboard: stock filter lists" "en-US": "The dashboard: stock filter lists"
}, },
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238548.png?modified=1622132423", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238548.png?modified=1622132423",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238548.jpg?modified=1622132423" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238548.jpg?modified=1622132423"
}, },
{ {
@ -225,15 +209,9 @@
"caption": { "caption": {
"en-US": "The popup panel: default-deny mode" "en-US": "The popup panel: default-deny mode"
}, },
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238547.png?modified=1622132425", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238547.png?modified=1622132425",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238547.jpg?modified=1622132425" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238547.jpg?modified=1622132425"
}, },
{ {
@ -241,15 +219,9 @@
"caption": { "caption": {
"en-US": "The dashboard: settings" "en-US": "The dashboard: settings"
}, },
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238549.png?modified=1622132426", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238549.png?modified=1622132426",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238549.jpg?modified=1622132426" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238549.jpg?modified=1622132426"
}, },
{ {
@ -257,15 +229,9 @@
"caption": { "caption": {
"en-US": "The popup panel in Firefox Preview: default mode with more blocking options revealed" "en-US": "The popup panel in Firefox Preview: default mode with more blocking options revealed"
}, },
"image_size": [ "image_size": [970, 1800],
970,
1800
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/238/238552.png?modified=1622132430", "image_url": "https://addons.mozilla.org/user-media/previews/full/238/238552.png?modified=1622132430",
"thumbnail_size": [ "thumbnail_size": [216, 400],
216,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238552.jpg?modified=1622132430" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/238/238552.jpg?modified=1622132430"
}, },
{ {
@ -273,23 +239,14 @@
"caption": { "caption": {
"en-US": "The unified logger tells you all that uBO is seeing and doing" "en-US": "The unified logger tells you all that uBO is seeing and doing"
}, },
"image_size": [ "image_size": [800, 600],
800,
600
],
"image_url": "https://addons.mozilla.org/user-media/previews/full/230/230370.png?modified=1622132432", "image_url": "https://addons.mozilla.org/user-media/previews/full/230/230370.png?modified=1622132432",
"thumbnail_size": [ "thumbnail_size": [533, 400],
533,
400
],
"thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/230/230370.jpg?modified=1622132432" "thumbnail_url": "https://addons.mozilla.org/user-media/previews/thumbs/230/230370.jpg?modified=1622132432"
} }
], ],
"promoted": { "promoted": {
"apps": [ "apps": ["firefox", "android"],
"firefox",
"android"
],
"category": "recommended" "category": "recommended"
}, },
"ratings": { "ratings": {

View file

@ -162,15 +162,9 @@
"caption": { "caption": {
"en-US": "Default mode" "en-US": "Default mode"
}, },
"image_size": [ "image_size": [640, 480],
640,
480
],
"image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/157/157572.png?modified=1543520531", "image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/157/157572.png?modified=1543520531",
"thumbnail_size": [ "thumbnail_size": [640, 480],
640,
480
],
"thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/157/157572.png?modified=1543520531" "thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/157/157572.png?modified=1543520531"
}, },
{ {
@ -178,15 +172,9 @@
"caption": { "caption": {
"en-US": "The dashboard: stock filter lists" "en-US": "The dashboard: stock filter lists"
}, },
"image_size": [ "image_size": [640, 480],
640,
480
],
"image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/157/157576.png?modified=1543520531", "image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/157/157576.png?modified=1543520531",
"thumbnail_size": [ "thumbnail_size": [640, 480],
640,
480
],
"thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/157/157576.png?modified=1543520531" "thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/157/157576.png?modified=1543520531"
}, },
{ {
@ -194,15 +182,9 @@
"caption": { "caption": {
"en-US": "Dynamic filtering allows default-deny mode" "en-US": "Dynamic filtering allows default-deny mode"
}, },
"image_size": [ "image_size": [640, 480],
640,
480
],
"image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/157/157592.png?modified=1543520532", "image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/157/157592.png?modified=1543520532",
"thumbnail_size": [ "thumbnail_size": [640, 480],
640,
480
],
"thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/157/157592.png?modified=1543520532" "thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/157/157592.png?modified=1543520532"
}, },
{ {
@ -210,15 +192,9 @@
"caption": { "caption": {
"en-US": "The dashboard: settings" "en-US": "The dashboard: settings"
}, },
"image_size": [ "image_size": [640, 480],
640,
480
],
"image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/159/159634.png?modified=1543520533", "image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/159/159634.png?modified=1543520533",
"thumbnail_size": [ "thumbnail_size": [640, 480],
640,
480
],
"thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/159/159634.png?modified=1543520533" "thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/159/159634.png?modified=1543520533"
}, },
{ {
@ -226,15 +202,9 @@
"caption": { "caption": {
"en-US": "Unified logger" "en-US": "Unified logger"
}, },
"image_size": [ "image_size": [700, 525],
700,
525
],
"image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/158/158734.png?modified=1543520534", "image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/158/158734.png?modified=1543520534",
"thumbnail_size": [ "thumbnail_size": [640, 480],
640,
480
],
"thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/158/158734.png?modified=1543520534" "thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/158/158734.png?modified=1543520534"
} }
], ],

View file

@ -19,12 +19,8 @@
], ],
"average_daily_users": 5060298, "average_daily_users": 5060298,
"categories": { "categories": {
"android": [ "android": ["security-privacy"],
"security-privacy" "firefox": ["privacy-security"]
],
"firefox": [
"privacy-security"
]
}, },
"contributions_url": "", "contributions_url": "",
"created": "2015-04-25T07:26:22Z", "created": "2015-04-25T07:26:22Z",
@ -110,93 +106,54 @@
{ {
"id": 238546, "id": 238546,
"caption": "The popup panel: default mode", "caption": "The popup panel: default mode",
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/238/238546.png?modified=1590420038", "image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/238/238546.png?modified=1590420038",
"thumbnail_size": [ "thumbnail_size": [640, 480],
640,
480
],
"thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/238/238546.png?modified=1590420038" "thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/238/238546.png?modified=1590420038"
}, },
{ {
"id": 238548, "id": 238548,
"caption": "The dashboard: stock filter lists", "caption": "The dashboard: stock filter lists",
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/238/238548.png?modified=1590420038", "image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/238/238548.png?modified=1590420038",
"thumbnail_size": [ "thumbnail_size": [640, 480],
640,
480
],
"thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/238/238548.png?modified=1590420038" "thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/238/238548.png?modified=1590420038"
}, },
{ {
"id": 238547, "id": 238547,
"caption": "The popup panel: default-deny mode", "caption": "The popup panel: default-deny mode",
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/238/238547.png?modified=1590420038", "image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/238/238547.png?modified=1590420038",
"thumbnail_size": [ "thumbnail_size": [640, 480],
640,
480
],
"thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/238/238547.png?modified=1590420038" "thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/238/238547.png?modified=1590420038"
}, },
{ {
"id": 238549, "id": 238549,
"caption": "The dashboard: settings", "caption": "The dashboard: settings",
"image_size": [ "image_size": [1011, 758],
1011,
758
],
"image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/238/238549.png?modified=1590420038", "image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/238/238549.png?modified=1590420038",
"thumbnail_size": [ "thumbnail_size": [640, 480],
640,
480
],
"thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/238/238549.png?modified=1590420038" "thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/238/238549.png?modified=1590420038"
}, },
{ {
"id": 238552, "id": 238552,
"caption": "The popup panel in Firefox Preview: default mode with more blocking options revealed", "caption": "The popup panel in Firefox Preview: default mode with more blocking options revealed",
"image_size": [ "image_size": [970, 1800],
970,
1800
],
"image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/238/238552.png?modified=1590420044", "image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/238/238552.png?modified=1590420044",
"thumbnail_size": [ "thumbnail_size": [259, 480],
259,
480
],
"thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/238/238552.png?modified=1590420044" "thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/238/238552.png?modified=1590420044"
}, },
{ {
"id": 230370, "id": 230370,
"caption": "The unified logger tells you all that uBO is seeing and doing", "caption": "The unified logger tells you all that uBO is seeing and doing",
"image_size": [ "image_size": [800, 600],
800,
600
],
"image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/230/230370.png?modified=1590420038", "image_url": "https://addons.cdn.mozilla.net/user-media/previews/full/230/230370.png?modified=1590420038",
"thumbnail_size": [ "thumbnail_size": [640, 480],
640,
480
],
"thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/230/230370.png?modified=1590420038" "thumbnail_url": "https://addons.cdn.mozilla.net/user-media/previews/thumbs/230/230370.png?modified=1590420038"
} }
], ],
"promoted": { "promoted": {
"apps": [ "apps": ["firefox", "android"],
"firefox",
"android"
],
"category": "recommended" "category": "recommended"
}, },
"ratings": { "ratings": {

View file

@ -10,7 +10,10 @@
"content_scripts": [ "content_scripts": [
{ {
"matches": ["<all_urls>"], "matches": ["<all_urls>"],
"js": ["readability/readability-readerable-0.4.2.js", "readerview-content.js"], "js": [
"readability/readability-readerable-0.4.2.js",
"readerview-content.js"
],
"run_at": "document_idle" "run_at": "document_idle"
} }
], ],

View file

@ -7,10 +7,10 @@
browser.runtime.onMessage.addListener(message => { browser.runtime.onMessage.addListener(message => {
switch (message.action) { switch (message.action) {
case 'addSerializedDoc': case "addSerializedDoc":
browser.storage.session.set({ [message.id]: message.doc }); browser.storage.session.set({ [message.id]: message.doc });
return Promise.resolve(); return Promise.resolve();
case 'getSerializedDoc': case "getSerializedDoc":
return (async () => { return (async () => {
let doc = await browser.storage.session.get(message.id); let doc = await browser.storage.session.get(message.id);
browser.storage.session.remove(message.id); browser.storage.session.remove(message.id);

View file

@ -17,7 +17,7 @@ const blockedHosts = [
"pinterest.com", "pinterest.com",
"reddit.com", "reddit.com",
"twitter.com", "twitter.com",
"youtube.com" "youtube.com",
]; ];
function isReaderable() { function isReaderable() {
@ -25,7 +25,9 @@ function isReaderable() {
return false; return false;
} }
if (blockedHosts.some(blockedHost => location.hostname.endsWith(blockedHost))) { if (
blockedHosts.some(blockedHost => location.hostname.endsWith(blockedHost))
) {
return false; return false;
} }
@ -42,14 +44,22 @@ function _isNodeVisible(node) {
function connectNativePort() { function connectNativePort() {
let port = browser.runtime.connectNative("mozacReaderview"); let port = browser.runtime.connectNative("mozacReaderview");
port.onMessage.addListener((message) => { port.onMessage.addListener(message => {
switch (message.action) { switch (message.action) {
case 'cachePage': case "cachePage":
let serializedDoc = new XMLSerializer().serializeToString(document); let serializedDoc = new XMLSerializer().serializeToString(document);
browser.runtime.sendMessage({action: "addSerializedDoc", doc: serializedDoc, id: message.id}); browser.runtime.sendMessage({
action: "addSerializedDoc",
doc: serializedDoc,
id: message.id,
});
break; break;
case 'checkReaderState': case "checkReaderState":
port.postMessage({type: 'checkReaderState', baseUrl: browser.runtime.getURL("/"), readerable: isReaderable()}); port.postMessage({
type: "checkReaderState",
baseUrl: browser.runtime.getURL("/"),
readerable: isReaderable(),
});
break; break;
default: default:
console.error(`Received unsupported action ${message.action}`); console.error(`Received unsupported action ${message.action}`);
@ -65,11 +75,11 @@ let port = connectNativePort();
// do want to connect a new native port to trigger a new readerable check and // do want to connect a new native port to trigger a new readerable check and
// apply the same logic (as on page load) in our feature class (e.g. updating the // apply the same logic (as on page load) in our feature class (e.g. updating the
// toolbar etc.) // toolbar etc.)
window.addEventListener("pageshow", (event) => { window.addEventListener("pageshow", event => {
port = (port != null)? port : connectNativePort(); port = port != null ? port : connectNativePort();
}); });
window.addEventListener("pagehide", (event) => { window.addEventListener("pagehide", event => {
port.disconnect(); port.disconnect();
port = null; port = null;
}); });

View file

@ -15,11 +15,10 @@ const preservedClasses = [
"visuallyhidden", "visuallyhidden",
"wp-caption", "wp-caption",
"wp-caption-text", "wp-caption-text",
"wp-smiley" "wp-smiley",
]; ];
class ReaderView { class ReaderView {
static get MIN_FONT_SIZE() { static get MIN_FONT_SIZE() {
return 1; return 1;
} }
@ -37,8 +36,14 @@ class ReaderView {
* @param url the url of the article. * @param url the url of the article.
* @param options the fontSize, fontType and colorScheme to use. * @param options the fontSize, fontType and colorScheme to use.
*/ */
show(doc, url, options = {fontSize: 4, fontType: "sans-serif", colorScheme: "light"}) { show(
let result = new Readability(doc, {classesToPreserve: preservedClasses}).parse(); doc,
url,
options = { fontSize: 4, fontType: "sans-serif", colorScheme: "light" }
) {
let result = new Readability(doc, {
classesToPreserve: preservedClasses,
}).parse();
result.language = doc.documentElement.lang; result.language = doc.documentElement.lang;
document.title = result.title; document.title = result.title;
@ -68,7 +73,10 @@ class ReaderView {
* @param changeAmount e.g. +1, or -1. * @param changeAmount e.g. +1, or -1.
*/ */
changeFontSize(changeAmount) { changeFontSize(changeAmount) {
var size = Math.max(ReaderView.MIN_FONT_SIZE, Math.min(ReaderView.MAX_FONT_SIZE, this.fontSize + changeAmount)); var size = Math.max(
ReaderView.MIN_FONT_SIZE,
Math.min(ReaderView.MAX_FONT_SIZE, this.fontSize + changeAmount)
);
this.setFontSize(size); this.setFontSize(size);
} }
@ -79,7 +87,7 @@ class ReaderView {
* and ReaderView.MAX_FONT_SIZE. * and ReaderView.MAX_FONT_SIZE.
*/ */
setFontSize(fontSize) { setFontSize(fontSize) {
let size = (10 + 2 * fontSize) + "px"; let size = 10 + 2 * fontSize + "px";
let readerView = document.getElementById("mozac-readerview-container"); let readerView = document.getElementById("mozac-readerview-container");
readerView.style.setProperty("font-size", size); readerView.style.setProperty("font-size", size);
this.fontSize = fontSize; this.fontSize = fontSize;
@ -108,8 +116,8 @@ class ReaderView {
* or sepia. * or sepia.
*/ */
setColorScheme(colorScheme) { setColorScheme(colorScheme) {
if(!['light', 'sepia', 'dark'].includes(colorScheme)) { if (!["light", "sepia", "dark"].includes(colorScheme)) {
console.error(`Invalid color scheme specified: ${colorScheme}`) console.error(`Invalid color scheme specified: ${colorScheme}`);
return; return;
} }
@ -152,7 +160,7 @@ class ReaderView {
</div> </div>
</div> </div>
</body> </body>
` `;
} }
/** /**
@ -162,7 +170,8 @@ class ReaderView {
* @param optional language of the article, defaults to en. * @param optional language of the article, defaults to en.
*/ */
getReadingTime(length, lang = "en") { getReadingTime(length, lang = "en") {
const [readingSpeed, readingSpeedLang] = this.getReadingSpeedForLanguage(lang); const [readingSpeed, readingSpeedLang] =
this.getReadingSpeedForLanguage(lang);
const charactersPerMinuteLow = readingSpeed.cpm - readingSpeed.variance; const charactersPerMinuteLow = readingSpeed.cpm - readingSpeed.variance;
const charactersPerMinuteHigh = readingSpeed.cpm + readingSpeed.variance; const charactersPerMinuteHigh = readingSpeed.cpm + readingSpeed.variance;
const readingTimeMinsSlow = Math.ceil(length / charactersPerMinuteLow); const readingTimeMinsSlow = Math.ceil(length / charactersPerMinuteLow);
@ -172,7 +181,10 @@ class ReaderView {
// If we have both a fast and slow reading time we'll show both e.g. // If we have both a fast and slow reading time we'll show both e.g.
// "2 - 4 minutes", otherwise we'll just show "4 minutes". // "2 - 4 minutes", otherwise we'll just show "4 minutes".
try { try {
var parts = new Intl.RelativeTimeFormat(readingSpeedLang).formatToParts(readingTimeMinsSlow, 'minute'); var parts = new Intl.RelativeTimeFormat(readingSpeedLang).formatToParts(
readingTimeMinsSlow,
"minute"
);
if (parts.length == 3) { if (parts.length == 3) {
// No need to use part[0] which represents the literal "in". // No need to use part[0] which represents the literal "in".
var readingTime = parts[1].value; // reading time in minutes var readingTime = parts[1].value; // reading time in minutes
@ -183,8 +195,7 @@ class ReaderView {
} }
return readingTimeString; return readingTimeString;
} }
} } catch (error) {
catch(error) {
console.error(`Failed to format reading time: ${error}`); console.error(`Failed to format reading time: ${error}`);
} }
@ -221,7 +232,9 @@ class ReaderView {
["zh", { cpm: 255, variance: 29 }], ["zh", { cpm: 255, variance: 29 }],
]); ]);
return readingSpeed.has(lang) ? [readingSpeed.get(lang), lang] : [readingSpeed.get("en"), "en"]; return readingSpeed.has(lang)
? [readingSpeed.get(lang), lang]
: [readingSpeed.get("en"), "en"];
} }
getByline(article) { getByline(article) {
@ -282,16 +295,16 @@ function fetchDocument(url) {
function getPreparedDocument(id, url) { function getPreparedDocument(id, url) {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
browser.runtime
browser.runtime.sendMessage({action: "getSerializedDoc", id: id}).then((serializedDoc) => { .sendMessage({ action: "getSerializedDoc", id: id })
.then(serializedDoc => {
if (serializedDoc) { if (serializedDoc) {
let doc = new JSDOMParser().parse(serializedDoc, url); let doc = new JSDOMParser().parse(serializedDoc, url);
resolve(doc); resolve(doc);
} else { } else {
reject(); reject();
} }
} });
);
}); });
} }
@ -306,14 +319,17 @@ function connectNativePort() {
let baseUrl = browser.runtime.getURL("/"); let baseUrl = browser.runtime.getURL("/");
let port = browser.runtime.connectNative("mozacReaderviewActive"); let port = browser.runtime.connectNative("mozacReaderviewActive");
port.onMessage.addListener((message) => { port.onMessage.addListener(message => {
switch (message.action) { switch (message.action) {
case 'show': case "show":
async function showAsync(options) { async function showAsync(options) {
try { try {
let doc; let doc;
if (typeof Promise.any === "function") { if (typeof Promise.any === "function") {
doc = await Promise.any([fetchDocument(articleUrl), getPreparedDocument(id, articleUrl)]); doc = await Promise.any([
fetchDocument(articleUrl),
getPreparedDocument(id, articleUrl),
]);
} else { } else {
try { try {
doc = await getPreparedDocument(id, articleUrl); doc = await getPreparedDocument(id, articleUrl);
@ -332,19 +348,23 @@ function connectNativePort() {
} }
showAsync(message.value); showAsync(message.value);
break; break;
case 'hide': case "hide":
window.location.href = articleUrl; window.location.href = articleUrl;
case 'setColorScheme': case "setColorScheme":
readerView.setColorScheme(message.value.toLowerCase()); readerView.setColorScheme(message.value.toLowerCase());
break; break;
case 'changeFontSize': case "changeFontSize":
readerView.changeFontSize(message.value); readerView.changeFontSize(message.value);
break; break;
case 'setFontType': case "setFontType":
readerView.setFontType(message.value.toLowerCase()); readerView.setFontType(message.value.toLowerCase());
break; break;
case 'checkReaderState': case "checkReaderState":
port.postMessage({baseUrl: baseUrl, activeUrl: articleUrl, readerable: true}); port.postMessage({
baseUrl: baseUrl,
activeUrl: articleUrl,
readerable: true,
});
break; break;
default: default:
console.error(`Received invalid action ${message.action}`); console.error(`Received invalid action ${message.action}`);

View file

@ -11,9 +11,9 @@
*/ */
function sendCurrentState() { function sendCurrentState() {
let message = { let message = {
'url': document.location.href, url: document.location.href,
'urls': getLinks(), urls: getLinks(),
'cookies': getCookies() cookies: getCookies(),
}; };
browser.runtime.sendNativeMessage("MozacBrowserAdsMessage", message); browser.runtime.sendNativeMessage("MozacBrowserAdsMessage", message);
} }
@ -47,13 +47,13 @@ function getCookies() {
let result = []; let result = [];
cookiesList.forEach(cookie => { cookiesList.forEach(cookie => {
var [name, ...value] = cookie.split('='); var [name, ...value] = cookie.split("=");
// For that special cases where the value contains '='. // For that special cases where the value contains '='.
value = value.join("=") value = value.join("=");
result.push({ result.push({
"name" : name, name: name,
"value" : value value: value,
}); });
}); });
@ -74,9 +74,7 @@ const eventLogger = event => {
} }
break; break;
default: default:
console.log('Event:', event.type); console.log("Event:", event.type);
} }
}; };
events.forEach(eventName => events.forEach(eventName => window.addEventListener(eventName, eventLogger));
window.addEventListener(eventName, eventLogger)
);

View file

@ -10,8 +10,8 @@
*/ */
function sendCurrentState() { function sendCurrentState() {
let message = { let message = {
'url': document.location.href, url: document.location.href,
'cookies': getCookies() cookies: getCookies(),
}; };
browser.runtime.sendNativeMessage("MozacBrowserSearchMessage", message); browser.runtime.sendNativeMessage("MozacBrowserSearchMessage", message);
} }
@ -26,13 +26,13 @@ function getCookies() {
let result = []; let result = [];
cookiesList.forEach(cookie => { cookiesList.forEach(cookie => {
var [name, ...value] = cookie.split('='); var [name, ...value] = cookie.split("=");
// For that special cases where the cookie value contains '='. // For that special cases where the cookie value contains '='.
value = value.join("="); value = value.join("=");
result.push({ result.push({
"name" : name, name: name,
"value" : value value: value,
}); });
}); });
@ -53,9 +53,7 @@ const eventLogger = event => {
} }
break; break;
default: default:
console.log('Event:', event.type); console.log("Event:", event.type);
} }
}; };
events.forEach(eventName => events.forEach(eventName => window.addEventListener(eventName, eventLogger));
window.addEventListener(eventName, eventLogger)
);

View file

@ -27,18 +27,11 @@
"96": "icons/lightbulb.svg", "96": "icons/lightbulb.svg",
"128": "icons/lightbulb.svg" "128": "icons/lightbulb.svg"
}, },
"permissions": [ "permissions": ["geckoViewAddons", "nativeMessaging", "tabs", "<all_urls>"],
"geckoViewAddons",
"nativeMessaging",
"tabs",
"<all_urls>"
],
"background": { "background": {
"persistent": false, "persistent": false,
"type": "module", "type": "module",
"scripts": [ "scripts": ["background.js"]
"background.js"
]
}, },
"page_action": { "page_action": {
"browser_style": true, "browser_style": true,

View file

@ -7,7 +7,9 @@
<label for="nav-trigger"> <label for="nav-trigger">
<span class="menu-icon"> <span class="menu-icon">
<svg viewBox="0 0 18 15" width="18px" height="15px"> <svg viewBox="0 0 18 15" width="18px" height="15px">
<path d="M18,1.484c0,0.82-0.665,1.484-1.484,1.484H1.484C0.665,2.969,0,2.304,0,1.484l0,0C0,0.665,0.665,0,1.484,0 h15.032C17.335,0,18,0.665,18,1.484L18,1.484z M18,7.516C18,8.335,17.335,9,16.516,9H1.484C0.665,9,0,8.335,0,7.516l0,0 c0-0.82,0.665-1.484,1.484-1.484h15.032C17.335,6.031,18,6.696,18,7.516L18,7.516z M18,13.516C18,14.335,17.335,15,16.516,15H1.484 C0.665,15,0,14.335,0,13.516l0,0c0-0.82,0.665-1.483,1.484-1.483h15.032C17.335,12.031,18,12.695,18,13.516L18,13.516z"/> <path
d="M18,1.484c0,0.82-0.665,1.484-1.484,1.484H1.484C0.665,2.969,0,2.304,0,1.484l0,0C0,0.665,0.665,0,1.484,0 h15.032C17.335,0,18,0.665,18,1.484L18,1.484z M18,7.516C18,8.335,17.335,9,16.516,9H1.484C0.665,9,0,8.335,0,7.516l0,0 c0-0.82,0.665-1.484,1.484-1.484h15.032C17.335,6.031,18,6.696,18,7.516L18,7.516z M18,13.516C18,14.335,17.335,15,16.516,15H1.484 C0.665,15,0,14.335,0,13.516l0,0c0-0.82,0.665-1.483,1.484-1.483h15.032C17.335,12.031,18,12.695,18,13.516L18,13.516z"
/>
</svg> </svg>
</span> </span>
</label> </label>

View file

@ -1,24 +1,42 @@
--- ---
layout: default layout: default
--- ---
<article class="post h-entry" itemscope itemtype="http://schema.org/BlogPosting">
<article
class="post h-entry"
itemscope
itemtype="http://schema.org/BlogPosting"
>
<header class="post-header"> <header class="post-header">
<h1 class="post-title p-name" itemprop="name headline">{{ page.title | escape }}</h1> <h1 class="post-title p-name" itemprop="name headline">
{{ page.title | escape }}
</h1>
<p class="post-meta"> <p class="post-meta">
<time class="dt-published" datetime="{{ page.date | date_to_xmlschema }}" itemprop="datePublished"> <time
{%- assign date_format = site.minima.date_format | default: "%b %-d, %Y" -%} class="dt-published"
{{ page.date | date: date_format }} datetime="{{ page.date | date_to_xmlschema }}"
itemprop="datePublished"
>
{%- assign date_format = site.minima.date_format | default: "%b %-d, %Y"
-%} {{ page.date | date: date_format }}
</time> </time>
{%- if page.author -%} {%- if page.author -%} - {% assign author = site.data.authors[page.author]
- %}
{% assign author = site.data.authors[page.author] %}
<span itemprop="author" itemscope itemtype="http://schema.org/Person"> <span itemprop="author" itemscope itemtype="http://schema.org/Person">
<span class="p-author h-card" itemprop="name"> <span class="p-author h-card" itemprop="name">
<img src="{{ author.image }}" width="20" height="20" style="margin:5px;" /> <img
{{ author.name }} src="{{ author.image }}"
{%- if author.twitter -%} width="20"
<a href="{{ author.twitter }}"><svg class="svg-icon" style="margin-left:10px;"><use xlink:href="{{ '/assets/minima-social-icons.svg#twitter' | relative_url }}"></use></svg></a> height="20"
style="margin: 5px"
/>
{{ author.name }} {%- if author.twitter -%}
<a href="{{ author.twitter }}"
><svg class="svg-icon" style="margin-left: 10px">
<use
xlink:href="{{ '/assets/minima-social-icons.svg#twitter' | relative_url }}"
></use></svg
></a>
{%- endif -%} {%- endif -%}
</span> </span>
</span> </span>
@ -26,13 +44,10 @@ layout: default
</p> </p>
</header> </header>
<div class="post-content e-content" itemprop="articleBody"> <div class="post-content e-content" itemprop="articleBody">{{ content }}</div>
{{ content }}
</div>
{%- if site.disqus.shortname -%} {%- if site.disqus.shortname -%} {%- include disqus_comments.html -%} {%-
{%- include disqus_comments.html -%} endif -%}
{%- endif -%}
<a class="u-url" href="{{ page.url | relative_url }}" hidden></a> <a class="u-url" href="{{ page.url | relative_url }}" hidden></a>
</article> </article>

View file

@ -3,7 +3,7 @@
* @return {Element} * @return {Element}
*/ */
function htmlToElement(html) { function htmlToElement(html) {
let template = document.createElement('template'); let template = document.createElement("template");
html = html.trim(); // Never return a text node of whitespace as the result html = html.trim(); // Never return a text node of whitespace as the result
template.innerHTML = html; template.innerHTML = html;
//firstChild may be a comment so we must use firstElementChild to avoid picking it //firstChild may be a comment so we must use firstElementChild to avoid picking it
@ -17,14 +17,17 @@ function htmlToElement(html) {
* @returns {String} The same string but in the standard SVG representation * @returns {String} The same string but in the standard SVG representation
*/ */
function androidSVGtoNormalSVG(s) { function androidSVGtoNormalSVG(s) {
s = s.replace(/<\?xml version="1\.0" encoding="utf-8"\?>/g, ''); s = s.replace(/<\?xml version="1\.0" encoding="utf-8"\?>/g, "");
s = s.replace(/<vector xmlns:android="http:\/\/schemas.android.com\/apk\/res\/android"/g, '<svg xmlns="http://www.w3.org/2000/svg"'); s = s.replace(
s = s.replace(/<\/vector>/g, '</svg>'); /<vector xmlns:android="http:\/\/schemas.android.com\/apk\/res\/android"/g,
s = s.replace(/android:(height|width)="(\d+)dp"/g, ''); '<svg xmlns="http://www.w3.org/2000/svg"'
);
s = s.replace(/<\/vector>/g, "</svg>");
s = s.replace(/android:(height|width)="(\d+)dp"/g, "");
s = s.replace(/android:viewportHeight="(\d+\.?\d+)"/g, 'height="$1"'); s = s.replace(/android:viewportHeight="(\d+\.?\d+)"/g, 'height="$1"');
s = s.replace(/android:viewportWidth="(\d+\.?\d+)"/g, 'width="$1"'); s = s.replace(/android:viewportWidth="(\d+\.?\d+)"/g, 'width="$1"');
s = s.replace(/android:fillColor=/g, 'fill='); s = s.replace(/android:fillColor=/g, "fill=");
s = s.replace(/android:pathData=/g, 'd='); s = s.replace(/android:pathData=/g, "d=");
//s = s.replace(/android:/g, ''); //s = s.replace(/android:/g, '');
return s; return s;
} }
@ -41,13 +44,13 @@ function addToTable(name, svg) {
function addSingleItemToTable(str) { function addSingleItemToTable(str) {
let table = document.querySelector("#preview_table > tbody"); let table = document.querySelector("#preview_table > tbody");
table.append(htmlToElement("<tr><td colspan='2'>" + str + "</td></tr>")) table.append(htmlToElement("<tr><td colspan='2'>" + str + "</td></tr>"));
} }
function getFile(iconName, downloadUrl) { function getFile(iconName, downloadUrl) {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
let request = new XMLHttpRequest(); let request = new XMLHttpRequest();
request.open('GET', downloadUrl, true); request.open("GET", downloadUrl, true);
request.onreadystatechange = function () { request.onreadystatechange = function () {
if (request.readyState === 4 && request.status === 200) { if (request.readyState === 4 && request.status === 200) {
let androidXmlText = request.responseText; let androidXmlText = request.responseText;
@ -60,13 +63,16 @@ function getFile(iconName, downloadUrl) {
}; };
request.send(null); request.send(null);
}); });
} }
// This function recovers all icons inside the drawable folder via github API // This function recovers all icons inside the drawable folder via github API
(function getIcons() { (function getIcons() {
let request = new XMLHttpRequest(); let request = new XMLHttpRequest();
request.open("GET", "https://api.github.com/repos/mozilla-mobile/android-components/contents/components/ui/icons/src/main/res/drawable", true); request.open(
"GET",
"https://api.github.com/repos/mozilla-mobile/android-components/contents/components/ui/icons/src/main/res/drawable",
true
);
//Explicit request of the V3 version of the API //Explicit request of the V3 version of the API
request.setRequestHeader("Accept", "application/vnd.github.v3+json"); request.setRequestHeader("Accept", "application/vnd.github.v3+json");
request.onreadystatechange = function () { request.onreadystatechange = function () {
@ -80,13 +86,17 @@ function getFile(iconName, downloadUrl) {
addSingleItemToTable("Loading"); addSingleItemToTable("Loading");
let promises = []; let promises = [];
for (let i = 0; i < response.length; i++) { for (let i = 0; i < response.length; i++) {
let iconName = response[i]['name'].substr(0, response[i]['name'].length - 4); let iconName = response[i]["name"].substr(
promises.push(getFile(iconName, response[i]['download_url'])); 0,
response[i]["name"].length - 4
);
promises.push(getFile(iconName, response[i]["download_url"]));
} }
Promise.all(promises).then((values) => { Promise.all(promises).then(values => {
document.querySelector("#preview_table > tbody").innerHTML = ""; document.querySelector("#preview_table > tbody").innerHTML = "";
for (let i = 0; i < values.length; i++) { for (let i = 0; i < values.length; i++) {
let name = values[i][0], svg = values[i][1]; let name = values[i][0],
svg = values[i][1];
addToTable(name, htmlToElement(svg)); addToTable(name, htmlToElement(svg));
} }
}); });
@ -94,4 +104,3 @@ function getFile(iconName, downloadUrl) {
}; };
request.send(null); request.send(null);
})(); })();

View file

@ -6,7 +6,7 @@
* inadvertently match elements in the article content. */ * inadvertently match elements in the article content. */
// Counts to three and sends a greeting via the browser action of a newly created tab. // Counts to three and sends a greeting via the browser action of a newly created tab.
browser.tabs.onCreated.addListener((tab) => { browser.tabs.onCreated.addListener(tab => {
let counter = 0; let counter = 0;
let intervalId = setInterval(() => { let intervalId = setInterval(() => {
var message; var message;
@ -16,7 +16,10 @@ browser.tabs.onCreated.addListener((tab) => {
message = "Hi!"; message = "Hi!";
clearInterval(intervalId); clearInterval(intervalId);
} }
browser.browserAction.setBadgeTextColor({tabId: tab.id, color: "#FFFFFF"}); browser.browserAction.setBadgeTextColor({
tabId: tab.id,
color: "#FFFFFF",
});
browser.browserAction.setBadgeText({ tabId: tab.id, text: message }); browser.browserAction.setBadgeText({ tabId: tab.id, text: message });
}, 1000); }, 1000);
}); });

View file

@ -16,7 +16,5 @@
"default_title": "Test", "default_title": "Test",
"default_popup": "popup.html" "default_popup": "popup.html"
}, },
"permissions": [ "permissions": ["tabs"]
"tabs"
]
} }

View file

@ -1,17 +1,17 @@
<html> <html>
<head> <head>
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<title>Address_Form</title> <title>Address_Form</title>
</head> </head>
<body> <body>
<form> <form>
<p>Street Address: <input id="streetAddress" type="text"></p> <p>Street Address: <input id="streetAddress" type="text" /></p>
<p>City: <input id="city" type="text"></p> <p>City: <input id="city" type="text" /></p>
<p>Zip Code: <input id="zipCode" type="text"></p> <p>Zip Code: <input id="zipCode" type="text" /></p>
<p>Country: <input id="country" type="text"></p> <p>Country: <input id="country" type="text" /></p>
<p>Telephone: <input id="telephone" type="text"></p> <p>Telephone: <input id="telephone" type="text" /></p>
<p>Email: <input id="email" type="text"></p> <p>Email: <input id="email" type="text" /></p>
<p>Apartment, suite, etc. <input id="apartment" type="text"></p> <p>Apartment, suite, etc. <input id="apartment" type="text" /></p>
</form> </form>
</body> </body>
</html> </html>

View file

@ -6,7 +6,7 @@
<p id="testContent">Page content: audio player</p> <p id="testContent">Page content: audio player</p>
<div class="audioPlayer"> <div class="audioPlayer">
<audio id="audioSample" controls loop> <audio id="audioSample" controls loop>
<source src="../resources/audioSample.mp3"> <source src="../resources/audioSample.mp3" />
</audio> </audio>
</div> </div>
</body> </body>

View file

@ -1,17 +1,31 @@
<html> <html>
<head> <head>
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<title>Credit_Card_Form</title> <title>Credit_Card_Form</title>
</head> </head>
<body> <body>
<form> <form>
<p>Card information</p> <p>Card information</p>
<p>Card Number: <input id="cardNumber" type="text" placeholder="1234 1234 1234 1234"></p> <p>
<p>Name on card: <input id="nameOnCard"type="text" placeholder="Name on card"></p> Card Number:
<p> Expiry date: <input id="cardNumber" type="text" placeholder="1234 1234 1234 1234" />
<input id="expiryMonthAndYear" inputmode="numerical" placeholder="MM / YYYY" type="text" /> </p>
<p>
Name on card:
<input id="nameOnCard" type="text" placeholder="Name on card" />
</p>
<p>
Expiry date:
<input
id="expiryMonthAndYear"
inputmode="numerical"
placeholder="MM / YYYY"
type="text"
/>
</p>
<p>
<input type="submit" id="submit" value="Submit" aria-label="submit" />
</p> </p>
<p><input type="submit" id="submit" value="Submit" aria-label="submit"/></p>
</form> </form>
</body> </body>
</html> </html>

View file

@ -10,6 +10,10 @@
<h2>Cross-site cookies storage access test</h2> <h2>Cross-site cookies storage access test</h2>
<h3>anti-tracker-test.com</h3> <h3>anti-tracker-test.com</h3>
<h4>different site, cross-origin iframe</h4> <h4>different site, cross-origin iframe</h4>
<iframe width=500 height=1000 src="https://mozilla-mobile.github.io/testapp/anti-tracker-test_set_storage_with_sa_api.html"></iframe> <iframe
width="500"
height="1000"
src="https://mozilla-mobile.github.io/testapp/anti-tracker-test_set_storage_with_sa_api.html"
></iframe>
</body> </body>
</html> </html>

View file

@ -2,8 +2,8 @@
<html> <html>
<head> <head>
<title>Html_Control_Form</title> <title>Html_Control_Form</title>
<meta charset="utf-8"> <meta charset="utf-8" />
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
</head> </head>
<p>Misc Link Types</p> <p>Misc Link Types</p>
@ -24,6 +24,8 @@
</section> </section>
<section> <section>
<a href="http://play.google.com/store/apps/details?id=org.mozilla.firefox">Playstore link</a> <a href="http://play.google.com/store/apps/details?id=org.mozilla.firefox"
>Playstore link</a
>
</section> </section>
</html> </html>

View file

@ -6,7 +6,10 @@
<h1> <h1>
<p id="testContent">Page content: 3</p> <p id="testContent">Page content: 3</p>
<p> <p>
<a href="https://play.google.com/store/apps/details?id=org.mozilla.fenix">Mozilla Playstore link</a> <a
href="https://play.google.com/store/apps/details?id=org.mozilla.fenix"
>Mozilla Playstore link</a
>
</p> </p>
<p> <p>
<a href="../resources/pdfForm.pdf">PDF form file</a> <a href="../resources/pdfForm.pdf">PDF form file</a>

View file

@ -10,11 +10,11 @@
<a href="generic3.html">Link 3</a> <a href="generic3.html">Link 3</a>
<p> <p>
<a href="../resources/rabbit.jpg"> <a href="../resources/rabbit.jpg">
<img src="../resources/rabbit.jpg" alt="test_link_image"> <img src="../resources/rabbit.jpg" alt="test_link_image" />
</a> </a>
</p> </p>
<p> <p>
<img src="../resources/rabbit.jpg" alt="test_no_link_image"> <img src="../resources/rabbit.jpg" alt="test_no_link_image" />
</p> </p>
</body> </body>
</html> </html>

View file

@ -1,15 +1,14 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<body> <body>
<script type="text/javascript"> <script type="text/javascript">
const gpcValue = navigator.globalPrivacyControl const gpcValue = navigator.globalPrivacyControl;
if (gpcValue) { if (gpcValue) {
document.write('<p>GPC is enabled.</p>'); document.write("<p>GPC is enabled.</p>");
} else { } else {
document.write('<p>GPC not enabled.</p>'); document.write("<p>GPC not enabled.</p>");
} }
</script> </script>
</body> </body>
</html> </html>

View file

@ -1,19 +1,21 @@
<!DOCTYPE html> <!DOCTYPE html>
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="utf-8" /> <meta charset="utf-8" />
<title>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy <title>
eirmod tempor invidunt</title> Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
<meta content="width=device-width, initial-scale=1" eirmod tempor invidunt
name="viewport"/> </title>
<meta content="width=device-width, initial-scale=1" name="viewport" />
</head> </head>
<body> <body>
<p id="testContent">Page content: lorem ipsum</p> <p id="testContent">Page content: lorem ipsum</p>
<h1>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt</h1> <h1>
Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
eirmod tempor invidunt
</h1>
<p> <p>
Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
@ -21,16 +23,14 @@
voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet
clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit
amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam
nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed
sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum.
Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed
diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam
sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea
Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum
sit amet. dolor sit amet.
</p> </p>
</body> </body>
</html> </html>

View file

@ -1,4 +1,4 @@
<!DOCTYPE HTML> <!DOCTYPE html>
<!-- This Source Code Form is subject to the terms of the Mozilla Public <!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this - License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. --> - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
@ -15,9 +15,9 @@
<button onclick="play()">Play</button> <button onclick="play()">Play</button>
<button onclick="pause()">Pause</button> <button onclick="pause()">Pause</button>
<button onclick="fullscreen()">Full Screen</button> <button onclick="fullscreen()">Full Screen</button>
<br><br> <br /><br />
<video id="mutedVideo" width="420" autoplay muted controls loop> <video id="mutedVideo" width="420" autoplay muted controls loop>
<source src="../resources/clip.mp4" type="video/mp4"> <source src="../resources/clip.mp4" type="video/mp4" />
Your browser does not support HTML video. Your browser does not support HTML video.
</video> </video>
</div> </div>
@ -37,12 +37,14 @@
mutedVideo.requestFullscreen(); mutedVideo.requestFullscreen();
} }
mutedVideo.addEventListener('playing', (event) => { mutedVideo.addEventListener("playing", event => {
document.querySelector('.playbackState').innerHTML="Media file is playing"; document.querySelector(".playbackState").innerHTML =
"Media file is playing";
}); });
mutedVideo.addEventListener('pause', (event) => { mutedVideo.addEventListener("pause", event => {
document.querySelector('.playbackState').innerHTML="Media file is paused"; document.querySelector(".playbackState").innerHTML =
"Media file is paused";
}); });
</script> </script>
</body> </body>

View file

@ -1,22 +1,23 @@
<html> <html>
<head> <head>
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
</head> </head>
<body aria-label="body"> <body aria-label="body">
<form method="GET" action="passwordsubmit.html"> <form method="GET" action="passwordsubmit.html">
<p>Username: <input id="username" type="text" value="test@example.com"></p> <p>
<p>Password: <input id="password" type="password" value="verysecret"></p> Username: <input id="username" type="text" value="test@example.com" />
<p><input type="submit" id="submit" value="Login" aria-label="submit"/></p> </p>
<p>
Password: <input id="password" type="password" value="verysecret" />
</p>
<p>
<input type="submit" id="submit" value="Login" aria-label="submit" />
</p>
</form> </form>
</body> </body>
<script> <script>
document.getElementById("password").value = Math.random().toString(); document.getElementById("password").value = Math.random().toString();
</script> </script>
</html> </html>

View file

@ -1,6 +1,6 @@
<html> <html>
<head> <head>
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
</head> </head>
<body aria-label="body"> <body aria-label="body">
<p>Password submitted. Nope just a test.</p> <p>Password submitted. Nope just a test.</p>

View file

@ -1,18 +1,15 @@
<html> <html>
<script> <script>
function setCookie(newVal) { function setCookie(newVal) {
window.document.cookie = "pageStatus = " + newVal + ";"; window.document.cookie = "pageStatus = " + newVal + ";";
} }
function readCookie(name) { function readCookie(name) {
var nameEQ = name + "="; var nameEQ = name + "=";
var ca = document.cookie.split(';'); var ca = document.cookie.split(";");
for (var i = 0; i < ca.length; i++) { for (var i = 0; i < ca.length; i++) {
var c = ca[i]; var c = ca[i];
while (c.charAt(0)==' ') c = c.substring(1,c.length); while (c.charAt(0) == " ") c = c.substring(1, c.length);
if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length, c.length); if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length, c.length);
} }
return null; return null;
@ -34,8 +31,8 @@
} }
var textToShow = valSwap(); var textToShow = valSwap();
window.addEventListener('DOMContentLoaded', (event) => { window.addEventListener("DOMContentLoaded", event => {
document.querySelector('h1').innerHTML = textToShow; document.querySelector("h1").innerHTML = textToShow;
}); });
</script> </script>
<body> <body>

View file

@ -1,23 +1,21 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<body> <body>
<h1>Storage check</h1> <h1>Storage check</h1>
<script type="text/javascript"> <script type="text/javascript">
if (sessionStorage.getItem('sessionTest') == 'session storage') { if (sessionStorage.getItem("sessionTest") == "session storage") {
document.write('<p>Session storage has value</p>'); document.write("<p>Session storage has value</p>");
} else { } else {
document.write('<p>Session storage empty</p>'); document.write("<p>Session storage empty</p>");
} }
if (localStorage.getItem('localTest') == 'local storage') { if (localStorage.getItem("localTest") == "local storage") {
document.write('<p>Local storage has value</p>'); document.write("<p>Local storage has value</p>");
} else { } else {
document.write('<p>Local storage empty</p>'); document.write("<p>Local storage empty</p>");
} }
</script> </script>
</body> </body>
</html> </html>

View file

@ -1,8 +1,7 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<body> <body>
<h1>Storage Write</h1> <h1>Storage Write</h1>
<p id="cookies"></p> <p id="cookies"></p>
@ -10,19 +9,22 @@
<script type="text/javascript"> <script type="text/javascript">
(function () { (function () {
document.getElementById("cookies").textContent = document.cookie?document.cookie:"No cookies set"; document.getElementById("cookies").textContent = document.cookie
? document.cookie
: "No cookies set";
})(); })();
document.getElementById("setCookies").addEventListener("click", function() { document
.getElementById("setCookies")
.addEventListener("click", function () {
document.cookie = "user=android"; document.cookie = "user=android";
document.getElementById("cookies").textContent = document.cookie; document.getElementById("cookies").textContent = document.cookie;
}); });
sessionStorage.setItem('sessionTest', 'session storage'); sessionStorage.setItem("sessionTest", "session storage");
localStorage.setItem('localTest', 'local storage'); localStorage.setItem("localTest", "local storage");
document.write('<p>Values written to storage</p>'); document.write("<p>Values written to storage</p>");
</script> </script>
</body> </body>
</html> </html>

View file

@ -1,4 +1,4 @@
<!DOCTYPE HTML> <!DOCTYPE html>
<!-- This Source Code Form is subject to the terms of the Mozilla Public <!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this - License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. --> - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
@ -15,9 +15,9 @@
<button onclick="play()">Play</button> <button onclick="play()">Play</button>
<button onclick="pause()">Pause</button> <button onclick="pause()">Pause</button>
<button onclick="fullscreen()">Full Screen</button> <button onclick="fullscreen()">Full Screen</button>
<br><br> <br /><br />
<video id="video" width="420" autoplay controls loop> <video id="video" width="420" autoplay controls loop>
<source src="../resources/clip.mp4" type="video/mp4"> <source src="../resources/clip.mp4" type="video/mp4" />
Your browser does not support HTML video. Your browser does not support HTML video.
</video> </video>
</div> </div>
@ -37,12 +37,14 @@
video.requestFullscreen(); video.requestFullscreen();
} }
video.addEventListener('playing', (event) => { video.addEventListener("playing", event => {
document.querySelector('.playbackState').innerHTML="Media file is playing"; document.querySelector(".playbackState").innerHTML =
"Media file is playing";
}); });
video.addEventListener('pause', (event) => { video.addEventListener("pause", event => {
document.querySelector('.playbackState').innerHTML="Media file is paused"; document.querySelector(".playbackState").innerHTML =
"Media file is paused";
}); });
</script> </script>
</body> </body>

View file

@ -8,19 +8,17 @@
*/ */
EnableEngines(["bookmarks"]); EnableEngines(["bookmarks"]);
var phases = { "phase1": "profile1" }; var phases = { phase1: "profile1" };
// expected bookmark state // expected bookmark state
var bookmarksCreated = { var bookmarksCreated = {
"mobile": [{ mobile: [
{
uri: "http://www.example.com/", uri: "http://www.example.com/",
title: "Example Domain"}] title: "Example Domain",
},
],
}; };
// sync and verify bookmarks // sync and verify bookmarks
Phase("phase1", [ Phase("phase1", [[Sync], [Bookmarks.add, bookmarksCreated], [Sync]]);
[Sync],
[Bookmarks.add, bookmarksCreated],
[Sync]
]);

View file

@ -8,18 +8,17 @@
*/ */
EnableEngines(["bookmarks"]); EnableEngines(["bookmarks"]);
var phases = { "phase1": "profile1" }; var phases = { phase1: "profile1" };
// expected bookmark state // expected bookmark state
var bookmarksExpected = { var bookmarksExpected = {
"mobile": [{ mobile: [
{
uri: "http://www.example.com/", uri: "http://www.example.com/",
title: "Example Domain"}] title: "Example Domain",
},
],
}; };
// sync and verify bookmarks // sync and verify bookmarks
Phase("phase1", [ Phase("phase1", [[Sync], [Bookmarks.verify, bookmarksExpected]]);
[Sync],
[Bookmarks.verify, bookmarksExpected],
]);

View file

@ -8,26 +8,18 @@
*/ */
EnableEngines(["history"]); EnableEngines(["history"]);
var phases = { "phase1": "profile1" }; var phases = { phase1: "profile1" };
// expected history state // expected history state
var historyCreated = [ var historyCreated = [
{ uri: "http://www.example.com/", {
uri: "http://www.example.com/",
visits: [ visits: [
{ type: 1 , { type: 1, date: 0 },
date: 0 { type: 2, date: -1 },
],
}, },
{ type: 2,
date: -1
}
]
}
]; ];
// sync and verify history // sync and verify history
Phase("phase1", [ Phase("phase1", [[Sync], [History.add, historyCreated], [Sync]]);
[Sync],
[History.add, historyCreated],
[Sync]
]);

View file

@ -8,21 +8,12 @@
*/ */
EnableEngines(["history"]); EnableEngines(["history"]);
var phases = { "phase1": "profile1" }; var phases = { phase1: "profile1" };
// expected history state // expected history state
var historyExpected = [ var historyExpected = [
{ uri: "http://www.example.com/", { uri: "http://www.example.com/", visits: [{ type: 1 }, { type: 2 }] },
visits: [
{ type: 1 },
{ type: 2 }
]
}
]; ];
// sync and verify history // sync and verify history
Phase("phase1", [ Phase("phase1", [[Sync], [History.verify, historyExpected]]);
[Sync],
[History.verify, historyExpected]
]);

View file

@ -8,11 +8,11 @@
*/ */
EnableEngines(["passwords"]); EnableEngines(["passwords"]);
var phases = { "phase1": "profile1" }; var phases = { phase1: "profile1" };
// expected tabs state // expected tabs state
var password_list = [{ var password_list = [
{
hostname: "https://accounts.google.com", hostname: "https://accounts.google.com",
submitURL: "https://accounts.google.com/signin/challenge/sl/password", submitURL: "https://accounts.google.com/signin/challenge/sl/password",
realm: null, realm: null,
@ -20,11 +20,8 @@ var password_list = [{
password: "test15mz", password: "test15mz",
usernameField: "Email", usernameField: "Email",
passwordField: "Passwd", passwordField: "Passwd",
}]; },
];
// sync and verify tabs // sync and verify tabs
Phase("phase1", [ Phase("phase1", [[Sync], [Passwords.add, password_list], [Sync]]);
[Sync],
[Passwords.add, password_list],
[Sync]
]);

View file

@ -6,12 +6,12 @@
* Handles the parsing of the ErrorPages URI and then passes them to injectValues * Handles the parsing of the ErrorPages URI and then passes them to injectValues
*/ */
function parseQuery(queryString) { function parseQuery(queryString) {
if (queryString[0] === '?') { if (queryString[0] === "?") {
queryString = queryString.substr(1); queryString = queryString.substr(1);
} }
const query = Object.fromEntries(new URLSearchParams(queryString).entries()); const query = Object.fromEntries(new URLSearchParams(queryString).entries());
injectValues(query); injectValues(query);
}; }
/** /**
* Updates the HTML elements based on the queryMap * Updates the HTML elements based on the queryMap
@ -19,11 +19,11 @@ function parseQuery(queryString) {
function injectValues(queryMap) { function injectValues(queryMap) {
// Go through each element and inject the values // Go through each element and inject the values
document.title = queryMap.title; document.title = queryMap.title;
document.getElementById('errorTitleText').innerHTML = queryMap.title; document.getElementById("errorTitleText").innerHTML = queryMap.title;
document.getElementById('errorShortDesc').innerHTML = queryMap.description; document.getElementById("errorShortDesc").innerHTML = queryMap.description;
// If no image is passed in, remove the element so as not to leave an empty iframe // If no image is passed in, remove the element so as not to leave an empty iframe
const errorImage = document.getElementById('errorImage'); const errorImage = document.getElementById("errorImage");
if (!queryMap.image) { if (!queryMap.image) {
errorImage.remove(); errorImage.remove();
} else { } else {
@ -31,11 +31,13 @@ function injectValues(queryMap) {
} }
} }
document.addEventListener('DOMContentLoaded', function () { document.addEventListener("DOMContentLoaded", function () {
if (window.history.length == 1) { if (window.history.length == 1) {
document.getElementById('backButton').style.display = 'none'; document.getElementById("backButton").style.display = "none";
} else { } else {
document.getElementById('backButton').addEventListener('click', () => window.history.back() ); document
.getElementById("backButton")
.addEventListener("click", () => window.history.back());
} }
}); });

View file

@ -8,7 +8,10 @@
<head> <head>
<meta charset="UTF-8" /> <meta charset="UTF-8" />
<meta name="viewport" content="width=device-width; user-scalable=false;" /> <meta name="viewport" content="width=device-width; user-scalable=false;" />
<meta http-equiv="Content-Security-Policy" content="default-src resource:; object-src 'none'" /> <meta
http-equiv="Content-Security-Policy"
content="default-src resource:; object-src 'none'"
/>
<link rel="stylesheet" type="text/css" href="shared_error_style.css" /> <link rel="stylesheet" type="text/css" href="shared_error_style.css" />
<link rel="stylesheet" type="text/css" href="high_risk_error_style.css" /> <link rel="stylesheet" type="text/css" href="high_risk_error_style.css" />
</head> </head>

View file

@ -6,37 +6,41 @@
* Handles the parsing of the ErrorPages URI and then passes them to injectValues * Handles the parsing of the ErrorPages URI and then passes them to injectValues
*/ */
function parseQuery(queryString) { function parseQuery(queryString) {
if (queryString[0] === '?') { if (queryString[0] === "?") {
queryString = queryString.substr(1); queryString = queryString.substr(1);
} }
const query = Object.fromEntries(new URLSearchParams(queryString).entries()); const query = Object.fromEntries(new URLSearchParams(queryString).entries());
injectValues(query); injectValues(query);
updateShowSSL(query); updateShowSSL(query);
updateShowHSTS(query); updateShowHSTS(query);
}; }
/** /**
* Updates the HTML elements based on the queryMap * Updates the HTML elements based on the queryMap
*/ */
function injectValues(queryMap) { function injectValues(queryMap) {
const tryAgainButton = document.getElementById('errorTryAgain'); const tryAgainButton = document.getElementById("errorTryAgain");
const continueHttpButton = document.getElementById("continueHttp"); const continueHttpButton = document.getElementById("continueHttp");
const backFromHttpButton = document.getElementById('backFromHttp'); const backFromHttpButton = document.getElementById("backFromHttp");
// Go through each element and inject the values // Go through each element and inject the values
document.title = queryMap.title; document.title = queryMap.title;
tryAgainButton.innerHTML = queryMap.button; tryAgainButton.innerHTML = queryMap.button;
continueHttpButton.innerHTML = queryMap.continueHttpButton; continueHttpButton.innerHTML = queryMap.continueHttpButton;
backFromHttpButton.innerHTML = queryMap.badCertGoBack; backFromHttpButton.innerHTML = queryMap.badCertGoBack;
document.getElementById('errorTitleText').innerHTML = queryMap.title; document.getElementById("errorTitleText").innerHTML = queryMap.title;
document.getElementById('errorShortDesc').innerHTML = queryMap.description; document.getElementById("errorShortDesc").innerHTML = queryMap.description;
document.getElementById('advancedButton').innerHTML = queryMap.badCertAdvanced; document.getElementById("advancedButton").innerHTML =
document.getElementById('badCertTechnicalInfo').innerHTML = queryMap.badCertTechInfo; queryMap.badCertAdvanced;
document.getElementById('advancedPanelBackButton').innerHTML = queryMap.badCertGoBack; document.getElementById("badCertTechnicalInfo").innerHTML =
document.getElementById('advancedPanelAcceptButton').innerHTML = queryMap.badCertAcceptTemporary; queryMap.badCertTechInfo;
document.getElementById("advancedPanelBackButton").innerHTML =
queryMap.badCertGoBack;
document.getElementById("advancedPanelAcceptButton").innerHTML =
queryMap.badCertAcceptTemporary;
// If no image is passed in, remove the element so as not to leave an empty iframe // If no image is passed in, remove the element so as not to leave an empty iframe
const errorImage = document.getElementById('errorImage'); const errorImage = document.getElementById("errorImage");
if (!queryMap.image) { if (!queryMap.image) {
errorImage.remove(); errorImage.remove();
} else { } else {
@ -46,12 +50,12 @@ function injectValues(queryMap) {
if (queryMap.showContinueHttp === "true") { if (queryMap.showContinueHttp === "true") {
// On the "HTTPS-Only" error page "Try again" doesn't make sense since reloading the page // On the "HTTPS-Only" error page "Try again" doesn't make sense since reloading the page
// will just show an error page again. // will just show an error page again.
tryAgainButton.style.display = 'none'; tryAgainButton.style.display = "none";
} else { } else {
continueHttpButton.style.display = 'none'; continueHttpButton.style.display = "none";
backFromHttpButton.style.display = 'none'; backFromHttpButton.style.display = "none";
}
} }
};
let advancedVisible = false; let advancedVisible = false;
@ -61,37 +65,37 @@ let advancedVisible = false;
function updateShowSSL(queryMap) { function updateShowSSL(queryMap) {
/** @type {'true' | 'false'} */ /** @type {'true' | 'false'} */
const showSSL = queryMap.showSSL; const showSSL = queryMap.showSSL;
if (typeof document.addCertException === 'undefined') { if (typeof document.addCertException === "undefined") {
document.getElementById('advancedButton').style.display='none'; document.getElementById("advancedButton").style.display = "none";
} else { } else {
if (showSSL === 'true') { if (showSSL === "true") {
document.getElementById('advancedButton').style.display='block'; document.getElementById("advancedButton").style.display = "block";
} else { } else {
document.getElementById('advancedButton').style.display='none'; document.getElementById("advancedButton").style.display = "none";
}
} }
} }
};
/** /**
* Used to show or hide the "accept" button based for the HSTS error page * Used to show or hide the "accept" button based for the HSTS error page
*/ */
function updateShowHSTS(queryMap) { function updateShowHSTS(queryMap) {
const showHSTS = queryMap.showHSTS; const showHSTS = queryMap.showHSTS;
if (showHSTS === 'true') { if (showHSTS === "true") {
document.getElementById('advancedButton').style.display='block'; document.getElementById("advancedButton").style.display = "block";
document.getElementById('advancedPanelAcceptButton').style.display='none'; document.getElementById("advancedPanelAcceptButton").style.display = "none";
}
} }
};
/** /**
* Used to display information about the SSL certificate in `error_pages.html` * Used to display information about the SSL certificate in `error_pages.html`
*/ */
function toggleAdvancedAndScroll() { function toggleAdvancedAndScroll() {
const advancedPanel = document.getElementById('badCertAdvancedPanel'); const advancedPanel = document.getElementById("badCertAdvancedPanel");
if (advancedVisible) { if (advancedVisible) {
advancedPanel.style.display='none'; advancedPanel.style.display = "none";
} else { } else {
advancedPanel.style.display='block'; advancedPanel.style.display = "block";
} }
advancedVisible = !advancedVisible; advancedVisible = !advancedVisible;
@ -99,9 +103,7 @@ function toggleAdvancedAndScroll() {
const advancedPanelAcceptButton = document.getElementById( const advancedPanelAcceptButton = document.getElementById(
"advancedPanelAcceptButton" "advancedPanelAcceptButton"
); );
const badCertAdvancedPanel = document.getElementById( const badCertAdvancedPanel = document.getElementById("badCertAdvancedPanel");
"badCertAdvancedPanel"
);
// We know that the button is being displayed // We know that the button is being displayed
if (badCertAdvancedPanel.style.display === "block") { if (badCertAdvancedPanel.style.display === "block") {
@ -114,7 +116,7 @@ function toggleAdvancedAndScroll() {
} else { } else {
horizontalLine.hidden = true; horizontalLine.hidden = true;
} }
}; }
/** /**
* Used to bypass an SSL pages in `error_pages.html` * Used to bypass an SSL pages in `error_pages.html`
@ -126,21 +128,33 @@ async function acceptAndContinue(temporary) {
} catch (error) { } catch (error) {
console.error("Unexpected error: " + error); console.error("Unexpected error: " + error);
} }
};
document.addEventListener('DOMContentLoaded', function () {
if (window.history.length == 1) {
document.getElementById('advancedPanelBackButton').style.display = 'none';
document.getElementById('backFromHttp').style.display = 'none';
} else {
document.getElementById('advancedPanelBackButton').addEventListener('click', () => window.history.back());
document.getElementById('backFromHttp').addEventListener('click', () => window.history.back());
} }
document.getElementById('errorTryAgain').addEventListener('click', () => window.location.reload()); document.addEventListener("DOMContentLoaded", function () {
document.getElementById('advancedButton').addEventListener('click', toggleAdvancedAndScroll); if (window.history.length == 1) {
document.getElementById('advancedPanelAcceptButton').addEventListener('click', () => acceptAndContinue(true)); document.getElementById("advancedPanelBackButton").style.display = "none";
document.getElementById('continueHttp').addEventListener('click', () => document.reloadWithHttpsOnlyException()); document.getElementById("backFromHttp").style.display = "none";
} else {
document
.getElementById("advancedPanelBackButton")
.addEventListener("click", () => window.history.back());
document
.getElementById("backFromHttp")
.addEventListener("click", () => window.history.back());
}
document
.getElementById("errorTryAgain")
.addEventListener("click", () => window.location.reload());
document
.getElementById("advancedButton")
.addEventListener("click", toggleAdvancedAndScroll);
document
.getElementById("advancedPanelAcceptButton")
.addEventListener("click", () => acceptAndContinue(true));
document
.getElementById("continueHttp")
.addEventListener("click", () => document.reloadWithHttpsOnlyException());
}); });
parseQuery(document.documentURI); parseQuery(document.documentURI);

View file

@ -8,7 +8,10 @@
<head> <head>
<meta charset="UTF-8" /> <meta charset="UTF-8" />
<meta name="viewport" content="width=device-width; user-scalable=false;" /> <meta name="viewport" content="width=device-width; user-scalable=false;" />
<meta http-equiv="Content-Security-Policy" content="default-src resource:; object-src 'none'" /> <meta
http-equiv="Content-Security-Policy"
content="default-src resource:; object-src 'none'"
/>
<link rel="stylesheet" type="text/css" href="shared_error_style.css" /> <link rel="stylesheet" type="text/css" href="shared_error_style.css" />
<link <link
rel="stylesheet" rel="stylesheet"
@ -37,10 +40,7 @@
<button id="errorTryAgain"></button> <button id="errorTryAgain"></button>
<!-- Advanced Button --> <!-- Advanced Button -->
<button <button id="advancedButton" class="buttonSecondary hidden"></button>
id="advancedButton"
class="buttonSecondary hidden"
></button>
<!-- "Go back" Button (For HTTPS-Only error page only) --> <!-- "Go back" Button (For HTTPS-Only error page only) -->
<button id="backFromHttp"></button> <button id="backFromHttp"></button>
@ -56,9 +56,7 @@
id="advancedPanelBackButtonContainer" id="advancedPanelBackButtonContainer"
class="advancedPanelButtonContainer" class="advancedPanelButtonContainer"
> >
<button <button id="advancedPanelBackButton"></button>
id="advancedPanelBackButton"
></button>
</div> </div>
<div <div
id="advancedPanelAcceptButtonContainer" id="advancedPanelAcceptButtonContainer"
@ -76,7 +74,7 @@
<script type="text/javascript"> <script type="text/javascript">
if (window.history.length == 1) { if (window.history.length == 1) {
document.getElementById('advancedPanelBackButton').style.display = 'none'; document.getElementById("advancedPanelBackButton").style.display = "none";
} }
function toggleAdvancedAndScroll() { function toggleAdvancedAndScroll() {

View file

@ -7,18 +7,17 @@
<div class="audioPlayer"> <div class="audioPlayer">
<audio id="audioSample" controls loop> <audio id="audioSample" controls loop>
<source src="resources/audioSample.mp3"> <source src="resources/audioSample.mp3" />
</audio> </audio>
</div> </div>
<div class="playbackState"> <div class="playbackState"></div>
</div>
<script> <script>
const audio = document.querySelector('audio'); const audio = document.querySelector("audio");
var showPlayingAlert = true; var showPlayingAlert = true;
audio.addEventListener('playing', (event) => { audio.addEventListener("playing", event => {
<!--document.querySelector('.playbackState').innerText="Media file is playing"--> <!--document.querySelector('.playbackState').innerText="Media file is playing"-->
<!--Need this hack to verify that the video is playing,--> <!--Need this hack to verify that the video is playing,-->
<!--the test cannot currently verify the text displayed on the page--> <!--the test cannot currently verify the text displayed on the page-->
@ -28,7 +27,7 @@
} }
}); });
audio.addEventListener('pause', (event) => { audio.addEventListener("pause", event => {
<!--document.querySelector('.playbackState').innerText="Media file is paused"--> <!--document.querySelector('.playbackState').innerText="Media file is paused"-->
alert("Media file is paused"); alert("Media file is paused");
}); });

View file

@ -1,12 +1,16 @@
<!DOCTYPE HTML> <!DOCTYPE html>
<!-- This Source Code Form is subject to the terms of the Mozilla Public <!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this - License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. --> - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<html> <html>
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<body> <body>
<h3>known-tracker.englehardt-tracker.com</h3> <h3>known-tracker.englehardt-tracker.com</h3>
<h4>different site, cross-origin iframe, on blocklist</h4> <h4>different site, cross-origin iframe, on blocklist</h4>
<iframe width=500 height=600 src="https://known-tracker.englehardt-tracker.com/set_storage_simple.html"></iframe> <iframe
width="500"
height="600"
src="https://known-tracker.englehardt-tracker.com/set_storage_simple.html"
></iframe>
</body> </body>
</html> </html>

View file

@ -1,11 +1,11 @@
<!DOCTYPE HTML> <!DOCTYPE html>
<!-- This Source Code Form is subject to the terms of the Mozilla Public <!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this - License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. --> - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<html dir="ltr" xml:lang="en-US" lang="en-US"> <html dir="ltr" xml:lang="en-US" lang="en-US">
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8" />
<title>adsTrackers</title> <title>adsTrackers</title>
</head> </head>
<body> <body>
@ -16,6 +16,7 @@
<p>ads trackers not blocked</p> <p>ads trackers not blocked</p>
<img <img
src="https://ads-track-digest256.dummytracker.org/test_not_blocked.png" src="https://ads-track-digest256.dummytracker.org/test_not_blocked.png"
onerror="this.onerror=null;this.src='https://not-a-tracker.dummytracker.org/test_blocked.png';alert('ads trackers blocked')"> onerror="this.onerror=null;this.src='https://not-a-tracker.dummytracker.org/test_blocked.png';alert('ads trackers blocked')"
/>
</body> </body>
</html> </html>

View file

@ -1,11 +1,11 @@
<!DOCTYPE HTML> <!DOCTYPE html>
<!-- This Source Code Form is subject to the terms of the Mozilla Public <!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this - License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. --> - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<html dir="ltr" xml:lang="en-US" lang="en-US"> <html dir="ltr" xml:lang="en-US" lang="en-US">
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8" />
<title>analyticsTrackers</title> <title>analyticsTrackers</title>
</head> </head>
<body> <body>
@ -16,6 +16,7 @@
<p>analytics trackers not blocked</p> <p>analytics trackers not blocked</p>
<img <img
src="https://analytics-track-digest256.dummytracker.org/test_not_blocked.png" src="https://analytics-track-digest256.dummytracker.org/test_not_blocked.png"
onerror="this.onerror=null;this.src='https://not-a-tracker.dummytracker.org/test_blocked.png';alert('analytics trackers blocked')"> onerror="this.onerror=null;this.src='https://not-a-tracker.dummytracker.org/test_blocked.png';alert('analytics trackers blocked')"
/>
</body> </body>
</html> </html>

View file

@ -1,11 +1,11 @@
<!DOCTYPE HTML> <!DOCTYPE html>
<!-- This Source Code Form is subject to the terms of the Mozilla Public <!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this - License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. --> - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<html dir="ltr" xml:lang="en-US" lang="en-US"> <html dir="ltr" xml:lang="en-US" lang="en-US">
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8" />
<title>otherTrackers</title> <title>otherTrackers</title>
</head> </head>
<body> <body>
@ -17,6 +17,7 @@
<p>other content trackers not blocked</p> <p>other content trackers not blocked</p>
<img <img
src="https://content-track-digest256.dummytracker.org/test_not_blocked.png" src="https://content-track-digest256.dummytracker.org/test_not_blocked.png"
onerror="this.onerror=null;this.src='https://not-a-tracker.dummytracker.org/test_blocked.png';alert('other content trackers blocked')"> onerror="this.onerror=null;this.src='https://not-a-tracker.dummytracker.org/test_blocked.png';alert('other content trackers blocked')"
/>
</body> </body>
</html> </html>

View file

@ -1,11 +1,11 @@
<!DOCTYPE HTML> <!DOCTYPE html>
<!-- This Source Code Form is subject to the terms of the Mozilla Public <!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this - License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. --> - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<html dir="ltr" xml:lang="en-US" lang="en-US"> <html dir="ltr" xml:lang="en-US" lang="en-US">
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8" />
<title>socialTrackers</title> <title>socialTrackers</title>
</head> </head>
<body> <body>
@ -16,6 +16,7 @@
<p>social trackers not blocked</p> <p>social trackers not blocked</p>
<img <img
src="https://social-track-digest256.dummytracker.org/test_not_blocked.png" src="https://social-track-digest256.dummytracker.org/test_not_blocked.png"
onerror="this.onerror=null;this.src='https://not-a-tracker.dummytracker.org/test_blocked.png';alert('social trackers blocked')"> onerror="this.onerror=null;this.src='https://not-a-tracker.dummytracker.org/test_blocked.png';alert('social trackers blocked')"
/>
</body> </body>
</html> </html>

View file

@ -1,7 +1,7 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8" />
<!-- random words that should not end up on disk --> <!-- random words that should not end up on disk -->
<title>GenericPage</title> <title>GenericPage</title>
</head> </head>
@ -10,6 +10,5 @@
<!-- More random words that should not end up on disk --> <!-- More random words that should not end up on disk -->
<p>groovy rabbits</p> <p>groovy rabbits</p>
<p>This test page does nothing.</p> <p>This test page does nothing.</p>
</body> </body>
</html> </html>

View file

@ -1,15 +1,14 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<body> <body>
<script type="text/javascript"> <script type="text/javascript">
const gpcValue = navigator.globalPrivacyControl const gpcValue = navigator.globalPrivacyControl;
if (gpcValue) { if (gpcValue) {
document.write('<p>GPC is enabled.</p>'); document.write("<p>GPC is enabled.</p>");
} else { } else {
document.write('<p>GPC not enabled.</p>'); document.write("<p>GPC not enabled.</p>");
} }
</script> </script>
</body> </body>
</html> </html>

View file

@ -2,8 +2,8 @@
<html> <html>
<head> <head>
<title>Html_Control_Form</title> <title>Html_Control_Form</title>
<meta charset="utf-8"> <meta charset="utf-8" />
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
</head> </head>
<p>Misc Link Types</p> <p>Misc Link Types</p>
@ -21,18 +21,20 @@
<option type="text" text="The Only Ones">The Only Ones</option> <option type="text" text="The Only Ones">The Only Ones</option>
<option type="text" text="The National">The National</option> <option type="text" text="The National">The National</option>
</select> </select>
<button onclick="printOption()" id="submitOption"> Submit drop down option </button> <button onclick="printOption()" id="submitOption">
Submit drop down option
</button>
<div id="displayOption"></div> <div id="displayOption"></div>
<section> <section>
<p>Copy <input type="text" placeholder="and Paste" id="textInput"> me</p> <p>Copy <input type="text" placeholder="and Paste" id="textInput" /> me</p>
<button onclick="printInput()" id="submitInput">Submit input</button> <button onclick="printInput()" id="submitInput">Submit input</button>
<div id="displayInput"></div> <div id="displayInput"></div>
</section> </section>
<p>Calendar Form</p> <p>Calendar Form</p>
<section> <section>
<input type="date" id="calendar"> <input type="date" id="calendar" />
<button onclick="printDate()" id="submitDate">Submit date</button> <button onclick="printDate()" id="submitDate">Submit date</button>
<div id="displayDate"></div> <div id="displayDate"></div>
</section> </section>

View file

@ -1,7 +1,7 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8" />
<!-- random words that should not end up on disk --> <!-- random words that should not end up on disk -->
<title>gigantic experience</title> <title>gigantic experience</title>
</head> </head>
@ -10,11 +10,22 @@
<!-- More random words that should not end up on disk --> <!-- More random words that should not end up on disk -->
<p>groovy rabbits</p> <p>groovy rabbits</p>
<img id="rabbitImage" src="rabbit.jpg" alt="rabbit.jpg" width="251" height="201"> <img
id="rabbitImage"
src="rabbit.jpg"
alt="rabbit.jpg"
width="251"
height="201"
/>
<a id="download" href="download.jpg" download="mozillaLogo"> <a id="download" href="download.jpg" download="mozillaLogo">
<img border="0" src="download.jpg" alt="download icon" width="104" height="142"> <img
border="0"
src="download.jpg"
alt="download icon"
width="104"
height="142"
/>
</a> </a>
</body> </body>
</html> </html>

View file

@ -4,15 +4,14 @@
</head> </head>
<body> <body>
<p id="testContent">Page content: muted video player</p> <p id="testContent">Page content: muted video player</p>
<div class="playbackState"> <div class="playbackState"></div>
</div>
<div id="video-container" style="text-align: center"> <div id="video-container" style="text-align: center">
<button onclick="play()">Play</button> <button onclick="play()">Play</button>
<button onclick="pause()">Pause</button> <button onclick="pause()">Pause</button>
<button onclick="fullscreen()">Full Screen</button> <button onclick="fullscreen()">Full Screen</button>
<br><br> <br /><br />
<video id="mutedVideo" width="420" autoplay muted controls loop> <video id="mutedVideo" width="420" autoplay muted controls loop>
<source src="resources/clip.mp4" type="video/mp4"> <source src="resources/clip.mp4" type="video/mp4" />
Your browser does not support HTML video. Your browser does not support HTML video.
</video> </video>
</div> </div>
@ -34,7 +33,7 @@
var showPlayAlert = true; var showPlayAlert = true;
mutedVideo.addEventListener('playing', (event) => { mutedVideo.addEventListener("playing", event => {
<!-- document.querySelector('.playbackState').innerHTML="Media file is playing";--> <!-- document.querySelector('.playbackState').innerHTML="Media file is playing";-->
<!-- Need this hack to verify that the video is playing, --> <!-- Need this hack to verify that the video is playing, -->
<!-- the test cannot currently verify the text displayed on the page--> <!-- the test cannot currently verify the text displayed on the page-->
@ -44,7 +43,7 @@
} }
}); });
mutedVideo.addEventListener('pause', (event) => { mutedVideo.addEventListener("pause", event => {
// document.querySelector('.playbackState').innerHTML="Media file is paused"; // document.querySelector('.playbackState').innerHTML="Media file is paused";
alert("Media file is paused"); alert("Media file is paused");
}); });

View file

@ -1,15 +1,15 @@
<!DOCTYPE HTML> <!DOCTYPE html>
<!-- This Source Code Form is subject to the terms of the Mozilla Public <!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this - License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. --> - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<html lang="en-US" dir="ltr"> <html lang="en-US" dir="ltr">
<head> <head>
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<script src="https://cdn.jsdelivr.net/npm/idb-keyval@3/dist/idb-keyval-iife.min.js"></script> <script src="https://cdn.jsdelivr.net/npm/idb-keyval@3/dist/idb-keyval-iife.min.js"></script>
</head> </head>
<body> <body>
<button onclick="setAllStorageLocations();">Rerun Tests</button> <button onclick="setAllStorageLocations();">Rerun Tests</button>
<br> <br />
<h4>cookies</h4> <h4>cookies</h4>
<pre id="cookie_message"></pre> <pre id="cookie_message"></pre>
@ -26,11 +26,14 @@
<!-- Storage access API --> <!-- Storage access API -->
<br /> <br />
<h4>Storage Access API</h4> <h4>Storage Access API</h4>
<button onclick='requestSA()'>requestStorageAccess()</button><br /> <button onclick="requestSA()">requestStorageAccess()</button><br />
<p>Return value of requestStorageAccess():</p><pre id='request_storage_access'>not yet called</pre><br /> <p>Return value of requestStorageAccess():</p>
<button onclick='hasSA()'>hasStorageAccess()</button><br /> <pre id="request_storage_access">not yet called</pre>
<p>Return value of hasStorageAccess():</p><pre id='has_storage_access'>not yet called</pre><br /> <br />
<button onclick="hasSA()">hasStorageAccess()</button><br />
<p>Return value of hasStorageAccess():</p>
<pre id="has_storage_access">not yet called</pre>
<br />
<script> <script>
var newRandVal = Math.random(); var newRandVal = Math.random();
@ -38,62 +41,65 @@
function outputResult(value, output_id) { function outputResult(value, output_id) {
var msg = document.getElementById(output_id); var msg = document.getElementById(output_id);
document.hasStorageAccess().then( document.hasStorageAccess().then(
(hasStorageAccess) => { hasStorageAccess => {
if (hasStorageAccess === false) { if (hasStorageAccess === false) {
msg.innerHTML = "BLOCKED"; msg.innerHTML = "BLOCKED";
} else if (value === "" & hasStorageAccess === true) { } else if ((value === "") & (hasStorageAccess === true)) {
msg.innerHTML = "UNEXPECTED. We have storage access but value is empty..."; msg.innerHTML =
"UNEXPECTED. We have storage access but value is empty...";
} else if (hasStorageAccess === true) { } else if (hasStorageAccess === true) {
msg.innerHTML = "UNRESTRICTED"; msg.innerHTML = "UNRESTRICTED";
} }
}, },
(reason) => {msg.innerHTML = 'promise rejected for reason' + reason} reason => {
msg.innerHTML = "promise rejected for reason" + reason;
}
); );
} }
function setCookies() { function setCookies() {
var cookies = document.cookie; var cookies = document.cookie;
if (cookies === "") { if (cookies === "") {
document.cookie = 'foo='+newRandVal+'; SameSite=None; Secure'; document.cookie = "foo=" + newRandVal + "; SameSite=None; Secure";
cookies = document.cookie; cookies = document.cookie;
} }
outputResult(cookies, 'cookie_message'); outputResult(cookies, "cookie_message");
} }
function setLocalStorage() { function setLocalStorage() {
try { try {
var foo = window.localStorage.getItem('foo'); var foo = window.localStorage.getItem("foo");
if (foo === null) { if (foo === null) {
window.localStorage.setItem('foo', newRandVal); window.localStorage.setItem("foo", newRandVal);
foo = window.localStorage.getItem('foo'); foo = window.localStorage.getItem("foo");
} }
} catch (error) { } catch (error) {
foo = ""; foo = "";
} }
outputResult(foo, 'ls_message'); outputResult(foo, "ls_message");
} }
function setSessionStorage() { function setSessionStorage() {
try { try {
var foo = window.sessionStorage.getItem('foo'); var foo = window.sessionStorage.getItem("foo");
if (foo === null) { if (foo === null) {
window.sessionStorage.setItem('foo', newRandVal); window.sessionStorage.setItem("foo", newRandVal);
foo = window.sessionStorage.getItem('foo'); foo = window.sessionStorage.getItem("foo");
} }
} catch (error) { } catch (error) {
foo = ""; foo = "";
} }
outputResult(foo, 'ss_message'); outputResult(foo, "ss_message");
} }
async function setIndexedDB() { async function setIndexedDB() {
try { try {
var foo = await idbKeyval.get('foo'); var foo = await idbKeyval.get("foo");
if (foo === undefined) { if (foo === undefined) {
await idbKeyval.set('foo', newRandVal); await idbKeyval.set("foo", newRandVal);
foo = await idbKeyval.get('foo'); foo = await idbKeyval.get("foo");
} }
} catch (error) { } catch (error) {
foo = ""; foo = "";
} }
outputResult(foo, 'idb_message'); outputResult(foo, "idb_message");
} }
function setAllStorageLocations() { function setAllStorageLocations() {
setCookies(); setCookies();
@ -105,18 +111,26 @@
// Storage Access API // Storage Access API
function requestSA() { function requestSA() {
var result = document.getElementById('request_storage_access'); var result = document.getElementById("request_storage_access");
document.requestStorageAccess().then( document.requestStorageAccess().then(
() => {result.innerHTML = 'access granted'}, () => {
() => {result.innerHTML = 'access denied'} result.innerHTML = "access granted";
},
() => {
result.innerHTML = "access denied";
}
); );
} }
function hasSA() { function hasSA() {
var result = document.getElementById('has_storage_access'); var result = document.getElementById("has_storage_access");
document.hasStorageAccess().then( document.hasStorageAccess().then(
(hasAccess) => {result.innerHTML = hasAccess}, hasAccess => {
(reason) => {result.innerHTML = 'promise rejected for reason' + reason} result.innerHTML = hasAccess;
},
reason => {
result.innerHTML = "promise rejected for reason" + reason;
}
); );
} }
hasSA(); hasSA();

View file

@ -1,23 +1,21 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<body> <body>
<h1>Storage check</h1> <h1>Storage check</h1>
<script type="text/javascript"> <script type="text/javascript">
if (sessionStorage.getItem('focusSessionTest') == 'caterpillar') { if (sessionStorage.getItem("focusSessionTest") == "caterpillar") {
document.write('<p>Session storage has value</p>'); document.write("<p>Session storage has value</p>");
} else { } else {
document.write('<p>Session storage empty</p>'); document.write("<p>Session storage empty</p>");
} }
if (localStorage.getItem('focusLocalTest') == 'caterpillar') { if (localStorage.getItem("focusLocalTest") == "caterpillar") {
document.write('<p>Local storage has value</p>'); document.write("<p>Local storage has value</p>");
} else { } else {
document.write('<p>Local storage empty</p>'); document.write("<p>Local storage empty</p>");
} }
</script> </script>
</body> </body>
</html> </html>

View file

@ -1,8 +1,7 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<body> <body>
<h1>Storage Start</h1> <h1>Storage Start</h1>
<p id="cookies"></p> <p id="cookies"></p>
@ -10,19 +9,22 @@
<script type="text/javascript"> <script type="text/javascript">
(function () { (function () {
document.getElementById("cookies").textContent = document.cookie?document.cookie:"No cookies set"; document.getElementById("cookies").textContent = document.cookie
? document.cookie
: "No cookies set";
})(); })();
document.getElementById("setCookies").addEventListener("click", function() { document
.getElementById("setCookies")
.addEventListener("click", function () {
document.cookie = "user=android"; document.cookie = "user=android";
document.getElementById("cookies").textContent = document.cookie; document.getElementById("cookies").textContent = document.cookie;
}); });
sessionStorage.setItem('focusSessionTest', 'caterpillar'); sessionStorage.setItem("focusSessionTest", "caterpillar");
localStorage.setItem('focusLocalTest', 'butterfly'); localStorage.setItem("focusLocalTest", "butterfly");
document.write('<p>Values written to storage</p>'); document.write("<p>Values written to storage</p>");
</script> </script>
</body> </body>
</html> </html>

View file

@ -1,8 +1,8 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8" />
<meta name="viewport" content="width=device-width"> <meta name="viewport" content="width=device-width" />
<title>tab1</title> <title>tab1</title>
</head> </head>
<body> <body>
@ -19,11 +19,12 @@
window.mobileCheck = function () { window.mobileCheck = function () {
let check = false; let check = false;
(function (a) { (function (a) {
if (a.includes("Android")) if (a.includes("Android")) check = true;
check = true; })(navigator.userAgent);
}) (navigator.userAgent)
return check; return check;
}; };
document.getElementById('viewMode').textContent=mobileCheck()? "mobile-site":"desktop-site"; document.getElementById("viewMode").textContent = mobileCheck()
? "mobile-site"
: "desktop-site";
</script> </script>
</html> </html>

View file

@ -1,16 +1,14 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8" />
<title>tab2</title> <title>tab2</title>
</head> </head>
<body> <body>
<h1 id="content">Tab 2</h1> <h1 id="content">Tab 2</h1>
<a href="tab1.html" id="tab1">Tab 1</a> <a href="tab1.html" id="tab1">Tab 1</a>
<a href="tab3.html" id="tab3">Tab 3</a> <a href="tab3.html" id="tab3">Tab 3</a>
</body> </body>
</html> </html>

View file

@ -1,11 +1,10 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8" />
<title>tab3</title> <title>tab3</title>
</head> </head>
<body> <body>
<h1 id="content">Tab 3</h1> <h1 id="content">Tab 3</h1>
<a href="tab2.html" id="tab1">Tab 1</a> <a href="tab2.html" id="tab1">Tab 1</a>
@ -13,8 +12,9 @@
<a href="tab3.html" id="tab2">Tab 2</a> <a href="tab3.html" id="tab2">Tab 2</a>
<p> <p>
<a href="https://www.youtube.com/c/MozillaChannel/videos">Mozilla Youtube link</a> <a href="https://www.youtube.com/c/MozillaChannel/videos"
>Mozilla Youtube link</a
>
</p> </p>
</body> </body>
</html> </html>

View file

@ -1,7 +1,7 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8" />
<!-- random words that should not end up on disk --> <!-- random words that should not end up on disk -->
<title>gigantic experience</title> <title>gigantic experience</title>
</head> </head>
@ -12,15 +12,26 @@
<p>This test page installs a service worker and saves a cookie.</p> <p>This test page installs a service worker and saves a cookie.</p>
<h2 id="cookieHeading">Cookie</h2> <h2 id="cookieHeading">Cookie</h2>
<p>Initial: <script type="text/javascript">document.write(document.cookie);</script></p> <p>
Initial:
<script type="text/javascript">
document.write(document.cookie);
</script>
</p>
<p> <p>
<!-- Setting a cookie --> <!-- Setting a cookie -->
<script type="text/javascript"> <script type="text/javascript">
document.cookie = "birthday=armchair; expires=Tue, 18 Dec 2035 12:00:00 UTC; path=/"; document.cookie =
"birthday=armchair; expires=Tue, 18 Dec 2035 12:00:00 UTC; path=/";
document.write("Cookie saved"); document.write("Cookie saved");
</script> </script>
</p> </p>
<p>Afterwards: <script type="text/javascript">document.write(document.cookie);</script></p> <p>
Afterwards:
<script type="text/javascript">
document.write(document.cookie);
</script>
</p>
<h2>Service worker</h2> <h2>Service worker</h2>
<p id="status"></p> <p id="status"></p>
@ -28,11 +39,10 @@
<script type="text/javascript"> <script type="text/javascript">
// Add a key value pair to local storage. This is required by WebViewDataTest which asserts // Add a key value pair to local storage. This is required by WebViewDataTest which asserts
// that the local storage directory should exist // that the local storage directory should exist
var script = document.createElement('script'); var script = document.createElement("script");
script.src = "service-worker.js"; script.src = "service-worker.js";
document.head.appendChild(script); //or something of the likes document.head.appendChild(script); //or something of the likes
</script> </script>
</body> </body>
</html> </html>

View file

@ -4,15 +4,14 @@
</head> </head>
<body> <body>
<p id="testContent">Page content: video player</p> <p id="testContent">Page content: video player</p>
<div class="playbackState"> <div class="playbackState"></div>
</div>
<div id="video-container" style="text-align: center"> <div id="video-container" style="text-align: center">
<button onclick="play()">Play</button> <button onclick="play()">Play</button>
<button onclick="pause()">Pause</button> <button onclick="pause()">Pause</button>
<button onclick="fullscreen()">Full Screen</button> <button onclick="fullscreen()">Full Screen</button>
<br><br> <br /><br />
<video id="video" width="420" autoplay controls loop> <video id="video" width="420" autoplay controls loop>
<source src="resources/clip.mp4" type="video/mp4"> <source src="resources/clip.mp4" type="video/mp4" />
Your browser does not support HTML video. Your browser does not support HTML video.
</video> </video>
</div> </div>
@ -34,7 +33,7 @@
var showPlayingAlert = true; var showPlayingAlert = true;
video.addEventListener('playing', (event) => { video.addEventListener("playing", event => {
<!-- document.querySelector('.playbackState').innerHTML="Media file is playing";--> <!-- document.querySelector('.playbackState').innerHTML="Media file is playing";-->
<!-- Need this hack to verify that the video is playing, --> <!-- Need this hack to verify that the video is playing, -->
<!-- the test cannot currently verify the text displayed on the page--> <!-- the test cannot currently verify the text displayed on the page-->
@ -44,7 +43,7 @@
} }
}); });
video.addEventListener('pause', (event) => { video.addEventListener("pause", event => {
// document.querySelector('.playbackState').innerHTML="Media file is paused"; // document.querySelector('.playbackState').innerHTML="Media file is paused";
alert("Media file is paused"); alert("Media file is paused");
}); });

View file

@ -1,13 +1,18 @@
<!doctype html> <!DOCTYPE html>
<!-- This Source Code Form is subject to the terms of the Mozilla Public <!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this file, - License, v. 2.0. If a copy of the MPL was not distributed with this file,
- You can obtain one at http://mozilla.org/MPL/2.0/. --> - You can obtain one at http://mozilla.org/MPL/2.0/. -->
<head> <head>
<meta name="viewport" charset="utf-8" content="width=device-width, initial-scale=1"> <meta
name="viewport"
charset="utf-8"
content="width=device-width, initial-scale=1"
/>
<style> <style>
body, html { body,
background: #221F1F; html {
color: #FFFFFF; background: #221f1f;
color: #ffffff;
font-family: sans-serif; font-family: sans-serif;
line-height: 24px; line-height: 24px;
font-size: 14px; font-size: 14px;
@ -21,17 +26,17 @@
} }
a { a {
color: #0A9AF4; color: #0a9af4;
} }
/* Make only about page links ("learn more") white */ /* Make only about page links ("learn more") white */
.about a { .about a {
color: #FFFFFF; color: #ffffff;
} }
p.subtitle { p.subtitle {
text-align: center; text-align: center;
opacity: .7; opacity: 0.7;
margin: 0; margin: 0;
} }

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -1,12 +1,18 @@
<!doctype html> <!DOCTYPE html>
<!-- This Source Code Form is subject to the terms of the Mozilla Public <!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this file, - License, v. 2.0. If a copy of the MPL was not distributed with this file,
- You can obtain one at http://mozilla.org/MPL/2.0/. --> - You can obtain one at http://mozilla.org/MPL/2.0/. -->
<head> <head>
<meta name="viewport" charset="utf-8" content="width=device-width, initial-scale=1"><style> <meta
body, html { name="viewport"
background: #221F1F; charset="utf-8"
color: #FFFFFF; content="width=device-width, initial-scale=1"
/>
<style>
body,
html {
background: #221f1f;
color: #ffffff;
font-family: sans-serif; font-family: sans-serif;
line-height: 24px; line-height: 24px;
font-size: 14px; font-size: 14px;
@ -20,17 +26,17 @@
} }
a { a {
color: #0A9AF4; color: #0a9af4;
} }
/* Make only about page links ("learn more") white */ /* Make only about page links ("learn more") white */
.about a { .about a {
color: #FFFFFF; color: #ffffff;
} }
p.subtitle { p.subtitle {
text-align: center; text-align: center;
opacity: .7; opacity: 0.7;
margin: 0; margin: 0;
} }

View file

@ -23,8 +23,6 @@ dom/tests/ajax/mochikit/
intl/components/src/UnicodeScriptCodes.h intl/components/src/UnicodeScriptCodes.h
intl/unicharutil/util/nsSpecialCasingData.cpp intl/unicharutil/util/nsSpecialCasingData.cpp
intl/unicharutil/util/nsUnicodePropertyData.cpp intl/unicharutil/util/nsUnicodePropertyData.cpp
mobile/locales/l10n-changesets.json
mobile/locales/l10n-onchange-changesets.json
mobile/android/**/.build-cache mobile/android/**/.build-cache
mobile/android/**/.gradle mobile/android/**/.gradle
mobile/android/**/build mobile/android/**/build
@ -32,6 +30,12 @@ mobile/android/**/bin
mobile/android/**/generated mobile/android/**/generated
mobile/android/**\/local.properties mobile/android/**\/local.properties
mobile/android/**\/manifest.json mobile/android/**\/manifest.json
mobile/android/android-components/components/feature/search/src/main/assets/search/search_telemetry_v2.json
mobile/android/android-components/samples/glean/src/main/res/raw/initial_experiments.json
mobile/android/fenix/app/src/debug/res/raw/initial_experiments.json
mobile/android/fenix/app/src/main/res/raw/initial_experiments.json
mobile/locales/l10n-changesets.json
mobile/locales/l10n-onchange-changesets.json
node_modules/ node_modules/
python/mozperftest/mozperftest/tests/data/ python/mozperftest/mozperftest/tests/data/
security/manager/tools/KnownRootHashes.json security/manager/tools/KnownRootHashes.json

View file

@ -135,6 +135,9 @@ media/openmax_il/
media/webrtc/signaling/gtest/MockCall.h media/webrtc/signaling/gtest/MockCall.h
mfbt/double-conversion/double-conversion/ mfbt/double-conversion/double-conversion/
mfbt/lz4/.* mfbt/lz4/.*
mobile/android/android-components/components/feature/readerview/src/main/assets/extensions/readerview/readability/JSDOMParser-0.4.2.js
mobile/android/android-components/components/feature/readerview/src/main/assets/extensions/readerview/readability/readability-0.4.2.js
mobile/android/android-components/components/feature/readerview/src/main/assets/extensions/readerview/readability/readability-readerable-0.4.2.js
mobile/android/exoplayer2/ mobile/android/exoplayer2/
modules/brotli/ modules/brotli/
modules/fdlibm/ modules/fdlibm/