Update sleeky

This commit is contained in:
2022-04-23 14:51:04 +03:00
parent 33101f5fc2
commit 33e14d4c8f
30 changed files with 13176 additions and 63 deletions

View File

@@ -0,0 +1,948 @@
@import url('https://fonts.googleapis.com/css?family=Open+Sans:300,400,600,700,800');
@import url('https://fonts.googleapis.com/icon?family=Material+Icons');
// Mobile mixin
@mixin for-size($range) {
$phone-upper-boundary: 900px;
$tablet-portrait-upper-boundary: 1100px;
$tablet-landscape-upper-boundary: 1200px;
$desktop-upper-boundary: 1800px;
@if $range == phone-only {
@media (max-width: #{$phone-upper-boundary - 1}) { @content; }
} @else if $range == tablet-portrait-up {
@media (min-width: $phone-upper-boundary) { @content; }
} @else if $range == tablet-landscape-up {
@media (min-width: $tablet-portrait-upper-boundary) { @content; }
} @else if $range == desktop-up {
@media (min-width: $tablet-landscape-upper-boundary) { @content; }
} @else if $range == big-desktop-up {
@media (min-width: $desktop-upper-boundary) { @content; }
}
}
// Use it like this:
// @include for-size(phone-only) {
// margin: 30px;
// }
//
// Globals
//
body {
background-color: $darker;
display: inline;
}
div, p, td, input, p {
font-family: 'Open Sans', sans-serif !important;
}
h1,
h2 {
color: $title;
}
p {
color: $text;
}
a, a:link, a:active, a:visited {
color: #828282;
text-decoration: none;
}
a:hover {
color: darken($title, 20%);
transition: 0.4s all;
}
input {
padding: 10px;
border: none !important;
background: $light !important;
color: $text !important;
font-size: 1em !important;
outline: none;
margin: 0px 5px !important;
border-radius: 0 !important;
@if ($theme == "light") {
border-radius: 3px !important;
}
}
input.button,
input.submit,
input[type="submit"] {
border-left: 7px solid $accent !important;
background: $light !important;
font-weight: 600;
transition: 0.3s all !important;
cursor: pointer;
@if ($theme == "light") {
background: $accent !important;
border-left: none !important;
color: white !important;
font-weight: 700;
}
}
// Need to fix this, because I've had to copy this down lower to make it apply to the add URL button
input.button:hover,
input.submit:hover,
input[type="submit"]:hover {
background: darken($accent, 15%) !important;
@if ($theme == "light") {
background: darken($accent, 15%) !important;
}
}
input[type="button"]:disabled,
input[type="submit"]:disabled {
cursor: not-allowed;
}
input.text,
input[type="text"] {
border: 1px solid rgba(255, 255, 255, 0.25) !important;
transition: 0.4s all;
}
@if ($theme != "light") {
input.text:active,
input.text:focus {
border: 1px solid $accent !important;
}
}
select {
width: 150px;
padding: 5px 35px 5px 10px;
// font-size: 0.9em;
border: none;
border-radius: 0;
height: 26px;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
color: $text;
background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAAeCAYAAADZ7LXbAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNYAMqUIeEeCDx8TG4eQuQIEKJHAAEAizZCFz/SMBAPh+PDwrIsAHvgABeNMLCADATZvAMByH/w/qQplcAYCEAcB0kThLCIAUAEB6jkKmAEBGAYCdmCZTAKAEAGDLY2LjAFAtAGAnf+bTAICd+Jl7AQBblCEVAaCRACATZYhEAGg7AKzPVopFAFgwABRmS8Q5ANgtADBJV2ZIALC3AMDOEAuyAAgMADBRiIUpAAR7AGDIIyN4AISZABRG8lc88SuuEOcqAAB4mbI8uSQ5RYFbCC1xB1dXLh4ozkkXKxQ2YQJhmkAuwnmZGTKBNA/g88wAAKCRFRHgg/P9eM4Ors7ONo62Dl8t6r8G/yJiYuP+5c+rcEAAAOF0ftH+LC+zGoA7BoBt/qIl7gRoXgugdfeLZrIPQLUAoOnaV/Nw+H48PEWhkLnZ2eXk5NhKxEJbYcpXff5nwl/AV/1s+X48/Pf14L7iJIEyXYFHBPjgwsz0TKUcz5IJhGLc5o9H/LcL//wd0yLESWK5WCoU41EScY5EmozzMqUiiUKSKcUl0v9k4t8s+wM+3zUAsGo+AXuRLahdYwP2SycQ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q0Dd9WtO319kXbL5fNKNu7g7ZDuaO/PLi8ZafJzs07P1SkVPRU+lQ27tLdtWHX+G7R7ht7vPY07NXbW7z3/T7JvttVAVVN1WbVZftJ+7P3P66Jqun4lvttXa1ObXHtxwPSA/0HIw6217nU1R3SPVRSj9Yr60cOxx++/p3vdy0NNg1VjZzG4iNwRHnk6fcJ3/ceDTradox7rOEH0x92HWcdL2pCmvKaRptTmvtbYlu6T8w+0dbq3nr8R9sfD5w0PFl5SvNUyWna6YLTk2fyz4ydlZ19fi753GDborZ752PO32oPb++6EHTh0kX/i+c7vDvOXPK4dPKy2+UTV7hXmq86X23qdOo8/pPTT8e7nLuarrlca7nuer21e2b36RueN87d9L158Rb/1tWeOT3dvfN6b/fF9/XfFt1+cif9zsu72Xcn7q28T7xf9EDtQdlD3YfVP1v+3Njv3H9qwHeg89HcR/cGhYPP/pH1jw9DBY+Zj8uGDYbrnjg+OTniP3L96fynQ89kzyaeF/6i/suuFxYvfvjV69fO0ZjRoZfyl5O/bXyl/erA6xmv28bCxh6+yXgzMV70VvvtwXfcdx3vo98PT+R8IH8o/2j5sfVT0Kf7kxmTk/8EA5jz/GMzLdsAAAAgY0hSTQAAeiUAAICDAAD5/wAAgOkAAHUwAADqYAAAOpgAABdvkl/FRgAAAKRJREFUeNrs1TEKwkAQheEvIoI2nsk7qFdIq1hoJ3gCC5sUVpY23sDKXnvrYOUBbGITG0kQjQriPlgYhmF/3ryFjbIs82nVfEEBEiAB8k+Q+q1IkqSDNVq4lMy3scIkjuP0FSdbjNHMLys6OwyQVlnXEsOS2QP6OL8jkzlmd70jus86eBT8FIu8PqGXg6oFX6ARGthgX+V1ReFnDJAACZAfhFwHAJI7HF2lZGQaAAAAAElFTkSuQmCC) 96% / 15% no-repeat $light;
margin: 5px 10px;
transition: 0.4s all;
outline: none;
}
select:hover {
background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAAeCAYAAADZ7LXbAAAACXBIWXMAAAsTAAALEwEAmpw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XPK4dPKy2+UTV7hXmq86X23qdOo8/pPTT8e7nLuarrlca7nuer21e2b36RueN87d9L158Rb/1tWeOT3dvfN6b/fF9/XfFt1+cif9zsu72Xcn7q28T7xf9EDtQdlD3YfVP1v+3Njv3H9qwHeg89HcR/cGhYPP/pH1jw9DBY+Zj8uGDYbrnjg+OTniP3L96fynQ89kzyaeF/6i/suuFxYvfvjV69fO0ZjRoZfyl5O/bXyl/erA6xmv28bCxh6+yXgzMV70VvvtwXfcdx3vo98PT+R8IH8o/2j5sfVT0Kf7kxmTk/8EA5jz/GMzLdsAAAAgY0hSTQAAeiUAAICDAAD5/wAAgOkAAHUwAADqYAAAOpgAABdvkl/FRgAAAKRJREFUeNrs1TEKwkAQheEvIoI2nsk7qFdIq1hoJ3gCC5sUVpY23sDKXnvrYOUBbGITG0kQjQriPlgYhmF/3ryFjbIs82nVfEEBEiAB8k+Q+q1IkqSDNVq4lMy3scIkjuP0FSdbjNHMLys6OwyQVlnXEsOS2QP6OL8jkzlmd70jus86eBT8FIu8PqGXg6oFX6ARGthgX+V1ReFnDJAACZAfhFwHAJI7HF2lZGQaAAAAAElFTkSuQmCC) 96% / 15% no-repeat $light;
}
#javascript_error {
background: red;
color: white;
padding: 20px;
margin-top: 10px;
}
// End Globals
//
// Notification Bar
//
.jquery-notify-bar {
color: #fff;
text-shadow: none;
border: none;
opacity: 1;
box-shadow: none;
font-size: 1.1em;
font-weight: 500;
position: static;
margin-top: 30px;
margin-bottom: -45px;
padding: 10px;
a, a:link, a:active, a:visited {
color: white;
}
}
.jquery-notify-bar.error,
.jquery-notify-bar.fail {
background-color: #FF9800;
color: white;
}
.jquery-notify-bar.success {
color: white;
background-color: #4CAF50;
}
// End Notification Bar
//
// Login page
//
.login {
#wrap {
margin: auto;
}
label {
font-size: 1em;
font-weight: 600;
}
.login-logo {
width: 150px;
margin: 30px auto;
display: flex;
}
input.text {
width: 270px !important;
}
input.button {
font-weight: 600;
padding: 10px 25px;
margin-top: 15px !important;
font-weight: 600;
@if ($theme == "light") {
background: $accent !important;
} else {
background: $light !important;
border-left: 7px solid $accent !important;
}
}
input.button:hover {
background: darken($accent, 10%) !important;
}
.error {
padding: 10px;
background: $accent;
color: white;
position: fixed;
top: 0;
left: 0;
width: 100%;
margin: 0;
text-align: center
}
}
// End login page
//
// Start Index page
//
.index {
#add-url {
width: 200px;
}
#new_url_form {
box-sizing: border-box;
overflow: hidden;
// min-width: 900px;
}
#new_url {
border: none;
background: $default;
text-align: left;
input.button {
margin-top: 10px !important;
}
div {
background: $default;
padding: 4px;
padding-top: 0px;
}
}
.create {
background: $accent !important;
width: 150px;
font-size: 1.3em !important;
border: none !important;
font-weight: 700;
text-align: center;
margin-top: 10px !important;
margin-left: 20px !important;
}
.top {
position: absolute;
top: 0;
left: 0;
width: 100vw;
height: 50px;
@if ($theme == "light") {
background: darken($accent, 10%);
} @else {
background: $default;
}
label {
font-size: 1em;
font-weight: 600;
color: $text;
@if ($theme == "light") {
color: $default;
}
}
input.text {
width: 360px;
padding: 4px;
font-weight: 200;
font-size: 1em !important;
@if ($theme == "light") {
background: $default !important;
} @else {
background: $lightest !important;
}
}
.short {
padding-left: 10px;
}
#add-keyword {
width: 100px;
}
input.button {
font-weight: 500;
padding: 5px 10px;
font-size: 1em !important;
margin-left: 10px !important;
background: $lightest !important;
@if ($theme == "light") {
background: $default !important;
font-weight: 700;
color: $accent !important;
}
}
input.button:hover {
background: darken($accent, 10%) !important;
@if ($theme == "light") {
background: darken(white, 10%) !important;
}
}
#new_url_form {
margin-left: 260px;
padding: 12px;
}
}
// Table stuff
table.tblSorter {
background-color: $default;
color: $text;
a {
color: $text;
}
small a {
color: darken(white, 50%)
}
thead tr .tablesorter-header {
padding: 10px;
}
tfoot tr {
background-color: $default;
}
thead tr th,
tfoot tr th,
th.header {
background-color: transparent;
border: none;
/* font-size: 8pt; */
padding: 4px;
}
thead tr .tablesorter-headerAsc,
thead tr .tablesorter-headerDesc {
background-color: $lightest !important;
}
tbody td {
color: $text;
padding: 5px;
background-color: $light;
vertical-align: middle;
transition: 0.4s all;
}
tbody tr:hover td {
background-color: $lightest !important;
}
tbody tr.normal-row td {
background: $light;
}
.keyword {
border-left: 7px solid $accent;
}
input.text {
padding: 5px;
margin: 8px 5px !important;
}
.navigation .nav_link a {
background: $light;
border: none;
&:hover {
background: $lightest;
}
}
tr.edit-row td {
background: $default !important;
}
// Icons
$icons-list: stats, share, edit, delete;
@each $icon in $icons-list {
@if $icon == delete {
td.actions .button_#{$icon} {
background: red url(../img/#{$icon}.png) 0px center no-repeat;
background-size: 23px;
background-position: center;
border: none;
padding: 3px;
border-radius: 2px;
&:hover {
background: darken(red, 10%) url(../img/#{$icon}.png) 0px center no-repeat;
background-size: 23px;
background-position: center;
}
}
} @else {
td.actions .button_#{$icon} {
background: $accent url(../img/#{$icon}.png) 0px center no-repeat;
background-size: 23px;
background-position: center;
border: none;
padding: 3px;
border-radius: 2px;
&:hover {
background: darken($accent, 10%) url(../img/#{$icon}.png) 0px center no-repeat;
background-size: 23px;
background-position: center;
}
}
}
}
}
}
// End index page
//
// Nav
//
nav {
background: $default;
height: 100%;
position: fixed;
top: 0;
left: 0;
padding: 50px 30px;
width: 200px;
z-index: 10;
li#admin_menu_logout_link {
font-size: 1.3em;
}
ul#admin_menu li:hover {
list-style-type: none;
color: darken($title, 20%);
}
ul#admin_menu li {
color: $title;
padding: 5px 0;
}
#admin_menu_logout_link:hover {
color: $title !important;
}
.admin_menu_sublevel {
font-weight: 100;
margin-left: -20px;
}
.material-icons {
font-size: 1em;
vertical-align: middle;
margin-top: -1px;
}
ul {
list-style-type: none;
}
}
img.logo {
width: 90px;
position: fixed;
top: 0;
left: 0;
background: $accent;
padding: 9px 150px 8px 20px;
z-index: 20;
}
.nav-open {
color: white;
position: fixed;
top: 0;
right: 0;
z-index: 30;
padding: 10px 15px;
cursor: pointer;
display: none;
i {
font-size: 2em;
line-height: 30px;
}
}
header {
display: none;
}
// End nav
//
// Information
//
#wrap {
#tabs {
min-width: 580px;
.tab {
background: $light !important;
}
.wrap_unfloat {
margin-bottom: -5px;
}
ul#headers {
border: none;
padding: 0px;
}
li {
color: $text;
}
#historical_clicks li:hover {
background: darken($default, 10%) !important;
}
ul#headers li a,
#stats_lines li a {
outline: none;
border: none;
border-radius: 0;
background: $light;
color: $text;
padding: 10px 15px 7px 25px;
&:hover {
background: darken($default, 10%);
}
h2 {
font-weight: 400;
font-size: 1em;
}
&.selected {
background: $lightest;
border-bottom: 2px solid $accent;
&:hover {
background: darken($default, 15%);
}
}
}
#stats_lines li a {
padding: 7px 15px;
}
ul.toggle_display {
border: none;
}
svg {
ellipse {
fill: $accent;
}
}
}
}
//
// General Styles
//
body.index #wrap {
padding-top: 50px;
}
#wrap {
background: none;
margin-left: 270px;
border: none;
color: $text;
max-width: 100%;
}
.notice {
width: calc(100% - 22px);
margin: 0;
padding: 0;
border-radius: 0;
background: $accent;
border: 1px solid $accent;
padding: 10px;
p {
color: white;
}
}
#shareboxes {
margin-top: -10px;
}
#sharebox {
width: 558px;
margin-right: 0px;
}
div.share {
background: $default;
border-radius: 0;
border: none;
padding: 0px 20px 10px;
margin-top: 10px;
textarea {
background: $light;
color: $text;
border: none;
padding: 3px;
outline: none;
margin: 1px !important;
}
#charcount {
padding-left: 5px;
color: $text;
}
#share_links a {
color: $text;
}
}
.sub_wrap,
.plugins main,
.plugin_page_sleeky_settings main,
code {
background: $default;
padding: 10px;
padding: 5px 25px;
max-width: 100%;
span {
background: rgba(255, 255, 255, 0.2);
}
code,
tt {
background: rgba(0, 123, 255, 0.7);
@if ($theme == "light") {
background: rgba(35, 185, 222, 0.5);
}
}
a.bookmarklet {
border: none;
background: #ffffff url(/images/favicon.gif) 4px center no-repeat;
color: #3c3c3c;
border-radius: 1px;
padding: 7px 7px 7px 25px;
color: darken(white, 80%) !important;
&:hover {
background: #e0e0e0 url(/images/favicon.gif) 4px center no-repeat;
}
}
// Table
table.tblSorter {
background: $default;
a {
color: $text;
&:hover {
color: darken($text, 30%);
}
}
thead tr th,
tfoot tr th,
th.header {
border: none;
background-color: $light;
padding: 10px;
}
tbody td {
background: $lightest;
color: $text;
}
}
}
#filter_options {
padding: 0px 10px !important;
}
body > div > pre {
overflow-x: scroll;
padding-left: 290px;
}
// End General Styles
//
// Footer
//
#footer {
position: fixed;
bottom: 0;
width: 230px;
color: #828282;
padding: 10px;
text-align: left;
z-index: 10;
p {
background: none;
border: none;
font-size: 1em;
a {
background: none;
padding-left: 0;
color: $text;
&:hover {
color: #828282;
}
}
}
}
// End footer
// Mobile styles
@include for-size(phone-only) {
body.index #wrap {
padding-top: 210px;
}
body.tools #wrap,
body.plugins #wrap,
body.plugin_page_sleeky_settings #wrap {
padding-top: 50px;
}
#wrap {
margin-left: 0;
main {
overflow-x: scroll;
}
}
img.logo {
padding: 9px 100% 8px 20px;
}
.nav-open {
display: block;
}
nav {
height: 0;
padding: 0;
width: 0;
ul#admin_menu {
position: fixed;
top: 0;
left: 0;
z-index: 9999 !important;
width: 100%;
height: 100%;
padding: 50px;
display: none;
@if ($theme == "light") {
background: darken($accent, 10%);
} @else {
background: $default;
}
li {
color: white;
}
a, a:link, a:active, a:visited {
color: white;
}
}
}
.index {
.top {
display: block;
margin-top: 50px;
width: 100vw;
height: auto;
form {
margin-left: 0 !important;
}
#new_url_form {
min-width: unset;
height: auto;
}
.short {
padding: 0;
}
#add-url,
#add-keyword {
width: calc(100% - 10px);
margin: 10px 0px !important;
}
input.button {
margin: 0 !important;
width: 100%;
}
}
table.tblSorter {
min-width: 600px;
// Icons
$icons-list: stats, share, edit, delete;
@each $icon in $icons-list {
td.actions .button_#{$icon} {
background-size: 15px;
margin: 3px;
}
}
}
}
#copybox {
width: 100%;
}
.jquery-notify-bar {
margin-top: 210px;
margin-bottom: -210px;
width: calc(100vw - 20px);
a {
margin-left: -30px;
}
}
#footer {
display: none;
}
.infos #wrap {
margin-top: 30px;
#headers {
li {
margin: 0;
display: inline-block;
}
}
}
.infos #tabs {
min-width: initial;
.tab {
overflow: scroll;
}
ul#headers {
margin: 20px 0;
li {
a {
padding: 10px 5px;
}
h2 {
margin: 0;
}
}
}
}
body > div > pre {
padding-left: 20px;
}
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,22 @@
// Sleeky Admin Dark UI Theme
// Define theme
$theme: "dark";
// Set up our basic colour scheme
$lightest: #464646;
$light: #313131;
$default: #232323;
$darker: #1d1d1d;
$darkest: #161616;
// Accents
$accent: #007bff;
// $accent_primary: #007bff;
// Text colours
$title: #ececec;
$text: #dcdcdc;
// Import the base styles
@import "../base.scss";

