Compare commits

..

No commits in common. 'pelican' and 'gh-pages' have entirely different histories.

  1. 2
      .gitignore
  2. 24
      LICENSE
  3. 11
      Readme.md
  4. 34
      archives.html
  5. 34
      authors.html
  6. 33
      categories.html
  7. 0
      css/theme.css
  8. 0
      img/black.jpg
  9. 0
      img/favicon.ico
  10. 0
      img/one_branch.png
  11. 0
      img/three_branch.png
  12. 0
      img/two_branch.png
  13. 2
      index.html
  14. 4
      jquery-1.9.0.min.js
  15. 495
      jquery.subwayMap-0.5.0.js
  16. 14
      one_branch.css
  17. 33
      one_branch.html
  18. 15
      pelican/READ_THESE_INSTRUCTIONS.md
  19. 62
      pelican/pelicanconf.py
  20. 45
      subway.css
  21. 34
      tags.html
  22. 177
      theme/static/css/style.css
  23. 79
      theme/style.css
  24. 14
      three_branches.css
  25. 50
      three_branches.html
  26. 14
      two_branches.css
  27. 44
      two_branches.html
  28. 0
      vendor/bootstrap/css/bootstrap.min.css
  29. 0
      vendor/bootstrap/js/bootstrap.bundle.min.js
  30. 0
      vendor/bootstrap/js/bootstrap.min.js
  31. 0
      vendor/jquery/jquery.min.js
  32. 0
      vendor/jquery/jquery.slim.min.js

2
.gitignore vendored

@ -1,2 +0,0 @@ @@ -1,2 +0,0 @@
pelican/output
pelican/subway

24
LICENSE

@ -1,24 +0,0 @@ @@ -1,24 +0,0 @@
This work is based on work by Nik Kalyani (2010) nik@kalyani.com http://www.kalyani.com
and Jon Burrows (2016) subwaymap@jonburrows.co.uk https://jonburrows.co.uk
---------------------------------------------
Copyright (c) 2018 Charles Reid
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

11
Readme.md

@ -1,11 +0,0 @@ @@ -1,11 +0,0 @@
# git-subway-maps
Diagrams of git repos in the style of subway maps.
Branches:
* `subway` - contains the actual files for the git subway map app
* `pelican` - contains the files to generate the Pelican site
* `gh-pages` - contains the final Pelican site content
You are currently on the `pelican` branch.

34
archives.html

@ -0,0 +1,34 @@ @@ -0,0 +1,34 @@
<!DOCTYPE html>
<html>
<head>
<title>Archives</title>
<meta charset="utf-8" />
<link href="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css" rel="stylesheet" />
<link href="/theme/static/css/style.css" rel="stylesheet" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
</head>
<body id="index" class="archive">
<div class="container">
<div class="header">
<ul class="nav nav-pills pull-right">
<li class=""><a href="">Home</a></li>
<li class="active"><a href="/archives.html">Archives</a></li>
</ul>
<h3 class="text-muted"><a href="">Git Subway Maps</a></h3>
<h2 class="text-muted"></h2>
</div>
<dl>
</dl>
<footer id="contentinfo" class="footer">
<nav class="pull-right bottom-nav">
<a href="/None">RSS</a>
</nav>
<address id="about" class="vcard body">
&copy; <a href="">Git Subway Maps</a> Proudly powered by <a href="http://getpelican.com/">Pelican</a>
</address><!-- /#about -->
</footer><!-- /#contentinfo -->
</div><!-- container -->
</body>
</html>

34
authors.html

@ -0,0 +1,34 @@ @@ -0,0 +1,34 @@
<!DOCTYPE html>
<html>
<head>
<title>Git Subway Maps - Authors</title>
<meta charset="utf-8" />
<link href="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css" rel="stylesheet" />
<link href="/theme/static/css/style.css" rel="stylesheet" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
</head>
<body id="index" class="archive">
<div class="container">
<div class="header">
<ul class="nav nav-pills pull-right">
<li class=""><a href="">Home</a></li>
<li><a href="/archives.html">Archives</a></li>
</ul>
<h3 class="text-muted"><a href="">Git Subway Maps</a></h3>
<h2 class="text-muted"></h2>
</div>
<h1>Authors on Git Subway Maps</h1>
<ul> </ul>
<footer id="contentinfo" class="footer">
<nav class="pull-right bottom-nav">
<a href="/None">RSS</a>
</nav>
<address id="about" class="vcard body">
&copy; <a href="">Git Subway Maps</a> Proudly powered by <a href="http://getpelican.com/">Pelican</a>
</address><!-- /#about -->
</footer><!-- /#contentinfo -->
</div><!-- container -->
</body>
</html>

33
categories.html

@ -0,0 +1,33 @@ @@ -0,0 +1,33 @@
<!DOCTYPE html>
<html>
<head>
<title> Articles in - Git Subway Maps</title>
<meta charset="utf-8" />
<link href="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css" rel="stylesheet" />
<link href="/theme/static/css/style.css" rel="stylesheet" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
</head>
<body id="index" class="archive">
<div class="container">
<div class="header">
<ul class="nav nav-pills pull-right">
<li class=""><a href="">Home</a></li>
<li class="active"><a href="/archives.html">Archives</a></li>
</ul>
<h3 class="text-muted"><a href="">Git Subway Maps</a></h3>
<h2 class="text-muted"></h2>
</div>
<ul>
</ul>
<footer id="contentinfo" class="footer">
<nav class="pull-right bottom-nav">
<a href="/None">RSS</a>
</nav>
<address id="about" class="vcard body">
&copy; <a href="">Git Subway Maps</a> Proudly powered by <a href="http://getpelican.com/">Pelican</a>
</address><!-- /#about -->
</footer><!-- /#contentinfo -->
</div><!-- container -->
</body>
</html>

