mirror of
https://github.com/krateng/maloja.git
synced 2023-08-10 21:12:55 +03:00
Made medals shiny
This commit is contained in:
parent
45e9586951
commit
6cc23caab0
@ -810,10 +810,6 @@ def build_db():
|
||||
scr = a["scrobbles"]
|
||||
|
||||
|
||||
|
||||
|
||||
print(MEDALS)
|
||||
|
||||
log("Database fully built!")
|
||||
|
||||
|
||||
|
@ -19,13 +19,13 @@ def instructions(keys):
|
||||
if "medals" in data and data["medals"] is not None:
|
||||
if "gold" in data["medals"]:
|
||||
for y in data["medals"]["gold"]:
|
||||
html_medals += "<span title='Best Artist in " + str(y) + "' class='gold'><a href='/charts_artists?max=50&in=" + str(y) + "'>" + str(y) + "</a></span>"
|
||||
html_medals += "<a title='Best Artist in " + str(y) + "' class='hidelink medal gold' href='/charts_artists?max=50&in=" + str(y) + "'><span>" + str(y) + "</span></a>"
|
||||
if "silver" in data["medals"]:
|
||||
for y in data["medals"]["silver"]:
|
||||
html_medals += "<span title='Second Best Artist in " + str(y) + "' class='silver'><a href='/charts_artists?max=50&in=" + str(y) + "'>" + str(y) + "</a></span>"
|
||||
html_medals += "<a title='Second Best Artist in " + str(y) + "' class='hidelink medal silver' href='/charts_artists?max=50&in=" + str(y) + "'><span>" + str(y) + "</span></a>"
|
||||
if "bronze" in data["medals"]:
|
||||
for y in data["medals"]["bronze"]:
|
||||
html_medals += "<span title='Third Best Artist in " + str(y) + "' class='bronze'><a href='/charts_artists?max=50&in=" + str(y) + "'>" + str(y) + "</a></span>"
|
||||
html_medals += "<a title='Third Best Artist in " + str(y) + "' class='hidelink medal bronze' href='/charts_artists?max=50&in=" + str(y) + "'><span>" + str(y) + "</span></a>"
|
||||
|
||||
credited = data.get("replace")
|
||||
includestr = " "
|
||||
|
@ -20,6 +20,9 @@ a {
|
||||
a.textlink {
|
||||
color:gold;
|
||||
}
|
||||
a.hidelink:hover {
|
||||
text-decoration:none;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
text-decoration:underline;
|
||||
@ -247,17 +250,49 @@ span.stat_selector_pulse,span.stat_selector_topartists,span.stat_selector_toptra
|
||||
}
|
||||
|
||||
|
||||
/* SHINY*/
|
||||
.medal {
|
||||
top:5px;
|
||||
position:relative;
|
||||
overflow: hidden;
|
||||
display: inline-block;
|
||||
|
||||
.gold,.silver,.bronze {
|
||||
font-size:80%;
|
||||
padding:3px;
|
||||
margin:2px;
|
||||
border-radius:2px;
|
||||
}
|
||||
.gold a:hover,.silver a:hover,.bronze a:hover {
|
||||
text-decoration:none;
|
||||
.medal:after {
|
||||
content: "";
|
||||
position: absolute;
|
||||
top: -110%;
|
||||
left: -210%;
|
||||
width: 200%;
|
||||
height: 200%;
|
||||
opacity: 0;
|
||||
transform: rotate(30deg);
|
||||
|
||||
background: rgba(255, 255, 255, 0.13);
|
||||
background: linear-gradient(
|
||||
to right,
|
||||
rgba(255, 255, 255, 0.13) 0%,
|
||||
rgba(255, 255, 255, 0.13) 77%,
|
||||
rgba(255, 255, 255, 0.5) 92%,
|
||||
rgba(255, 255, 255, 0.0) 100%
|
||||
);
|
||||
}
|
||||
.medal:hover:after {
|
||||
opacity: 1;
|
||||
top: -30%;
|
||||
left: -30%;
|
||||
transition-property: left, top, opacity;
|
||||
transition-duration: 0.7s, 0.7s, 0.15s;
|
||||
transition-timing-function: ease;
|
||||
}
|
||||
.medal:active:after {
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
|
||||
.gold {
|
||||
background-color:gold;
|
||||
|
Loading…
Reference in New Issue
Block a user