className="input-medium"
onChange={this.handleChange}
options={options}
- searchable={false}
value={options.find(o => o.value === this.props.value)}
+ isSearchable={false}
/>
);
}
<Select
aria-labelledby="background-task-type-filter-label"
className="input-large"
- clearable={false}
+ isClearable={false}
onChange={this.handleChange}
options={allOptions}
- searchable={false}
+ isSearchable={false}
value={allOptions.find(o => o.value === value)}
/>
);
aria-labelledby="coding-rules-custom-rule-status"
onChange={this.handleStatusChange}
options={statusesOptions}
- searchable={false}
+ isSearchable={false}
value={statusesOptions.find(s => s.value === this.state.status)}
/>
</div>
aria-labelledby="coding-rules-custom-rule-status"
isClearable={false}
isDisabled={false}
+ isSearchable={false}
onChange={[Function]}
options={
Array [
},
]
}
- searchable={false}
value={
Object {
"label": "rules.status.READY",
aria-labelledby="coding-rules-custom-rule-status"
isClearable={false}
isDisabled={false}
+ isSearchable={false}
onChange={[Function]}
options={
Array [
},
]
}
- searchable={false}
value={
Object {
"label": "rules.status.READY",
return (
<Select
aria-labelledby="measures-view-selection-label"
- autoBlur={true}
+ blurInputOnSelect={true}
className={className}
onChange={this.handleChange}
components={{
exports[`should render correctly: has no list 1`] = `
<Select
aria-labelledby="measures-view-selection-label"
- autoBlur={true}
+ blurInputOnSelect={true}
components={
Object {
"Option": [Function],
exports[`should render correctly: has no tree 1`] = `
<Select
aria-labelledby="measures-view-selection-label"
- autoBlur={true}
+ blurInputOnSelect={true}
components={
Object {
"Option": [Function],
exports[`should render correctly: has no treemap 1`] = `
<Select
aria-labelledby="measures-view-selection-label"
- autoBlur={true}
+ blurInputOnSelect={true}
components={
Object {
"Option": [Function],
.map(graph => graph[0].type);
};
- addCustomMetric = (metric: string) => {
- const customMetrics = [...this.props.query.customMetrics, metric];
- saveActivityGraph(PROJECT_ACTIVITY_GRAPH, this.props.project, GraphType.custom, customMetrics);
- this.props.updateQuery({ customMetrics });
- };
-
- removeCustomMetric = (removedMetric: string) => {
- const customMetrics = this.props.query.customMetrics.filter(metric => metric !== removedMetric);
- saveActivityGraph(PROJECT_ACTIVITY_GRAPH, this.props.project, GraphType.custom, customMetrics);
- this.props.updateQuery({ customMetrics });
+ updateSelectedMetrics = (selectedMetrics: string[]) => {
+ saveActivityGraph(
+ PROJECT_ACTIVITY_GRAPH,
+ this.props.project,
+ GraphType.custom,
+ selectedMetrics
+ );
+ this.props.updateQuery({ customMetrics: selectedMetrics });
};
updateGraph = (graph: GraphType) => {
return (
<div className="project-activity-layout-page-main-inner boxed-group boxed-group-inner">
<GraphsHeader
- addCustomMetric={this.addCustomMetric}
className="big-spacer-bottom"
graph={query.graph}
metrics={metrics}
metricsTypeFilter={this.getMetricsTypeFilter()}
- removeCustomMetric={this.removeCustomMetric}
selectedMetrics={this.props.query.customMetrics}
updateGraph={this.updateGraph}
/>
leakPeriodDate={leakPeriodDate}
loading={loading}
measuresHistory={this.props.measuresHistory}
- removeCustomMetric={this.removeCustomMetric}
selectedDate={this.props.query.selectedDate}
series={series}
updateGraphZoom={this.updateGraphZoom}
className="project-activity-layout-page-main-inner boxed-group boxed-group-inner"
>
<GraphsHeader
- addCustomMetric={[Function]}
className="big-spacer-bottom"
graph="issues"
metrics={
},
]
}
- removeCustomMetric={[Function]}
selectedMetrics={Array []}
updateGraph={[Function]}
/>
},
]
}
- removeCustomMetric={[Function]}
series={
Array [
Object {
<strong>{translate('baseline.reference_branch.choose')}</strong>
<MandatoryFieldMarker />
</label>
- <Select<BranchOption>
- autofocus={false}
+ <Select
className="little-spacer-top spacer-bottom"
options={branchList}
onChange={(option: BranchOption) => props.onChangeReferenceBranch(option.value)}
*/
import classNames from 'classnames';
import * as React from 'react';
-import Select from '../../../components/controls/Select';
import Radio from '../../../components/controls/Radio';
+import Select from '../../../components/controls/Select';
import Tooltip from '../../../components/controls/Tooltip';
import DateFormatter from '../../../components/intl/DateFormatter';
import TimeFormatter from '../../../components/intl/TimeFormatter';
{translate('baseline.analysis_from')}
</label>
<Select
- autoBlur={true}
+ blurInputOnSelect={true}
inputId="branch-analysis-from-input"
className="input-medium spacer-left"
onChange={props.handleRangeChange}
<MandatoryFieldMarker />
</label>
<Select
- autofocus={false}
className="little-spacer-top spacer-bottom"
components={
Object {
<MandatoryFieldMarker />
</label>
<Select
- autofocus={false}
className="little-spacer-top spacer-bottom"
components={
Object {
<MandatoryFieldMarker />
</label>
<Select
- autofocus={false}
className="little-spacer-top spacer-bottom"
components={
Object {
baseline.analysis_from
</label>
<Select
- autoBlur={true}
+ blurInputOnSelect={true}
className="input-medium spacer-left"
inputId="branch-analysis-from-input"
isSearchable={false}
baseline.analysis_from
</label>
<Select
- autoBlur={true}
+ blurInputOnSelect={true}
className="input-medium spacer-left"
inputId="branch-analysis-from-input"
isSearchable={false}
baseline.analysis_from
</label>
<Select
- autoBlur={true}
+ blurInputOnSelect={true}
className="input-medium spacer-left"
inputId="branch-analysis-from-input"
isSearchable={false}
isLoading={this.props.isLoading}
onChange={this.handleOptionChange}
onInputChange={this.props.onInputChange}
- onOpen={this.props.onOpen}
+ onMenuOpen={this.props.onOpen}
options={this.props.options}
placeholder={translate('search_verb')}
/>
<td className="thin nowrap text-middle">
<Select
className="input-medium it__project-qualifier-select"
- disabled={!this.props.ready}
+ isDisabled={!this.props.ready}
name="projects-qualifier"
onChange={this.handleQualifierChange}
isSearchable={false}
SingleValue: this.singleValueRenderer
}}
options={this.getQualifierOptions()}
- searchable={false}
value={options.find(option => option.value === this.props.qualifiers)}
/>
</td>
"SingleValue": [Function],
}
}
- disabled={false}
+ isDisabled={false}
isSearchable={false}
name="projects-qualifier"
onChange={[Function]}
},
]
}
- searchable={false}
value={
Object {
"label": "qualifiers.TRK",
import ReactSelect, {
GroupTypeBase,
IndicatorProps,
+ NamedProps,
OptionTypeBase,
- Props,
StylesConfig
} from 'react-select';
import AsyncReactSelect, { AsyncProps } from 'react-select/async';
Option,
IsMulti extends boolean = false,
Group extends GroupTypeBase<Option> = GroupTypeBase<Option>
-> extends React.Component<Props<Option, IsMulti, Group> & StyleExtensionProps> {
+> extends React.Component<NamedProps<Option, IsMulti, Group> & StyleExtensionProps> {
render() {
return (
<ReactSelect
Option,
IsMulti extends boolean,
Group extends GroupTypeBase<Option> = GroupTypeBase<Option>
->(props: Props<Option, IsMulti, Group> & AsyncProps<Option, Group> & StyleExtensionProps) {
+>(props: NamedProps<Option, IsMulti, Group> & AsyncProps<Option, Group> & StyleExtensionProps) {
return (
<AsyncReactSelect
{...omit(props, 'className', 'large')}
}
export function selectStyle<Option, IsMulti extends boolean, Group extends GroupTypeBase<Option>>(
- props?: Props<Option, IsMulti, Group> & AsyncProps<Option, Group> & StyleExtensionProps
+ props?: NamedProps<Option, IsMulti, Group> & AsyncProps<Option, Group> & StyleExtensionProps
): StylesConfig<Option, IsMulti, Group> {
return {
container: () => ({