From e4719c56a79fb6aa443e32da799bd77b5ed14e8d Mon Sep 17 00:00:00 2001 From: Ed Sanders Date: Fri, 20 Nov 2015 18:03:06 -0800 Subject: [PATCH] SVG/CSS generator: Ignore duplicates and 'notWorking' buttons Change-Id: I5f0c9fc62a1e434576550e142d6b25f329e63e7f --- modules/ve-math/tools/makeSvgsAndCss.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/modules/ve-math/tools/makeSvgsAndCss.js b/modules/ve-math/tools/makeSvgsAndCss.js index 76b2a78..ba2e8ac 100755 --- a/modules/ve-math/tools/makeSvgsAndCss.js +++ b/modules/ve-math/tools/makeSvgsAndCss.js @@ -3,7 +3,7 @@ /* jshint node: true */ ( function () { - var i, count, group, symbols, symbolObject, + var i, count, group, symbol, symbols, symbolObject, symbolsData, cssData, cssLines, index, cssRules = [], cssClasses = [], @@ -135,9 +135,13 @@ for ( group in symbolObject ) { symbols = symbolObject[ group ]; for ( i = 0; i < symbols.length; i++ ) { - index = cssClasses.indexOf( texToClass( symbols[ i ].tex ) ); + symbol = symbols[ i ]; + if ( symbol.duplicate || symbol.notWorking ) { + continue; + } + index = cssClasses.indexOf( texToClass( symbol.tex ) ); if ( index === -1 ) { - symbolList.push( symbols[ i ].tex ); + symbolList.push( symbol.tex ); } else { // Remove CSS classes we found in the symbol list so that // and the end of this loop, cssClasses contains classes