Skip to content

Conversation

@rkeerthient
Copy link
Contributor

Tickets - OPAQF-19,, OPAQF-84.

  • Renamed Media orientation to Media Position in promo section.
  • Added default truncate field.

Didn't run any test cases as there may not be any noticeable visual difference.

Screen.Recording.2026-01-05.at.7.08.13.PM.mov

@github-actions
Copy link
Contributor

github-actions bot commented Jan 5, 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
Contributor

coderabbitai bot commented Jan 5, 2026

Walkthrough

The PR makes two changes: it adjusts EventCard.tsx so DescriptionSlot truncation treats undefined as truncating by using a !== false check when resolving and updating parentStyles.className; and it adds desktopMediaPosition and mobileMediaPosition localization keys across many visual-editor locale files and updates PromoSection/docs to reference the new media-position keys.

Sequence Diagram(s)

(omitted)

Possibly related PRs

Suggested labels

create-dev-release

Suggested reviewers

  • benlife5
  • mkilpatrick
  • colton-demetriou
  • asanehisa
🚥 Pre-merge checks | ✅ 2
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately summarizes the main changes: renaming media orientation to media position and fixing truncate behavior in the event section.
Description check ✅ Passed The description is directly related to the changeset, referencing relevant tickets and describing the key modifications made (media position rename and truncate field addition).

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


📜 Recent review details

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between b548fb7 and 2d6e772.

📒 Files selected for processing (1)
  • packages/visual-editor/locales/zh-TW/visual-editor.json
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2025-12-23T16:36:42.670Z
Learnt from: benlife5
Repo: yext/visual-editor PR: 958
File: packages/visual-editor/locales/ro/visual-editor.json:394-394
Timestamp: 2025-12-23T16:36:42.670Z
Learning: In Romanian locale files (ro), "Top" is an acceptable translation for directional terms like "top_direction" rather than the native Romanian "Sus". The maintainer benlife5 confirmed this is the preferred translation in packages/visual-editor/locales/ro/visual-editor.json.

Applied to files:

  • packages/visual-editor/locales/zh-TW/visual-editor.json
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: call_unit_test / unit_tests (24.x)
  • GitHub Check: call_unit_test / unit_tests (20.x)
  • GitHub Check: call_unit_test / unit_tests (22.x)
  • GitHub Check: semgrep/ci
🔇 Additional comments (1)
packages/visual-editor/locales/zh-TW/visual-editor.json (1)

214-214: LGTM! Translations are accurate and properly placed.

The new desktopMediaPosition and mobileMediaPosition keys provide correct Traditional Chinese translations that appropriately distinguish "媒體" (media) from "圖像" (image). The additions align with the PR objective to support media positioning labels for sections that handle both images and videos, while preserving the existing image position keys to avoid migration issues.

Also applies to: 295-295


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
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

Fix all issues with AI Agents 🤖
In
@packages/visual-editor/src/components/pageSections/EventSection/EventCard.tsx:
- Line 439: Inconsistent handling of the truncateDescription default causes
differing behavior; update the earlier conditional that checks
data.props.styles.truncateDescription (the one currently treating undefined as
falsy) to the same pattern used elsewhere (data.props.styles.truncateDescription
!== false) so both code paths compute shouldTruncate the same way and the
DescriptionSlot renders consistently.
📜 Review details

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 0cb573f and 117c97c.

📒 Files selected for processing (2)
  • packages/visual-editor/src/components/pageSections/EventSection/EventCard.tsx
  • packages/visual-editor/src/components/pageSections/PromoSection.tsx
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: benlife5
Repo: yext/visual-editor PR: 958
File: packages/visual-editor/src/components/pageSections/heroVariants/CompactHero.tsx:38-41
Timestamp: 2025-12-23T16:30:55.497Z
Learning: In CompactHero and CompactPromo components, duplicate IDs on image elements are intentional: conditional visibility classes (hidden/sm:block/sm:hidden) ensure only one image renders at a time based on responsive breakpoints and desktopImagePosition/mobileImagePosition settings.
🧬 Code graph analysis (1)
packages/visual-editor/src/components/pageSections/PromoSection.tsx (2)
packages/visual-editor/src/editor/YextField.tsx (1)
  • YextField (188-327)
