Skip to content

Commit

Permalink
fix for Solid color scheme not loading #689 special cases
Browse files Browse the repository at this point in the history
  • Loading branch information
okg21 committed Jun 14, 2024
1 parent 6eb70b5 commit efce680
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions app/js/app-cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -1391,8 +1391,13 @@ module.exports = function (chiseInstance) {

var opt = {};
keys.forEach(function(key) {
if (!isNaN(node.data(key)) || key === 'background-image' || (node.data('class') === 'unspecified entity' || node.data('class') === 'perturbing agent')) {
opt[key] = node.data(key);
var value = node.data(key);
var isSpecialClass = node.data('class') === 'unspecified entity' || node.data('class') === 'perturbing agent';

if (isNaN(value) && key !== 'background-image' && !isSpecialClass) {
opt[key] = undefined;
} else {
opt[key] = value;
}
});

Expand Down

0 comments on commit efce680

Please sign in to comment.