mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-22 16:03:47 +01:00
Add new attribute for details widget to overlay the summary container
This commit is contained in:
parent
78ec08fcc4
commit
84a58ec6ae
@ -63,6 +63,11 @@ export class Et2Details extends Et2Widget(SlDetails)
|
||||
max-height: 15em;
|
||||
overflow-y: auto;
|
||||
}
|
||||
.details.hoist .details__body.overlaySummary {
|
||||
top: 0;
|
||||
left: 2em;
|
||||
width: calc(100% - 2em);
|
||||
}
|
||||
`,
|
||||
];
|
||||
}
|
||||
@ -91,6 +96,13 @@ export class Et2Details extends Et2Widget(SlDetails)
|
||||
*/
|
||||
toggleAlign: {
|
||||
type: String
|
||||
},
|
||||
|
||||
/**
|
||||
* Overlay summary container with the details container when in open state
|
||||
*/
|
||||
overlaySummaryOnOpen: {
|
||||
type: Boolean
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -115,6 +127,7 @@ export class Et2Details extends Et2Widget(SlDetails)
|
||||
this.toggleOnHover = false;
|
||||
this.toggleAlign = 'right';
|
||||
this.hoist = false;
|
||||
this.overlaySummaryOnOpen = false;
|
||||
}
|
||||
|
||||
connectedCallback()
|
||||
@ -134,6 +147,10 @@ export class Et2Details extends Et2Widget(SlDetails)
|
||||
{
|
||||
this.shadowRoot.querySelector('.details__summary-icon').style.order = -1;
|
||||
}
|
||||
if (this.overlaySummaryOnOpen)
|
||||
{
|
||||
this.shadowRoot.querySelector('.details__body').classList.add('overlaySummary');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user