Bug 1780543 - Part 4: Add mozilla/remote-page environment. r=Standard8

Differential Revision: https://phabricator.services.mozilla.com/D152429
This commit is contained in:
Tooru Fujisawa 2022-07-26 02:46:30 +00:00
parent 4e35a2bf9c
commit 9fa82cdffe
19 changed files with 53 additions and 17 deletions

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
var AboutRestartRequired = {
/* Only do autofocus if we're the toplevel frame; otherwise we

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
var AboutTabCrashed = {
/**

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
import "chrome://global/content/certviewer/pvutils_bundle.jsm";
import "chrome://global/content/certviewer/asn1js_bundle.jsm";

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
import { toggleContainer } from "./helpers.mjs";

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
import {
actionCreators as ac,

View File

@ -14641,7 +14641,7 @@ const external_Redux_namespaceObject = Redux;
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
const MERGE_STORE_ACTION = "NEW_TAB_INITIAL_STATE";

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
/**
* Determines whether a given value is a fluent id or plain text and adds it to an element

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
const HOW_IT_WORKS_URL_PREF = RPMGetFormatURLPref(
"browser.contentblocking.report.lockwise.how_it_works.url"

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
const MONITOR_URL = RPMGetStringPref(
"browser.contentblocking.report.monitor.url",

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
import LockwiseCard from "./lockwise-card.mjs";
import MonitorCard from "./monitor-card.mjs";

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
const PROXY_EXTENSION_URL = RPMGetStringPref(
"browser.contentblocking.report.proxy_extension.url",

View File

@ -2,7 +2,8 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
export default class VPNCard {
constructor(document) {
this.doc = document;

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
"use strict";

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
import { ListItem } from "./list-item.js";

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
import { InfoGroupContainer } from "./info-group-container.js";
import { CertificateTabsSection } from "./certificate-tabs-section.js";

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
"use strict";

View File

@ -2,7 +2,7 @@
* 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/. */
/* eslint-env mozilla/frame-script */
/* eslint-env mozilla/remote-page */
"use strict";

View File

@ -0,0 +1,34 @@
/**
* @fileoverview Defines the environment for remote page.
*
* 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, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
"use strict";
module.exports = {
globals: {
atob: false,
btoa: false,
RPMGetAppBuildID: false,
RPMGetInnerMostURI: false,
RPMGetIntPref: false,
RPMGetStringPref: false,
RPMGetBoolPref: false,
RPMSetBoolPref: false,
RPMGetFormatURLPref: false,
RPMIsWindowPrivate: false,
RPMSendAsyncMessage: false,
RPMSendQuery: false,
RPMAddMessageListener: false,
RPMRecordTelemetryEvent: false,
RPMCheckAlternateHostAvailable: false,
RPMAddToHistogram: false,
RPMRemoveMessageListener: false,
RPMGetHttpResponseHeader: false,
RPMTryPingSecureWWWLink: false,
RPMOpenSecureWWWLink: false,
},
};

View File

@ -25,6 +25,7 @@ module.exports = {
"frame-script": require("../lib/environments/frame-script.js"),
jsm: require("../lib/environments/jsm.js"),
"process-script": require("../lib/environments/frame-script.js"),
"remote-page": require("../lib/environments/remote-page.js"),
simpletest: require("../lib/environments/simpletest.js"),
sjs: require("../lib/environments/sjs.js"),
privileged: require("../lib/environments/privileged.js"),