0
pelican/content/css/theme.css → css/theme.css

0
pelican/content/img/black.jpg → img/black.jpg

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 40 KiB

0
pelican/content/img/favicon.ico → img/favicon.ico

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

0
pelican/content/img/one_branch.png → img/one_branch.png

Before

Width:  |  Height:  |  Size: 37 KiB

After

Width:  |  Height:  |  Size: 37 KiB

0
pelican/content/img/three_branch.png → img/three_branch.png

Before

Width:  |  Height:  |  Size: 81 KiB

After

Width:  |  Height:  |  Size: 81 KiB

0
pelican/content/img/two_branch.png → img/two_branch.png

Before

Width:  |  Height:  |  Size: 67 KiB

After

Width:  |  Height:  |  Size: 67 KiB

2
pelican/content/index.html → index.html

@ -102,4 +102,4 @@ @@ -102,4 +102,4 @@
</body>
</html>
</html>

4
jquery-1.9.0.min.js vendored

File diff suppressed because one or more lines are too long

495
jquery.subwayMap-0.5.0.js

@ -0,0 +1,495 @@ @@ -0,0 +1,495 @@
/*
Copyright (c) 2010 Nik Kalyani nik@kalyani.com http://www.kalyani.com
Modified work Copyright (c) 2016 Jon Burrows subwaymap@jonburrows.co.uk https://jonburrows.co.uk
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
(function ($) {
var plugin = {
defaults: {
debug: false,
grid: false
},
options: {
},
identity: function (type) {
if (type === undefined) type = "name";
switch (type.toLowerCase()) {
case "version": return "1.0.0"; break;
default: return "subwayMap Plugin"; break;
}
},
_debug: function (s) {
if (this.options.debug)
this._log(s);
},
_log: function () {
if (window.console && window.console.log)
window.console.log('[subwayMap] ' + Array.prototype.join.call(arguments, ' '));
},
_supportsCanvas: function () {
var canvas = $("<canvas></canvas>");
if (canvas[0].getContext)
return true;
else
return false;
},
_getCanvasLayer: function (el, overlay) {
this.layer++;
var canvas = $("<canvas style='position:absolute;z-Index:" + ((overlay ? 2000 : 1000) + this.layer) + "' width='" + this.options.pixelWidth + "' height='" + this.options.pixelHeight + "'></canvas>");
el.append(canvas);
return (canvas[0].getContext("2d"));
},
_render: function (el) {
this.layer = -1;
var rows = el.attr("data-rows");
if (rows === undefined)
rows = 10;
else
rows = parseInt(rows);
var columns = el.attr("data-columns");
if (columns === undefined)
columns = 10;
else
columns = parseInt(columns);
var scale = el.attr("data-cellSize");
if (scale === undefined)
scale = 100;
else
scale = parseInt(scale);
var lineWidth = el.attr("data-lineWidth");
if (lineWidth === undefined)
lineWidth = 10;
else
lineWidth = parseInt(lineWidth);
var textClass = el.attr("data-textClass");
if (textClass === undefined) textClass = "";
var grid = el.attr("data-grid");
if ((grid === undefined) || (grid.toLowerCase() == "false"))
grid = false;
else
grid = true;
var legendId = el.attr("data-legendId");
if (legendId === undefined) legendId = "";
var gridNumbers = el.attr("data-gridNumbers");
if ((gridNumbers === undefined) || (gridNumbers.toLowerCase() == "false"))
gridNumbers = false;
else
gridNumbers = true;
var reverseMarkers = el.attr("data-reverseMarkers");
if ((reverseMarkers === undefined) || (reverseMarkers.toLowerCase() == "false"))
reverseMarkers = false;
else
reverseMarkers = true;
this.options.pixelWidth = columns * scale;
this.options.pixelHeight = rows * scale;
//el.css("width", this.options.pixelWidth);
//el.css("height", this.options.pixelHeight);
var self = this;
var lineLabels = [];
var supportsCanvas = $("<canvas></canvas>")[0].getContext;
if (supportsCanvas) {
if (grid) this._drawGrid(el, scale, gridNumbers);
$(el).children("ul").each(function (index) {
var ul = $(this);
var color = $(ul).attr("data-color");
if (color === undefined) color = "#000000";
var lineTextClass = $(ul).attr("data-textClass");
if (lineTextClass === undefined) lineTextClass = "";
var shiftCoords = $(ul).attr("data-shiftCoords");
if (shiftCoords === undefined) shiftCoords = "";
var shiftX = 0.00;
var shiftY = 0.00;
if (shiftCoords.indexOf(",") > -1) {
shiftX = parseInt(shiftCoords.split(",")[0]) * lineWidth/scale;
shiftY = parseInt(shiftCoords.split(",")[1]) * lineWidth/scale;
}
var lineLabel = $(ul).attr("data-label");
if (lineLabel === undefined)
lineLabel = "Line " + index;
lineLabels[lineLabels.length] = {label: lineLabel, color: color};
var nodes = [];
$(ul).children("li").each(function () {
var coords = $(this).attr("data-coords");
if (coords === undefined) coords = "";
var dir = $(this).attr("data-dir");
if (dir === undefined) dir = "";
var labelPos = $(this).attr("data-labelPos");
if (labelPos === undefined) labelPos = "s";
var marker = $(this).attr("data-marker");
if (marker == undefined) marker = "";
var markerInfo = $(this).attr("data-markerInfo");
if (markerInfo == undefined) markerInfo = "";
var dotted = $(this).attr("data-dotted-line");
if (dotted == undefined) dotted = "false";
var anchor = $(this).children("a:first-child");
var label = $(this).text();
if (label === undefined) label = "";
var link = "";
var title = "";
if (anchor != undefined) {
link = $(anchor).attr("href");
if (link === undefined) link = "";
title = $(anchor).attr("title");
if (title === undefined) title = "";
}
self._debug("Coords=" + coords + "; Dir=" + dir + "; Link=" + link + "; Label=" + label + "; labelPos=" + labelPos + "; Marker=" + marker + "; Dotted=" + dotted);
var x = "";
var y = "";
if (coords.indexOf(",") > -1) {
x = Number(coords.split(",")[0]) + (marker.indexOf("interchange") > -1 ? 0 : shiftX);
y = Number(coords.split(",")[1]) + (marker.indexOf("interchange") > -1 ? 0 : shiftY);
}
nodes[nodes.length] = { x: x, y: y, direction: dir, marker: marker, markerInfo: markerInfo, link: link, title: title, label: label, labelPos: labelPos, dotted: dotted };
});
if (nodes.length > 0)
self._drawLine(el, scale, rows, columns, color, (lineTextClass != "" ? lineTextClass : textClass), lineWidth, nodes, reverseMarkers);
$(ul).remove();
});
if ((lineLabels.length > 0) && (legendId != ""))
{
var legend = $("#" + legendId);
for(var line=0; line<lineLabels.length; line++)
legend.append("<div><span style='float:left;width:100px;height:" + lineWidth + "px;background-color:" + lineLabels[line].color + "'></span>" + lineLabels[line].label + "</div>");
}
}
},
_drawLine: function (el, scale, rows, columns, color, textClass, width, nodes, reverseMarkers) {
var ctx = this._getCanvasLayer(el, false);
ctx.beginPath();
ctx.moveTo(nodes[0].x * scale, nodes[0].y * scale);
var markers = [];
var lineNodes = [];
var node;
for(node = 0; node < nodes.length; node++)
{
if (nodes[node].marker.indexOf("@") != 0)
lineNodes[lineNodes.length] = nodes[node];
}
for (var lineNode = 0; lineNode < lineNodes.length; lineNode++) {
if (lineNode < (lineNodes.length - 1)) {
var nextNode = lineNodes[lineNode + 1];
var currNode = lineNodes[lineNode];
// Correction for edges so lines are not running off campus
var xCorr = 0;
var yCorr = 0;
if (nextNode.x == 0) xCorr = width / 2;
if (nextNode.x == columns) xCorr = -1 * width / 2;
if (nextNode.y == 0) yCorr = width / 2;
if (nextNode.y == rows) yCorr = -1 * width / 2;
var xVal = 0;
var yVal = 0;
var direction = "";
var xDiff = Math.round(Math.abs(currNode.x - nextNode.x));
var yDiff = Math.round(Math.abs(currNode.y - nextNode.y));
if ((xDiff == 0) || (yDiff == 0)) {
// Horizontal or Vertical
ctx.lineTo((nextNode.x * scale) + xCorr, (nextNode.y * scale) + yCorr);
}
else if ((xDiff == 1) && (yDiff == 1)) {
// 90 degree turn
if (nextNode.direction != "")
direction = nextNode.direction.toLowerCase();
switch (direction) {
case "s": xVal = 0; yVal = scale; break;
case "e": xVal = scale; yVal = 0; break;
case "w": xVal = -1 * scale; yVal = 0; break;
default: xVal = 0; yVal = -1 * scale; break;
}
ctx.quadraticCurveTo((currNode.x * scale) + xVal, (currNode.y * scale) + yVal,
(nextNode.x * scale) + xCorr, (nextNode.y * scale) + yCorr);
}
else if (xDiff == yDiff) {
// Symmetric, angular with curves at both ends
if (nextNode.x < currNode.x) {
if (nextNode.y < currNode.y)
direction = "nw";
else
direction = "sw";
}
else {
if (nextNode.y < currNode.y)
direction = "ne";
else
direction = "se";
}
var dirVal = 1;
switch (direction) {
case "nw": xVal = -1 * (scale / 2); yVal = 1; dirVal = 1; break;
case "sw": xVal = -1 * (scale / 2); yVal = -1; dirVal = 1; break;
case "se": xVal = (scale / 2); yVal = -1; dirVal = -1; break;
case "ne": xVal = (scale / 2); yVal = 1; dirVal = -1; break;
}
this._debug((currNode.x * scale) + xVal + ", " + (currNode.y * scale) + "; " + (nextNode.x + (dirVal * xDiff / 2)) * scale + ", " +
(nextNode.y + (yVal * xDiff / 2)) * scale);
ctx.bezierCurveTo(
(currNode.x * scale) + xVal, (currNode.y * scale),
(currNode.x * scale) + xVal, (currNode.y * scale),
(nextNode.x + (dirVal * xDiff / 2)) * scale, (nextNode.y + (yVal * xDiff / 2)) * scale);
ctx.bezierCurveTo(
(nextNode.x * scale) + (dirVal * scale / 2), (nextNode.y) * scale,
(nextNode.x * scale) + (dirVal * scale / 2), (nextNode.y) * scale,
nextNode.x * scale, nextNode.y * scale);
}
else
ctx.lineTo(nextNode.x * scale, nextNode.y * scale);
}
}
if (nodes[0].dotted == "true") { ctx.setLineDash([5, 5]); }
ctx.strokeStyle = color;
ctx.lineWidth = width;
ctx.stroke();
ctx = this._getCanvasLayer(el, true);
for (node = 0; node < nodes.length; node++) {
this._drawMarker(el, ctx, scale, color, textClass, width, nodes[node], reverseMarkers);
}
},
_drawMarker: function (el, ctx, scale, color, textClass, width, data, reverseMarkers) {
if (data.label == "") return;
if (data.marker == "") data.marker = "station";
// Scale coordinates for rendering
var x = data.x * scale;
var y = data.y * scale;
// Keep it simple -- black on white, or white on black
var fgColor = "#000000";
var bgColor = "#ffffff";
if (reverseMarkers)
{
fgColor = "#ffffff";
bgColor = "#000000";
}
// Render station and interchange icons
ctx.strokeStyle = fgColor;
ctx.fillStyle = bgColor;
ctx.beginPath();
switch(data.marker.toLowerCase())
{
case "interchange":
case "@interchange":
ctx.lineWidth = width;
if (data.markerInfo == "")
ctx.arc(x, y, width * 0.7, 0, Math.PI * 2, true);
else
{
var mDir = data.markerInfo.substr(0,1).toLowerCase();
var mSize = parseInt(data.markerInfo.substr(1,10));
if (((mDir == "v") || (mDir == "h")) && (mSize > 1))
{
if (mDir == "v")
{
ctx.arc(x, y, width * 0.7,290 * Math.PI/180, 250 * Math.PI/180, false);
ctx.arc(x, y-(width*mSize), width * 0.7,110 * Math.PI/180, 70 * Math.PI/180, false);
}
else
{
ctx.arc(x, y, width * 0.7,20 * Math.PI/180, 340 * Math.PI/180, false);
ctx.arc(x+(width*mSize), y, width * 0.7,200 * Math.PI/180, 160 * Math.PI/180, false);
}
}
else
ctx.arc(x, y, width * 0.7, 0, Math.PI * 2, true);
}
break;
case "station":
case "@station":
ctx.lineWidth = width/2;
ctx.arc(x, y, width/2, 0, Math.PI * 2, true);
break;
}
ctx.closePath();
ctx.stroke();
ctx.fill();
// Render text labels and hyperlinks
var pos = "";
var offset = width + 4;
var topOffset = 0;
var centerOffset = "-50px";
switch(data.labelPos.toLowerCase())
{
case "n":
pos = "text-align: center; margin: 0 0 " + offset + "px " + centerOffset;
topOffset = offset * 2;
break;
case "w":
pos = "text-align: right; margin:0 " + offset + "px 0 -" + (100 + offset) + "px";
topOffset = offset;
break;
case "e":
pos = "text-align: left; margin:0 0 0 " + offset + "px";
topOffset = offset;
break;
case "s":
pos = "text-align: center; margin:" + offset + "px 0 0 " + centerOffset;
break;
case "se":
pos = "text-align: left; margin:" + offset + "px 0 0 " + offset + "px";
break;
case "ne":
pos = "text-align: left; padding-left: " + offset + "px; margin: 0 0 " + offset + "px 0";
topOffset = offset * 2;
break;
case "sw":
pos = "text-align: right; margin:" + offset + "px 0 0 -" + (100 + offset) + "px";
topOffset = offset;
break;
case "nw":
pos = "text-align: right; margin: -" + offset + "px 0 0 -" + (100 + offset) + "px";
topOffset = offset;
break;
}
var style = (textClass != "" ? "class='" + textClass + "' " : "") + "style='" + (textClass == "" ? "font-size:8pt;font-family:Verdana,Arial,Helvetica,Sans Serif;text-decoration:none;" : "") + "width:100px;" + (pos != "" ? pos : "") + ";position:absolute;top:" + (y + el.offset().top - (topOffset > 0 ? topOffset : 0)) + "px;left:" + (x + el.offset().left) + "px;z-index:3000;'";
if (data.link != "")
$("<a " + style + " title='" + data.title.replace(/\\n/g,"<br />") + "' href='" + data.link + "' target='_new'>" + data.label.replace(/\\n/g,"<br />") + "</span>").appendTo(el);
else
$("<span " + style + ">" + data.label.replace(/\\n/g,"<br />") + "</span>").appendTo(el);
},
_drawGrid: function (el, scale, gridNumbers) {
var ctx = this._getCanvasLayer(el, false);
ctx.fillStyle = "#000";
ctx.beginPath();
var counter = 0;
for (var x = 0.5; x < this.options.pixelWidth; x += scale) {
if (gridNumbers)
{
ctx.moveTo(x, 0);
ctx.fillText(counter++, x-15, 10);
}
ctx.moveTo(x, 0);
ctx.lineTo(x, this.options.pixelHeight);
}
ctx.moveTo(this.options.pixelWidth - 0.5, 0);
ctx.lineTo(this.options.pixelWidth - 0.5, this.options.pixelHeight);
counter = 0;
for (var y = 0.5; y < this.options.pixelHeight; y += scale) {
if (gridNumbers)
{
ctx.moveTo(0, y);
ctx.fillText(counter++, 0, y-15);
}
ctx.moveTo(0, y);
ctx.lineTo(this.options.pixelWidth, y);
}
ctx.moveTo(0, this.options.pixelHeight - 0.5);
ctx.lineTo(this.options.pixelWidth, this.options.pixelHeight - 0.5);
ctx.strokeStyle = "#eee";
ctx.lineWidth = 1;
ctx.stroke();
ctx.fill();
ctx.closePath();
}
};
var methods = {
init: function (options) {
plugin.options = $.extend({}, plugin.defaults, options);
// iterate and reformat each matched element
return this.each(function (index) {
plugin.options = $.meta
? $.extend(plugin.options, $(this).data())
: plugin.options;
plugin._debug("BEGIN: " + plugin.identity() + " for element " + index);
plugin._render($(this));
plugin._debug("END: " + plugin.identity() + " for element " + index);
});
},
drawLine: function (data) {
plugin._drawLine(data.element, data.scale, data.rows, data.columns, data.color, data.width, data.nodes);
}
};
$.fn.subwayMap = function (method) {
// Method calling logic
if (methods[method]) {
return methods[method].apply(this, Array.prototype.slice.call(arguments, 1));
} else if (typeof method === 'object' || !method) {
return methods.init.apply(this, arguments);
} else {
$.error('Method ' + method + ' does not exist on jQuery.tooltip');
}
};
})(jQuery);

14
one_branch.css

@ -0,0 +1,14 @@ @@ -0,0 +1,14 @@
/**
* These styles are for one-branch maps.
*/
.subway-map
{
margin: 0;
width: 500px;
height:200px;
background-color: white;
}
div#legend {
margin-left: 50px;
}

