Skip to content

Commit

Permalink
Upgrade Site to Bootstrap 5
Browse files Browse the repository at this point in the history
  • Loading branch information
mjmusante committed Oct 26, 2024
1 parent 1df54c7 commit 41baaa9
Show file tree
Hide file tree
Showing 48 changed files with 803 additions and 529 deletions.
2 changes: 1 addition & 1 deletion IFComp/conf/ifcomp.conf
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# rename this file to ifcomp.yml and put a ':' after 'name' if
# you want to use YAML like in old versions of Catalyst
name IFComp
name IFComp
1 change: 1 addition & 0 deletions IFComp/lib/IFComp.pm
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ use namespace::autoclean;

use Catalyst::Runtime 5.80;


# Set flags and add plugins for the application.
#
# Note that ORDERING IS IMPORTANT here as plugins are initialized in order,
Expand Down
34 changes: 25 additions & 9 deletions IFComp/root/lib/site/footer
Original file line number Diff line number Diff line change
@@ -1,12 +1,28 @@
<!-- BEGIN site/footer -->
<footer class="container">
<hr />
<div class="pull-left" style="width: 25%; margin-right:2em; margin-bottom: 1ex;">
<a href="http://iftechfoundation.org"><img class="img-responsive transparent-img-bg" id="iftf-logo" src="/static/images/iftf_logo.svg" alt="Interactive Fiction Technology Foundation" /></a>
</div>
<div>
<p>The Interactive Fiction Competition is a public service of <a href="http://iftechfoundation.org">the Interactive Fiction Technology Foundation</a>, and <a href="http://iftechfoundation.org/give/">funded by IF supporters like you</a>.</p>
<p>Except where otherwise noted, content of this website is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution 4.0 International License</a>, attributable to <a href="http://iftechfoundation.org">Interactive Fiction Technology Foundation (www.iftechfoundation.org)</a>.</p>
</div>
<footer class="container mt-5">

<hr>
<div class="row">
<div class="col-sm-4" style="width: 25%; margin-right:2em; margin-bottom: 1ex;">
<a href="http://iftechfoundation.org">
<img class="iftf_logo col-sm-12 img-responsive transparent-img-bg svgicon"
alt="Interactive Fiction Technology Foundation">
</a>
</div>

<div class="col-sm-8">
<p>The Interactive Fiction Competition is a public service of
<a href="http://iftechfoundation.org">the Interactive Fiction Technology Foundation</a>, and
<a href="http://iftechfoundation.org/give/">funded by IF supporters like you</a>.
</p>
<p>Except where otherwise noted, content of this website is licensed under a
<a rel="license" href="http://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution 4.0 International License</a>,
attributable to
<a href="http://iftechfoundation.org">Interactive Fiction Technology Foundation (www.iftechfoundation.org)</a>.
</p>
</div>

</div><!-- row -->

</footer>
<!-- END site/footer -->
207 changes: 141 additions & 66 deletions IFComp/root/lib/site/header
Original file line number Diff line number Diff line change
Expand Up @@ -9,81 +9,156 @@ ELSE;
button_id = 'signin-button';
END;
%]

<!-- BEGIN site/header -->
<div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="/">IFComp</a>
</div>
<div class="navbar-collapse collapse">
<ul class="nav navbar-nav">
<header style="padding-top: 0px;" class="navbar navbar-expand-lg sticky-top">
<nav class="bg-secondary-subtle navbar-static-top container-xxl flex-wrap flex-lg-nowrap" aria-label="Main navigation">

<a class="navbar-brand" href="/">IFComp</a>

