Difference between revisions of "Widget:DCTList"

From LINKS Community Center
Jump to: navigation, search
Line 341: Line 341:
 
                     cssClass: 'functions-cell',
 
                     cssClass: 'functions-cell',
 
                     formatter: function (cell) {
 
                     formatter: function (cell) {
 +
                        const order = Object.keys(fnImages);
 
                         const output = cell.getValue()
 
                         const output = cell.getValue()
                             .sort((a, b) => fnImages.indexOf(a) - fnImages.indexOf(b))
+
                             .sort((a, b) => order.indexOf(a) - order.indexOf(b))
 
                             .map(func => '<img class="func-img" src="' + fnImages[func] +
 
                             .map(func => '<img class="func-img" src="' + fnImages[func] +
 
                                 '" data-value="' + func +
 
                                 '" data-value="' + func +

Revision as of 10:25, 6 September 2022

Development verstion of the DCT List.
Not ready for production!