View File

@@ -0,0 +1,22 @@
// Sleeky Admin Light UI Theme
// Define theme
$theme: "light";
// Set up our basic colour scheme
$lightest: #e8e8e8;
$light: white;
$default: #f7f7f7;
$darker: #efefef;
$darkest: #161616;
// Accents
$accent: #007bff;
// $accent_secondary: black;
// Text colours
$title: #1d1d1d;
$text: #313131;
// Import the base styles
@import "../base.scss";

View File

@@ -0,0 +1,10 @@
<div class="top" id="add">
<form id="new_url_form" action="javascript:add_link();" method="get">
<label>Link</label>
<input type="url" id="add-url" name="url" value="" class="text" placeholder="e.g. sleeky.flynntes.com" required>
<label class="short">Short URL</label>
<input type="text" id="add-keyword" name="keyword" value="" class="text" placeholder="e.g. theme">
<input type="hidden" id="nonce-add" name="nonce-add" value="">
<input type="button" id="add-button" name="add-button" value="Shorten" class="button" onclick="add_link();">
</form>
</div>

Binary file not shown.

After

Width:  |  Height:  |  Size: 228 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 239 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 496 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 243 B

View File

@@ -0,0 +1,144 @@
// Sleeky Admin Theme
// 2019 Flynn Tesoriero
console.log("Sleeky Admin Theme Running");
$( document ).ready(function() {
// Get the theme URL
var url;
if ($('meta[name=pluginURL]').attr("content")) {
url = $('meta[name=pluginURL]').attr("content");
} else {
// If for some reason we can't find the URL attribute
url = "/user/plugins/sleeky_backend";
}
// Detect theme
var theme;
if ($('meta[name=sleeky_theme]').attr("content") == 'light') {
theme = "light";
} else if ($('meta[name=sleeky_theme]').attr("content") == 'dark') {
theme = "dark";
}
console.log("Theme is", theme)
// Update favicon
$('link[rel="shortcut icon"]').attr('href', url + "/assets/img/favicon.ico");
// Update meta viewport
$('head').append('<meta name="viewport" content="width=device-width, initial-scale=1.0">');
// Detect pages
if ($("body").hasClass("login")) {
// Login page
console.log("Login page");
if (theme == "light") {
$("#login").prepend(`<img class="login-logo" src="${url}/assets/img/logo_black.png">`);
} else if (theme == "dark") {
$("#login").prepend(`<img class="login-logo" src="${url}/assets/img/logo_white.png">`);
}
} else if ($("body").hasClass("index")) {
// Index page
console.log("Index page");
handleNav()
// Hide YOURLS new URL section
$("#new_url").hide();
// Grab the nonce id
var nonce = $("#nonce-add").val();
// Remove the YOURLS new URL Section
$("#new_url").remove();
// Create the sleeky new URL section from the template
$("nav").append($('<div>').load(`${url}/assets/html/form.html`, function () {
$("#nonce-add").val(nonce);
}));
} else if ($("body").hasClass("tools")) {
// Tools page
console.log("Tools page");
handleNav()
} else if ($("body").hasClass("plugins")) {
// Plugins page
console.log("Plugins page");
handleNav()
} else if ($("body").hasClass("plugin_page_sleeky_settings")) {
// Tools page
console.log("Sleeky Settings Page");
handleNav()
$("#ui_selector").val($("#ui_selector").attr("value"));
} else if ($("body").hasClass("infos")) {
// Information page
console.log("Information page");
handleNav()
$("#historical_clicks li").each(function (index) {
if (index % 2 != 0) {
$("#historical_clicks li").eq(index).css("background", "");
}
})
// Update tab headers
var titles = ['Statistics', 'Location', 'Sources']
for (let i = 0; i < 3; i++) {
$($('#headers > li')[i]).find('h2').text(titles[i]);
}
} else {
console.warn("Unknown page");
handleNav();
}
function handleNav() {
// Add logo
$("#wrap").prepend(`<img class="logo" src="${url}/assets/img/logo_white.png">`);
// Add mobile nav hamburger
$("#wrap").prepend(`<div class="nav-open" id="navOpen"><i class="material-icons">menu</i></div>`);
// Add frontend link
$('#admin_menu').append('<li class="admin_menu_toplevel frontend_link"><a href="/"><i class="material-icons">arrow_back</i> Frontend Interface</a></li>');
// admin_menu
$('#navOpen').on('click', function() {
$('#admin_menu').slideToggle();
})
$(window).resize(function () {
if ($(window).width() > 899) {
$('#admin_menu').show();
} else {
$('#admin_menu').hide();
}
});
}
// Update P elements
$("p").each(function (index) {
if (/Display/.test($(this).text()) || /Overall/.test($(this).text())) {
// Move info on index page to the bottom
$("main").append("<p>" + $(this).html() + "</p>");
$(this).remove();
} else if (/Powered by/.test($(this).text())) {
// Update footer
var content = $(this).html();
var i = 77
var updated_content = "Running on" + content.slice(13, i) + '& <a href="https://sleeky.flynntes.com/" title="Sleeky">Sleeky</a>' + content.slice(i-1)
$(this).html(updated_content);
}
});
});

