You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

283 lines
14 KiB

11 years ago
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <% uiIntroduction = @getCollection("documents").findAll({type: $in: ['UI Introduction']},[{title: 1}]).toJSON() %>
  5. <% uiProject = @getCollection("documents").findAll({type: $in: ['Semantic Project']},[{title: 1}]).toJSON() %>
  6. <% uiGuide = @getCollection("documents").findAll({type: $in: ['UI Guide']},[{title: 1}]).toJSON() %>
  7. <% uiElements = @getCollection("documents").findAll({type: $in: ['UI Element']},[{title: 1}]).toJSON() %>
  8. <% uiCollections = @getCollection("documents").findAll({type: $in: ['UI Collection']},[{title: 1}]).toJSON() %>
  9. <% uiViews = @getCollection("documents").findAll({type: $in: ['UI View']},[{title: 1}]).toJSON() %>
  10. <% uiModules = @getCollection("documents").findAll({type: $in: ['UI Module']},[{title: 1}]).toJSON() %>
  11. <% uiBehavior = @getCollection("documents").findAll({type: $in: ['UI Behavior']},[{title: 1}]).toJSON() %>
  12. <% uiSpecification = @getCollection("documents").findAll({type: $in: ['UI Specification']},[{title: 1}]).toJSON() %>
  13. <% currentCollection = @getCollection("documents").findAll({type: $in: [@document.type]},[{title: 1}]).toJSON() %>
  14. <% pageCount = @pageCount(currentCollection) %>
  15. <% pageNumber = @getPage(currentCollection, @document.id) %>
  16. <% pageCollection = @getPageCollection(currentCollection, @document.id) %>
  17. <!-- Standard Meta -->
  18. <meta charset="utf-8" />
  19. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
  20. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  21. <link rel="image_src" type="image/jpeg" href="images/share.png" />
  22. <!-- Site Properities -->
  23. <%- @getBlock('meta').toHTML() %>
  24. <title><%= @getPreparedTitle() %></title>
  25. <meta name="description" content="<%= @getPreparedDescription() %>" />
  26. <meta name="keywords" content="<%= @getPreparedKeywords() %>" />
  27. <link href='Open+Sans:300italic,400,300,700' rel='stylesheet' type='text/css'>
  28. <link rel="stylesheet" type="text/css" href="/stylesheets/reset.css">
  29. <link rel="stylesheet" type="text/css" href="/stylesheets/library/basic.icon.css">
  30. <% if 'development' in @getEnvironments(): %>
  31. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/site.css">
  32. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/elements/icon.css">
  33. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/elements/button.css">
  34. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/elements/divider.css">
  35. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/elements/header.css">
  36. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/elements/image.css">
  37. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/elements/input.css">
  38. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/elements/label.css">
  39. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/elements/loader.css">
  40. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/elements/reveal.css">
  41. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/elements/progress.css">
  42. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/elements/segment.css">
  43. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/elements/step.css">
  44. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/collections/breadcrumb.css">
  45. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/collections/form.css">
  46. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/collections/grid.css">
  47. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/collections/menu.css">
  48. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/collections/message.css">
  49. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/collections/table.css">
  50. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/views/comment.css">
  51. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/views/list.css">
  52. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/views/feed.css">
  53. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/views/item.css">
  54. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/views/statistic.css">
  55. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/modules/modal.css">
  56. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/modules/accordion.css">
  57. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/modules/dropdown.css">
  58. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/modules/popup.css">
  59. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/modules/rating.css">
  60. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/modules/sidebar.css">
  61. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/modules/shape.css">
  62. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/modules/tab.css">
  63. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/modules/checkbox.css">
  64. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/modules/dimmer.css">
  65. <link rel="stylesheet" type="text/css" class="ui" href="/build/uncompressed/modules/transition.css">
  66. <% else: %>
  67. <link rel="stylesheet" type="text/css" class="ui" href="/build/packaged/css/semantic.min.css">
  68. <% end %>
  69. <!-- <link rel="stylesheet/less" type="text/css" href="/build/less/site.less" /> -->
  70. <link rel="stylesheet" type="text/css" href="/stylesheets/semantic.css">
  71. <% if 'development' in @getEnvironments(): %>
  72. <script>
  73. (function () {
  74. var
  75. eventSupport = ('querySelector' in document && 'addEventListener' in window)
  76. jsonSupport = (typeof JSON !== 'undefined'),
  77. jQuery = (eventSupport && jsonSupport)
  78. ? '/javascript/library/jquery.js'
  79. : '/javascript/library/jquery.legacy.js'
  80. ;
  81. document.write('<script src="' + jQuery + '"><\/script>');
  82. }());
  83. </script>
  84. <% else: %>
  85. <script>
  86. (function () {
  87. var
  88. eventSupport = ('querySelector' in document && 'addEventListener' in window)
  89. jsonSupport = (typeof JSON !== 'undefined'),
  90. jQuery = (eventSupport && jsonSupport)
  91. ? '/javascript/library/jquery.min.js'
  92. : '/javascript/library/jquery.legacy.min.js'
  93. ;
  94. document.write('<script src="' + jQuery + '"><\/script>');
  95. }());
  96. </script>
  97. <% end %>
  98. <script src="/javascript/library/history.js"></script>
  99. <script src="/javascript/library/easing.js"></script>
  100. <script src="/javascript/library/ace/ace.js"></script>
  101. <script src="/javascript/library/tablesort.js"></script>
  102. <script src="/javascript/library/waypoints.js"></script>
  103. <% if 'development' in @getEnvironments(): %>
  104. <script src="/build/uncompressed/modules/behavior/api.js"></script>
  105. <script src="/build/uncompressed/modules/behavior/state.js"></script>
  106. <script src="/build/uncompressed/modules/accordion.js"></script>
  107. <script src="/build/uncompressed/modules/checkbox.js"></script>
  108. <script src="/build/uncompressed/modules/dimmer.js"></script>
  109. <script src="/build/uncompressed/modules/dropdown.js"></script>
  110. <script src="/build/uncompressed/modules/modal.js"></script>
  111. <script src="/build/uncompressed/modules/popup.js"></script>
  112. <script src="/build/uncompressed/modules/rating.js"></script>
  113. <script src="/build/uncompressed/modules/shape.js"></script>
  114. <script src="/build/uncompressed/modules/sidebar.js"></script>
  115. <script src="/build/uncompressed/modules/tab.js"></script>
  116. <script src="/build/uncompressed/modules/transition.js"></script>
  117. <% else: %>
  118. <script src="/build/packaged/javascript/semantic.min.js"></script>
  119. <% end %>
  120. <script src="/javascript/semantic.js"></script>
  121. <script>
  122. (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
  123. (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
  124. m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
  125. })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
  126. ga('create', 'UA-44039803-1', 'semantic-ui.com');
  127. ga('send', 'pageview');
  128. </script>
  129. </head>
  130. <body id="example" class="<%= @document.css %>">
  131. <div class="ui large vertical inverted labeled icon sidebar menu" id="menu">
  132. <a class="hide item">
  133. <i class="close icon"></i> Close Menu
  134. </a>
  135. <a class="item" href="/build/semantic.zip">
  136. <i class="inverted circular red awesome download cloud icon"></i> <b>Download</b>
  137. </a>
  138. <div class="item">
  139. <a href="/">
  140. <b>Introduction</b>
  141. </a>
  142. <div class="menu">
  143. <% for element in uiIntroduction: %>
  144. <a class="<%= if element.id is @document.id then 'active ' %>item" href="<%= element.url %>"><%= element.title %></a>
  145. <% end %>
  146. </div>
  147. </div>
  148. <div class="item">
  149. <b>Project</b>
  150. <div class="menu">
  151. <% for element in uiProject: %>
  152. <a class="<%= if element.id is @document.id then 'active ' %>item" href="<%= element.url %>"><%= element.title %></a>
  153. <% end %>
  154. </div>
  155. </div>
  156. <div class="item">
  157. <a href="/element.html"><b>Elements</b></a>
  158. <div class="menu">
  159. <% for element in uiElements: %>
  160. <a class="<%= if element.id is @document.id then 'active ' %>item" href="<%= element.url %>"><%= element.title %></a>
  161. <% end %>
  162. </div>
  163. </div>
  164. <div class="item">
  165. <a href="/collection.html"><b>Collections</b></a>
  166. <div class="menu">
  167. <% for element in uiCollections: %>
  168. <a class="<%= if element.id is @document.id then 'active ' %>item" href="<%= element.url %>"><%= element.title %></a>
  169. <% end %>
  170. </div>
  171. </div>
  172. <div class="item">
  173. <b>Views</b>
  174. <div class="menu">
  175. <% for element in uiViews: %>
  176. <a class="<%= if element.id is @document.id then 'active ' %>item" href="<%= element.url %>"><%= element.title %></a>
  177. <% end %>
  178. </div>
  179. </div>
  180. <div class="item">
  181. <a href="/module.html"><b>Modules</b></a>
  182. <div class="menu">
  183. <% for element in uiModules: %>
  184. <a class="<%= if element.id is @document.id then 'active ' %>item" href="<%= element.url %>"><%= element.title %></a>
  185. <% end %>
  186. </div>
  187. </div>
  188. <div class="item">
  189. <b>Behavior</b>
  190. <div class="menu">
  191. <% for element in uiBehavior: %>
  192. <a class="<%= if element.id is @document.id then 'active ' %>item" href="<%= element.url %>"><%= element.title %></a>
  193. <% end %>
  194. </div>
  195. </div>
  196. <div class="item">
  197. <b>Style Guide</b>
  198. <div class="menu">
  199. <% for element in uiGuide: %>
  200. <a class="<%= if element.id is @document.id then 'active ' %>item" href="<%= element.url %>"><%= element.title %></a>
  201. <% end %>
  202. </div>
  203. </div>
  204. <!-- <div class="item">
  205. <b>Specification</b>
  206. <div class="menu">
  207. <% for element in uiSpecification: %>
  208. <a class="<%= if element.id is @document.id then 'active ' %>item" href="<%= element.url %>"><%= element.title %></a>
  209. <% end %>
  210. </div>
  211. </div> -->
  212. </div>
  213. <div class="ui fixed transparent inverted main menu">
  214. <div class="container">
  215. <a class="launch item"><i class="icon list layout"></i> Content</a>
  216. <div class="title item">
  217. <b><%= @document.type %>:</b> <%= @document.title %>
  218. </div>
  219. <% if pageNumber > 1 and currentCollection[pageNumber - 2]?: %>
  220. <a class="icon item" href="<%= currentCollection[pageNumber - 2].url %>"><i class="left arrow icon"></i></a>
  221. <% else: %>
  222. <div class="disabled icon item"><i class="left arrow icon"></i></div>
  223. <% end %>
  224. <div class="section ui dropdown link item">
  225. <span class="count"><%= "#{pageNumber} of #{pageCount}" %></span>
  226. <div class="menu">
  227. <% for element, index in currentCollection: %>
  228. <div class="<%= if element.id is @document.id then 'active ' %>item">
  229. <a href="<%= element.url %>"><%= (index+1) %>. <%= element.title %></a>
  230. </div>
  231. <% end %>
  232. </div>
  233. </div>
  234. <% if pageNumber isnt pageCount and currentCollection[pageNumber]?: %>
  235. <a class="icon item" href="<%= currentCollection[pageNumber].url %>"><i class="right arrow icon"></i></a>
  236. <% else: %>
  237. <div class="disabled icon item"><i class="right arrow icon"></i></div>
  238. <% end %>
  239. <div class="right menu">
  240. <div class="vertically fitted borderless item">
  241. <iframe src="http://ghbtns.com/github-btn.html?user=semantic-org&repo=semantic-ui&type=watch&count=true"
  242. allowtransparency="true" frameborder="0" scrolling="0" width="95" height="20"></iframe>
  243. </div>
  244. <% if @document.type is 'UI Element' or @document.type is 'UI View' or @document.type is 'UI Collection' or @document.type is 'UI Module': %>
  245. <a class="popup designer icon item" data-content="Designer Mode">
  246. <i class="basic paint icon"></i>
  247. </a>
  248. <a class="popup developer icon item" data-content="Developer Mode">
  249. <i class="terminal icon"></i>
  250. </a>
  251. <% end %>
  252. <a class="popup icon github item" data-content="View project on Github" href="https://github.com/quirkyinc/semantic">
  253. <i class="icon github"></i>
  254. </a>
  255. </div>
  256. </div>
  257. </div>
  258. <div class="ui black huge launch right attached button">
  259. <i class="icon list layout"></i>
  260. <span class="text">Menu</span>
  261. </div>
  262. <%- @content %>
  263. <script src="/javascript/library/less.js"></script>
  264. </body>
  265. </html>