<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav me-auto mb-2 mb-lg-0">
<li class="nav-item">
[% IF ( current_comp.status == 'open_for_judging' ) || ( current_comp.status == 'processing_votes' ) %]
<li><a href="/ballot/">Entries</a></li>
<a class="nav-link" href="/ballot/">Entries</a>
[% ELSE %]
<li><a href="/comp/">Results</a></li>
<a class="nav-link" href="/comp/">Results</a>
[% END %]
<li><a href="/rules/">Rules</a></li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Participate <b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="/about/schedule">Schedule</a></li>
<li class="divider"></li>
[% IF current_comp.status == 'open_for_judging' %]
<li><a href="/ballot/vote">Rate the entries</a></li>
<li class="divider"></li>
[% END %]
<li><a href="/about/how_to_enter">Author’s Handbook</a></li>
<li><a href="/entry">Register or manage your entries</a></li>
<li class="divider"></li>
<li><a href="/about/prizes">View or donate prizes</a></li>
<li class="divider"></li>
<li><a href="/about/faq">Frequently Asked Questions</a></li>
</ul>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">About <b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="/about/comp">About IFComp</a></li>
<li><a href="/about/guidelines">Guidelines for authors</a></li>
<li><a href="/about/judging">Guidelines for judges</a></li>
<li><a href="/about/prizes">View or donate prizes</a></li>
<li><a href="/about/if">About IF</a></li>
<li><a href="/history/">History of the IFComp</a></li>
<li><a href="/comp/last_comp">Past IFComp Results</a></li>
<li><a href="/about/contact">Contact / Credits / Legal</a></li>
</ul>
</li>

<li class="nav-item"><a class="nav-link" href="/rules/">Rules</a></li>

<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" data-bs-toggle="dropdown" href="#" role="button" aria-expanded="false">Participate</a>
<ul class="dropdown-menu">
<li><a class="dropdown-item" href="/about/schedule">Schedule</a></li>
<li class="dropdown-divider"></li>
[% IF current_comp.status == 'open_for_judging' %]
<li><a class="dropdown-item" href="/ballot/vote">Rate the entries</a></li>
<li class="dropdown-divider"></li>
[% END %]
<li><a class="dropdown-item" href="/about/how_to_enter">Author’s Handbook</a></li>
<li><a class="dropdown-item" href="/entry">Register or manage your entries</a></li>
<li class="dropdown-divider"></li>
<li><a class="dropdown-item" href="/about/prizes">View or donate prizes</a></li>
<li class="dropdown-divider"></li>
<li><a class="dropdown-item" href="/about/faq">Frequently Asked Questions</a></li>
</ul>
</li>

<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" data-bs-toggle="dropdown" href="#" role="button" aria-expanded="false">About</a>
<ul class="dropdown-menu">
<li><a class="dropdown-item" href="/about/comp">About IFComp</a></li>
<li><a class="dropdown-item" href="/about/guidelines">Guidelines for authors</a></li>
<li><a class="dropdown-item" href="/about/judging">Guidelines for judges</a></li>
<li><a class="dropdown-item" href="/about/file_formats">Game File Format Information</a></li>
<li><a class="dropdown-item" href="/about/prizes">View or donate prizes</a></li>
<li><a class="dropdown-item" href="/about/if">About IF</a></li>
<li><a class="dropdown-item" href="/history/">History of the IFComp</a></li>
<li><a class="dropdown-item" href="/comp/last_comp">Past IFComp Results</a></li>
<li><a class="dropdown-item" href="/about/contact">Contact / Credits / Legal</a></li>
</ul>
</li>

<li class="dropdown">
<a class="nav-link dropdown-toggle" data-bs-toggle="dropdown" href="#" role="button" aria-expanded="false">News</a>
<ul class="dropdown-menu">
<li><a class="dropdown-item" href="http://blog.ifcomp.org">Blog</a></li>
<li><a class="dropdown-item" href="http://twitter.com/ifcomp">Twitter</a></li>
<li><a class="dropdown-item" rel="me" href="https://mastodon.gamedev.place/@IFComp">Mastodon</a></li>
</ul>
</li>
</ul>
<hr class="d-lg-none text-white-50">
<ul class="navbar-nav flex-row flex-wrap ms-md-auto">

<li class="nav-item dropdown">

