From 2c01b2c4f4e74ab77ad5fcf52737055d5a16741e Mon Sep 17 00:00:00 2001 From: Zacqary Adam Xeper Date: Mon, 19 Aug 2019 15:22:18 -0500 Subject: [PATCH] Fix cascade issue with adding className to EuiPageContent (#2237) * Fix cascade issue with adding className to EuiPageContent * Add changelog entry --- CHANGELOG.md | 1 + src/components/page/page_content/page_content.js | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 30d46e0ce4a..f302f88d1c6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ - Removed Firefox's focus ring to match other browsers ([#2193](https://github.com/elastic/eui/pull/2193)) - Added missing `onChange` TS defs for EuiRange ([#2211](https://github.com/elastic/eui/pull/2211)) - Fixed `EuiBadge` text cursor to default pointer ([#2234](https://github.com/elastic/eui/pull/2234)) +- Fixed `EuiPageContent` className prop to allow the passed-in className to take cascade precedence over classes generated by the component ([#2237](https://github.com/elastic/eui/pull/2237)) ## [`13.3.0`](https://github.com/elastic/eui/tree/v13.3.0) diff --git a/src/components/page/page_content/page_content.js b/src/components/page/page_content/page_content.js index 91819108dd4..e8fa94ec286 100644 --- a/src/components/page/page_content/page_content.js +++ b/src/components/page/page_content/page_content.js @@ -27,9 +27,9 @@ export const EuiPageContent = ({ }) => { const classes = classNames( 'euiPageContent', - className, verticalPositionToClassNameMap[verticalPosition], - horizontalPositionToClassNameMap[horizontalPosition] + horizontalPositionToClassNameMap[horizontalPosition], + className ); return (