Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
Wumpuspro authored Aug 15, 2021
1 parent c6d1cbf commit 6e49d5d
Show file tree
Hide file tree
Showing 48 changed files with 1,551 additions and 0 deletions.
12 changes: 12 additions & 0 deletions dashboard/.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
API_URL=localhost:4000/api/v1,
BOT_ROLE_ID=861875883190255646,
BOT_TOKEN=ODYxODg2OTEyNjE2OTg4Njcy.YOQUvQ._nTVCqkKoQFkYLLqK9VwWefVGBQ,
CLIENT_ID=861886912616988672,
CLIENT_SECRET=861886912616988672,
DASHBOARD_URL=localhost:3000,
DEV_ROLE_ID=861876106130489415,
DOWNTIME_CHANNEL_ID=861879504447995925,
GUILD_ID=861875493245419521,
LOG_CHANNEL_ID=861879665232576534,
MONGO_URI=mongodb+srv://wumpusdiscordbotlist:[email protected]/myFirstDatabase?retryWrites=true&w=majority,
PORT=3000
37 changes: 37 additions & 0 deletions dashboard/assets/css/charts.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
.charts {
display: flex;
justify-content: space-between;
text-align: center;
}

.charts svg {
display: flex;
float: left;
}

.ct-series-a .ct-line,
.ct-series-a .ct-point {
stroke: var(--success);
stroke-width: 4px;
}
.ct-series-b .ct-line,
.ct-series-b .ct-point {
stroke: var(--danger);
stroke-width: 4px;
}

.ct-series-a .ct-area {
fill: var(--success);
}
.ct-series-b .ct-area {
fill: var(--danger);
}

.ct-grids line,
.ct-labels span,
.ct-grid.ct-horizontal {
color: var(--font);
}
.ct-grid {
stroke: transparent;
}
20 changes: 20 additions & 0 deletions dashboard/assets/css/commands.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#search {
max-width: 300px;
}
#search + button {
height: 64px;
}

li {
cursor: pointer;
}

.commands li {
margin: 5px 0;
border-radius: 5px;
border: 1px solid var(--font) !important;
}

.list-group-item {
background-color: inherit;
}
3 changes: 3 additions & 0 deletions dashboard/assets/css/index.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.jumbotron {
margin-top: 25vh;
}
21 changes: 21 additions & 0 deletions dashboard/assets/css/leaderboard.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
h1 img {
height: 64px;
}

li.list-group-item {
background-color: var(--background-secondary);
color: var(--heading);
}

li:nth-of-type(1) {
background: linear-gradient(to bottom, #C5B358 0%, #B6A449 100%);
color: white;
}
li:nth-of-type(2) {
background: linear-gradient(to bottom, #C0C0C0 0%, #B1B1B1 100%);
color: white;
}
li:nth-of-type(3) {
background: linear-gradient(to bottom, #CD7F32 0%, #BE7023 100%);
color: white;
}
29 changes: 29 additions & 0 deletions dashboard/assets/css/main.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
body {
overflow-x: hidden;
background-color: var(--background-primary);
color: var(--font);
}

h1, h2, h3, h4, h5 {
color: var(--heading);
}

code.hljs {
background-color: var(--background-secondary);
}

.user-avatar {
max-width: 36px;
}

.navbar a {
color: var(--heading);
}

.table {
color: var(--heading);
}

.dropdown-menu {
background-color: inherit;
}
45 changes: 45 additions & 0 deletions dashboard/assets/css/music.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
.card-header img {
width: 128px;
height: 128px;
object-fit: cover;
border-radius: 15px;
}

.buttons,
#volume {
text-align: center;
}
.q-control,
.position {
display: flex;
justify-content: center;
}

.form-control,
.btn {
box-shadow: none !important;
outline: none !important;
}

.track-list img {
width: 64px;
height: 64px;
object-fit: cover;
border-radius: 10px;
}

#trackSearch {
margin-top: 20px;
max-height: 42px;
}

#volume {
cursor: pointer;
}
#volume input {
opacity: 0;
transition: opacity .3s ease-in-out;
}
#volume:hover input {
opacity: 1;
}
97 changes: 97 additions & 0 deletions dashboard/assets/css/sidebar.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
.icon, .icon img {
font-size: x-large;

height: 52px;
width: 52px;

transition: border-radius .3s ease-in-out;
}
.icon:hover, .icon img:hover {
border-radius: 15% !important;
}
.abbr {
padding-top: 7.5px;
}

