Stash
This commit is contained in:
parent
660f1732ce
commit
0d8dd65028
@ -1,3 +1,4 @@
|
||||
from datetime import datetime
|
||||
from secrets import token_hex
|
||||
|
||||
from flask import Flask, render_template
|
||||
@ -11,6 +12,11 @@ app.config["SECRET_KEY"] = token_hex()
|
||||
|
||||
@app.context_processor
|
||||
def utility_processor():
|
||||
current_date = datetime.now()
|
||||
next_year = current_date.year + 5 - (current_date.year % 5)
|
||||
|
||||
print(next_year)
|
||||
|
||||
return dict(_=i18n, current_lang=current_lang(), search_form=SearchForm())
|
||||
|
||||
|
||||
|
6
pynyaata/bridge/__init__.py
Normal file
6
pynyaata/bridge/__init__.py
Normal file
@ -0,0 +1,6 @@
|
||||
from pynyaata.bridge.animeultime import AnimeUltime
|
||||
from pynyaata.bridge.nyaa import EraiRaws, Nyaa
|
||||
from pynyaata.bridge.yggtorrent import YggAnimation, YggTorrent
|
||||
|
||||
|
||||
BRIDGES = [Nyaa(), EraiRaws(), YggTorrent(), YggAnimation(), AnimeUltime()]
|
@ -1,3 +0,0 @@
|
||||
.has-addons .button {
|
||||
border-left: 0
|
||||
}
|
@ -1,5 +1,8 @@
|
||||
{% extends "layout.html.j2" %}
|
||||
|
||||
{% block body %}
|
||||
|
||||
<section class="hero is-fullheight-with-navbar">
|
||||
<div class="hero-body m-auto">
|
||||
<p class="title">{{ _("π😼た") }}</p>
|
||||
</div>
|
||||
</section>
|
||||
{% endblock body %}
|
||||
|
@ -23,28 +23,29 @@
|
||||
<body>
|
||||
<nav class="navbar" role="navigation" aria-label="main navigation">
|
||||
<div class="navbar-brand">
|
||||
<a class="navbar-item" href="{{ url_for('index') }}">{{ _("ℼ😼た") }}</a>
|
||||
<a class="navbar-item" href="{{ url_for('index') }}">{{ _("π😼た") }}</a>
|
||||
</div>
|
||||
<div class="navbar-start">
|
||||
{% block links %}
|
||||
{% endblock links %}
|
||||
</div>
|
||||
<div class="navbar-end">
|
||||
{% if request.endpoint != "index" %}
|
||||
<form action="{{ url_for('index') }}" class="navbar-item">
|
||||
<div class="field has-addons">
|
||||
<div class="control">
|
||||
{{ search_form.q(placeholder=_("Search animes ..."), class="input", value=request.args.get("q", "")) }}
|
||||
</div>
|
||||
<div class="control">
|
||||
<button type="submit" class="button">
|
||||
<div class="control has-icons-right">
|
||||
{{ search_form.q(placeholder=_("Search animes ..."), class="input is-rounded", value=request.args.get("q", "")) }}
|
||||
<span class="icon is-small is-right">
|
||||
<i class="fa fa-search"></i>
|
||||
</button>
|
||||
</div>
|
||||
</span>
|
||||
</div>
|
||||
</form>
|
||||
{% endif %}
|
||||
</div>
|
||||
</nav>
|
||||
{% block body %}
|
||||
{% endblock body %}
|
||||
<footer>
|
||||
lol
|
||||
</footer>
|
||||
</body>
|
||||
</html>
|
||||
|
Reference in New Issue
Block a user