65 lines
2.3 KiB
XML
65 lines
2.3 KiB
XML
<svg xmlns="http://www.w3.org/2000/svg" width="480" height="99999" class="<%= !animated ? 'no-animations' : '' %>">
|
|
<%
|
|
meta.$ = `<span class="ps1-path">${`${user.login}`.toLocaleLowerCase()}@metrics</span>:<span class="ps1-location">~</span>${computed.token.scopes.includes("repo") ? "#" : "$"}`
|
|
meta.animations = !meta.placeholder ? {stdin:.16, stdout:.28, length:(2+Object.keys(base).length+Object.keys(plugins).length)} : {stdin:0, stdout:0, length:0}
|
|
%>
|
|
|
|
<defs><style><%= fonts %></style></defs>
|
|
|
|
<style data-optimizable="true">
|
|
<%= style %>
|
|
.stdin, .stdout {
|
|
animation-duration: <%= meta.animations.stdin %>s;
|
|
}
|
|
.stdout {
|
|
animation-duration: <%= meta.animations.stdout %>s;
|
|
}
|
|
<% for (let i = 0, d = 0; i < meta.animations.length; i++, d+=meta.animations.stdin+meta.animations.stdout) { %>
|
|
.stdin:nth-of-type(<%= i+1 %>) {
|
|
animation-delay: <%= d %>s;
|
|
}
|
|
.stdout:nth-of-type(<%= i+2 %>) {
|
|
animation-delay: <%= d+meta.animations.stdin %>s;
|
|
}
|
|
<% if (i === meta.animations.length-1) { %>
|
|
footer {
|
|
animation-delay: <%= d %>s;
|
|
}
|
|
<% } %>
|
|
<% } %>
|
|
</style>
|
|
<style><%= extras.css %></style>
|
|
|
|
<foreignObject x="0" y="0" width="100%" height="100%">
|
|
<div xmlns="http://www.w3.org/1999/xhtml" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
|
|
<div class="header">
|
|
<span class="title"></span>
|
|
<div class="buttons">
|
|
<div class="button">─</div>
|
|
<div class="button">□</div>
|
|
<div class="button exit">✕</div>
|
|
</div>
|
|
</div>
|
|
|
|
<pre><%# -%>
|
|
<% if (base.metadata) { %>
|
|
<div class="banner"><%# -%>
|
|
Metrics generator <%= meta.version %>
|
|
These generated metrics comes with ABSOLUTELY NO
|
|
WARRANTY, to the extent permitted by applicable law.
|
|
|
|
Last generated: <%= meta.generated %>
|
|
</div><% } -%>
|
|
<% for (const partial of [...partials]) { %><%- await include(`partials/${partial}.ejs`) %><% } -%>
|
|
<% if (base.metadata) { -%>
|
|
|
|
<footer>Connection reset by <%= Math.floor(256*Math.random()) %>.<%= Math.floor(256*Math.random()) %>.<%= Math.floor(256*Math.random()) %>.<%= Math.floor(256*Math.random()) %></footer><%# -%>
|
|
<% } -%></pre>
|
|
|
|
</div>
|
|
<div id="metrics-end"></div>
|
|
</foreignObject>
|
|
</svg>
|
|
|