aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Weiske <cweiske@cweiske.de>2012-03-26 23:55:46 +0200
committerChristian Weiske <cweiske@cweiske.de>2012-03-26 23:55:46 +0200
commit64ff825aec91fd0f914d05cf17cd299be83b165c (patch)
treedbb66383995372b880b6dea1c4977f23f55a27b3
parentf7101de3d20753dafe8e02f4e43112e2e208b8d7 (diff)
downloadphorkie-64ff825aec91fd0f914d05cf17cd299be83b165c.tar.gz
phorkie-64ff825aec91fd0f914d05cf17cd299be83b165c.zip
anchors for file names
-rw-r--r--data/templates/base.htm2
-rw-r--r--data/templates/display.htm2
-rw-r--r--data/templates/exception.htm2
-rw-r--r--www/phorkie.css16
4 files changed, 19 insertions, 3 deletions
diff --git a/data/templates/base.htm b/data/templates/base.htm
index f406f00..d0c3cee 100644
--- a/data/templates/base.htm
+++ b/data/templates/base.htm
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
- <!--<link rel="stylesheet" href="phorkie.css" />-->
+ <link rel="stylesheet" href="phorkie.css" />
<title>{% block title %}{% endblock %} - Phorkie</title>
</head>
<body>
diff --git a/data/templates/display.htm b/data/templates/display.htm
index 6575617..afdc75c 100644
--- a/data/templates/display.htm
+++ b/data/templates/display.htm
@@ -9,7 +9,7 @@
</ul>
{% for file in repo.getFiles %}
<div>
- <h2>{{file.getFilename}}</h2>
+ <h2 id="{{file.getFilename}}">{{file.getFilename}}<a class="anchorlink" href="#{{file.getFilename}}"></a></h2>
<p>
<a href="{{file.getLink('raw')}}">raw</a>
</p>
diff --git a/data/templates/exception.htm b/data/templates/exception.htm
index 805342a..410c3c0 100644
--- a/data/templates/exception.htm
+++ b/data/templates/exception.htm
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
- <!--<link rel="stylesheet" href="phorkie.css" />-->
+ <link rel="stylesheet" href="phorkie.css" />
<title>Error - Phorkie</title>
</head>
<body>
diff --git a/www/phorkie.css b/www/phorkie.css
new file mode 100644
index 0000000..d6d1173
--- /dev/null
+++ b/www/phorkie.css
@@ -0,0 +1,16 @@
+/* show IDs for anchors */
+h1[id]:hover a.anchorlink:before,
+h2[id]:hover a.anchorlink:before,
+h3[id]:hover a.anchorlink:before,
+h4[id]:hover a.anchorlink:before,
+h5[id]:hover a.anchorlink:before,
+h6[id]:hover a.anchorlink:before {
+ content: "\00B6";/* pilcrow */
+ color: #888;
+ font-size: smaller;
+}
+a.anchorlink {
+ text-decoration: none;
+ margin-left: 0.5em;
+ font-size: smaller;
+}