From f1b50fe12fdc6d5af37b79f1fee54760367e3fbb Mon Sep 17 00:00:00 2001 From: Bernhard Bock Date: Fri, 21 Sep 2018 14:21:38 +0200 Subject: [PATCH] Hide sub-header in print Add a CSS class for all sub-headers and hide in media `@print`. Issue: #2435 Signed-off-by: Bernhard Bock (github: bbock) --- netbox/project-static/css/base.css | 9 ++++++++- netbox/templates/circuits/circuit.html | 2 +- netbox/templates/circuits/provider.html | 2 +- netbox/templates/dcim/device.html | 2 +- netbox/templates/dcim/devicetype.html | 2 +- netbox/templates/dcim/interface.html | 2 +- netbox/templates/dcim/rack.html | 2 +- netbox/templates/dcim/site.html | 2 +- netbox/templates/extras/configcontext.html | 2 +- netbox/templates/extras/objectchange.html | 2 +- netbox/templates/extras/report.html | 2 +- netbox/templates/ipam/aggregate.html | 2 +- netbox/templates/ipam/ipaddress.html | 2 +- netbox/templates/ipam/prefix.html | 2 +- netbox/templates/ipam/service.html | 2 +- netbox/templates/ipam/vlan.html | 2 +- netbox/templates/ipam/vlangroup_vlans.html | 2 +- netbox/templates/ipam/vrf.html | 2 +- netbox/templates/secrets/secret.html | 2 +- netbox/templates/tenancy/tenant.html | 2 +- netbox/templates/virtualization/cluster.html | 2 +- netbox/templates/virtualization/virtualmachine.html | 2 +- 22 files changed, 29 insertions(+), 22 deletions(-) diff --git a/netbox/project-static/css/base.css b/netbox/project-static/css/base.css index 6222a477d..a362ade47 100644 --- a/netbox/project-static/css/base.css +++ b/netbox/project-static/css/base.css @@ -444,4 +444,11 @@ td .progress { } textarea { font-family: Consolas, Lucida Console, monospace; -} \ No newline at end of file +} + +/* Hide some elements for printing */ +@media print { + .sub-header { + display: none; + } +} diff --git a/netbox/templates/circuits/circuit.html b/netbox/templates/circuits/circuit.html index 5c86cb24e..24127c66b 100644 --- a/netbox/templates/circuits/circuit.html +++ b/netbox/templates/circuits/circuit.html @@ -4,7 +4,7 @@ {% block title %}{{ circuit }}{% endblock %} {% block header %} -
+