Added profile and join analytics
This commit is contained in:
1 parent
ef0725439c
commit
d0a969f145
15 files changed
+227
-33
No files matched your search
@@ -48,6 +48,9 @@
|
||||
<option value="roleplay">Roleplay</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="relative z-0 mb-6 w-full group">
|
||||
<label for="tos" class="ml-2 text-sm font-medium text-gray-900 dark:text-gray-300">Be adding a server you automatically to our <a href="/tos" target="_blank" class="text-blue-700 hover:text-blue-300">Terms of Service</a></label>\
|
||||
</div>
|
||||
<button type="submit" class="text-white bg-blue-700 hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 font-medium rounded-lg text-sm w-full sm:w-auto px-5 py-2.5 text-center dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800">Submit</button>
|
||||
</form>
|
||||
</div>
|
||||
@@ -55,8 +55,8 @@
|
||||
<div class="mt-2 font-italic">
|
||||
<h3 style="color: #5f79da" class="text-uppercase">Referrers</h3>
|
||||
<p style="color: rgb(126, 126, 126)">The domain names of the sites that most redirect to your bot's page.</p>
|
||||
</div>
|
||||
<table id="analytics_referring" class="table table-hover" style="width:100%; color: #fff">
|
||||
</div><br>
|
||||
<table id="analytics_referring" class="w-full text-sm text-left text-gray-500 dark:text-gray-400 table" style="width:100%; color: #fff">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Referring Url</th>
|
||||
@@ -78,21 +78,20 @@
|
||||
<div class="mt-2 font-italic">
|
||||
<h3 style="color: #5f79da" class="text-uppercase">Countries</h3>
|
||||
<p style="color: rgb(126, 126, 126)">These are the countries that enter your bot's page.</p>
|
||||
</div>
|
||||
<table id="analytics_country" class="table table-hover" style="width:100%; color: #fff">
|
||||
<thead>
|
||||
</div><br>
|
||||
<table id="analytics_country" class="w-full text-sm text-left text-gray-500 dark:text-gray-400 table" style="width:100%; color: #fff">
|
||||
<thead class="text-xs uppercase text-white ">
|
||||
<tr>
|
||||
<th>Country</th>
|
||||
<th>Total viewers</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<%
|
||||
if(bot.country) {
|
||||
Object.keys(bot.country).sort((a,b) => bot.country[b] - bot.country[a]).forEach(b => {
|
||||
%>
|
||||
<tr>
|
||||
<td translate="no"><span style="display: flex; align-items: center;"><img src="https://www.countryflags.io/<%= b %>/flat/32.png"> <%= b %></span></td>
|
||||
<td translate="no"><span style="display: flex; align-items: center;"><img src="https://countryflagsapi.com/png/<%= b %>" width="32px"> <%= b %></span></td>
|
||||
<td><span style="display: flex; align-items: center;"><%= bot.country[b] %></span></td>
|
||||
</tr>
|
||||
<%
|
||||
|
||||
@@ -51,6 +51,9 @@
|
||||
}
|
||||
});
|
||||
</script>
|
||||
<div class="relative z-0 mb-6 w-full group">
|
||||
<label for="tos" class="ml-2 text-sm font-medium text-gray-900 dark:text-gray-300">Be adding a server you automatically to our <a href="/tos" target="_blank" class="text-blue-700 hover:text-blue-300">Terms of Service</a></label>\
|
||||
</div>
|
||||
<button type="submit" class="text-white bg-blue-700 hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 font-medium rounded-lg text-sm w-full sm:w-auto px-5 py-2.5 text-center dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800">Submit</button>
|
||||
</form>
|
||||
</div>
|
||||
@@ -1,6 +1,11 @@
|
||||
<%- include("../includes/header.ejs", {title: "Edit " + server.name}) %>
|
||||
<!-- create form -->
|
||||
<div class="container-sm p-10">
|
||||
<a href="/server/<%= server.id %>/analytics" class="text-white bg-blue-700 hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 font-medium rounded-lg text-sm w-full sm:w-auto px-5 py-2.5 text-center dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800">
|
||||
<i class="fas fa-chart-bar"></i>
|
||||
<span>Analytics</span>
|
||||
</a>
|
||||
<br><br>
|
||||
<form method="post" action="">
|
||||
<div class="relative z-0 mb-6 w-full group">
|
||||
<textarea type="text" name="server_description" id="server_name" class="block py-2.5 px-0 w-full text-sm text-gray-900 bg-transparent border-0 border-b-2 border-gray-300 appearance-none dark:text-white dark:border-gray-600 dark:focus:border-blue-500 focus:outline-none focus:ring-0 focus:border-blue-600 peer" placeholder=" " required rows="5"><%= server.long_description %></textarea>
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
<%- include('../includes/header.ejs', {title: 'Join' + server.name}) %>
|
||||
<div class="flex flex-col items-center justify-center h-screen ">
|
||||
<div class="w-96 h-96 bg-blue-color text-white text-center rounded-lg items-center">
|
||||
<h1 class="text-3xl font-bold p-5">Join <%= server.name %></h1>
|
||||
<p>You will be redirect after 3 seconds </p>
|
||||
<div class="flex justify-center">
|
||||
<image src="/gif/loading.gif">
|
||||
<span class="sr-only">Loading...</span>
|
||||
</div>
|
||||
</div>
|
||||
<!-- script to redirect -->
|
||||
<script>
|
||||
setTimeout(function() {
|
||||
window.location.href = '<%= server.invite %>';
|
||||
}, 3000);
|
||||
</script>
|
||||
</div>
|
||||
</div>
|
||||
<%- include('../includes/footer.ejs') %>
|
||||
File renamed without changes.
@@ -0,0 +1,59 @@
|
||||
<%- include('../includes/header.ejs', {title: 'User' + dcuser.username}) %>
|
||||
<br><br><br><br>
|
||||
<div class="lg:flex space-x-4 py-2 lg:h-5/6 sm:min-h-min">
|
||||
<div class="p-10 bg-blue-color w-full text-white h-full m-4 lg:mx-14 text-ellipsis lg:w-2/3">
|
||||
<p class="text-white text-clip">
|
||||
<pre style="white-space: pre-wrap;" class="text-clip break-wordsw-full h-full"><br><%= users.biography || "User Has No biography" %></pre>
|
||||
</p>
|
||||
</div>
|
||||
<div class="bg-blue-color w-full p-10 text-white h-full lg:w-1/4 lg:m-4">
|
||||
<img class="w-full rounded-full max-w-xs" src="https://cdn.discordapp.com/avatars/<%=dcuser.id %>/<%=dcuser.avatar %>.png" alt="<%= dcuser.name %>" onerror="this.src='/img/logo.png'">
|
||||
<h1 class="text-3xl">
|
||||
<%= dcuser.tag %>
|
||||
</h1>
|
||||
<!-- edit button -->
|
||||
<!-- fontawome icon -->
|
||||
<div class="flex">
|
||||
<a href="/user/edit" class="text-white text-sm">
|
||||
<i class="fa fa-edit"></i> Edit
|
||||
</a>
|
||||
</div>
|
||||
<% if(typeof users.website != "undefined") { %>
|
||||
<a href="<%= users.website %>" target="_blank" class="text-white text-clip">
|
||||
<i class="fab fa-website"></i>
|
||||
<%= users.website %>
|
||||
<br>
|
||||
</a>
|
||||
<% } %>
|
||||
<% if(typeof users.twitter != "undefined" ) { %>
|
||||
<a href="https://twitter.com/<%= users.twitter %>" target="_blank" class="text-white text-clip">
|
||||
<i class="fab fa-facebook"></i>
|
||||
<%= users.twitter %>
|
||||
<br>
|
||||
</a>
|
||||
<% } %>
|
||||
<% if(typeof users.instagram != "undefined") { %>
|
||||
<a href="https://instagram.com/<%= users.instagram %>" target="_blank" class="text-white text-clip">
|
||||
<i class="fab fa-instagram"></i>
|
||||
<%= users.instagram %>
|
||||
<br>
|
||||
</a>
|
||||
<% } %>
|
||||
<% if(typeof users.facebook != "undefined") { %>
|
||||
<a href="https://facebook.com/<%= users.facebook %>" target="_blank" class="text-white text-clip">
|
||||
<i class="fab fa-facebook"></i>
|
||||
<%= users.facebook %>
|
||||
<br>
|
||||
</a>
|
||||
<% } %>
|
||||
<% if(typeof users.github != "undefined") { %>
|
||||
<a href="https://youtube.com/<%= users.github %>" target="_blank" class="text-white text-clip">
|
||||
<i class="fab fa-github"></i>
|
||||
<%= users.github %>
|
||||
<br>
|
||||
</a>
|
||||
<% } %>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<br><br><br>
|
||||
@@ -1 +0,0 @@
|
||||
<%- include('../../includes/header.ejs', {title: 'User' + user.username}) %>
|
||||
Reference in new issue
Block a user