Skip to content

Commit 7719484

Browse files
committed
fix(table): move LESS Functions out of LESS file and into separate variables instead
1 parent bf65cde commit 7719484

File tree

3 files changed

+67
-2
lines changed

3 files changed

+67
-2
lines changed

src/definitions/collections/table.less

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -670,6 +670,8 @@ each(@colors, {
670670
@l: @colors[@@color][light];
671671
@lh: @colors[@@color][lightHover];
672672
@r: @colors[@@color][ribbon];
673+
@b: @colors[@@color][bright];
674+
@bh: @colors[@@color][brightHover];
673675
@isDark: @colors[@@color][isDark];
674676
@isVeryDark: @colors[@@color][isVeryDark];
675677

@@ -687,7 +689,7 @@ each(@colors, {
687689
background: @l;
688690
}
689691
& when not (@isDark) {
690-
background: screen(@l,@blendingBaseColor);
692+
background: @b;
691693
}
692694
& when (@isVeryDark) {
693695
color: @white;
@@ -703,7 +705,7 @@ each(@colors, {
703705
background: @lh;
704706
}
705707
& when not (@isDark) {
706-
background: screen(@lh,@blendingBaseColor);
708+
background: @bh;
707709
}
708710
& when (@isVeryDark) {
709711
color: @white;

src/themes/default/globals/colors.less

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@
3030
tertiaryHover : @primaryTertiaryColorHover;
3131
tertiaryFocus : @primaryTertiaryColorFocus;
3232
tertiaryActive : @primaryTertiaryColorActive;
33+
bright : @primaryBright;
34+
brightHover : @primaryBrightHover;
3335
isDark : false;
3436
isVeryDark : false;
3537
};
@@ -60,6 +62,8 @@
6062
tertiaryHover : @secondaryTertiaryColorHover;
6163
tertiaryFocus : @secondaryTertiaryColorFocus;
6264
tertiaryActive : @secondaryTertiaryColorActive;
65+
bright : @secondaryBright;
66+
brightHover : @secondaryBrightHover;
6367
isDark : false;
6468
isVeryDark : false;
6569
};
@@ -90,6 +94,8 @@
9094
tertiaryHover : @redTertiaryColorHover;
9195
tertiaryFocus : @redTertiaryColorFocus;
9296
tertiaryActive : @redTertiaryColorActive;
97+
bright : @redBright;
98+
brightHover : @redBrightHover;
9399
isDark : false;
94100
isVeryDark : false;
95101
};
@@ -120,6 +126,8 @@
120126
tertiaryHover : @orangeTertiaryColorHover;
121127
tertiaryFocus : @orangeTertiaryColorFocus;
122128
tertiaryActive : @orangeTertiaryColorActive;
129+
bright : @orangeBright;
130+
brightHover : @orangeBrightHover;
123131
isDark : false;
124132
isVeryDark : false;
125133
};
@@ -150,6 +158,8 @@
150158
tertiaryHover : @yellowTertiaryColorHover;
151159
tertiaryFocus : @yellowTertiaryColorFocus;
152160
tertiaryActive : @yellowTertiaryColorActive;
161+
bright : @yellowBright;
162+
brightHover : @yellowBrightHover;
153163
isDark : false;
154164
isVeryDark : false;
155165
};
@@ -180,6 +190,8 @@
180190
tertiaryHover : @oliveTertiaryColorHover;
181191
tertiaryFocus : @oliveTertiaryColorFocus;
182192
tertiaryActive : @oliveTertiaryColorActive;
193+
bright : @oliveBright;
194+
brightHover : @oliveBrightHover;
183195
isDark : false;
184196
isVeryDark : false;
185197
};
@@ -210,6 +222,8 @@
210222
tertiaryHover : @greenTertiaryColorHover;
211223
tertiaryFocus : @greenTertiaryColorFocus;
212224
tertiaryActive : @greenTertiaryColorActive;
225+
bright : @greenBright;
226+
brightHover : @greenBrightHover;
213227
isDark : false;
214228
isVeryDark : false;
215229
};
@@ -240,6 +254,8 @@
240254
tertiaryHover : @tealTertiaryColorHover;
241255
tertiaryFocus : @tealTertiaryColorFocus;
242256
tertiaryActive : @tealTertiaryColorActive;
257+
bright : @tealBright;
258+
brightHover : @tealBrightHover;
243259
isDark : false;
244260
isVeryDark : false;
245261
};
@@ -270,6 +286,8 @@
270286
tertiaryHover : @blueTertiaryColorHover;
271287
tertiaryFocus : @blueTertiaryColorFocus;
272288
tertiaryActive : @blueTertiaryColorActive;
289+
bright : @blueBright;
290+
brightHover : @blueBrightHover;
273291
isDark : false;
274292
isVeryDark : false;
275293
};
@@ -300,6 +318,8 @@
300318
tertiaryHover : @violetTertiaryColorHover;
301319
tertiaryFocus : @violetTertiaryColorFocus;
302320
tertiaryActive : @violetTertiaryColorActive;
321+
bright : @violetBright;
322+
brightHover : @violetBrightHover;
303323
isDark : false;
304324
isVeryDark : false;
305325
};
@@ -330,6 +350,8 @@
330350
tertiaryHover : @purpleTertiaryColorHover;
331351
tertiaryFocus : @purpleTertiaryColorFocus;
332352
tertiaryActive : @purpleTertiaryColorActive;
353+
bright : @purpleBright;
354+
brightHover : @purpleBrightHover;
333355
isDark : false;
334356
isVeryDark : false;
335357
};
@@ -360,6 +382,8 @@
360382
tertiaryHover : @pinkTertiaryColorHover;
361383
tertiaryFocus : @pinkTertiaryColorFocus;
362384
tertiaryActive : @pinkTertiaryColorActive;
385+
bright : @pinkBright;
386+
brightHover : @pinkBrightHover;
363387
isDark : false;
364388
isVeryDark : false;
365389
};
@@ -390,6 +414,8 @@
390414
tertiaryHover : @brownTertiaryColorHover;
391415
tertiaryFocus : @brownTertiaryColorFocus;
392416
tertiaryActive : @brownTertiaryColorActive;
417+
bright : @brownBright;
418+
brightHover : @brownBrightHover;
393419
isDark : false;
394420
isVeryDark : false;
395421
};
@@ -420,6 +446,8 @@
420446
tertiaryHover : @greyTertiaryColorHover;
421447
tertiaryFocus : @greyTertiaryColorFocus;
422448
tertiaryActive : @greyTertiaryColorActive;
449+
bright : @greyBright;
450+
brightHover : @greyBrightHover;
423451
isDark : true;
424452
isVeryDark : false;
425453
};
@@ -450,6 +478,8 @@
450478
tertiaryHover : @blackTertiaryColorHover;
451479
tertiaryFocus : @blackTertiaryColorFocus;
452480
tertiaryActive : @blackTertiaryColorActive;
481+
bright : @blackBright;
482+
brightHover : @blackBrightHover;
453483
isDark : true;
454484
isVeryDark : true;
455485
};

