[lintian] 01/01: r/templates: Generate HTML5 output instead of XHTML 1.1
This is an automated email from the git hooks/post-receive script.
nthykier pushed a commit to branch master
in repository lintian.
commit 9652c2e46cc5909e7d8ebad7a28aa5fefaf29e1e
Author: Niels Thykier <niels@thykier.net>
Date: Tue Jun 30 21:22:05 2015 +0200
r/templates: Generate HTML5 output instead of XHTML 1.1
... for that new and shiny look.
Signed-off-by: Niels Thykier <niels@thykier.net>
---
debian/changelog | 3 +++
reporting/templates/foot.tmpl | 6 +++---
reporting/templates/head.tmpl | 16 ++++++----------
reporting/templates/lintian.css.tmpl | 23 ++++++++++++++++-------
reporting/templates/maintainer.tmpl | 2 +-
reporting/templates/maintainers.tmpl | 2 +-
6 files changed, 30 insertions(+), 22 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index a82e175..359d0ca 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -6,6 +6,9 @@ lintian (2.5.33) UNRELEASED; urgency=medium
+ [JW] Correct spelling for "GNU Public Licence".
(Closes: #790369)
+ * reporting/templates/*.tmpl:
+ + [NT] Change from XHTML 1.1 to HTML5.
+
-- Niels Thykier <niels@thykier.net> Sun, 28 Jun 2015 17:01:10 +0200
lintian (2.5.32) unstable; urgency=medium
diff --git a/reporting/templates/foot.tmpl b/reporting/templates/foot.tmpl
index baa1e42..d9553b7 100644
--- a/reporting/templates/foot.tmpl
+++ b/reporting/templates/foot.tmpl
@@ -1,8 +1,8 @@
-</div> <!-- main -->
+</main>
<hr/>
-<div id="footer">
+<footer>
<p>
Comments about these web pages? Please use
<a href="http://packages.debian.org/sid/reportbug">reportbug</a>
@@ -14,7 +14,7 @@
<a href="{$LINTIAN_SOURCE}">{$LINTIAN_SOURCE}</a>.
</p>
<p>Page last updated: {$timestamp} using Lintian {$version}.</p>
-</div>
+</footer>
</body>
</html>
diff --git a/reporting/templates/head.tmpl b/reporting/templates/head.tmpl
index ffeb81a..fd3554f 100644
--- a/reporting/templates/head.tmpl
+++ b/reporting/templates/head.tmpl
@@ -1,12 +1,8 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!DOCTYPE html
- PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<!DOCTYPE html>
+<html lang="en">
<head>
<title>{$page_title}</title>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link rel="stylesheet" href="{resource_path('lintian.css')}" type="text/css" />
<link rel="icon" href="{resource_path('ico.png')}" type="image/png" />
@@ -14,7 +10,7 @@
<body>
-<div id="header">
+<header>
<p><a href="{$path_prefix}index.html">Lintian Reports</a></p>
<ul id="nav">
<li><a href="{$path_prefix}maintainers.html">Maintainers</a></li>
@@ -23,6 +19,6 @@
<li><a href="{$path_prefix}packages_1.html">Packages</a></li>
</ul>
<div class="clear"></div>
-</div>
+</header>
-<div id="main">
+<main>
diff --git a/reporting/templates/lintian.css.tmpl b/reporting/templates/lintian.css.tmpl
index af49fff..a8cfef5 100644
--- a/reporting/templates/lintian.css.tmpl
+++ b/reporting/templates/lintian.css.tmpl
@@ -92,19 +92,19 @@ hr {
display: none;
}
-
/*
* 2. Header title
*/
-#header {
+header {
+ display: block; /* HTML5 compat */
margin: 0 0 28px 0;
padding: 5px 20px;
background: #F3F3F3 url("{{{resource_path('logo-small.png')}}}") no-repeat right;
border-bottom: 1px solid #AAA;
}
-#header p {
+header p {
float: left;
margin: 5px 0;
color: #444;
@@ -113,7 +113,7 @@ hr {
font-weight: bold;
}
-#header p a {
+header p a {
color: #444;
text-decoration: none;
}
@@ -151,7 +151,8 @@ hr {
* 4. Main content
*/
-#main {
+main {
+ display: block;
margin: 0 25px;
font-size: 0.9em;
line-height: 1.4em;
@@ -408,14 +409,15 @@ blockquote.type-P {
* 5. Footer
*/
-#footer {
+footer {
+ display: block; /* HTML5 compat */
margin: 20px 20px;
padding: 10px 0 0 0;
font-size: 0.85em;
border-top: 1px solid #AAA;
}
-#footer p {
+footer p {
margin: 0;
padding: 0;
}
@@ -428,3 +430,10 @@ blockquote.type-P {
div.clear {
clear: both;
}
+
+a.invisible-anchor {
+ /*
+ These elements are always empty, but lets make this abundantly clear
+ */
+ display: none;
+}
diff --git a/reporting/templates/maintainer.tmpl b/reporting/templates/maintainer.tmpl
index d720919..5740b04 100644
--- a/reporting/templates/maintainer.tmpl
+++ b/reporting/templates/maintainer.tmpl
@@ -121,7 +121,7 @@
if ($first_version) {
# Unversioned #<pkg> references just go to the first version.
$first_version = 0;
- $OUT .= qq( <a id="${source}" />)
+ $OUT .= qq( <a class="invisible-anchor" id="${source}"></a>)
}
$OUT .= "</h2>\n";
$OUT .= qq( <p class="info-links">\n);
diff --git a/reporting/templates/maintainers.tmpl b/reporting/templates/maintainers.tmpl
index 24ed83d..b6c02e8 100644
--- a/reporting/templates/maintainers.tmpl
+++ b/reporting/templates/maintainers.tmpl
@@ -34,7 +34,7 @@
if ($letter eq 'Other') {
$OUT .= qq( </p>\n\n <h2>Other</h2>\n\n <p>\n);
} else {
- $OUT .= qq( </p>\n\n <h2 id="$letter"><a name="$letter">)
+ $OUT .= qq( </p>\n\n <h2 id="$letter"><a id="$letter">)
. $letter . "</a></h2>\n\n <p>\n";
}
}
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/lintian/lintian.git
Reply to: