mirror of
https://github.com/next-theme/hexo-theme-next.git
synced 2026-01-20 19:02:33 +00:00
Refactor .menu-item style
This commit is contained in:
parent
2195b01d8c
commit
6bf97f6e49
@ -36,18 +36,8 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.badge {
|
.badge {
|
||||||
display: inline-block;
|
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
line-height: 1;
|
line-height: 1;
|
||||||
margin-left: .35em;
|
|
||||||
margin-top: .35em;
|
|
||||||
text-align: center;
|
|
||||||
white-space: nowrap;
|
|
||||||
|
|
||||||
+mobile() {
|
|
||||||
float: right;
|
|
||||||
margin-left: 0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -272,3 +272,12 @@ gemini-block-not-first() {
|
|||||||
margin-top: $content-mobile-padding;
|
margin-top: $content-mobile-padding;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
menu-item-row() {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
|
||||||
|
.badge {
|
||||||
|
margin-left: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@ -31,6 +31,7 @@
|
|||||||
|
|
||||||
+mobile() {
|
+mobile() {
|
||||||
text-align: left;
|
text-align: left;
|
||||||
|
menu-item-row();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -38,6 +39,7 @@
|
|||||||
background: white;
|
background: white;
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
color: $black-light;
|
color: $black-light;
|
||||||
|
margin-left: .35em;
|
||||||
padding: 1px 4px;
|
padding: 1px 4px;
|
||||||
text-shadow: 1px 1px 0 rgba(0, 0, 0, .1);
|
text-shadow: 1px 1px 0 rgba(0, 0, 0, .1);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -27,6 +27,7 @@
|
|||||||
|
|
||||||
+mobile() {
|
+mobile() {
|
||||||
padding: 5px 10px;
|
padding: 5px 10px;
|
||||||
|
menu-item-row();
|
||||||
}
|
}
|
||||||
|
|
||||||
&:hover, &.menu-item-active {
|
&:hover, &.menu-item-active {
|
||||||
@ -51,6 +52,7 @@
|
|||||||
.badge {
|
.badge {
|
||||||
background: $gainsboro;
|
background: $gainsboro;
|
||||||
color: $black-light;
|
color: $black-light;
|
||||||
|
margin-left: .35em;
|
||||||
padding: 1px 4px;
|
padding: 1px 4px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -10,9 +10,8 @@
|
|||||||
|
|
||||||
a {
|
a {
|
||||||
padding: 5px 20px;
|
padding: 5px 20px;
|
||||||
position: relative;
|
|
||||||
text-align: left;
|
|
||||||
transition-property: background-color;
|
transition-property: background-color;
|
||||||
|
menu-item-row();
|
||||||
}
|
}
|
||||||
|
|
||||||
+tablet-mobile() {
|
+tablet-mobile() {
|
||||||
@ -25,7 +24,6 @@
|
|||||||
background: $grey-light;
|
background: $grey-light;
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
color: var(--content-bg-color);
|
color: var(--content-bg-color);
|
||||||
float: right;
|
|
||||||
padding: 2px 5px;
|
padding: 2px 5px;
|
||||||
text-shadow: 1px 1px 0 rgba(0, 0, 0, .1);
|
text-shadow: 1px 1px 0 rgba(0, 0, 0, .1);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user