33
one_branch.html

@ -0,0 +1,33 @@ @@ -0,0 +1,33 @@
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Git Map</title>
<script type="text/javascript" src="jquery-1.9.0.min.js"></script>
<script type="text/javascript" src="jquery.subwayMap-0.5.0.js"></script>
<link href="subway.css" rel="stylesheet">
<link href="one_branch.css" rel="stylesheet">
</head>
<body>
<div class="subway-map" data-columns="10" data-rows="3" data-cellSize="45"
data-legendId="legend" data-textClass="text" data-gridNumbers="true"
data-grid="false" data-lineWidth="8">
<ul data-color="#aced00" data-label="master branch">
<li data-coords="2,2" data-labelPos="W" data-marker="interchange">83bca09</li>
<li data-coords="3,2" data-labelPos="N">a72b587</li>
<li data-coords="4,2" data-labelPos="S">bf8a986</li>
<li data-coords="5,2" data-labelPos="N">5e6f031</li>
<li data-coords="6,2">734b547</li>
<li data-coords="7,2" data-labelPos="N">25803aa</li>
<li data-coords="8,2">60c0ff0</li>
<li data-coords="9,2" data-labelPos="E">70b8130</li>
<!--
Any additional stations will get cut off on the right side
-->
</ul>
</div>
<div id="legend"></div>
<script type="text/javascript">
$(".subway-map").subwayMap({ debug: true });
</script>
</body>
</html>

