From 49217c4945592af71bbf41863b0eba793f2f364f Mon Sep 17 00:00:00 2001 From: Dominik Guzei Date: Thu, 5 Sep 2019 15:11:01 +0200 Subject: Remove news item on CTA clicks --- src/components/layout/AppLayout.js | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/components/layout') diff --git a/src/components/layout/AppLayout.js b/src/components/layout/AppLayout.js index 941e60bfd..200777ae6 100644 --- a/src/components/layout/AppLayout.js +++ b/src/components/layout/AppLayout.js @@ -125,7 +125,15 @@ class AppLayout extends Component { sticky={item.sticky} onHide={() => removeNewsItem({ newsId: item.id })} > - + { + const { target } = event; + if (target && target.hasAttribute('data-is-news-cta')) { + removeNewsItem({ newsId: item.id }); + } + }} + /> ))} {hasActivatedTrial && ( -- cgit v1.2.3-70-g09d2