Skip to content

The agent that grows with you

refactor(website): dedupe plugin catalog light-mode overrides

kshitijk4poor3eea0fe1e109
diff --git a/website/src/components/PluginCatalog/pages.module.css b/website/src/components/PluginCatalog/pages.module.css
index d6c61eb3219..a5c05e5f267 100644
--- a/website/src/components/PluginCatalog/pages.module.css
+++ b/website/src/components/PluginCatalog/pages.module.css
@@ -70,8 +70,8 @@
font-size: 0.72rem;
letter-spacing: 0.15em;
text-transform: uppercase;
- /* #a8860a is only 3.5:1 on white. #6E4F00 clears 4.5:1; dark mode overrides. */
- color: #6e4f00;
+ /* #a8860a was only 3.5:1 on white; dark mode overrides. */
+ color: var(--ifm-color-primary-darker);
margin: 0 0 0.5rem;
}
@@ -157,7 +157,7 @@
[data-theme="light"] .versionPill {
border-color: rgba(29, 78, 216, 0.45);
background: rgba(29, 78, 216, 0.08);
- color: #1d4ed8;
+ color: var(--plugin-catalog-link);
}
.starPill {
@@ -565,7 +565,7 @@
[data-theme="light"] .miniStars,
[data-theme="light"] .starPill,
[data-theme="light"] .starPill:hover {
- color: #8a6d00;
+ color: var(--ifm-color-primary-darker);
}
.miniDesc {
diff --git a/website/src/css/custom.css b/website/src/css/custom.css
index 7e38656e016..a148c612556 100644
--- a/website/src/css/custom.css
+++ b/website/src/css/custom.css
@@ -29,12 +29,14 @@
/* Catalog tier pills are inline styles. Gold #FFD700 is 1.4:1 on white;
these light-mode tones stay above 4.5:1. Dark mode overrides below. */
- --plugin-catalog-official: #6E4F00;
+ --plugin-catalog-official: var(--ifm-color-primary-darker);
--plugin-catalog-official-bg: rgba(110, 79, 0, 0.1);
--plugin-catalog-official-border: rgba(110, 79, 0, 0.4);
--plugin-catalog-community: #475569;
--plugin-catalog-community-bg: rgba(71, 85, 105, 0.1);
--plugin-catalog-community-border: rgba(71, 85, 105, 0.35);
+ /* Link blue for light-only catalog overrides (sky blue is 2:1 on white). */
+ --plugin-catalog-link: #1d4ed8;
}
/* Dark mode — the PRIMARY mode, matches landing page */
diff --git a/website/src/pages/plugins/styles.module.css b/website/src/pages/plugins/styles.module.css
index ccc248d0e66..850dad62c1c 100644
--- a/website/src/pages/plugins/styles.module.css
+++ b/website/src/pages/plugins/styles.module.css
@@ -44,7 +44,7 @@
}
[data-theme="light"] .heroEyebrow {
- color: #a8860a;
+ color: var(--ifm-color-primary-darker);
}
.heroTitle {
@@ -1148,9 +1148,8 @@ a.pickBtn {
}
/* Dark-theme gold (#ffd700, 1.4:1 on white) and sky blue (#7dd3fc / #60a5fa)
- are unreadable on the light page. These overrides use the same dark amber
- as --ifm-color-primary-darker and a blue that clears WCAG AA. */
-[data-theme="light"] .heroEyebrow,
+ are unreadable on the light page. Text uses the theme's darker amber and a
+ blue that clears WCAG AA; tints stay translucent versions of the same hues. */
[data-theme="light"] .heroLink,
[data-theme="light"] .heroLink:hover,
[data-theme="light"] .crossNavActive,
@@ -1159,19 +1158,12 @@ a.pickBtn {
[data-theme="light"] .emptyCta:hover,
[data-theme="light"] .emptyReset,
[data-theme="light"] .emptyReset:hover,
-[data-theme="light"] .starPill,
-[data-theme="light"] .starPill:hover,
-[data-theme="light"] .capChip,
-[data-theme="light"] .envChip,
-[data-theme="light"] .installHint code,
-[data-theme="light"] .copyBtn,
-[data-theme="light"] .copyBtn:hover,
-[data-theme="light"] .highlight {
- color: #6e4f00;
+[data-theme="light"] .installHint code {
+ color: var(--ifm-color-primary-darker);
}
[data-theme="light"] .searchIcon {
- color: #8b6508;
+ color: var(--ifm-color-primary);
}
[data-theme="light"] .searchInput {
@@ -1194,6 +1186,7 @@ a.pickBtn {
border-color: rgba(28, 30, 33, 0.16);
}
+/* Active rules below must stay after these: same specificity as :hover. */
[data-theme="light"] .tierBtn:hover,
[data-theme="light"] .categoryBtn:hover {
border-color: rgba(28, 30, 33, 0.32);
@@ -1202,20 +1195,18 @@ a.pickBtn {
[data-theme="light"] .tierBtnActive,
[data-theme="light"] .tierBtnActive:hover {
- color: var(--pill-color, #6e4f00);
+ color: var(--pill-color, var(--ifm-color-primary-darker));
border-color: var(--pill-border, rgba(110, 79, 0, 0.45));
background: var(--pill-bg, rgba(110, 79, 0, 0.08));
}
[data-theme="light"] .sortBtnActive,
[data-theme="light"] .sortBtnActive:hover {
- color: #6e4f00;
+ color: var(--ifm-color-primary-darker);
border-color: rgba(110, 79, 0, 0.45);
background: rgba(110, 79, 0, 0.08);
}
-[data-theme="light"] .categoryBtnActive,
-[data-theme="light"] .categoryChip,
[data-theme="light"] .categoryViewAll,
[data-theme="light"] .categoryViewAll:hover {
color: #075985;
@@ -1237,6 +1228,7 @@ a.pickBtn {
[data-theme="light"] .categoryChip {
border-color: rgba(7, 89, 133, 0.35);
background: rgba(7, 89, 133, 0.08);
+ color: #075985;
}
[data-theme="light"] .card {
@@ -1253,12 +1245,14 @@ a.pickBtn {
[data-theme="light"] .starPill:hover {
border-color: rgba(110, 79, 0, 0.35);
background: rgba(110, 79, 0, 0.08);
+ color: var(--ifm-color-primary-darker);
}
[data-theme="light"] .capChip,
[data-theme="light"] .envChip {
border-color: rgba(110, 79, 0, 0.28);
background: rgba(110, 79, 0, 0.06);
+ color: var(--ifm-color-primary-darker);
}
[data-theme="light"] .cardDates,
@@ -1269,21 +1263,16 @@ a.pickBtn {
opacity: 1;
}
-[data-theme="light"] .docsLink,
-[data-theme="light"] .docsLink:hover,
[data-theme="light"] .shaLink,
-[data-theme="light"] .shaLink:hover,
-[data-theme="light"] .versionPill,
-[data-theme="light"] .platformPill,
-[data-theme="light"] .emptyCtaSecondary,
-[data-theme="light"] .emptyCtaSecondary:hover {
- color: #1d4ed8;
+[data-theme="light"] .shaLink:hover {
+ color: var(--plugin-catalog-link);
}
[data-theme="light"] .docsLink,
[data-theme="light"] .emptyCtaSecondary {
border-color: rgba(29, 78, 216, 0.35);
background: rgba(29, 78, 216, 0.06);
+ color: var(--plugin-catalog-link);
}
[data-theme="light"] .docsLink:hover,
@@ -1297,6 +1286,7 @@ a.pickBtn {
[data-theme="light"] .platformPill {
border-color: rgba(29, 78, 216, 0.4);
background: rgba(29, 78, 216, 0.08);
+ color: var(--plugin-catalog-link);
}
[data-theme="light"] .installHint {
@@ -1304,9 +1294,11 @@ a.pickBtn {
border-color: rgba(110, 79, 0, 0.22);
}
-[data-theme="light"] .copyBtn {
+[data-theme="light"] .copyBtn,
+[data-theme="light"] .copyBtn:hover {
border-color: rgba(110, 79, 0, 0.35);
background: rgba(110, 79, 0, 0.08);
+ color: var(--ifm-color-primary-darker);
}
[data-theme="light"] .copyBtn:hover {
@@ -1315,6 +1307,7 @@ a.pickBtn {
[data-theme="light"] .highlight {
background: rgba(110, 79, 0, 0.15);
+ color: var(--ifm-color-primary-darker);
}
[data-theme="light"] .filterPanelOpen {