Currently, I'm utilizing the code below (not my original) in order to load an image into a css element (referred to as cell) and showcase an activity indicator.
var cell = document.createElement('li');
cell.textContent = this.labelForIndex(index);
var indicator = new NKActivityIndicator();
indicator.init(10,100,20,"white");
indicator.show();
indicator.spin();
$(cell).css("background-image", "url("+iconImage+")");
I am now seeking assistance on how to position the indicator in the center of the cell. The line of code
indicator.init(10,100,20,"white");
specifies the position, width, and color of the indicator. I wish to center it within the cell. Any suggestions?