0
plugins/sleeky-backend/plugin.php Normal file → Executable file
View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

View File

@@ -0,0 +1,35 @@
// Font Imports
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@700&family=Open+Sans&display=swap');
$open-sans: "Open Sans", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
$montserrat: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
// Bootstrap Overrides
$enable-negative-margins: true;
$font-family-sans-serif: $open-sans;
$input-btn-font-family: $montserrat;
$headings-font-family: $montserrat;
$input-bg: #ebebeb;
$input-font-weight: 700;
$btn-font-weight: 700;
$input-border-width: 0;
$border-radius: 6px;
// Bootstrap Imports
@import '../../node_modules/bootstrap/scss/bootstrap.scss';
// Custom Styles
.bold-link {
font-family: $montserrat;
font-weight: 700;
text-transform: uppercase;
}
@include media-breakpoint-down(md) {
.input-group-block {
input, button {
width: 100%;
border-radius: $border-radius !important;
}
}
}

View File

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="#757575"><path clip-rule="evenodd" fill="none" d="M0 0h24v24H0z"/><path d="M22.7 19l-9.1-9.1c.9-2.3.4-5-1.5-6.9-2-2-5-2.4-7.4-1.3L9 6 6 9 1.6 4.7C.4 7.1.9 10.1 2.9 12.1c1.9 1.9 4.6 2.4 6.9 1.5l9.1 9.1c.4.4 1 .4 1.4 0l2.3-2.3c.5-.4.5-1.1.1-1.4z"/></svg>

