From bd7758102822eb9ae292482190cb07ac29cc5300 Mon Sep 17 00:00:00 2001 From: Chandler Prall Date: Tue, 9 Jun 2020 11:32:39 -0600 Subject: [PATCH 1/2] Correct IconControlProps to include an onClick definition --- src/components/control_bar/control_bar.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/components/control_bar/control_bar.tsx b/src/components/control_bar/control_bar.tsx index 9f8152d7cd0..be303adfbdc 100644 --- a/src/components/control_bar/control_bar.tsx +++ b/src/components/control_bar/control_bar.tsx @@ -22,6 +22,7 @@ import React, { ButtonHTMLAttributes, Component, HTMLAttributes, + MouseEventHandler, Ref, } from 'react'; import { EuiScreenReaderOnly } from '../accessibility'; @@ -119,6 +120,7 @@ export interface IconControlProps { controlType: 'icon'; id: string; iconType: string; + onClick?: MouseEventHandler; } /** From c0adc6a8fd7779d971a1edcff856ee8530d5c015 Mon Sep 17 00:00:00 2001 From: Chandler Prall Date: Tue, 9 Jun 2020 11:48:55 -0600 Subject: [PATCH 2/2] changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index ee9b78c0cc6..7a99c2c7722 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ - Added `display` prop to `EuiDataGridColumnSortingDraggable` to pass` displayAsText` prop correctly to the column sorting popover.([#3574](https://github.com/elastic/eui/pull/3574)) - Fixed `EuiCodeBlockImpl` testenv mock pass-through of `data-test-subj` attribute ([#3560](https://github.com/elastic/eui/pull/3560)) - Fixed DOM element creation issues in `EuiOverlayMask` by using lifecycle methods ([#3555](https://github.com/elastic/eui/pull/3555)) +- Included `onClick` as a valid prop for `EuiControlBar` **icon** controls ([#3523](https://github.com/elastic/eui/pull/3523)) ## [`25.0.0`](https://github.com/elastic/eui/tree/v25.0.0)