15
pelican/READ_THESE_INSTRUCTIONS.md

@ -1,15 +0,0 @@ @@ -1,15 +0,0 @@
# Read these instructions
The subway map materials are not on the `pelican` branch,
so you cannot make the `pelican` site without an extra step.
You will need to clone the `subway` branch to the `subway`
folder by executing the following command in the current
directory:
```
git clone -b subway https://git.charlesreid1.com/charlesreid1/git-subway-maps.git subway
```
Now the subway branch is located in the `subway/` folder,
and running `pelican content` will now generate the content.

62
pelican/pelicanconf.py

@ -1,62 +0,0 @@ @@ -1,62 +0,0 @@
#!/usr/bin/env python
import markdown
AUTHOR = 'charlesreid1'
SITENAME = 'Git Subway Maps'
SITEURL = ''
TIMEZONE = 'America/Los_Angeles'
DEFAULT_LANG = 'en'
PATH = 'content'
OUTPUT_PATH = 'output'
# --------------8<---------------------
# Theme
THEME = 'simple-bootstrap'
# --------------8<---------------------
# Files and content
# Don't try to turn HTML files into pages
READERS = {'html': None}
# This will look for a directory img/
# inside the directory content/
# The contents of img/ will be available at
# {{ SITEURL }}/img
STATIC_PATHS = ['img','css','vendor']
# --------------8<---------------------
# apps
EXTRA_TEMPLATES_PATHS = []
TEMPLATE_PAGES = {}
TEMPLATE_PAGES['index.html'] = 'index.html'
EXTRA_TEMPLATES_PATHS.append('subway')
TEMPLATE_PAGES['one_branch.html'] = 'one_branch.html'
TEMPLATE_PAGES['two_branches.html'] = 'two_branches.html'
TEMPLATE_PAGES['three_branches.html'] = 'three_branches.html'
TEMPLATE_PAGES['subway.css'] = 'subway.css'
TEMPLATE_PAGES['one_branch.css'] = 'one_branch.css'
TEMPLATE_PAGES['two_branches.css'] = 'two_branches.css'
TEMPLATE_PAGES['three_branches.css'] = 'three_branches.css'
TEMPLATE_PAGES['jquery-1.9.0.min.js'] = 'jquery-1.9.0.min.js'
TEMPLATE_PAGES['jquery.subwayMap-0.5.0.js'] = 'jquery.subwayMap-0.5.0.js'
# --------------8<---------------------
# idk just some dumb stuff
DISPLAY_PAGES_ON_MENU = False
FEED_ALL_ATOM = None
CATEGORY_FEED_ATOM = None
TRANSLATION_FEED_ATOM = None
AUTHOR_FEED_ATOM = None
AUTHOR_FEED_RSS = None
DEFAULT_PAGINATION = False

