Can I highlight the background of a cell in a table? Thanks to your sample snippet, I figured out how to do some simple highlighting of a value with a snippet when it is read-only. The below code highlights an integer value when it is greater than zero:
var field = arguments[0], value = arguments[1], display; if (field.mode == 'read') { if (value > 0) { display = '<b>&nbsp&nbsp&nbsp&nbsp' + value + '&nbsp&nbsp&nbsp&nbsp</b>'; } else { display = value; } field.element.append(display); } else if (field.mode == 'edit') { skuid.ui.fieldRenderers.INTEGER.edit(field,value); }
I show this field in a table, and use the snippet as a custom renderer, and it seems to work as expected (yea!): Now I could probably easily add a reference to an image instead of coloring the text to make it even prettier. However, these approaches only work when the field isn’t editable (and I’m not sure if I’m up to building a new editor component). What I’d love is to be able to highlight the entire background of the ce