First commit
This commit is contained in:
77
application/demo/page/news.page.backButton.js
Normal file
77
application/demo/page/news.page.backButton.js
Normal file
@@ -0,0 +1,77 @@
|
||||
|
||||
import icon from "/elements/icon.js";
|
||||
|
||||
export default class backButton{
|
||||
|
||||
text = "<"
|
||||
|
||||
color = "white"
|
||||
|
||||
fontWeight = "bold"
|
||||
|
||||
cursor = "pointer";
|
||||
|
||||
propegateEvent = false
|
||||
|
||||
transition = "2s";
|
||||
|
||||
margin = 10;
|
||||
|
||||
marginLeft = 20;
|
||||
|
||||
fontFamily = "unset"
|
||||
|
||||
|
||||
|
||||
#ifdef WINDOWS
|
||||
|
||||
#ifdef DARK
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef LIGHT
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef MACOS
|
||||
|
||||
#ifdef DARK
|
||||
|
||||
boxBackground = "#282828";
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef LIGHT
|
||||
|
||||
boxBackground = "#ffffff";
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
click() {
|
||||
|
||||
this.stateMachine.composeState( "Home" );
|
||||
|
||||
this.openNewsItems();
|
||||
|
||||
}
|
||||
|
||||
state openNewsItems() {
|
||||
|
||||
var rightSide = this.parents("newsPages");
|
||||
|
||||
//rightSide.newsItemPage.marginLeft = "0";
|
||||
|
||||
rightSide.newsItemPage.transform = "translateX(0)";
|
||||
|
||||
rightSide.newsPage.transform = "translateX(0)";
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user