packages/visual-editor/src/editor/index.ts (1)
  • YextField (15-15)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: call_unit_test / unit_tests (20.x)
  • GitHub Check: call_unit_test / unit_tests (24.x)
  • GitHub Check: call_unit_test / unit_tests (22.x)
  • GitHub Check: semgrep/ci
🔇 Additional comments (1)
packages/visual-editor/src/components/pageSections/PromoSection.tsx (1)

133-149: LGTM! Clear label improvement.

The field label change from "Media Orientation" to "Media Position" improves clarity for users. The underlying property name and functionality remain unchanged, making this a safe UX enhancement.

Copy link
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

Fix all issues with AI Agents 🤖
In @packages/visual-editor/locales/zh-TW/visual-editor.json:
- Line 290: Update the localization value for the "mediaPosition" key: replace
the current string "媒體立場" with "媒體位置" so the zh-TW entry for mediaPosition
matches the intended spatial/layout meaning used in other locales.
📜 Review details

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 117c97c and ff8f4f2.

📒 Files selected for processing (25)
  • packages/visual-editor/locales/cs/visual-editor.json
  • packages/visual-editor/locales/da/visual-editor.json
  • packages/visual-editor/locales/de/visual-editor.json
  • packages/visual-editor/locales/en-GB/visual-editor.json
  • packages/visual-editor/locales/en/visual-editor.json
  • packages/visual-editor/locales/es/visual-editor.json
  • packages/visual-editor/locales/et/visual-editor.json
  • packages/visual-editor/locales/fi/visual-editor.json
  • packages/visual-editor/locales/fr/visual-editor.json
  • packages/visual-editor/locales/hr/visual-editor.json
  • packages/visual-editor/locales/hu/visual-editor.json
  • packages/visual-editor/locales/it/visual-editor.json
  • packages/visual-editor/locales/ja/visual-editor.json
  • packages/visual-editor/locales/lt/visual-editor.json
  • packages/visual-editor/locales/lv/visual-editor.json
  • packages/visual-editor/locales/nb/visual-editor.json
  • packages/visual-editor/locales/nl/visual-editor.json
  • packages/visual-editor/locales/pl/visual-editor.json
  • packages/visual-editor/locales/pt/visual-editor.json
  • packages/visual-editor/locales/ro/visual-editor.json
  • packages/visual-editor/locales/sk/visual-editor.json
  • packages/visual-editor/locales/sv/visual-editor.json
  • packages/visual-editor/locales/tr/visual-editor.json
  • packages/visual-editor/locales/zh-TW/visual-editor.json
  • packages/visual-editor/locales/zh/visual-editor.json
✅ Files skipped from review due to trivial changes (1)
  • packages/visual-editor/locales/fi/visual-editor.json
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2025-12-23T16:36:42.670Z
Learnt from: benlife5
Repo: yext/visual-editor PR: 958
File: packages/visual-editor/locales/ro/visual-editor.json:394-394
Timestamp: 2025-12-23T16:36:42.670Z
Learning: In Romanian locale files (ro), "Top" is an acceptable translation for directional terms like "top_direction" rather than the native Romanian "Sus". The maintainer benlife5 confirmed this is the preferred translation in packages/visual-editor/locales/ro/visual-editor.json.

Applied to files:

  • packages/visual-editor/locales/ro/visual-editor.json
  • packages/visual-editor/locales/es/visual-editor.json
  • packages/visual-editor/locales/et/visual-editor.json
  • packages/visual-editor/locales/pt/visual-editor.json
  • packages/visual-editor/locales/hu/visual-editor.json
  • packages/visual-editor/locales/sk/visual-editor.json
  • packages/visual-editor/locales/pl/visual-editor.json
  • packages/visual-editor/locales/lt/visual-editor.json
  • packages/visual-editor/locales/en-GB/visual-editor.json
  • packages/visual-editor/locales/da/visual-editor.json
  • packages/visual-editor/locales/lv/visual-editor.json
  • packages/visual-editor/locales/hr/visual-editor.json
  • packages/visual-editor/locales/tr/visual-editor.json
  • packages/visual-editor/locales/cs/visual-editor.json
  • packages/visual-editor/locales/en/visual-editor.json
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: call_unit_test / unit_tests (22.x)
  • GitHub Check: call_unit_test / unit_tests (24.x)
  • GitHub Check: call_unit_test / unit_tests (20.x)
  • GitHub Check: semgrep/ci
