Bug 587871, loading spinner for add to collection
This commit is contained in:
Родитель
b34b5bdc4d
Коммит
c619a5fd92
|
@ -2830,7 +2830,7 @@ a.outlink:hover {
|
|||
|
||||
|
||||
.addon-favorite.ajax-loading span,
|
||||
.collection-add.ajax-loading span,
|
||||
.collection-add.ajax-loading > span,
|
||||
.widgets a.widget.ajax-loading,
|
||||
.widgets .widget.ajax-loading > a,
|
||||
.widgets > a.widget.ajax-loading:hover,
|
||||
|
|
|
@ -595,10 +595,12 @@ $(document).ready(function () {
|
|||
};
|
||||
|
||||
var handleClick = function(e) {
|
||||
$widget = $(this).closest('.collection-add');
|
||||
$('.collection-add-dropdown').hide();
|
||||
var dropdown = $('.collection-add-dropdown', $(this));
|
||||
dropdown.removeClass("new-collection");
|
||||
var addon_id = $(this).attr('data-addonid');
|
||||
$widget.addClass("ajax-loading");
|
||||
// If anonymous, show login overlay.
|
||||
if (z.anonymous) {
|
||||
dropdown.show();
|
||||
|
@ -607,6 +609,7 @@ $(document).ready(function () {
|
|||
$.get(list_url, {'addon_id': addon_id}, function(data) {
|
||||
dropdown.show();
|
||||
dropdown.html(data);
|
||||
$widget.removeClass("ajax-loading");
|
||||
$("a.outlink", dropdown).click(stopPropagation);
|
||||
}, 'html');
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче