Skip to content

Commit

Permalink
Merge branch 'main' into identity-selection-improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
plural authored Sep 29, 2024
2 parents e86b375 + 9cd6fed commit 8a20877
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 33 deletions.
19 changes: 10 additions & 9 deletions app/Resources/views/Decklist/decklists.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,17 @@
<div class="row">
<div class="col-md-3">

<!-- Duplicated in search.html.twig -->
<ul class="nav nav-pills nav-stacked" id="side_nav" style="margin-bottom:2em">
{% set linkurl = path('decklists_list', {type:'popular'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Popular</a></li>
{% set linkurl = path('decklists_list', {type:'recent'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Recent</a></li>
{% set linkurl = path('decklists_list', {type:'tournament'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Tournaments</a></li>
{% set linkurl = path('decklists_list', {type:'hottopics'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Hot topics</a></li>
{% set linkurl = path('decklists_list', {type:'dotw'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Decklist of the week</a></li>
{% set linkurl = path('decklists_list', {type:'halloffame'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Hall of Fame</a></li>
{% set linkurl = path('decklists_list', {type:'favorites'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">My favorites</a></li>
{% set linkurl = path('decklists_list', {type:'mine'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">My decklists</a></li>
{% set linkurl = path('decklists_searchform') %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}"><span class="glyphicon glyphicon-search"></span> Search</a></li>
{% set linkurl = path('decklists_searchform') %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}"><span class="glyphicon glyphicon-search"></span> Search</a></li>
{% set linkurl = path('decklists_list', {type:'dotw'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Decklist of the week</a></li>
{% set linkurl = path('decklists_list', {type:'recent'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Recent</a></li>
{% set linkurl = path('decklists_list', {type:'tournament'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Tournaments</a></li>
{% set linkurl = path('decklists_list', {type:'popular'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Popular</a></li>
{% set linkurl = path('decklists_list', {type:'hottopics'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Hot topics</a></li>
{% set linkurl = path('decklists_list', {type:'halloffame'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Hall of Fame</a></li>
{% set linkurl = path('decklists_list', {type:'mine'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">My decklists</a></li>
{% set linkurl = path('decklists_list', {type:'favorites'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">My favorites</a></li>
</ul>

</div>
Expand Down
34 changes: 11 additions & 23 deletions app/Resources/views/Search/search.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -9,29 +9,17 @@
<div class="row">
<div class="col-sm-3">

<ul class="nav nav-pills nav-stacked">
{% set linkurl = path('decklists_list', {type:'popular'}) %}
<li class="{% if url == linkurl %}active{% endif %}"><a
href="{{ linkurl }}">Popular</a></li> {% set linkurl =
path('decklists_list', {type:'recent'}) %}
<li class="{% if url == linkurl %}active{% endif %}"><a
href="{{ linkurl }}">Recent</a></li> {% set linkurl =
path('decklists_list', {type:'hottopics'}) %}
<li class="{% if url == linkurl %}active{% endif %}"><a
href="{{ linkurl }}">Hot topics</a></li> {% set linkurl =
path('decklists_list', {type:'halloffame'}) %}
<li class="{% if url == linkurl %}active{% endif %}"><a
href="{{ linkurl }}">Hall of Fame</a></li> {% if app.user %} {% set
linkurl = path('decklists_list', {type:'favorites'}) %}
<li class="{% if url == linkurl %}active{% endif %}"><a
href="{{ linkurl }}">My favorites</a></li> {% set linkurl =
path('decklists_list', {type:'mine'}) %}
<li class="{% if url == linkurl %}active{% endif %}"><a
href="{{ linkurl }}">My decklists</a></li> {% endif %} {% set
linkurl = path('decklists_searchform') %}
<li class="{% if url == linkurl %}active{% endif %}"><a
href="{{ linkurl }}"><span class="glyphicon glyphicon-search"></span>
Search</a></li>
<!-- Duplicated in decklists.html.twig -->
<ul class="nav nav-pills nav-stacked" id="side_nav" style="margin-bottom:2em">
{% set linkurl = path('decklists_searchform') %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}"><span class="glyphicon glyphicon-search"></span> Search</a></li>
{% set linkurl = path('decklists_list', {type:'dotw'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Decklist of the week</a></li>
{% set linkurl = path('decklists_list', {type:'recent'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Recent</a></li>
{% set linkurl = path('decklists_list', {type:'tournament'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Tournaments</a></li>
{% set linkurl = path('decklists_list', {type:'popular'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Popular</a></li>
{% set linkurl = path('decklists_list', {type:'hottopics'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Hot topics</a></li>
{% set linkurl = path('decklists_list', {type:'halloffame'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">Hall of Fame</a></li>
{% set linkurl = path('decklists_list', {type:'mine'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">My decklists</a></li>
{% set linkurl = path('decklists_list', {type:'favorites'}) %}<li class="{% if url == linkurl %}active{% endif %}"><a href="{{ linkurl }}">My favorites</a></li>
</ul>

</div>
Expand Down
17 changes: 16 additions & 1 deletion app/Resources/views/layout.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,22 @@
<div class="navbar-collapse collapse">
<ul class="nav navbar-nav">
<li><a href="{{ path('decks_list') }}">My Decks</a></li>
<li><a href="{{ path('decklists_list', {type:'popular'}) }}">Decklists</a></li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false">Decklists <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu">
<li><a href="{{ path('decklists_list', {type:'search'}) }}">Search</a></li>
<li class="divider"></li>
<li><a href="{{ path('decklists_list', {type:'dotw'}) }}">Decklists of the Week</a></li>
<li><a href="{{ path('decklists_list', {type:'recent'}) }}">Recent</a></li>
<li><a href="{{ path('decklists_list', {type:'tournament'}) }}">Tournaments</a></li>
<li><a href="{{ path('decklists_list', {type:'popular'}) }}">Popular</a></li>
<li><a href="{{ path('decklists_list', {type:'hottopics'}) }}">Hot Topics</a></li>
<li><a href="{{ path('decklists_list', {type:'halloffame'}) }}">Hall of Fame</a></li>
<li class="divider"></li>
<li><a href="{{ path('decklists_list', {type:'mine'}) }}">My Decklists</a></li>
<li><a href="{{ path('decklists_list', {type:'favorites'}) }}">My Favorites</a></li>
</ul>
</li>
<li><a href="{{ path('cards_sets') }}">Sets</a></li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false">Factions <span class="caret"></span></a>
Expand Down

0 comments on commit 8a20877

Please sign in to comment.