From 419bfd0fd1790e92d7b40419ca2b15b7e93e5e43 Mon Sep 17 00:00:00 2001 From: kaitlynkittyy Date: Mon, 8 Apr 2024 23:40:24 -0400 Subject: [PATCH] begin reworking screenshare modal to properly fit all elements --- src/renderer/components/ScreenSharePicker.tsx | 211 ++++++++++-------- src/renderer/components/screenSharePicker.css | 17 +- 2 files changed, 128 insertions(+), 100 deletions(-) diff --git a/src/renderer/components/ScreenSharePicker.tsx b/src/renderer/components/ScreenSharePicker.tsx index 9a9cc90..6130747 100644 --- a/src/renderer/components/ScreenSharePicker.tsx +++ b/src/renderer/components/ScreenSharePicker.tsx @@ -183,106 +183,117 @@ function StreamSettings({ ); // the source's name is not properly being displayed return ( -
- What you're streaming - - - {source.name} - +
+
+ What you're streaming + + + {source.name} + +
+
+ Stream Settings + +
+
+ Resolution +
+ {StreamResolutions.map(res => ( + + ))} +
+
- Stream Settings - - -
-
- Resolution -
- {StreamResolutions.map(res => ( - - ))} -
-
- -
- Frame Rate -
- {StreamFps.map(fps => ( - - ))} -
-
-
-
- Content Type -
-
- - -
-
-

- Choosing "Prefer Clarity" will result in a significantly lower framerate in exchange for - a much sharper and clearer image. -

-
+
+ Frame Rate +
+ {StreamFps.map(fps => ( + + ))} +
+
-
- {isWindows && ( - setSettings(s => ({ ...s, audio: checked }))} - hideBorder - className="vcd-screen-picker-audio" - > - Stream With Audio - - )} +
+ Content Type +
+
+ + +
+
+

+ Choosing "Prefer Clarity" will result in a significantly lower framerate in exchange + for a much sharper and clearer image. +

+
+
+
+ {isWindows && ( + setSettings(s => ({ ...s, audio: checked }))} + hideBorder + className="vcd-screen-picker-audio" + > + Stream With Audio + + )} - {isLinux && ( - setSettings(s => ({ ...s, audioSource: source }))} - setWorkaround={workaround => setSettings(s => ({ ...s, workaround: workaround }))} - /> - )} -
+ {isLinux && ( + setSettings(s => ({ ...s, audioSource: source }))} + setWorkaround={workaround => setSettings(s => ({ ...s, workaround: workaround }))} + /> + )} + +
); } @@ -370,9 +381,13 @@ function ModalComponent({ contentHint: "motion", audio: true }); + const newModalProps = { + ...modalProps, + size: "large" + }; return ( - + ScreenShare diff --git a/src/renderer/components/screenSharePicker.css b/src/renderer/components/screenSharePicker.css index f828e54..6c78139 100644 --- a/src/renderer/components/screenSharePicker.css +++ b/src/renderer/components/screenSharePicker.css @@ -1,3 +1,13 @@ +.vcd-screen-picker { + display: flex; + flex-direction: row; +} + +.vcd-screen-picker-content { + margin: 1em; + align-self: center; +} + .vcd-screen-picker-modal { padding: 1em; } @@ -125,7 +135,10 @@ .vcd-screen-picker-hint-description { font-size: 14px; - color: var(--header-secondary); + color: var(--text-normal); width: 100%; - + font-weight: 400; +} +.vcd-screen-picker-hints { + white-space: nowrap; } \ No newline at end of file