Skip to content
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

feat: migrate ItemsListInjection mixin #1460

Merged
merged 23 commits into from
May 9, 2024

Conversation

lauramargar
Copy link
Contributor

@lauramargar lauramargar commented May 2, 2024

Pull request template

Migrate ItemsListInjection mixin.
The initial idea was to migrate all components that use this mixin and then remove it. The components involved are:

  • ResultsList
  • BannersList
  • PromotedsList
  • NextQueriesList

Motivation and context

  • Dependencies. If any, specify:
  • Open issue. If applicable, link: EMP-3792

Type of change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that causes existing functionality to not work as expected)
  • Change requires a documentation update

What is the destination branch of this PR?

  • Main
  • Other. Specify:

How has this been tested?

Tests performed according to testing guidelines:

Checklist:

  • My code follows the style guidelines of this project.
  • I have performed a self-review on my own code.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have made corresponding changes to the documentation.
  • My changes generate no new warnings.
  • I have added tests that prove my fix is effective or that my feature works.
  • New and existing unit tests pass locally with my changes.

@lauramargar lauramargar requested a review from a team as a code owner May 2, 2024 14:09
@lauramargar lauramargar changed the title feat: migrate result list feat: migrate ItemsListInjection mixin May 2, 2024
packages/x-components/package-lock.json Outdated Show resolved Hide resolved
packages/x-components/src/components/base-grid.vue Outdated Show resolved Hide resolved
packages/x-components/src/components/base-grid.vue Outdated Show resolved Hide resolved
* @internal
*/
(
$x.on('RenderedColumnsNumberChanged', true) as unknown as Observable<
Copy link
Member

Choose a reason for hiding this comment

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

Why this subscription is only needed in this component and not the others? 🤔

joseacabaneros
joseacabaneros previously approved these changes May 7, 2024
Copy link
Member

@joseacabaneros joseacabaneros left a comment

Choose a reason for hiding this comment

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

I'm not sure if the DOM tree could interfere with styles. Anyway and for the time being, it seems the best option we have. Really good job here! 🎩
Screenshot 2024-05-07 at 4 08 59 PM

joseacabaneros
joseacabaneros previously approved these changes May 8, 2024
Copy link
Contributor

@diegopf diegopf left a comment

Choose a reason for hiding this comment

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

I've found why the NoElement was a problem in the playground. It has to do with how slots are working in vue 3 in contrast with vue 2. We can discuss it tomorrow!

@diegopf diegopf merged commit a89fb51 into main May 9, 2024
4 checks passed
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.

4 participants