<svg xmlns="http://www.w3.org/2000/svg" style="display: none;">
<symbol id="question-circle" viewBox="0 0 16 16">
<path d="M8 15A7 7 0 1 1 8 1a7 7 0 0 1 0 14m0 1A8 8 0 1 0 8 0a8 8 0 0 0 0 16"/>
<path d="M5.255 5.786a.237.237 0 0 0 .241.247h.825c.138 0 .248-.113.266-.25.09-.656.54-1.134 1.342-1.134.686 0 1.314.343 1.314 1.168 0 .635-.374.927-.965 1.371-.673.489-1.206 1.06-1.168 1.987l.003.217a.25.25 0 0 0 .25.246h.811a.25.25 0 0 0 .25-.25v-.105c0-.718.273-.927 1.01-1.486.609-.463 1.244-.977 1.244-2.056 0-1.511-1.276-2.241-2.673-2.241-1.267 0-2.655.59-2.75 2.286m1.557 5.763c0 .533.425.927 1.01.927.609 0 1.028-.394 1.028-.927 0-.552-.42-.94-1.029-.94-.584 0-1.009.388-1.009.94"/>
</symbol>
<symbol id="bar-chart-fill" viewBox="0 0 16 16">
<path d="M1 11a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1v3a1 1 0 0 1-1 1H2a1 1 0 0 1-1-1zm5-4a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1v7a1 1 0 0 1-1 1H7a1 1 0 0 1-1-1zm5-5a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1v12a1 1 0 0 1-1 1h-2a1 1 0 0 1-1-1z"/>
</symbol>
<symbol id="cloud-download-fill" viewBox="0 0 16 16">
<path fill-rule="evenodd" d="M8 0a5.53 5.53 0 0 0-3.594 1.342c-.766.66-1.321 1.52-1.464 2.383C1.266 4.095 0 5.555 0 7.318 0 9.366 1.708 11 3.781 11H7.5V5.5a.5.5 0 0 1 1 0V11h4.188C14.502 11 16 9.57 16 7.773c0-1.636-1.242-2.969-2.834-3.194C12.923 1.999 10.69 0 8 0m-.354 15.854a.5.5 0 0 0 .708 0l3-3a.5.5 0 0 0-.708-.708L8.5 14.293V11h-1v3.293l-2.146-2.147a.5.5 0 0 0-.708.708z"/>
</symbol>
<symbol id="card-list" viewBox="0 0 16 16">
<path d="M14.5 3a.5.5 0 0 1 .5.5v9a.5.5 0 0 1-.5.5h-13a.5.5 0 0 1-.5-.5v-9a.5.5 0 0 1 .5-.5zm-13-1A1.5 1.5 0 0 0 0 3.5v9A1.5 1.5 0 0 0 1.5 14h13a1.5 1.5 0 0 0 1.5-1.5v-9A1.5 1.5 0 0 0 14.5 2z"/>
<path d="M5 8a.5.5 0 0 1 .5-.5h7a.5.5 0 0 1 0 1h-7A.5.5 0 0 1 5 8m0-2.5a.5.5 0 0 1 .5-.5h7a.5.5 0 0 1 0 1h-7a.5.5 0 0 1-.5-.5m0 5a.5.5 0 0 1 .5-.5h7a.5.5 0 0 1 0 1h-7a.5.5 0 0 1-.5-.5m-1-5a.5.5 0 1 1-1 0 .5.5 0 0 1 1 0M4 8a.5.5 0 1 1-1 0 .5.5 0 0 1 1 0m0 2.5a.5.5 0 1 1-1 0 .5.5 0 0 1 1 0"/>
</symbol>
<symbol id="twitter" viewBox="0 0 16 16">
<path d="M5.026 15c6.038 0 9.341-5.003 9.341-9.334q.002-.211-.006-.422A6.7 6.7 0 0 0 16 3.542a6.7 6.7 0 0 1-1.889.518 3.3 3.3 0 0 0 1.447-1.817 6.5 6.5 0 0 1-2.087.793A3.286 3.286 0 0 0 7.875 6.03a9.32 9.32 0 0 1-6.767-3.429 3.29 3.29 0 0 0 1.018 4.382A3.3 3.3 0 0 1 .64 6.575v.045a3.29 3.29 0 0 0 2.632 3.218 3.2 3.2 0 0 1-.865.115 3 3 0 0 1-.614-.057 3.28 3.28 0 0 0 3.067 2.277A6.6 6.6 0 0 1 .78 13.58a6 6 0 0 1-.78-.045A9.34 9.34 0 0 0 5.026 15"/>
</symbol>
<symbol id="chevron-right" viewBox="0 0 16 16">
<path fill-rule="evenodd" d="M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708"/>
</symbol>
<symbol id="circle-half" viewBox="0 0 16 16">
<path d="M8 15A7 7 0 1 0 8 1v14zm0 1A8 8 0 1 1 8 0a8 8 0 0 1 0 16z"/>
</symbol>
<symbol id="moon-stars-fill" viewBox="0 0 16 16">
<path d="M6 .278a.768.768 0 0 1 .08.858 7.208 7.208 0 0 0-.878 3.46c0 4.021 3.278 7.277 7.318 7.277.527 0 1.04-.055 1.533-.16a.787.787 0 0 1 .81.316.733.733 0 0 1-.031.893A8.349 8.349 0 0 1 8.344 16C3.734 16 0 12.286 0 7.71 0 4.266 2.114 1.312 5.124.06A.752.752 0 0 1 6 .278z"/>
<path d="M10.794 3.148a.217.217 0 0 1 .412 0l.387 1.162c.173.518.579.924 1.097 1.097l1.162.387a.217.217 0 0 1 0 .412l-1.162.387a1.734 1.734 0 0 0-1.097 1.097l-.387 1.162a.217.217 0 0 1-.412 0l-.387-1.162A1.734 1.734 0 0 0 9.31 6.593l-1.162-.387a.217.217 0 0 1 0-.412l1.162-.387a1.734 1.734 0 0 0 1.097-1.097l.387-1.162zM13.863.099a.145.145 0 0 1 .274 0l.258.774c.115.346.386.617.732.732l.774.258a.145.145 0 0 1 0 .274l-.774.258a1.156 1.156 0 0 0-.732.732l-.258.774a.145.145 0 0 1-.274 0l-.258-.774a1.156 1.156 0 0 0-.732-.732l-.774-.258a.145.145 0 0 1 0-.274l.774-.258c.346-.115.617-.386.732-.732L13.863.1z"/>
</symbol>
<symbol id="sun-fill" viewBox="0 0 16 16">
<path d="M8 12a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM8 0a.5.5 0 0 1 .5.5v2a.5.5 0 0 1-1 0v-2A.5.5 0 0 1 8 0zm0 13a.5.5 0 0 1 .5.5v2a.5.5 0 0 1-1 0v-2A.5.5 0 0 1 8 13zm8-5a.5.5 0 0 1-.5.5h-2a.5.5 0 0 1 0-1h2a.5.5 0 0 1 .5.5zM3 8a.5.5 0 0 1-.5.5h-2a.5.5 0 0 1 0-1h2A.5.5 0 0 1 3 8zm10.657-5.657a.5.5 0 0 1 0 .707l-1.414 1.415a.5.5 0 1 1-.707-.708l1.414-1.414a.5.5 0 0 1 .707 0zm-9.193 9.193a.5.5 0 0 1 0 .707L3.05 13.657a.5.5 0 0 1-.707-.707l1.414-1.414a.5.5 0 0 1 .707 0zm9.193 2.121a.5.5 0 0 1-.707 0l-1.414-1.414a.5.5 0 0 1 .707-.707l1.414 1.414a.5.5 0 0 1 0 .707zM4.464 4.465a.5.5 0 0 1-.707 0L2.343 3.05a.5.5 0 1 1 .707-.707l1.414 1.414a.5.5 0 0 1 0 .708z"/>
</symbol>
<symbol id="check2" viewBox="0 0 16 16">
<path d="M13.854 3.646a.5.5 0 0 1 0 .708l-7 7a.5.5 0 0 1-.708 0l-3.5-3.5a.5.5 0 1 1 .708-.708L6.5 10.293l6.646-6.647a.5.5 0 0 1 .708 0z"/>
</symbol>
<symbol id="envelope" viewBox="0 0 16 16">
<path d="M0 4a2 2 0 0 1 2-2h12a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2zm2-1a1 1 0 0 0-1 1v.217l7 4.2 7-4.2V4a1 1 0 0 0-1-1zm13 2.383-4.708 2.825L15 11.105zm-.034 6.876-5.64-3.471L8 9.583l-1.326-.795-5.64 3.47A1 1 0 0 0 2 13h12a1 1 0 0 0 .966-.741M1 11.105l4.708-2.897L1 5.383z"/>
</symbol>
</svg>

