mirror of
https://github.com/nextcloud/server.git
synced 2026-06-12 18:21:40 -04:00
Add loading icon on avatar
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
This commit is contained in:
parent
0f235aec1f
commit
a118817a69
2 changed files with 5 additions and 3 deletions
|
|
@ -140,12 +140,13 @@
|
|||
|
||||
// If the new image loads successfully set it.
|
||||
img.onload = function() {
|
||||
$div.show();
|
||||
$div.text('');
|
||||
$div.append(img);
|
||||
$div.clearimageplaceholder();
|
||||
};
|
||||
|
||||
$div.addClass('icon-loading');
|
||||
$div.show();
|
||||
img.width = size;
|
||||
img.height = size;
|
||||
img.src = url;
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
* ownCloud
|
||||
*
|
||||
* @author John Molakvoæ
|
||||
* @copyright 2016 John Molakvoæ <fremulon@protonmail.com>
|
||||
* @copyright 2016-2017 John Molakvoæ <skjnldsv@protonmail.com>
|
||||
* @author Morris Jobke
|
||||
* @copyright 2013 Morris Jobke <morris.jobke@gmail.com>
|
||||
*
|
||||
|
|
@ -47,7 +47,7 @@
|
|||
* <div id="albumart" style="background-color: hsl(123, 90%, 65%); ... ">A</div>
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
* Alternatively, you can use the prototype function to convert your string to hsl colors:
|
||||
*
|
||||
|
|
@ -156,5 +156,6 @@
|
|||
this.css('text-align', '');
|
||||
this.css('line-height', '');
|
||||
this.css('font-size', '');
|
||||
this.removeClass('icon-loading');
|
||||
};
|
||||
}(jQuery));
|
||||
|
|
|
|||
Loading…
Reference in a new issue