@vuepress/theme-default 2.0.0-beta.5 → 2.0.0-beta.50

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (142) hide show
  1. package/lib/client/components/AutoLink.vue +114 -0
  2. package/lib/client/components/DropdownTransition.vue +21 -0
  3. package/lib/client/components/Home.vue +15 -0
  4. package/lib/client/components/HomeContent.vue +5 -0
  5. package/lib/client/components/HomeFeatures.vue +23 -0
  6. package/lib/client/components/HomeFooter.vue +17 -0
  7. package/lib/client/components/HomeHero.vue +97 -0
  8. package/lib/client/components/Navbar.vue +75 -0
  9. package/lib/client/components/NavbarBrand.vue +55 -0
  10. package/lib/client/components/NavbarDropdown.vue +126 -0
  11. package/lib/{components/NavbarLinks.vue → client/components/NavbarItems.vue} +41 -52
  12. package/lib/{components → client/components}/Page.vue +9 -15
  13. package/lib/{components → client/components}/PageMeta.vue +51 -66
  14. package/lib/{components → client/components}/PageNav.vue +44 -57
  15. package/lib/client/components/Sidebar.vue +13 -0
  16. package/lib/client/components/SidebarItem.vue +87 -0
  17. package/lib/client/components/SidebarItems.vue +57 -0
  18. package/lib/client/components/ToggleColorModeButton.vue +57 -0
  19. package/lib/client/components/ToggleSidebarButton.vue +24 -0
  20. package/lib/client/components/global/Badge.vue +31 -0
  21. package/lib/{components → client/components}/global/CodeGroup.d.ts +2 -3
  22. package/lib/client/components/global/CodeGroup.js +106 -0
  23. package/lib/client/components/global/CodeGroupItem.vue +31 -0
  24. package/lib/client/components/global/index.d.ts +4 -0
  25. package/lib/client/components/global/index.js +4 -0
  26. package/lib/client/composables/index.d.ts +6 -0
  27. package/lib/client/composables/index.js +6 -0
  28. package/lib/client/composables/useDarkMode.d.ts +12 -0
  29. package/lib/client/composables/useDarkMode.js +57 -0
  30. package/lib/{composables → client/composables}/useNavLink.d.ts +6 -1
  31. package/lib/{composables → client/composables}/useNavLink.js +5 -2
  32. package/lib/{composables → client/composables}/useResolveRouteWithRedirect.d.ts +1 -1
  33. package/lib/{composables → client/composables}/useResolveRouteWithRedirect.js +2 -2
  34. package/lib/{composables → client/composables}/useScrollPromise.d.ts +0 -0
  35. package/lib/{composables → client/composables}/useScrollPromise.js +1 -1
  36. package/lib/{composables → client/composables}/useSidebarItems.d.ts +12 -7
  37. package/lib/client/composables/useSidebarItems.js +118 -0
  38. package/lib/{composables → client/composables}/useThemeData.d.ts +2 -2
  39. package/lib/{composables → client/composables}/useThemeData.js +1 -1
  40. package/lib/client/config.d.ts +3 -0
  41. package/lib/client/config.js +38 -0
  42. package/lib/client/index.d.ts +3 -0
  43. package/lib/client/index.js +3 -0
  44. package/lib/client/layouts/404.vue +27 -0
  45. package/lib/client/layouts/Layout.vue +134 -0
  46. package/lib/{shim.d.ts → client/shim.d.ts} +0 -0
  47. package/lib/{styles/_wrapper.scss → client/styles/_mixins.scss} +7 -2
  48. package/lib/client/styles/_variables.scss +11 -0
  49. package/lib/{styles → client/styles}/arrow.scss +4 -6
  50. package/lib/{styles → client/styles}/badge.scss +9 -11
  51. package/lib/{styles → client/styles}/code-group.scss +9 -2
  52. package/lib/{styles → client/styles}/code.scss +26 -37
  53. package/lib/client/styles/custom-container.scss +88 -0
  54. package/lib/{styles → client/styles}/home.scss +32 -24
  55. package/lib/{styles → client/styles}/index.scss +4 -4
  56. package/lib/{styles → client/styles}/layout.scss +70 -66
  57. package/lib/{styles/dropdown.scss → client/styles/navbar-dropdown.scss} +37 -47
  58. package/lib/{styles → client/styles}/navbar.scss +70 -34
  59. package/lib/client/styles/normalize.scss +177 -0
  60. package/lib/{styles → client/styles}/page.scss +20 -8
  61. package/lib/client/styles/sidebar.scss +134 -0
  62. package/lib/{styles → client/styles}/toc.scss +0 -0
  63. package/lib/client/styles/transitions.scss +22 -0
  64. package/lib/client/styles/vars-dark.scss +46 -0
  65. package/lib/client/styles/vars.scss +133 -0
  66. package/lib/client/utils/index.d.ts +3 -0
  67. package/lib/client/utils/index.js +3 -0
  68. package/lib/client/utils/isActiveSidebarItem.d.ts +3 -0
  69. package/lib/client/utils/isActiveSidebarItem.js +20 -0
  70. package/lib/{utils → client/utils}/resolveEditLink.d.ts +2 -2
  71. package/lib/{utils → client/utils}/resolveEditLink.js +15 -9
  72. package/lib/client/utils/resolveRepoType.d.ts +2 -0
  73. package/lib/{utils → client/utils}/resolveRepoType.js +3 -1
  74. package/lib/node/defaultTheme.d.ts +10 -0
  75. package/lib/node/defaultTheme.js +120 -0
  76. package/lib/node/index.d.ts +5 -5
  77. package/lib/node/index.js +5 -17
  78. package/lib/node/utils/assignDefaultLocaleOptions.d.ts +7 -0
  79. package/lib/node/{assignDefaultLocaleOptions.js → utils/assignDefaultLocaleOptions.js} +13 -13
  80. package/lib/node/utils/index.d.ts +2 -0
  81. package/lib/node/utils/index.js +2 -0
  82. package/lib/node/utils/resolveContainerPluginOptions.d.ts +8 -0
  83. package/lib/node/utils/resolveContainerPluginOptions.js +17 -0
  84. package/lib/shared/index.d.ts +3 -0
  85. package/lib/shared/index.js +3 -0
  86. package/lib/{types → shared}/nav.d.ts +11 -12
  87. package/lib/shared/nav.js +1 -0
  88. package/lib/{types → shared}/options.d.ts +49 -11
  89. package/lib/shared/options.js +1 -0
  90. package/lib/{types → shared}/page.d.ts +14 -6
  91. package/lib/shared/page.js +1 -0
  92. package/package.json +47 -29
  93. package/templates/build.html +33 -0
  94. package/CHANGELOG.md +0 -368
  95. package/lib/clientAppEnhance.d.ts +0 -3
  96. package/lib/clientAppEnhance.js +0 -30
  97. package/lib/clientAppSetup.d.ts +0 -2
  98. package/lib/clientAppSetup.js +0 -11
  99. package/lib/components/DropdownLink.vue +0 -141
  100. package/lib/components/DropdownTransition.vue +0 -34
  101. package/lib/components/Home.vue +0 -133
  102. package/lib/components/NavLink.vue +0 -115
  103. package/lib/components/Navbar.vue +0 -114
  104. package/lib/components/Sidebar.vue +0 -38
  105. package/lib/components/SidebarChild.d.ts +0 -6
  106. package/lib/components/SidebarChild.js +0 -91
  107. package/lib/components/ToggleSidebarButton.vue +0 -27
  108. package/lib/components/global/Badge.vue +0 -37
  109. package/lib/components/global/CodeGroup.js +0 -52
  110. package/lib/components/global/CodeGroupItem.vue +0 -25
  111. package/lib/components/global/OutboundLink.vue +0 -30
  112. package/lib/composables/index.d.ts +0 -5
  113. package/lib/composables/index.js +0 -5
  114. package/lib/composables/useSidebarItems.js +0 -114
  115. package/lib/index.d.ts +0 -6
  116. package/lib/index.js +0 -67
  117. package/lib/layouts/404.vue +0 -38
  118. package/lib/layouts/Layout.vue +0 -152
  119. package/lib/node/assignDefaultLocaleOptions.d.ts +0 -5
  120. package/lib/node/resolveActiveHeaderLinksPluginOptions.d.ts +0 -6
  121. package/lib/node/resolveActiveHeaderLinksPluginOptions.js +0 -16
  122. package/lib/node/resolveContainerPluginOptions.d.ts +0 -26
  123. package/lib/node/resolveContainerPluginOptions.js +0 -79
  124. package/lib/node/resolveGitPluginOptions.d.ts +0 -6
  125. package/lib/node/resolveGitPluginOptions.js +0 -22
  126. package/lib/node/resolveMediumZoomPluginOptions.d.ts +0 -6
  127. package/lib/node/resolveMediumZoomPluginOptions.js +0 -17
  128. package/lib/styles/_normalize.scss +0 -148
  129. package/lib/styles/_variables.scss +0 -34
  130. package/lib/styles/custom-container.scss +0 -78
  131. package/lib/styles/plugins.scss +0 -18
  132. package/lib/styles/sidebar.scss +0 -152
  133. package/lib/styles/sr-only.scss +0 -12
  134. package/lib/styles/transitions.scss +0 -13
  135. package/lib/types/index.d.ts +0 -3
  136. package/lib/types/index.js +0 -15
  137. package/lib/types/nav.js +0 -2
  138. package/lib/types/options.js +0 -2
  139. package/lib/types/page.js +0 -2
  140. package/lib/utils/index.d.ts +0 -2
  141. package/lib/utils/index.js +0 -2
  142. package/lib/utils/resolveRepoType.d.ts +0 -2
