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(catalog): Add tile counters #874

Merged
merged 1 commit into from
Feb 27, 2024

Conversation

lordrip
Copy link
Member

@lordrip lordrip commented Feb 26, 2024

Currently, when looking for a saga component, we see a Saga component, but there's also a Saga pattern and there's no visual feedback that it exists until we click on the Pattern toggle.

This PR adds counters to each toggle, so we can monitor the occurrences in other groups as well.

In addition to that, the lookup is debounced until the user stops writing, in a 500ms window. This helps when writing the first letters of the search term, it doesn't get stuck until the UI renders.

Screencast

2024-02-26.16-41-27.mp4

fix: #745

@lordrip lordrip requested review from lhein and tplevko and removed request for lhein February 26, 2024 15:52
@tplevko
Copy link
Contributor

tplevko commented Feb 27, 2024

Hi @lordrip, looking at the e2e failures, it seems there is an issue introduced by this PR. It's making it not possible to use filtering using tags:

vokoscreenNG-2024-02-27_08-50-52.mp4

@lordrip
Copy link
Member Author

lordrip commented Feb 27, 2024

Hi @lordrip, looking at the e2e failures, it seems there is an issue introduced by this PR. It's making it not possible to use filtering using tags:
vokoscreenNG-2024-02-27_08-50-52.mp4

It looks like just the first tag is honored, I'll check it out

@lordrip lordrip force-pushed the feat/add-result-badges-for-catalog branch from af60042 to 1371ebb Compare February 27, 2024 09:34
Copy link
Contributor

@tplevko tplevko left a comment

Choose a reason for hiding this comment

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

The changes look good - the test failure seems to be caused by the addition of the debounce, where the cleanup by the reset button doesn't seem to get reflected prior to the next actions with the search field.

https://github.com/KaotoIO/kaoto-next/blob/3b963873cc7224a7c9cef43346616e8454ff35b0/packages/ui-tests/cypress/e2e/catalog.cy.ts#L12

https://github.com/KaotoIO/kaoto-next/blob/3b963873cc7224a7c9cef43346616e8454ff35b0/packages/ui-tests/cypress/e2e/catalog.cy.ts#L17

The easiest solution would be to add the verification step, to check that the field was indeed cleared.
I think the easiest way to do this is adding this check after the above mentioned lines: cy.get('.pf-v5-c-text-input-group__text-input').should('have.value', '');

Currently, when looking for a `saga` component, we see a `Saga` component, but there's also a `Saga` pattern and there's no visual feedback that it exists, until we click on the `Pattern` toggle.

This commit adds counters to each toggle, so we can monitor the
occurrences in other groups as well.

In addition to that, the lookup is debounced until the user stop
writing, in a 500ms window. This helps when writing the first letters of
the search term, it doesn't get stuck until the UI renders.

The e2e tests for the catalog were updated to include a check after
resetting the search field.

fix: KaotoIO#745
@lordrip lordrip force-pushed the feat/add-result-badges-for-catalog branch from 1371ebb to 7f2ef77 Compare February 27, 2024 13:43
@lordrip
Copy link
Member Author

lordrip commented Feb 27, 2024

cy.get('.pf-v5-c-text-input-group__text-input').should('have.value', '');

Thanks @tplevko, I've updated it according to your suggestion 💪

@lordrip lordrip merged commit 1c01516 into KaotoIO:main Feb 27, 2024
8 of 9 checks passed
@lordrip lordrip deleted the feat/add-result-badges-for-catalog branch February 27, 2024 14:36
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.

when filtering the catalog we should give users hints on results in all tabs
2 participants