Skip to content

feat: Add speaker component with Content Fragment support and update filters#11

Merged
tusharmane-tm merged 1 commit intomainfrom
qa
Feb 6, 2026
Merged

feat: Add speaker component with Content Fragment support and update filters#11
tusharmane-tm merged 1 commit intomainfrom
qa

Conversation

@tusharmane-tm
Copy link
Contributor

Please always provide the GitHub issue(s) your PR is for, as well as test URLs where your change can be observed (before and after):

Fix #

Test URLs:

@aem-code-sync
Copy link

aem-code-sync bot commented Feb 6, 2026

Hello, I'm the AEM Code Sync Bot and I will run some actions to deploy your branch and validate page speed.
In case there are problems, just click a checkbox below to rerun the respective action.

  • Re-run PSI checks
  • Re-sync branch
Commits

@gemini-code-assist
Copy link

Summary of Changes

Hello @tusharmane-tm, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request introduces a new 'Speaker' component, enhancing the system's ability to present speaker profiles. The component is designed to be highly flexible by leveraging Content Fragments for data sourcing, which streamlines content management and ensures reusability. The changes involve structural updates to component configuration files to properly register and define the new component and its data model.

Highlights

  • New Speaker Component: A new 'Speaker' component has been introduced, designed to display speaker-related information.
  • Content Fragment Support: The new Speaker component is integrated with Content Fragments, allowing it to fetch speaker data from a specified fragment path.
  • Component Integration: The component definition, filters, and models have been updated across component-definition.json, component-filters.json, and component-models.json to support the new Speaker component.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Changelog
  • component-definition.json
    • Added a new entry for the 'Speaker' component, including its title, ID, and XWalk plugin configuration, linking it to a block template named 'Speaker' with model 'speaker'.
  • component-filters.json
    • Included 'speaker' in the list of available components, making it discoverable and usable within the system's filtering mechanisms.
  • component-models.json
    • Defined a new model with ID 'speaker', which includes a field named 'fragmentPath' of type 'aem-content'. This field is intended to store the path to the Content Fragment containing speaker data.
Activity
  • The pull request is linked to a GitHub issue, indicating it addresses a specific task or bug.
  • Test URLs are provided for 'Before' and 'After' states, facilitating verification of the changes.
  • No other review comments or activities have been recorded yet.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@tusharmane-tm tusharmane-tm merged commit 44e0a1f into main Feb 6, 2026
1 of 2 checks passed
Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces a new 'speaker' component with support for fetching content from Content Fragments. The changes include updating the component definitions, models, and filters in the main JSON configuration files. New JavaScript and CSS files for the speaker block functionality and styling are also included.

My review has identified a critical bug in the fallback logic for the Content Fragment loading, which will cause a runtime error. I've also found a high-severity issue where HTML content is not rendered correctly. Additionally, there are several opportunities for code improvements regarding code duplication, dead code, and unclear implementation of social links. I've also noted a potential configuration duplication issue that could affect maintainability. Please see the detailed comments for suggestions.

Comment on lines +299 to +313
{
"title": "Speaker",
"id": "speaker",
"plugins": {
"xwalk": {
"page": {
"resourceType": "core/franklin/components/block/v1/block",
"template": {
"name": "Speaker",
"model": "speaker"
}
}
}
}
},

Choose a reason for hiding this comment

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

medium

While the new 'Speaker' component definition is functionally correct, it seems to duplicate the configuration found in the new file ue/models/blocks/_speaker.json. This can lead to maintenance issues if the two definitions diverge. If this duplication is not part of an automated build process, consider consolidating them into a single source of truth to improve maintainability.

Comment on lines +367 to +377
{
"id": "speaker",
"fields": [
{
"component": "aem-content",
"name": "fragmentPath",
"label": "Content Fragment Path",
"description": "Path to the Content Fragment containing speaker data"
}
]
},

Choose a reason for hiding this comment

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

medium

The new model for the 'speaker' component appears to be a duplicate of the model defined in ue/models/blocks/_speaker.json. Maintaining configuration in multiple places can be error-prone. If possible, it would be better to have a single source of truth for component models to avoid inconsistencies in the future.

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.

1 participant