Skip to content

Commit efb3c46

Browse files
committed
Avoid color sparkles when switching modes.
- the search bar (desktop view) - the site title.
1 parent b0017a6 commit efb3c46

4 files changed

Lines changed: 10 additions & 16 deletions

File tree

assets/css/_addon/main.scss

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ $sidebar-display: "sidebar-display";
8080
background: rgb(42, 30, 107);
8181
background: var(--sidebar-bg);
8282
a {
83-
@include sidebar-icon;
83+
@include sidebar-links;
8484
}
8585
.sidebar-bottom {
8686
.icon-border+a { // the icon behide mode-toggle
@@ -168,7 +168,7 @@ $sidebar-display: "sidebar-display";
168168

169169
#mode-toggle-wrapper {
170170
i {
171-
@include sidebar-icon;
171+
@include sidebar-links;
172172
margin-right: 0;
173173
font-size: 1.05rem;
174174
text-align: center;
@@ -226,11 +226,10 @@ $sidebar-display: "sidebar-display";
226226
img {
227227
width: 100%;
228228
height: 100%;
229-
background-size: cover;
230-
background-repeat: no-repeat;
231-
-webkit-transition: all .5s !important;
232-
-moz-transition: all .5s !important;
233-
transition: all .5s !important;
229+
-webkit-transition: transform .5s;
230+
-moz-transition: transform .5s;
231+
transition: transform .5s;
232+
234233
&:hover {
235234
-ms-transform: scale(1.2);
236235
-moz-transform: scale(1.2);
@@ -243,7 +242,7 @@ $sidebar-display: "sidebar-display";
243242
#site-title {
244243
text-align: center;
245244
a {
246-
color: var(--site-title-color);
245+
// color: var(--site-title-color);
247246
font-weight: 900;
248247
font-size: 1.5rem;
249248
letter-spacing: .5px;
@@ -323,7 +322,6 @@ $sidebar-display: "sidebar-display";
323322
border: 1px solid var(--search-wrapper-bg);
324323
background: var(--search-wrapper-bg);
325324
padding: 0 .5rem;
326-
transition: background-color .15s ease-in-out,border-color .15s ease-in-out;
327325
i {
328326
z-index: 2;
329327
font-size: .9rem;
@@ -921,6 +919,7 @@ table {
921919
box-shadow: none;
922920
border-color: var(--input-focus-border-color) !important;
923921
background: center !important;
922+
transition: background-color .15s ease-in-out,border-color .15s ease-in-out;
924923
}
925924

926925
/*--- Responsive Design ---*/

assets/css/_addon/module.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@
6262
text-decoration: none;
6363
}
6464

65-
@mixin sidebar-icon {
66-
color: rgba(255, 255, 255, 0.5);
65+
@mixin sidebar-links($color: rgba(255, 255, 255, 0.5)) {
66+
color: $color;
6767
transition: color 0.35s ease-in-out;
6868
user-select: none;
6969
margin: 0 .25rem;

assets/css/_colors/dark-typography.scss

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@
3737
--label-color: rgb(108, 117, 125);
3838

3939
/* Sidebar */
40-
--site-title-color: rgba(255, 255, 255, 0.5);
4140
--nav-cursor-color: rgb(183, 182, 182);
4241
--sidebar-bg: radial-gradient(circle, #242424 0%, #1d1f27 100%);
4342

assets/css/_colors/light-typography.scss

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,6 @@
4444

4545
/* Sidebar */
4646

47-
--site-title-color: #b6b6b6;
48-
4947
--sidebar-bg: radial-gradient(
5048
circle, rgba(42, 30, 107, 1) 0%, rgba(35, 37, 46, 1) 100%);
5149

@@ -57,8 +55,6 @@
5755

5856
--topbar-text-color: rgb(78, 78, 78);
5957

60-
--search-wrapper-bg: #fff;
61-
6258
--search-wrapper-bg: #f5f5f5;
6359

6460
--search-tag-bg: #f8f9fa;

0 commit comments

Comments
 (0)