Skip to content

Commit

Permalink
Correction manuelle des erreurs ESLint
Browse files Browse the repository at this point in the history
  • Loading branch information
Situphen committed Mar 7, 2022
1 parent 4347169 commit ebf8005
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 10 deletions.
12 changes: 5 additions & 7 deletions assets/js/charts.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@
*/
function hsvToRgb(h, s, v) {
let r, g, b
let i
let f, p, q, t

// Make sure our arguments stay in-range
h = Math.max(0, Math.min(360, h))
Expand All @@ -32,11 +30,11 @@
}

h /= 60 // sector 0 to 5
i = Math.floor(h)
f = h - i // factorial part of h
p = v * (1 - s)
q = v * (1 - s * f)
t = v * (1 - s * (1 - f))
const i = Math.floor(h)
const f = h - i // factorial part of h
const p = v * (1 - s)
const q = v * (1 - s * f)
const t = v * (1 - s * (1 - f))

switch (i) {
case 0: r = v; g = t; b = p; break
Expand Down
2 changes: 1 addition & 1 deletion assets/js/editor-new.js
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,7 @@
}

/* global EasyMDE */
var easyMDE = new EasyMDE({
const easyMDE = new EasyMDE({
autoDownloadFontAwesome: false,
element: this,
forceSync: true,
Expand Down
2 changes: 1 addition & 1 deletion assets/js/karma.js
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@
$.fn.karma = function() {
if (this.length !== 1) {
return $(this).map(function(index, elem) {
$(elem).karma()
return $(elem).karma()
})
} else {
let message
Expand Down
2 changes: 1 addition & 1 deletion assets/js/mobile-menu.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
const isAndroidMobile = navU.indexOf('Android') > -1 && navU.indexOf('Mozilla/5.0') > -1 && navU.indexOf('AppleWebKit') > -1

// Android Browser (not Chrome)
const regExAppleWebKit = new RegExp(/AppleWebKit\/([\d.]+)/)
const regExAppleWebKit = /AppleWebKit\/([\d.]+)/
const resultAppleWebKitRegEx = regExAppleWebKit.exec(navU)
const appleWebKitVersion = (resultAppleWebKitRegEx === null ? null : parseFloat(regExAppleWebKit.exec(navU)[1]))
const disableMobileMenu = isAndroidMobile && appleWebKitVersion !== null && appleWebKitVersion < 537
Expand Down

0 comments on commit ebf8005

Please sign in to comment.