ソースを参照

添加了屏幕分享预览器的video元素
将屏幕分享按钮从本地视频区域移除
将屏幕分享按钮添加到屏幕分享区域
确保UI布局合理,功能正常

yourname 7 ヶ月 前
コミット
c3e7e41c16
1 ファイル変更8 行追加6 行削除
  1. 8 6
      client/mobile/pages_classroom.tsx

+ 8 - 6
client/mobile/pages_classroom.tsx

@@ -1199,12 +1199,6 @@ export const ClassroomPage = () => {
                   >
                     {isAudioOn ? '关闭麦克风' : '开启麦克风'}
                   </button>
-                  <button
-                    onClick={toggleScreenShare}
-                    className={`px-3 py-1 rounded-md ${isScreenSharing ? 'bg-red-600' : 'bg-blue-600'} text-white`}
-                  >
-                    {isScreenSharing ? '停止分享' : '分享屏幕'}
-                  </button>
                 </div>
               </div>
             </div>
@@ -1217,6 +1211,14 @@ export const ClassroomPage = () => {
                   muted
                   className="w-full h-48 bg-black hidden"
                 ></video>
+                <div className="absolute bottom-2 right-2">
+                  <button
+                    onClick={toggleScreenShare}
+                    className={`px-3 py-1 rounded-md ${isScreenSharing ? 'bg-red-600' : 'bg-blue-600'} text-white`}
+                  >
+                    {isScreenSharing ? '停止分享' : '分享屏幕'}
+                  </button>
+                </div>
               </div>
             </div>