Skip to content

Instantly share code, notes, and snippets.

@LewisRhine
Created January 5, 2017 19:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save LewisRhine/9f73a093dfa89a5ed9237358df0d581c to your computer and use it in GitHub Desktop.
Save LewisRhine/9f73a093dfa89a5ed9237358df0d581c to your computer and use it in GitHub Desktop.
fun main(args: Array<String>) {
val mdlApp = mdlApp {
navigationLayout(About, "layout") {
header {}
drawer("drawer") {
mainElement.header("drawer-header ${MdlColor.Background.blueGrey(Shade.s300)}") {
img("avatar") { src = "images/roundprofile.png" }
b { textContent = "Lewis Rhine" }
append(document.createTextNode("Android Developer"))
}
nav("navigation") {
link { text = "About"; materialIcons = "account_circle"; onClick { content = About } }
link { text = "Blog"; materialIcons = "book"; href = "https://medium.com/lewisrhine" }
link { text = "Projects"; materialIcons = "build"; href = "https://github.com/lewisrhine" }
link {
text = "Twitter"
href = "https://twitter.com/lewisrhine"
mainElement.append(document.createElement("i").apply {
setAttribute("class", "material-icons fa fa-twitter")
})
}
link {
text = "Instagram"
href = "https://www.instagram.com/lewisrhine"
mainElement.append(document.createElement("i").apply {
setAttribute("class", "material-icons fa fa-instagram")
})
}
link {
text = "LinkedIn"
href = "https://www.linkedin.com/in/lewisrhine"
mainElement.append(document.createElement("i").apply {
setAttribute("class", "material-icons fa fa-linkedin")
})
}
link { text = "email"; href = "mailto:lewisrhine@gmail.com"; materialIcons = "email" }
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment