diff --git a/kdots/css/kdots.css b/kdots/css/kdots.css index 803cc72b60..44f4295d44 100644 --- a/kdots/css/kdots.css +++ b/kdots/css/kdots.css @@ -667,4 +667,10 @@ div.et2_nextmatch .egwGridView_outer .egwGridView_scrollarea table tr { div.et2_nextmatch .egwGridView_outer .egwGridView_scrollarea table tr.selected { background-color: var(--highlight-background-color); } +div.et2_toolbar .et2_toolbar_actionlist > span { + gap: var(--sl-spacing-small); +} +div.et2_toolbar .et2_toolbar_actionlist > span * { + margin-right: 0px; +} /*** END WIDGETS ***/ diff --git a/kdots/css/kdots.less b/kdots/css/kdots.less index ba649dea6e..1210af191a 100644 --- a/kdots/css/kdots.less +++ b/kdots/css/kdots.less @@ -652,5 +652,13 @@ div.et2_nextmatch { } } +div.et2_toolbar { + .et2_toolbar_actionlist > span { + gap: var(--sl-spacing-small); + * { + margin-right: 0px; + } + } +} /*** END WIDGETS ***/ \ No newline at end of file diff --git a/kdots/js/EgwFrameworkApp.ts b/kdots/js/EgwFrameworkApp.ts index 905a8a055d..205f7a78aa 100644 --- a/kdots/js/EgwFrameworkApp.ts +++ b/kdots/js/EgwFrameworkApp.ts @@ -171,7 +171,7 @@ export class EgwFrameworkApp extends LitElement protected async getUpdateComplete() : Promise { - const result = await super.updateComplete; + const result = await super.getUpdateComplete(); await this.loadingPromise; return result @@ -280,22 +280,22 @@ export class EgwFrameworkApp extends LitElement public showLeft() { - this.showSide("left"); + return this.showSide("left"); } public hideLeft() { - this.hideSide("left"); + return this.hideSide("left"); } public showRight() { - this.showSide("right"); + return this.showSide("right"); } public hideRight() { - this.hideSide("right"); + return this.hideSide("right"); } public async print() @@ -382,6 +382,7 @@ export class EgwFrameworkApp extends LitElement const attribute = `${side}Collapsed`; this[attribute] = false; this[`${side}Splitter`].position = this[`${side}PanelInfo`].preferenceWidth || this[`${side}PanelInfo`].defaultWidth; + return this.updateComplete; } protected hideSide(side : "left" | "right") @@ -391,6 +392,7 @@ export class EgwFrameworkApp extends LitElement this[attribute] = true; this[`${side}Splitter`].position = this[`${side}PanelInfo`].hiddenWidth; this.requestUpdate(attribute, oldValue); + return this.updateComplete; } get egw() @@ -426,9 +428,16 @@ export class EgwFrameworkApp extends LitElement return; } - // Move templates with slots + // Move templates with slots (along with DOMContainer if only one template there to keep it together) const slottedTemplates = etemplate.DOMContainer.querySelectorAll(":scope > [slot]"); - slottedTemplates.forEach(node => {this.appendChild(node);}); + if(slottedTemplates.length == 1 && etemplate.DOMContainer.childElementCount == 1) + { + etemplate.DOMContainer.slot = slottedTemplates[0].slot; + } + else + { + slottedTemplates.forEach(node => {this.appendChild(node);}); + } // Move top level slotted components const slottedWidgets = etemplate.widgetContainer.querySelectorAll(":scope > [slot]")