Skip to content

Conversation

@srambach
Copy link
Member

Fixes #87

Adds a high contrast border on a pseudoelement for filter side panel and vertical tabs when hovered.

Will need PatternFly 6.4 for the high contrast tokens.
Since there is no theme switcher, add pf-v6-theme-high-contrast to the html tag to trigger high contrast mode.

@srambach
Copy link
Member Author

The build for this is failing, and cursor says

"The error indicates that your project is configured to use Yarn 4.5.3 (as specified in the packageManager field), but the CI environment is using Yarn 1.22.22. The solution is to enable Corepack, which manages package manager versions automatically."

and recommends adding

name: Enable Corepack
run: corepack enable

before running yarn install --frozen-lockfile
Can someone advise? @nicole, @wise-king-sullyman ?

Copy link
Contributor

@thatblindgeye thatblindgeye left a comment

Choose a reason for hiding this comment

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

This should be good to rebase after a PR for workflows was merged in. Just a note below.

Comment on lines 44 to 45
"@patternfly/react-core": "^6.4.0",
"@patternfly/react-styles": "^6.4.0"
Copy link
Contributor

Choose a reason for hiding this comment

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

Nicole had suggested I try keeping the patternfly versions in extensions as what they were, and just updating the docs framework version to the latest (6.28.9). We could try that here so that at least the docs build will allow showing the high contrast styles.

We would also probably want to add to the patternfly-docs.config.js file the following to get the switchers showing up and make it easier to test HC styles:

  hasThemeSwitcher: true,
  hasHighContrastSwitcher: true

@patternfly-build
Copy link

patternfly-build commented Oct 29, 2025

@lboehling
Copy link

The vertical tabs look good in high contrast, but i'm seeing some additional hover states being applied to the filters in this PR. I don't think we need the bkg color/high contrast border on the filter checkbox items. otherwise this looks good!

Screenshot 2025-10-29 at 4 41 35 PM


&:hover {
background-color: var(--pf-t--global--background--color--action--plain--hover);
}
Copy link
Member Author

Choose a reason for hiding this comment

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

@lboehling @thatblindgeye I didn't add the hover background, just the outline. Git blame points to a change by @nicolethoen - anyone know why this was added?

Copy link
Contributor

Choose a reason for hiding this comment

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

There is this issue that might handle this: #88

Copy link
Member Author

@srambach srambach Oct 30, 2025

Choose a reason for hiding this comment

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

So it looks like maybe it was applied to the filter side panel by accident and was only meant to be the vertical tabs?
#73 comments talk about a hover background on vertical tabs but it was also applied to the filter side panel, perhaps erroneously?

@srambach srambach assigned srambach and unassigned srambach Oct 30, 2025
@srambach
Copy link
Member Author

@thatblindgeye IDK if I still need to revert some of the dependency stuff or not?
Also I'm a little confused about the packages/module/src/components/react-catalog-view-extension.css file and whether it's actually needed or not.

Copy link
Contributor

@mcoker mcoker left a comment

Choose a reason for hiding this comment

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

Just one change por favor. Also want to double check that this visual diff looks OK. From what I see, this change:

  • Indents the entire list so that the blue line is not flush-left with the left edge of the container.

    • Before
      Image

    • After
      Image

  • Reduces the padding around the nav link/box. That makes the layout space a bit more compact. It also changes the link padding so that it matches the height of the blue accent, instead of being taller than the accent.

  • Moves the blue accent outside of the link box

    • Before

    • Image
    • After

    • Image

bottom: 0;
border-width: var(--pf-t--global--border--width--high-contrast--regular);
border-style: solid;
border-color: transparent;
Copy link
Contributor

Choose a reason for hiding this comment

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

Just a nit, we can use the action-plain border width token and change it for :hover below

Suggested change
border-color: transparent;
inset: 0;
border: var(--pf-t--global--border--width--action--plain--default) solid var(--pf-t--global--border--color--high-contrast);

text-decoration: none;

&::after {
border-color: var(--pf-t--global--border--color--high-contrast);
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
border-color: var(--pf-t--global--border--color--high-contrast);
border-width: var(--pf-t--global--border--width--action--plain--hover);

@srambach
Copy link
Member Author

srambach commented Dec 4, 2025

Just one change por favor. Also want to double check that this visual diff looks OK. From what I see, this change:

For clarity - what you see in this PR should hopefully match what you currently see on https://www.patternfly.org/extensions/catalog-view/vertical-tabs There's a whole bunch of custom styling done on .org that's now in the extension.

Copy link
Contributor

@mcoker mcoker left a comment

Choose a reason for hiding this comment

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

LGTM!

Copy link
Contributor

@mcoker mcoker left a comment

Choose a reason for hiding this comment

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

Oops just noticed a small bug. The links are currently wider than the container because they have width: 100% and an inline margin. I replaced width: 100% with display: block and it seemed to address it? You can see it's causing a horizontal scrollbar in the screenshot below.

Image

@mcoker
Copy link
Contributor

mcoker commented Dec 4, 2025

@thatblindgeye @lboehling just want to double check that this PR will introduce a few changes.

  • More compact padding/spacing so the list takes up less space overall
  • Font size of the links/tabs changes from 13px to match whatever the body font size is (probably 14px)
  • The blue accent is now always beside the tab text, it's most visible when your current tab is indented.

Here are some screenshots

Before:

Screenshot 2025-12-04 at 5 53 49 PM Screenshot 2025-12-04 at 5 53 59 PM

After:

Screenshot 2025-12-04 at 5 53 25 PM Screenshot 2025-12-04 at 5 54 07 PM

Copy link
Contributor

@thatblindgeye thatblindgeye left a comment

Choose a reason for hiding this comment

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

I think the above changes are probably mostly fine, just wondering if the accent being indented along with nested items will be an issue for consumers/other designers who may prefer the accent being consistently placed along the left-most edge of the container.

Maybe we don't change anything for now, but do we think it'd be an easy lift if we have to come back to maybe make that aspect an opt-in?

@srambach
Copy link
Member Author

I don't think it would be hard since it was like that minus the .org styling - this is how it appears on .org now since there was local styling applied for whatever reason.

@mcoker mcoker merged commit 0e5884c into patternfly:main Dec 17, 2025
5 checks passed
@github-actions
Copy link

🎉 This PR is included in version 6.3.0-prerelease.3 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

High contrast theme support

5 participants