After

Width:  |  Height:  |  Size: 341 B

View File

@@ -0,0 +1,59 @@
<?php
// CONFIG - These control the look and details on your site. Consult documentation for more details.
// GENERAL
// Page title for your site
define('title', 'Sleeky theme for YOURLS');
// The short title of your site, used in the footer and in some sub pages
define('shortTitle', 'Sleeky');
// A description of your site, shown on the homepage.
define('description', 'A quick description on why your site is so fantastic, what it does and why people should definitely start using it. Oh, and how its free.');
// The favicon for your site
define('favicon', '/frontend/assets/img/favicon.ico');
// Logo for your site, displayed on home page
define('logo', '/frontend/assets/img/logo-black.png');
// Enable reCAPTCHA V3
// It is highly recommended you use reCAPTCHA V3. It will stop spam. You can get a site and secret key from here: https://www.google.com/recaptcha/admin/create
define("enableRecaptcha", false);
// reCAPTCHA V3 Site Key
define("recaptchaV3SiteKey", 'YOUR_SITE_KEY_HERE');
// reCAPTCHA V3 Secret Key
define("recaptchaV3SecretKey", 'YOUR_SECRET_KEY_HERE');
// Enables the custom URL field
// true or false
define('enableCustomURL', true);
// Optional
// Set a primary colour to be used. Default: #007bff
// Here are some other colours you could try:
// #f44336: red, #9c27b0: purple, #00bcd4: teal, #ff5722: orange
define('colour', '#007bff');
// Optional
// Set a background image to be used.
// default: unsplash.com random daily photo of the day
// More possibilities of photo embedding from unsplash could be found at: https://source.unsplash.com
// define('backgroundImage', 'https://source.unsplash.com/daily');
// FOOTER
// These are the links in the footer. Add a new link for each new link.
// The array follows a title link structure:
// "TITLE" => "LINK",
$footerLinks = [
"About" => "https://sleeky.flynntes.com/",
"Contact" => "https://yourls.org/",
"Legal" => "https://yourls.org/",
"Admin" => "/admin"
];
?>

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,86 @@
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.bundle.min.js" integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM" crossorigin="anonymous"></script>
<script>
// From https://stackoverflow.com/a/30810322
function fallbackCopyTextToClipboard(text) {
var textArea = document.createElement("textarea");
textArea.value = text;
// Avoid scrolling to bottom
textArea.style.top = "0";
textArea.style.left = "0";
textArea.style.position = "fixed";
document.body.appendChild(textArea);
textArea.focus();
textArea.select();
try {
var successful = document.execCommand('copy');
var msg = successful ? 'successful' : 'unsuccessful';
console.log('Fallback: Copying text command was ' + msg);
} catch (err) {
console.error('Fallback: Oops, unable to copy', err);
}
document.body.removeChild(textArea);
}
function copyTextToClipboard(text) {
if (!navigator.clipboard) {
fallbackCopyTextToClipboard(text);
return;
}
navigator.clipboard.writeText(text).then(function() {
console.log('Async: Copying to clipboard was successful!');
}, function(err) {
console.error('Async: Could not copy text: ', err);
});
}
const copyBtn = document.querySelector('button#copy-button');
if (copyBtn) {
copyBtn.addEventListener('click', function(event) {
copyTextToClipboard(event.target.dataset.shorturl);
});
}
const closeShortenedLinkScreenButton = document.querySelector('button#close-shortened-screen');
if (closeShortenedLinkScreenButton) {
closeShortenedLinkScreenButton.addEventListener('click', function(event) {
window.location.href=window.location.href;
});
}
</script>
<?php if (enableRecaptcha) : ?>
<script src="https://www.google.com/recaptcha/api.js?render=<?php echo recaptchaV3SiteKey ?>"></script>
<script>
const shortenForm = document.querySelector("form#shortenlink");
if (shortenForm) {
shortenForm.addEventListener("submit", function(e){
e.preventDefault();
grecaptcha.ready(function() {
grecaptcha.execute('<?php echo recaptchaV3SiteKey ?>', {action: 'shorten_link'}).then(function(token) {
const tokenInput = document.createElement("input");
tokenInput.setAttribute("type", "hidden");
tokenInput.setAttribute("name", "token");
tokenInput.setAttribute("value", token);
const actionInput = document.createElement("input");
actionInput.setAttribute("type", "hidden");
actionInput.setAttribute("name", "action");
actionInput.setAttribute("value", "shorten_link");
shortenForm.prepend(tokenInput);
shortenForm.prepend(actionInput);
shortenForm.submit();
});
});
});
}
</script>
<?php endif; ?>

