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.

123 lines
5.4 KiB

3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
  1. {% set player_bar = [
  2. ('/npc/spells', 'spells', 'Spells', false),
  3. ('/worldmap', 'worldmap', 'Maps', false),
  4. ('/player_tokens', 'tokens', 'Tokens', false),
  5. ('https://reddit.com/r/PalismaACKS/wiki', 'redditwiki', 'Wiki', true),
  6. ] %}
  7. {% set judge_bar = [
  8. ('/npc/party', 'npcparty', 'Generate Party', false),
  9. ('/npc/single', 'npcsingle', 'Generate NPC', false),
  10. ('/lairs', 'lairs', 'Lairs', false),
  11. ('http://autarch.co/treasure', 'treasure', 'Treasure', true),
  12. ('/quest/list', 'questlist', 'Quests', false),
  13. ('/wiki', 'wiki', 'Wiki', false),
  14. ]%}
  15. {% set navigation_bar = [
  16. ('/', 'index', 'Home', false),
  17. ('/handbook', 'handbook', 'Handbook', false),
  18. (player_bar, 'section', 'Player Resources', false),
  19. (judge_bar, 'section', 'Judge Resources', false),
  20. ('https://reddit.com/r/PalismaACKS', 'subreddit', '/r/PalismaACKS', true),
  21. ] %}
  22. {% set active_page = active_page|default('index') %}
  23. <!doctype html>
  24. <html>
  25. <head>
  26. <title>{% block title %}{% endblock %} - Palisma ACKS</title>
  27. <meta charset="utf-8">
  28. <meta name="viewport" contents="width=device-width, initial-scale=1">
  29. <link rel="shortcut icon" href="{{ url_for('static', filename='favicon.ico') }}">
  30. <!-- UIkit CSS -->
  31. <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/uikit@3.2.4/dist/css/uikit.min.css" />
  32. <!-- UIkit JS -->
  33. <script src="https://cdn.jsdelivr.net/npm/uikit@3.2.4/dist/js/uikit.min.js"></script>
  34. <script src="https://cdn.jsdelivr.net/npm/uikit@3.2.4/dist/js/uikit-icons.min.js"></script>
  35. <style>
  36. h1 strong {
  37. display: block;
  38. font-size: 50%;
  39. opacity: 0.65;
  40. }
  41. .uk-navbar-nav > li > a {
  42. font-size: 1em;
  43. text-transform: none;
  44. }
  45. </style>
  46. {% block head %}
  47. {% endblock %}
  48. </head>
  49. <body>
  50. <nav class="uk-navbar-container" uk-navbar>
  51. <div class="uk-navbar-left">
  52. <a href="" class="uk-hidden@m uk-button-default uk-margin-small-left uk-margin-small-right" uk-toggle="target: #offcanvas-nav" uk-icon="menu"></a>
  53. <a href="" class="uk-navbar-item uk-logo">Palisma ACKS</a>
  54. </div>
  55. <div class="uk-navbar-center uk-visible@m">
  56. <ul class="uk-navbar-nav">
  57. {% for href, id, label, blank in navigation_bar %}
  58. {% if id == 'section' %}
  59. <li>
  60. <a href="" {% if blank is sameas true %} target="_blank" {% endif %}>{{ label|e }}</a>
  61. <div class="uk-navbar-dropdown">
  62. <ul class="uk-nav uk-navbar-dropdown-nav">
  63. {% for phref, pid, plabel, pblank in href %}
  64. <li>
  65. <a href="{{ phref|e }}" {% if pblank is sameas true %} target="_blank" {% endif %}>{{ plabel|e }}</a>
  66. </li>
  67. {% endfor %}
  68. </ul>
  69. </div>
  70. </li>
  71. {% else %}
  72. <li {% if id == active_page %} class="uk-active" {% endif %}>
  73. <a href="{{ href|e }}" {% if blank is sameas true %} target="_blank" {% endif %}>{{ label|e }}</a>
  74. </li>
  75. {% endif %}
  76. {% endfor %}
  77. </ul>
  78. </div>
  79. </nav>
  80. <div id="offcanvas-nav" uk-offcanvas="overlay: true">
  81. <div class="uk-offcanvas-bar uk-flex uk-flex-column">
  82. <ul class="uk-nav uk-nav-primary uk-nav-center uk-margin-auto-vertical">
  83. {% for href, id, label, blank in navigation_bar %}
  84. {% if id == 'section' %}
  85. <li class="uk-nav-header uk-margin-large-top">{{ label|e }}</li>
  86. {% for phref, pid, plabel, pblank in href %}
  87. <li {% if pid == active_page %} class="uk-active" {% endif %}>
  88. <a href="{{ phref|e }}" {% if pblank is sameas true %} target="_blank" {% endif %}>{{ plabel|e }}</a>
  89. </li>
  90. {% endfor %}
  91. <li class="uk-margin-large-bottom"/>
  92. {% else %}
  93. <li {% if id == active_page %} class="uk-active" {% endif %}>
  94. <a href="{{ href|e }}" {% if blank is sameas true %} target="_blank" {% endif %}>{{ label|e }}</a>
  95. </li>
  96. {% endif %}
  97. {% endfor %}
  98. </ul>
  99. </div>
  100. </div>
  101. <div class="uk-container uk-margin-medium-top">
  102. {% block content %}{% endblock %}
  103. </div>
  104. <footer class="uk-flex uk-flex-top uk-flex-center uk-margin-small uk-margin-medium-top">
  105. <div class="uk-text-center uk-text-small">
  106. Made by <a href="https://binaryatrocity.name">binaryatrocity</a>.
  107. ACKS &amp; related &copy; <a href="http://www.autarch.co/">Autarch</a>.
  108. </div>
  109. </footer>
  110. {% block scripts %}
  111. {% endblock %}
  112. </body>
  113. </html>