tools/module/discord/pages/index.go.html

160 lines
5.2 KiB
HTML
Raw Permalink Normal View History

2022-03-28 21:22:34 +01:00
<!DOCTYPE html>
<html lang="en-GB">
<head>
2022-04-04 22:07:15 +01:00
<meta name="viewport" content="width=device-width, initial-scale=1">
2022-03-28 21:22:34 +01:00
<title>Discord | Melon Tools</title>
<style>
html, body {
background-color: #2a2c2d;
color: #d8d4d0;
}
a {
color: #4699fa;
}
2022-03-28 21:22:34 +01:00
.page-content {
}
.page-row {
2022-03-28 21:22:34 +01:00
display: flex;
flex-direction: row;
align-items: flex-start;
flex-wrap: wrap;
}
.page-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}
2022-03-28 21:22:34 +01:00
.connected-accounts li a[data-is-revoked=true] {
border: 2px solid red;
}
.guilds .guild-item {
margin: 8px;
border: 1px solid black;
padding: 8px;
border-radius: 8px;
}
.colour-block {
display: inline-block;
width: 18px;
height: 18px;
}
2022-03-28 21:22:34 +01:00
</style>
</head>
<body>
2022-05-16 12:54:08 +01:00
<h1>Discord | <a href="/">Melon Tools</a></h1>
2022-03-28 21:22:34 +01:00
<div class="page-content">
<div class="page-row">
<div>
{{with .User}}
<p>My User: {{.Username}}#{{.Discriminator}}</p>
<ul>
<li>ID: {{.ID}}</li>
<li>Email: {{.Email}}</li>
<li>Username: {{.Username}}</li>
<li>Avatar: <img src="{{$.Avatar}}" alt="User Avatar"/></li>
<li>Locale: {{.Locale}}</li>
<li>Discriminator: {{.Discriminator}}</li>
<li>Verified: {{.Verified}}</li>
<li>MFA: {{.MFAEnabled}}</li>
<li>Banner: <img src="{{$.Banner}}" alt="User Banner"/></li>
<li>Accent Color: {{$.UserAccent}} <span class="colour-block"
style="background-color: {{$.UserAccent}}">&nbsp;</span>
</li>
<li>Bot: {{.Bot}}</li>
<li>Premium: {{.PremiumType}}</li>
<li>System: {{.System}}</li>
</ul>
{{end}}
</div>
<div>
{{with .User.PublicFlags}}
<p>My Flags:</p>
<ul>
{{if checkFlag . 1}}
<li>Discord Employee</li>
{{end}}
{{if checkFlag . 2}}
<li>Discord Partner</li>
{{end}}
{{if checkFlag . 4}}
<li>Hype Squad Events</li>
{{end}}
{{if checkFlag . 8}}
<li>Bug Hunter Level 1</li>
{{end}}
{{if checkFlag . 64}}
<li>House Bravery</li>
{{end}}
{{if checkFlag . 128}}
<li>House Brilliance</li>
{{end}}
{{if checkFlag . 256}}
<li>House Balance</li>
{{end}}
{{if checkFlag . 512}}
<li>Early Supporter</li>
{{end}}
{{if checkFlag . 1024}}
<li>Team User</li>
{{end}}
{{if checkFlag . 4096}}
<li>System</li>
{{end}}
{{if checkFlag . 16384}}
<li>Bug Hunter Level 2</li>
{{end}}
{{if checkFlag . 65536}}
<li>Verified Bot</li>
{{end}}
{{if checkFlag . 131072}}
<li>Verified Bot Developer</li>
{{end}}
{{if checkFlag . 262144}}
<li>Discord Certified Moderator</li>
{{end}}
{{if checkFlag . 524288}}
<li>Bot HTTP interactions</li>
{{end}}
{{if checkFlag . 4194304}}
<li>Active Developer</li>
{{end}}
</ul>
{{end}}
</div>
<div>
<p>Connections ({{len .Connections}}):</p>
<ul class="connected-accounts">
{{range .Connections}}
<li>
2023-09-22 02:25:09 +01:00
<a {{if connectedLink .}}href="{{connectedLink .}}"{{end}} target="_blank" data-is-revoked="{{.Revoked}}">
<img src="/discord/assets/icon/{{.Type}}.svg" alt="Icon for {{.Type}}"/>
<span>{{.Name}}</span>
</a>
</li>
{{end}}
2022-05-16 12:57:46 +01:00
</ul>
</div>
2022-03-28 21:22:34 +01:00
</div>
2023-09-22 02:22:39 +01:00
<div>
2022-03-28 21:22:34 +01:00
<p>Guilds ({{len .Guilds}}):</p>
<div class="page-grid guilds">
2022-03-28 21:22:34 +01:00
{{range $k, $v := .Guilds}}
2022-05-16 12:57:46 +01:00
<div class="guild-item">
<div><img src="{{index $.GuildIcons $k}}" alt="Icon for {{$v.Name}}"/></div>
2022-05-16 12:57:46 +01:00
<div>{{$v.Name}}</div>
<div>@*{{$v.ID}}</div>
</div>
2022-03-28 21:22:34 +01:00
{{end}}
</div>
</div>
</div>
</body>
</html>