fix: restore Connect button outline in MUI theme - #1350
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
a8a9e49 to
1f7bb0b
Compare
christian-heusel
left a comment
There was a problem hiding this comment.
What you shared in your screenshot still looks different from the "expected" one in #1345, could you recheck the differences? From a broad look the spacing / button layout still seems to be different 😅
|
/ok-to-test |
Signed-off-by: Shitanshu Pandey <shitanshu.19p@gmail.com>
1f7bb0b to
ab4ad60
Compare
|
Thanks for catching that. I rechecked the controls against standalone at the same viewport and found the spacing/layout difference came from the same CSS cascade issue as the missing outline. The PatternFly variant tokens were already correct, but in the Community Dashboard the generic MUI compatibility mappings were winning instead. This affected the Connect border, background and horizontal padding, and the adjacent plain row-action toggle's background/padding as well. I've updated the fix to restore the existing PatternFly variant mappings only for these Workspaces controls, without hard-coding colors or dimensions. I also verified the updated Community build against standalone, including hover/focus states, and all frontend checks pass (452 tests). Would appreciate another look when you have time 😊 |
What
Fixes the Workspaces action controls rendering differently when Notebooks v2 is embedded in the Kubeflow Community Dashboard.
Fixes #1345
Root cause
The Connect and row-action controls use PatternFly
MenuTogglevariants.When comparing the same UI at the same viewport in standalone Notebooks v2 and Community Dashboard, the variant-specific PatternFly tokens were already correct in both environments.
The difference was in which CSS declarations won the cascade:
mod-arch-kubeflow/ MUI compatibility mappings winFor the secondary Connect toggle this changed the final border, background, and horizontal padding.
For the plain row-actions toggle this changed the background and horizontal padding.
Fix
The overrides remain scoped to the affected Workspaces controls.
Verification
Compared the same Workspace at a 1111px viewport in:
Before, Community resolved:
transparent10px#fff#fff10pxAfter the fix, the Community controls match the standalone variant semantics:
134.953125px37px24px / 24px#1976d237px × 37px8px / 8pxHover/focus behavior was also verified.
Checks:
npm run prettier:checknpm run test:lintnpm run test:type-checknpm run test:unit— 452 tests passednpm run build