View File

@@ -0,0 +1,26 @@
<?php
// Darken or lighten a hex code
// Full credit goes to: https://stackoverflow.com/a/11951022
function adjustBrightness($hex, $steps) {
// Steps should be between -255 and 255. Negative = darker, positive = lighter
$steps = max(-255, min(255, $steps));
// Normalize into a six character long hex string
$hex = str_replace('#', '', $hex);
if (strlen($hex) == 3) {
$hex = str_repeat(substr($hex,0,1), 2).str_repeat(substr($hex,1,1), 2).str_repeat(substr($hex,2,1), 2);
}
// Split into three parts: R, G and B
$color_parts = str_split($hex, 2);
$return = '#';
foreach ($color_parts as $color) {
$color = hexdec($color); // Convert to decimal
$color = max(0,min(255,$color + $steps)); // Adjust color
$return .= str_pad(dechex($color), 2, '0', STR_PAD_LEFT); // Make two char hex code
}
return $return;
}
?>

View File

@@ -0,0 +1,14 @@
var gulp = require('gulp');
var sass = require('gulp-sass')(require('sass'));
gulp.task('sass', () => {
return gulp.src("./assets/sass/*.scss")
.pipe(sass())
.pipe(gulp.dest("dist/"))
});
gulp.task('start', gulp.series('sass', function () {
gulp.watch("sass/*.scss", gulp.series('sass'));
}));
gulp.task('default', gulp.series('start'));

