Albirew/nyaa-pantsu
Archivé
1
0
Bifurcation 0

Merge pull request #798 from kipukun/frontend-bugs-2

Frontend bugs 2
Cette révision appartient à :
akuma06 2017-05-28 02:14:17 +02:00 révisé par GitHub
révision 25c40d6d5c
7 fichiers modifiés avec 45 ajouts et 43 suppressions

Voir le fichier

@ -222,6 +222,7 @@ select.form-input {
table {
border-collapse:collapse;
width: 100%;
table-layout: fixed;
}
@ -250,7 +251,7 @@ th { border-bottom-width: 2px; }
.tr-size { width: 90px; }
.tr-se, .tr-le { font-weight: bold; }
.tr-se, .tr-le, .tr-dl { width: 50px; }
.tr-date { width: 90px; }
.tr-date { width: 100px; }
.sort-arrows { margin-left: 0.2rem; }
.sort-arrows span {
@ -277,8 +278,8 @@ th { border-bottom-width: 2px; }
min-width: 35px;
}
.pagination li:first-child { border-radius: 3px 0 0 3px; }
.pagination li:nth-last-child(2) { border-radius: 0 3px 3px 0; border-right-width: 1px !important}
.pagination a:first-child li { border-radius: 3px 0 0 3px; }
.pagination a:nth-last-child(2) li { border-radius: 0 3px 3px 0; border-right-width: 1px !important}
#footer { width: 100%; bottom: 0; left: 0; margin-top: 40px;}
@ -286,6 +287,8 @@ th { border-bottom-width: 2px; }
.footer {
text-align: center;
padding: 1rem 0 1.2rem 0;
position: relative;
z-index: 2;
}
.footer-opt {
@ -467,7 +470,7 @@ td.tr-le { color: #E84C4C; }
font-weight: bold;
}
.torrent-info-data {
width: 60%;
width: 50%;
}
.torrent-info-row {
text-align: left;
@ -517,6 +520,10 @@ td.tr-le { color: #E84C4C; }
}
.profile-content {
width: 70%;
text-align: left;
}
div.profile-content.box > nav > ul > li {
border-right-width: 1px;
}
.magnet-icon {
display: inline-block;

Voir le fichier

@ -32,13 +32,6 @@ function switchThemes(){
}
function changeTheme(opt) {
theme = opt.value;
localStorage.setItem("theme", theme);
document.getElementById("theme").href = "/css/" + theme;
console.log(theme);
}
function toggleMascot(btn) {
var state= btn.value;
if (state == "hide") {
@ -86,13 +79,11 @@ window.onload = function() {
};
function playVoice() {
switch (theme) {
case "tomorrow.css":
if (explosion) {
explosion.play();
break;
default:
}
else {
nyanpassu.volume = 0.5;
nyanpassu.play();
break;
}
}

Voir le fichier

@ -11,14 +11,14 @@
<form role="form" method="POST">
<label class="input-label">{{call $.T "api_token" }}:</label>
<p style="font-family: monospace;">{{.APIToken}}</p>
<a class="form-input" href="{{ genRoute "user_profile_apireset" "id" (print .ID) "username" .Username }}">Reset Api key</a> <br> <br>
<a class="form-input up-input" href="{{ genRoute "user_profile_apireset" "id" (print .ID) "username" .Username }}">Reset Api key</a> <br> <br>
<label class="input-label">{{ call $.T "email_address" }}:</label> <br>
<input class="form-input" type="text" name="email" id="email" value="{{.Email}}"> <br>
<input class="form-input up-input" type="text" name="email" id="email" value="{{.Email}}"> <br>
{{ range (index $.FormErrors "email")}}
<p class="text-error">{{ . }}</p>
{{end}}
<label class="input-label">{{ call $.T "language"}}:</label> <br>
<select id="language" name="language" class="form-input">
<select id="language" name="language" class="form-input up-input">
{{ $userLanguage := .Language }}
{{ range $tag, $translatedName := $.Languages }}
<option value="{{ $tag }}" {{ if or (eq $userLanguage $tag) (and (eq $userLanguage "") (eq $tag getDefaultLanguage)) }}selected{{end}}>{{ $translatedName }} {{if eq $tag getDefaultLanguage}}({{ call $.T "default" }}){{end}}</option>
@ -29,18 +29,18 @@
{{end}}
{{ if not (HasAdmin $.User)}}
<label class="input-label">{{ call $.T "current_password"}}:</label> <br>
<input class="form-input" name="current_password" id="current_password" type="password"> <br>
<input class="form-input up-input up-input" name="current_password" id="current_password" type="password"> <br>
{{ range (index $.FormErrors "current_password")}}
<p class="text-error">{{ . }}</p>
{{end}}
{{end}}
<label class="input-label">{{ call $.T "password"}}:</label> <br>
<input class="form-input" name="password" id="password" type="password"> <br>
<input class="form-input up-input up-input" name="password" id="password" type="password"> <br>
{{ range (index $.FormErrors "password")}}
<p class="text-error">{{ . }}</p>
{{end}}
<label class="input-label">{{ call $.T "confirm_password"}}:</label> <br>
<input class="form-input" name="password_confirmation" id="password_confirmation" type="password"> <br>
<input class="form-input up-input up-input" name="password_confirmation" id="password_confirmation" type="password"> <br>
{{ range (index $.FormErrors "password_confirmation")}}
<p class="text-error">{{ . }}</p>
{{end}}
@ -48,7 +48,7 @@
{{ with .Settings }}
{{ if DefaultUserSettings "new_torrent"}}
<label class="input-label">{{ call $.T "new_torrent_settings" }}:</label> <br>
<select id="new_torrent" name="new_torrent" class="form-control">
<select id="new_torrent" name="new_torrent" class="form-input up-input">
<option value="0" {{ if not (.Get "new_torrent") }}selected{{end}}>{{ call $.T "no"}}</option>
<option value="1" {{ if .Get "new_torrent" }}selected{{end}}>{{ call $.T "yes"}}</option>
</select> <br>
@ -58,7 +58,7 @@
{{end}}
{{ if DefaultUserSettings "new_torrent_email"}}
<label class="input-label">{{ call $.T "new_torrent_email_settings" }}:</label> <br>
<select id="new_torrent_email" name="new_torrent_email" class="form-control">
<select id="new_torrent_email" name="new_torrent_email" class="form-input up-input">
<option value="0" {{ if not (.Get "new_torrent_email") }}selected{{end}}>{{ call $.T "no"}}</option>
<option value="1" {{ if .Get "new_torrent_email"}}selected{{end}}>{{ call $.T "yes"}}</option>
</select> <br>
@ -68,7 +68,7 @@
{{end}}
{{ if DefaultUserSettings "new_comment"}}
<label class="input-label">{{ call $.T "new_comment_settings" }}:</label> <br>
<select id="new_comment" name="new_comment" class="form-control">
<select id="new_comment" name="new_comment" class="form-input up-input">
<option value="0" {{ if not (.Get "new_comment") }}selected{{end}}>{{ call $.T "no"}}</option>
<option value="1" {{ if .Get "new_comment" }}selected{{end}}>{{ call $.T "yes"}}</option>
</select> <br>
@ -78,7 +78,7 @@
{{end}}
{{ if DefaultUserSettings "new_comment_email"}}
<label class="input-label">{{ call $.T "new_comment_email_settings" }}:</label> <br>
<select id="new_comment_email" name="new_comment_email" class="form-control">
<select id="new_comment_email" name="new_comment_email" class="form-input up-input">
<option value="0" {{ if not (.Get "new_comment_email") }}selected{{end}}>{{ call $.T "no"}}</option>
<option value="1" {{ if .Get "new_comment_email" }}selected{{end}}>{{ call $.T "yes"}}</option>
</select> <br>
@ -88,7 +88,7 @@
{{end}}
{{ if DefaultUserSettings "new_responses"}}
<label class="input-label">{{ call $.T "new_responses_settings" }}:</label> <br>
<select id="new_responses" name="new_responses" class="form-control">
<select id="new_responses" name="new_responses" class="form-input up-input">
<option value="0" {{ if not (.Get "new_responses") }}selected{{end}}>{{ call $.T "no"}}</option>
<option value="1" {{ if .Get "new_responses" }}selected{{end}}>{{ call $.T "yes"}}</option>
</select> <br>
@ -98,7 +98,7 @@
{{end}}
{{ if DefaultUserSettings "new_responses_email"}}
<label class="input-label">{{ call $.T "new_responses_email_settings" }}:</label> <br>
<select id="new_responses_email" name="new_responses_email" class="form-control">
<select id="new_responses_email" name="new_responses_email" class="form-input up-input">
<option value="0" {{ if not (.Get "new_responses_email") }}selected{{end}}>{{ call $.T "no"}}</option>
<option value="1" {{ if .Get "new_responses_email" }}selected{{end}}>{{ call $.T "yes"}}</option>
</select> <br>
@ -108,7 +108,7 @@
{{end}}
{{ if DefaultUserSettings "new_follower"}}
<label class="input-label">{{ call $.T "new_follower_settings" }}:</label> <br>
<select id="new_follower" name="new_follower" class="form-control">
<select id="new_follower" name="new_follower" class="form-input up-input">
<option value="0" {{ if not (.Get "new_follower") }}selected{{end}}>{{ call $.T "no"}}</option>
<option value="1" {{ if .Get "new_follower" }}selected{{end}}>{{ call $.T "yes"}}</option>
</select> <br>
@ -118,7 +118,7 @@
{{end}}
{{ if DefaultUserSettings "new_follower_email"}}
<label class="input-label">{{ call $.T "new_follower_email_settings" }}:</label> <br>
<select id="new_follower_email" name="new_follower_email" class="form-control">
<select id="new_follower_email" name="new_follower_email" class="form-input up-input">
<option value="0" {{ if not (.Get "new_follower_email") }}selected{{end}}>{{ call $.T "no"}}</option>
<option value="1" {{ if .Get "new_follower_email"}}selected{{end}}>{{ call $.T "yes"}}</option>
</select> <br>
@ -128,7 +128,7 @@
{{end}}
{{ if DefaultUserSettings "followed"}}
<label class="input-label">{{ call $.T "followed_settings" }}:</label> <br>
<select id="followed" name="followed" class="form-control">
<select id="followed" name="followed" class="form-input up-input">
<option value="0" {{ if not (.Get "followed") }}selected{{end}}>{{ call $.T "no"}}</option>
<option value="1" {{ if .Get "followed" }}selected{{end}}>{{ call $.T "yes"}}</option>
</select><br>
@ -138,7 +138,7 @@
{{end}}
{{ if DefaultUserSettings "followed_email"}}
<label class="input-label">{{ call $.T "followed_email_settings" }}:</label> <br>
<select id="followed_email" name="followed_email" class="form-control">
<select id="followed_email" name="followed_email" class="form-input up-input">
<option value="0" {{ if not (.Get "followed_email") }}selected{{end}}>{{ call $.T "no"}}</option>
<option value="1" {{ if .Get "followed_email" }}selected{{end}}>{{ call $.T "yes"}}</option>
</select> <br>
@ -150,12 +150,12 @@
{{ if HasAdmin $.User}}
<h3>{{ call $.T "moderation"}}</h3>
<label class="input-label">{{ call $.T "username"}}:</label> <br>
<input class="form-control" name="username" id="username" type="text" value="{{.Username}}">
<input class="form-input up-input" name="username" id="username" type="text" value="{{.Username}}">
{{ range (index $.FormErrors "username")}}
<p class="text-error">{{ . }}</p>
{{end}}
<label class="input-label">{{ call $.T "role" }}:</label>
<select id="status" name="status" class="form-control">
<select id="status" name="status" class="form-input up-input">
<option value="-1" {{ if eq .Status -1 }}selected{{end}}>{{ call $.T "banned"}}</option>
<option value="0" {{ if eq .Status 0 }}selected{{end}}>{{ call $.T "member"}} ({{ call $.T "default" }})</option>
<option value="1" {{ if eq .Status 1 }}selected{{end}}>{{ call $.T "trusted_member"}}</option>
@ -168,9 +168,9 @@
{{end}}
{{end}}
<label class="input-label"></label>
<input type="submit" class="btn btn-primary" name="save" value="{{ call $.T "save_changes"}}">
<input type="submit" class="form-input" name="save" value="{{ call $.T "save_changes"}}">
<span></span>
<input type="reset" class="btn btn-default" value="{{ call $.T "cancel"}}">
<input type="reset" class="form-input" value="{{ call $.T "cancel"}}">
</form>
</div>
{{ if CurrentOrAdmin $.User .ID }}

Voir le fichier

@ -44,7 +44,7 @@
<td class="tr-size hide-xs">
{{ fileSize .Filesize $.T }}
</td>
<td class="tr-date home-td date-short hide-xs">{{.Date}}</td>
<td class="tr-date date-short hide-xs">{{.Date}}</td>
</tr>
{{end}}
{{end}}

Voir le fichier

@ -73,14 +73,16 @@
{{block "content" .}}{{call $.T "nothing_here"}}{{end}}
</div>
<div id="mascot" class="hide-xs" onclick="playVoice();"></div>
{{ if eq .Theme "tomorrow" }}
<audio id="explosion" hidden preload="none">
<source src="https://megumin.love/sounds/explosion.mp3" type="audio/mpeg">
</audio>
{{ else }}
<audio id="nyanpassu" hidden preload="none">
<source src="https://a.doko.moe/sewang.mp3" type="audio/mpeg">
</audio>
<audio id="explosion" hidden preload="none">
<source src="https://megumin.love/sounds/explosion.mp3" type="audio/mpeg">
</audio>
<div class="pagination">
{{end}}
<div class="pagination">
{{ genNav .Navigation .URL 15 }}
</div>

Voir le fichier

@ -8,7 +8,7 @@
{{end}}
<h3>{{call $.T "name"}}</h3>
<input type="text" name="name" id="name" class="form-input up-input" placeholder="{{call $.T "file_name"}}" value="{{.Name}}" autofocus required>
<input type="text" name="name" id="name" class="form-input up-input" placeholder="{{call $.T "file_name"}}" value="{{.Name}}" autofocus>
<h3>{{call $.T "torrent_file"}}</h3>
<input type="file" name="torrent" id="torrent" class="up-input" accept=".torrent">

Voir le fichier

@ -64,7 +64,9 @@
</table>
<div class="torrent-buttons">
<a href="{{.Magnet}}" class="form-input">{{call $.T "magnet_link"}}</a>
{{ if ne .TorrentLink ""}}
<a href="{{.TorrentLink}}" class="form-input">{{call $.T "torrent_file"}}</a>
{{end}}
{{ if gt $.User.ID 0}}
<script>
function reportPopup() {