mirror of
https://github.com/flarum/framework.git
synced 2025-01-21 13:17:30 +08:00
16 lines
388 B
JavaScript
16 lines
388 B
JavaScript
|
import Component from 'flarum/component';
|
||
|
|
||
|
export default class LoadingIndicator extends Component {
|
||
|
view() {
|
||
|
var size = this.props.size || 'small';
|
||
|
delete this.props.size;
|
||
|
|
||
|
this.props.config = function(element) {
|
||
|
$.fn.spin.presets[size].zIndex = 'auto';
|
||
|
$(element).spin(size);
|
||
|
};
|
||
|
|
||
|
return m('div.loading-indicator', this.props, m.trust(' '));
|
||
|
}
|
||
|
}
|