View File

@@ -0,0 +1,45 @@
<?php
include 'config.php';
include 'functions.php';
?>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-patible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="<?php echo description ?>">
<link rel="icon" href="<?php echo favicon ?>">
<title><?php echo title ?></title>
<link rel="stylesheet" href="<?php echo $YOURLS_SITE ?>/frontend/dist/styles.css">
<?php if (defined('backgroundImage')) : ?>
<style>
body {
background: url(<?php echo backgroundImage ?>) no-repeat center center fixed !important;
background-size: cover !important;
}
</style>
<?php else : ?>
<style>
body {
background-color: <?php echo colour ?>;
}
</style>
<?php endif; ?>
<style>
.btn-primary {
background-color: <?php echo colour ?>;
border-color: <?php echo colour ?>;
}
.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
background-color: <?php echo adjustBrightness(colour, -15) ?>;
border-color: <?php echo adjustBrightness(colour, -15) ?>;
}
</style>
</head>

View File

@@ -0,0 +1,21 @@
{
"name": "sleeky-frontend",
"version": "2.5.0",
"description": "",
"main": "index.js",
"scripts": {
"start": "gulp",
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC",
"devDependencies": {
"gulp": "^4.0.2",
"gulp-sass": "^5.0.0",
"sass": "^1.35.1"
},
"dependencies": {
"bootstrap": "^5.0.2",
"popper.js": "^1.16.1"
}
}

View File

@@ -72,77 +72,79 @@
}
?>
<?php if( isset($status) && $status == 'success' ): ?>
<div class="container-fluid h-100">
<div class="row justify-content-center align-items-center h-100">
<div class="col-12 col-lg-10 col-xl-8 col-xxl-5 mt-5">
<div class="card border-0 mt-5">
<?php if( isset($status) && $status == 'success' ): ?>
<?php $url = preg_replace("(^https?://)", "", $shorturl ); ?>
<?php $url = preg_replace("(^https?://)", "", $shorturl ); ?>
<div class="close-container text-end mt-3 me-3">
<button type="button" class="btn-close" id="close-shortened-screen" aria-label="Close"></button>
</div>
<section class="success-screen">
<div class="container verticle-center">
<div class="main-content">
<div class="close noselect">
<a href="javascript:window.location.href=window.location.href;"><i class="material-icons">close</i></a>
</div>
<section class="head">
<h2>YOUR SHORTENED LINK:</h2>
</section>
<section class="link-section">
<input type="text" class="short-url" disabled style="text-transform:none;" value="<?php echo $shorturl; ?>">
<button class="short-url-button noselect" data-clipboard-text="<?php echo $shorturl; ?>">Copy</button>
<span class="info">View info &amp; stats at <a href="<?php echo $shorturl; ?>+"><?php echo $url; ?>+</a></span>
</section>
</div>
</section>
<div class="card-body px-5 pb-5">
<h2 class="text-uppercase text-center">Your shortened link</h2>
<div class="row justify-content-center">
<div class="col-10">
<div class="input-group input-group-block mt-4 mb-3">
<input type="text" class="form-control text-uppercase" value="<?php echo $shorturl; ?>" required>
<button class="btn btn-primary text-uppercase py-2 px-5 mt-2 mt-md-0" type="submit" id="copy-button" data-shorturl="<?php echo $shorturl; ?>">Copy</button>
</div>
<span class="info">View info &amp; stats at <a href="<?php echo $shorturl; ?>+"><?php echo $url; ?>+</a></span>
</div>
</div>
</div>
<?php else: ?>
<div class="text-center">
<img src="<?php echo YOURLS_SITE ?><?php echo logo ?>" alt="Logo" width="95px" class="mt-n5">
</div>
<div class="card-body px-md-5">
<p><?php echo description ?></p>
<script>
var clipboard = new ClipboardJS('.short-url-button');
</script>
<?php if ( isset( $_REQUEST['url'] ) && $_REQUEST['url'] != 'http://' ): ?>
<?php if (strpos($message,'added') === false): ?>
<div class="alert alert-danger alert-dismissible fade show" role="alert">
<span>Oh no, <?php echo $message; ?>!</span>
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
<?php endif; ?>
<?php endif; ?>
<?php else: ?>
<?php $site = YOURLS_SITE; ?>
<div class="container verticle-center main">
<div class="main-content">
<div class="above">
<img class="noselect" src="<?php echo siteURL ?><?php echo logo ?>" alt="Logo" width="95px">
</div>
<section class="head">
<p><?php echo description ?></p>
</section>
<section class="field-section">
<?php if ( isset( $_REQUEST['url'] ) && $_REQUEST['url'] != 'http://' ): ?>
<?php if (strpos($message,'added') === false): ?>
<div id="error" class="alert alert-warning error" role="alert">
<h5>Oh no, <?php echo $message; ?>!</h5>
</div>
<?php endif; ?>
<?php endif; ?>
<form id="shortenlink" method="post" action="">
<input type="url" name="url" class="url" id="url" placeholder="PASTE URL, SHORTEN &amp; SHARE" required>
<input type="submit" value="Shorten">
<?php if (enableCustomURL): ?>
<span class="customise-button noselect" id="customise-toggle"><img src="<?php echo siteURL ?>/frontend/assets/svg/custom-url.svg" alt="Options"> Customise Link</span>
<div class="customise-container" id="customise-link" style="display:none;">
<span><?php echo preg_replace("(^https?://)", "", siteURL ); ?>/</span>
<input type="text" name="keyword" class="custom" placeholder="CUSTOM URL">
<form id="shortenlink" method="post" action="">
<div class="input-group input-group-block mt-4 mb-3">
<input type="url" name="url" id="url" class="form-control text-uppercase" placeholder="PASTE URL, SHORTEN &amp; SHARE" aria-label="PASTE URL, SHORTEN &amp; SHARE" aria-describedby="shorten-button" required>
<input class="btn btn-primary text-uppercase py-2 px-4 mt-2 mt-md-0" type="submit" id="shorten-button" value="Shorten" />
</div>
<?php if (enableCustomURL): ?>
<a class="btn btn-sm btn-white text-black-50 text-uppercase" data-bs-toggle="collapse" href="#customise-link" role="button" aria-expanded="false" aria-controls="customise-link">
<img src="<?php echo YOURLS_SITE ?>/frontend/assets/svg/custom-url.svg" alt="Options"> Customise Link
</a>
<div class="collapse" id="customise-link">
<div class="mt-2 card card-body">
<div class="d-flex align-items-center">
<span class="me-2"><?php echo preg_replace("(^https?://)", "", YOURLS_SITE ); ?>/</span>
<input type="text" name="keyword" class="form-control form-control-sm text-uppercase" placeholder="CUSTOM URL" aria-label="CUSTOM URL">
</div>
</div>
</div>
<?php endif; ?>
</form>
</div>
<?php endif; ?>
</form>
</section>
<section class="footer">
<div>
<span class="light">&copy; <?php echo date("Y"); ?> <?php echo shortTitle ?></span>
<div class="footer-links">
<?php foreach ($footerLinks as $key => $val): ?>
<a href="<?php echo $val ?>"><span><?php echo $key ?></span></a>
<?php endforeach ?>
</div>
<div class="d-flex flex-column flex-md-row align-items-center my-3">
<span class="text-white fw-light">&copy; <?php echo date("Y"); ?> <?php echo shortTitle ?></span>
<div class="ms-3">
<?php foreach ($footerLinks as $key => $val): ?>
<a class="bold-link me-3 text-white text-decoration-none" href="<?php echo $val ?>"><span><?php echo $key ?></span></a>
<?php endforeach ?>
</div>
</div>
</div>
</div>
</section>
</div>
</div>
<?php endif; ?>
<?php include 'frontend/footer.php'; ?>
<?php include 'frontend/footer.php'; ?>
</body>
</html>