Просмотр исходного кода

-Removed the size specification from the icon component used in the fab.
Renamed "NewPageIcon" to "CreatePageIcon".

oshikishintaro 5 лет назад
Родитель
Сommit
1ba84c6e75

+ 2 - 2
src/client/js/components/Fab.jsx

@@ -6,7 +6,7 @@ import StickyEvents from 'sticky-events';
 
 
 import NavigationContainer from '../services/NavigationContainer';
 import NavigationContainer from '../services/NavigationContainer';
 import { withUnstatedContainers } from './UnstatedUtils';
 import { withUnstatedContainers } from './UnstatedUtils';
-import NewPageIcon from './Icons/NewPageIcon';
+import CreatePageIcon from './Icons/CreatePageIcon';
 import ReturnTopIcon from './Icons/ReturnTopIcon';
 import ReturnTopIcon from './Icons/ReturnTopIcon';
 
 
 const logger = loggerFactory('growi:cli:Fab');
 const logger = loggerFactory('growi:cli:Fab');
@@ -48,7 +48,7 @@ const Fab = (props) => {
           className="btn btn-lg btn-create-page btn-primary rounded-circle p-0 waves-effect waves-light"
           className="btn btn-lg btn-create-page btn-primary rounded-circle p-0 waves-effect waves-light"
           onClick={navigationContainer.openPageCreateModal}
           onClick={navigationContainer.openPageCreateModal}
         >
         >
-          <NewPageIcon />
+          <CreatePageIcon />
         </button>
         </button>
       </div>
       </div>
       <div className={`rounded-circle position-absolute ${animateClasses}`} style={{ bottom: 0, right: 0 }}>
       <div className={`rounded-circle position-absolute ${animateClasses}`} style={{ bottom: 0, right: 0 }}>

+ 2 - 4
src/client/js/components/Icons/NewPageIcon.jsx → src/client/js/components/Icons/CreatePageIcon.jsx

@@ -1,10 +1,8 @@
 import React from 'react';
 import React from 'react';
 
 
-const NewPageIcon = () => (
+const CreatePageIcon = () => (
   <svg
   <svg
     xmlns="http://www.w3.org/2000/svg"
     xmlns="http://www.w3.org/2000/svg"
-    width="27"
-    height="27"
     viewBox="0 0 27 30"
     viewBox="0 0 27 30"
   >
   >
     <path
     <path
@@ -25,4 +23,4 @@ const NewPageIcon = () => (
 );
 );
 
 
 
 
-export default NewPageIcon;
+export default CreatePageIcon;

+ 0 - 2
src/client/js/components/Icons/ReturnTopIcon.jsx

@@ -3,8 +3,6 @@ import React from 'react';
 const ReturnTopIcon = () => (
 const ReturnTopIcon = () => (
   <svg
   <svg
     xmlns="http://www.w3.org/2000/svg"
     xmlns="http://www.w3.org/2000/svg"
-    width="18"
-    height="18"
     viewBox="0 0 23 23"
     viewBox="0 0 23 23"
   >
   >
     <path d="M.41,18.71a.82.82,0,0,0,0,.26.71.71,0,0,0,0,.29.5.5,0,0,0,.16.22.66.66,0,0,0,.51.21.67.67,0,0,0,
     <path d="M.41,18.71a.82.82,0,0,0,0,.26.71.71,0,0,0,0,.29.5.5,0,0,0,.16.22.66.66,0,0,0,.51.21.67.67,0,0,0,

+ 7 - 4
src/client/styles/scss/_layout.scss

@@ -70,6 +70,10 @@ body {
     font-size: 24px;
     font-size: 24px;
 
 
     box-shadow: 2px 3px 6px #0000005d;
     box-shadow: 2px 3px 6px #0000005d;
+    svg {
+      width: 28px;
+      height: 28px;
+    }
   }
   }
 
 
   .btn-scroll-to-top {
   .btn-scroll-to-top {
@@ -77,10 +81,9 @@ body {
     height: 40px;
     height: 40px;
 
 
     opacity: 0.4;
     opacity: 0.4;
-
-    i {
-      display: inline-block;
-      transform: rotate(90deg);
+    svg {
+      width: 18px;
+      height: 18px;
     }
     }
   }
   }
 }
 }