gitlab-rdoc 6.3.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (196) hide show
  1. checksums.yaml +7 -0
  2. data/CONTRIBUTING.rdoc +220 -0
  3. data/CVE-2013-0256.rdoc +49 -0
  4. data/ExampleMarkdown.md +37 -0
  5. data/ExampleRDoc.rdoc +208 -0
  6. data/Gemfile +12 -0
  7. data/History.rdoc +1666 -0
  8. data/LEGAL.rdoc +50 -0
  9. data/LICENSE.rdoc +57 -0
  10. data/README.rdoc +133 -0
  11. data/RI.rdoc +57 -0
  12. data/Rakefile +101 -0
  13. data/TODO.rdoc +59 -0
  14. data/bin/console +7 -0
  15. data/bin/setup +6 -0
  16. data/exe/rdoc +44 -0
  17. data/exe/ri +12 -0
  18. data/lib/rdoc/alias.rb +112 -0
  19. data/lib/rdoc/anon_class.rb +11 -0
  20. data/lib/rdoc/any_method.rb +361 -0
  21. data/lib/rdoc/attr.rb +176 -0
  22. data/lib/rdoc/class_module.rb +802 -0
  23. data/lib/rdoc/code_object.rb +421 -0
  24. data/lib/rdoc/code_objects.rb +6 -0
  25. data/lib/rdoc/comment.rb +250 -0
  26. data/lib/rdoc/constant.rb +187 -0
  27. data/lib/rdoc/context/section.rb +232 -0
  28. data/lib/rdoc/context.rb +1266 -0
  29. data/lib/rdoc/cross_reference.rb +202 -0
  30. data/lib/rdoc/encoding.rb +136 -0
  31. data/lib/rdoc/erb_partial.rb +19 -0
  32. data/lib/rdoc/erbio.rb +42 -0
  33. data/lib/rdoc/extend.rb +10 -0
  34. data/lib/rdoc/generator/darkfish.rb +790 -0
  35. data/lib/rdoc/generator/json_index.rb +300 -0
  36. data/lib/rdoc/generator/markup.rb +160 -0
  37. data/lib/rdoc/generator/pot/message_extractor.rb +68 -0
  38. data/lib/rdoc/generator/pot/po.rb +84 -0
  39. data/lib/rdoc/generator/pot/po_entry.rb +141 -0
  40. data/lib/rdoc/generator/pot.rb +98 -0
  41. data/lib/rdoc/generator/ri.rb +31 -0
  42. data/lib/rdoc/generator/template/darkfish/.document +0 -0
  43. data/lib/rdoc/generator/template/darkfish/_footer.rhtml +5 -0
  44. data/lib/rdoc/generator/template/darkfish/_head.rhtml +22 -0
  45. data/lib/rdoc/generator/template/darkfish/_sidebar_VCS_info.rhtml +19 -0
  46. data/lib/rdoc/generator/template/darkfish/_sidebar_classes.rhtml +9 -0
  47. data/lib/rdoc/generator/template/darkfish/_sidebar_extends.rhtml +15 -0
  48. data/lib/rdoc/generator/template/darkfish/_sidebar_in_files.rhtml +9 -0
  49. data/lib/rdoc/generator/template/darkfish/_sidebar_includes.rhtml +15 -0
  50. data/lib/rdoc/generator/template/darkfish/_sidebar_installed.rhtml +15 -0
  51. data/lib/rdoc/generator/template/darkfish/_sidebar_methods.rhtml +12 -0
  52. data/lib/rdoc/generator/template/darkfish/_sidebar_navigation.rhtml +11 -0
  53. data/lib/rdoc/generator/template/darkfish/_sidebar_pages.rhtml +12 -0
  54. data/lib/rdoc/generator/template/darkfish/_sidebar_parent.rhtml +11 -0
  55. data/lib/rdoc/generator/template/darkfish/_sidebar_search.rhtml +14 -0
  56. data/lib/rdoc/generator/template/darkfish/_sidebar_sections.rhtml +11 -0
  57. data/lib/rdoc/generator/template/darkfish/_sidebar_table_of_contents.rhtml +18 -0
  58. data/lib/rdoc/generator/template/darkfish/class.rhtml +172 -0
  59. data/lib/rdoc/generator/template/darkfish/css/fonts.css +167 -0
  60. data/lib/rdoc/generator/template/darkfish/css/rdoc.css +639 -0
  61. data/lib/rdoc/generator/template/darkfish/fonts/Lato-Light.ttf +0 -0
  62. data/lib/rdoc/generator/template/darkfish/fonts/Lato-LightItalic.ttf +0 -0
  63. data/lib/rdoc/generator/template/darkfish/fonts/Lato-Regular.ttf +0 -0
  64. data/lib/rdoc/generator/template/darkfish/fonts/Lato-RegularItalic.ttf +0 -0
  65. data/lib/rdoc/generator/template/darkfish/fonts/SourceCodePro-Bold.ttf +0 -0
  66. data/lib/rdoc/generator/template/darkfish/fonts/SourceCodePro-Regular.ttf +0 -0
  67. data/lib/rdoc/generator/template/darkfish/images/add.png +0 -0
  68. data/lib/rdoc/generator/template/darkfish/images/arrow_up.png +0 -0
  69. data/lib/rdoc/generator/template/darkfish/images/brick.png +0 -0
  70. data/lib/rdoc/generator/template/darkfish/images/brick_link.png +0 -0
  71. data/lib/rdoc/generator/template/darkfish/images/bug.png +0 -0
  72. data/lib/rdoc/generator/template/darkfish/images/bullet_black.png +0 -0
  73. data/lib/rdoc/generator/template/darkfish/images/bullet_toggle_minus.png +0 -0
  74. data/lib/rdoc/generator/template/darkfish/images/bullet_toggle_plus.png +0 -0
  75. data/lib/rdoc/generator/template/darkfish/images/date.png +0 -0
  76. data/lib/rdoc/generator/template/darkfish/images/delete.png +0 -0
  77. data/lib/rdoc/generator/template/darkfish/images/find.png +0 -0
  78. data/lib/rdoc/generator/template/darkfish/images/loadingAnimation.gif +0 -0
  79. data/lib/rdoc/generator/template/darkfish/images/macFFBgHack.png +0 -0
  80. data/lib/rdoc/generator/template/darkfish/images/package.png +0 -0
  81. data/lib/rdoc/generator/template/darkfish/images/page_green.png +0 -0
  82. data/lib/rdoc/generator/template/darkfish/images/page_white_text.png +0 -0
  83. data/lib/rdoc/generator/template/darkfish/images/page_white_width.png +0 -0
  84. data/lib/rdoc/generator/template/darkfish/images/plugin.png +0 -0
  85. data/lib/rdoc/generator/template/darkfish/images/ruby.png +0 -0
  86. data/lib/rdoc/generator/template/darkfish/images/tag_blue.png +0 -0
  87. data/lib/rdoc/generator/template/darkfish/images/tag_green.png +0 -0
  88. data/lib/rdoc/generator/template/darkfish/images/transparent.png +0 -0
  89. data/lib/rdoc/generator/template/darkfish/images/wrench.png +0 -0
  90. data/lib/rdoc/generator/template/darkfish/images/wrench_orange.png +0 -0
  91. data/lib/rdoc/generator/template/darkfish/images/zoom.png +0 -0
  92. data/lib/rdoc/generator/template/darkfish/index.rhtml +22 -0
  93. data/lib/rdoc/generator/template/darkfish/js/darkfish.js +84 -0
  94. data/lib/rdoc/generator/template/darkfish/js/search.js +110 -0
  95. data/lib/rdoc/generator/template/darkfish/page.rhtml +18 -0
  96. data/lib/rdoc/generator/template/darkfish/servlet_not_found.rhtml +18 -0
  97. data/lib/rdoc/generator/template/darkfish/servlet_root.rhtml +62 -0
  98. data/lib/rdoc/generator/template/darkfish/table_of_contents.rhtml +58 -0
  99. data/lib/rdoc/generator/template/json_index/.document +1 -0
  100. data/lib/rdoc/generator/template/json_index/js/navigation.js +105 -0
  101. data/lib/rdoc/generator/template/json_index/js/searcher.js +229 -0
  102. data/lib/rdoc/generator.rb +51 -0
  103. data/lib/rdoc/ghost_method.rb +7 -0
  104. data/lib/rdoc/i18n/locale.rb +102 -0
  105. data/lib/rdoc/i18n/text.rb +126 -0
  106. data/lib/rdoc/i18n.rb +10 -0
  107. data/lib/rdoc/include.rb +10 -0
  108. data/lib/rdoc/known_classes.rb +73 -0
  109. data/lib/rdoc/markdown/entities.rb +2132 -0
  110. data/lib/rdoc/markdown/literals.kpeg +23 -0
  111. data/lib/rdoc/markdown/literals.rb +417 -0
  112. data/lib/rdoc/markdown.kpeg +1237 -0
  113. data/lib/rdoc/markdown.rb +16685 -0
  114. data/lib/rdoc/markup/attr_changer.rb +23 -0
  115. data/lib/rdoc/markup/attr_span.rb +36 -0
  116. data/lib/rdoc/markup/attribute_manager.rb +409 -0
  117. data/lib/rdoc/markup/attributes.rb +71 -0
  118. data/lib/rdoc/markup/blank_line.rb +28 -0
  119. data/lib/rdoc/markup/block_quote.rb +15 -0
  120. data/lib/rdoc/markup/document.rb +165 -0
  121. data/lib/rdoc/markup/formatter.rb +266 -0
  122. data/lib/rdoc/markup/hard_break.rb +32 -0
  123. data/lib/rdoc/markup/heading.rb +79 -0
  124. data/lib/rdoc/markup/include.rb +43 -0
  125. data/lib/rdoc/markup/indented_paragraph.rb +48 -0
  126. data/lib/rdoc/markup/list.rb +102 -0
  127. data/lib/rdoc/markup/list_item.rb +100 -0
  128. data/lib/rdoc/markup/paragraph.rb +29 -0
  129. data/lib/rdoc/markup/parser.rb +575 -0
  130. data/lib/rdoc/markup/pre_process.rb +296 -0
  131. data/lib/rdoc/markup/raw.rb +70 -0
  132. data/lib/rdoc/markup/regexp_handling.rb +41 -0
  133. data/lib/rdoc/markup/rule.rb +21 -0
  134. data/lib/rdoc/markup/table.rb +47 -0
  135. data/lib/rdoc/markup/to_ansi.rb +94 -0
  136. data/lib/rdoc/markup/to_bs.rb +77 -0
  137. data/lib/rdoc/markup/to_html.rb +444 -0
  138. data/lib/rdoc/markup/to_html_crossref.rb +176 -0
  139. data/lib/rdoc/markup/to_html_snippet.rb +285 -0
  140. data/lib/rdoc/markup/to_joined_paragraph.rb +47 -0
  141. data/lib/rdoc/markup/to_label.rb +75 -0
  142. data/lib/rdoc/markup/to_markdown.rb +192 -0
  143. data/lib/rdoc/markup/to_rdoc.rb +362 -0
  144. data/lib/rdoc/markup/to_table_of_contents.rb +89 -0
  145. data/lib/rdoc/markup/to_test.rb +70 -0
  146. data/lib/rdoc/markup/to_tt_only.rb +121 -0
  147. data/lib/rdoc/markup/verbatim.rb +84 -0
  148. data/lib/rdoc/markup.rb +867 -0
  149. data/lib/rdoc/meta_method.rb +7 -0
  150. data/lib/rdoc/method_attr.rb +419 -0
  151. data/lib/rdoc/mixin.rb +121 -0
  152. data/lib/rdoc/normal_class.rb +93 -0
  153. data/lib/rdoc/normal_module.rb +74 -0
  154. data/lib/rdoc/options.rb +1285 -0
  155. data/lib/rdoc/parser/c.rb +1225 -0
  156. data/lib/rdoc/parser/changelog.rb +335 -0
  157. data/lib/rdoc/parser/markdown.rb +24 -0
  158. data/lib/rdoc/parser/rd.rb +23 -0
  159. data/lib/rdoc/parser/ripper_state_lex.rb +590 -0
  160. data/lib/rdoc/parser/ruby.rb +2327 -0
  161. data/lib/rdoc/parser/ruby_tools.rb +167 -0
  162. data/lib/rdoc/parser/simple.rb +61 -0
  163. data/lib/rdoc/parser/text.rb +12 -0
  164. data/lib/rdoc/parser.rb +277 -0
  165. data/lib/rdoc/rd/block_parser.rb +1056 -0
  166. data/lib/rdoc/rd/block_parser.ry +639 -0
  167. data/lib/rdoc/rd/inline.rb +72 -0
  168. data/lib/rdoc/rd/inline_parser.rb +1208 -0
  169. data/lib/rdoc/rd/inline_parser.ry +593 -0
  170. data/lib/rdoc/rd.rb +100 -0
  171. data/lib/rdoc/rdoc.rb +579 -0
  172. data/lib/rdoc/require.rb +52 -0
  173. data/lib/rdoc/ri/driver.rb +1572 -0
  174. data/lib/rdoc/ri/formatter.rb +6 -0
  175. data/lib/rdoc/ri/paths.rb +171 -0
  176. data/lib/rdoc/ri/store.rb +7 -0
  177. data/lib/rdoc/ri/task.rb +71 -0
  178. data/lib/rdoc/ri.rb +21 -0
  179. data/lib/rdoc/rubygems_hook.rb +246 -0
  180. data/lib/rdoc/servlet.rb +451 -0
  181. data/lib/rdoc/single_class.rb +26 -0
  182. data/lib/rdoc/stats/normal.rb +58 -0
  183. data/lib/rdoc/stats/quiet.rb +60 -0
  184. data/lib/rdoc/stats/verbose.rb +46 -0
  185. data/lib/rdoc/stats.rb +462 -0
  186. data/lib/rdoc/store.rb +979 -0
  187. data/lib/rdoc/task.rb +329 -0
  188. data/lib/rdoc/text.rb +304 -0
  189. data/lib/rdoc/token_stream.rb +119 -0
  190. data/lib/rdoc/tom_doc.rb +263 -0
  191. data/lib/rdoc/top_level.rb +289 -0
  192. data/lib/rdoc/version.rb +8 -0
  193. data/lib/rdoc.rb +201 -0
  194. data/man/ri.1 +247 -0
  195. data/rdoc.gemspec +249 -0
  196. metadata +279 -0
