DotaNoobs main site.
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.

133 lines
6.5 KiB

  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. {% block head %}
  5. <title>{% block title %}{% endblock %}</title>
  6. {% endblock %}
  7. <!-- Meta-tags -->
  8. <meta name="viewport" content="initial-scale=1">
  9. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  10. <!-- CSS includes -->
  11. <link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/uikit/2.8.0/css/uikit.gradient.min.css" />
  12. <link rel="stylesheet" href="{{ url_for('static', filename='css/app.css') }}" />
  13. <link rel="shortcut icon" href="{{ url_for('static', filename='img/favicon.ico') }}">
  14. <!-- Javascript includes -->
  15. <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
  16. <script src="//cdnjs.cloudflare.com/ajax/libs/uikit/2.8.0/js/uikit.min.js"></script>
  17. <script src="//cdnjs.cloudflare.com/ajax/libs/moment.js/2.5.1/moment.min.js"></script>
  18. </head>
  19. <body>
  20. <!-- Navigation bar -->
  21. <nav class="uk-navbar uk-navbar-attached" data-uk-navbar>
  22. <a href="#offcanvas" class="uk-navbar-brand uk-hidden-large" data-uk-offcanvas>
  23. <img src="{{ url_for('static', filename='img/navlogo.png') }}" class="uk-visible-large" /><i class="uk-icon-navicon uk-hidden-large"></i>
  24. </a>
  25. <a href="" class="uk-navbar-brand uk-visible-large" data-uk-offcanvas><img src="{{ url_for('static', filename='img/navlogo.png') }}" /></a>
  26. <!-- Check if user is logged in -->
  27. {% if g.user %}
  28. <ul class="uk-navbar-nav uk-navbar-flip">
  29. <li data-uk-dropdown="" class="uk-parent">
  30. <a href="#"><img class="uk-responsive-height" src="{{ g.user.avatar }}" /> {{ g.user.nickname }} </a>
  31. <div class="uk-dropdown uk-dropdown-navbar">
  32. <ul class="uk-nav uk-nav-navbar">
  33. <li><a href="{{ url_for('user_profile', userid=g.user.id) }}">Profile</a></li>
  34. <li><a href="{{ url_for('user_random_hero', userid=g.user.id) }}">A-Z Challenge</a></li>
  35. <li><a href="http://board.dotanoobs.com/?page=lastposts">Latest Posts</a></li>
  36. {% if g.user.admin %}
  37. <li><a href="{{ url_for('event_edit') }}">Add Event</a></li>
  38. {% endif %}
  39. <li class="uk-nav-divider"></li>
  40. <li><a href="{{ url_for('user_settings') }}">Settings</a></li>
  41. <li><a href="{{ url_for('logout') }}">Logout</a></li>
  42. </ul>
  43. </div>
  44. </ul>
  45. {% else %}
  46. <a class="uk-navbar-flip uk-navbar-content" href="{{ url_for('login') }}"><img src="http://steamcommunity-a.akamaihd.net/public/images/signinthroughsteam/sits_large_border.png" /></a>
  47. {% endif %}
  48. <div class="uk-navbar-content uk-navbar-center uk-hidden-small uk-text-bold">DotaNoobs</div>
  49. </nav>
  50. <!-- Flash Error Messages -->
  51. {% with messages = get_flashed_messages(with_categories=true) %}
  52. {% if messages %}
  53. <ul class="uk-list flashes uk-width-2-3 uk-container-center">
  54. {% for category, message in messages %}
  55. <li class="uk-alert uk-alert-{{ category }}">{{ message }} <a href="#" class="uk-alert-close uk-close"></a> </li>
  56. {% endfor %}
  57. </ul>
  58. {% endif %}
  59. {% endwith %}
  60. <!-- Start Main Container -->
  61. <div id="container" class="uk-grid">
  62. <!-- Big top logo -->
  63. {% if not g.user.logo %}
  64. <div class="uk-width-1-1"><img class="uk-align-center" id="biglogo" src="{{ url_for('static', filename='img/biglogo.png') }}"></div>
  65. {% endif %}
  66. <!-- Side navigation -->
  67. <div class="uk-visible-large uk-width-1-5 uk-panel">
  68. {% if g.doob%}
  69. <h3 class="uk-panel-title">{{ g.doob.name }}</h3>
  70. <hr class="uk-nav-divider" />
  71. {% endif %}
  72. <ul class="uk-nav uk-nav-side uk-text-right uk-nav-parent-icon" data-uk-nav>
  73. {% include 'sidenav.html' %}
  74. </ul>
  75. </div>
  76. <div id="offcanvas" class="uk-offcanvas">
  77. <div class="uk-offcanvas-bar">
  78. {% if g.doob%}
  79. <h3 class="uk-panel-title">{{ g.doob.name }}</h3>
  80. {% endif %}
  81. <ul class="uk-nav uk-nav-offcanvas" data-uk-nav>
  82. {% include 'sidenav.html' %}
  83. </ul>
  84. </div>
  85. </div>
  86. <!-- Main content area -->
  87. <div class="uk-width-large-4-5 uk-width-medium-5-5">
  88. {% block content %}
  89. {% endblock %}
  90. </div>
  91. </div>
  92. <!-- Footer section -->
  93. <footer class="uk-clearfix uk-align-center">
  94. {% cache 60*5 %}
  95. <div class="uk-float-left uk-visible-large">
  96. <a href="http://flask.pocoo.org/"><img src="{{ url_for('static', filename='img/powered-by-flask-s.png') }}" alt="Flask"></a> &amp;
  97. <a href="http://store.steampowered.com/"><img src="{{ url_for('static', filename='img/steam.png') }}" alt="Steam"></a>
  98. </div>
  99. &copy; Coypright 2013 by <a href="http://www.dotanoobs.com/"><img src="{{ url_for('static',filename='img/navlogo.png') }}" alt="DotaNoobs" /></a>
  100. <div class="uk-float-right uk-visible-large">
  101. <a href="http://www.twitch.tv/dotanoobs"><img src="{{ url_for('static', filename='img/twitchicon.png') }}" width="32" alt="Twitch.tv" /></a>
  102. <a href="http://www.youtube.com/user/DotaNoobsVods"><img src="{{ url_for('static', filename='img/youtube.png') }}" alt="YouTube" /></a>
  103. <a href="emailto:admin@dotanoobs.com"><img src="{{ url_for('static', filename='img/email.png') }}" /></a>
  104. </div>
  105. {% endcache %}
  106. </footer>
  107. <!-- Page-specific javascript here -->
  108. {% block pagescripts %}
  109. {% endblock %}
  110. <script type='text/javascript'>
  111. $(document).ready(function() {
  112. $("li.uk-alert > a.uk-alert-close").on('click', function(){
  113. $(this).parent().hide();
  114. });
  115. $(document).ready(function() {
  116. $('.date').each(function (index) {
  117. var d = moment.utc($(this).text()+" UTC");
  118. $(this).html(d.local().format("h:mm A on MMM Do"));
  119. });
  120. });
  121. });
  122. </script>
  123. </body>
  124. </html>