Update design of VideoTileSettingsModal
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
This commit is contained in:
parent
a150619d08
commit
33ef680c41
2 changed files with 20 additions and 6 deletions
|
@ -1,5 +1,16 @@
|
||||||
|
.videoTileSettingsModal {
|
||||||
|
width: 700px;
|
||||||
|
height: 316px;
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
|
||||||
.content {
|
.content {
|
||||||
|
position: relative;
|
||||||
margin: 27px 34px;
|
margin: 27px 34px;
|
||||||
|
height: 100%;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.localVolumePercentage {
|
.localVolumePercentage {
|
||||||
|
|
|
@ -17,10 +17,10 @@ limitations under the License.
|
||||||
import React, { ChangeEvent, useState } from "react";
|
import React, { ChangeEvent, useState } from "react";
|
||||||
import { CallFeed } from "matrix-js-sdk/src/webrtc/callFeed";
|
import { CallFeed } from "matrix-js-sdk/src/webrtc/callFeed";
|
||||||
|
|
||||||
import selectInputStyles from "../input/SelectInput.module.css";
|
|
||||||
import { FieldRow } from "../input/Input";
|
import { FieldRow } from "../input/Input";
|
||||||
import { Modal } from "../Modal";
|
import { Modal } from "../Modal";
|
||||||
import styles from "./VideoTileSettingsModal.module.css";
|
import styles from "./VideoTileSettingsModal.module.css";
|
||||||
|
import { VolumeIcon } from "../button/VolumeIcon";
|
||||||
|
|
||||||
interface LocalVolumeProps {
|
interface LocalVolumeProps {
|
||||||
feed: CallFeed;
|
feed: CallFeed;
|
||||||
|
@ -39,11 +39,8 @@ const LocalVolume: React.FC<LocalVolumeProps> = ({
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<h4 className={selectInputStyles.label}> Local Volume </h4>
|
|
||||||
<FieldRow>
|
<FieldRow>
|
||||||
<span className={styles.localVolumePercentage}>
|
<VolumeIcon volume={localVolume} />
|
||||||
{`${Math.round(localVolume * 100)}%`}
|
|
||||||
</span>
|
|
||||||
<input
|
<input
|
||||||
className={styles.localVolumeSlider}
|
className={styles.localVolumeSlider}
|
||||||
type="range"
|
type="range"
|
||||||
|
@ -65,7 +62,13 @@ interface Props {
|
||||||
|
|
||||||
export const VideoTileSettingsModal = ({ feed, ...rest }: Props) => {
|
export const VideoTileSettingsModal = ({ feed, ...rest }: Props) => {
|
||||||
return (
|
return (
|
||||||
<Modal title="Feed settings" isDismissable mobileFullScreen {...rest}>
|
<Modal
|
||||||
|
className={styles.videoTileSettingsModal}
|
||||||
|
title="Local volume"
|
||||||
|
isDismissable
|
||||||
|
mobileFullScreen
|
||||||
|
{...rest}
|
||||||
|
>
|
||||||
<div className={styles.content}>
|
<div className={styles.content}>
|
||||||
<LocalVolume feed={feed} />
|
<LocalVolume feed={feed} />
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in a new issue