45
subway.css

@ -0,0 +1,45 @@ @@ -0,0 +1,45 @@
/**
* These styles are for all subway maps.
*/
body
{
font-family: Verdana;
font-size: 8pt;
}
/* The main DIV for the map */
.subway-map
{
margin: 0;
width: 500px;
height:300px;
background-color: white;
}
/* Text labels */
.text
{
text-decoration: none;
color: black;
}
#legend
{
float: left;
width: 250px;
height:400px;
}
#legend div
{
height: 25px;
}
#legend span
{
margin: 5px 5px 5px 0;
}
.subway-map span
{
margin: 5px 5px 5px 0;
}

34
tags.html

@ -0,0 +1,34 @@ @@ -0,0 +1,34 @@
<!DOCTYPE html>
<html>
<head>
<title>Tags</title>
<meta charset="utf-8" />
<link href="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css" rel="stylesheet" />
<link href="/theme/static/css/style.css" rel="stylesheet" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
</head>
<body id="index" class="archive">
<div class="container">
<div class="header">
<ul class="nav nav-pills pull-right">
<li class=""><a href="">Home</a></li>
<li class="active"><a href="/archives.html">Archives</a></li>
</ul>
<h3 class="text-muted"><a href="">Git Subway Maps</a></h3>
<h2 class="text-muted"></h2>
</div>
<ul class="tag">
</ul>
<footer id="contentinfo" class="footer">
<nav class="pull-right bottom-nav">
<a href="/None">RSS</a>
</nav>
<address id="about" class="vcard body">
&copy; <a href="">Git Subway Maps</a> Proudly powered by <a href="http://getpelican.com/">Pelican</a>
</address><!-- /#about -->
</footer><!-- /#contentinfo -->
</div><!-- container -->
</body>
</html>