<button class="btn btn-link nav-link py-2 px-0 px-lg-2 dropdown-toggle d-flex align-items-center"
id="bd-theme"
type="button"
aria-expanded="false"
data-bs-toggle="dropdown"
data-bs-display="static"
aria-label="Toggle theme (auto)">
<svg width="16" height="16" class="svgfill bi my-1 theme-icon-active"><use href="#circle-half"></use></svg>
<span class="d-lg-none ms-2" id="bd-theme-text">Toggle theme</span>
</button>
<ul class="dropdown-menu dropdown-menu-end" aria-labelledby="bd-theme-text">
<li>
<button type="button" class="dropdown-item d-flex align-items-center" data-bs-theme-value="light" aria-pressed="false">
<svg role="img" width="16" height="16" class="svgfill navbar-nav-svg bi me-2 opacity-50"><use href="#sun-fill"></use></svg>
Light
<svg class="svgfill bi ms-auto d-none"><use href="#check2"></use></svg>
</button>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">News <b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="http://blog.ifcomp.org">Blog</a></li>
<li><a href="http://twitter.com/ifcomp">Twitter</a></li>
<li><a rel="me" href="https://mastodon.gamedev.place/@IFComp">Mastodon</a></li>
</ul>
<li>
<button type="button" class="dropdown-item d-flex align-items-center" data-bs-theme-value="dark" aria-pressed="false">
<svg width="16" height="16" class="svgfill bi me-2 opacity-50"><use href="#moon-stars-fill"></use></svg>
Dark
<svg class="svgfill bi ms-auto d-none"><use href="#check2"></use></svg>
</button>
</li>
<li>
<input type="checkbox"
class="custom-control-input" hidden id="dark_mode_toggle" />
<a href="#"><label id="dark_mode_override" style="cursor: pointer;"
class="custom-control-label mode-toggle-link"
for="dark_mode_toggle">Dark Mode</label></a>
<button type="button" class="dropdown-item d-flex align-items-center active" data-bs-theme-value="auto" aria-pressed="true">
<svg width="16" height="16" class="svgfill bi me-2 opacity-50"><use href="#circle-half"></use></svg>
Auto
<svg class="svgfill bi ms-auto d-none"><use href="#check2"></use></svg>
</button>
</li>
</ul>
<form class="navbar-form navbar-right" role="form" action="[% form_action %]" method="POST">
<button type="submit" id="[% button_id %]" class="btn btn-success">[% button_label %]</button>
</form>
</ul>
</li>


[% IF c.user %]
<p class="navbar-text navbar-right"><a href="/user/edit_account">Welcome, [% c.user.name | html %]</a></p>
[% END %]
</div><!--/.navbar-collapse -->
</div>
</ul>
[% IF c.user %]
<p style="margin: 10px;" class="nav-item navbar-text navbar-right"><a class="nav-link" href="/user/edit_account">Welcome, [% c.user.name | html %]</a></p>
[% END %]
<form class="navbar-form navbar-right" role="form" action="[% form_action %]" method="POST">
<button type="submit" id="[% button_id %]" class="btn btn-success">[% button_label %]</button>
</form>
</div>
</nav>
</header>

<!-- END site/header -->
Loading

0 comments on commit 41baaa9

Please sign in to comment.