mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-03 04:29:28 +01:00
Et2LinkAppSelect: Use configured app link icon instead of always using navbar
This commit is contained in:
parent
62bc77a4d2
commit
e4e0610a41
@ -105,7 +105,7 @@ export class Et2LinkAppSelect extends SlotMixin(Et2Select)
|
||||
super.connectedCallback();
|
||||
|
||||
// Set icon
|
||||
this.querySelector(":scope > [slot='prefix']").setAttribute("src", this.value + "/navbar");
|
||||
this.querySelector(":scope > [slot='prefix']").setAttribute("src", this.egw().link_get_registry(this.value, 'icon') ?? this.value + "/navbar");
|
||||
|
||||
if(!this.value)
|
||||
{
|
||||
@ -176,7 +176,7 @@ export class Et2LinkAppSelect extends SlotMixin(Et2Select)
|
||||
_handleChange(e)
|
||||
{
|
||||
// Set icon
|
||||
this.querySelector(":scope > [slot='prefix']").setAttribute("src", this.value + "/navbar");
|
||||
this.querySelector(":scope > [slot='prefix']").setAttribute("src", this.egw().link_get_registry(this.value, 'icon'));
|
||||
|
||||
// update preference
|
||||
let appname = "";
|
||||
@ -235,7 +235,7 @@ export class Et2LinkAppSelect extends SlotMixin(Et2Select)
|
||||
|
||||
_iconTemplate(appname)
|
||||
{
|
||||
let url = appname ? this.egw().image('navbar', appname) : "";
|
||||
let url = appname ? this.egw().link_get_registry(appname, 'icon') : "";
|
||||
return html`
|
||||
<et2-image style="width: var(--icon-width)" slot="prefix" src="${url}"></et2-image>`;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user