Skip to content

Fix some ui issues#1694

Merged
tbrkollar merged 9 commits intoproject-chip:masterfrom
tbrkollar:master
Mar 17, 2026
Merged

Fix some ui issues#1694
tbrkollar merged 9 commits intoproject-chip:masterfrom
tbrkollar:master

Conversation

@tbrkollar
Copy link
Copy Markdown
Collaborator

No description provided.

@gemini-code-assist
Copy link
Copy Markdown
Contributor

Summary of Changes

Hello, 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 enhances the user interface for managing cluster domains by introducing an 'Open All' button, providing users with a quick way to expand all collapsed domains. It also refines the visibility of the 'Close All' and 'Open All' buttons, ensuring that only the appropriate action is presented to the user based on the current state of the domains.

Highlights

  • New 'Open All' Functionality: Introduced an 'Open All' action for cluster domains, complementing the existing 'Close All' functionality to provide users with more control over domain visibility.
  • Conditional Button Rendering: Implemented conditional rendering for the 'Close All' and 'Open All' buttons in the cluster manager, ensuring that only the relevant action is displayed based on whether all domains are currently collapsed or open.
  • State Management for Domain Collapse: Managed the state of whether all domains are collapsed or open within the Vuex store to support the new UI logic and ensure consistent behavior across the application.
  • Code Cleanup: Removed an unused regenerateIntoDirectory method from the ZCLToolbar component, contributing to code maintainability.

🧠 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
  • src/components/ZCLToolbar.vue
    • Removed the regenerateIntoDirectory method, which was no longer in use.
  • src/components/ZclClusterManager.vue
    • Added a v-if directive to the action buttons to conditionally display 'Close All' or 'Open All' based on the allDomainsCollapsed state.
    • Introduced a new computed property allDomainsCollapsed to retrieve the state from the Vuex store.
  • src/store/zap/mutations.js
    • Removed a redundant comment from the doActionFilter mutation.
    • Updated the doActionFilter mutation to set the state.clusterManager.allDomainsCollapsed property based on whether the 'Close All' action was performed.
  • src/store/zap/state.js
    • Added allDomainsCollapsed: true to the initial clusterManager state.
    • Included an 'Open All' option in the actionOptions array, with a domainFilterFn that sets all domains to open.
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.

Copy link
Copy Markdown
Collaborator

@brdandu brdandu left a comment

Choose a reason for hiding this comment

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

add open ALL and close all cypress tests while changing the different filter options(enabled, all clusters, etc) and make sure nothing breaks

Copy link
Copy Markdown
Contributor

@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 UI improvement for managing cluster domains by adding 'Open All' and 'Close All' buttons that toggle based on the collapsed state of the domains. The changes involve updating the Vuex store to track the collapsed state and modifying the component to display the appropriate button. The implementation is mostly correct, but I have a couple of suggestions to improve code readability and maintainability by making a conditional more explicit and addressing the use of a magic string.

Comment thread src/components/ZclClusterManager.vue
Comment thread src/store/zap/mutations.js Outdated
@tbrkollar tbrkollar requested a review from brdandu March 5, 2026 09:06
@codecov-commenter
Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 61.53846% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 75.13%. Comparing base (8b63392) to head (f4c7049).

Files with missing lines Patch % Lines
src/components/ZclClusterManager.vue 60.00% 2 Missing ⚠️
src/store/zap/mutations.js 60.00% 2 Missing ⚠️
src/store/zap/state.js 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1694      +/-   ##
==========================================
- Coverage   75.16%   75.13%   -0.03%     
==========================================
  Files         203      203              
  Lines       23833    23843      +10     
  Branches     5454     5456       +2     
==========================================
+ Hits        17914    17915       +1     
- Misses       5919     5928       +9     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

{ retries: { runMode: 2, openMode: 2 } },
() => {
cy.get('[data-test="filter-input"]').click()
// Selecting All clusters
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Selecting all clusters filter option

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Github ui is not so good. line 56,
cy.get('.q-virtual-scroll__content > :nth-child(2)').click({
force: true
})
It is the "All Clusters" option.

// hiding domains and swapping to Open All button
cy.dataCy('cluster-btn-closeall').click()
cy.dataCy('cluster-btn-closeall').should('not.exist')
cy.dataCy('cluster-btn-openall').should('exist')
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Check if the clusters do not exist after close all? (data.cluster10 and data.cluster9)

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

you are right. i add a not-visible check.


cy.fixture('data').then((data) => {
cy.get('tbody').children().contains(data.cluster9).should('exist')
cy.get('tbody').children().contains(data.cluster10).should('exist')
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

What about the not.exist when close all button is clicked?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

you are right. i add a not-visible check.

cy.fixture('data').then((data) => {
// Power Configurator for Zigbee is disabled and should not show up
// Occupancy Sensing for Matter is disabled and should not exist
cy.get('tbody').children().contains(data.cluster9).should('not.exist')
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

not exist?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Please open the file and check it again. Github ui is not so good.
you can see above in the code (before open and close) that this value does not exist.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

@tbrkollar I am also confused by this line of code should('not.exist')

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

nvm I see the comment clearly explains it // Power Configurator for Zigbee is disabled and should not show up // Occupancy Sensing for Matter is disabled and should not exist

@dhchandw dhchandw requested a review from brdandu March 12, 2026 19:47
cy.fixture('data').then((data) => {
// Power Configurator for Zigbee is disabled and should not show up
// Occupancy Sensing for Matter is disabled and should not exist
cy.get('tbody').children().contains(data.cluster9).should('not.exist')
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

@tbrkollar I am also confused by this line of code should('not.exist')

cy.fixture('data').then((data) => {
// Power Configurator for Zigbee is disabled and should not show up
// Occupancy Sensing for Matter is disabled and should not exist
cy.get('tbody').children().contains(data.cluster9).should('not.exist')
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

nvm I see the comment clearly explains it // Power Configurator for Zigbee is disabled and should not show up // Occupancy Sensing for Matter is disabled and should not exist

@tbrkollar tbrkollar merged commit b6177d5 into project-chip:master Mar 17, 2026
14 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