adding some market elements
This commit is contained in:
@@ -8,6 +8,16 @@ class Home extends Shadow {
|
||||
|
||||
render() {
|
||||
ZStack(() => {
|
||||
img("_/icons/logo.svg", "3.5em")
|
||||
.position("fixed")
|
||||
.left("3em")
|
||||
.top("2em")
|
||||
.zIndex(3)
|
||||
// .onClick(() => {
|
||||
// window.navigateTo("/")
|
||||
// this.rerender()
|
||||
// })
|
||||
|
||||
div()
|
||||
.width(100, vw)
|
||||
.height(100, vh)
|
||||
@@ -17,64 +27,59 @@ class Home extends Shadow {
|
||||
.backgroundPosition("48% 65%")
|
||||
.backgroundRepeat("no-repeat")
|
||||
|
||||
switch(window.location.pathname) {
|
||||
case "/":
|
||||
AppWindow()
|
||||
AppMenu()
|
||||
break
|
||||
case "/app/forum":
|
||||
AppWindow("Forum")
|
||||
AppMenu("Forum")
|
||||
break;
|
||||
case "/app/messages":
|
||||
AppWindow("Messages")
|
||||
AppMenu("Messages")
|
||||
break;
|
||||
case "/app/market":
|
||||
AppWindow("Market")
|
||||
AppMenu("Market")
|
||||
break;
|
||||
}
|
||||
switch(window.location.pathname) {
|
||||
case "/":
|
||||
AppWindow()
|
||||
AppMenu()
|
||||
break
|
||||
case "/app/forum":
|
||||
AppWindow("Forum")
|
||||
AppMenu("Forum")
|
||||
break;
|
||||
case "/app/messages":
|
||||
AppWindow("Messages")
|
||||
AppMenu("Messages")
|
||||
break;
|
||||
case "/app/market":
|
||||
AppWindow("Market")
|
||||
AppMenu("Market")
|
||||
break;
|
||||
}
|
||||
|
||||
ProfileButton()
|
||||
.zIndex(1)
|
||||
.cursor("default")
|
||||
.position("fixed")
|
||||
.top("5.5vh")
|
||||
.right("4.5vw")
|
||||
ProfileButton()
|
||||
.zIndex(1)
|
||||
.cursor("default")
|
||||
.position("fixed")
|
||||
.top("5.5vh")
|
||||
.right("4.5vw")
|
||||
|
||||
img("_/icons/logo.svg", "3.5em")
|
||||
.position("fixed")
|
||||
.left("3em")
|
||||
.top("2em")
|
||||
|
||||
a("/signout", "Sign Out")
|
||||
.position("fixed")
|
||||
.top("3em")
|
||||
.right("2em")
|
||||
.background("transparent")
|
||||
.border("1px solid var(--tan)")
|
||||
.color("var(--tan)")
|
||||
.borderRadius(5, px)
|
||||
.onHover(function (hovering) {
|
||||
console.log('hovering', hovering, this)
|
||||
if(hovering) {
|
||||
this.style.background = "var(--tan)"
|
||||
this.style.color = "black"
|
||||
} else {
|
||||
this.style.background = ""
|
||||
this.style.color = "var(--tan)"
|
||||
}
|
||||
})
|
||||
.onNavigate(function () {
|
||||
if(window.location.pathname === "/") {
|
||||
this.style.border = "1px solid var(--tan)"
|
||||
this.style.color = "var(--tan)"
|
||||
} else {
|
||||
this.style.border = "1px solid var(--accent)"
|
||||
this.style.color = "var(--accent)"
|
||||
}
|
||||
})
|
||||
a("/signout", "Sign Out")
|
||||
.position("fixed")
|
||||
.top("3em")
|
||||
.right("2em")
|
||||
.background("transparent")
|
||||
.border("1px solid var(--tan)")
|
||||
.color("var(--tan)")
|
||||
.borderRadius(5, px)
|
||||
.onHover(function (hovering) {
|
||||
console.log('hovering', hovering, this)
|
||||
if(hovering) {
|
||||
this.style.background = "var(--tan)"
|
||||
this.style.color = "black"
|
||||
} else {
|
||||
this.style.background = ""
|
||||
this.style.color = "var(--tan)"
|
||||
}
|
||||
})
|
||||
.onNavigate(function () {
|
||||
if(window.location.pathname === "/") {
|
||||
this.style.border = "1px solid var(--tan)"
|
||||
this.style.color = "var(--tan)"
|
||||
} else {
|
||||
this.style.border = "1px solid var(--accent)"
|
||||
this.style.color = "var(--accent)"
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user