Skip to content

Commit 9e83d00

Browse files
committed
Styling fix for user print
1 parent 4d212f9 commit 9e83d00

2 files changed

Lines changed: 21 additions & 4 deletions

File tree

‎src/layouts/MarkdownLayout.astro‎

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -201,9 +201,13 @@ const link = `https://www.webstackbuilders.com${path}`
201201
{/** SLOT: after-content, includes social shares and web mentions */}
202202
<slot name="after-content" />
203203

204-
<div class="hidden print:flex print:items-center print:justify-center print:gap-8 print:mx-24 print:mt-8 print:break-inside-avoid print:break-before-avoid">
205-
<Copyright publishDate={publishDate ?? new Date()} variant="print" link={link} />
206-
<QrCode data={link} />
204+
<div class="hidden mx-24 mt-8 print:grid print:grid-cols-2 print:gap-4 print:items-center print:break-inside-avoid">
205+
<span class="print:break-inside-avoid">
206+
<Copyright publishDate={publishDate ?? new Date()} variant="print" link={link} />
207+
</span>
208+
<span class="print:break-inside-avoid">
209+
<QrCode data={link} />
210+
</span>
207211
</div>
208212
</div>
209213
</article>

‎src/styles/print.css‎

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,20 @@
88
-------------------------------------------------------------------------- */
99

1010
@page {
11-
margin: 2cm 2cm 3.5cm;
11+
margin: 2cm;
12+
13+
@bottom-left {
14+
content: "Webstack Builders, Inc.";
15+
font-size: 9pt;
16+
color: #000;
17+
}
18+
19+
@bottom-right {
20+
content: "Page " counter(page) " of " counter(pages);
21+
font-family: Arial, sans-serif;
22+
font-size: 10pt;
23+
color: #000;
24+
}
1225
}
1326

1427
/* --------------------------------------------------------------------------

0 commit comments

Comments
 (0)