garapenean...

This commit is contained in:
2021-04-20 16:24:53 +02:00
parent 77adf56da7
commit 39bf61af39
14 changed files with 223 additions and 16 deletions
+2
View File
@@ -0,0 +1,2 @@
//footer.pug
footer wproject - 2021
+6
View File
@@ -0,0 +1,6 @@
//header.pug
header
.title
h3 ariketa 3
.next(onclick='window.location.href="irudiak"')
.back(onclick='window.history.go(-1)')
+18
View File
@@ -0,0 +1,18 @@
extends layout
block content
if logged
#logged
h1 Kaixo !{username}!!
p
| Hau Node.js, Express.js eta Pug erabiliz egindako nabigazio adibide bat da.
else
#unknown
h4 Erabiltzailea:
form(action='./' method='post')
input(type='text' name='username')
button Sartu
p
| Oharra: sartzen duzun izena 15 minutuan iraungitzen den cookie batean gordeko da.
+36
View File
@@ -0,0 +1,36 @@
doctype
html(lang='eu')
head
title Node.js Express.js Pug adibidea
meta(name='viewport', content='width=device-width, initial-scale=1.0')
base(href='/')
link(rel='stylesheet', href='css/styles.css')
link(rel='stylesheet', href='css/header.css')
link(rel='stylesheet', href='css/footer.css')
link(rel='shortcut icon', href='#')
script.
window.onload = function () {
var logged = "#{logged}"
var path = window.location.pathname;
if(path != '/'){
document.querySelector('.back').style.display = 'block';
document.querySelector('.next').style.display = 'none';
}else{
document.querySelector('.back').style.display = 'none';
if(logged) {
document.querySelector('.next').style.display = 'block';
}
}
};
body
block header
include header
block content
block footer
include footer
+7
View File
@@ -0,0 +1,7 @@
extends ../layout.pug
block content
-var num
.edukiontzia
h1 Irudi !{num}
img.irudi(src='images/irudi_'+num+'.jpg')
+19
View File
@@ -0,0 +1,19 @@
extends ../layout.pug
block content
.edukiontzia
h1 Irudiak
.irudiak
div
img.irudi_1(src='images/irudi_1.jpg' onclick='window.location.href="images/irudi_1.jpg"')
p
a(href='irudi_1') irudi 1
div
img.irudi_2(src='images/irudi_2.jpg' onclick='window.location.href="images/irudi_2.jpg"')
p
a(href='irudi_2') irudi 2
div
img.irudi_3(src='images/irudi_3.jpg' onclick='window.location.href="images/irudi_3.jpg"')
p
a(href='irudi_3') irudi 3