diff options
author | JoelHMikael <joel.h.kronqvist@gmail.com> | 2021-12-30 21:30:53 +0200 |
---|---|---|
committer | JoelHMikael <joel.h.kronqvist@gmail.com> | 2021-12-30 21:30:53 +0200 |
commit | 7743b9ff7b9eb85ea9502e401529f10fed83a0f6 (patch) | |
tree | 9aea492f7595d321156800fa2de60699e721442b | |
parent | 4c4f007130ff20691b9ac2f5fbf05ed5be3c9931 (diff) | |
download | LYLLRuoka-7743b9ff7b9eb85ea9502e401529f10fed83a0f6.tar.gz LYLLRuoka-7743b9ff7b9eb85ea9502e401529f10fed83a0f6.zip |
Footer
-rw-r--r-- | index.css | 28 | ||||
-rw-r--r-- | index.html | 6 | ||||
-rw-r--r-- | parse.js | 51 |
3 files changed, 32 insertions, 53 deletions
@@ -56,6 +56,11 @@ body { margin: .5em; } +/*** the input field & choose ***/ +#input[type="text"], select { + background-color: white; +} + /*** the send-button ***/ #send { background: blue; @@ -74,6 +79,25 @@ body { box-shadow: .25em .25em; } +/*** Footer ***/ +footer { + position: fixed; + top: calc(100% - 3em); + left: 0; + + width: 100%; + margin: 0; + padding: 1em; + line-height: 1em; + box-sizing: border-box; + + background-color: #0d0d0d; +} + +footer > a { + color: #b3b3b3; +} + /*** The shadowed elements ***/ .highlight { border: 1px solid black; @@ -88,7 +112,7 @@ img.info { vertical-align: middle; } -img.info ~ span { +img.info + span { position: relative; vertical-align: middle; left: -1em; @@ -120,7 +144,7 @@ p.infoblock { opacity: 0; } -img.info:hover ~ span > p.infoblock { +img.info:hover + span > p.infoblock { animation-name: fade-in; animation-duration: var(--fadetime); visibility: visible; @@ -53,5 +53,11 @@ </div> </div> </main> + + <footer> + <a href="https://www.github.com/JoelHMikael/FoodJS">Lähdekoodi</a> + <span>|</span> + <a href="https://www.example.com">Ota yhteyttä</a> + </footer> </body> </html> @@ -1,54 +1,3 @@ -/*let i = 0; - let foodShiftNames = []; - let db = []; // first level array: days - second level array: shifts - third level dict: course/teacher - fourth level array: indexes - while (db.length < weekdays.length) - { - i = findExpression(data, weekdays[db.length], i); - let end = i; - if (db.length === weekdays.length) - end = data.length; - else - end = findExpression(data, weekdays[db.length + 1], i + 1); - - db.push([]); // add the day - let shifts = 0; - - do - { - let teachers = []; - let courses = []; - i = findExpression(data, "RUOKAILUVUORO", i); - let nextLineStart = getNextChar(data, i, "\n"); - foodShiftNames.push(data.substring(i, nextLineStart)); - db[db.length - 1].push([]); // add the food shift - nextLineStart = getNextChar(data, nextLineStart + 1, "\n"); - while (!((nextLineStart - i) > 2)) - { - i = nextLineStart; - nextLineStart = getNextChar(data, i + 1, "\n"); - } - let parsedLine = data.substring(i, nextLineStart).replaceAll(",", "").replaceAll("ja ", ""); - let parse_i = 0; - let nextSpace = getNextChar(parsedLine, parse_i, " "); - while (parse_i !== -1) - { - courses.push(parsedLine.substring(parse_i, nextSpace)); - parse_i = nextSpace + 1; - nextSpace = getNextChar(parsedLine, parse_i, " "); - teachers.push(parsedLine.substring(parse_i, nextSpace)); - parse_i = nextSpace + 1; - nextSpace = getNextChar(parsedLine, parse_i, " "); - } - i = nextLineStart; - db[db.length - 1][shifts][0] = courses; - db[db.length - 1][shifts][1] = teachers; - shifts++; - } while ((i < end) && (i !== -1)) - - i = getNextChar("\n"); - } - return [db, foodShiftNames];*/ - function getCharAmount(s, c) { let n = 0; |