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.

45 lines
2.0 KiB

  1. <% @tabs = { definition: 'Definition', usage: 'Usage', examples: 'Examples', settings: 'Settings' } if @tabs == 'module' %>
  2. <div class="<% if @tabs?: %>tab <% end %>segment">
  3. <div class="container">
  4. <div class="introduction">
  5. <h1 class="ui dividing header">
  6. <%=@document.title %>
  7. <% if @document.status?: %><span class="ui label"><%= @document.status %></span><% end %>
  8. </h1>
  9. <p><%=@document.description %></p>
  10. <% if @document.type is 'UI Element' or @document.type is 'UI View' or @document.type is 'UI Collection' or @document.type is 'UI Module': %>
  11. <div class="ui basic labeled icon toggle overview button">
  12. Overview
  13. <i class="book icon"></i>
  14. </div>
  15. <% end %>
  16. </div>
  17. <div class="advertisement">
  18. <div id="carbonads-container"><div class="carbonad"><div id="azcarbon"></div><script type="text/javascript">var z = document.createElement("script"); z.type = "text/javascript"; z.async = true; z.src = "http://engine.carbonads.com/z/51619/azcarbon_2_1_0_HORIZ"; var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(z, s);</script></div></div>
  19. </div>
  20. <% if @tabs?: %>
  21. <% index = 0 %>
  22. <% tabCount = 0 %>
  23. <% numbers = ['zero', 'one', 'two', 'three', 'four', 'five', 'six'] %>
  24. <% colors = ['red', 'teal', 'blue', 'purple', 'black', 'orange'] %>
  25. <% for id, name of @tabs: %>
  26. <% tabCount++ %>
  27. <% end %>
  28. <div class="<%= numbers[tabCount] %> item tabular ui menu">
  29. <% for id, name of @tabs: %>
  30. <a class="<%= if index == 0 then 'active ' %>item" data-tab="<%= id %>"><%= name %></a>
  31. <% index++ %>
  32. <% end %>
  33. </div>
  34. <% index = 0 %>
  35. <div class="fluid vertical ui menu">
  36. <% for id, name of @tabs: %>
  37. <a class="<%= if index == 0 then 'active ' %>item" data-tab="<%= id %>"><%= name %></a>
  38. <% index++ %>
  39. <% end %>
  40. </div>
  41. <% end %>
  42. </div>
  43. </div>