The documentation for theming (https://www.igniteui.com/help/api/2017.1/ui.ignumericeditor#theming:ui-igedit-negative)
Class applied to the editing element of numeric editor when value is negative. The class is applied only when the editor is in display mode (no focus). Default value is 'ui-igedit-negative'.
seems to suggest that the default class applied to negative numbers can be changed from 'ui-igedit-negative' to something else. Have I misunderstood this? I can't see how to actually change this.
Hi AlistairWood,
Thank you for posting in our forums!
You can access the widget objects through the prototype. Please see the following line as an example:
$.ui.igNumericEditor.prototype.css.negative = "my-own-class";
As long as you call this before any igNumericEditors are created, this should be fine. Please be aware that this will apply to every igNumericEditor.
If you have any further questions or concerns with this, please let me know.
and if I want to change the class for some instances of igNumericEditor and not others ..... how would I do that?
Excellent, just what I needed. I should have thought of that.
There is no way to change this per instance. Why do you need to change the naming of the classes this way?
If you need to target a specific class, you should use more specific CSS instead. e.g.
#profitsMade .ui-igedit-negative { color: red }#resourcesGained .ui-igedit-negative { color: orange }
The first example will change the color to red for the profitsMade editor and to orange for the resourcesGained editor.
If you need further assistance with this, please let me know.