Skip to content

frontend: cleanup crds view#3561

Merged
illume merged 1 commit intokubernetes-sigs:mainfrom
farodin91:frontend--cleanup-crds-view
Jul 7, 2025
Merged

frontend: cleanup crds view#3561
illume merged 1 commit intokubernetes-sigs:mainfrom
farodin91:frontend--cleanup-crds-view

Conversation

@farodin91
Copy link
Contributor

@farodin91 farodin91 commented Jul 3, 2025

Summary

This PR adds feature by make crds more consistent with other views.

image
image
image

Related Issue

Fixes #ISSUE_NUMBER

Changes

  • Added/Updated [component/file/logic]
  • Fixed [bug/issue/typo]
  • Refactored [code/module] for clarity/performance

Steps to Test

  1. [Step 1: e.g., Navigate to ...]
  2. [Step 2: Click on ...]
  3. [Step 3: Observe behavior or check logs/output]

Screenshots (if applicable)

Notes for the Reviewer

  • [e.g., This touches the i18n layer, so please check language consistency.]

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Jul 3, 2025
@k8s-ci-robot k8s-ci-robot requested review from illume and skoeva July 3, 2025 20:53
@k8s-ci-robot k8s-ci-robot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Jul 3, 2025
Signed-off-by: farodin91 <github@jan-jansen.net>
@farodin91 farodin91 force-pushed the frontend--cleanup-crds-view branch from c0c74d8 to 75cd17a Compare July 3, 2025 20:59
@illume illume requested a review from Copilot July 7, 2025 15:29
Copy link
Contributor

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 refactors the CRD views to align with other list views by unifying component imports, adjusting namespace filters, and introducing a backLink/subtitle pattern across resource lists.

  • Unified imports and removed obsolete renderer components in CustomResourceList and CustomResourceDefinitionList.
  • Added backLink and subtitle support in ResourceListView and CustomResourceListTable.
  • Updated snapshots to match the cleaned-up grid and filter layouts.

Reviewed Changes

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

Show a summary per file
File Description
frontend/src/components/crd/snapshots/CustomResourceList.List.stories.storyshot Cleaned up grid wrappers and added new filter widget in snapshots
frontend/src/components/crd/snapshots/CustomResourceDefinition.List.stories.storyshot Removed duplicate filter section from snapshot
frontend/src/components/crd/snapshots/CustomResourceDefinition.Details.stories.storyshot Added Back button, Create icon, and filter UI in details snapshot
frontend/src/components/crd/List.tsx Disabled namespace filter on CRD list and consolidated imports
frontend/src/components/crd/CustomResourceList.tsx Dropped legacy renderer, set default title, and grouped imports
frontend/src/components/crd/CustomResourceInstancesList.tsx Grouped imports and removed SectionBox wrapper around instances view
frontend/src/components/common/Resource/ResourceListView.tsx Introduced backLink prop and subtitle support in ResourceListView
Comments suppressed due to low confidence (2)

frontend/src/components/common/Resource/ResourceListView.tsx:28

  • The comment has a typo with an extra parenthesis and uses incorrect JSDoc syntax (//** instead of /**); consider using a proper JSDoc block and correcting the typo to improve clarity.
  //** The location to go back to. If provided as an empty string, the browser's history will be used. If not provided (default)), then no back button is used. */

frontend/src/components/crd/CustomResourceInstancesList.tsx:77

  • [nitpick] The SectionBox wrapper with backLink was removed, which may remove navigation controls and styling; consider reintroducing a wrapper or configuring a backLink prop to preserve consistent layout and back navigation.
    <>

@illume
Copy link
Contributor

illume commented Jul 7, 2025

Removing the namespace filter from the CRD list is good, because that didn't make any sense.
image

Copy link
Contributor

@illume illume left a comment

Choose a reason for hiding this comment

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

🎉 thanks

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: farodin91, illume

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 7, 2025
@illume illume merged commit 859f7e3 into kubernetes-sigs:main Jul 7, 2025
11 of 12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants