some documents

This commit is contained in:
Evert Prants 2017-08-03 18:49:31 +03:00
parent d178a8ee40
commit c7d348b27d
Signed by: evert
GPG Key ID: 1688DA83D222D0B5
10 changed files with 185 additions and 8 deletions

View File

@ -0,0 +1,21 @@
<div class="tos">
<h1>Privacy Policy</h1>
<p>By using Services of Icy Network, you acknowledge and agree to these policies.</p>
<h2>Information We Collect and Use</h2>
<p>Icy Network may collect and save some information about our users.</p>
<h3>Basic Account Information</h3>
<p>Icy Network uses your username to identify you in our system. Please only enter Usernames which you are comfortable with other people seeing.</p>
<p>Your email addess is used to send you updates and important information about our Services and the status of your account. You may unsubscribe from update emails at any time. We will never provide, sell, or leak your email address to Third-Party sites nor send you malicious or spam emails. Please always verify that the sender is an IcyNet.eu email address before clicking on any links on emails claiming to be from us. We will never ask you for your personal information or passwords via email.</p>
<h3>Additional Information</h3>
<p>We use your IP Address to track our visitor traffic in order for us to better allocate resources to the Services which are used the most. Your IP address is not available publicly and is only used internally within our systems.</p>
<h2>Cookies</h2>
<p>Like many websites, we use Cookies in our Services. A Cookie is a small file saved onto your computer by your web browser which contains a bit of information about your presence on Icy Network websites. Icy Network uses temporary session cookies in order to save log-in sessions, which means that you won't have to log in every time you visit our website.</p>
<h2>External Logins</h2>
<p>By logging in from external websites, you agree to these Policies.</p>
<h3>Twitter</h3>
<p>By logging in with Twitter, we will only ask you for your Screen Name, Public Profile Name and Email Address for the above-mentioned purposes. We will never Tweet on your behalf nor see your Tweets.</p>
<h3>Facebook</h3>
<p>By logging in with Facebook, we will only ask you for your Public Profile and Email Address. We will use your Name as your Display Name, which can be changed from your Account Settings after logging in. Your profile picture may be downloaded onto our servers and used as your network-wide profile image. You may change your profile picture from your Account Settings at any time. Your Email Address will only be used to send you updates, which you can opt-out of. We can not and will not post on your behalf.</p>
<h3>Discord</h3>
<p>By logging in with Discord, we will only ask you for your Username and Email Address for the above-mentioned purposes. We do not ask you for any other information and we will not know which Discord Servers you're on.</p>
</div>

View File

@ -0,0 +1,33 @@
<div class="tos">
<h1>Terms of Service</h1>
<p>Please read the following Terms and Conditions carefully. By using Icy Network services, you signify that you have read, understood and agreed to be bound by these Terms and Conditions. Icy Network reserves the right to modify, replace or remove any of the Terms and Conditions written in this document at any given time without restrictions. We will try to notify you of any such amendments. If you do not agree to these Terms and Conditions, you may not use any of the services provided by Icy Network.</p>
<p>Separate entities owned by Icy Network may have their own Terms and Conditions which you must read and comply with.</p>
<h2>Who May Use the Services</h2>
<p>You may use our Services only if you have not been previously unauthorized of doing so and that you are above the legal age of 13. Our Services may contain inappropriate language or images not suitable for minors.</p>
<h2>Privacy</h2>
<p>Icy Network requires you to sign up for an account or log in using another external website. Please read our <a href="/docs/privacy-policy">Privacy Policies</a> before entering any information into our Services to understand what information we may collect and what it's used for.</p>
<h2>Content on the Services</h2>
<p>You are responsible for your use of the Services and the Content you provide to our Services, including complicance with laws, rules and regulations. You should only provide Content you are comfortable sharing with others.</p>
<p>Icy Network is not responsible for any Content provided by our Users which may appear as offensive or otherwise inappropriate. Icy Network reserves the right to remove any inappropriate Content provided by our Users at will.</p>
<h3>Third-Party Content</h3>
<p>Icy Network websites may contain Logos or Images not owned by Icy Network. Any Third-Party Content not owned by Icy Network, but is provided on any Icy Network website, is the property of their respective owners.</p>
<h4>Credits</h4>
<p>Google Play and the Google Play logo are trademarks of Google Inc.</p>
<p>Apple and the Apple logo are trademarks of Apple Inc., registered in the U.S. and other countries. App Store is a service mark of Apple Inc., registered in the U.S. and other countries.</p>
<h2>Icy Network Software License</h2>
<a href="https://github.com/IcyNet/IcyNet.eu" target="_blank">Icy Network Primary Web Application - Authentication and News</a><br>
Copyright (C) 2017 Icy Network - Evert Prants &lt;evert@lunasqu.ee&gt;<br>
<br>
This program is free software: you can redistribute it and/or modify<br>
it under the terms of the GNU General Public License as published by<br>
the Free Software Foundation, either version 3 of the License, or<br>
(at your option) any later version.<br>
<br>
This program is distributed in the hope that it will be useful,<br>
but WITHOUT ANY WARRANTY; without even the implied warranty of<br>
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the<br>
GNU General Public License for more details.<br>
<br>
You should have received a copy of the GNU General Public License<br>
along with this program. If not, see &lt;<a href="http://www.gnu.org/licenses/" target="_blank">http://www.gnu.org/licenses/</a>&gt;.<br>
</div>

View File

@ -1,3 +1,5 @@
import fs from 'fs'
import path from 'path'
import express from 'express' import express from 'express'
import parseurl from 'parseurl' import parseurl from 'parseurl'
import config from '../../scripts/load-config' import config from '../../scripts/load-config'
@ -44,6 +46,10 @@ router.get('/login', wrap(async (req, res) => {
res.locals.twitter_auth = true res.locals.twitter_auth = true
} }
if (config.discord && config.discord.api) {
res.locals.discord_auth = true
}
if (config.facebook && config.facebook.client) { if (config.facebook && config.facebook.client) {
res.locals.facebook_auth = config.facebook.client res.locals.facebook_auth = config.facebook.client
} }
@ -66,6 +72,10 @@ router.get('/register', wrap(async (req, res) => {
res.locals.twitter_auth = true res.locals.twitter_auth = true
} }
if (config.discord && config.discord.api) {
res.locals.discord_auth = true
}
if (config.facebook && config.facebook.client) { if (config.facebook && config.facebook.client) {
res.locals.facebook_auth = config.facebook.client res.locals.facebook_auth = config.facebook.client
} }
@ -103,10 +113,10 @@ router.get('/login/verify', wrap(async (req, res) => {
================= =================
*/ */
function formError (req, res, error, path) { function formError (req, res, error, redirect) {
req.flash('formkeep', req.body || {}) req.flash('formkeep', req.body || {})
req.flash('message', {error: true, text: error}) req.flash('message', {error: true, text: error})
res.redirect(path || parseurl(req).path) res.redirect(redirect || parseurl(req).path)
} }
router.post('/user/two-factor', wrap(async (req, res) => { router.post('/user/two-factor', wrap(async (req, res) => {
@ -295,6 +305,24 @@ router.post('/register', wrap(async (req, res) => {
res.redirect('/login') res.redirect('/login')
})) }))
/*
=============
DOCUMENTS
=============
*/
const docsDir = path.join(__dirname, '../../documents')
router.get('/docs/:name', wrap(async (req, res) => {
let doc = path.join(docsDir, req.params.name + '.html')
if (!fs.existsSync(docsDir) || !fs.existsSync(doc)) {
return res.status(404).end()
}
doc = fs.readFileSync(doc, {encoding: 'utf8'})
res.render('document', {doc: doc})
}))
/* /*
========= =========
OTHER OTHER

View File

@ -8,6 +8,12 @@ body
height: 100vh; height: 100vh;
background-size: 50px 50px; background-size: 50px 50px;
a
color: green
text-decoration: none
&:hover
text-decoration: underline
.logo .logo
font-size: 8vw font-size: 8vw
font-family: "Open Sans" font-family: "Open Sans"
@ -89,14 +95,41 @@ section
footer footer
padding: 20px padding: 20px
background-color: #fff background: #e9f6fd
background: -moz-linear-gradient(top, #e9f6fd 0%, #d3eefb 100%)
background: -webkit-linear-gradient(top, #e9f6fd 0%,#d3eefb 100%)
background: linear-gradient(to bottom, #e9f6fd 0%,#d3eefb 100%)
border-top: 1px solid #ddd
text-align: center
.copyright .copyright
display: block display: inline-block
text-align: center text-align: center
font-size: 90%
vertical-align: top
margin-top: 50px
padding: 15px
margin-left: 5vw
.squeebot
width: 200px
.wrapper .wrapper
overflow: hidden overflow: hidden
height: 100vh height: 100vh
.document
overflow: hidden
min-height: 100vh;
padding: 50px;
background-color: #fff;
.tos
display: inline-block
width: 60%
font-size: 120%
code
white-space: pre
label label
display: block display: block
margin-top: 20px margin-top: 20px
@ -157,6 +190,39 @@ input[type="submit"]
background-color: #fff background-color: #fff
border: 1px solid #ddd border: 1px solid #ddd
border-radius: 5px border-radius: 5px
text-decoration: none
i
color: #03A9F4;
font-size: 22px;
span
color: #000;
display: inline-block;
vertical-align: top;
margin-top: 3px;
margin-left: 12px;
.discordLogin
background-color: #99AAB5;
width: 225px;
height: 40px;
padding: 5px 5px;
display: inline-block;
border-radius: 5px;
text-decoration: none
span
color: white
vertical-align: top
margin-top: 11px
margin-left: 3px
display: inline-block
img
width: 45px
display: inline-block
span.divider
color: #ddd
margin: 0 5px
cursor: default
@media all and (max-width: 800px) @media all and (max-width: 800px)
.navigator .navigator
@ -171,6 +237,14 @@ input[type="submit"]
display: inline-block !important display: inline-block !important
.logo .logo
font-size: 10vw font-size: 10vw
footer
.squeebot
margin: 0
width: 150px
margin: auto
display: block
.copyright
margin-left: 0
@media all and (max-width: 500px) @media all and (max-width: 500px)
.logo.small .logo.small

View File

@ -0,0 +1 @@
<svg id="Layer_1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 245 240"><style>.st0{fill:#FFFFFF;}</style><path class="st0" d="M104.4 103.9c-5.7 0-10.2 5-10.2 11.1s4.6 11.1 10.2 11.1c5.7 0 10.2-5 10.2-11.1.1-6.1-4.5-11.1-10.2-11.1zM140.9 103.9c-5.7 0-10.2 5-10.2 11.1s4.6 11.1 10.2 11.1c5.7 0 10.2-5 10.2-11.1s-4.5-11.1-10.2-11.1z"/><path class="st0" d="M189.5 20h-134C44.2 20 35 29.2 35 40.6v135.2c0 11.4 9.2 20.6 20.5 20.6h113.4l-5.3-18.5 12.8 11.9 12.1 11.2 21.5 19V40.6c0-11.4-9.2-20.6-20.5-20.6zm-38.6 130.6s-3.6-4.3-6.6-8.1c13.1-3.7 18.1-11.9 18.1-11.9-4.1 2.7-8 4.6-11.5 5.9-5 2.1-9.8 3.5-14.5 4.3-9.6 1.8-18.4 1.3-25.9-.1-5.7-1.1-10.6-2.7-14.7-4.3-2.3-.9-4.8-2-7.3-3.4-.3-.2-.6-.3-.9-.5-.2-.1-.3-.2-.4-.3-1.8-1-2.8-1.7-2.8-1.7s4.8 8 17.5 11.8c-3 3.8-6.7 8.3-6.7 8.3-22.1-.7-30.5-15.2-30.5-15.2 0-32.2 14.4-58.3 14.4-58.3 14.4-10.8 28.1-10.5 28.1-10.5l1 1.2c-18 5.2-26.3 13.1-26.3 13.1s2.2-1.2 5.9-2.9c10.7-4.7 19.2-6 22.7-6.3.6-.1 1.1-.2 1.7-.2 6.1-.8 13-1 20.2-.2 9.5 1.1 19.7 3.9 30.1 9.6 0 0-7.9-7.5-24.9-12.7l1.4-1.6s13.7-.3 28.1 10.5c0 0 14.4 26.1 14.4 58.3 0 0-8.5 14.5-30.6 15.2z"/></svg>

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.6 KiB

5
views/document.pug Normal file
View File

@ -0,0 +1,5 @@
extends layout.pug
block body
.document
.content !{doc}

View File

@ -22,4 +22,9 @@
fb:login-button(scope="public_profile,email", onlogin="checkLoginState();" data-max-rows="1", data-size="large", data-button-type="login_with", data-show-faces="false", data-auto-logout-link="false", data-use-continue-as="false") fb:login-button(scope="public_profile,email", onlogin="checkLoginState();" data-max-rows="1", data-size="large", data-button-type="login_with", data-show-faces="false", data-auto-logout-link="false", data-use-continue-as="false")
if twitter_auth if twitter_auth
a.twitterLogin(href="/api/external/twitter/login") a.twitterLogin(href="/api/external/twitter/login")
img(src="/static/image/sign-in-with-twitter-link.png") i.fa.fa-fw.fa-twitter
span Log in With Twitter
if discord_auth
a.discordLogin(href="/api/external/discord/login")
img(src="/static/image/Discord-Logo-White.svg")
span Log in With Discord

View File

@ -44,6 +44,15 @@ html
block body block body
block footer block footer
footer footer
span.copyright &copy; 2017 - Icy Network - Some Rights Reserved img.squeebot(src="/static/image/squeebot.svg")
span.copyright Designed by span.copyright
a(href="https://lunasqu.ee") LunaSquee .logo.small
.part1 Icy
.part2 Network
br
span &copy; 2017 - Icy Network - Some Rights Reserved
br
span
a(href="/docs/terms-of-service") Terms of Service
span.divider |
a(href="/docs/privacy-policy") Privacy Policy

View File

@ -31,3 +31,4 @@ block body
a#create(href="/login") Log in with an existing account a#create(href="/login") Log in with an existing account
.right .right
h3 More options h3 More options
include includes/external.pug