Added repos tab, merged feedback/test sender, added irc link, other improvements

This commit is contained in:
MrFry 2020-03-19 16:32:30 +01:00
parent c1f019956a
commit b8f87452b9
8 changed files with 61 additions and 48 deletions

View file

@ -16,7 +16,6 @@ export default function Layout (props) {
const closeSideBar = () => {
if (typeof window !== 'undefined') {
console.log('window.innerWidth', window.innerWidth)
if (window.innerWidth < constants.mobileWindowWidth) {
setSidebarOpen(false)
}
@ -53,9 +52,12 @@ export default function Layout (props) {
</Link>
)
})}
<a href={constants.serverUrl + 'donate'}>
<a href='/donate'>
Donate
</a>
<a href='/irc'>
IRC chat
</a>
</div>
: null}
</div>

View file

@ -1,5 +1,4 @@
{
"apiUrl": "http://api.frylabs.net/",
"serverUrl": "http://qmining.frylabs.net/",
"mobileWindowWidth": 700
}

View file

@ -11,12 +11,12 @@
"href": "/allQuestions",
"text": "All question"
},
"repos": {
"href": "/repos",
"text": "Repos"
},
"feedback": {
"href": "/feedback",
"text": "Feedback"
},
"testSender": {
"href": "/testSender",
"text": "Test Sender"
}
}

View file

@ -2,7 +2,7 @@ export default function Custom404 () {
return (
<center>
<h1>404</h1>
<iframe width='660' height='465' src='https://www.youtube-nocookie.com/embed/GOzwOeONBhQ' frameborder='0' allow='accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture' allowfullscreen />
<iframe width='660' height='465' src='https://www.youtube-nocookie.com/embed/GOzwOeONBhQ' frameBorder='0' allow='accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture' allowFullScreen />
</center>
)
}

View file

@ -3,7 +3,7 @@ function Error ({ statusCode }) {
return (
<center>
<h1>404</h1>
<iframe width='100%' height='465' src='https://www.youtube-nocookie.com/embed/GOzwOeONBhQ' frameborder='0' allow='accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture' allowfullscreen />
<iframe width='100%' height='465' src='https://www.youtube-nocookie.com/embed/GOzwOeONBhQ' frameBorder='0' allow='accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture' allowFullScreen />
</center>
)
}

View file

@ -3,6 +3,29 @@ import constants from '../constants.json'
export default function Feedback (props) {
// TODO: textarea style to css
// TODO: response to user that msg is sucessfully sent
const renderTestSender = () => {
return (
<div>
Hibát kiváltó teszt feltöltése
<br />
<form action={constants.apiUrl + 'badtestsender'} encType='multipart/form-data' method='post'>
<input type='file' name='dasfile' />
<input type='submit' value='Upload' />
</form>
<p />
Ha egy kérdésre mindig helytelenül talál választ a userscript (vagy egyéb hibát észlelsz), akkor
azon az oldalon nyomj egy ctrl-s -t. Ez lementi a weboldalt úgy ahogy van egy mappába, és egy
html fájlba. Ezt a kettőt ha berakod egy .zip-be, és ide feltöltöd, akkor ránézek mi lehet a
hiba, és kijavítom. <b> Max 10 MB! </b> Ha több, elég a .html. Bónusz ha mellékelsz egy
readme-t, hogy mit csináljak.
</div>
)
}
const renderFeedback = () => {
return (
<div>
<form action={constants.apiUrl + 'postfeedback'} method='post'>
@ -22,4 +45,15 @@ export default function Feedback (props) {
</form>
</div>
)
}
return (
<div>
{renderFeedback()}
<p />
<hr />
<p />
{renderTestSender()}
</div>
)
}

View file

@ -94,7 +94,7 @@ export default function Index (props) {
key={key}
>
<a
href={constants.serverUrl + link.href}
href={link.href}
>
{link.text}
</a>

View file

@ -1,22 +0,0 @@
import constants from '../constants.json'
export default function TestSender (props) {
return (
<div>
Hibát kiváltó teszt feltöltése
<br />
<form action={constants.serverUrl + 'badtestsender'} encType='multipart/form-data' method='post'>
<input type='file' name='dasfile' />
<input type='submit' value='Upload' />
</form>
<p />
Ha egy kérdésre mindig helytelenül talál választ a userscript (vagy egyéb hibát észlelsz), akkor
azon az oldalon nyomj egy ctrl-s -t. Ez lementi a weboldalt úgy ahogy van egy mappába, és egy
html fájlba. Ezt a kettőt ha berakod egy .zip-be, és ide feltöltöd, akkor ránézek mi lehet a
hiba, és kijavítom. <b> Max 10 MB! </b> Ha több, elég a .html. Bónusz ha mellékelsz egy
readme-t, hogy mit csináljak.
</div>
)
}