-
Notifications
You must be signed in to change notification settings - Fork 23
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
fix: remove color-context JS in favor of color-scheme
and light-dark()
#2138
Draft
zeroedin
wants to merge
35
commits into
main
Choose a base branch
from
poc/remove-color-context
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from all commits
Commits
Show all changes
35 commits
Select commit
Hold shift + click to select a range
155c5ce
docs: add color-scheme stylesheet
zeroedin 28d5253
fix(accordion): use color-scheme
zeroedin d1b542d
fix(alert): use color-scheme
zeroedin 1e75a4c
fix(audio-player): use color-scheme
zeroedin 6bbde2a
fix(avatar): use color-scheme
zeroedin 8af51ed
fix(badge): use color-scheme
zeroedin 5dcec2b
fix(blockquote): use color-scheme
zeroedin c45da3b
fix(breadcrumb): use color-scheme
zeroedin 4dba5c4
fix(button): use color-scheme
zeroedin e221bb6
fix(card): use color-scheme
zeroedin 192f486
fix(code-block): use color-scheme
zeroedin 4b2d898
fix(cta): use color-scheme
zeroedin 275c44a
fix(footer): use color-scheme
zeroedin bf820aa
fix(health-index): use color-scheme
zeroedin 1ebbcc7
fix(menu): use color-scheme
zeroedin 46b9a84
fix(navigation-secondary): use color-scheme
zeroedin 57a8e42
fix(pagination): use color-scheme
zeroedin 9340fa2
fix(site-status): use color-scheme
zeroedin b220910
fix(spinner): use color-scheme
zeroedin fa14484
fix(stat): use color-scheme
zeroedin 81be9f3
fix(subnav): use color-scheme
zeroedin 92a09dc
fix(surface): use color-scheme
zeroedin c833810
fix(switch): use color-scheme
zeroedin 945649f
fix(tabs): use color-scheme
zeroedin 0ec823b
fix(tag): use color-scheme
zeroedin 6bf8661
fix(tile): use color-scheme
zeroedin e22adc2
fix(tooltip): use color-scheme
zeroedin 0c2f657
fix(video-embed): use color-scheme
zeroedin cb0b859
fix(context-demo): use color-scheme
zeroedin 874962f
fix: apply only keyword to color-scheme
zeroedin 731852a
Merge branch 'main' into poc/remove-color-context
zeroedin 328b057
fix(cta): update cta variants
zeroedin 497043b
fix: clean up missed dark classes
zeroedin 172911a
fix: simplify css use computed values where optimal
zeroedin a95f9d8
Merge branch 'main' into poc/remove-color-context
zeroedin File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,170 @@ | ||
:root { | ||
--rh-color-surface: | ||
light-dark(var(--rh-color-surface-lightest), | ||
var(--rh-color-surface-darkest)); | ||
--rh-color-accent-base: | ||
light-dark(var(--rh-color-accent-base-on-light), | ||
var(--rh-color-accent-base-on-dark)); | ||
--rh-color-accent-brand: | ||
light-dark(var(--rh-color-accent-brand-on-light), | ||
var(--rh-color-accent-brand-on-dark)); | ||
--rh-color-border-strong: | ||
light-dark(var(--rh-color-border-strong-on-light), | ||
var(--rh-color-border-strong-on-dark)); | ||
--rh-color-border-subtle: | ||
light-dark(var(--rh-color-border-subtle-on-light), | ||
var(--rh-color-border-subtle-on-dark)); | ||
--rh-color-border-interactive: | ||
light-dark(var(--rh-color-border-interactive-on-light), | ||
var(--rh-color-border-interactive-on-dark)); | ||
--rh-color-border-destructive: | ||
light-dark(var(--rh-color-border-destructive-on-light), | ||
var(--rh-color-border-destructive-on-dark)); | ||
--rh-color-border-status-danger: | ||
light-dark(var(--rh-color-border-status-danger-on-light), | ||
var(--rh-color-border-status-danger-on-dark)); | ||
--rh-color-border-status-caution: | ||
light-dark(var(--rh-color-border-status-caution-on-light), | ||
var(--rh-color-border-status-caution-on-dark)); | ||
--rh-color-border-status-warning: | ||
light-dark(var(--rh-color-border-status-warning-on-light), | ||
var(--rh-color-border-status-warning-on-dark)); | ||
--rh-color-border-status-neutral: | ||
light-dark(var(--rh-color-border-status-neutral-on-light), | ||
var(--rh-color-border-status-neutral-on-dark)); | ||
--rh-color-border-status-info: | ||
light-dark(var(--rh-color-border-status-info-on-light), | ||
var(--rh-color-border-status-info-on-dark)); | ||
--rh-color-border-status-success: | ||
light-dark(var(--rh-color-border-status-success-on-light), | ||
var(--rh-color-border-status-success-on-dark)); | ||
--rh-color-brand-red: | ||
light-dark(var(--rh-color-brand-red-on-light), | ||
var(--rh-color-brand-red-on-dark)); | ||
--rh-color-icon-primary: | ||
light-dark(var(--rh-color-icon-primary-on-light), | ||
var(--rh-color-icon-primary-on-dark)); | ||
--rh-color-icon-secondary: | ||
light-dark(var(--rh-color-icon-secondary-on-light), | ||
var(--rh-color-icon-secondary-on-dark)); | ||
--rh-color-icon-status-danger: | ||
light-dark(var(--rh-color-icon-status-danger-on-light), | ||
var(--rh-color-icon-status-danger-on-dark)); | ||
--rh-color-icon-status-caution: | ||
light-dark(var(--rh-color-icon-status-caution-on-light), | ||
var(--rh-color-icon-status-caution-on-dark)); | ||
--rh-color-icon-status-warning: | ||
light-dark(var(--rh-color-icon-status-warning-on-light), | ||
var(--rh-color-icon-status-warning-on-dark)); | ||
--rh-color-icon-status-default: | ||
light-dark(var(--rh-color-icon-status-default-on-light), | ||
var(--rh-color-icon-status-default-on-dark)); | ||
--rh-color-icon-status-neutral: | ||
light-dark(var(--rh-color-icon-status-neutral-on-light), | ||
var(--rh-color-icon-status-neutral-on-dark)); | ||
--rh-color-icon-status-info: | ||
light-dark(var(--rh-color-icon-status-info-on-light), | ||
var(--rh-color-icon-status-info-on-dark)); | ||
--rh-color-icon-status-success: | ||
light-dark(var(--rh-color-icon-status-success-on-light), | ||
var(--rh-color-icon-status-success-on-dark)); | ||
--rh-color-interactive-primary-default: | ||
light-dark(var(--rh-color-interactive-primary-default-on-light), | ||
var(--rh-color-interactive-primary-default-on-dark)); | ||
--rh-color-interactive-primary-hover: | ||
light-dark(var(--rh-color-interactive-primary-hover-on-light), | ||
var(--rh-color-interactive-primary-hover-on-dark)); | ||
--rh-color-interactive-primary-active: | ||
light-dark(var(--rh-color-interactive-primary-active-on-light), | ||
var(--rh-color-interactive-primary-active-on-dark)); | ||
--rh-color-interactive-primary-focus: | ||
light-dark(var(--rh-color-interactive-primary-focus-on-light), | ||
var(--rh-color-interactive-primary-focus-on-dark)); | ||
--rh-color-interactive-primary-visited-default: | ||
light-dark(var(--rh-color-interactive-primary-visited-default-on-light), | ||
var(--rh-color-interactive-primary-visited-default-on-dark)); | ||
--rh-color-interactive-primary-visited-hover: | ||
light-dark(var(--rh-color-interactive-primary-visited-hover-on-light), | ||
var(--rh-color-interactive-primary-visited-hover-on-dark)); | ||
--rh-color-interactive-primary-visited-active: | ||
light-dark(var(--rh-color-interactive-primary-visited-active-on-light), | ||
var(--rh-color-interactive-primary-visited-active-on-dark)); | ||
--rh-color-interactive-primary-visited-focus: | ||
light-dark(var(--rh-color-interactive-primary-visited-focus-on-light), | ||
var(--rh-color-interactive-primary-visited-focus-on-dark)); | ||
--rh-color-interactive-secondary-default: | ||
light-dark(var(--rh-color-interactive-secondary-default-on-light), | ||
var(--rh-color-interactive-secondary-default-on-dark)); | ||
--rh-color-interactive-secondary-hover: | ||
light-dark(var(--rh-color-interactive-secondary-hover-on-light), | ||
var(--rh-color-interactive-secondary-hover-on-dark)); | ||
--rh-color-interactive-secondary-active: | ||
light-dark(var(--rh-color-interactive-secondary-active-on-light), | ||
var(--rh-color-interactive-secondary-active-on-dark)); | ||
--rh-color-interactive-secondary-focus: | ||
light-dark(var(--rh-color-interactive-secondary-focus-on-light), | ||
var(--rh-color-interactive-secondary-focus-on-dark)); | ||
--rh-color-interactive-secondary-visited-default: | ||
light-dark(var(--rh-color-interactive-secondary-visited-default-on-light), | ||
var(--rh-color-interactive-secondary-visited-default-on-dark)); | ||
--rh-color-interactive-secondary-visited-hover: | ||
light-dark(var(--rh-color-interactive-secondary-visited-hover-on-light), | ||
var(--rh-color-interactive-secondary-visited-hover-on-dark)); | ||
--rh-color-interactive-secondary-visited-active: | ||
light-dark(var(--rh-color-interactive-secondary-visited-active-on-light), | ||
var(--rh-color-interactive-secondary-visited-active-on-dark)); | ||
--rh-color-interactive-secondary-visited-focus: | ||
light-dark(var(--rh-color-interactive-secondary-visited-focus-on-light), | ||
var(--rh-color-interactive-secondary-visited-focus-on-dark)); | ||
--rh-color-status-danger: | ||
light-dark(var(--rh-color-status-danger-on-light), | ||
var(--rh-color-status-danger-on-dark)); | ||
--rh-color-status-caution: | ||
light-dark(var(--rh-color-status-caution-on-light), | ||
var(--rh-color-status-caution-on-dark)); | ||
--rh-color-status-warning: | ||
light-dark(var(--rh-color-status-warning-on-light), | ||
var(--rh-color-status-warning-on-dark)); | ||
--rh-color-status-neutral: | ||
light-dark(var(--rh-color-status-neutral-on-light), | ||
var(--rh-color-status-neutral-on-dark)); | ||
--rh-color-status-note: | ||
light-dark(var(--rh-color-status-note-on-light), | ||
var(--rh-color-status-note-on-dark)); | ||
--rh-color-status-info: | ||
light-dark(var(--rh-color-status-info-on-light), | ||
var(--rh-color-status-info-on-dark)); | ||
--rh-color-status-success: | ||
light-dark(var(--rh-color-status-success-on-light), | ||
var(--rh-color-status-success-on-dark)); | ||
--rh-color-surface-status-danger: | ||
light-dark(var(--rh-color-surface-status-danger-on-light), | ||
var(--rh-color-surface-status-danger-on-dark)); | ||
--rh-color-surface-status-caution: | ||
light-dark(var(--rh-color-surface-status-caution-on-light), | ||
var(--rh-color-surface-status-caution-on-dark)); | ||
--rh-color-surface-status-warning: | ||
light-dark(var(--rh-color-surface-status-warning-on-light), | ||
var(--rh-color-surface-status-warning-on-dark)); | ||
--rh-color-surface-status-default: | ||
light-dark(var(--rh-color-surface-status-default-on-light), | ||
var(--rh-color-surface-status-default-on-dark)); | ||
--rh-color-surface-status-neutral: | ||
light-dark(var(--rh-color-surface-status-neutral-on-light), | ||
var(--rh-color-surface-status-neutral-on-dark)); | ||
--rh-color-surface-status-info: | ||
light-dark(var(--rh-color-surface-status-info-on-light), | ||
var(--rh-color-surface-status-info-on-dark)); | ||
--rh-color-surface-status-success: | ||
light-dark(var(--rh-color-surface-status-success-on-light), | ||
var(--rh-color-surface-status-success-on-dark)); | ||
--rh-color-text-primary: | ||
light-dark(var(--rh-color-text-primary-on-light), | ||
var(--rh-color-text-primary-on-dark)); | ||
--rh-color-text-secondary: | ||
light-dark(var(--rh-color-text-secondary-on-light), | ||
var(--rh-color-text-secondary-on-dark)); | ||
--rh-color-text-brand: | ||
light-dark(var(--rh-color-text-brand-on-light), | ||
var(--rh-color-text-brand-on-dark)); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this file should
:host([color-palette=whatev])
for shadow and[color-palette=whatev]
for light (not super sure about the lightdom one...)