@@ -1,10 +1,9 @@
1
+ @import '_mixins';
1
2
  @import '_variables';
2
- @import '_wrapper';
3
-
4
- $mobileSidebarWidth: $sidebarWidth * 0.82;
5
3
 
6
4
  .page {
7
- padding-left: $sidebarWidth;
5
+ padding-top: var(--navbar-height);
6
+ padding-left: var(--sidebar-width);
8
7
  }
9
8
 
10
9
  .navbar {
@@ -13,35 +12,38 @@ $mobileSidebarWidth: $sidebarWidth * 0.82;
13
12
  top: 0;
14
13
  left: 0;
15
14
  right: 0;
16
- height: $navbarHeight;
17
- background-color: #fff;
15
+ height: var(--navbar-height);
18
16
  box-sizing: border-box;
19
- border-bottom: 1px solid $borderColor;
17
+ border-bottom: 1px solid var(--c-border);
18
+ background-color: var(--c-bg-navbar);
19
+ transition: background-color var(--t-color), border-color var(--t-color);
20
20
  }
21
21
 
22
22
  .sidebar {
23
23
  font-size: 16px;
24
- background-color: #fff;
25
- width: $sidebarWidth;
24
+ width: var(--sidebar-width);
26
25
  position: fixed;
27
26
  z-index: 10;
28
27
  margin: 0;
29
- top: $navbarHeight;
28
+ top: var(--navbar-height);
30
29
  left: 0;
31
30
  bottom: 0;
32
31
  box-sizing: border-box;
33
- border-right: 1px solid $borderColor;
32
+ border-right: 1px solid var(--c-border);
34
33
  overflow-y: auto;
35
34
  scrollbar-width: thin;
36
- scrollbar-color: $accentColor $borderColor;
35
+ scrollbar-color: var(--c-brand) var(--c-border);
36
+ background-color: var(--c-bg-sidebar);
37
+ transition: transform var(--t-transform), background-color var(--t-color),
38
+ border-color var(--t-color);
37
39
  &::-webkit-scrollbar {
38
40
  width: 7px;
39
41
  }
40
42
  &::-webkit-scrollbar-track {
41
- background-color: $borderColor;
43
+ background-color: var(--c-border);
42
44
  }
43
45
  &::-webkit-scrollbar-thumb {
44
- background-color: $accentColor;
46
+ background-color: var(--c-brand);
45
47
  }
46
48
  }
