From 7f80da03a2edeec5522daf89fcf1fa040f55a57c Mon Sep 17 00:00:00 2001 From: Sophie Schneider Date: Wed, 10 Apr 2024 22:45:32 +0000 Subject: [PATCH] Move Frame classnames inline --- polaris-react/src/components/Frame/Frame.tsx | 25 +++++++++----------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/polaris-react/src/components/Frame/Frame.tsx b/polaris-react/src/components/Frame/Frame.tsx index f638dafa824..6558093beeb 100644 --- a/polaris-react/src/components/Frame/Frame.tsx +++ b/polaris-react/src/components/Frame/Frame.tsx @@ -23,7 +23,6 @@ import type { } from '../../utilities/frame'; import {UseTheme} from '../../utilities/use-theme'; import {UseFeatures} from '../../utilities/features'; -import type {FeaturesConfig} from '../../utilities/features'; import { ToastManager, @@ -240,18 +239,6 @@ class FrameInner extends PureComponent { } : {}; - const getFrameClassName = (features: FeaturesConfig) => - classNames( - styles.Frame, - features?.dynamicTopBarAndReframe && styles['Frame-TopBarAndReframe'], - navigation && styles.hasNav, - topBar && styles.hasTopBar, - sidebar && styles.hasSidebar, - sidebar && - features?.dynamicTopBarAndReframe && - styles['hasSidebar-TopBarAndReframe'], - ); - const contextualSaveBarMarkup = ( {({dynamicTopBarAndReframe}) => @@ -299,7 +286,17 @@ class FrameInner extends PureComponent { {(features) => (