🔇 Additional comments (23)
packages/visual-editor/locales/nb/visual-editor.json (1)

290-290: LGTM! Localization update aligns with PR objectives.

The locale key rename from mediaOrientation to mediaPosition and its corresponding Norwegian translation update are correct and consistent with the PR's goal of renaming "Media Orientation" to "Media Position" throughout the application.

packages/visual-editor/locales/de/visual-editor.json (1)

295-295: LGTM! Locale key and translation updated correctly.

The rename from mediaOrientation to mediaPosition aligns with the PR objectives, and the German translation "Medienposition" appears accurate for "Media Position".

packages/visual-editor/locales/et/visual-editor.json (1)

290-290: LGTM! Translation is accurate.

The Estonian translation "Meedia positsioon" correctly translates "Media Position" and aligns with the PR objective to rename the media orientation field. The JSON syntax is valid.

packages/visual-editor/locales/tr/visual-editor.json (1)

290-290: LGTM!

The key rename from mediaOrientation to mediaPosition and the corresponding Turkish translation update from "Medya Yönü" to "Medya Konumu" are correct and align with the PR objectives.

packages/visual-editor/locales/it/visual-editor.json (1)

290-290: LGTM! Old key has been completely removed.

The translation "Posizione dei media" for "Media Position" is appropriate for Italian. Verification confirms the old mediaOrientation key has been completely removed from the codebase and the new mediaPosition key is consistently applied across all 25+ locale files.

packages/visual-editor/locales/nl/visual-editor.json (1)

290-290: Translation quality and key removal verified.

The Dutch translation "Mediapositie" for "Media Position" is accurate and follows proper compound word conventions. The new key name mediaPosition is semantically clearer than mediaOrientation and follows the camelCase convention used throughout the file. All references to the old mediaOrientation key have been updated with no stale references remaining in the codebase.

packages/visual-editor/locales/hu/visual-editor.json (1)

290-290: LGTM! Translation looks accurate.

The key rename from mediaOrientation to mediaPosition with the Hungarian translation "Média pozíció" aligns with the PR objectives and is grammatically correct. Verification confirms the migration is complete—no references to the old mediaOrientation key remain in the codebase, the JSON is valid, and the change has been consistently applied across all 10+ locale files.

packages/visual-editor/locales/da/visual-editor.json (1)

297-297: Locale key successfully renamed across all languages.

The key rename from mediaOrientation to mediaPosition with the Danish translation "Medieposition" is correct. Verification confirms the old key has been completely removed from the codebase and mediaPosition is consistently applied across all 24 supported locale files and the source code (PromoSection.tsx:133).

packages/visual-editor/locales/sk/visual-editor.json (1)

291-291: LGTM! Locale key rename is clean and consistent.

The rename from mediaOrientation to mediaPosition is properly implemented with an appropriate Slovak translation. This aligns with the broader UI improvement across all locales in this PR.

packages/visual-editor/locales/es/visual-editor.json (1)

289-289: LGTM! Spanish translation is accurate.

The locale key has been correctly updated to mediaPosition with an appropriate Spanish translation that conveys "Media Position".

packages/visual-editor/locales/ja/visual-editor.json (1)

290-290: LGTM! Japanese translation is appropriate.

The key has been correctly renamed to mediaPosition with a proper Japanese translation (メディアの位置).

packages/visual-editor/locales/pt/visual-editor.json (1)

290-290: LGTM! Portuguese translation is correct.

The locale key has been properly updated to mediaPosition with an accurate Portuguese translation.

packages/visual-editor/locales/en/visual-editor.json (1)

289-289: LGTM! Migration to mediaPosition is complete.

The English base translation has been updated from mediaOrientation to mediaPosition, which is clearer and more accurate. Verification confirms no remaining references to the old key exist in the codebase or locale files.

packages/visual-editor/locales/fr/visual-editor.json (1)

289-289: LGTM! Locale key rename is correct.

