Skip to content

Commit ce31d97

Browse files
committed
[issuegen] Add ability to draft HTML intros
1 parent d6ef4a3 commit ce31d97

File tree

1 file changed

+34
-21
lines changed

1 file changed

+34
-21
lines changed

bin/issuegen.pl

Lines changed: 34 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@
2626
2727
Draft: http://www.w3.org/TR/2013/WD-css-text-decor-3-20130103/
2828
Title: CSS Text Decoration Level 3
29-
... any notes you want here, except 4 dashes ...
29+
30+
... any HTML intro content you want here, except 4 consecutive dashes ...
3031
3132
----
3233
Issue 1.
@@ -220,11 +221,12 @@ sub header {
220221
chomp;
221222

222223
# Extract title and URL
223-
my ($title, $url, $shortname);
224+
my ($title, $url, $shortname, $intro);
224225
for (split /\n+/) {
225-
$title = $1 if (/^Title:\s+(.+)$/);
226-
$url = $1 if (/^Draft:\s+(\S+)/);
227-
$shortname = $1 if (/^Shortname:\s+(\S+)/);
226+
if (/^Title:\s+(.+)$/) { $title = $1; }
227+
elsif (/^Draft:\s+(\S+)/) { $url = $1; }
228+
elsif (/^Shortname:\s+(\S+)/) { $shortname = $1; }
229+
else { $intro .= $_; }
228230
}
229231
die "Error: missing document URL or title.\n" unless ($url && $title);
230232

@@ -244,7 +246,7 @@ sub header {
244246
<meta charset="utf-8">
245247
<title>$title Disposition of Comments for $date $status</title>
246248
<style type="text/css">
247-
pre { border: solid thin silver; padding: 0.2em; white-space: normal; }
249+
pre, .legend { border: solid thin silver; padding: 0.2em; white-space: normal; }
248250
pre > span { display: block; white-space: pre; }
249251
.a { background: #52E052 }
250252
.d { background: #8CCBF2 }
@@ -259,30 +261,41 @@ sub header {
259261
.open { border: solid red; }
260262
:target { box-shadow: 0.25em 0.25em 0.25em; }
261263
a[href^=mid], a[href~=flatten] { text-decoration: none; }
262-
abbr { font-weight: bold; }
264+
abbr, dt { font-weight: bold; }
265+
dl.compact { display: grid; grid-template-columns: auto 1fr; }
266+
dt { grid-column: 1 }
267+
dd { grid-column: 2 }
268+
ins { color: green; }
269+
del { color: #A00; }
263270
</style>
264271
265272
<h1>$title Disposition of Comments for $date $status</h1>
266273
267-
<p>Dated Draft: <a href="$url">$url</a>
274+
<dl class="compact">
275+
<dt>Dated Draft: <dd><a href="$url">$url</a>
276+
<dt>Editor's Draft: <dd><a href="http://drafts.csswg.org/$shortname/">http://drafts.csswg.org/$shortname/</a>
277+
</dl>
268278
269-
<p>Editor's Draft: <a href="http://drafts.csswg.org/$shortname/">http://drafts.csswg.org/$shortname/</a>
279+
$intro
270280
271-
<p>The following color coding convention is used for comments:</p>
281+
<details class="legend">
282+
<summary>Legend</summary>
283+
<p>The following color coding convention is used for comments:</p>
272284
273-
<ul>
274-
<li class="a">Accepted or Rejected and positive response
275-
<li class="r">Rejected and no response
276-
<li class="fo">Rejected and negative response
277-
<li class="d">Deferred
278-
<li class="oi">Out-of-Scope or Invalid and not verified
279-
</ul>
285+
<ul>
286+
<li class="a">Accepted or Rejected and positive response
287+
<li class="r">Rejected and no response
288+
<li class="fo">Rejected and negative response
289+
<li class="d">Deferred
290+
<li class="oi">Out-of-Scope or Invalid and not verified
291+
</ul>
280292
281-
<p class=open>Open issues are marked like this</p>
293+
<p class=open>Open issues are marked like this</p>
282294
283-
<p>An issue can be closed as <code>Accepted</code>, <code>OutOfScope</code>,
284-
<code>Invalid</code>, <code>Rejected</code>, or <code>Retracted</code>.
285-
<code>Verified</code> indicates commentor's acceptance of the response.</p>
295+
<p>An issue can be closed as <code>Accepted</code>, <code>OutOfScope</code>,
296+
<code>Invalid</code>, <code>Rejected</code>, or <code>Retracted</code>.
297+
<code>Verified</code> indicates commentor's acceptance of the response.</p>
298+
</details>
286299
XXX
287300
}
288301

0 commit comments

Comments
 (0)