diff --git a/projects/js-packages/publicize-components/changelog/fix-social-remove-upgrade-nudge-for-vip-sites b/projects/js-packages/publicize-components/changelog/fix-social-remove-upgrade-nudge-for-vip-sites new file mode 100644 index 0000000000000..2c522d4cde7e8 --- /dev/null +++ b/projects/js-packages/publicize-components/changelog/fix-social-remove-upgrade-nudge-for-vip-sites @@ -0,0 +1,4 @@ +Significance: patch +Type: fixed + +Ensure that VIP sites don't see the upgrade nudge diff --git a/projects/js-packages/publicize-components/src/components/form/enhanced-features-nudge.tsx b/projects/js-packages/publicize-components/src/components/form/enhanced-features-nudge.tsx index d3a2d27ecdb47..385d83e344563 100644 --- a/projects/js-packages/publicize-components/src/components/form/enhanced-features-nudge.tsx +++ b/projects/js-packages/publicize-components/src/components/form/enhanced-features-nudge.tsx @@ -1,21 +1,18 @@ import { getRedirectUrl } from '@automattic/jetpack-components'; -import { - getSiteFragment, - isAtomicSite, - isSimpleSite, -} from '@automattic/jetpack-shared-extension-utils'; +import { AdminSiteData, getScriptData } from '@automattic/jetpack-script-data'; +import { getSiteFragment } from '@automattic/jetpack-shared-extension-utils'; import { Button, PanelRow } from '@wordpress/components'; import { _x } from '@wordpress/i18n'; import { hasSocialPaidFeatures } from '../../utils'; import styles from './styles.module.scss'; import { useAutoSaveAndRedirect } from './use-auto-save-and-redirect'; +const DISABLE_NUDGE_FOR: Array< AdminSiteData[ 'host' ] > = [ 'wpcom', 'atomic', 'woa', 'vip' ]; + export const EnhancedFeaturesNudge: React.FC = () => { const autosaveAndRedirect = useAutoSaveAndRedirect(); - const isWpcom = isSimpleSite() || isAtomicSite(); - - if ( isWpcom || hasSocialPaidFeatures() ) { + if ( hasSocialPaidFeatures() || DISABLE_NUDGE_FOR.includes( getScriptData().site.host ) ) { return null; } diff --git a/projects/plugins/jetpack/changelog/fix-social-remove-upgrade-nudge-for-vip-sites b/projects/plugins/jetpack/changelog/fix-social-remove-upgrade-nudge-for-vip-sites new file mode 100644 index 0000000000000..e16d5f6666a7f --- /dev/null +++ b/projects/plugins/jetpack/changelog/fix-social-remove-upgrade-nudge-for-vip-sites @@ -0,0 +1,4 @@ +Significance: patch +Type: bugfix + +Social | Ensure that VIP sites don't see the upgrade nudge diff --git a/projects/plugins/social/changelog/fix-social-remove-upgrade-nudge-for-vip-sites b/projects/plugins/social/changelog/fix-social-remove-upgrade-nudge-for-vip-sites new file mode 100644 index 0000000000000..2c522d4cde7e8 --- /dev/null +++ b/projects/plugins/social/changelog/fix-social-remove-upgrade-nudge-for-vip-sites @@ -0,0 +1,4 @@ +Significance: patch +Type: fixed + +Ensure that VIP sites don't see the upgrade nudge