Skip to content

🎨 [Frontend] Grouped list view #7845

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

Open
wants to merge 29 commits into
base: master
Choose a base branch
from

Conversation

odeimaiz
Copy link
Member

@odeimaiz odeimaiz commented Jun 6, 2025

What do these changes do?

The grouped containers in the Tutorial and App browser wouldn't support the list mode view. This PR brings this enhacement.

AppsListMode

Related issue/s

How to test

Dev-ops

@odeimaiz odeimaiz self-assigned this Jun 6, 2025
@odeimaiz odeimaiz added t:enhancement Improvement or request on an existing feature a:frontend issue affecting the front-end (area group) labels Jun 6, 2025
@odeimaiz odeimaiz added this to the Bazinga! milestone Jun 6, 2025
@odeimaiz odeimaiz marked this pull request as ready for review June 6, 2025 13:23
@odeimaiz odeimaiz requested a review from Copilot June 6, 2025 13:23
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR enhances the grouped view in both the Tutorial and App browser so that list mode view is now supported for grouped containers. The changes include:

  • Refactoring the flat list creation and group container creation in ResourceContainerManager to support list mode.
  • Removing the forced grid mode in group changes in ResourceBrowserBase.
  • Adding a new "mode" property and associated logic in GroupedCardContainer with updated padding and event propagation.

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
services/static-webserver/client/source/class/osparc/dashboard/ResourceContainerManager.js Refactored __createFlatList and __createGroupContainer methods to support dynamic mode changes using a new __modeChanged helper
services/static-webserver/client/source/class/osparc/dashboard/ResourceBrowserBase.js Removed forced grid mode when grouping is changed to allow list mode support
services/static-webserver/client/source/class/osparc/dashboard/GroupedCardContainer.js Added a new "mode" property and updated __createContentContainer to adjust layout spacing and expansion based on mode
Comments suppressed due to low confidence (1)

services/static-webserver/client/source/class/osparc/dashboard/ResourceContainerManager.js:314

  • [nitpick] The __modeChanged function in ResourceContainerManager shares similar logic with the one in GroupedCardContainer. Consider refactoring this logic into a shared helper function to reduce code duplication.
const spacing = this.getMode() === "grid" ? osparc.dashboard.GridButtonBase.SPACING : osparc.dashboard.ListButtonBase.SPACING;

Copy link

sonarqubecloud bot commented Jun 6, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a:frontend issue affecting the front-end (area group) t:enhancement Improvement or request on an existing feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant