mrfrys-node-server/src/modules/pornvids/views/folders.ejs
2020-11-23 15:10:24 +01:00

144 lines
4.2 KiB
Text
Executable file

<html>
<body bgcolor="#ffeeee">
<head>
<title><%=dirname%></title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=0.6" />
<style>
body {
font: normal 14px Verdana;
}
td {
vertical-align: top;
word-wrap: break-word;
word-break: break-all;
table-layout: fixed;
padding: 0;
vertical-align: middle;
}
a {
color: #0000ff;
}
.subtable {
border-collapse: collapse;
table-layout:fixed;
width:100%
}
.maintable {
border-collapse: collapse;
table-layout:fixed;
width:100%;
padding:0; margin:0;
border: none !important;
}
tr {
width:32%;
}
.butt td {
font: normal 24px Verdana;
font-weight: bold;
}
.watched {
color: #999999;
}
.butt {
cursor: pointer;
width: 100%;
border: none;
text-align: left;
}
.rainbow {
background: linear-gradient( 92deg, #ff0000, #00ffff);
background: -webkit-linear-gradient( 92deg, #ff0000, #00ffff);
background-size:600vw 600vw;
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
animation: textAnimate 4s linear infinite alternate;
}
@keyframes textAnimate {
from {
filter: hue-rotate(0deg);
background-position-x: 0%;
}
to {
filter: hue-rotate(360deg);
background-position-x: 600vw;
}
}
</style>
</head>
<center>
<h1 class="rainbow">
<div>
Hi <%= user.name %> c:
</div>
<div>
gyerekkori videók <%=dirname%>
</div>
</h1>
</center>
<h2>
<a href="<%= url + prevDir%>" >Back</a>
</h2>
</p>
<table class="maintable">
<% for (var i = 0; i < folders.length; i++) { %>
<tr>
<td>
<a
href="<%= url + folders[i].path %>"
style="font-size: 0px"
>
<button
class="butt"
onmouseenter='mouseEnter(this, <%= i %>)'
onmouseleave='mouseLeave(this, <%= i %>)'
>
<table class="subtable <%= folders[i].watched ? 'watched' : '' %>">
<tr height="62">
<td style='width:85%;'>
<%=folders[i].name %>
</td>
<td style='width:15%;'>
<%
if (folders[i].isDir) {
%> <%= "Mappa" %> <%
} else {
if (folders[i].size === 0) {
%> <%= "~0 MB" %> <%
} else {
%> <%= folders[i].size + ' MB' %> <%
}
}
%>
</td>
</tr>
</table>
</button>
</a>
</td>
</tr>
<% } %>
</table>
<a href='/logout'>logout</a>
</body>
<script>
console.log('hi')
function mouseEnter (e, i) {
e.className += ' rainbow'
}
function mouseLeave (e, i) {
e.className = e.className.replace(/ rainbow/g, '')
}
</script>
</html>