You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Add a QR code at the bottom of printed pages so it's easier for someone to navigate to from a printed page. npm install qr-code-styling is added as a package.
47
-
48
-
- Need a layout alternative to Markup that formats for print. It needs to handle TOC differently as a full-width page. Need a fixed header format that adds article title, subtitle, and date.
49
-
50
-
- Need to make sure that on print, when we have a tabbed code block with multiple languages, only the first language is printed and the other language tabs are hidden. The styling should be different for print for the code block. Maybe move other language code tabs to an appendix and add a link to them.
14
+
2. Need to make sure that on print, when we have a tabbed code block with multiple languages, only the first language is printed and the other language tabs are hidden. The styling should be different for print for the code block. Maybe move other language code tabs to an appendix and add a link to them.
51
15
52
16
[This article](https://excessivelyadequate.com/posts/print.html) shows how to control the following properties in Chrome's Print Properties dialog box from CSS: Layout, Paper size, Margins, Headers and footers, and Background graphics. Headers and footers is the checkbox that by default is enabled and adds information on printed pages. It also shows how to use Chrome from the terminal in headless mode to output a PDF file from an HTML page.
53
17
54
-
For printed pages, your header should shift from a navigation tool to a document identifier. Since users cannot click links or icons on paper, these elements are "cruft" that waste space and ink.
18
+
3. For printed pages, your header should shift from a navigation tool to a document identifier. Since users cannot click links or icons on paper, these elements are "cruft" that waste space and ink.
19
+
20
+
2. Need a layout alternative to Markup that formats for print. It should hide Table Of Contents. Need a fixed header format that adds article title, subtitle, and date.
55
21
56
-
1. Recommended Print Header Format
22
+
__Recommended Print Header Format__
57
23
58
24
A professional print header typically includes only these three elements:
59
25
60
26
- Brand Identity: A high-contrast version of your logo or the site name in plain text for brand recognition.
61
27
- Document Title: The main title of the page (usually the <h1>), ensuring the reader knows exactly what the document is.
62
28
- Source URL: A small, plain-text URL so the reader can find the live version later.
63
29
64
-
2. Elements to Remove
30
+
__Elements to Remove__
65
31
66
32
Hide any interactive or screen-specific components using display: none; in your @media print block:
67
33
@@ -70,7 +36,7 @@ Hide any interactive or screen-specific components using display: none; in your
70
36
- Breadcrumbs: While useful on-screen for site hierarchy, they often look like cluttered, disconnected text on paper. Most designers remove them to keep the focus on the primary content.
71
37
- Social Media & CTA Buttons: "Sign In" or "Follow Us" buttons are irrelevant in print.
72
38
73
-
3. Expand External Links For Print:
39
+
__Expand External Links For Print__
74
40
75
41
We can't (yet) directly interface with a printed page to explore links, so link URLs should be visible on the printed version of the Web page. To keep the page relatively clean, I prefer to expand only outbound links in articles, and suppress internal ones. If you've used relative URLs on your website for local links, you can easily do this through an attribute selector and `:after` pseudo classes, thus preventing internal links and links around images from being printed:
76
42
@@ -117,6 +83,41 @@ Requirements: You must provide sufficient margins (e.g.,` margin: { top: '50px',
117
83
118
84
Styling: You must use inline CSS within your `headerTemplate` or `footerTemplate` strings, as they cannot access your external stylesheet.
119
85
86
+
87
+
Maybe something like this to check if we're on the playwright PDF generation run and set the light theme:
- Add people who sign up for newsletter, download, or fill out contact form to Hubspot tracking. Need to configure it to remove them if they do the GDPR remove me. Also remove them from the newsletter.
141
142
142
-
## Downloads / Gated Content
143
-
144
143
- We need a gating system, where the user gets a token to be able to download a PDF and the token is checked before downloading. If a reader has already given their email address - newsletter signup, contact form, download registration, then the download CTA on short form articles should show the PDF download button instead of trying to collect email addresses again.
145
144
146
145
- We had this copyright statement for articles, it should be in the front matter of PDFs:
0 commit comments