(cq) replace var with let

This commit is contained in:
Simon Vieille 2022-08-21 15:58:12 +02:00 committed by Gitea
parent 3cf8b685ba
commit eba06e8ef8

View file

@ -2,7 +2,7 @@ const alwaysDisplayed = function() {
const elements = querySelectorAll('*') const elements = querySelectorAll('*')
const fixedElements = [] const fixedElements = []
for (var element of elements) { for (let element of elements) {
if (typeof element !== 'object') { if (typeof element !== 'object') {
continue continue
} }
@ -44,7 +44,7 @@ const alwaysDisplayed = function() {
fixedElements.push(element) fixedElements.push(element)
} }
for (var i in fixedElements) { for (let i in fixedElements) {
const element = fixedElements[i] const element = fixedElements[i]
const computedStyle = window.getComputedStyle(element, null) const computedStyle = window.getComputedStyle(element, null)
const left = computedStyle.getPropertyValue('left') const left = computedStyle.getPropertyValue('left')