mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-24 15:48:55 +01:00
Fix email tags could not be edited inside Et2Email
They could, but the change was ignored for the first tag
This commit is contained in:
parent
197e321905
commit
0dfeae9b16
@ -297,6 +297,7 @@ export class Et2Email extends Et2InputWidget(LitElement) implements SearchMixinI
|
||||
pull: pull,
|
||||
put: !(this.readonly || this.disabled)
|
||||
},
|
||||
// filter: "[isEditing],.et2-no-drag",
|
||||
onEnd: this.handleSortEnd
|
||||
});
|
||||
}
|
||||
@ -905,7 +906,7 @@ export class Et2Email extends Et2InputWidget(LitElement) implements SearchMixinI
|
||||
handleTagChange(event)
|
||||
{
|
||||
// Need to update our value, or it will just redo the tag with the old value
|
||||
if(event.originalValue && this.value.indexOf(event.originalValue))
|
||||
if(event.originalValue && this.value.includes(event.originalValue))
|
||||
{
|
||||
let index = this.value.indexOf(event.originalValue);
|
||||
this.value[index] = event.target.value;
|
||||
|
@ -176,6 +176,7 @@ export class Et2Tag extends Et2Widget(SlTag)
|
||||
<et2-textbox value="${this.value}"
|
||||
@sl-change=${this.handleChange}
|
||||
@blur=${this.stopEdit}
|
||||
@mousedown=${e => e.stopPropagation()}
|
||||
@click=${e => e.stopPropagation()}
|
||||
@keydown=${this.handleKeyDown}
|
||||
></et2-textbox>
|
||||
@ -199,6 +200,7 @@ export class Et2Tag extends Et2Widget(SlTag)
|
||||
}
|
||||
this.getRootNode().host.hide()
|
||||
this.isEditing = true;
|
||||
this.setAttribute("isEditing", "");
|
||||
this.requestUpdate();
|
||||
this.updateComplete.then(() =>
|
||||
{
|
||||
@ -209,6 +211,7 @@ export class Et2Tag extends Et2Widget(SlTag)
|
||||
stopEdit()
|
||||
{
|
||||
this.isEditing = false;
|
||||
this.removeAttribute("isEditing");
|
||||
let event = new Event("change", {
|
||||
bubbles: true
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user