Closed Shine226 closed 4 years ago
I tested on the dataset having a group called "R&D", after clicking the cell for this group, get an error "SyntaxError: The string did not match the expected pattern."
The error occurs on this line code (subgroup: R&D): d3.selectAll('.sel-' + subgroup).transition().style('opacity', 1);
and your solution is to switch &
to _
?
If it's possible, it would be better to escape the characters and display as provided.
Also, before we merge this, find the full disallowed list of characters and be sure to handle all of them
I add more invalid characters to the regular expression and escape those characters. For space ' ', just replace space with ''. These characters will be displayed as provided, only class names for the components will be replaced with '' if there is a space in the name. I pushed the new code.
I see you pushed a solution to this, can you add more detail to how and why it happened so that we can check that the solution is robust?