The locale key rename from mediaOrientation to mediaPosition is structurally correct and the French translation has been appropriately updated to reflect "Position médiatique".

packages/visual-editor/locales/zh/visual-editor.json (1)

290-290: LGTM! Locale migration from mediaOrientation to mediaPosition is complete across all languages.

The key rename is correctly implemented in all 25 locale files with proper translations. No remaining references to the old mediaOrientation key were found in the codebase.

packages/visual-editor/locales/sv/visual-editor.json (1)

291-291: No action needed — locale key rename is complete.

The migration from mediaOrientation to mediaPosition is correctly implemented across the codebase. No stale references to the old key remain, and all 25 locale files (including Swedish) have been updated consistently. The code in PromoSection.tsx properly references the new key.

packages/visual-editor/locales/ro/visual-editor.json (1)

290-290: LGTM

The translation key rename from mediaOrientation to mediaPosition and the Romanian translation "Poziția media" are correct. All code references have been properly updated—no orphaned references to the old key remain, and the new key is actively being used in PromoSection.tsx.

packages/visual-editor/locales/lv/visual-editor.json (1)

290-290: Translation key renamed correctly and consistently applied.

The translation key has been properly updated from mediaOrientation to mediaPosition, and the Latvian translation "Mediju pozīcija" (Media Position) is semantically appropriate. The old key has been completely removed from the codebase, and the change is consistently applied across all 24 locale files. This change aligns with the PR objectives to rename the field in the promo section.

packages/visual-editor/locales/cs/visual-editor.json (1)

297-297: LGTM! Clean locale key rename across all locales.

The key rename from mediaOrientation to mediaPosition with the Czech translation "Pozice médií" is correct and properly implemented. The old key has been completely removed from the codebase, and the new key is consistently present across all locale files.

packages/visual-editor/locales/lt/visual-editor.json (1)

290-290: Locale key successfully renamed across all translations.

The translation "Žiniasklaidos pozicija" (Media Position) correctly replaces the old "mediaOrientation" key, aligning with the PR objective. Verification confirms the migration is complete: all 24+ locale files have been updated to use "mediaPosition", and no remaining references to "mediaOrientation" exist in the codebase.

packages/visual-editor/locales/en-GB/visual-editor.json (1)

289-289: Approved. The mediaPosition key change is correct and the migration from mediaOrientation is complete across all 25 locale files and code references. No stale references remain.

packages/visual-editor/locales/pl/visual-editor.json (1)

291-291: LGTM! Clean key rename from mediaOrientation to mediaPosition.

The translation "Pozycja medialna" is appropriate for "Media Position" in Polish. The change is consistent across all 26 locale files with properly localized translations, and PromoSection.tsx correctly references the new key. No remaining references to the old key exist in the codebase.

packages/visual-editor/locales/hr/visual-editor.json (1)

290-290: LGTM! The locale key rename from mediaOrientation to mediaPosition is correctly implemented across all 26 locale files. The nested key structure (fields.mediaPosition) matches the code usage in PromoSection.tsx, and the Croatian translation "Položaj medija" is appropriate.

@benlife5
Copy link
Contributor

benlife5 commented Jan 6, 2026

Sorry, I wasn't clear -- let's rename the labels in the updated Promo Section
"Desktop Image Position" -> "Desktop Media Position"
"Mobile Image Position" -> "Mobile Media Position"
You can keep the object key the same so that we don't need a migration

@rkeerthient
Copy link
Contributor Author

rkeerthient commented Jan 6, 2026

Sorry, I wasn't clear -- let's rename the labels in the updated Promo Section "Desktop Image Position" -> "Desktop Media Position" "Mobile Image Position" -> "Mobile Media Position" You can keep the object key the same so that we don't need a migration

@benlife5 Just curious, Shall I do the same in HeroSection as well? I see the same labels used there as well.

Screenshot 2026-01-06 at 11 54 01 PM

@benlife5
Copy link
Contributor

benlife5 commented Jan 6, 2026

Hero doesn't have the option for a video so I think keeping it as "Image" is best

Copy link
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

