multiple spinners with different options?
Closed this issue · 6 comments
sonicparke commented
It seems that once a spinner is started the config options that are passed into that spinner override any other config options that are passed into any additional spinners on the page. Is this a bug or intended behavior or am I just doing something wrong?
Here's a plunker to illustrate: http://plnkr.co/edit/XLK0emyBzDij0pYv6EqO?p=preview
BenMGilman commented
+1
igler commented
+1
igler commented
Changing line 85 in https://github.com/urish/angular-spinner/blob/master/angular-spinner.js to
options = angular.extend({}, usSpinnerConfig.config, usSpinnerConfig.themes[attr.spinnerTheme]);
helped in my scenario where colors got mixed up.
lucaferri commented
+1
I think the problem could be line 90
scope.spinner = new SpinJSSpinner(options);
because every new instance of SpinJs override the previous one.
dorr-fg commented
+1
rich186 commented
+1