浏览代码

fix(icons): scope white svgs to Icon components

master
Leonard Kim 6 年前
父节点
当前提交
92e7be34e3
共有 2 个文件被更改,包括 6 次插入3 次删除
  1. 1
    1
      css/_base.scss
  2. 5
    2
      react/features/base/icons/components/Icon.js

+ 1
- 1
css/_base.scss 查看文件

33
     }
33
     }
34
 }
34
 }
35
 
35
 
36
-svg {
36
+.jitsi-icon svg {
37
     fill: white;
37
     fill: white;
38
 }
38
 }
39
 
39
 

+ 5
- 2
react/features/base/icons/components/Icon.js 查看文件

11
     /**
11
     /**
12
      * Class name for the web platform, if any.
12
      * Class name for the web platform, if any.
13
      */
13
      */
14
-    className?: string,
14
+    className: string,
15
 
15
 
16
     /**
16
     /**
17
      * Color of the icon (if not provided by the style object).
17
      * Color of the icon (if not provided by the style object).
68
 
68
 
69
     return (
69
     return (
70
         <Container
70
         <Container
71
-            className = { className }
71
+            className = { `jitsi-icon ${className}` }
72
             style = { restStyle }>
72
             style = { restStyle }>
73
             <IconComponent
73
             <IconComponent
74
                 fill = { calculatedColor }
74
                 fill = { calculatedColor }
79
     );
79
     );
80
 }
80
 }
81
 
81
 
82
+Icon.defaultProps = {
83
+    className: ''
84
+};

正在加载...
取消
保存