Browse Source

SONAR-16993 [893826] Form elements must have labels

tags/9.7.0.61563
Wouter Admiraal 1 year ago
parent
commit
f8605f7076

+ 25
- 17
server/sonar-web/src/main/js/components/activity-graph/GraphsHeader.tsx View File

@@ -65,24 +65,32 @@ export default class GraphsHeader extends React.PureComponent<Props> {

return (
<div className={classNames(className, 'position-relative')}>
<Select
className="pull-left input-medium"
isSearchable={false}
onChange={this.handleGraphChange}
options={selectOptions}
value={selectOptions.find(option => option.value === graph)}
/>
{isCustomGraph(graph) &&
addCustomMetric !== undefined &&
removeCustomMetric !== undefined && (
<AddGraphMetric
addMetric={addCustomMetric}
metrics={metrics}
metricsTypeFilter={metricsTypeFilter}
removeMetric={removeCustomMetric}
selectedMetrics={selectedMetrics}
<div className="display-flex-end">
<div className="display-flex-column">
<label className="text-bold little-spacer-bottom" htmlFor="graph-select">
{translate('project_activity.graphs.choose_type')}
</label>
<Select
id="graph-select"
className="input-medium"
isSearchable={false}
onChange={this.handleGraphChange}
options={selectOptions}
value={selectOptions.find(option => option.value === graph)}
/>
)}
</div>
{isCustomGraph(graph) &&
addCustomMetric !== undefined &&
removeCustomMetric !== undefined && (
<AddGraphMetric
addMetric={addCustomMetric}
metrics={metrics}
metricsTypeFilter={metricsTypeFilter}
removeMetric={removeCustomMetric}
selectedMetrics={selectedMetrics}
/>
)}
</div>
</div>
);
}

+ 1
- 0
sonar-core/src/main/resources/org/sonar/l10n/core.properties View File

@@ -1534,6 +1534,7 @@ project_activity.events.tooltip.delete=Delete this event
project_activity.new_code_period_start=New Code Period starts here
project_activity.new_code_period_start.help=The analysis before this mark is the baseline for New Code comparison

project_activity.graphs.choose_type=Choose graph type
project_activity.graphs.new_code=New Code
project_activity.graphs.new_code_long=New Code is indicated in yellow on the graph.
project_activity.graphs.issues=Issues

Loading…
Cancel
Save