mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-08 23:19:04 +01:00
Et2TreeDropdown fixes
- Fix ID / tag could be doubled by selecting the same tree node multiple times - Fix global categories had their marker escaped
This commit is contained in:
parent
5f26b940e3
commit
2bbac91254
@ -353,7 +353,7 @@ export class Et2TreeDropdown extends Et2WidgetWithSelectMixin(LitElement)
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
const id = event?.detail?.selection?.map(i => i.id).pop();
|
const id = event?.detail?.selection?.map(i => i.id).pop();
|
||||||
if(id)
|
if(id && !this.value.includes(id))
|
||||||
{
|
{
|
||||||
// Copy so LitElement knows it changed
|
// Copy so LitElement knows it changed
|
||||||
this.value = [...this.value, id];
|
this.value = [...this.value, id];
|
||||||
@ -468,7 +468,7 @@ export class Et2TreeDropdown extends Et2WidgetWithSelectMixin(LitElement)
|
|||||||
@click=${typeof this.onTagClick == "function" ? (e) => this.onTagClick(e, e.target) : nothing}
|
@click=${typeof this.onTagClick == "function" ? (e) => this.onTagClick(e, e.target) : nothing}
|
||||||
>
|
>
|
||||||
${image ?? nothing}
|
${image ?? nothing}
|
||||||
${option.text.trim()}
|
${(option.label ?? option.text).trim()}
|
||||||
</et2-tag>
|
</et2-tag>
|
||||||
`;
|
`;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user