Skip to content

Commit abd1050

Browse files
committed
Hide MTA navigation for printing
1 parent 3c8f706 commit abd1050

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

packages/starlight-theme-mtasa/overrides/Header.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import type { Props } from '@astrojs/starlight/props';
33
import Default from '@astrojs/starlight/components/Header.astro';
44
---
55

6-
<nav>
6+
<nav class="print:hidden">
77
<a href="https://multitheftauto.com" rel="noopener">Home</a>
88
<a class="keepMobile" href="https://discord.com/invite/mtasa" rel="noopener" target="_blank">Discord</a>
99
<a href="https://community.multitheftauto.com" rel="noopener">Community</a>

packages/starlight-theme-mtasa/theme.css

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,13 @@
1616
}
1717
}
1818

19+
/* Restore the original height for printing. */
20+
@media print {
21+
:root {
22+
--sl-nav-height: var(--sl-nav-height-original);
23+
}
24+
}
25+
1926
/* Add the MTA color strip to the header,
2027
remove the padding so we can utilize the full width of the page,
2128
and include the height of the MTA navigation in the calculation of the header. */

0 commit comments

Comments
 (0)