| @@ -1,79 +1,51 @@ |
| 1 | // Style overrides for printing | | |
| 2 | | | |
| 3 | @include print { | 1 | @include print { |
| 4 | | 2 | ._header, ._sidebar, ._path, ._notif, ._toc, ._pre-clip, ._notice, ._links { |
| 5 | ._header, ._sidebar, ._path, ._notif, ._toc, ._pre-clip, ._notice { | | |
| 6 | display: none !important; | 3 | display: none !important; |
| 7 | } | 4 | } |
| 8 | | 5 | |
| 9 | // make the docs fill the page and scroll the <body> instead of ._container | 6 | body, ._app, ._container, ._content { |
| 10 | body { | | |
| 11 | height: initial; | | |
| 12 | &::after { | | |
| 13 | content: ''; | | |
| 14 | clear: both; | | |
| 15 | } | | |
| 16 | } | | |
| 17 | ._app { | | |
| 18 | height: initial; | | |
| 19 | } | | |
| 20 | ._container { | | |
| 21 | margin: 0; | 7 | margin: 0; |
| 22 | padding: 0; | 8 | padding: 0; |
| 23 | height: initial; | 9 | height: initial; |
| | 10 | background: none; |
| 24 | | 11 | |
| 25 | ._content { | 12 | &:after { |
| 26 | margin: 0; | 13 | content: ''; |
| | 14 | clear: both; |
| 27 | } | 15 | } |
| 28 | } | 16 | } |
| 29 | | 17 | |
| 30 | // Hide the scrollbars | | |
| 31 | ::-webkit-scrollbar { | 18 | ::-webkit-scrollbar { |
| 32 | display: none; | 19 | display: none; |
| 33 | } | 20 | } |
| 34 | | 21 | |
| 35 | // empty the boxes. | 22 | %external-link:after { |
| 36 | %box, | 23 | display: none; |
| 37 | %heading-box { | | |
| 38 | background: transparent; | | |
| 39 | } | | |
| 40 | %heading-box { | | |
| 41 | border-radius: 0; | | |
| 42 | border: { | | |
| 43 | top: none; | | |
| 44 | left: none; | | |
| 45 | right: none; | | |
| 46 | } | | |
| 47 | } | 24 | } |
| 48 | | 25 | |
| | 26 | ._attribution-p { |
| | 27 | background: none; |
| | 28 | border: 2px solid $boxBorder; |
| | 29 | } |
| 49 | | 30 | |
| 50 | // Underline links, put the destination after the link text | 31 | ._attribution:last-child:after { |
| 51 | %external-link { | 32 | content: 'Exported from DevDocs — https://devdocs.io'; |
| 52 | text-decoration: underline; | 33 | display: block; |
| 53 | &::after { | 34 | margin-top: 1rem; |
| 54 | content: ' (' attr(href) ')'; | 35 | font-weight: $bolderFontWeight; |
| 55 | background-image: none; | | |
| 56 | display: inline; | | |
| 57 | margin: 0; | | |
| 58 | } | | |
| 59 | } | 36 | } |
| 60 | | 37 | |
| 61 | // Link back to DevDocs | 38 | ._attribution { |
| 62 | ._attribution-p { | 39 | page-break-inside: avoid; |
| 63 | background: transparent; | 40 | } |
| 64 | border: 2px solid $labelBackground; | | |
| 65 | | 41 | |
| 66 | &:after { | 42 | h1, h2, h3, h4, h5, h6 { |
| 67 | content: 'Exported from DevDocs (https://devdocs.io)'; | 43 | page-break-inside: avoid; |
| 68 | font-style: italic; | 44 | page-break-after: avoid; |
| 69 | } | | |
| 70 | } | 45 | } |
| 71 | | 46 | |
| 72 | // Fix page breaks | | |
| 73 | pre { | 47 | pre { |
| 74 | page-break-before: avoid; | 48 | page-break-before: avoid; |
| 75 | } | | |
| 76 | pre { | | |
| 77 | orphans: 5; | 49 | orphans: 5; |
| 78 | widows: 5; | 50 | widows: 5; |
| 79 | } | 51 | } |