47
49
 
@@ -60,16 +62,43 @@ $mobileSidebarWidth: $sidebarWidth * 0.82;
60
62
  .sidebar-mask {
61
63
  display: block;
62
64
  }
65
+
66
+ .navbar > .toggle-sidebar-button .icon {
67
+ span {
68
+ &:nth-child(1) {
69
+ transform: rotate(45deg) translate3d(5.5px, 5.5px, 0);
70
+ }
71
+
72
+ &:nth-child(2) {
73
+ transform: scale3d(0, 1, 1);
74
+ }
75
+
76
+ &:nth-child(3) {
77
+ transform: rotate(-45deg) translate3d(6px, -6px, 0);
78
+ }
79
+
80
+ &:nth-child(1),
81
+ &:nth-child(3) {
82
+ transform-origin: center;
83
+ }
84
+ }
85
+ }
63
86
  }
64
87
 
65
88
  &.no-navbar {
66
- #{$contentClass}:not(.custom) > h1,
67
- h2,
68
- h3,
69
- h4,
70
- h5,
71
- h6 {
72
- margin-top: 1.5rem;
89
+ .theme-default-content {
90
+ h1,
91
+ h2,
92
+ h3,
93
+ h4,
94
+ h5,
95
+ h6 {
96
+ margin-top: 1.5rem;
97
+ padding-top: 0;
98
+ }
99
+ }
100
+
101
+ .page {
73
102
  padding-top: 0;
74
103
  }
75
104
 
@@ -91,19 +120,26 @@ $mobileSidebarWidth: $sidebarWidth * 0.82;
91
120
  }
92
121
  }
