mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-17 23:35:34 +00:00
Bug 1525615: Add 'title' attribute to '<a>' of title of DebugTargetPane. r=jdescottes,ladybenko
Depends on D20296 Differential Revision: https://phabricator.services.mozilla.com/D20765 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
73059dbb18
commit
66bda67c38
@ -8,6 +8,8 @@ const { createFactory, PureComponent } = require("devtools/client/shared/vendor/
|
||||
const dom = require("devtools/client/shared/vendor/react-dom-factories");
|
||||
const PropTypes = require("devtools/client/shared/vendor/react-prop-types");
|
||||
|
||||
const FluentReact = require("devtools/client/shared/vendor/fluent-react");
|
||||
|
||||
const DebugTargetList = createFactory(require("./DebugTargetList"));
|
||||
|
||||
const Actions = require("../../actions/index");
|
||||
@ -23,6 +25,8 @@ class DebugTargetPane extends PureComponent {
|
||||
collapsibilityKey: PropTypes.string.isRequired,
|
||||
detailComponent: PropTypes.any.isRequired,
|
||||
dispatch: PropTypes.func.isRequired,
|
||||
// Provided by wrapping the component with FluentReact.withLocalization.
|
||||
getString: PropTypes.func.isRequired,
|
||||
icon: PropTypes.string.isRequired,
|
||||
isCollapsed: PropTypes.bool.isRequired,
|
||||
name: PropTypes.string.isRequired,
|
||||
@ -40,12 +44,15 @@ class DebugTargetPane extends PureComponent {
|
||||
actionComponent,
|
||||
detailComponent,
|
||||
dispatch,
|
||||
getString,
|
||||
icon,
|
||||
isCollapsed,
|
||||
name,
|
||||
targets,
|
||||
} = this.props;
|
||||
|
||||
const title = getString("about-debugging-collapse-expand-debug-targets");
|
||||
|
||||
return dom.section(
|
||||
{
|
||||
className: "js-debug-target-pane",
|
||||
@ -53,7 +60,8 @@ class DebugTargetPane extends PureComponent {
|
||||
dom.a(
|
||||
{
|
||||
className: "undecorated-link debug-target-pane__title " +
|
||||
"js-debug-target-pane-title",
|
||||
"js-debug-target-pane-title",
|
||||
title,
|
||||
onClick: e => this.toggleCollapsibility(),
|
||||
},
|
||||
dom.h2(
|
||||
@ -85,4 +93,4 @@ class DebugTargetPane extends PureComponent {
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = DebugTargetPane;
|
||||
module.exports = FluentReact.withLocalization(DebugTargetPane);
|
||||
|
@ -306,3 +306,8 @@ about-debugging-profiler-dialog-title = Performance Profiler
|
||||
# The "Learn more" link points to MDN.
|
||||
# https://developer.mozilla.org/docs/Tools/about:debugging#Enabling_add-on_debugging
|
||||
about-debugging-extension-debug-setting-label = Enable extension debugging <a>Learn more</a>
|
||||
|
||||
# Clicking on the header of a debug target category will expand or collapse the debug
|
||||
# target items in the category. This text is used as ’title’ attribute of the header,
|
||||
# to describe this feature.
|
||||
about-debugging-collapse-expand-debug-targets = Collapse / expand
|
||||
|
Loading…
Reference in New Issue
Block a user