瀏覽代碼

ref(filmstrip): apply filmstrip class to Conference root (#3294)

* ref(filmstrip): apply filmstrip class to Conference root

Instead of apply the layout class to the body, it can be
applied to Conference. This will allow easier switching
between tile filmstrip and horizontal/vertical filmstrip.

* squash: fix typo filstrip
master
virtuacoplenny 7 年之前
父節點
當前提交
39f1958300
沒有連結到貢獻者的電子郵件帳戶。
共有 3 個檔案被更改,包括 24 行新增6 行删除
  1. 1
    1
      css/filmstrip/_vertical_filmstrip.scss
  2. 0
    5
      modules/UI/UI.js
  3. 23
    0
      react/features/conference/components/Conference.web.js

+ 1
- 1
css/filmstrip/_vertical_filmstrip.scss 查看文件

127
 /**
127
 /**
128
  * Override other styles to support vertical filmstrip mode.
128
  * Override other styles to support vertical filmstrip mode.
129
  */
129
  */
130
-.vertical-filmstrip.filmstrip-only {
130
+.filmstrip-only .vertical-filmstrip {
131
     .filmstrip {
131
     .filmstrip {
132
         flex-direction: row-reverse;
132
         flex-direction: row-reverse;
133
     }
133
     }

+ 0
- 5
modules/UI/UI.js 查看文件

320
         SidePanels.init(eventEmitter);
320
         SidePanels.init(eventEmitter);
321
     }
321
     }
322
 
322
 
323
-    const filmstripTypeClassname = interfaceConfig.VERTICAL_FILMSTRIP
324
-        ? 'vertical-filmstrip' : 'horizontal-filmstrip';
325
-
326
-    $('body').addClass(filmstripTypeClassname);
327
-
328
     document.title = interfaceConfig.APP_NAME;
323
     document.title = interfaceConfig.APP_NAME;
329
 };
324
 };
330
 
325
 

+ 23
- 0
react/features/conference/components/Conference.web.js 查看文件

42
     'fullscreenchange'
42
     'fullscreenchange'
43
 ];
43
 ];
44
 
44
 
45
+/**
46
+ * The CSS class to apply to the root element of the conference so CSS can
47
+ * modify the app layout.
48
+ *
49
+ * @private
50
+ * @type {Object}
51
+ */
52
+const LAYOUT_CLASSES = {
53
+    HORIZONTAL_FILMSTRIP: 'horizontal-filmstrip',
54
+    VERTICAL_FILMSTRIP: 'vertical-filmstrip'
55
+};
56
+
45
 /**
57
 /**
46
  * The type of the React {@code Component} props of {@link Conference}.
58
  * The type of the React {@code Component} props of {@link Conference}.
47
  */
59
  */
52
      */
64
      */
53
     _iAmRecorder: boolean,
65
     _iAmRecorder: boolean,
54
 
66
 
67
+    /**
68
+     * The CSS class to apply to the root of {@link Conference} to modify the
69
+     * application layout.
70
+     */
71
+    _layoutModeClassName: string,
72
+
55
     /**
73
     /**
56
      * Conference room name.
74
      * Conference room name.
57
      */
75
      */
162
 
180
 
163
         return (
181
         return (
164
             <div
182
             <div
183
+                className = { this.props._layoutModeClassName }
165
                 id = 'videoconference_page'
184
                 id = 'videoconference_page'
166
                 onMouseMove = { this._onShowToolbar }>
185
                 onMouseMove = { this._onShowToolbar }>
167
                 <Notice />
186
                 <Notice />
253
          */
272
          */
254
         _iAmRecorder: iAmRecorder,
273
         _iAmRecorder: iAmRecorder,
255
 
274
 
275
+        _layoutModeClassName: interfaceConfig.VERTICAL_FILMSTRIP
276
+            ? LAYOUT_CLASSES.VERTICAL_FILMSTRIP
277
+            : LAYOUT_CLASSES.HORIZONTAL_FILMSTRIP,
278
+
256
         /**
279
         /**
257
          * Conference room name.
280
          * Conference room name.
258
          */
281
          */

Loading…
取消
儲存