@@ -0,0 +1,22 @@
1
+ <body id="top" role="document" class="file">
2
+ <nav role="navigation">
3
+ <div id="project-navigation">
4
+ <%= render '_sidebar_navigation.rhtml' %>
5
+
6
+ <%= render '_sidebar_search.rhtml' %>
7
+ </div>
8
+
9
+ <div id="project-metadata">
10
+ <%= render '_sidebar_pages.rhtml' %>
11
+ <%= render '_sidebar_classes.rhtml' %>
12
+ </div>
13
+ </nav>
14
+
15
+ <main role="main">
16
+ <%- if @options.main_page and
17
+ main_page = @files.find { |f| f.full_name == @options.main_page } then %>
18
+ <%= main_page.description %>
19
+ <%- else -%>
20
+ <p>This is the API documentation for <%= @title %>.
21
+ <%- end -%>
22
+ </main>
@@ -0,0 +1,84 @@
1
+ /**
2
+ *
3
+ * Darkfish Page Functions
4
+ * $Id: darkfish.js 53 2009-01-07 02:52:03Z deveiant $
5
+ *
6
+ * Author: Michael Granger <mgranger@laika.com>
7
+ *
8
+ */
9
+
10
+ /* Provide console simulation for firebug-less environments */
11
+ /*
12
+ if (!("console" in window) || !("firebug" in console)) {
13
+ var names = ["log", "debug", "info", "warn", "error", "assert", "dir", "dirxml",
14
+ "group", "groupEnd", "time", "timeEnd", "count", "trace", "profile", "profileEnd"];
15
+
16
+ window.console = {};
17
+ for (var i = 0; i < names.length; ++i)
18
+ window.console[names[i]] = function() {};
19
+ };
20
+ */
21
+
22
+
23
+ function showSource( e ) {
24
+ var target = e.target;
25
+ while (!target.classList.contains('method-detail')) {
26
+ target = target.parentNode;
27
+ }
28
+ if (typeof target !== "undefined" && target !== null) {
29
+ target = target.querySelector('.method-source-code');
30
+ }
31
+ if (typeof target !== "undefined" && target !== null) {
32
+ target.classList.toggle('active-menu')
33
+ }
34
+ };
35
+
36
+ function hookSourceViews() {
37
+ document.querySelectorAll('.method-heading').forEach(function (codeObject) {
38
+ codeObject.addEventListener('click', showSource);
39
+ });
40
+ };
41
+
42
+ function hookSearch() {
43
+ var input = document.querySelector('#search-field');
44
+ var result = document.querySelector('#search-results');
45
+ result.classList.remove("initially-hidden");
46
+
47
+ var search_section = document.querySelector('#search-section');
48
+ search_section.classList.remove("initially-hidden");
49
+
50
+ var search = new Search(search_data, input, result);
51
+
52
+ search.renderItem = function(result) {
53
+ var li = document.createElement('li');
54
+ var html = '';
55
+
56
+ // TODO add relative path to <script> per-page
57
+ html += '<p class="search-match"><a href="' + index_rel_prefix + result.path + '">' + this.hlt(result.title);
58
+ if (result.params)
59
+ html += '<span class="params">' + result.params + '</span>';
60
+ html += '</a>';
61
+
62
+
63
+ if (result.namespace)
64
+ html += '<p class="search-namespace">' + this.hlt(result.namespace);
65
+
66
+ if (result.snippet)
67
+ html += '<div class="search-snippet">' + result.snippet + '</div>';
68
+
69
+ li.innerHTML = html;
70
+
71
+ return li;
72
+ }
73
+
74
+ search.select = function(result) {
75
+ window.location.href = result.firstChild.firstChild.href;
76
+ }
77
+
78
+ search.scrollIntoView = search.scrollInWindow;
79
+ };
80
+
81
+ document.addEventListener('DOMContentLoaded', function() {
82
+ hookSourceViews();
83
+ hookSearch();
84
+ });
@@ -0,0 +1,110 @@
1
+ Search = function(data, input, result) {
2
+ this.data = data;
3
+ this.input = input;
4
+ this.result = result;
5
+
6
+ this.current = null;
7
+ this.view = this.result.parentNode;
8
+ this.searcher = new Searcher(data.index);
9
+ this.init();
10
+ }
11
+
12
+ Search.prototype = Object.assign({}, Navigation, new function() {
13
+ var suid = 1;
14
+
15
+ this.init = function() {
16
+ var _this = this;
17
+ var observer = function(e) {
18
+ switch(e.keyCode) {
19
+ case 38: // Event.KEY_UP
20
+ case 40: // Event.KEY_DOWN
21
+ return;
22
+ }
23
+ _this.search(_this.input.value);
24
+ };
25
+ this.input.addEventListener('keyup', observer);
26
+ this.input.addEventListener('click', observer); // mac's clear field
27
+
28
+ this.searcher.ready(function(results, isLast) {
29
+ _this.addResults(results, isLast);
30
+ })
31
+
32
+ this.initNavigation();
33
+ this.setNavigationActive(false);
34
+ }
35
+
36
+ this.search = function(value, selectFirstMatch) {
37
+ value = value.trim().toLowerCase();
38
+ if (value) {
39
+ this.setNavigationActive(true);
40
+ } else {
41
+ this.setNavigationActive(false);
42
+ }
43
+
44
+ if (value == '') {
45
+ this.lastQuery = value;
46
+ this.result.innerHTML = '';
47
+ this.result.setAttribute('aria-expanded', 'false');
48
+ this.setNavigationActive(false);
49
+ } else if (value != this.lastQuery) {
50
+ this.lastQuery = value;
51
+ this.result.setAttribute('aria-busy', 'true');
52
+ this.result.setAttribute('aria-expanded', 'true');
53
+ this.firstRun = true;
54
+ this.searcher.find(value);
55
+ }
56
+ }
57
+
58
+ this.addResults = function(results, isLast) {
59
+ var target = this.result;
60
+ if (this.firstRun && (results.length > 0 || isLast)) {
61
+ this.current = null;
62
+ this.result.innerHTML = '';
63
+ }
64
+
65
+ for (var i=0, l = results.length; i < l; i++) {
66
+ var item = this.renderItem.call(this, results[i]);
67
+ item.setAttribute('id', 'search-result-' + target.childElementCount);
68
+ target.appendChild(item);
69
+ };
70
+
71
+ if (this.firstRun && results.length > 0) {
72
+ this.firstRun = false;
73
+ this.current = target.firstChild;
74
+ this.current.classList.add('search-selected');
75
+ }
76
+ //TODO: ECMAScript
77
+ //if (jQuery.browser.msie) this.$element[0].className += '';
78
+
79
+ if (isLast) this.result.setAttribute('aria-busy', 'false');
80
+ }
81
+
82
+ this.move = function(isDown) {
83
+ if (!this.current) return;
84
+ var next = isDown ? this.current.nextElementSibling : this.current.previousElementSibling;
85
+ if (next) {
86
+ this.current.classList.remove('search-selected');
87
+ next.classList.add('search-selected');
88
+ this.input.setAttribute('aria-activedescendant', next.getAttribute('id'));
89
+ this.scrollIntoView(next, this.view);
90
+ this.current = next;
91
+ this.input.value = next.firstChild.firstChild.text;
92
+ this.input.select();
93
+ }
94
+ return true;
95
+ }
96
+
97
+ this.hlt = function(html) {
98
+ return this.escapeHTML(html).
99
+ replace(/\u0001/g, '<em>').
100
+ replace(/\u0002/g, '</em>');
101
+ }
102
+
103
+ this.escapeHTML = function(html) {
104
+ return html.replace(/[&<>]/g, function(c) {
105
+ return '&#' + c.charCodeAt(0) + ';';
106
+ });
107
+ }
108
+
109
+ });
110
+
@@ -0,0 +1,18 @@
1
+ <body id="top" role="document" class="file">
2
+ <nav role="navigation">
3
+ <div id="project-navigation">
4
+ <%= render '_sidebar_navigation.rhtml' %>
5
+ <%= render '_sidebar_search.rhtml' %>
6
+ </div>
7
+
8
+ <%= render '_sidebar_table_of_contents.rhtml' %>
9
+
10
+ <div id="project-metadata">
11
+ <%= render '_sidebar_pages.rhtml' %>
12
+ </div>
13
+ </nav>
14
+
15
+ <main role="main" aria-label="Page <%=h file.full_name%>">
16
+ <%= file.description %>
17
+ </main>
18
+
@@ -0,0 +1,18 @@
1
+ <body role="document">
2
+ <nav role="navigation">
3
+ <%= render '_sidebar_navigation.rhtml' %>
4
+
5
+ <%= render '_sidebar_search.rhtml' %>
6
+
7
+ <div id="project-metadata">
8
+ <%= render '_sidebar_pages.rhtml' %>
9
+ <%= render '_sidebar_classes.rhtml' %>
10
+ </div>
11
+ </nav>
12
+
13
+ <main role="main">
14
+ <h1>Not Found</h1>
15
+
16
+ <p><%= message %>
17
+ </main>
18
+
@@ -0,0 +1,62 @@
1
+ <body role="document">
2
+ <nav role="navigation">
3
+ <div id="project-navigation">
4
+ <div id="home-section" class="nav-section">
5
+ <h2>
6
+ <a href="<%= rel_prefix %>/" rel="home">Home</a>
7
+ </h2>
8
+ </div>
9
+
10
+ <%= render '_sidebar_search.rhtml' %>
11
+ </div>
12
+
13
+ <%= render '_sidebar_installed.rhtml' %>
14
+ </nav>
15
+
16
+ <main role="main">
17
+ <h1>Local RDoc Documentation</h1>
18
+
19
+ <p>Here you can browse local documentation from the ruby standard library and
20
+ your installed gems.
21
+
22
+ <%- extra_dirs = installed.select { |_, _, _, type,| type == :extra } -%>
23
+ <%- unless extra_dirs.empty? -%>
24
+ <h2>Extra Documentation Directories</h2>
25
+
26
+ <p>The following additional documentation directories are available:</p>
27
+
28
+ <ol>
29
+ <%- extra_dirs.each do |name, href, exists, _, path| -%>
30
+ <li>
31
+ <%- if exists -%>
32
+ <a href="<%= href %>"><%= h name %></a> (<%= h path %>)
33
+ <%- else -%>
34
+ <%= h name %> (<%= h path %>; <i>not available</i>)
35
+ <%- end -%>
36
+ </li>
37
+ <%- end -%>
38
+ </ol>
39
+ <%- end -%>
40
+
41
+ <%- gems = installed.select { |_, _, _, type,| type == :gem } -%>
42
+ <%- missing = gems.reject { |_, _, exists,| exists } -%>
43
+ <%- unless missing.empty? then -%>
44
+ <h2>Missing Gem Documentation</h2>
45
+
46
+ <p>You are missing documentation for some of your installed gems.
47
+ You can install missing documentation for gems by running
48
+ <kbd>gem rdoc --all</kbd>. After installing the missing documentation you
49
+ only need to reload this page. The newly created documentation will
50
+ automatically appear.
51
+
52
+ <p>You can also install documentation for a specific gem by running one of
53
+ the following commands.
54
+
55
+ <ul>
56
+ <%- names = missing.map { |name,| name.sub(/-([^-]*)$/, '') }.uniq -%>
57
+ <%- names.each do |name| -%>
58
+ <li><kbd>gem rdoc <%=h name %></kbd>
59
+ <%- end -%>
60
+ </ul>
61
+ <%- end -%>
62
+ </main>
@@ -0,0 +1,58 @@
1
+ <body id="top" class="table-of-contents">
2
+ <main role="main">
3
+ <h1 class="class"><%= h @title %></h1>
4
+
5
+ <%- simple_files = @files.select { |f| f.text? } -%>
6
+ <%- unless simple_files.empty? then -%>
7
+ <h2 id="pages">Pages</h2>
8
+ <ul>
9
+ <%- simple_files.sort.each do |file| -%>
10
+ <li class="file">
11
+ <a href="<%= file.path %>"><%= h file.page_name %></a>
12
+ <%
13
+ # HACK table_of_contents should not exist on Document
14
+ table = file.parse(file.comment).table_of_contents
15
+ unless table.empty? then %>
16
+ <ul>
17
+ <%- table.each do |heading| -%>
18
+ <li><a href="<%= file.path %>#<%= heading.aref %>"><%= heading.plain_html %></a>
19
+ <%- end -%>
20
+ </ul>
21
+ <%- end -%>
22
+ </li>
23
+ <%- end -%>
24
+ </ul>
25
+ <%- end -%>
26
+
27
+ <h2 id="classes">Classes and Modules</h2>
28
+ <ul>
29
+ <%- @modsort.each do |klass| -%>
30
+ <li class="<%= klass.type %>">
31
+ <a href="<%= klass.path %>"><%= klass.full_name %></a>
32
+ <%- table = []
33
+ table.concat klass.parse(klass.comment_location).table_of_contents
34
+ table.concat klass.section_contents
35
+
36
+ unless table.empty? then %>
37
+ <ul>
38
+ <%- table.each do |item| -%>
39
+ <li><a href="<%= klass.path %>#<%= item.aref %>"><%= item.plain_html %></a>
40
+ <%- end -%>
41
+ </ul>
42
+ <%- end -%>
43
+ </li>
44
+ <%- end -%>
45
+ </ul>
46
+
47
+ <h2 id="methods">Methods</h2>
48
+ <ul>
49
+ <%- @store.all_classes_and_modules.map do |mod|
50
+ mod.method_list
51
+ end.flatten.sort.each do |method| %>
52
+ <li class="method">
53
+ <a href="<%= method.path %>"><%= h method.pretty_name %></a>
54
+ &mdash;
55
+ <span class="container"><%= method.parent.full_name %></span>
56
+ <%- end -%>
57
+ </ul>
58
+ </main>