-
Notifications
You must be signed in to change notification settings - Fork 0
fix: restore functionality from merge #882
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Warning: Component files have been updated but no migrations have been added. See https://github.com/yext/visual-editor/blob/main/packages/visual-editor/src/components/migrations/README.md for more information. |
commit: |
e3bfe05
into
fall-2025-slot-ify-components
|
Caution Review failedThe pull request is closed. WalkthroughThis pull request introduces empty-state handling and data migration features across multiple components. The NearbyLocations component gains a new empty-state UI component with observer-based change detection (ResizeObserver and MutationObserver) to track rendering state. NearbyLocationsCardsWrapper adds early loading state rendering and simplified empty-data checks. ReviewsSection introduces a new exported interface (ReviewsSectionProps), expands props destructuring to include editing state (puck), and updates empty-state logic to consider query status. The main template file adds a transformProps function that performs data migration and resolution before rendering. Sequence DiagramsequenceDiagram
participant Mount as Component Mount
participant Observer as ResizeObserver/<br/>MutationObserver
participant State as Component State
participant Render as Render Logic
Mount->>Observer: Setup watchers on mount<br/>(cards wrapper + empty-state)
Observer->>Observer: Perform initial check
Observer->>State: Detect changes in DOM
Note over State: isEmptyState evaluation:<br/>1. Empty-state marker present?<br/>2. Element height > 0?<br/>3. Content presence (wrapper)?<br/>4. Loading state?
State->>Render: isEmptyState = true
Render->>Render: Render NearbyLocationsEmptyState<br/>(with MapPinOff icon + text)
Note over Render: Alternative path
State->>Render: isEmptyState = false
Render->>Render: Render standard<br/>NearbyLocationsSection
Possibly related PRs
Suggested reviewers
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (4)
Comment |
tested here: https://www.yext.com/s/4259018/yextsites/161497/branches/131426/editor#pageSetId=empty-loc-test&locale=en&themeId=empty-test&entityId=1095527849
Fix reviews section, slotify nearby locations empty state logic, and restore migration logic that was removed