src/themes/default/globals/site.variables

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1296,3 +1296,36 @@
12961296
@blackTertiaryColorHover : lighten(@blackHover, 40%);
12971297
@blackTertiaryColorFocus : lighten(@blackFocus, 40%);
12981298
@blackTertiaryColorActive : lighten(@blackActive, 20%);
1299+
1300+
/*--- Bright ---*/
1301+
@primaryBright : screen(@lightPrimaryColor,@blendingBaseColor);
1302+
@secondaryBright : screen(@lightSecondaryColor,@blendingBaseColor);
1303+
@redBright : screen(@lightRed,@blendingBaseColor);
1304+
@orangeBright : screen(@lightOrange,@blendingBaseColor);
1305+
@yellowBright : screen(@lightYellow,@blendingBaseColor);
1306+
@oliveBright : screen(@lightOlive,@blendingBaseColor);
1307+
@greenBright : screen(@lightGreen,@blendingBaseColor);
1308+
@tealBright : screen(@lightTeal,@blendingBaseColor);
1309+
@blueBright : screen(@lightBlue,@blendingBaseColor);
1310+
@violetBright : screen(@lightViolet,@blendingBaseColor);
1311+
@purpleBright : screen(@lightPurple,@blendingBaseColor);
1312+
@pinkBright : screen(@lightPink,@blendingBaseColor);
1313+
@brownBright : screen(@lightBrown,@blendingBaseColor);
1314+
@greyBright : @lightGrey;
1315+
@blackBright : @lightBlack;
1316+
1317+
@primaryBrightHover : screen(@lightPrimaryColorHover,@blendingBaseColor);
1318+
@secondaryBrightHover : screen(@lightSecondaryColorHover,@blendingBaseColor);
1319+
@redBrightHover : screen(@lightRedHover,@blendingBaseColor);
1320+
@orangeBrightHover : screen(@lightOrangeHover,@blendingBaseColor);
1321+
@yellowBrightHover : screen(@lightYellowHover,@blendingBaseColor);
1322+
@oliveBrightHover : screen(@lightOliveHover,@blendingBaseColor);
1323+
@greenBrightHover : screen(@lightGreenHover,@blendingBaseColor);
1324+
@tealBrightHover : screen(@lightTealHover,@blendingBaseColor);
1325+
@blueBrightHover : screen(@lightBlueHover,@blendingBaseColor);
1326+
@violetBrightHover : screen(@lightVioletHover,@blendingBaseColor);
1327+
@purpleBrightHover : screen(@lightPurpleHover,@blendingBaseColor);
1328+
@pinkBrightHover : screen(@lightPinkHover,@blendingBaseColor);
1329+
@brownBrightHover : screen(@lightBrownHover,@blendingBaseColor);
1330+
@greyBrightHover : @lightGreyHover;
1331+
@blackBrightHover : @lightBlackHover;

0 commit comments

Comments
 (0)