Skip to content

Studio: Fix SearchControl margin bottom styles to ensure compatibility with the new component version - #701

Merged
ivan-ottinger merged 2 commits into
trunkfrom
fix/searchControl-styling
Nov 27, 2024
Merged

Studio: Fix SearchControl margin bottom styles to ensure compatibility with the new component version#701
ivan-ottinger merged 2 commits into
trunkfrom
fix/searchControl-styling

Conversation

@ivan-ottinger

@ivan-ottinger ivan-ottinger commented Nov 27, 2024

Copy link
Copy Markdown
Contributor

Related issues

Proposed Changes

  • add __nextHasNoMarginBottom={ true } prop that removes margin bottom built into the SearchControl component
  • add margin bottom back using the className prop

Testing Instructions

  1. Check out the PR and build the app with STUDIO_SITE_SYNC=true npm start.
  2. Open browser inspector.
  3. Navigate to the Sync tab of a particular site and click on the Connect site button.
  4. There should be no Bottom margin styles for wp.components.SearchControl is deprecated since version 6.7 [...] warning displayed in the console (as described in the related issue: https://github.com/Automattic/dotcom-forge/issues/9652).
  5. There should still be a margin bottom separating the SearchControl component from the Syncing is supported for sites on the Business plan or above. text below.

Markup on 2024-11-27 at 10:40:11

Pre-merge Checklist

  • Have you checked for TypeScript, React or other console errors?
@ivan-ottinger ivan-ottinger self-assigned this Nov 27, 2024
@ivan-ottinger
ivan-ottinger requested a review from a team November 27, 2024 09:45

@katinthehatsite katinthehatsite left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes look good to me and I do not see the warning in the console anymore 👍

@ivan-ottinger
ivan-ottinger merged commit bbec227 into trunk Nov 27, 2024
@ivan-ottinger
ivan-ottinger deleted the fix/searchControl-styling branch November 27, 2024 10:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants