mirror of
https://github.com/kristoferssolo/kristofersxyz.git
synced 2025-10-21 18:30:34 +00:00
Added new Names
This commit is contained in:
parent
1097812daf
commit
e0e811227d
@ -1,10 +1,17 @@
|
|||||||
const DISPLAY_NAME = document.getElementById("swap-text")
|
const DISPLAY_NAME = document.getElementById("swap-text")
|
||||||
|
const NAMES = [
|
||||||
|
"Kristiāns",
|
||||||
|
"Francis",
|
||||||
|
"Cagulis",
|
||||||
|
"Kristiāns Francis Cagulis",
|
||||||
|
"KFC",
|
||||||
|
"Kristofers",
|
||||||
|
"Solo",
|
||||||
|
"Kristofers Solo",
|
||||||
|
"Salaspils 1",
|
||||||
|
"Šis puisis",
|
||||||
|
]
|
||||||
|
|
||||||
DISPLAY_NAME.addEventListener("click", () => {
|
DISPLAY_NAME.addEventListener("click", () => {
|
||||||
const NAMES = ["Kristofers Solo", "Kristiāns Francis Cagulis"]
|
DISPLAY_NAME.innerHTML = NAMES[Math.floor(Math.random() * NAMES.length)]
|
||||||
if (DISPLAY_NAME.innerHTML == NAMES[0]) {
|
|
||||||
DISPLAY_NAME.innerHTML = NAMES[1]
|
|
||||||
} else {
|
|
||||||
DISPLAY_NAME.innerHTML = NAMES[0]
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user