Bug 1452290 - Update the labels in the DevTools meatball menu; r?jryans
This also updates the link behavior to use the less privileged openWebLink.
MozReview-Commit-ID: HHDQKAQz6hQ
--- a/devtools/client/framework/components/toolbox-toolbar.js
+++ b/devtools/client/framework/components/toolbox-toolbar.js
@@ -2,17 +2,17 @@
* 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";
const { Component, createFactory } = require("devtools/client/shared/vendor/react");
const dom = require("devtools/client/shared/vendor/react-dom-factories");
const PropTypes = require("devtools/client/shared/vendor/react-prop-types");
const {div, button} = dom;
-const {openTrustedLink} = require("devtools/client/shared/link");
+const {openWebLink} = require("devtools/client/shared/link");
const Menu = require("devtools/client/framework/menu");
const MenuItem = require("devtools/client/framework/menu-item");
const ToolboxTab = createFactory(require("devtools/client/framework/components/toolbox-tab"));
const ToolboxTabs = createFactory(require("devtools/client/framework/components/toolbox-tabs"));
/**
* This is the overall component for the toolbox toolbar. It is designed to not know how
@@ -389,29 +389,29 @@ function showMeatballMenu(
}));
if (menu.items.length) {
menu.append(new MenuItem({ type: "separator" }));
}
// Getting started
menu.append(new MenuItem({
- id: "toolbox-meatball-menu-gettingstarted",
- label: L10N.getStr("toolbox.meatballMenu.gettingStarted.label"),
+ id: "toolbox-meatball-menu-documentation",
+ label: L10N.getStr("toolbox.meatballMenu.documentation.label"),
click: () => {
- openTrustedLink("https://developer.mozilla.org/docs/Tools", toolbox);
+ openWebLink("https://developer.mozilla.org/docs/Tools", toolbox);
},
}));
// Give feedback
menu.append(new MenuItem({
- id: "toolbox-meatball-menu-feedback",
- label: L10N.getStr("toolbox.meatballMenu.giveFeedback.label"),
+ id: "toolbox-meatball-menu-community",
+ label: L10N.getStr("toolbox.meatballMenu.community.label"),
click: () => {
- openTrustedLink("https://discourse.mozilla.org/c/devtools", toolbox);
+ openWebLink("https://discourse.mozilla.org/c/devtools", toolbox);
},
}));
const rect = menuButton.getBoundingClientRect();
const screenX = menuButton.ownerDocument.defaultView.mozInnerScreenX;
const screenY = menuButton.ownerDocument.defaultView.mozInnerScreenY;
// Display the popup below the button.
--- a/devtools/client/locales/en-US/toolbox.properties
+++ b/devtools/client/locales/en-US/toolbox.properties
@@ -168,23 +168,23 @@ toolbox.meatballMenu.hideconsole.label=H
toolbox.meatballMenu.noautohide.label=Disable popup auto-hide
# LOCALIZATION NOTE (toolbox.meatballMenu.settings.label): This is the label for
# the item in the "..." menu in the toolbox that brings up the Settings
# (Options) panel.
# The keyboard shortcut will be shown to the side of the label.
toolbox.meatballMenu.settings.label=Settings
-# LOCALIZATION NOTE (toolbox.meatballMenu.gettingStarted.label): This is the
-# label for the Getting Started menu item.
-toolbox.meatballMenu.gettingStarted.label=Getting started
+# LOCALIZATION NOTE (toolbox.meatballMenu.documentation.label): This is the
+# label for the Documentation menu item.
+toolbox.meatballMenu.documentation.label=Documentation…
-# LOCALIZATION NOTE (toolbox.meatballMenu.giveFeedback.label): This is the label
-# for the Give feedback menu item.
-toolbox.meatballMenu.giveFeedback.label=Give feedback
+# LOCALIZATION NOTE (toolbox.meatballMenu.community.label): This is the label
+# for the Community menu item.
+toolbox.meatballMenu.community.label=Community…
# LOCALIZATION NOTE (toolbox.closebutton.tooltip): This is the tooltip for
# the close button the developer tools toolbox.
toolbox.closebutton.tooltip=Close Developer Tools
# LOCALIZATION NOTE (toolbox.allToolsButton.tooltip): This is the tooltip for the
# "all tools" button displayed when some tools are hidden by overflow of the toolbar.
toolbox.allToolsButton.tooltip=Select another tool