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

tmp: Theme level variables #518

Draft
wants to merge 50 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
50 commits
Select commit Hold shift + click to select a range
d56176a
Add theme layer files
mstrasinskis Oct 29, 2024
a3f1e2a
test mapping 1
mstrasinskis Oct 29, 2024
4d7fbcf
Add components level
mstrasinskis Oct 29, 2024
c408059
Fix card background
mstrasinskis Oct 30, 2024
0fca88e
Fix islands and progressbar
mstrasinskis Oct 30, 2024
c1ec551
cleanup
mstrasinskis Oct 30, 2024
1ce0322
Add night theme
mstrasinskis Oct 30, 2024
2aedae2
Cleanup
mstrasinskis Oct 30, 2024
adc116a
Fix content background
mstrasinskis Oct 30, 2024
177dd1e
Fix table header
mstrasinskis Oct 30, 2024
fc2e315
Fix tags
mstrasinskis Oct 30, 2024
43851ec
New primitives
mstrasinskis Oct 30, 2024
c8c2d2a
Fix contrast on card
mstrasinskis Oct 30, 2024
3cdec9f
Fix table hover
mstrasinskis Oct 30, 2024
554bf80
Fix background
mstrasinskis Oct 30, 2024
65fd9a6
Fix transaction history icon
mstrasinskis Oct 30, 2024
90bd788
rename: --statuses_success-shade
mstrasinskis Oct 30, 2024
b74925a
Fix popover
mstrasinskis Oct 30, 2024
1adbd0f
Update page icons
mstrasinskis Oct 30, 2024
38e5e8e
🤖 update snapshots
github-actions[bot] Oct 30, 2024
d7ed8ef
Upgrade icons w/o blur
mstrasinskis Oct 30, 2024
b53126f
Merge branch 'page-icon-colour' of github.com:dfinity/gix-components …
mstrasinskis Oct 30, 2024
95fd3d1
Fix canisters icon
mstrasinskis Oct 30, 2024
3cf5cd2
TMP Merge branch 'page-icon-colour' into theme-level-variables
mstrasinskis Oct 30, 2024
2c0d7bc
Squashed commit of the following:
mstrasinskis Oct 30, 2024
79b878b
Cleanup
mstrasinskis Oct 30, 2024
a22dbd0
TMP: tripple toggler
mstrasinskis Oct 30, 2024
006af95
tmp script
mstrasinskis Oct 31, 2024
ec60d8a
Updating formatting
github-actions[bot] Oct 31, 2024
1ee21c5
Fix the script
mstrasinskis Oct 31, 2024
49aaa6b
Merge branch 'theme-level-variables' of github.com:dfinity/gix-compon…
mstrasinskis Oct 31, 2024
41b05f7
Changes from https://github.com/dfinity/gix-components/pull/524
mstrasinskis Nov 6, 2024
66ba95a
Sync input background
mstrasinskis Nov 6, 2024
016a9a7
Restore -sidebar-button-background
mstrasinskis Nov 7, 2024
7897145
Normalise colours (w/ Dm)
mstrasinskis Nov 7, 2024
841844a
Rename --statuses_warning-surface
mstrasinskis Nov 7, 2024
186766f
Remove unused files
mstrasinskis Nov 7, 2024
3e76498
Reset icons
mstrasinskis Nov 7, 2024
94f1878
Reset license
mstrasinskis Nov 7, 2024
55c260c
Add tmp styles
mstrasinskis Nov 8, 2024
5ca447e
Fix old: --cp-light-100 -> --neutral-50
mstrasinskis Nov 8, 2024
5599ebe
Upgrade known light theme colors to new ones
mstrasinskis Nov 8, 2024
189ec45
Test for missing variables
mstrasinskis Nov 8, 2024
68c9c4d
chore: rename
mstrasinskis Nov 10, 2024
01d7996
Chore
mstrasinskis Nov 10, 2024
58be226
sortMap
mstrasinskis Nov 10, 2024
16cad34
Compare colors
mstrasinskis Nov 10, 2024
d480de6
Reset theme switcher
mstrasinskis Nov 13, 2024
6f8a2c0
Update color report script
mstrasinskis Nov 13, 2024
a823359
Add missing status colors
mstrasinskis Nov 13, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
220 changes: 220 additions & 0 deletions a-dark.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,220 @@
/** Default theme: dark */

