Skip to content

Commit 5ff7e7e

Browse files
authored
Add blog link to site switcher (#6961)
This makes it more consistent with other Dart-related site properties. It is still linked to from the top navigation as well. **Screenshot with the added button:** <img height="240" alt="Screenshot of the added link button to the blog." src="https://github.com/user-attachments/assets/32a23cf9-e2a2-48d5-b9bf-bd79a9428f1d" />
1 parent cee4edf commit 5ff7e7e

File tree

4 files changed

+14
-4
lines changed

4 files changed

+14
-4
lines changed

site/lib/_sass/components/_dropdown.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
z-index: var(--site-z-dropdown);
1414

1515
.dropdown-divider {
16-
background-color: var(--site-outline-variant);
16+
background-color: var(--site-outline);
1717
border-radius: 0.5rem;
1818
height: 0.125rem;
1919
margin: 0.25rem;

site/lib/_sass/components/_site-switcher.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@
4444
}
4545

4646
&.subtype {
47-
padding: 0 0.3rem;
48-
font-size: 1.25rem;
47+
padding: 0.05rem 0.3rem;
48+
font-size: 1.2rem;
4949
font-weight: 500;
5050
line-height: 1.3;
5151
border-radius: 0.25rem;

site/lib/src/components/layout/site_switcher.dart

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,16 @@ final class SiteSwitcher extends StatelessComponent {
3636
subtype: 'API',
3737
href: 'https://api.dart.dev',
3838
),
39+
_SiteWordMarkListEntry(
40+
name: 'Dart',
41+
subtype: 'Blog',
42+
href: 'https://blog.dart.dev',
43+
),
44+
Component.element(
45+
tag: 'li',
46+
classes: 'dropdown-divider',
47+
attributes: {'aria-hidden': 'true', 'role': 'separator'},
48+
),
3949
_SiteWordMarkListEntry(
4050
name: 'DartPad',
4151
href: 'https://dartpad.dev',

site/lib/src/style_hash.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
// dart format off
33

44
/// The generated hash of the `main.css` file.
5-
const generatedStylesHash = 'EcoGkjHB12Fs';
5+
const generatedStylesHash = 'zGgBgeW5Ot3f';

0 commit comments

Comments
 (0)