extracted closeNav function to Utils
This commit is contained in:
@@ -2,6 +2,12 @@ export const setTitle = (title) => {
|
||||
document.title = `${title} | csgoWTF`
|
||||
}
|
||||
|
||||
export const closeNav = (navSelector) => {
|
||||
const nav = document.querySelector(navSelector)
|
||||
if (nav.classList.contains('show'))
|
||||
nav.classList.remove('show')
|
||||
}
|
||||
|
||||
export const GetWinLoss = (matchResult, teamId) => {
|
||||
if (matchResult === teamId) {
|
||||
return 'win'
|
||||
|
Reference in New Issue
Block a user