Skip to content

chore: merge main into branch#1228

Draft
asanehisa wants to merge 20 commits into
2026-custom-components-templatesfrom
merge-main
Draft

chore: merge main into branch#1228
asanehisa wants to merge 20 commits into
2026-custom-components-templatesfrom
merge-main

Conversation

@asanehisa
Copy link
Copy Markdown
Contributor

No description provided.

asanehisa and others added 19 commits May 6, 2026 11:22
Before:
<img width="671" height="331" alt="Screenshot 2026-05-05 at 4 11 15 PM"
src="https://github.com/user-attachments/assets/05196088-08b8-4e7f-a8ed-7c6c012a950c"
/>

After:
<img width="668" height="286" alt="Screenshot 2026-05-05 at 4 13 05 PM"
src="https://github.com/user-attachments/assets/f3d4c1e1-5286-4582-ac9d-41fddf57b1c2"
/>

(ignore the font changing)

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Allow boolean display fields in locator result card headings (Primary
Heading, Secondary Heading, and Tertiary Heading). When a boolean field
is selected, allow the users to set what should display in the result
card for true and false cases via 2 static text boxes.

J=WAT-5527
TEST=manual

tested in dev mode, Rob approved UI
https://yext.slack.com/archives/C0A1G447MPD/p1778015267221689

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1. Adds a framework for linked entities

This PR does not modify the existing components like Events, FAQs,
Testimonials, etc

These functions can be used in new components or generated components

Includes example in the README

2. Swaps from using LINKED_ENTITY_SCHEMAS to ENTITY_FIELDS

3. Separates the entity field picker into two sections for linked fields
and entity fields.
<img width="378" height="453" alt="Screenshot 2026-05-05 at 7 08 15 PM"
src="https://github.com/user-attachments/assets/14070116-e4f7-4fa1-88f0-e69812847336"
/>