🤖 Fix all issues with AI Agents
In @packages/visual-editor/locales/zh-TW/visual-editor.json:
- Line 295: The translation for the JSON key "mobileMediaPosition" uses "移動媒體定位"
which is inconsistent with other keys; update the value for
"mobileMediaPosition" to "移動媒體位置" so it matches the existing "桌面/移動 圖像/媒體 位置"
terminology and keeps consistency with keys like "desktopMediaPosition",
"mobileImagePosition", and "desktopImagePosition".
🧹 Nitpick comments (1)
packages/visual-editor/src/components/pageSections/PromoSection/PromoSection.tsx (1)

73-83: Consider updating JSDoc comments for consistency.

While not critical, the JSDoc comments on lines 74-75 and 80-81 still reference "image" positioning. Consider updating them to "media" to match the new user-facing terminology:

  • Line 74: "Positions the media to the left or right..."
  • Line 80: "Positions the media to the top or bottom..."
📝 Suggested JSDoc updates
  /**
-  * Positions the image to the left or right of the promo content on desktop (classic and compact variants).
+  * Positions the media to the left or right of the promo content on desktop (classic and compact variants).
   * @defaultValue right
   */
  desktopImagePosition: "left" | "right";

  /**
-  * Positions the image to the top or bottom of the promo content on mobile (classic and compact variants).
+  * Positions the media to the top or bottom of the promo content on mobile (classic and compact variants).
   * @defaultValue top
   */
  mobileImagePosition: "top" | "bottom";
📜 Review details

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 72e8ddd and 7c3dd14.

📒 Files selected for processing (26)
  • packages/visual-editor/locales/cs/visual-editor.json
  • packages/visual-editor/locales/da/visual-editor.json
  • packages/visual-editor/locales/de/visual-editor.json
  • packages/visual-editor/locales/en-GB/visual-editor.json
  • packages/visual-editor/locales/en/visual-editor.json
  • packages/visual-editor/locales/es/visual-editor.json
  • packages/visual-editor/locales/et/visual-editor.json
  • packages/visual-editor/locales/fi/visual-editor.json
  • packages/visual-editor/locales/fr/visual-editor.json
  • packages/visual-editor/locales/hr/visual-editor.json
  • packages/visual-editor/locales/hu/visual-editor.json
  • packages/visual-editor/locales/it/visual-editor.json
  • packages/visual-editor/locales/ja/visual-editor.json
  • packages/visual-editor/locales/lt/visual-editor.json
  • packages/visual-editor/locales/lv/visual-editor.json
  • packages/visual-editor/locales/nb/visual-editor.json
  • packages/visual-editor/locales/nl/visual-editor.json
  • packages/visual-editor/locales/pl/visual-editor.json
  • packages/visual-editor/locales/pt/visual-editor.json
  • packages/visual-editor/locales/ro/visual-editor.json
  • packages/visual-editor/locales/sk/visual-editor.json
  • packages/visual-editor/locales/sv/visual-editor.json
  • packages/visual-editor/locales/tr/visual-editor.json
  • packages/visual-editor/locales/zh-TW/visual-editor.json
  • packages/visual-editor/locales/zh/visual-editor.json
  • packages/visual-editor/src/components/pageSections/PromoSection/PromoSection.tsx
🚧 Files skipped from review as they are similar to previous changes (15)
  • packages/visual-editor/locales/en/visual-editor.json
  • packages/visual-editor/locales/ja/visual-editor.json
  • packages/visual-editor/locales/it/visual-editor.json
  • packages/visual-editor/locales/tr/visual-editor.json
  • packages/visual-editor/locales/zh/visual-editor.json
  • packages/visual-editor/locales/pl/visual-editor.json
  • packages/visual-editor/locales/fi/visual-editor.json
  • packages/visual-editor/locales/ro/visual-editor.json
  • packages/visual-editor/locales/lv/visual-editor.json
  • packages/visual-editor/locales/da/visual-editor.json
  • packages/visual-editor/locales/et/visual-editor.json
  • packages/visual-editor/locales/en-GB/visual-editor.json
  • packages/visual-editor/locales/sv/visual-editor.json
  • packages/visual-editor/locales/nb/visual-editor.json
  • packages/visual-editor/locales/cs/visual-editor.json
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2025-12-23T16:30:55.497Z
Learnt from: benlife5
Repo: yext/visual-editor PR: 958
File: packages/visual-editor/src/components/pageSections/heroVariants/CompactHero.tsx:38-41
Timestamp: 2025-12-23T16:30:55.497Z
Learning: In CompactHero and CompactPromo components, duplicate IDs on image elements are intentional: conditional visibility classes (hidden/sm:block/sm:hidden) ensure only one image renders at a time based on responsive breakpoints and desktopImagePosition/mobileImagePosition settings.

Applied to files:

  • packages/visual-editor/src/components/pageSections/PromoSection/PromoSection.tsx
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: call_unit_test / unit_tests (20.x)
  • GitHub Check: call_unit_test / unit_tests (24.x)
  • GitHub Check: call_unit_test / unit_tests (22.x)
  • GitHub Check: semgrep/ci
🔇 Additional comments (12)
packages/visual-editor/locales/es/visual-editor.json (1)

213-213: LGTM! New locale keys added correctly.

The new desktopMediaPosition and mobileMediaPosition keys are properly added to support the label rename in PromoSection. The existing desktopImagePosition and mobileImagePosition keys remain intact, which correctly avoids the need for data migration.

Also applies to: 294-294

packages/visual-editor/locales/hr/visual-editor.json (1)

214-214: LGTM! Locale keys added consistently.

The Croatian translations for desktopMediaPosition and mobileMediaPosition are properly added, matching the pattern used in other locale files.

Also applies to: 295-295

packages/visual-editor/locales/fr/visual-editor.json (1)

213-213: LGTM! French locale keys added correctly.

The new media position translation keys are properly added to the French locale file, maintaining consistency with the multilingual rollout.

Also applies to: 294-294

packages/visual-editor/src/components/pageSections/PromoSection/PromoSection.tsx (1)

191-210: LGTM! Label changes implemented correctly.

The implementation correctly updates only the user-facing labels via msg() calls while keeping the underlying field names (desktopImagePosition, mobileImagePosition) unchanged. This avoids the need for a data migration, as requested in the PR comments.

packages/visual-editor/locales/pt/visual-editor.json (1)

214-214: LGTM! Portuguese locale keys added correctly.

The Portuguese translations for the new media position labels are properly added, completing the multilingual locale updates for this feature.

Also applies to: 295-295

packages/visual-editor/locales/hu/visual-editor.json (1)

214-214: LGTM! Clean localization additions for Media Position labels.

The new translation keys support the PromoSection label changes from "Image Position" to "Media Position" while keeping the underlying object keys unchanged (as required to avoid migration). The Hungarian translations follow proper grammar patterns and are correctly positioned adjacent to the existing image position keys.

Also applies to: 295-295

packages/visual-editor/locales/de/visual-editor.json (1)

218-218: LGTM! Consistent with the localization approach.

The German translations mirror the structure used in the Hungarian locale file, properly supporting the PromoSection label updates. The compound noun "Medienposition" is grammatically correct and follows German language conventions.

Also applies to: 300-300

packages/visual-editor/locales/zh-TW/visual-editor.json (1)

214-214: LGTM!

The translation "桌面媒體位置" correctly conveys "Desktop Media Position" and uses consistent terminology with the existing desktopImagePosition field.

packages/visual-editor/locales/lt/visual-editor.json (2)

214-214: LGTM: New locale keys added consistently across all files.

Both desktopMediaPosition and mobileMediaPosition keys have been correctly added to all 25 locale files. The keys are appropriately positioned adjacent to their corresponding image position keys (desktopImagePosition and mobileImagePosition), maintaining backward compatibility and avoiding migration requirements.


295-295: LGTM: Mobile media position key is consistently added across all locale files.

The mobileMediaPosition key has been added uniformly across all 25 locale files and is appropriately positioned next to mobileImagePosition, maintaining the parallel structure for desktop and mobile configurations.

packages/visual-editor/locales/sk/visual-editor.json (1)

215-215: Approved. New Slovak translations for media position labels added correctly.

Both desktopMediaPosition and mobileMediaPosition keys are referenced in PromoSection.tsx via the msg() function and properly included in the Slovak localization file. The translations consistently replace "obraz" (image) with "média" (media), aligning with the UI label rename across the PromoSection component.

packages/visual-editor/locales/nl/visual-editor.json (1)

