Bug 1643990 - Set tooltip for navigation buttons r=flod,jdescottes
authorDavid Walsh <dwalsh@mozilla.com>
Tue, 09 Jun 2020 11:15:08 +0000
changeset 534720 7a1e6bfc8554c0156a65d23648c95d53c3961ce0
parent 534719 480645112235b90bef6bd367090dec9d67885bd8
child 534721 49f533a95f64945e91b1f971cd86b662d75b9a73
push id118482
push userdwalsh@mozilla.com
push dateTue, 09 Jun 2020 16:14:44 +0000
treeherderautoland@7a1e6bfc8554 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersflod, jdescottes
bugs1643990
milestone79.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1643990 - Set tooltip for navigation buttons r=flod,jdescottes Differential Revision: https://phabricator.services.mozilla.com/D78690
devtools/client/framework/components/DebugTargetInfo.js
devtools/client/framework/test/node/components/__snapshots__/debug-target-info.test.js.snap
--- a/devtools/client/framework/components/DebugTargetInfo.js
+++ b/devtools/client/framework/components/DebugTargetInfo.js
@@ -269,16 +269,17 @@ class DebugTargetInfo extends PureCompon
 
   renderNavigationButton(detail) {
     const { L10N } = this.props;
 
     return dom.button(
       {
         className: `iconized-label navigation-button ${detail.className}`,
         onClick: detail.onClick,
+        title: L10N.getStr(detail.l10nId),
       },
       dom.img({
         src: detail.icon,
         alt: L10N.getStr(detail.l10nId),
       })
     );
   }
 
--- a/devtools/client/framework/test/node/components/__snapshots__/debug-target-info.test.js.snap
+++ b/devtools/client/framework/test/node/components/__snapshots__/debug-target-info.test.js.snap
@@ -45,34 +45,37 @@ exports[`DebugTargetInfo component Conne
     </b>
   </span>
   <div
     className="debug-target-navigation"
   >
     <button
       className="iconized-label navigation-button qa-back-button"
       onClick={[Function]}
+      title="toolbox.debugTargetInfo.back"
     >
       <img
         alt="toolbox.debugTargetInfo.back"
         src="chrome://browser/skin/back.svg"
       />
     </button>
     <button
       className="iconized-label navigation-button qa-forward-button"
       onClick={[Function]}
+      title="toolbox.debugTargetInfo.forward"
     >
       <img
         alt="toolbox.debugTargetInfo.forward"
         src="chrome://browser/skin/forward.svg"
       />
     </button>
     <button
       className="iconized-label navigation-button qa-reload-button"
       onClick={[Function]}
+      title="toolbox.debugTargetInfo.reload"
     >
       <img
         alt="toolbox.debugTargetInfo.reload"
         src="chrome://browser/skin/reload.svg"
       />
     </button>
   </div>
   <span
@@ -194,34 +197,37 @@ exports[`DebugTargetInfo component Targe
     </b>
   </span>
   <div
     className="debug-target-navigation"
   >
     <button
       className="iconized-label navigation-button qa-back-button"
       onClick={[Function]}
+      title="toolbox.debugTargetInfo.back"
     >
       <img
         alt="toolbox.debugTargetInfo.back"
         src="chrome://browser/skin/back.svg"
       />
     </button>
     <button
       className="iconized-label navigation-button qa-forward-button"
       onClick={[Function]}
+      title="toolbox.debugTargetInfo.forward"
     >
       <img
         alt="toolbox.debugTargetInfo.forward"
         src="chrome://browser/skin/forward.svg"
       />
     </button>
     <button
       className="iconized-label navigation-button qa-reload-button"
       onClick={[Function]}
+      title="toolbox.debugTargetInfo.reload"
     >
       <img
         alt="toolbox.debugTargetInfo.reload"
         src="chrome://browser/skin/reload.svg"
       />
     </button>
   </div>
   <span
@@ -388,34 +394,37 @@ exports[`DebugTargetInfo component Targe
     </b>
   </span>
   <div
     className="debug-target-navigation"
   >
     <button
       className="iconized-label navigation-button qa-back-button"
       onClick={[Function]}
+      title="toolbox.debugTargetInfo.back"
     >
       <img
         alt="toolbox.debugTargetInfo.back"
         src="chrome://browser/skin/back.svg"
       />
     </button>
     <button
       className="iconized-label navigation-button qa-forward-button"
       onClick={[Function]}
+      title="toolbox.debugTargetInfo.forward"
     >
       <img
         alt="toolbox.debugTargetInfo.forward"
         src="chrome://browser/skin/forward.svg"
       />
     </button>
     <button
       className="iconized-label navigation-button qa-reload-button"
       onClick={[Function]}
+      title="toolbox.debugTargetInfo.reload"
     >
       <img
         alt="toolbox.debugTargetInfo.reload"
         src="chrome://browser/skin/reload.svg"
       />
     </button>
   </div>
   <span
@@ -465,34 +474,37 @@ exports[`DebugTargetInfo component Targe
     />
   </span>
   <div
     className="debug-target-navigation"
   >
     <button
       className="iconized-label navigation-button qa-back-button"
       onClick={[Function]}
+      title="toolbox.debugTargetInfo.back"
     >
       <img
         alt="toolbox.debugTargetInfo.back"
         src="chrome://browser/skin/back.svg"
       />
     </button>
     <button
       className="iconized-label navigation-button qa-forward-button"
       onClick={[Function]}
+      title="toolbox.debugTargetInfo.forward"
     >
       <img
         alt="toolbox.debugTargetInfo.forward"
         src="chrome://browser/skin/forward.svg"
       />
     </button>
     <button
       className="iconized-label navigation-button qa-reload-button"
       onClick={[Function]}
+      title="toolbox.debugTargetInfo.reload"
     >
       <img
         alt="toolbox.debugTargetInfo.reload"
         src="chrome://browser/skin/reload.svg"
       />
     </button>
   </div>
   <span