Skip to content

Commit 4864d1b

Browse files
committed
fix(themes): update navbar style
1 parent 324301a commit 4864d1b

File tree

1 file changed

+19
-21
lines changed

1 file changed

+19
-21
lines changed

src/themes/basic/_layout.css

+19-21
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,6 @@ nav {
8787
}
8888

8989
a {
90-
margin: 0 1em;
91-
padding: 5px 0;
9290
font-size: 16px;
9391
text-decoration: none;
9492
color: inherit;
@@ -108,34 +106,37 @@ nav {
108106
li {
109107
position: relative;
110108
display: inline-block;
109+
margin: 0 1em;
110+
padding: 5px 0;
111111

112112
ul {
113-
border-radius: 2px;
114-
background-color: rgba($color-bg, .6);
115-
border-width: 1px;
116-
border-style: solid;
117-
border-color: var(--theme-color, $color-primary);
118-
opacity: 0;
119-
overflow: hidden;
120-
padding: 0;
113+
display: none;
114+
box-sizing: border-box;
115+
max-height: calc(100vh - 61px);
116+
overflow-y: scroll;
121117
position: absolute;
122-
right: 1em;
123-
top: 26px;
124-
transform-origin: 100% 0%;
125-
transform: scale(1, 0);
126-
transition: opacity .4s ease-out, transform .2s ease;
127-
transition-delay: .3s;
118+
top: 100%;
119+
right: -15px;
120+
background-color: #fff;
121+
padding: 10px 0;
122+
border: 1px solid #ddd;
123+
border-bottom-color: #ccc;
124+
text-align: left;
125+
border-radius: 4px;
126+
white-space: nowrap;
128127

129128
li {
130129
display: block;
131130
font-size: 14px;
132131
margin: 0;
133-
padding: 4px 10px;
132+
margin: 8px 14px;
134133
white-space: nowrap;
134+
line-height: 1em;
135135
}
136136

137137
a {
138138
display: block;
139+
font-size: inherit;
139140
margin: 0;
140141
padding: 0;
141142

@@ -146,10 +147,7 @@ nav {
146147
}
147148

148149
&:hover ul {
149-
opacity: 1;
150-
transform: scale(1, 1);
151-
transition: opacity .4s ease, transform .2s ease-out;
152-
transition-delay: 0;
150+
display: block;
153151
}
154152
}
155153
}

0 commit comments

Comments
 (0)