Skip to content

Conversation

@wesleyboar
Copy link
Member

@wesleyboar wesleyboar commented Mar 26, 2025

Overview

  • Use blue not purple accent color via:
    • Delete outdated global CSS vars.
    • Use Portal values from Core-Styles.
History
  1. Portal used Core-Styles v0 (only a few vars).
  2. Portal defined its own CSS vars.
  3. Wes copied the vars to Core-Styles v1.
  4. Portal never used Core-Styles v1.
  5. Core-Styles v2.N changed accent color.
  6. Portal upgraded to Core-Styles v2.
  7. Portal retained those vars which became Core-Styles v1.
  8. Portal is overwriting Core-Styles v2 vars with its v1 vars.
  9. Thus, portal still uses purple, not blue.

Related

Changes

  • deleted old CSS vars
  • changed all CSS vars to come from Core-Styles

Testing

  1. Verify accent color changes from blue to purple.
  2. Verify nothing else changes:
    • fonts
    • spaces
    • borders

UI

local dev prod
local, blue - via core-styles dev, purple - via local styles prod, purple - via local styles

Solution:
- Delete old CSS vars.

Why:
- So Portal uses CSS vars from Core-Styles, instead of overwriting them.

History:
1. Portal used Core-Styles v0 (only a few vars).
2. Portal defined its own CSS vars.
3. Wes copied the vars to Core-Styles v1.
4. Portal never used Core-Styles v1.
5. Portal upgraded to Core-Styles v2.
6. Portal retained those vars which became Core-Styles v1.
7. Portal is overwriting Core-Styles v2 vars with its v1 vars.
8. Thus, portal still uses purple, not blue.
@codecov
Copy link

codecov bot commented Mar 26, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 70.64%. Comparing base (56b4c2a) to head (38256c1).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #1087   +/-   ##
=======================================
  Coverage   70.64%   70.64%           
=======================================
  Files         540      540           
  Lines       33727    33727           
  Branches     3002     3002           
=======================================
  Hits        23828    23828           
  Misses       9690     9690           
  Partials      209      209           
Flag Coverage Δ
javascript 72.83% <ø> (ø)
unittests 61.34% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@wesleyboar wesleyboar changed the title feat: feat: global css vars only via core-styles Mar 26, 2025
Copy link
Member Author

@wesleyboar wesleyboar left a comment

Choose a reason for hiding this comment

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

Notes for reviewers.

Copy link
Member Author

Choose a reason for hiding this comment

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

Use only Core-Styles settings/space.css (ref); same values, but as pixels.1

Footnotes

  1. Designer chose to use pixels (static zoom-based sizing) for spaces instead of rem (dynamic font-based sizing).

Copy link
Member Author

@wesleyboar wesleyboar Mar 26, 2025

Choose a reason for hiding this comment

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

Use only Core-Styles settings/font(…).css (ref 1, ref 2); same values1 plus global font size vars.

Footnotes

  1. Same values, eventually. You gotta follow the --this-var: var(--that-var) cascade2 to verify. I verified.

  2. I will simplify the cascade in Core-Styles v3.

Copy link
Member Author

@wesleyboar wesleyboar Mar 26, 2025

Choose a reason for hiding this comment

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

Use only Core-Styles settings/color(…).css (ref 1a, ref 1b1, ref 2a, ref 2b1).

Footnotes

  1. Design tokens. Designers maintain the colors. Devs import the colors.2 2

  2. Use CSS vars or design tokens?! For now, use vars as medium for tokens.3

  3. Core-Styles v3 might offer design tokens for clients.

Comment on lines 5 to 10
@import url('@tacc/core-styles/dist/settings/border.css');
@import url('@tacc/core-styles/dist/settings/color.css');
@import url('@tacc/core-styles/dist/settings/color--portal.v2.css');
@import url('@tacc/core-styles/dist/settings/font.css');
@import url('@tacc/core-styles/dist/settings/font--portal.css');
@import url('@tacc/core-styles/dist/settings/space.css');
Copy link
Member Author

@wesleyboar wesleyboar Mar 26, 2025

Choose a reason for hiding this comment

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

Basically, load the same CSS vars, with accent color change, plus some new font size vars that are innocuous and intended for Core-Portal to eventually use.

@wesleyboar wesleyboar changed the title feat: global css vars only via core-styles feat: use blue not purple accent color Mar 27, 2025
Copy link
Member Author

@wesleyboar wesleyboar Mar 27, 2025

Choose a reason for hiding this comment

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

See #1087 (review) for annotations.

@wesleyboar wesleyboar changed the title feat: use blue not purple accent color feat: use blue not purple accent color, via core-styles Sep 11, 2025
@wesleyboar wesleyboar marked this pull request as ready for review September 11, 2025 19:30
@wesleyboar wesleyboar changed the title feat: use blue not purple accent color, via core-styles feat: use blue not purple accent color (via core-styles) Sep 11, 2025
Copy link
Contributor

@taoteg taoteg left a comment

Choose a reason for hiding this comment

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

LGTM!

--global-color-accent--weak: #6039cc40; /* similar to #E3D7FD on #f4f4f4 */

--global-color-info--dark: var(--global-color-primary--x-dark);
--global-color-info--normal: var(--global-color-primary--normal);
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't think it really matters, but might be a sign of other changes. The info box borders get darker after this changes.
Screenshot 2025-10-09 at 11 38 09 AM
Screenshot 2025-10-09 at 11 39 15 AM

Copy link
Contributor

@fnets fnets left a comment

Choose a reason for hiding this comment

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

LGTM, but a minor aesthetic change. If it's not important, I'll go ahead and approve this.

@wesleyboar
Copy link
Member Author

What @fnets found is minor, but —

  1. unexpected
  2. potentially not legible enough to pass a11y test
  3. suggests other unexpected bugs are possible

— so please hold for now.

@wesleyboar wesleyboar marked this pull request as draft October 14, 2025 22:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants