Skip to content

Fallback to Merchandisers displayName set for recommendation pods #193

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

Merged
merged 2 commits into from
Feb 4, 2025

Conversation

mocca102
Copy link
Contributor

@mocca102 mocca102 commented Jan 30, 2025

Before:

  • If displayName is not passed to the section configuration we used the pod ID as a fallback displayName
Screenshot 2025-01-30 at 5 43 50 PM

After:

  • If displayName is not passed to the section configuration, we fall back to the displayName set by merchandisers and returned in the API response
Screenshot 2025-01-30 at 5 45 10 PM

@mocca102 mocca102 requested a review from a team as a code owner January 30, 2025 15:45
Copy link
Contributor

@Mudaafi Mudaafi left a comment

Choose a reason for hiding this comment

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

lgtm, just some lints. I have some ideas about improving where we do transformations, but we can follow up on that internally.

src/constants.ts Outdated
@@ -72,7 +72,8 @@ export const sectionsDescription = `- by default, typing a query will fetch data
- the order of the objects in the \`sections\` array determines the order of the results
- each autocomplete section object must have a \`indexSectionName\`
- each recommendation section object must have a \`podId\`
- each custom section object must have a \`displayName\`
- recommendation section displayName if passed will override the displayName set by Merchandisers
Copy link
Contributor

Choose a reason for hiding this comment

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

wdyt of

passing displayName in the sectionConfiguration will override the displayName set by Merchandisers on the Customer Dashboard

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I approve

src/constants.ts Outdated
@@ -112,6 +113,7 @@ export const zeroStateDescription = `- when the text input field has no text, we
- the order of the objects in the \`zeroStateSections\` array determines the order of the results
- each autocomplete section object must have a \`indexSectionName\`
- each recommendation section object must have a \`podId\`
- recommendation section displayName if passed will override the displayName set by Merchandisers
Copy link
Contributor

Choose a reason for hiding this comment

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

same as above

src/constants.ts Outdated
@@ -72,7 +72,8 @@ export const sectionsDescription = `- by default, typing a query will fetch data
- the order of the objects in the \`sections\` array determines the order of the results
- each autocomplete section object must have a \`indexSectionName\`
- each recommendation section object must have a \`podId\`
- each custom section object must have a \`displayName\`
- recommendation section displayName if passed will override the displayName set by Merchandisers
- each custom section object must have a \`displayName\`.
Copy link
Contributor

Choose a reason for hiding this comment

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

extra fullstop (.)

@mocca102 mocca102 merged commit 6c9ce4b into main Feb 4, 2025
9 of 10 checks passed
@mocca102 mocca102 deleted the ci-4136-os-ui-autocomplete-fix-failing-e2e-tests branch February 4, 2025 15:09
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.

2 participants