.hamburger {
cursor: pointer;
font-size: xxx-large;

bottom: 0;
position: absolute;
}

#sidebar {
padding: 10px;
background-color: var(--background-tertiary);
}
#sidebar,
#sidebarExtension {
height: 100vh;
float: left;
}

/* extension */
#sidebarExtension {
width: 275px;
transition: .3s;
opacity: 1;
background-color: var(--background-secondary);
}
#sidebarExtension .large-icon {
display: block;
margin-left: auto;
margin-right: auto;
width: 50%;
}
#sidebarExtension .large-icon,
#sidebarExtension img {
font-size: xx-large;

width: 96px;
height: 96px;
}
#sidebarExtension .abbr {
padding-top: 25px;
}
#sidebarExtension h4 {
cursor: pointer;
}

#sidebarExtension.closed {
width: 0;
padding: 0px 0;
}
#sidebarExtension.closed {
opacity: 0;
}

/* tabs */
.tabs a {
margin: 2px 10px;
padding: 5px;
padding-left: 10px !important;
border-radius: 5px;

text-decoration: none;
color: var(--font);
}
.tabs a.active,
.tabs a:hover {
background-color: var(--background-primary);
}

.tabs .category {
padding: 24px 0 4px 24px;
font-size: 12px;
text-transform: uppercase;
font-weight: 700;

color: gray;
cursor: pointer;

transition: color .3s ease-in-out;
}
.tabs .category:hover {
color: var(--heading);
}
22 changes: 22 additions & 0 deletions dashboard/assets/css/theme.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
:root,
:root[theme='ASCETIC'] {
--primary: black;

--heading: black;
--font: black;

--background-primary: white;
--background-secondary: #F8F9FA;
--background-tertiary: #F8F9FA;
}

:root[theme='DISCORD'] {
--primary: #7289DA;

--heading: white;
--font: #99AAB5;

--background-primary: #36393F;
--background-secondary: #2F3136;
--background-tertiary: #202225;
}
28 changes: 28 additions & 0 deletions dashboard/assets/css/utils.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
.round {
border-radius: 50% !important;
}

.shadow {
box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06) !important;
}

.cursor-pointer {
cursor: pointer !important;
}

/* buttons */
.btn-gradient {
background-image: linear-gradient(135deg, var(--secondary), var(--info));
color: white;
}
.btn-gradient:hover {
color: white;
}

/* text */
.text-gradient {
background: linear-gradient(135deg, var(--secondary), var(--info));
background-clip: text;
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
}
11 changes: 11 additions & 0 deletions dashboard/assets/js/charts.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
function initChart(selector, ...log) {
new Chartist.Line(selector, {
labels: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],
series: [...log]
}, { low: Math.min(log), showArea: true });
}

initChart('.joins-chart', joinsLog, leavesLog);
initChart('.punishments-chart', punishmentsLog);
initChart('.messages-chart', messagesLog);
initChart('.commands-chart', commandsLog);
51 changes: 51 additions & 0 deletions dashboard/assets/js/commands.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
$('.categories li').on('click', setCategory);

function setCategory() {
blank();

const selected = $(this);
selected.addClass('active');

const categoryCommands = $(`.commands .${selected[0].id}`);
categoryCommands.show();

updateResultsText(categoryCommands);
}
function blank() {
$('.categories li').removeClass('active');
$('.commands li').hide();
}

$('#search + button').on('click', () => {
const query = $('#search input').val();
if (!query.trim()) {
updateResultsText(commands);
return $('.commands li').show();
}

const results = new Fuse(commands, {
isCaseSensitive: false,
keys: [
{ name: 'name', weight: 1 },
{ name: 'category', weight: 0.5 }
]
})
.search(query)
.map(r => r.item);

blank();

for (const command of results)
$(`#${command.name}Command`).show();

updateResultsText(results);
});

function updateResultsText(arr) {
$('#commandError').text(
(arr.length <= 0)
? 'There is nothing to see here.'
: '');
}

setCategory.bind($('.categories li')[0])();
Loading

0 comments on commit 6e49d5d

Please sign in to comment.