177
theme/static/css/style.css

@ -0,0 +1,177 @@ @@ -0,0 +1,177 @@
/* Space out content a bit */
body {
padding-top: 20px;
}
/* Everything but the jumbotron gets side spacing for mobile first views */
.header,
.footer,
.content,
.comment {
padding-left: 5px;
padding-right: 5px;
}
.nav-pills{
display:none;
}
/* Custom page header */
.header {
border-bottom: 1px solid #e5e5e5;
}
/* Make the masthead heading the same height as the navigation */
.header h3 {
margin-top: 0;
margin-bottom: 0;
line-height: 40px;
padding-bottom: 19px;
}
/* Custom page footer */
.footer {
padding-top: 19px;
color: #777;
border-top: 1px solid #e5e5e5;
margin-top:40px;
}
/* Customize container */
@media (min-width: 768px) {
.container {
max-width: 730px;
}
}
.container-narrow > hr {
margin: 30px 0;
}
/* Main marketing message and sign up button */
.jumbotron {
text-align: center;
border-bottom: 1px solid #e5e5e5;
}
.jumbotron .btn {
font-size: 21px;
padding: 14px 24px;
}
/* Supporting marketing content */
.marketing {
margin: 40px 0;
}
.marketing p + h4 {
margin-top: 28px;
}
.header .text-muted a{
color:#999;
text-decoration:none;
}
.entry-content{
padding:5px 0 15px;;
line-height:1.8;
}
.hentry{
margin-bottom:18px;
}
.pager{
margin-bottom:30px;
}
.pager ul{
margin:0;
padding:0;
}
.post-info{
padding-bottom:30px;
}
.post-info address{
display:inline;
}
.comment{
padding-top:15px;
padding-bottom:15px;
}
.archive-list li{
font-size:16px;
margin-bottom:10px;
}
.bottom-nav{display:none;}
.bottom-nav a{margin-left:15px;}
/* code style */
.highlight { background-color: #ffffcc }
.c { color: #999988; font-style: italic } /* Comment */
.err { color: #a61717; background-color: #e3d2d2 } /* Error */
.k { color: #000000; font-weight: bold } /* Keyword */
.o { color: #000000; font-weight: bold } /* Operator */
.cm { color: #999988; font-style: italic } /* Comment.Multiline */
.cp { color: #999999; font-weight: bold; font-style: italic } /* Comment.Preproc */
.c1 { color: #999988; font-style: italic } /* Comment.Single */
.cs { color: #999999; font-weight: bold; font-style: italic } /* Comment.Special */
.gd { color: #000000; background-color: #ffdddd } /* Generic.Deleted */
.ge { color: #000000; font-style: italic } /* Generic.Emph */
.gr { color: #aa0000 } /* Generic.Error */
.gh { color: #999999 } /* Generic.Heading */
.gi { color: #000000; background-color: #ddffdd } /* Generic.Inserted */
.go { color: #888888 } /* Generic.Output */
.gp { color: #555555 } /* Generic.Prompt */
.gs { font-weight: bold } /* Generic.Strong */
.gu { color: #aaaaaa } /* Generic.Subheading */
.gt { color: #aa0000 } /* Generic.Traceback */
.kc { color: #000000; font-weight: bold } /* Keyword.Constant */
.kd { color: #000000; font-weight: bold } /* Keyword.Declaration */
.kn { color: #000000; font-weight: bold } /* Keyword.Namespace */
.kp { color: #000000; font-weight: bold } /* Keyword.Pseudo */
.kr { color: #000000; font-weight: bold } /* Keyword.Reserved */
.kt { color: #445588; font-weight: bold } /* Keyword.Type */
.m { color: #009999 } /* Literal.Number */
.s { color: #d01040 } /* Literal.String */
.na { color: #008080 } /* Name.Attribute */
.nb { color: #0086B3 } /* Name.Builtin */
.nc { color: #445588; font-weight: bold } /* Name.Class */
.no { color: #008080 } /* Name.Constant */
.nd { color: #3c5d5d; font-weight: bold } /* Name.Decorator */
.ni { color: #800080 } /* Name.Entity */
.ne { color: #990000; font-weight: bold } /* Name.Exception */
.nf { color: #990000; font-weight: bold } /* Name.Function */
.nl { color: #990000; font-weight: bold } /* Name.Label */
.nn { color: #555555 } /* Name.Namespace */
.nt { color: #000080 } /* Name.Tag */
.nv { color: #008080 } /* Name.Variable */
.ow { color: #000000; font-weight: bold } /* Operator.Word */
.w { color: #bbbbbb } /* Text.Whitespace */
.mf { color: #009999 } /* Literal.Number.Float */
.mh { color: #009999 } /* Literal.Number.Hex */
.mi { color: #009999 } /* Literal.Number.Integer */
.mo { color: #009999 } /* Literal.Number.Oct */
.sb { color: #d01040 } /* Literal.String.Backtick */
.sc { color: #d01040 } /* Literal.String.Char */
.sd { color: #d01040 } /* Literal.String.Doc */
.s2 { color: #d01040 } /* Literal.String.Double */
.se { color: #d01040 } /* Literal.String.Escape */
.sh { color: #d01040 } /* Literal.String.Heredoc */
.si { color: #d01040 } /* Literal.String.Interpol */
.sx { color: #d01040 } /* Literal.String.Other */
.sr { color: #009926 } /* Literal.String.Regex */
.s1 { color: #d01040 } /* Literal.String.Single */
.ss { color: #990073 } /* Literal.String.Symbol */
.bp { color: #999999 } /* Name.Builtin.Pseudo */
.vc { color: #008080 } /* Name.Variable.Class */
.vg { color: #008080 } /* Name.Variable.Global */
.vi { color: #008080 } /* Name.Variable.Instance */
.il { color: #009999 } /* Literal.Number.Integer.Long */
/* Responsive: Portrait tablets and up */
@media screen and (min-width: 768px) {
/* Remove the padding we set earlier */
.header,
.content,
.footer,
.comment {
padding-left: 0;
padding-right: 0;
}
/* Space out the masthead */
.header {
margin-bottom: 30px;
}
.nav-pills,.bottom-nav{
display:block;
}
}

79
theme/style.css

@ -0,0 +1,79 @@ @@ -0,0 +1,79 @@
/* Space out content a bit */
body {
padding-top: 20px;
padding-bottom: 20px;
}
/* Everything but the jumbotron gets side spacing for mobile first views */
.header,
.marketing,
.footer {
padding-left: 15px;
padding-right: 15px;
}
/* Custom page header */
.header {
border-bottom: 1px solid #e5e5e5;
}
/* Make the masthead heading the same height as the navigation */
.header h3 {
margin-top: 0;
margin-bottom: 0;
line-height: 40px;
padding-bottom: 19px;
}
/* Custom page footer */
.footer {
padding-top: 19px;
color: #777;
border-top: 1px solid #e5e5e5;
}
/* Customize container */
@media (min-width: 768px) {
.container {
max-width: 730px;
}
}
.container-narrow > hr {
margin: 30px 0;
}
/* Main marketing message and sign up button */
.jumbotron {
text-align: center;
border-bottom: 1px solid #e5e5e5;
}
.jumbotron .btn {
font-size: 21px;
padding: 14px 24px;
}
/* Supporting marketing content */
.marketing {
margin: 40px 0;
}
.marketing p + h4 {
margin-top: 28px;
}
/* Responsive: Portrait tablets and up */
@media screen and (min-width: 768px) {
/* Remove the padding we set earlier */
.header,
.marketing,
.footer {
padding-left: 0;
padding-right: 0;
}
/* Space out the masthead */
.header {
margin-bottom: 30px;
}
/* Remove the bottom border on the jumbotron for visual effect */
.jumbotron {
border-bottom: 0;
}
}

14
three_branches.css

@ -0,0 +1,14 @@ @@ -0,0 +1,14 @@
/**
* These styles are for two-branch maps.
*/
.subway-map
{
margin: 0;
width: 500px;
height: 500px;
background-color: white;
}
div#legend {
margin-left: 50px;
}

50
three_branches.html

@ -0,0 +1,50 @@ @@ -0,0 +1,50 @@
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Git Map</title>
<script type="text/javascript" src="jquery-1.9.0.min.js"></script>
<script type="text/javascript" src="jquery.subwayMap-0.5.0.js"></script>
<link href="subway.css" rel="stylesheet">
<link href="two_branches.css" rel="stylesheet">
</head>
<body>
<div class="subway-map" data-columns="15" data-rows="10" data-cellSize="45"
data-legendId="legend" data-textClass="text" data-gridNumbers="true"
data-grid="false" data-lineWidth="8">
<ul data-color="#00edac" data-label="master">
<li data-coords="2,5" data-labelPos="W" data-marker="interchange">c384c87</li>
<li data-coords="3,5" data-labelPos="N">13c4011</li>
<li data-coords="4,5">f5cede7</li>
<li data-coords="5,4" data-labelPos="N">f0f0ef6</li>
<li data-coords="6,4">8c0cb2c</li>
<li data-coords="7,4" data-labelPos="N">18a3d79</li>
<li data-coords="8,4">457d019</li>
</ul>
<ul data-color="#ac00ed" data-label="bugfix">
<li data-coords="5,4" data-labelPos="N" data-marker="interchange"></li>
<li data-coords="6,3" data-labelPos="N">bb1341a</li>
<li data-coords="8,3" data-labelPos="N">ef86851</li>
<li data-coords="10,3" data-labelPos="N">a88eef0</li>
<li data-coords="12,3" data-labelPos="N">11510b2</li>
</ul>
<ul data-color="#00aced" data-label="feature">
<li data-coords="4,5">f5cede7</li>
<li data-coords="5,6" data-dir="S">c384c87</li>
<li data-coords="6,6" data-dir="N" data-labelPos="N">57de4f4</li>
<li data-coords="7,6" data-dir="E">2576472</li>
<li data-coords="8,6" data-labelPos="N">13c4011</li>
<li data-coords="9,6">e5e8a5f</li>
<li data-coords="10,6" data-labelPos="N">ab317eb</li>
<li data-coords="11,6">01cd690</li>
<li data-coords="12,6" data-labelPos="N">33876fb</li>
</ul>
</div>
<div id="legend"></div>
<script type="text/javascript">
$(".subway-map").subwayMap({ debug: true });
</script>
</body>
</html>

14
two_branches.css

@ -0,0 +1,14 @@ @@ -0,0 +1,14 @@
/**
* These styles are for two-branch maps.
*/
.subway-map
{
margin: 0;
width: 500px;
height: 350px;
background-color: white;
}
div#legend {
margin-left: 50px;
}

44
two_branches.html

@ -0,0 +1,44 @@ @@ -0,0 +1,44 @@
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Git Map</title>
<script type="text/javascript" src="jquery-1.9.0.min.js"></script>
<script type="text/javascript" src="jquery.subwayMap-0.5.0.js"></script>
<link href="subway.css" rel="stylesheet">
<link href="two_branches.css" rel="stylesheet">
</head>
<body>
<div class="subway-map" data-columns="10" data-rows="5" data-cellSize="60"
data-legendId="legend" data-textClass="text" data-gridNumbers="true"
data-grid="false" data-lineWidth="8">
<ul data-color="#aced00" data-label="master">
<li data-coords="2,3" data-labelPos="W" data-marker="interchange">c384c87</li>
<li data-coords="3,2" data-dir="N">57de4f4</li>
<li data-coords="4,2" data-dir="E">2576472</li>
<li data-coords="5,2">13c4011</li>
<li data-coords="6,2">f5cede7</li>
<li data-coords="7,2">3f79bc0</li>
<li data-coords="8,2">64ca124</li>
<li data-coords="9,2" data-labelPos="E">c047ced</li>
</ul>
<ul data-color="#00aced" data-label="development">
<li data-coords="2,3" data-marker="interchange"></li>
<li data-coords="3,4" data-dir="S">15343a2</li>
<li data-coords="4,4" data-dir="E">e6fa816</li>
<li data-coords="5,4">874b8ba</li>
<li data-coords="6,4">ee3d025</li>
<li data-coords="7,4">3e822fe</li>
<li data-coords="8,4">a6c2089</li>
<li data-coords="9,4" data-labelPos="E">9cd4434</li>
<!--
Any additional stations will get cut off on the right side
-->
</ul>
</div>
<div id="legend"></div>
<script type="text/javascript">
$(".subway-map").subwayMap({ debug: true });
</script>
</body>
</html>

0
pelican/content/vendor/bootstrap/css/bootstrap.min.css → vendor/bootstrap/css/bootstrap.min.css vendored

0
pelican/content/vendor/bootstrap/js/bootstrap.bundle.min.js → vendor/bootstrap/js/bootstrap.bundle.min.js vendored

0
pelican/content/vendor/bootstrap/js/bootstrap.min.js → vendor/bootstrap/js/bootstrap.min.js vendored

0
pelican/content/vendor/jquery/jquery.min.js → vendor/jquery/jquery.min.js vendored

0
pelican/content/vendor/jquery/jquery.slim.min.js → vendor/jquery/jquery.slim.min.js vendored

Loading…
Cancel
Save