Skip to content
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

Prefixed Icon Links do not always colorize correctly when used within Brand Textboxes #271

Open
wrenaria opened this issue Dec 19, 2023 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@wrenaria
Copy link

There some funky colorization that happens if you put a prefixed icon link within a brand text box.

Examples on Stage at: https://stage.library.ucdavis.edu/brand-boxes/

Screenshots for quick ref/posterity:

Screenshot 2023-12-19 at 2 48 14 PM

@wrenaria wrenaria added the bug Something isn't working label Dec 19, 2023
@spelkey-ucd
Copy link
Member

@wrenaria Yeah, we're pushing on the limits of what the sitefarm theme can do. It isn't designed to allow brand colors within other brand colors. From a tech perspective, the --category-brand and --category-brand-contrast-color css variables get confused.

We ran into a similar issue with #259. For that, I was able to put in a little patch since, from a code perspective, the priority links are kind of a one-off. However, a full patch for this will likely be more involved.

But we might be able to figure something else out. What exactly are you trying to accomplish/how should it look?

Do you just want an icon link to render in the brand textbox's normal colors? Like the datalab email link below:

image

Or do you actually want to use a different color for the icon while keeping the text the contrast color of the text box:
image

@wrenaria
Copy link
Author

wrenaria commented Jan 9, 2024

@spelkey-ucd It doesn't really matter which solution is used. All white works well and is the most forgiving/contrasty with the different colors, but it's not a currently achievable option from what is available. Ultimately, I just want it to be legible/consistently colored. A green text link on a green background is not.

But if it is a pain/theme breaking, I can figure out a different design solution/not use prefixed links on colored backgrounds.

@spelkey-ucd
Copy link
Member

nah i can get it to be the contrast color (white for most), at least on the public side.

spelkey-ucd added a commit that referenced this issue Jan 9, 2024
spelkey-ucd added a commit that referenced this issue Jan 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants