mirror of
https://github.com/vector-im/element-call.git
synced 2026-11-07 00:52:28 +00:00
clean up css calc in ts code
This commit is contained in:
@@ -45,8 +45,16 @@ Please see LICENSE in the repository root for full details.
|
||||
so CSS can't size it against the call. */
|
||||
.deviceList {
|
||||
max-block-size: var(--device-list-max-height);
|
||||
/* Keeps a row reached by keyboard clear of the sticky heading. */
|
||||
scroll-padding-block-start: var(--device-list-scroll-padding-start, 0);
|
||||
/* Keeps a row focused by keyboard clear of the sticky heading… */
|
||||
scroll-padding-block-start: var(--device-list-heading-height, 0px);
|
||||
}
|
||||
|
||||
/* …and of the sticky meter and the padding strip beneath it. */
|
||||
.deviceListWithMeter {
|
||||
scroll-padding-block-end: calc(
|
||||
var(--device-list-meter-height, 0px) +
|
||||
var(--cpd-menu-padding-block-end, 0px)
|
||||
);
|
||||
}
|
||||
|
||||
/* Compound's heading rule heads each section; the design adds space below it. */
|
||||
@@ -73,7 +81,7 @@ Please see LICENSE in the repository root for full details.
|
||||
background: var(--cpd-color-bg-canvas-default);
|
||||
}
|
||||
|
||||
/* Fills the band between the meter and the frame, or rows show through it. */
|
||||
/* Fills the padding strip between the audio meter and the frame. Prohibits overlaps. */
|
||||
.stickyMeter::after {
|
||||
content: "";
|
||||
position: absolute;
|
||||
|
||||
@@ -363,14 +363,10 @@ export const MediaMuteAndSwitchButton: FC<MediaMuteAndSwitchButtonProps> = ({
|
||||
{
|
||||
"--device-list-max-height":
|
||||
listMaxHeight === undefined ? undefined : `${listMaxHeight}px`,
|
||||
// A row reached by keyboard stays above the meter and the band its
|
||||
// ground fills.
|
||||
scrollPaddingBlockEnd:
|
||||
meterHeight === undefined
|
||||
? undefined
|
||||
: `calc(${meterHeight}px + var(--cpd-menu-padding-block-end, 0px))`,
|
||||
"--device-list-scroll-padding-start":
|
||||
"--device-list-heading-height":
|
||||
headingHeight === undefined ? undefined : `${headingHeight}px`,
|
||||
"--device-list-meter-height":
|
||||
meterHeight === undefined ? undefined : `${meterHeight}px`,
|
||||
} as CSSProperties
|
||||
}
|
||||
>
|
||||
|
||||
Reference in New Issue
Block a user