aboutsummaryrefslogtreecommitdiff
path: root/tools/template.html
blob: 89eddd2b50133e07c23097a50b54104d803d465d (plain)
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>$title$</title>
  6. <style type="text/css">
  7. body { font-family: Helvetica, arial, freesans, clean, sans-serif;
  8. line-height: 1.4;
  9. max-width: 48em;
  10. margin: auto;
  11. padding: 0 0.5em 4em;
  12. color: #333333;
  13. background-color: #ffffff;
  14. font-size: 13pt;
  15. }
  16. div#TOC ul { list-style: none; }
  17. h1 { font-size: 140%; font-weight: bold; border-top: 1px solid gray; padding-top: 0.5em; }
  18. h2 { font-size: 120%; font-weight: bold; }
  19. h3 { font-size: 110%; font-weight: bold; }
  20. h4 { font-size: 100%; font-weight: bold; }
  21. a.definition { font-weight: bold; }
  22. span.space { position: relative; }
  23. span.number:after { content: "  " }
  24. span.space:after {
  25. content: "·";
  26. position: absolute;
  27. /* create a mark that indicates a space (trick from D. Greenspan) */
  28. top: 0; bottom: 7px; left: 1px; right: 1px;
  29. color: #aaaaaa;
  30. }
  31. div.example { overflow: hidden; }
  32. p { text-align: justify; }
  33. pre { padding: 0.5em; margin: 0.2em 0 0.5em; font-size: 88%; }
  34. pre {
  35. white-space: pre-wrap; /* css-3 */
  36. white-space: -moz-pre-wrap; /* Mozilla, since 1999 */
  37. white-space: -pre-wrap; /* Opera 4-6 */
  38. white-space: -o-pre-wrap; /* Opera 7 */
  39. word-wrap: break-word; /* Internet Explorer 5.5+ */
  40. }
  41. code { font-family: monospace; background-color: #d3e1e4; }
  42. pre > code { background-color: transparent; }
  43. .example { font-size: 0; /* hack to get width: 50% to work on inline-block */
  44. padding-bottom: 6pt; }
  45. .column pre { font-size: 11pt; padding: 2pt 6pt; }
  46. div.examplenum { font-size: 11pt; text-align: left; margin-bottom: 10px; }
  47. div.column { display: inline-block; width: 50%; vertical-align: top; }
  48. div.example > div:nth-child(2) { clear:left; background-color: #d3e1e4; }
  49. div.example > div:nth-child(3) { clear:right; background-color: #c9cace; }
  50. #watermark {
  51. position: fixed;
  52. bottom: 0;
  53. left: 0;
  54. padding: 1em;
  55. width: 100%;
  56. font-size: 120%;
  57. opacity: 0.7;
  58. z-index: 99;
  59. color: white;
  60. }
  61. #watermark a { color: white; }
  62. a.dingus {
  63. margin-left: 1em;
  64. cursor: pointer;
  65. line-height: 30px;
  66. padding: 4px 7px;
  67. color: #ffffff;
  68. background-color: #33c3f0;
  69. box-shadow: 2px 2px 2px rgba(0, 0, 0, .2);
  70. border-color: #4fcaef;
  71. border-bottom: 2px #2a9ec1 solid;
  72. border-right: 2px #2a9ec1 solid;
  73. }
  74. a.footnoteRef > sup:before {
  75. content: "[";
  76. }
  77. a.footnoteRef > sup:after {
  78. content: "]";
  79. }
  80. a.footnoteRef > sup {
  81. vertical-align: baseline;
  82. font-size: 100%;
  83. }
  84. @media print {
  85. @page {
  86. size: auto;
  87. margin: 1.2in 1.2in 1.2in 1.2in;
  88. }
  89. body {
  90. margin: 0;
  91. line-height: 1.2;
  92. font-size: 10pt;
  93. }
  94. .column pre { font-size: 9pt; }
  95. div.examplenum { font-size: 9pt; }
  96. a.dingus { display: none; }
  97. }
  98. </style>
  99. <script src="https://code.jquery.com/jquery-2.2.0.min.js"></script>
  100. <script type="text/javascript">
  101. $$(document).ready(function() {
  102. $$("div.example").each(function(e) {
  103. var t = $$(this).find('code.language-markdown').text();
  104. $$(this).find('a.dingus').click(function(f) {
  105. window.open('/dingus/?text=' +
  106. encodeURIComponent(t.replace(/→/g,"\t")));
  107. });
  108. });
  109. $$("code.language-markdown").dblclick(function(e) { window.open('/dingus/?text=' +
  110. encodeURIComponent($$(this).text()));
  111. });
  112. });
  113. </script>
  114. </head>
  115. <body>
  116. <h1 class="title">$title$</h1>
  117. <div class="version">Version $version$ ($date$)</div>
  118. <div class="authors">
  119. <span class="author">$author$</span>
  120. </div>
  121. <div class="license">
  122. <a rel="license"
  123. href="http://creativecommons.org/licenses/by-sa/4.0/"><img alt="Creative
  124. Commons BY-SA" style="border-width: 0;"
  125. src="https://i.creativecommons.org/l/by-sa/4.0/80x15.png"
  126. /></a><br/><span style="display: none;"><span xmlns:dct="http://purl.org/dc/terms/"
  127. href="http://purl.org/dc/dcmitype/Text" property="dct:title"
  128. rel="dct:type">CommonMark Spec</span> by
  129. <a xmlns:cc="http://creativecommons.org/ns#"
  130. href="http://spec.commonmark.org" property="cc:attributionName"
  131. rel="cc:attributionURL">John MacFarlane</a> is licensed under a
  132. <a rel="license"
  133. href="http://creativecommons.org/licenses/by-sa/4.0/">Creative
  134. Commons Attribution-ShareAlike 4.0 International License</a>.</span>
  135. </div>
  136. <div id="watermark"></div>
  137. <div id="TOC">
  138. $toc$
  139. </div>
  140. $body$
  141. </body>
  142. </html>