Compare commits

...

6 Commits

Author SHA1 Message Date
R. Miles McCain
dd6a9d1eaf Bump version 2020-04-28 10:19:05 -04:00
R. Miles McCain
3c74331a74 Fix x-padding on smaller screen sizes (fixes #7) 2020-04-28 10:18:43 -04:00
R. Miles McCain
7bfcb1caff Add reference to a17t 2020-04-28 10:15:35 -04:00
R. Miles McCain
f7e8580114 Add service screenshot 2020-04-25 12:02:32 -04:00
R. Miles McCain
25b7b1d0e5 Show version in sidebar (fixes #5) 2020-04-25 11:55:56 -04:00
R. Miles McCain
2223530f51 Show IP address in session details (fixes #6) 2020-04-25 11:55:31 -04:00
7 changed files with 31 additions and 10 deletions

View File

@@ -8,7 +8,7 @@
<br> <br>
<strong><a href="#installation">Getting started »</a></strong> <strong><a href="#installation">Getting started »</a></strong>
</p> </p>
<p align="center"><a href="#screenshots">Screenshots</a> &bull; <a href="#features">Features</a> &bull; <a href="#roadmap">Roadmap</a></p> <p align="center"><a href="#screenshots">Screenshots</a> &bull; <a href="#features">Features</a> &bull; <a href="https://github.com/milesmcc/a17t">Design</a></p>
</p> </p>
<br> <br>
@@ -34,7 +34,12 @@ _Note: These screenshots have been edited to hide sensitive data. The "real" Shy
![Shynet's homepage](images/homepage.png) ![Shynet's homepage](images/homepage.png)
_Shynet's homepage, where you can see all of your services at a glance._ _Shynet's homepage, where you can see all of your services at a glance._
Not shown: service view, management view, session view, full service view. (You'll need to install Shynet to see those!) ![A service page](images/service.png)
_A real service page, where you can see higher-level details about a site._
Not shown: management view, session view, full service view. (You'll need to install Shynet for yourself to see those!)
> **Shynet is built using [a17t](https://github.com/milesmcc/a17t),** an atomic design library. Customization and extension is simple; [learn more about a17t](https://github.com/milesmcc/a17t).
## Features ## Features

BIN
images/service.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 589 KiB

View File

@@ -1,4 +1,4 @@
{% load static rules %} {% load static rules helpers %}
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
@@ -20,8 +20,8 @@
<body class="bg-gray-200 min-h-full"> <body class="bg-gray-200 min-h-full">
{% block body %} {% block body %}
<section class="max-w-screen-xl mx-auto px-4 md:px-0 py-4 md:py-12 md:flex"> <section class="max-w-screen-xl mx-auto px-4 py-4 md:py-12 md:flex">
<aside class="mb-8 md:w-2/12 md:pr-6 relative flex flex-wrap md:block justify-between items-center"> <aside class="mb-8 md:w-2/12 md:pr-6 relative flex flex-wrap md:block justify-between items-center overflow-x-hidden">
<a class="icon ~urge ml-2 md:ml-6 md:mb-8 md:mt-3" href="{% url 'dashboard:dashboard' %}"> <a class="icon ~urge ml-2 md:ml-6 md:mb-8 md:mt-3" href="{% url 'dashboard:dashboard' %}">
<i class="fas fa-binoculars fa-3x text-purple-600 hidden md:block"></i> <i class="fas fa-binoculars fa-3x text-purple-600 hidden md:block"></i>
<i class="fas fa-binoculars fa-2x text-purple-600 md:hidden"></i> <i class="fas fa-binoculars fa-2x text-purple-600 md:hidden"></i>
@@ -93,6 +93,10 @@
{% include 'dashboard/includes/sidebar_portal.html' with label="Sign Up" url=url %} {% include 'dashboard/includes/sidebar_portal.html' with label="Sign Up" url=url %}
{% endif %} {% endif %}
<hr class="sep h-8">
{% sidebar_footer %}
</div> </div>
</aside> </aside>
<div class="md:w-10/12"> <div class="md:w-10/12">

View File

@@ -0,0 +1,5 @@
<div class="pl-2">
<p class="support text-gray-600">
<a href="https://github.com/milesmcc/shynet">Shynet {{version}}</a>
</p>
</div>

View File

@@ -59,8 +59,8 @@
</p> </p>
</div> </div>
<div> <div>
<p>Time Zone</p> <p>IP</p>
<p class="label">{{session.time_zone|default:"Unknown"}}</p> <p class="label" title="{{session.ip}}">{{session.ip|truncatechars:"16"}}</p>
</div> </div>
</div> </div>
</article> </article>

View File

@@ -3,6 +3,7 @@ from urllib.parse import urlparse
import flag import flag
import pycountry import pycountry
from django import template from django import template
from django.conf import settings
from django.utils import timezone from django.utils import timezone
from django.utils.html import escape from django.utils.html import escape
from django.utils.safestring import SafeString from django.utils.safestring import SafeString
@@ -80,6 +81,11 @@ def percent_change_display(start, end):
return SafeString(direction + pct_change) return SafeString(direction + pct_change)
@register.inclusion_tag("dashboard/includes/sidebar_footer.html")
def sidebar_footer():
return {
"version": settings.VERSION
}
@register.inclusion_tag("dashboard/includes/stat_comparison.html") @register.inclusion_tag("dashboard/includes/stat_comparison.html")
def compare( def compare(

View File

@@ -1,7 +1,5 @@
""" """
Django settings for shynet project. Django settings for Shynet.
Generated by 'django-admin startproject' using Django 2.2.5.
For more information on this file, see For more information on this file, see
https://docs.djangoproject.com/en/2.2/topics/settings/ https://docs.djangoproject.com/en/2.2/topics/settings/
@@ -15,6 +13,9 @@ import os
# Messages # Messages
from django.contrib.messages import constants as messages from django.contrib.messages import constants as messages
# Increment on new releases
VERSION = "v0.2.2"
# Build paths inside the project like this: os.path.join(BASE_DIR, ...) # Build paths inside the project like this: os.path.join(BASE_DIR, ...)
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))