93
122
 
94
- h1,
95
- h2,
96
- h3,
97
- h4,
98
- h5,
99
- h6 {
100
- #{$contentClass}:not(.custom) > & {
101
- margin-top: 0.5rem - $navbarHeight;
102
- padding-top: ($navbarHeight + 1rem);
123
+ .theme-default-content {
124
+ a:hover {
125
+ text-decoration: underline;
126
+ }
127
+
128
+ img {
129
+ max-width: 100%;
130
+ }
131
+
132
+ h1,
133
+ h2,
134
+ h3,
135
+ h4,
136
+ h5,
137
+ h6 {
138
+ margin-top: calc(0.5rem - var(--navbar-height));
139
+ padding-top: calc(1rem + var(--navbar-height));
103
140
  margin-bottom: 0;
104
141
 
105
142
  &:first-child {
106
- margin-top: -1.5rem;
107
143
  margin-bottom: 1rem;
108
144
 
109
145
  + p,
@@ -115,46 +151,15 @@ h6 {
115
151
  }
116
152
  }
117
153
 
118
- #{$contentClass}:not(.custom) {
119
- @extend %wrapper;
120
-
121
- > *:first-child {
122
- margin-top: $navbarHeight;
123
- }
124
-
125
- a:hover {
126
- text-decoration: underline;
127
- }
128
-
129
- p.demo {
130
- padding: 1rem 1.5rem;
131
- border: 1px solid #ddd;
132
- border-radius: 4px;
133
- }
134
-
135
- img {
136
- max-width: 100%;
137
- }
138
- }
139
-
140
- #{$contentClass}.custom {
141
- padding: 0;
142
- margin: 0;
143
-
144
- img {
145
- max-width: 100%;
146
- }
147
- }
148
-
149
154
  // narrow desktop / iPad
150
155
  @media (max-width: $MQNarrow) {
151
156
  .sidebar {
152
157
  font-size: 15px;
153
- width: $mobileSidebarWidth;
158
+ width: var(--sidebar-width-mobile);
154
159
  }
155
160
 
156
161
  .page {
157
- padding-left: $mobileSidebarWidth;
162
+ padding-left: var(--sidebar-width-mobile);
158
163
  }
159
164
  }
160
165
 
@@ -162,9 +167,8 @@ h6 {
162
167
  @media (max-width: $MQMobile) {
163
168
  .sidebar {
164
169
  top: 0;
165
- padding-top: $navbarHeight;
170
+ padding-top: var(--navbar-height);
166
171
  transform: translateX(-100%);
167
- transition: transform 0.2s ease;
168
172
  }
169
173
 
170
174
  .page {
@@ -1,9 +1,10 @@
1
+ @import '_mixins';
1
2
  @import '_variables';
2
3
 
3
- .dropdown-wrapper {
4
+ .navbar-dropdown-wrapper {
4
5
  cursor: pointer;
5
6
 
6
- .dropdown-title {
7
+ .navbar-dropdown-title {
7
8
  display: block;
8
9
  font-size: 0.9rem;
9
10
  font-family: inherit;
@@ -13,7 +14,7 @@
13
14
  background: transparent;
14
15
  border: none;
15
16
  font-weight: 500;
16
- color: $textColor;
17
+ color: var(--c-text);
17
18
 
18
19
  &:hover {
19
20
  border-color: transparent;
@@ -26,26 +27,24 @@
26
27
  }
27
28
  }
28
29
 
29
- .mobile-dropdown-title {
30
- @extend .dropdown-title;
30
+ .navbar-dropdown-title-mobile {
31
+ @extend .navbar-dropdown-title;
31
32
  display: none;
32
33
  font-weight: 600;
33
-
34
- font-size inherit {
35
- &:hover {
36
- color: $accentColor;
37
- }
34
+ font-size: inherit;
35
+ &:hover {
36
+ color: var(--c-text-accent);
38
37
  }
39
38
  }
40
39
 
41
- .nav-dropdown {
42
- .dropdown-item {
40
+ .navbar-dropdown {
41
+ .navbar-dropdown-item {
43
42
  color: inherit;
44
43
  line-height: 1.7rem;
45
44
 
46
- .dropdown-subtitle {
45
+ .navbar-dropdown-subtitle {
47
46
  margin: 0.45rem 0 0;
48
- border-top: 1px solid #eee;
47
+ border-top: 1px solid var(--c-border);
49
48
  padding: 1rem 0 0.45rem 0;
50
49
  font-size: 0.9rem;
51
50
 
@@ -63,11 +62,11 @@
63
62
  }
64
63
  }
65
64
 
66
- .dropdown-subitem-wrapper {
65
+ .navbar-dropdown-subitem-wrapper {
67
66
  padding: 0;
68
67
  list-style: none;
69
68
 
70
- .dropdown-subitem {
69
+ .navbar-dropdown-subitem {
71
70
  font-size: 0.9em;
72
71
  }
73
72
  }
@@ -82,17 +81,17 @@
82
81
  padding: 0 1.5rem 0 1.25rem;
83
82
 
84
83
  &:hover {
85
- color: $accentColor;
84
+ color: var(--c-text-accent);
86
85
  }
87
86
 
88
87
  &.router-link-active {
89
- color: $accentColor;
88
+ color: var(--c-text-accent);
90
89
 
91
90
  &::after {
92
91
  content: '';
93
92
  width: 0;
94
93
  height: 0;
95
- border-left: 5px solid $accentColor;
94
+ border-left: 5px solid var(--c-text-accent);
96
95
  border-top: 3px solid transparent;
97
96
  border-bottom: 3px solid transparent;
98
97
  position: absolute;
@@ -102,7 +101,7 @@
102
101
  }
103
102
  }
104
103
 
105
- &:first-child .dropdown-subtitle {
104
+ &:first-child .navbar-dropdown-subtitle {
106
105
  margin-top: 0;
107
106
  padding-top: 0;
108
107
  border-top: 0;
@@ -112,38 +111,37 @@
112
111
  }
113
112
 
114
113
  @media (max-width: $MQMobile) {
115
- .dropdown-wrapper {
116
- &.open .dropdown-title {
114
+ .navbar-dropdown-wrapper {
115
+ &.open .navbar-dropdown-title {
117
116
  margin-bottom: 0.5rem;
118
117
  }
119
118
 
120
- .dropdown-title {
119
+ .navbar-dropdown-title {
121
120
  display: none;
122
121
  }
123
122
 
124
- .mobile-dropdown-title {
123
+ .navbar-dropdown-title-mobile {
125
124
  display: block;
126
125
  }
127
126
 
128
- .nav-dropdown {
129
- transition: height 0.1s ease-out;
130
- overflow: hidden;
127
+ .navbar-dropdown {
128
+ @include dropdown_wrapper;
131
129
 
132
- .dropdown-item {
133
- .dropdown-subtitle {
130
+ .navbar-dropdown-item {
131
+ .navbar-dropdown-subtitle {
134
132
  border-top: 0;
135
133
  margin-top: 0;
136
134
  padding-top: 0;
137
135
  padding-bottom: 0;
138
136
  }
139
137
 
140
- .dropdown-subtitle,
138
+ .navbar-dropdown-subtitle,
141
139
  & > a {
142
140
  font-size: 15px;
143
141
  line-height: 2rem;
144
142
  }
145
143
 
146
- .dropdown-subitem {
144
+ .navbar-dropdown-subitem {
147
145
  font-size: 14px;
148
146
  padding-left: 1rem;
149
147
  }
@@ -152,12 +150,12 @@
152
150
  }
153
151
  }
154
152
 
155
- @media (min-width: $MQMobile) {
156
- .dropdown-wrapper {
153
+ @media (min-width: ($MQMobile + 1)) {
154
+ .navbar-dropdown-wrapper {
157
155
  height: 1.8rem;
158
156
 
159
- &:hover .nav-dropdown,
160
- &.open .nav-dropdown {
157
+ &:hover .navbar-dropdown,
158
+ &.open .navbar-dropdown {
161
159
  // override the inline style.
162
160
  display: block !important;
163
161
  }
@@ -166,7 +164,7 @@
166
164
  display: none;
167
165
  }
168
166
 
169
- .nav-dropdown {
167
+ .navbar-dropdown {
170
168
  display: none;
171
169
  // Avoid height shaked by clicking
172
170
  height: auto !important;
@@ -176,10 +174,10 @@
176
174
  position: absolute;
177
175
  top: 100%;
178
176
  right: 0;
179
- background-color: #fff;
177
+ background-color: var(--c-bg-navbar);
180
178
  padding: 0.6rem 0;
181
- border: 1px solid #ddd;
182
- border-bottom-color: #ccc;
179
+ border: 1px solid var(--c-border);
180
+ border-bottom-color: var(--c-border-dark);
183
181
  text-align: left;
184
182
  border-radius: 0.25rem;
185
183
  white-space: nowrap;
@@ -187,11 +185,3 @@
187
185
  }
188
186
  }
189
187
  }
190
-
191
- /**
192
- * transition
193
- */
194
- .dropdown-enter-from,
195
- .dropdown-leave-to {
196
- height: 0 !important;
197
- }
@@ -1,38 +1,36 @@
1
- @use 'sass:color';
2
-
3
1
  @import '_variables';
4
2
 
5
- $navbar-vertical-padding: 0.7rem;
6
- $navbar-horizontal-padding: 1.5rem;
7
-
8
3
  .navbar {
9
- padding: $navbar-vertical-padding $navbar-horizontal-padding;
10
- line-height: $navbarHeight - 1.4rem;
4
+ --navbar-line-height: calc(
5
+ var(--navbar-height) - 2 * var(--navbar-padding-v)
6
+ );
7
+
8
+ padding: var(--navbar-padding-v) var(--navbar-padding-h);
9
+ line-height: var(--navbar-line-height);
11
10
 
12
11
  .logo {
13
- height: $navbarHeight - 1.4rem;
14
- min-width: $navbarHeight - 1.4rem;
15
- margin-right: 0.8rem;
12
+ height: var(--navbar-line-height);
13
+ margin-right: var(--navbar-padding-v);
16
14
  vertical-align: top;
17
15
  }
18
16
 
19
17
  .site-name {
20
18
  font-size: 1.3rem;
21
19
  font-weight: 600;
22
- color: $textColor;
20
+ color: var(--c-text);
23
21
  position: relative;
24
22
  }
25
23
 
26
- .navbar-links-wrapper {
27
- padding-left: 1.5rem;
24
+ .navbar-items-wrapper {
25
+ display: flex;
26
+ position: absolute;
28
27
  box-sizing: border-box;
29
- background-color: white;
28
+ top: var(--navbar-padding-v);
29
+ right: var(--navbar-padding-h);
30
+ height: var(--navbar-line-height);
31
+ padding-left: var(--navbar-padding-h);
30
32
  white-space: nowrap;
31
33
  font-size: 0.9rem;
32
- position: absolute;
33
- right: $navbar-horizontal-padding;
34
- top: $navbar-vertical-padding;
35
- display: flex;
36
34
 
37
35
  .search-box {
38
36
  flex: 0 0 auto;
@@ -49,10 +47,6 @@ $navbar-horizontal-padding: 1.5rem;
49
47
  display: none;
50
48
  }
51
49
 
52
- .navbar-links-wrapper {
53
- padding-left: 1.5rem;
54
- }
55
-
56
50
  .site-name {
57
51
  width: calc(100vw - 9.4rem);
58
52
  overflow: hidden;
@@ -63,9 +57,9 @@ $navbar-horizontal-padding: 1.5rem;
63
57
  }
64
58
 
65
59
  /**
66
- * navbar-links
60
+ * navbar-items
67
61
  */
68
- .navbar-links {
62
+ .navbar-items {
69
63
  display: inline-block;
70
64
 
71
65
  a {
@@ -75,15 +69,15 @@ $navbar-horizontal-padding: 1.5rem;
75
69
 
76
70
  &:hover,
77
71
  &.router-link-active {
78
- color: $accentColor;
72
+ color: var(--c-text-accent);
79
73
  }
80
74
  }
81
75
 
82
- .navbar-links-item {
76
+ .navbar-item {
83
77
  position: relative;
84
78
  display: inline-block;
85
79
  margin-left: 1.5rem;
86
- line-height: 2rem;
80
+ line-height: var(--navbar-line-height);
87
81
 
88
82
  &:first-child {
89
83
  margin-left: 0;
@@ -92,26 +86,26 @@ $navbar-horizontal-padding: 1.5rem;
92
86
  }
93
87
 
94
88
  @media (max-width: $MQMobile) {
95
- .navbar-links {
96
- .navbar-links-item {
89
+ .navbar-items {
90
+ .navbar-item {
97
91
  margin-left: 0;
98
92
  }
99
93
  }
100
94
  }
101
95
 
102
96
  @media (min-width: $MQMobile) {
103
- .navbar-links a {
97
+ .navbar-items a {
104
98
  &:hover,
105
99
  &.router-link-active {
106
- color: $textColor;
100
+ color: var(--c-text);
107
101
  }
108
102
  }
109
103
 
110
- .navbar-links-item > a:not(.external) {
104
+ .navbar-item > a {
111
105
  &:hover,
112
106
  &.router-link-active {
113
107
  margin-bottom: -2px;
114
- border-bottom: 2px solid color.scale($accentColor, $lightness: 8%);
108
+ border-bottom: 2px solid var(--c-text-accent);
115
109
  }
116
110
  }
117
111
  }
@@ -129,9 +123,26 @@ $navbar-horizontal-padding: 1.5rem;
129
123
  }
130
124
 
131
125
  .toggle-sidebar-button .icon {
132
- display: block;
126
+ display: flex;
127
+ flex-direction: column;
128
+ justify-content: center;
129
+ align-items: center;
133
130
  width: 1.25rem;
134
131
  height: 1.25rem;
132
+ cursor: inherit;
133
+
134
+ span {
135
+ display: inline-block;
136
+ width: 100%;
137
+ height: 2px;
138
+ border-radius: 2px;
139
+ background-color: var(--c-text);
140
+ transition: transform var(--t-transform);
141
+
142
+ &:nth-child(2) {
143
+ margin: 6px 0;
144
+ }
145
+ }
135
146
  }
136
147
 
137
148
  @media screen and (max-width: $MQMobile) {
@@ -139,3 +150,28 @@ $navbar-horizontal-padding: 1.5rem;
139
150
  display: block;
140
151
  }
141
152
  }
153
+
154
+ /**
155
+ * toggle color mode button
156
+ */
157
+ .toggle-color-mode-button {
158
+ display: flex;
159
+ margin: auto;
160
+ margin-left: 1rem;
161
+ border: 0;
162
+ background: none;
163
+ color: var(--c-text);
164
+ opacity: 0.8;
165
+ cursor: pointer;
166
+ &:hover {
167
+ opacity: 1;
168
+ }
169
+ .icon {
170
+ width: 1.25rem;
171
+ height: 1.25rem;
172
+ }
173
+ }
174
+
175
+ .DocSearch {
176
+ transition: background-color var(--t-color);
177
+ }