From 88452b4eca51e4392831109241317420a53444bf Mon Sep 17 00:00:00 2001 From: Alex Page Date: Fri, 28 Jan 2022 10:42:14 -0800 Subject: [PATCH 1/6] Remove icon and removeUnderline for FooterHelp --- src/components/FooterHelp/FooterHelp.tsx | 10 ---------- src/components/FooterHelp/README.md | 5 ++++- 2 files changed, 4 insertions(+), 11 deletions(-) diff --git a/src/components/FooterHelp/FooterHelp.tsx b/src/components/FooterHelp/FooterHelp.tsx index e21a69aec99..51b301d1e79 100644 --- a/src/components/FooterHelp/FooterHelp.tsx +++ b/src/components/FooterHelp/FooterHelp.tsx @@ -1,8 +1,6 @@ import React from 'react'; -import {InfoMinor} from '@shopify/polaris-icons'; import {classNames} from '../../utilities/css'; -import {Icon, IconProps} from '../Icon'; import styles from './FooterHelp.scss'; @@ -14,17 +12,9 @@ export interface FooterHelpProps { export function FooterHelp({children}: FooterHelpProps) { const className = classNames(styles.FooterHelp); - const iconProps: IconProps = { - source: InfoMinor, - color: 'highlight', - }; - return (
-
- -
{children}
diff --git a/src/components/FooterHelp/README.md b/src/components/FooterHelp/README.md index e80538c41f9..f8938890c47 100644 --- a/src/components/FooterHelp/README.md +++ b/src/components/FooterHelp/README.md @@ -81,7 +81,10 @@ Use to direct merchants to more information related to the product or feature th ```jsx Learn more about{' '} - + fulfilling orders From 46e112a1b2dab7d8572fe92865c8a2c15ecf7169 Mon Sep 17 00:00:00 2001 From: Alex Page Date: Fri, 28 Jan 2022 10:43:10 -0800 Subject: [PATCH 2/6] Update UNRELEASED.md --- UNRELEASED.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UNRELEASED.md b/UNRELEASED.md index c0a87c6d6f6..081bc66332d 100644 --- a/UNRELEASED.md +++ b/UNRELEASED.md @@ -7,11 +7,11 @@ Use [the changelog guidelines](/documentation/Versioning%20and%20changelog.md) t ### Enhancements - [ColorPicker] Add an inset box-shadow to make it easier to see the draggers ([#4948](https://github.com/Shopify/polaris-react/pull/4948)) - - Tightened up the Navigation component UI density. ([#4874](https://github.com/Shopify/polaris-react/pull/4874)) - Updated the Navigation IA ([#4902](https://github.com/Shopify/polaris-react/pull/4902)) - Added new `duplicateRootItem` prop to a Navigation Section to support new mobile Navigation IA ([#4902](https://github.com/Shopify/polaris-react/pull/4902)) - Updated mobile behaviour of Navigation to only show one sub-section at a time ([#4902](https://github.com/Shopify/polaris-react/pull/4902)) +- Remove the icon from FooterHelp and recommend using `removeUnderline` for links in the footer ([#4982](https://github.com/Shopify/polaris-react/pull/4982)) ### Bug fixes From 6ec114aca98c873105df8759700bfe399f6031e0 Mon Sep 17 00:00:00 2001 From: Alex Page Date: Fri, 28 Jan 2022 11:15:24 -0800 Subject: [PATCH 3/6] Remove both icons, keep underline --- src/components/FooterHelp/FooterHelp.scss | 4 ---- src/components/FooterHelp/FooterHelp.tsx | 6 +----- src/components/FooterHelp/README.md | 5 +---- 3 files changed, 2 insertions(+), 13 deletions(-) diff --git a/src/components/FooterHelp/FooterHelp.scss b/src/components/FooterHelp/FooterHelp.scss index e1b11f3f0d5..fc893cfaf08 100644 --- a/src/components/FooterHelp/FooterHelp.scss +++ b/src/components/FooterHelp/FooterHelp.scss @@ -27,10 +27,6 @@ $border-radius: 999px; } } -.Icon { - margin-right: spacing(tight); -} - .Text { @include text-style-input; } diff --git a/src/components/FooterHelp/FooterHelp.tsx b/src/components/FooterHelp/FooterHelp.tsx index 51b301d1e79..3888215ba91 100644 --- a/src/components/FooterHelp/FooterHelp.tsx +++ b/src/components/FooterHelp/FooterHelp.tsx @@ -1,7 +1,5 @@ import React from 'react'; -import {classNames} from '../../utilities/css'; - import styles from './FooterHelp.scss'; export interface FooterHelpProps { @@ -10,10 +8,8 @@ export interface FooterHelpProps { } export function FooterHelp({children}: FooterHelpProps) { - const className = classNames(styles.FooterHelp); - return ( -
+
{children}
diff --git a/src/components/FooterHelp/README.md b/src/components/FooterHelp/README.md index f8938890c47..3692308c81b 100644 --- a/src/components/FooterHelp/README.md +++ b/src/components/FooterHelp/README.md @@ -81,10 +81,7 @@ Use to direct merchants to more information related to the product or feature th ```jsx Learn more about{' '} - + fulfilling orders From f477de87b09575e5773560b6d157532f4c7fd274 Mon Sep 17 00:00:00 2001 From: Alex Page Date: Fri, 28 Jan 2022 11:19:35 -0800 Subject: [PATCH 4/6] Remove unnecessary layout css --- src/components/FooterHelp/FooterHelp.scss | 13 +------------ src/components/FooterHelp/FooterHelp.tsx | 4 +--- 2 files changed, 2 insertions(+), 15 deletions(-) diff --git a/src/components/FooterHelp/FooterHelp.scss b/src/components/FooterHelp/FooterHelp.scss index fc893cfaf08..76af7befe34 100644 --- a/src/components/FooterHelp/FooterHelp.scss +++ b/src/components/FooterHelp/FooterHelp.scss @@ -7,22 +7,11 @@ $border-radius: 999px; display: flex; justify-content: center; margin: spacing(loose) 0; - width: 100%; - - @include page-content-when-not-fully-condensed { - margin: spacing(loose); - width: auto; - } -} - -.Content { - display: inline-flex; - align-items: center; padding: spacing(loose) spacing(loose) spacing(loose) spacing(); width: 100%; - justify-content: center; @include page-content-when-not-fully-condensed { + margin: spacing(loose); width: auto; } } diff --git a/src/components/FooterHelp/FooterHelp.tsx b/src/components/FooterHelp/FooterHelp.tsx index 3888215ba91..757f818da3a 100644 --- a/src/components/FooterHelp/FooterHelp.tsx +++ b/src/components/FooterHelp/FooterHelp.tsx @@ -10,9 +10,7 @@ export interface FooterHelpProps { export function FooterHelp({children}: FooterHelpProps) { return (
-
-
{children}
-
+
{children}
); } From 5225fa870ad5fc86e36a361cf1e719a4aed8996f Mon Sep 17 00:00:00 2001 From: Alex Page Date: Fri, 28 Jan 2022 11:24:12 -0800 Subject: [PATCH 5/6] Update UNRELEASED.md --- UNRELEASED.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UNRELEASED.md b/UNRELEASED.md index 081bc66332d..80dd65ff3c7 100644 --- a/UNRELEASED.md +++ b/UNRELEASED.md @@ -11,7 +11,7 @@ Use [the changelog guidelines](/documentation/Versioning%20and%20changelog.md) t - Updated the Navigation IA ([#4902](https://github.com/Shopify/polaris-react/pull/4902)) - Added new `duplicateRootItem` prop to a Navigation Section to support new mobile Navigation IA ([#4902](https://github.com/Shopify/polaris-react/pull/4902)) - Updated mobile behaviour of Navigation to only show one sub-section at a time ([#4902](https://github.com/Shopify/polaris-react/pull/4902)) -- Remove the icon from FooterHelp and recommend using `removeUnderline` for links in the footer ([#4982](https://github.com/Shopify/polaris-react/pull/4982)) +- Remove the info icon and external link guidance from FooterHelp ([#4982](https://github.com/Shopify/polaris-react/pull/4982)) ### Bug fixes From 5b8b55dae1b26a69a499d60b0b4a4439702ed439 Mon Sep 17 00:00:00 2001 From: Alex Page Date: Fri, 28 Jan 2022 12:25:32 -0800 Subject: [PATCH 6/6] Remove icon test --- src/components/FooterHelp/tests/FooterHelp.test.tsx | 9 --------- 1 file changed, 9 deletions(-) diff --git a/src/components/FooterHelp/tests/FooterHelp.test.tsx b/src/components/FooterHelp/tests/FooterHelp.test.tsx index 0e385a1b28a..1a0c27f18ca 100644 --- a/src/components/FooterHelp/tests/FooterHelp.test.tsx +++ b/src/components/FooterHelp/tests/FooterHelp.test.tsx @@ -1,8 +1,6 @@ import React from 'react'; -import {InfoMinor} from '@shopify/polaris-icons'; import {mountWithApp} from 'tests/utilities'; -import {Icon} from '../../Icon'; import {FooterHelp} from '../FooterHelp'; describe('', () => { @@ -14,11 +12,4 @@ describe('', () => { children, }); }); - - it('renders the help icon', () => { - const footerHelp = mountWithApp({children}); - expect(footerHelp).toContainReactComponent(Icon, { - source: InfoMinor, - }); - }); });