Skip to content

Commit

Permalink
[InfraUI] Fix group by "x" icon keyboard controls (#31960) (#33122)
Browse files Browse the repository at this point in the history
* First pass at ensuring click events do not swallow keyUp event, also ensure menu doesn't open / close for no reason

* Add comment

* Add key

* Revert changes

* Remove icons on badges within context menu

* Remove unused translation with script
  • Loading branch information
Kerry350 authored Mar 13, 2019
1 parent 46d8830 commit dd18eca
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 19 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -137,24 +137,7 @@ export const WaffleGroupByControls = injectI18n(
.filter(o => o != null)
// In this map the `o && o.field` is totally unnecessary but Typescript is
// too stupid to realize that the filter above prevents the next map from being null
.map(o => (
<EuiBadge
key={o && o.field}
iconType="cross"
iconOnClick={this.handleRemove((o && o.field) || '')}
iconOnClickAriaLabel={intl.formatMessage(
{
id: 'xpack.infra.waffle.removeGroupingItemAriaLabel',
defaultMessage: 'Remove {groupingItem} grouping',
},
{
groupingItem: o && o.text,
}
)}
>
{o && o.text}
</EuiBadge>
))
.map(o => <EuiBadge key={o && o.field}>{o && o.text}</EuiBadge>)
) : (
<FormattedMessage id="xpack.infra.waffle.groupByAllTitle" defaultMessage="All" />
);
Expand Down
1 change: 0 additions & 1 deletion x-pack/plugins/translations/translations/zh-CN.json
Original file line number Diff line number Diff line change
Expand Up @@ -4369,7 +4369,6 @@
"xpack.infra.waffle.noDataDescription": "尝试调整您的时间或筛选。",
"xpack.infra.waffle.noDataTitle": "没有可显示的数据。",
"xpack.infra.waffle.nodeTypeSwitcher.hostsLabel": "主机",
"xpack.infra.waffle.removeGroupingItemAriaLabel": "删除 {groupingItem} 分组",
"xpack.infra.waffle.selectTwoGroupingsTitle": "选择最多两个分组",
"xpack.infra.waffle.unableToSelectGroupErrorMessage": "无法选择 {nodeType} 的分组依据选项",
"xpack.infra.waffle.unableToSelectMetricErrorTitle": "无法选择指标选项或指标值。",
Expand Down

0 comments on commit dd18eca

Please sign in to comment.