Separate print and screen stylesheets for better automation

This commit is contained in:
RunasSudo 2020-04-17 03:45:37 +10:00
parent 0c8f4a2ad4
commit 92bbbcdf0f
Signed by: RunasSudo
GPG Key ID: 7234E476BF21C61A
3 changed files with 27 additions and 6 deletions

View File

@ -23,6 +23,7 @@
<title>{% block title %}{% endblock %}</title>
<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/8.0.1/normalize.min.css" integrity="sha256-l85OmPOjvil/SOvVt3HnSSjzF1TUMyT9eV0c2BzEGzU=" crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='main.css') }}">
<link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='print.css') }}" media="print">
</head>
<body>
{% block body %}{% endblock %}

View File

@ -18,6 +18,7 @@
body {
font-family: 'TeX Gyre Termes', 'Nimbus Roman', 'Times New Roman', 'Liberation Serif', Times, serif;
padding: 2em;
}
/* Tables */
@ -121,12 +122,6 @@ label {
transition: opacity 0s;
}
@media screen {
body {
padding: 2em;
}
}
@media print {
.nav-header {
display: none;

View File

@ -0,0 +1,25 @@
/*
ledger-pyreport
Copyright © 2020 Lee Yingtong Li (RunasSudo)
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
body {
padding: initial;
}
.nav-header {
display: none;
}