Closed hugo13122000 closed 4 years ago
https://ibb.co/GcwLXmT (image of the error showing up)
I did some research on the web although I don't code JS, a stack overflow thread allowed me to add a line fixing the error :
i just added after line 71 :
if (elem === null) return;
function get_column_color(col_num) {
let css_class_name = '.syntax--rainbow' + (col_num % num_rainbow_colors + 1);
let elem = document.querySelector(css_class_name);
if (elem === null)
return;
let style = getComputedStyle(elem);
return style.color;
}
it is now working properly
EDIT : The error was linked to adding coma when there's no header yet however, this fix allows you to do so without getting an error
Oops... Thanks, @hugo13122000 . I made a similar quick fix which should prevent the error. I will try to find the root cause later.
Hello there, I get a big red error box whenever I try to add a coma on my csv file :
CSV file
nom, email Hugo B, x Marie, x Hugo T, x Solen, x Coralie, x Léa, x Gauvain, x Camille, x impair, x
when it happens
Client info
Atom: 1.41.0 x64 Electron: 4.2.7 OS: Microsoft Windows 10 Pro Thrown From: rainbow-csv package 0.4.1
Stack Trace
Uncaught TypeError: Failed to execute 'getComputedStyle' on 'Window': parameter 1 is not of type 'Element'.
Commands
Non-Core Packages