Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 21f4ba4f87 | |||
| abce59057d | |||
| df8e8b8355 | |||
| 6ff2eaa540 |
@ -1 +1,2 @@
|
|||||||
Dockerfile
|
Dockerfile
|
||||||
|
readme.md
|
||||||
|
|||||||
35
config/config.json
Normal file
35
config/config.json
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
{
|
||||||
|
"search_engine": "https://www.google.com/search",
|
||||||
|
"categories": [
|
||||||
|
{
|
||||||
|
"image": "res/4chan.png",
|
||||||
|
"links": [
|
||||||
|
{"href":"https://boards.4chan.org/w/", "label":"walls"},
|
||||||
|
{"href":"https://boards.4chan.org/g/", "label":"tech"},
|
||||||
|
{"href":"https://boards.4chan.org/a/", "label":"anime"},
|
||||||
|
{"href":"https://boards.4chan.org/mu/", "label":"music"}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"image": "res/social.png",
|
||||||
|
"links": [
|
||||||
|
{"href":"https://facebook.com", "label":"facebook"},
|
||||||
|
{"href":"https://youtube.com/", "label":"youtube"},
|
||||||
|
{"href":"https://tumblr.com", "label":"tumblr"}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"image": "res/music.png",
|
||||||
|
"links": [
|
||||||
|
{"href":"https://last.fm", "label":"last.fm"},
|
||||||
|
{"href":"https://bandcamp.com/", "label":"bandcamp"}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"image": "res/mail.png",
|
||||||
|
"links": [
|
||||||
|
{"href":"https://mail.google.com", "label":"gmail"}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
88
config/style.css
Normal file
88
config/style.css
Normal file
@ -0,0 +1,88 @@
|
|||||||
|
|
||||||
|
a{
|
||||||
|
color:#c3c3c3;
|
||||||
|
font-family:"Segoe UI";
|
||||||
|
font-size:25px;
|
||||||
|
text-decoration:none;
|
||||||
|
margin-left:5px;
|
||||||
|
transition-property: color;
|
||||||
|
transition-duration: .1s;
|
||||||
|
transition-timing-function: linear;
|
||||||
|
}
|
||||||
|
body{
|
||||||
|
padding-left:10px;
|
||||||
|
padding-right:10px;
|
||||||
|
font-family:"Segoe UI";
|
||||||
|
color:#c8c8c8;
|
||||||
|
font-size:34px;
|
||||||
|
background:#FBFBFB;
|
||||||
|
}
|
||||||
|
|
||||||
|
span{
|
||||||
|
margin-left:10px;
|
||||||
|
text-family:"segoe UI";
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
a:hover { color:#A9BFA5}
|
||||||
|
|
||||||
|
input[type=text] {
|
||||||
|
width: 18px;
|
||||||
|
padding: 3px;
|
||||||
|
position:absolute;
|
||||||
|
right:5px;bottom:5px;
|
||||||
|
border: 1px solid #E6e6e6;
|
||||||
|
transition-property: all;
|
||||||
|
transition-duration: .5s;
|
||||||
|
transition-timing-function: ease;
|
||||||
|
color: #bebebe;
|
||||||
|
background-position: -2px -1px;
|
||||||
|
background-image: url('../res/search.png');
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
}
|
||||||
|
|
||||||
|
input[type=text]:hover {
|
||||||
|
border-color: #bebebe;
|
||||||
|
transition-property: all;
|
||||||
|
transition-duration: .5s;
|
||||||
|
transition-timing-function: ease;
|
||||||
|
color: #bebebe;
|
||||||
|
width:230px;
|
||||||
|
background-position: 227px -1px;
|
||||||
|
padding-right: 20px;
|
||||||
|
}
|
||||||
|
input[type=text]:focus {
|
||||||
|
border-color: #bebebe;
|
||||||
|
transition-property: all;
|
||||||
|
transition-duration: .5s;
|
||||||
|
transition-timing-function: ease;
|
||||||
|
color: #bebebe;
|
||||||
|
width:230px;
|
||||||
|
background-position: 227px -1px;
|
||||||
|
padding-right: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.boxed {
|
||||||
|
border: 1px solid #e6e6e6;
|
||||||
|
padding: 5px;
|
||||||
|
color: #494949;
|
||||||
|
background-color: #ffffff;
|
||||||
|
width: 760px;
|
||||||
|
margin-left: -390px;
|
||||||
|
margin-right: auto;
|
||||||
|
position:absolute;
|
||||||
|
left: 50%;
|
||||||
|
top: 40%;
|
||||||
|
}
|
||||||
|
|
||||||
|
h1 {
|
||||||
|
padding-bottom: -600px;
|
||||||
|
position: absolute;
|
||||||
|
visibility: hidden;
|
||||||
|
margin-top: -200px;
|
||||||
|
margin-left: -380px;
|
||||||
|
left: 50%;
|
||||||
|
top: 40%;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
53
index.html
53
index.html
@ -1,36 +1,17 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<!-- homepage by noha javascript by nullbyte -->
|
<!-- original homepage by noha https://www.deviantart.com/noha-ra/art/Konbanwa-homepage-450787545 -->
|
||||||
|
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||||
<link rel="stylesheet" href="src/style.css">
|
<link rel="stylesheet" href="src/animations.css">
|
||||||
<link rel="stylesheet" href="src/animations.css">
|
<link rel="stylesheet" href="config/style.css">
|
||||||
<script src="src/jquery.min.js"></script>
|
<script src="src/jquery.min.js"></script>
|
||||||
<script src="src/script.js"></script>
|
<script src="src/script.js"></script>
|
||||||
<title>new tab</title>
|
<title>new tab</title>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<h1 align="center" id="message" class="expandUp"></h1>
|
<h1 align="center" id="message" class="expandUp"></h1>
|
||||||
<div class="boxed" class=slideUp>
|
<div id="categories" class="boxed slideUp">
|
||||||
<span> <img src="res/4chan.png"></span>
|
</div>
|
||||||
<a style="padding-left:10px" href="http://boards.4chan.org/w/">walls</a>
|
</body>
|
||||||
<a href="http://boards.4chan.org/g/">tech</a>
|
|
||||||
<a href="http://boards.4chan.org/a/">anime</a>
|
|
||||||
<a href="http://boards.4chan.org/mu/">music</a>
|
|
||||||
</br>
|
|
||||||
<span> <img src="res/social.png"></span>
|
|
||||||
<a style="padding-left:10px" href="https://www.facebook.com">facebook</a>
|
|
||||||
<a href="http://youtube.com">youtube</a>
|
|
||||||
<a href="http://tumblr.com">tumblr</a>
|
|
||||||
</br>
|
|
||||||
<span> <img src="res/music.png"></span>
|
|
||||||
<a style="padding-left:10px" href="http://www.last.fm">last.fm</a>
|
|
||||||
<a href="http://bandcamp.com">bandcamp</a>
|
|
||||||
</br>
|
|
||||||
<span> <img src="res/mail.png"></span>
|
|
||||||
<a style="padding-left:10px" href="http://mail.google.com">gmail</a>
|
|
||||||
</br>
|
|
||||||
<form method="get" action="http://www.google.com/search"> <input type="text" placeholder="" value="" name="q">
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
|
|||||||
@ -13,3 +13,5 @@ docker pull tuxpa.in/a/homepage:stable
|
|||||||
it runs on port 8076
|
it runs on port 8076
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
woodpecker ci [](https://ci.tuxpa.in/a/homepage)
|
||||||
|
|||||||
@ -1,28 +1,72 @@
|
|||||||
|
const updateTime = () => {
|
||||||
|
const n = (new Date()).getHours()
|
||||||
|
var imgName = "goodnight"
|
||||||
|
if ( n == 23 || n == 0) {
|
||||||
|
imgName = "goodnight"
|
||||||
|
} else if ( n >= 1 && n <= 4 ) {
|
||||||
|
imgName = "goodnight"
|
||||||
|
} else if ( n >= 5 && n <= 11 ) {
|
||||||
|
imgName = "goodmorning"
|
||||||
|
} else if ( n >= 12 && n <= 17 ) {
|
||||||
|
imgName = "goodafternoon"
|
||||||
|
} else if ( n >= 18 && n <= 22 ) {
|
||||||
|
imgName = "goodevening"
|
||||||
|
}
|
||||||
|
//$("#message").html(imgName)
|
||||||
|
$("#message").html(`<image src="res/${imgName}.png" />`)
|
||||||
|
}
|
||||||
|
|
||||||
var d = new Date();
|
const renderCategoryLink = (link, first) => {
|
||||||
var n = d.getHours();
|
if(first) {
|
||||||
var message = ""
|
return `<a style="padding-left:10px" href="${link.href}">${link.label}</a>
|
||||||
|
`
|
||||||
|
}
|
||||||
|
return `<a href="${link.href}">${link.label}</a>
|
||||||
|
`
|
||||||
|
}
|
||||||
|
const renderCategoryLinks = (links) => {
|
||||||
|
let out = ""
|
||||||
|
for(let i = 0; i < links.length; i++) {
|
||||||
|
out = out + renderCategoryLink(links[i], i==0)
|
||||||
|
}
|
||||||
|
return out
|
||||||
|
}
|
||||||
|
|
||||||
if ( n == 23 || n == 0) {
|
const renderCategory =(obj) => {
|
||||||
message = "<img src='res/goodnight.png'></img>";
|
return `<span> <img src="${obj.image}"></span>
|
||||||
} else if ( n >= 1 && n <= 4 ) {
|
${renderCategoryLinks(obj.links)}</br>
|
||||||
message = "<img src='res/goodnight.png'></img>";
|
`
|
||||||
} else if ( n >= 5 && n <= 11 ) {
|
}
|
||||||
message = "<img src='res/goodmorning.png'></img>";
|
const renderCategories =(objs) => {
|
||||||
} else if ( n >= 12 && n <= 17 ) {
|
let out = ""
|
||||||
message = "<img src='res/goodafternoon.png'></img>";
|
for(let i = 0; i < objs.length; i++) {
|
||||||
} else if ( n >= 18 && n <= 22 ) {
|
out = out + renderCategory(objs[i])
|
||||||
message = "<img src='res/goodevening.png'></img>";
|
}
|
||||||
|
return out
|
||||||
|
}
|
||||||
|
|
||||||
|
const renderCategoriesBox = (data) => {
|
||||||
|
return `${renderCategories(data.categories)}
|
||||||
|
<form method="get" action="${data.search_engine}"> <input type="text" placeholder="" value="" name="q">
|
||||||
|
`
|
||||||
|
}
|
||||||
|
|
||||||
|
const loadUI = () => {
|
||||||
|
$.getJSON("config/config.json", (data)=>{
|
||||||
|
let drawn = renderCategoriesBox(data)
|
||||||
|
console.log(drawn)
|
||||||
|
$("#categories").html(drawn)
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
$(()=>{
|
$(()=>{
|
||||||
document.getElementById("message").innerHTML = message;
|
loadUI();
|
||||||
|
updateTime();
|
||||||
|
setInterval(updateTime, 1000 * 60)
|
||||||
})
|
})
|
||||||
|
|
||||||
$(window).scroll(function() {
|
$(window).scroll(function() {
|
||||||
$('#animatedElement').each(function(){
|
$('#animatedElement').each(function(){
|
||||||
var imagePos = $(this).offset().top;
|
var imagePos = $(this).offset().top;
|
||||||
|
|
||||||
var topOfWindow = $(window).scrollTop();
|
var topOfWindow = $(window).scrollTop();
|
||||||
if (imagePos < topOfWindow+400) {
|
if (imagePos < topOfWindow+400) {
|
||||||
$(this).addClass("slideUp");
|
$(this).addClass("slideUp");
|
||||||
|
|||||||
@ -1,87 +0,0 @@
|
|||||||
a{
|
|
||||||
color:#c3c3c3;
|
|
||||||
font-family:"Segoe UI";
|
|
||||||
font-size:25px;
|
|
||||||
text-decoration:none;
|
|
||||||
margin-left:5px;
|
|
||||||
transition-property: color;
|
|
||||||
transition-duration: .1s;
|
|
||||||
transition-timing-function: linear;
|
|
||||||
}
|
|
||||||
body{
|
|
||||||
padding-left:10px;
|
|
||||||
padding-right:10px;
|
|
||||||
font-family:"Segoe UI";
|
|
||||||
color:#c8c8c8;
|
|
||||||
font-size:34px;
|
|
||||||
background:#FBFBFB;
|
|
||||||
}
|
|
||||||
|
|
||||||
span{
|
|
||||||
margin-left:10px;
|
|
||||||
text-family:"segoe UI";
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
a:hover { color:#A9BFA5}
|
|
||||||
|
|
||||||
input[type=text] {
|
|
||||||
width: 18px;
|
|
||||||
padding: 3px;
|
|
||||||
position:absolute;
|
|
||||||
right:5px;bottom:5px;
|
|
||||||
border: 1px solid #E6e6e6;
|
|
||||||
transition-property: all;
|
|
||||||
transition-duration: .5s;
|
|
||||||
transition-timing-function: ease;
|
|
||||||
color: #bebebe;
|
|
||||||
background-position: -2px -1px;
|
|
||||||
background-image: url('../res/search.png');
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
}
|
|
||||||
|
|
||||||
input[type=text]:hover {
|
|
||||||
border-color: #bebebe;
|
|
||||||
transition-property: all;
|
|
||||||
transition-duration: .5s;
|
|
||||||
transition-timing-function: ease;
|
|
||||||
color: #bebebe;
|
|
||||||
width:230px;
|
|
||||||
background-position: 227px -1px;
|
|
||||||
padding-right: 20px;
|
|
||||||
}
|
|
||||||
input[type=text]:focus {
|
|
||||||
border-color: #bebebe;
|
|
||||||
transition-property: all;
|
|
||||||
transition-duration: .5s;
|
|
||||||
transition-timing-function: ease;
|
|
||||||
color: #bebebe;
|
|
||||||
width:230px;
|
|
||||||
background-position: 227px -1px;
|
|
||||||
padding-right: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.boxed {
|
|
||||||
border: 1px solid #e6e6e6;
|
|
||||||
padding: 5px;
|
|
||||||
color: #494949;
|
|
||||||
background-color: #ffffff;
|
|
||||||
width: 760px;
|
|
||||||
margin-left: -390px;
|
|
||||||
margin-right: auto;
|
|
||||||
position:absolute;
|
|
||||||
left: 50%;
|
|
||||||
top: 40%;
|
|
||||||
}
|
|
||||||
|
|
||||||
h1 {
|
|
||||||
padding-bottom: -600px;
|
|
||||||
position: absolute;
|
|
||||||
visibility: hidden;
|
|
||||||
margin-top: -200px;
|
|
||||||
margin-left: -380px;
|
|
||||||
left: 50%;
|
|
||||||
top: 40%;
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
Loading…
Reference in New Issue
Block a user