Skip to content

Commit

Permalink
LOYALIST-72 Add base print stylesheet, custom print rules
Browse files Browse the repository at this point in the history
  • Loading branch information
jtmcd75 committed Oct 30, 2024
1 parent b17a416 commit 2041def
Show file tree
Hide file tree
Showing 2 changed files with 98 additions and 0 deletions.
97 changes: 97 additions & 0 deletions custom/themes/the_loyalist_collection/src/scss/print.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
/* Borrow: https://github.com/coliff/bootstrap-print-css */
@media print {
*,
*::before,
*::after {
text-shadow: none !important;
box-shadow: none !important;
}
a:not(.btn) {
text-decoration: underline;
}
abbr[title]::after {
content: " (" attr(title) ")";
}
pre {
white-space: pre-wrap !important;
}
pre,
blockquote {
border: 1px solid #adb5bd;
page-break-inside: avoid;
}
tr,
img {
page-break-inside: avoid;
}
p,
h2,
h3 {
orphans: 3;
widows: 3;
}
h2,
h3 {
page-break-after: avoid;
}
@page {
size: a3;
}
body {
min-width: 992px !important;
}
.container {
min-width: 992px !important;
}
.badge {
border: 1px solid #000;
}
.table {
border-collapse: collapse !important;
}
.table td,
.table th {
background-color: #fff !important;
}
.table-bordered th,
.table-bordered td {
border: 1px solid #dee2e6 !important;
}
.table-dark {
color: inherit;
}
.table-dark th,
.table-dark td,
.table-dark thead th,
.table-dark tbody + tbody {
border-color: #dee2e6;
}

/* Custom Print rules */
.region-nav-branding {
width: 100%;
}

.navbar-toggler,
.region-breadcrumb,
.block-local-tasks-block {
display: none;
}

main {
margin-top: 1rem;
}

footer {
border-top: 2px solid var(--bs-dark);
padding: 1rem 0;

#copyright,
#copyright a {
color: var(--bs-black);
}
.unb-lib-logo .fill-unb {
fill: var(--bs-black);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ global-styling:
'//fonts.googleapis.com/css2?family=Merriweather:ital,wght@0,700;1,700&display=swap': { external: true, minified: true }
theme:
dist/css/style.css: { minified: true }
dist/css/print.css: { media: print, minified: true }
js:
dist/js/global.js: { }
dependencies:
Expand Down

0 comments on commit 2041def

Please sign in to comment.