Skip to content

fix: wrap long workspace option card text#1150

Open
yanmo42 wants to merge 2 commits into
kubeflow:notebooks-v2from
yanmo42:platypus/kubeflow-1142-wrap-option-text
Open

fix: wrap long workspace option card text#1150
yanmo42 wants to merge 2 commits into
kubeflow:notebooks-v2from
yanmo42:platypus/kubeflow-1142-wrap-option-text

Conversation

@yanmo42

@yanmo42 yanmo42 commented Jun 3, 2026

Copy link
Copy Markdown

Fixes #1142

Summary

  • add a shared title class to Workspace option card titles
  • apply the same title class to Workspace Kind cards
  • allow Workspace option card titles and descriptions to wrap within the card
  • add a focused test assertion for the option card title class

Testing

  • npm run prettier:check -- src/app/app.css src/app/pages/Workspaces/Form/shared/WorkspaceFormOptionCard.tsx src/app/pages/Workspaces/Form/shared/tests/WorkspaceFormOptionCard.spec.tsx src/app/pages/Workspaces/Form/kind/WorkspaceFormKindList.tsx
  • npm run test:lint -- src/app/pages/Workspaces/Form/shared/WorkspaceFormOptionCard.tsx src/app/pages/Workspaces/Form/shared/tests/WorkspaceFormOptionCard.spec.tsx src/app/pages/Workspaces/Form/kind/WorkspaceFormKindList.tsx
  • npm run test:jest -- WorkspaceFormOptionCard.spec.tsx --runInBand --silent
  • npm run test:type-check -- --pretty false
  • npm run build

Signed-off-by: Ian Moog <ianmoog42@gmail.com>
@github-project-automation github-project-automation Bot moved this to Needs Triage in Kubeflow Notebooks Jun 3, 2026
@google-oss-prow google-oss-prow Bot added size/S area/frontend area - related to frontend components labels Jun 3, 2026
@google-oss-prow google-oss-prow Bot requested review from caponetto and thaorell June 3, 2026 21:48
@google-oss-prow

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign ederign for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found 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

@google-oss-prow google-oss-prow Bot added the area/v2 area - version - kubeflow notebooks v2 label Jun 3, 2026

@thaorell thaorell left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Hi @yanmo42, have you tested this implementation? There is no changes visible on my end
Before:
Image
After:

Image

expect(description).toHaveTextContent(option.description);
});

it('should render title with workspace-option-card__title class', () => {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Remove this unit test since it doesn't test the functionality of the wrapping

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Done — removed that test. You're right, it was just asserting on the CSS class name, not that text actually wraps. Stripped it out.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/frontend area - related to frontend components area/v2 area - version - kubeflow notebooks v2 size/S

Projects

Status: Needs Triage

Development

Successfully merging this pull request may close these issues.

2 participants