summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorYorhel <git@yorhel.nl>2011-04-08 17:09:48 +0200
committerYorhel <git@yorhel.nl>2011-04-08 17:09:48 +0200
commitdf094a5eff934b6057def369dca30df616248c80 (patch)
tree2f2fbe1b78e648f916ea00c0f0daa65edfbab6e0 /lib
parent3a6a1dabe45d5fcdfd882de65c24ac45f173803e (diff)
Added spoiler warning to character revision pages
Diffstat (limited to 'lib')
-rw-r--r--lib/VNDB/Util/CommonHTML.pm11
1 files changed, 10 insertions, 1 deletions
diff --git a/lib/VNDB/Util/CommonHTML.pm b/lib/VNDB/Util/CommonHTML.pm
index 41370b4b..e1765d0d 100644
--- a/lib/VNDB/Util/CommonHTML.pm
+++ b/lib/VNDB/Util/CommonHTML.pm
@@ -163,6 +163,15 @@ sub htmlRevision {
div class => 'mainbox revision';
h1 mt '_revision_title', $new->{rev};
+ # character information may be rather spoilerous
+ if($type eq 'c') {
+ div class => 'warning';
+ h2 mt '_revision_spoil_title';
+ lit mt '_revision_spoil_msg', "/c$new->{id}";
+ end;
+ br;br;
+ }
+
# previous/next revision links
a class => 'prev', href => sprintf('/%s%d.%d', $type, $new->{id}, $new->{rev}-1), '<- '.mt '_revision_previous'
if $new->{rev} > 1;
@@ -174,7 +183,7 @@ sub htmlRevision {
# no previous revision, just show info about the revision itself
if(!$old) {
- div;
+ div class => 'rev';
revheader($self, $type, $new);
br;
b mt '_revision_new_summary';