mirror of
https://github.com/vector-im/element-call.git
synced 2026-09-13 21:59:30 +00:00
fix media queries in component based element call.
This commit is contained in:
@@ -68,7 +68,7 @@
|
||||
}
|
||||
|
||||
/* Hide everything but the subtitle in small windows */
|
||||
@media (max-height: 450px) {
|
||||
@container element-call (max-height: 450px) {
|
||||
.bar {
|
||||
display: none;
|
||||
}
|
||||
@@ -166,7 +166,7 @@
|
||||
}
|
||||
|
||||
/* Hide everything but the subtitle in small windows */
|
||||
@media (max-height: 450px) {
|
||||
@container element-call (max-height: 450px) {
|
||||
.bar:has(.subtitle) > header {
|
||||
grid-template-rows: var(--cpd-space-4x) minmax(var(--cpd-space-5x), auto);
|
||||
grid-template-areas: "." "subtitle";
|
||||
|
||||
@@ -107,7 +107,7 @@ Please see LICENSE in the repository root for full details.
|
||||
gap: var(--cpd-space-1-5x);
|
||||
}
|
||||
|
||||
@media (min-width: 800px) {
|
||||
@container element-call (min-width: 800px) {
|
||||
.headerLogo,
|
||||
.leftNav.hideMobile,
|
||||
.rightNav.hideMobile {
|
||||
|
||||
+11
-1
@@ -33,7 +33,8 @@ the app and for the component build. */
|
||||
@import url("@fontsource/inconsolata/700.css");
|
||||
|
||||
@import url("normalize.css/normalize.css") layer(normalize);
|
||||
@import url("@vector-im/compound-design-tokens/assets/web/css/compound-design-tokens.css") layer(compound);
|
||||
@import url("@vector-im/compound-design-tokens/assets/web/css/compound-design-tokens.css")
|
||||
layer(compound);
|
||||
@import url("@vector-im/compound-web/dist/style.css") layer(compound.components);
|
||||
|
||||
:root {
|
||||
@@ -76,6 +77,15 @@ the app and for the component build. */
|
||||
--video-tile-background: var(--cpd-color-bg-subtle-secondary);
|
||||
}
|
||||
|
||||
/* The breakpoints in Element Call's stylesheets are container queries against
|
||||
this element rather than media queries against the viewport. For the standalone
|
||||
app the two are the same thing, since the root is the page; for a host that
|
||||
embeds Element Call in a corner of its own page they are not, and it is the
|
||||
corner that the layout has to fit. */
|
||||
[data-element-call-root] {
|
||||
container: element-call / size;
|
||||
}
|
||||
|
||||
.cpd-theme-dark {
|
||||
--cpd-color-border-accent: var(--cpd-color-green-1100);
|
||||
--stopgap-color-on-solid-accent: var(--cpd-color-text-primary);
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
width: fit-content;
|
||||
}
|
||||
|
||||
@media (max-width: 420px) {
|
||||
@container element-call (max-width: 420px) {
|
||||
.reactionPopupMenu {
|
||||
--reaction-button-padding: 8px;
|
||||
--reaction-button-fontsize: 16px;
|
||||
|
||||
@@ -77,7 +77,7 @@ Please see LICENSE in the repository root for full details.
|
||||
}
|
||||
|
||||
/*First hide the logo*/
|
||||
@media (max-width: 750px) {
|
||||
@container element-call (max-width: 750px) {
|
||||
.logo {
|
||||
display: none;
|
||||
}
|
||||
@@ -94,7 +94,7 @@ Please see LICENSE in the repository root for full details.
|
||||
With the logo hidden >500px is enough space to show overflow, buttons, layout.
|
||||
Once we exceed 500 we hide everything except the buttons.
|
||||
*/
|
||||
@media (max-width: 500px) {
|
||||
@container element-call (max-width: 500px) {
|
||||
.footer {
|
||||
grid-template-areas: "buttons buttons buttons";
|
||||
}
|
||||
@@ -115,27 +115,27 @@ Once we exceed 500 we hide everything except the buttons.
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-height: 800px) {
|
||||
@container element-call (max-height: 800px) {
|
||||
.footer {
|
||||
padding-block: var(--cpd-space-8x)
|
||||
calc(env(safe-area-inset-bottom) + var(--cpd-space-8x));
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-height: 400px) {
|
||||
@container element-call (max-height: 400px) {
|
||||
.footer {
|
||||
padding-block: var(--cpd-space-4x)
|
||||
calc(env(safe-area-inset-bottom) + var(--cpd-space-4x));
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 370px) {
|
||||
@container element-call (max-width: 370px) {
|
||||
.shareScreen {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* PIP custom css */
|
||||
@media (max-height: 400px) {
|
||||
@container element-call (max-height: 400px) {
|
||||
.shareScreen {
|
||||
display: flex;
|
||||
}
|
||||
@@ -148,13 +148,13 @@ Once we exceed 500 we hide everything except the buttons.
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 320px) {
|
||||
@container element-call (max-width: 320px) {
|
||||
.raiseHand {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-width: 800px) {
|
||||
@container element-call (min-width: 800px) {
|
||||
.buttons {
|
||||
gap: var(--cpd-space-4x);
|
||||
}
|
||||
|
||||
@@ -30,7 +30,7 @@ Please see LICENSE in the repository root for full details.
|
||||
block-size: 140px;
|
||||
}
|
||||
|
||||
@media (max-width: 600px) {
|
||||
@container element-call (max-width: 600px) {
|
||||
/* Give the PiP a portrait aspect ratio */
|
||||
.pip[data-size="sm"] {
|
||||
inline-size: 88px;
|
||||
|
||||
@@ -25,7 +25,7 @@ Please see LICENSE in the repository root for full details.
|
||||
var(--content-inset-left);
|
||||
}
|
||||
|
||||
@media (min-width: 600px) {
|
||||
@container element-call (min-width: 600px) {
|
||||
.pip {
|
||||
inline-size: 180px;
|
||||
block-size: 135px;
|
||||
|
||||
@@ -74,7 +74,7 @@ Please see LICENSE in the repository root for full details.
|
||||
margin-bottom: 44px;
|
||||
}
|
||||
|
||||
@media (min-width: 800px) {
|
||||
@container element-call (min-width: 800px) {
|
||||
.logo {
|
||||
display: none;
|
||||
}
|
||||
|
||||
@@ -75,7 +75,7 @@ spotlight tile is maximised and displaying video, apply a gradient background. *
|
||||
background: none;
|
||||
}
|
||||
|
||||
@media (max-width: 320px) {
|
||||
@container element-call (max-width: 320px) {
|
||||
.invite {
|
||||
display: none;
|
||||
}
|
||||
|
||||
@@ -28,13 +28,13 @@ Please see LICENSE in the repository root for full details.
|
||||
color: var(--cpd-color-theme-primary) !important;
|
||||
}
|
||||
|
||||
@media (max-width: 500px) {
|
||||
@container element-call (max-width: 500px) {
|
||||
.join {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-height: 650px) {
|
||||
@container element-call (min-height: 650px) {
|
||||
.content {
|
||||
gap: var(--cpd-space-10x);
|
||||
}
|
||||
|
||||
@@ -71,7 +71,7 @@ video.mirror {
|
||||
);
|
||||
}
|
||||
|
||||
@media (max-width: 550px) {
|
||||
@container element-call (max-width: 550px) {
|
||||
.preview {
|
||||
margin-inline: 0;
|
||||
border-radius: 0;
|
||||
|
||||
Reference in New Issue
Block a user