Etemplate: Fix links with title provided always displayed loading spinner

This commit is contained in:
nathangray 2021-05-10 11:00:41 -06:00
parent 20c464a161
commit dd9352e9c4
2 changed files with 11 additions and 6 deletions

View File

@ -1373,10 +1373,12 @@ var et2_link_string = /** @class */ (function (_super) {
}
e.stopImmediatePropagation();
});
if (_link_data.title)
link.text(_link_data.title);
if (_link_data.title) {
link.text(_link_data.title)
.removeClass("loading");
}
// Now that link is created, get title from server & update
if (!_link_data.title) {
else {
this.egw().link_title(_link_data.app, _link_data.id, function (title) {
if (title)
this.removeClass("loading").text(title);

View File

@ -1694,10 +1694,13 @@ export class et2_link_string extends expose(class et2_link_string extends et2_va
e.stopImmediatePropagation();
});
if(_link_data.title) link.text(_link_data.title);
if(_link_data.title)
{
link.text(_link_data.title)
.removeClass("loading");
}
// Now that link is created, get title from server & update
if(!_link_data.title)
else
{
this.egw().link_title(_link_data.app, _link_data.id, function(title) {
if (title)