such a yes
This commit is contained in:
parent
2ee0adf095
commit
2a4ac40ee2
4 changed files with 185 additions and 0 deletions
91
css/app.css
Normal file
91
css/app.css
Normal file
|
@ -0,0 +1,91 @@
|
|||
:root {
|
||||
font-family: system-ui, sans-serif;
|
||||
|
||||
--dark-1: rgb(64,64,64);
|
||||
--dark-2: rgb(128,128,128);
|
||||
|
||||
--dark-3: rgb(192,192,192);
|
||||
--dark-4: rgb(255,255,255);
|
||||
|
||||
background-image: linear-gradient(to bottom, rgba(255,255,255,0.7), rgba(255,255,255,0.9)), url('../obama.png');
|
||||
background-size: 50px 50px;
|
||||
background-position: 0 0;
|
||||
}
|
||||
|
||||
body {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
color: var(--dark-1);
|
||||
}
|
||||
|
||||
h1 {
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
.content {
|
||||
background: var(--dark-4);
|
||||
max-width: 95vw;
|
||||
padding: 10px;
|
||||
width: 800px;
|
||||
margin: auto;
|
||||
|
||||
}
|
||||
|
||||
input {
|
||||
padding: 0.2rem;
|
||||
margin: 0.2rem;
|
||||
display: block;
|
||||
border: solid var(--dark-2) 1px;
|
||||
border-radius: 0.2rem;
|
||||
}
|
||||
|
||||
.header {
|
||||
background: var(--dark-1);
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
position: sticky;
|
||||
top: 0;
|
||||
}
|
||||
|
||||
img {
|
||||
height: 3rem;
|
||||
margin: 0.5rem ;
|
||||
display: block;
|
||||
|
||||
width: 40vmin;
|
||||
height: auto;
|
||||
}
|
||||
|
||||
.header a {
|
||||
margin: 0.5rem;
|
||||
}
|
||||
|
||||
.header a {
|
||||
color: var(--dark-4);
|
||||
}
|
||||
|
||||
pre {
|
||||
overflow: scroll;
|
||||
}
|
||||
|
||||
#area-main {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.proj {
|
||||
text-align: center;
|
||||
max-width: 240px;
|
||||
margin: 10px;
|
||||
}
|
||||
|
||||
.proj img {
|
||||
width: 240px;
|
||||
}
|
||||
|
||||
.contributors {
|
||||
overflow: scroll;
|
||||
height: 100px;
|
||||
}
|
43
index.html
Normal file
43
index.html
Normal file
|
@ -0,0 +1,43 @@
|
|||
<!DOCTYPE html>
|
||||
<head>
|
||||
<link rel="icon" href="/res/img/favi.svg">
|
||||
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
||||
<link rel="stylesheet" href="css/app.css" />
|
||||
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Open+Sans:wght@700&display=swap" rel="stylesheet">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div class="content">
|
||||
<h1>Frictionless - Platformer Remix Train <a href="https://git.qazox.dev/derv/frictionless">[GitHub]</a></h1>
|
||||
<pre>Only projects directly or indirectly remixed from @--Eternity--'s Frictionless - Platformer
|
||||
|
||||
Remixes: 3
|
||||
The chain with no* rules that happened from one featured platformer back in 2019.
|
||||
|
||||
You do have to follow the eras listed below. ALSO PLEASE KEEP PROJECTS IN ALPHABETICAL ORDER
|
||||
-------------Rules--------------------
|
||||
1. nobody should not not try not to not avoid not avoiding not refraining from not turning it into a spam chain (technically this isn't not not a rule but whatever)
|
||||
2. j
|
||||
-------------Information-------------
|
||||
Orange is an unincorporated community in Clark County, Illinois, United States. Orange is located in south central Clark County west of West Union.
|
||||
-------------Latest Remix-----------
|
||||
The latest remix is the 1th project.
|
||||
small sun
|
||||
https://scratch.mit.edu/projects/10000007/editor/
|
||||
|
||||
*±2</pre>
|
||||
|
||||
<h2>Made by...</h2>
|
||||
<div class='contributors'></div>
|
||||
</div>
|
||||
<div id='area-main'>
|
||||
|
||||
</div>
|
||||
<script src='js/app.js'></script>
|
||||
</body>
|
||||
|
51
js/app.js
Normal file
51
js/app.js
Normal file
|
@ -0,0 +1,51 @@
|
|||
let area = document.querySelector('#area-main');
|
||||
let entries = [];
|
||||
let users = {};
|
||||
|
||||
let fetchData;
|
||||
|
||||
async function genTree(treeId) {
|
||||
fetchData = await fetch(`https://scratch.mit.edu/projects/${treeId}/remixtree/bare`)
|
||||
.then(x => x.json());
|
||||
|
||||
entries.push(treeId)
|
||||
let entry = fetchData[treeId];
|
||||
|
||||
while (entry) {
|
||||
entry = entry.parent_id;
|
||||
entries.push(entry);
|
||||
entry = fetchData[entry];
|
||||
if (entry) users[entry.username] = true;
|
||||
}
|
||||
|
||||
return entry;
|
||||
}
|
||||
|
||||
async function main() {
|
||||
await genTree("945978970"); // latest project
|
||||
await genTree("654605857"); // tree bug here, unavoidable without jank
|
||||
console.log(entries)
|
||||
document.querySelector('.contributors').textContent = Object.keys(users).join(', ');
|
||||
}
|
||||
|
||||
main();
|
||||
|
||||
let i = 0;
|
||||
|
||||
function sanitize(content) {
|
||||
const decoder = document.createElement('div');
|
||||
decoder.textContent = content;
|
||||
return decoder.innerHTML;
|
||||
}
|
||||
|
||||
setInterval(function() {
|
||||
if ((window.innerHeight + window.scrollY) >= document.body.scrollHeight) {
|
||||
let h = '';
|
||||
for (let j = 0; j < 35; j++) {
|
||||
let entry = entries[i];
|
||||
h += `<div class='proj'><a href="https://scratch.mit.edu/projects/${entry}"><img src='https://uploads.scratch.mit.edu/get_image/project/${entry}_1920x1080.png'>${fetchData[entry].title}</a></div>`;
|
||||
i++;
|
||||
}
|
||||
area.innerHTML += h;
|
||||
}
|
||||
},500);
|
BIN
obama.png
Normal file
BIN
obama.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 7.8 KiB |
Loading…
Reference in a new issue