mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-22 14:41:29 +01:00
Et2VfsSelectButton: Fix slotted custom dialog did not actually work
This commit is contained in:
parent
e3272db8d4
commit
f4466a01b4
@ -78,7 +78,11 @@ export class Et2VfsSelectButton extends Et2InputWidget(LitElement)
|
|||||||
protected readonly hasSlotController = new HasSlotController(this, '');
|
protected readonly hasSlotController = new HasSlotController(this, '');
|
||||||
protected processingPromise : Promise<FileActionResult> = null;
|
protected processingPromise : Promise<FileActionResult> = null;
|
||||||
|
|
||||||
get _dialog() : Et2VfsSelectDialog {return this.shadowRoot.querySelector("et2-vfs-select-dialog") ?? null};
|
get _dialog() : Et2VfsSelectDialog
|
||||||
|
{
|
||||||
|
return this.hasSlotController.test("[default]") ? <Et2VfsSelectDialog><unknown>this.querySelector("*") :
|
||||||
|
<Et2VfsSelectDialog><unknown>this.shadowRoot.querySelector("et2-vfs-select-dialog") ?? null
|
||||||
|
};
|
||||||
|
|
||||||
constructor()
|
constructor()
|
||||||
{
|
{
|
||||||
@ -217,7 +221,8 @@ export class Et2VfsSelectButton extends Et2InputWidget(LitElement)
|
|||||||
${processing ? html`
|
${processing ? html`
|
||||||
<sl-spinner></sl-spinner>` : nothing}
|
<sl-spinner></sl-spinner>` : nothing}
|
||||||
</et2-button>
|
</et2-button>
|
||||||
${hasUserDialog ? nothing : this.dialogTemplate()}
|
${hasUserDialog ? html`
|
||||||
|
<slot></slot>` : this.dialogTemplate()}
|
||||||
`;
|
`;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user