214-214: [rewritten comment]
[classification tag]

@rkeerthient rkeerthient requested a review from benlife5 January 6, 2026 19:15
Copy link
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

🤖 Fix all issues with AI Agents
In
@packages/visual-editor/src/components/pageSections/PromoSection/PromoSection.tsx:
- Line 192: Remove the stale locale keys fields.desktopImagePosition and
fields.mobileImagePosition from the English locale files; specifically open
packages/visual-editor/locales/en/visual-editor.json and
packages/visual-editor/locales/en-GB/visual-editor.json and delete the entries
for "fields.desktopImagePosition" and "fields.mobileImagePosition" (they were
replaced by fields.desktopMediaPosition and fields.mobileMediaPosition
referenced via msg("fields.desktopMediaPosition", ...) in PromoSection and other
code).
📜 Review details

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7c3dd14 and b548fb7.

📒 Files selected for processing (3)
  • packages/visual-editor/src/components/pageSections/PromoSection/PromoSection.tsx
  • packages/visual-editor/src/docs/ai/components.d.ts
  • packages/visual-editor/src/docs/components.md
✅ Files skipped from review due to trivial changes (1)
  • packages/visual-editor/src/docs/ai/components.d.ts
🧰 Additional context used
🧠 Learnings (2)
📚 Learning: 2025-12-23T16:30:55.497Z
Learnt from: benlife5
Repo: yext/visual-editor PR: 958
File: packages/visual-editor/src/components/pageSections/heroVariants/CompactHero.tsx:38-41
Timestamp: 2025-12-23T16:30:55.497Z
Learning: In CompactHero and CompactPromo components, the 2xl breakpoint applies unconditional left padding because once the container reaches max-width (1440px), the design requires centering with consistent left padding regardless of desktopImagePosition.

Applied to files:

  • packages/visual-editor/src/components/pageSections/PromoSection/PromoSection.tsx
  • packages/visual-editor/src/docs/components.md
📚 Learning: 2025-12-23T16:30:55.497Z
Learnt from: benlife5
Repo: yext/visual-editor PR: 958
File: packages/visual-editor/src/components/pageSections/heroVariants/CompactHero.tsx:38-41
Timestamp: 2025-12-23T16:30:55.497Z
Learning: In CompactHero and CompactPromo components, duplicate IDs on image elements are intentional: conditional visibility classes (hidden/sm:block/sm:hidden) ensure only one image renders at a time based on responsive breakpoints and desktopImagePosition/mobileImagePosition settings.

Applied to files:

  • packages/visual-editor/src/components/pageSections/PromoSection/PromoSection.tsx
  • packages/visual-editor/src/docs/components.md
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: call_unit_test / unit_tests (24.x)
  • GitHub Check: call_unit_test / unit_tests (22.x)
  • GitHub Check: call_unit_test / unit_tests (20.x)
  • GitHub Check: semgrep/ci
🔇 Additional comments (2)
packages/visual-editor/src/docs/components.md (1)

695-697: LGTM! Documentation accurately reflects media support.

The updated descriptions correctly generalize from "image" to "media" to reflect that these position properties apply to both images and videos, while appropriately keeping the property names unchanged.

packages/visual-editor/src/components/pageSections/PromoSection/PromoSection.tsx (1)

74-74: LGTM! JSDoc comments accurately updated.

The documentation comments correctly generalize from "image" to "media" to reflect support for both images and videos.

Also applies to: 80-80

benlife5
benlife5 previously approved these changes Jan 7, 2026
@mkilpatrick mkilpatrick merged commit 9963525 into main Jan 8, 2026
17 checks passed
@mkilpatrick mkilpatrick deleted the OPAQF-84 branch January 8, 2026 16:20
colton-demetriou pushed a commit that referenced this pull request Jan 8, 2026
Tickets - [OPAQF-19,](https://yext.atlassian.net/browse/OPAQF-19),
[OPAQF-84](https://yext.atlassian.net/browse/OPAQF-84).

- Renamed Media orientation to Media Position in promo section.
- Added default truncate field.

Didn't run any test cases as there may not be any noticeable visual
difference.

https://github.com/user-attachments/assets/261881e0-5717-4576-8548-abeef9395a4c

---------

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>
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.

3 participants