:root {
// -------- NEW CSS VARIABLES ----------------
// We want to migrate to a new set of CSS variables for colors more adapted to our Figma.
--elements-divider: var(--night-200);
--elements-icons: var(--night-50);
--elements-badges: var(--blue-accent);
--elements-badges-inactive: var(--night-100);
--text-description: var(--night-50);
--text-description-tint: var(--night-100);

--tag-background: var(--night-400);
--tag-text: var(--night-50);
--tag-text-light: var(--night-900);
--tag-text-dark: var(--night-550);

--input-focus-background: var(--night-575);
--button-primary: var(--blue-accent);
--table-background: var(--night-500);
--table-header-background: var(--night-575);
--table-row-background: var(--night-500);
--table-row-background-hover: var(--night-575);

--alert: var(--pink-200);
--alert-tint: var(--pink-200-a25);
--check: var(--green-200);
--check-tint: var(--green-200-a25);
--pending-color: var(--orange-200);
--pending-background: var(--orange-200-a25);
--island-card-background: var(--night-575);

// -------- OLD CSS VARIABLES ----------------
// Shadows
// TODO-colors: Remove along the dark shadows.
--box-shadow-color: var(--night-500);
--box-shadow-color-rgb: 43, 51, 67;

--box-shadow: 0px 0px 6px var(--box-shadow-color);
--interaction-box-shadow: 0px 4px 4px rgba(var(--box-shadow-color-rgb), 0.25),
1px 1px 2px rgba(var(--box-shadow-color-rgb), 0.3);
--bottom-sheet-box-shadow: -1px -1px 10px rgba(var(--box-shadow-color-rgb), 0.25);
--input-box-shadow: 1px 1px 3px rgba(var(--box-shadow-color-rgb), 0.4) inset;
--content-box-shadow: 0px 0px 10px rgba(var(--box-shadow-color-rgb), 0.05);
--overlay-box-shadow: 0px 0px 8px rgba(var(--box-shadow-color-rgb), 0.2);

// Footer
--footer-background: transparent;

// Gradient
--primary-gradient: var(--blue-accent);
--primary-gradient-fallback: var(--blue-accent);

// Json colors
--json-bracket-color: inherit;
--json-value-color: var(--description-color);
--json-string-color: var(--value-color);
--json-number-color: var(--value-color);
--json-null-color: var(--description-color);
--json-principal-color: var(--value-color);
--json-hash-color: var(--value-color);
--json-bigint-color: var(--value-color);
--json-boolean-color: var(--value-color);

// Inputs
--input-border-color: var(--night-200);
--input-border-size: 1.5px;

//Tooltip
--tooltip-background: var(--neutral-50);
--tooltip-border-color: var(--neutral-blue-a10);
--tooltip-divider: var(--neutral-50);
--tooltip-description-color: var(--night-600);
--tooltip-text-color: var(--night-550);
--tooltip-border-size: 1.5px;

// Dropdown (used for Popover)
--dropdown-background: var(--night-575);
--dropdown-focus-background: var(--night-575);
--dropdown-border-color: var(--night-200);
--dropdown-focus-border-color: var(--blue-accent);
--dropdown-border-size: 1.5px;

// Buttons custom colors
--button-secondary-color: var(--blue-accent);
--button-card-focus-color: var(--blue-accent);
--button-card-focus-background: var(--night-550);
--button-disable-background: var(--night-575);
--button-disable-color: var(--night-50);

--light-opacity: 0.6;
--very-light-opacity: 0.4;

// Text color
--value-color: var(--neutral-50);
--label-color: var(--text-color);
--description-color: var(--night-50);

// Overlays - based on dark card background rgb color
--backdrop: var(--neutral-blue-1000-a80);
--backdrop-contrast: var(--neutral-50);
--backdrop-filter: blur(6px);

// Disable
--disable: var(--night-400);
--disable-contrast: var(--night-50);
// TODO-colors: Remove application of rgbs
--disable-contrast-rgb: 155, 173, 209;

// Line
--line: var(--night-400);

// Scrollbar
--scrollbar-thumb-background: transparent;
--scrollbar-thumb-color: var(--night-200);

// Progress
--progress-color: var(--blue-accent);
--progress-color-contrast: var(--neutral-50);
--progress-color-rgb: 77, 121, 255;

// Custom backgrounds
--body-background: radial-gradient(
farthest-corner circle at 0% 100%,
var(--night-1000),
var(--night-550)
);
--body-color: var(--night-100);

--content-background: var(--neutral-1000-a30);
--content-color: var(--neutral-50);
--content-start-background: var(--night-550);
--content-start-color: var(--neutral-50);

--overlay-background: var(--night-575);
--overlay-background-contrast: var(--background-contrast);
--overlay-content-background: var(--background);
--overlay-content-background-contrast: var(--neutral-50);

// Overlay inverted colors - i.e. light mode colors
--toast-inverted-background: var(--neutral-50);
--toast-inverted-background-contrast: var(--night-550);

// Menu
--menu-color: var(--neutral-50);
--menu-select-color: var(--neutral-50);
--menu-selected-background: var(--night-550);

--toolbar-color: var(--neutral-50);

// Tab and segment
--segment-selected-background: var(--overlay-content-background);

// Sidebar
--sidebar-button-background: var(--neutral-blue-a10);
--sidebar-button-background-hover: var(--night-550);
--sidebar-icon: var(--neutral-50);

// Theme color
--theme-color: var(--card-background);

// Palette

/* Light/Text/Text-xx? */
--text-color: var(--neutral-50);
--text-color-rgb: 255, 255, 255;

/* Design: Dark/Bg/Background-03 */
--input-background: var(--night-500);
--input-background-contrast: var(--neutral-50);

/* Design: Dark/Bg/Background */
--focus-background: var(--night-575);
--focus-background-rgb: 33, 39, 51;
--focus-background-contrast: var(--neutral-50);
--focus-background-tint: var(--night-400);

/* Design: Dark/Bg/Background-01 */
--card-background: var(--night-500);
--card-background-rgb: 43, 51, 67;
--card-background-contrast: var(--neutral-50);
--card-background-contrast-rgb: 255, 255, 255;
--card-background-shade: var(--night-575);
--card-background-tint: var(--night-575);
--card-background-disabled: var(--neutral-blue-a10);

/* Design: Dark/Bg/Background-02 */
--background: var(--night-400);
--background-contrast: var(--neutral-50);
--background-contrast-rgb: 255, 255, 255;
--background-shade: var(--night-600);

/* Design: Dark/Bg/Background-01 */
--background-disable: var(--neutral-75);
--background-disable-rgb: 249, 247, 255;
--background-disable-contrast: var(--disable-contrast);

--primary: var(--blue-accent);
--primary-rgb: 77, 121, 255;
--primary-contrast: var(--neutral-50);
--primary-shade: var(--blue-accent-secondary);
--primary-tint: var(--blue-accent);

--secondary: var(--blue-accent);
--secondary-rgb: 77, 121, 255;
--secondary-contrast: var(--neutral-50);

--tertiary: var(--night-50);

--warning-emphasis: var(--orange-200);
--warning-emphasis-contrast: var(--neutral-50);
--warning-emphasis-shade: var(--orange-200);

--positive-emphasis: var(--green-200);
--positive-emphasis-rgb: 45, 178, 134;
--positive-emphasis-contrast: var(--neutral-50);
--positive-emphasis-light: var(--green-200-a25);
--negative-emphasis: var(--pink-200);
--negative-emphasis-contrast: var(--neutral-50);
}
Loading