Skip to content

Commit

Permalink
print css for pdf generation
Browse files Browse the repository at this point in the history
  • Loading branch information
thomas.ekstrand committed Feb 25, 2024
1 parent bfda6f9 commit 68c5e1e
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pdf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git config --global user.name "GitHub Actions Bot"
git clone --single-branch -b docs https://github.com/meshtastic/artifacts.git --depth=1
DATE_TIME=$(date +'%Y-%m-%d_%H-%M-%S')
DATE_TIME=$(date +'%Y-%m-%d_%H-%M')
mv ./pdf/Meshtastic-Documentation.pdf ./artifacts/Meshtastic-Documentation-${DATE_TIME}_${{ github.sha }}.pdf
cd artifacts
git add .
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"swizzle": "docusaurus swizzle",
"serve": "docusaurus serve",
"clear": "docusaurus clear",
"pdf": "npm docusaurus-prince-pdf -u https://meshtastic.org/docs/about/ --dest ./static/documents/pdf --output ./static/documents/pdf/Meshtastic-Documentation.pdf"
"pdf": "npx docusaurus-prince-pdf -u http://localhost:3000/docs/hardware/devices/rak/base-board/ --dest ./static/documents/pdf --output ./static/documents/pdf/Meshtastic-Documentation.pdf"
},
"dependencies": {
"@algolia/client-search": "^4.22.1",
Expand Down
12 changes: 11 additions & 1 deletion src/css/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -228,4 +228,14 @@ th,
td {
padding-left: 10px !important;
padding-right: 10px !important;
}
}

/* Need all tab content to show for PDF generation */
@media print {
ul.tabs {
display: none;
}
.tabs-container div > div {
display: block;
}
}

0 comments on commit 68c5e1e

Please sign in to comment.