[https://dev.yext.com/s/1000168938/yextsites/67162/branches/6818/editor#pageSetId=linkedentityframework&local[…]ase2&entityId=9125102&xYextDebug=true](https://dev.yext.com/s/1000168938/yextsites/67162/branches/6818/editor#pageSetId=linkedentityframework&locale=en&themeId=dev-release2&entityId=9125102&xYextDebug=true)

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Matt Kilpatrick <mkilpatrick@yext.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Using the category names breaks when the locale is not `en` because the
names are translated. This updates the mapping to use the IDs of the
top-level categories instead, which is stable.

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This turns toPuckFields into a true adapter instead of just a TS cast
because actual usage was causing console errors. Also add some exports
that should've been exported.

Context:
- We export Yext field types like `basicSelector`, `ctaSelector`,
`entityField`, `multiSelector`, etc.
- We also export `YextPuckFieldOverrides` and `YextAutoField`.
- Today `toPuckFields()` is basically:

```
  export const toPuckFields = <Props extends DefaultComponentProps = DefaultComponentProps>(
    fields: YextFields<Props> | YextFieldMap<Props>
  ): Fields<Props> => fields as unknown as Fields<Props>;
```

Problem:
- Puck’s `overrides.fieldTypes.basicSelector` is not enough.
- Puck’s `AutoFieldInternal` still tries to render a default child
renderer from `defaultFields[field.type]`.
- For `basicSelector`, `defaultFields.basicSelector` is undefined,
causing:

  React.jsx: type is invalid -- expected a string ... but got undefined
  Check the render method of AutoFieldInternal

---------

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Adds a new createSlottedItemSource which functions like createItemSource
but for slot-based components

Migrates Events Section, FAQs Section, Teams Section, Testimonials
Section, Insights Section, and Products Section to this new system

Updates the Entity Field picker to use the name of the subfield for
entity fields.
<img width="284" height="566" alt="Screenshot 2026-05-11 at 1 00 11 PM"
src="https://github.com/user-attachments/assets/34fc74bb-db63-4ffd-b135-09342c51c6ae"
/>

Adds migration 0076 to map from the old system to the new.

Testing site here:
https://dev.yext.com/s/1000168938/yextsites/67197/branches/6862/editor#pageSetId=slotslocation&locale=en&themeId=dev-release3&entityId=9125102

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Matt Kilpatrick <mkilpatrick@yext.com>
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Uses the embedded field utilities to support modifying the directory
card title


https://github.com/user-attachments/assets/d192a5a5-3a71-4dcc-b6cf-7af15ffa0815

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Entity Field pickers under Mappings in itemSource and slottedItemSource
are scoped to the items selected in the parent field.

However embedded field pickers did not have this scoping. This change
fixes the embedded field pickers to respect the scope.

Also includes passing the sourceField to the Rich Text editor so that it
can scope to subfields properly.

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
When linked entity fields with multiple entities are used for a standard
(non-mapping) prop, we show a warning message. This PR changes the
message to:

{{linkedField}} contains multiple linked entities. Using the first one
for {{resolvedField}}.

The previous message was "Multiple linked entities were found for
{{resolvedField}} using the first linked entity."

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Updates the warning that is displayed when there are multiple linked
entities for a field to use the display names instead of API names.

Shows the linked entities warning when a linked entity field is chosen
by the embedded field picker.

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
primaryLocales were not getting normalized, which led to a mismatch
where "en-GB" in the locale and "en_gb" in the primaryLocale would be
seen as different and the locale would be pre-prended.

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Just a copy of work in this
[PR](#1222) for our other
branch.

Included a small change in DirectoryCard.tsx so tests would pass.
Before:
<img width="618" height="417" alt="Screenshot 2026-06-02 at 11 56 38 AM"
src="https://github.com/user-attachments/assets/74e1dc3c-bd98-454e-842a-d77c82fa668b"
/>

Now the accordion is hidden when comingSoon is true.

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
# Conflicts:
#	packages/visual-editor/CHANGELOG.md
#	packages/visual-editor/locales/platform/tr/visual-editor.json
#	packages/visual-editor/package.json
#	packages/visual-editor/src/components/LocatorResultCard.tsx
#	packages/visual-editor/src/components/directory/DirectoryWrapper.tsx
#	packages/visual-editor/src/components/pageSections/NearbyLocations/NearbyLocationCard.tsx
#	packages/visual-editor/src/editor/Editor.tsx
#	packages/visual-editor/src/editor/EmbeddedFieldStringInput.test.tsx
#	packages/visual-editor/src/editor/EmbeddedFieldStringInput.tsx
#	packages/visual-editor/src/editor/TranslatableRichTextField.test.tsx
#	packages/visual-editor/src/fields/EntityFieldSelectorField.test.tsx
#	packages/visual-editor/src/fields/EntityFieldSelectorField.tsx
#	packages/visual-editor/src/fields/fieldOverrides.ts
#	packages/visual-editor/src/fields/fields.ts
#	packages/visual-editor/src/vite-plugin/defaultLayoutData.ts
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 2, 2026

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.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Jun 2, 2026

Review Change Stack

Walkthrough

This patch release (1.3.2) adds support for the comingSoon flag in hours-related UI components across the Locator and nearby locations features. The package version is bumped, changelog and Turkish locale strings are updated, and a new test case validates the comingSoon rendering behavior. Component hours props are refactored to remove type casting and pass object spreads directly. Additionally, field selection scoping and directory grid normalization logic are refined to handle source fields and incoming mappings more precisely.

Possibly related PRs

  • yext/visual-editor#1215: Fixes embedded field picker scoping in mapping via updates to EmbeddedFieldStringInput.handleFieldSelect resolution path and document selection logic.
  • yext/visual-editor#1226: Adds the same version 74 comingSoon fixture and modifies LocatorResultCard hours rendering behavior.
  • yext/visual-editor#1220: Updates EmbeddedFieldStringInput callback argument handling and DirectoryWrapper grid normalization in parallel with this PR.

Suggested labels

create-dev-release

Suggested reviewers

  • benlife5
  • mkilpatrick
  • briantstephan
🚥 Pre-merge checks | ✅ 2 | ❌ 2

❌ Failed checks (1 warning, 1 inconclusive)

Check name Status Explanation Resolution
Title check ⚠️ Warning The title 'chore: merge main into branch' is unrelated to the actual changeset. The PR contains multiple meaningful feature and bug fix changes (version bump, comingSoon handling, localization updates, component refactoring), but the title falsely describes it as a merge commit. Update the title to reflect the actual changes, such as 'chore: v1.3.2 release with comingSoon UI enhancements and bug fixes' or similar.
Description check ❓ Inconclusive No description was provided by the author, making it impossible to verify relevance to the changeset. Add a pull request description that explains the purpose and scope of the changes included in this release.
✅ Passed checks (2 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch merge-main

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
packages/visual-editor/src/components/Locator.test.tsx (1)

1186-1215: ⚠️ Potential issue | 🔴 Critical | ⚡ Quick win

Remove duplicate test case.

This test case is identical to the one already added at lines 364-394. Having duplicate test entries in the array will cause redundant test execution and potential confusion.

🔧 Proposed fix

Remove this duplicate test case entry (lines 1186-1215) as it's already defined at lines 364-394.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@packages/visual-editor/src/components/Locator.test.tsx` around lines 1186 -
1215, Remove the duplicate test entry object whose name is "version 74
comingSoon" (the case with document.comingSoon: true, version: 74, and props: {
...LocatorComponent.defaultProps }) — it is already defined earlier in the
tests; delete this second occurrence to avoid running redundant tests and keep
the test array unique.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@packages/visual-editor/locales/platform/tr/visual-editor.json`:
- Line 568: The translation for the key linkedEntityMultiValueWarning has
inverted meaning; update the Turkish string so it clearly states that the first
linked entity will be used as a fallback (not that it won't be used). Edit the
value for linkedEntityMultiValueWarning to a wording like "{{linkedField}}
birden fazla bağlantılı varlık içeriyor; {{resolvedField}} için ilk olan
kullanılacak." so it accurately reflects the fallback behavior.

---

Outside diff comments:
In `@packages/visual-editor/src/components/Locator.test.tsx`:
- Around line 1186-1215: Remove the duplicate test entry object whose name is
"version 74 comingSoon" (the case with document.comingSoon: true, version: 74,
and props: { ...LocatorComponent.defaultProps }) — it is already defined earlier
in the tests; delete this second occurrence to avoid running redundant tests and
keep the test array unique.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: cfa7e1b8-b0e7-4154-b4b2-ccc6c759cac3

📥 Commits

Reviewing files that changed from the base of the PR and between 1a1a504 and a50475c.

📒 Files selected for processing (8)
  • packages/visual-editor/CHANGELOG.md
  • packages/visual-editor/locales/platform/tr/visual-editor.json
  • packages/visual-editor/package.json
  • packages/visual-editor/src/components/Locator.test.tsx
  • packages/visual-editor/src/components/LocatorResultCard.tsx
  • packages/visual-editor/src/components/directory/DirectoryWrapper.tsx
  • packages/visual-editor/src/components/pageSections/NearbyLocations/NearbyLocationCard.tsx
  • packages/visual-editor/src/editor/EmbeddedFieldStringInput.tsx

"link": "bağlantı",
"linkedEntityFields": "Bağlantılı Varlık Alanları",
"linkedEntityMultiValueWarning": "{{linkedField}} birden fazla bağlantılı varlık içerir. {{resolvedField}} için ilkini kullan.",
"linkedEntityMultiValueWarning": "{{linkedField}} birden fazla bağlantılı varlık içerir. {{resolvedField}} için ilkini kullanma.",
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.

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Fix inverted meaning in Turkish linked-entity warning.

The new sentence says “don’t use the first one,” which appears opposite of the fallback behavior this warning communicates. This will mislead users in the editor UI.

Suggested text correction
-  "linkedEntityMultiValueWarning": "{{linkedField}} birden fazla bağlantılı varlık içerir. {{resolvedField}} için ilkini kullanma.",
+  "linkedEntityMultiValueWarning": "{{linkedField}} birden fazla bağlantılı varlık içerir. {{resolvedField}} için ilkini kullan.",
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
"linkedEntityMultiValueWarning": "{{linkedField}} birden fazla bağlantılı varlık içerir. {{resolvedField}} için ilkini kullanma.",
"linkedEntityMultiValueWarning": "{{linkedField}} birden fazla bağlantılı varlık içerir. {{resolvedField}} için ilkini kullan.",
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@packages/visual-editor/locales/platform/tr/visual-editor.json` at line 568,
The translation for the key linkedEntityMultiValueWarning has inverted meaning;
update the Turkish string so it clearly states that the first linked entity will
be used as a fallback (not that it won't be used). Edit the value for
linkedEntityMultiValueWarning to a wording like "{{linkedField}} birden fazla
bağlantılı varlık içeriyor; {{resolvedField}} için ilk olan kullanılacak." so it
accurately reflects the fallback behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants