1
0
mirror of https://codeberg.org/nobody/LocalCDN.git synced 2025-02-23 07:07:47 +01:00

Updated welcome page

This commit is contained in:
nobody 2020-06-03 16:31:25 +02:00
parent 6a3726f397
commit f72b913ec6
No known key found for this signature in database
GPG Key ID: 8F6DE3D614FCFD7A
4 changed files with 130 additions and 33 deletions

View File

@ -26,6 +26,7 @@
<li>Optimised version selection</li> <li>Optimised version selection</li>
<li>Updated i18n (German)</li> <li>Updated i18n (German)</li>
<li>Improved font color for dark mode</li> <li>Improved font color for dark mode</li>
<li>Updated welcome page</li>
</ul> </ul>
<div class="topic-label"> <div class="topic-label">
Please update your uBlock/uMatrix rules Please update your uBlock/uMatrix rules

View File

@ -43,9 +43,10 @@ hr {
.btn-panel { .btn-panel {
cursor: default; cursor: default;
font-family: 'Noto Sans', Arial, sans-serif; font-family: 'Noto Sans', Arial, sans-serif;
margin: 35px auto; margin: auto;
max-width: 750px; max-width: 750px;
display: flex; display: flex;
justify-content: center;
} }
.topic-badge { .topic-badge {
@ -101,44 +102,80 @@ hr {
*/ */
.btn { .btn {
color: #fff; color: #fff !important;
font-weight: 600; font-weight: 600;
margin-right: 15px; margin: 15px;
padding: 11px 17px; padding: 11px 17px;
text-decoration: none; text-decoration: none;
text-align: center; text-align: center;
width: 100px;
border-radius: 4px;
border-style: solid;
border-width: 1px;
}
.btn-text {
display: inline-flex;
align-items: center;
min-height: 40px;
justify-content: center;
} }
.btn-gitlab { .btn-gitlab {
background-color: #24292e; background-color: #007bbd;
border-color: #00679e !important;
} }
.btn-gitlab:hover { .btn-gitlab:hover {
background-color: #42474c;
}
.btn-website {
background-color: #007bbd;
}
.btn-website:hover {
background-color: #00679e; background-color: #00679e;
} }
.btn-donate { .btn-testing-utility {
background-color: #f7931a; background-color: #058300;
border-color: #034800 !important;
} }
.btn-donate:hover { .btn-testing-utility:hover {
background-color: #034800;
}
.btn-contact {
background-color: #f49b2f;
border-color: #f58700 !important;
}
.btn-contact:hover {
background-color: #f58700; background-color: #f58700;
} }
.btn-author { .btn-donate {
background-color: #00bd7f; background-color: #007bbd;
border-color: #00679e !important;
} }
.btn-author:hover { .btn-donate:hover {
background-color: #009e69; background-color: #00679e;
}
.btn-grid {
background: #fff;
-webkit-box-sizing: border-box;
box-sizing: border-box;
display: grid;
grid-gap: 16px;
grid-template-columns: repeat(2,1fr);
max-width: 752px;
padding: 16px;
}
.btn-decentraleyes {
background-color: #777;
border-color: #444 !important;
}
.btn-decentraleyes:hover {
background-color: #444;
} }
/** /**
@ -204,6 +241,14 @@ hr {
text-align: center; text-align: center;
} }
#p-donate {
text-decoration: underline;
}
#p-donate:hover {
cursor: pointer;
}
/** /**
* Media Queries * Media Queries
*/ */

View File

@ -10,11 +10,13 @@
<link rel="icon" href="../images/favicon.ico" type="image/x-icon"> <link rel="icon" href="../images/favicon.ico" type="image/x-icon">
</head> </head>
<body> <body>
<script src="welcome.js"></script>
<img src="../images/logo.svg" alt="Decentraleyes" class="logo"/> <img src="../images/logo.svg" alt="Decentraleyes" class="logo"/>
<div class="container"> <div class="container">
<h1>What's new in LocalCDN?</h1> <h1>What's new in LocalCDN?</h1>
<div class="notice"> <div class="notice">
<div class="subtle-hint"><div class="topic-label">Differences between LocalCDN and Decentraleyes</div>LocalCDN based on Decentraleyes. It includes more frameworks and more CDNs: <div class="subtle-hint">
<div class="topic-label">Differences between LocalCDN and Decentraleyes</div>LocalCDN based on Decentraleyes. It includes more frameworks and more CDNs:
<ul> <ul>
<li>jQuery up to 3.4.1</li> <li>jQuery up to 3.4.1</li>
<li>Bootstrap CSS (Delivered by StackPath, NetDNA and MaxCDN)</li> <li>Bootstrap CSS (Delivered by StackPath, NetDNA and MaxCDN)</li>
@ -22,7 +24,8 @@
<li>AngularJS, AngularJS-Animate, AngularJS-Sanitize, AngularJS-Cookies and AngularJS-Touch</li> <li>AngularJS, AngularJS-Animate, AngularJS-Sanitize, AngularJS-Cookies and AngularJS-Touch</li>
<li>Generator to create uBlock/uMatrix rules</li> <li>Generator to create uBlock/uMatrix rules</li>
</ul> </ul>
You can find a detailed overview on the add-on <a href="https://addons.mozilla.org/en-US/firefox/addon/localcdn-fork-of-decentraleyes/versions/">version history</a> and on <a href="https://gitlab.com/nobody42/localcdn/-/releases">GitLab</a>. <p>You can find a detailed overview on the add-on <a href="https://addons.mozilla.org/en-US/firefox/addon/localcdn-fork-of-decentraleyes/versions/">version history</a> and on <a href="https://codeberg.org/nobody/LocalCDN/releases">Codeberg</a>.</p>
<p id="p-donate">If you like LocalCDN, I would be happy about a small donation.</p>
</div> </div>
</div> </div>
<div class="notice"> <div class="notice">
@ -48,11 +51,9 @@
</div> </div>
<h1>Learn more, or contribute</h1> <h1>Learn more, or contribute</h1>
<div class="btn-panel"> <div class="btn-panel">
<a class="btn btn-website" href="https://decentraleyes.org" target="_blank"><i class="btn-icon fai fa-globe" data-fa-transform="grow-2"></i><span class="btn-text">Website of Decentraleyes</span></a> <a class="btn btn-gitlab" href="https://codeberg.org/nobody/LocalCDN" target="_blank"><span class="btn-text">LocalCDN @Codeberg</span></a>
<a class="btn btn-gitlab" href="https://gitlab.com/nobody42/localcdn" target="_blank"><i class="btn-icon fai fa-gitlab" data-fa-transform="grow-2"></i><span class="btn-text">LocalCDN @GitLab</span></a> <a class="btn btn-contact" href="https://localcdn.de/contact"><span class="btn-text">Contact</span></a>
<a class="btn btn-gitlab" href="https://git.synz.io/Synzvato/decentraleyes" target="_blank"><i class="btn-icon fai fa-gitlab" data-fa-transform="grow-2"></i><span class="btn-text">Decentraleyes @GitLab</span></a> <a class="btn btn-testing-utility" href="https://localcdn.de/test/"><span class="btn-text">Testing Utility</span></a>
<a class="btn btn-donate" href="https://decentraleyes.org/donate" target="_blank"><i class="btn-icon fai fa-donate" data-fa-transform="grow-2"></i><span class="btn-text">Donate to Decentraleyes</span></a>
<a class="btn btn-author" href="https://synz.io" target="_blank"><i class="btn-icon fai fa-user-circle" data-fa-transform="grow-3"></i><span class="btn-text">Author of Decentraleyes</span></a>
</div> </div>
</div> </div>
</body> </body>

50
pages/welcome/welcome.js Normal file
View File

@ -0,0 +1,50 @@
/**
* Welcome Page
* Belongs to LocalCDN.
*
* @author nobody42
* @since 2020-02-27
* @license MPL 2.0
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/.
*/
'use strict';
/**
* Welcome
*/
var welcome = {};
/**
* Event Handlers
*/
welcome._onDonationElementClicked = function () {
if (event.button === 0 || event.button === 1) {
chrome.tabs.create({
'url': chrome.extension.getURL('pages/donate/donate.html'),
'active': (event.button === 0)
});
}
if (event.button === 0) {
window.close();
}
};
welcome._onDocumentLoaded = function () {
let donationElement = document.getElementById('p-donate');
donationElement.addEventListener('mouseup', welcome._onDonationElementClicked);
};
document.addEventListener('DOMContentLoaded', welcome._onDocumentLoaded);