From 3f01ac4ccb48480d49b479bf3f51ffd369fb9af8 Mon Sep 17 00:00:00 2001 From: caishi <1149225589@qq.com> Date: Thu, 25 Mar 2021 14:36:57 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AE=B8=E5=8F=AF=E8=AF=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/App.js | 82 +++++++---------------------------- src/mulan/HOC/Footer.jsx | 8 ++++ src/mulan/HOC/Header.jsx | 15 +++++++ src/mulan/HOC/Index.jsx | 18 ++++++++ src/mulan/HOC/Index.scss | 31 +++++++++++++ src/mulan/Index.jsx | 23 ++++++++++ src/mulan/license/Index.jsx | 41 ++++++++++++++++++ src/mulan/license/Index.scss | 21 +++++++++ src/mulan/license/Preface.jsx | 9 ++++ 9 files changed, 182 insertions(+), 66 deletions(-) create mode 100644 src/mulan/HOC/Footer.jsx create mode 100644 src/mulan/HOC/Header.jsx create mode 100644 src/mulan/HOC/Index.jsx create mode 100644 src/mulan/HOC/Index.scss create mode 100644 src/mulan/Index.jsx create mode 100644 src/mulan/license/Index.jsx create mode 100644 src/mulan/license/Index.scss create mode 100644 src/mulan/license/Preface.jsx diff --git a/src/App.js b/src/App.js index 789c0af2f..5dad6fc75 100644 --- a/src/App.js +++ b/src/App.js @@ -35,14 +35,14 @@ const theme = createMuiTheme({ secondary: { main: '#4CACFF' }, // #11cb5f This is just green.A700 as hex. }, }); -//forge项目 -const Projects = Loadable({ - loader: () => import('./forge/Index'), +//首页 +const Index = Loadable({ + loader: () => import('./mulan/Index'), loading: Loading, }) -//forge项目-devOps详情 -const OpsDetail = Loadable({ - loader: () => import('./forge/DevOps/opsDetail'), +//首页 +const License = Loadable({ + loader: () => import('./mulan/license/Index'), loading: Loading, }) //403页面 @@ -61,20 +61,6 @@ const http500 = Loadable({ loader: () => import('./modules/500/http500'), loading: Loading, }) -const InfosIndex = Loadable({ - loader: () => import('./forge/users/Index'), - loading: Loading, -}) -// 组织 -const OrganizeIndex = Loadable({ - loader: () => import('./forge/Team/Index'), - loading: Loading, -}) -const EducoderLogin = Loadable({ - loader: () => import('./modules/login/EducoderLogin'), - loading: Loading, -}) - class App extends Component { constructor(props) { super(props); @@ -214,60 +200,24 @@ class App extends Component { this.Modifyloginvalue()}> - {/*项目*/} - { - return () - } - }> - - {/*项目*/} - { - return () - } - }> - - { - return () - } - } - /> - {/*403*/} - - { - return () - } - }> - - {/*404*/} - {/* 个人主页 */} - { - return () - } - }> - ( - + + ) + } + /> + ( + ) } /> - diff --git a/src/mulan/HOC/Footer.jsx b/src/mulan/HOC/Footer.jsx new file mode 100644 index 000000000..8f981b176 --- /dev/null +++ b/src/mulan/HOC/Footer.jsx @@ -0,0 +1,8 @@ +import React from 'react'; + +function Footer(props){ + return( +
ddd
+ ) +} +export default Footer; \ No newline at end of file diff --git a/src/mulan/HOC/Header.jsx b/src/mulan/HOC/Header.jsx new file mode 100644 index 000000000..3a4b2b8f1 --- /dev/null +++ b/src/mulan/HOC/Header.jsx @@ -0,0 +1,15 @@ +import React from 'react'; + +function Header(props){ + return( +
+
+ +
+
+ ) +} +export default Header; \ No newline at end of file diff --git a/src/mulan/HOC/Index.jsx b/src/mulan/HOC/Index.jsx new file mode 100644 index 000000000..6f05a4187 --- /dev/null +++ b/src/mulan/HOC/Index.jsx @@ -0,0 +1,18 @@ +import React, { Component } from 'react'; +import Header from './Header'; +import Footer from './Footer'; +import './Index.scss'; + +export function HOC(Sub){ + return class II extends Component { + render(){ + return( +
+
+
+
+ ) + } + } +} \ No newline at end of file diff --git a/src/mulan/HOC/Index.scss b/src/mulan/HOC/Index.scss new file mode 100644 index 000000000..de4406df0 --- /dev/null +++ b/src/mulan/HOC/Index.scss @@ -0,0 +1,31 @@ +.headsnav{ + position: fixed; + width: 100%; + left: 0px; + top:0px; + height: 60px; + line-height: 60px; + box-shadow: 0px 0px 10px rgba(0,0,0,0.1); + & > div{ + width:1200px; + margin: 0px auto; + ul{ + display: flex; + height: 100%; + li{ + padding:0px 18px; + height: 100%; + font-size: 16px; + } + } + } +} +.homebody{ + padding-top: 60px; +} +.footsnav{ + position: absolute; + width: 100%; + bottom: 0px; + left: 0px; +} \ No newline at end of file diff --git a/src/mulan/Index.jsx b/src/mulan/Index.jsx new file mode 100644 index 000000000..82aada544 --- /dev/null +++ b/src/mulan/Index.jsx @@ -0,0 +1,23 @@ +import React from 'react'; +import { HOC } from './HOC/Index'; +import {Route,Switch} from 'react-router-dom'; +import Loadable from 'react-loadable'; +import Loading from '../Loading'; + +const LicenseIndex = Loadable({ + loader: () => import('./license/Index'), + loading: Loading, +}) +function Index(props){ + return( + + ( + + )} + > + + ) +} +export default HOC(Index); \ No newline at end of file diff --git a/src/mulan/license/Index.jsx b/src/mulan/license/Index.jsx new file mode 100644 index 000000000..13427effd --- /dev/null +++ b/src/mulan/license/Index.jsx @@ -0,0 +1,41 @@ +import React from 'react'; +import { HOC } from '../HOC/Index'; +import {Route, Switch , Link } from 'react-router-dom'; +import Loadable from 'react-loadable'; +import Loading from '../../Loading'; +import { Box , Long , Short , Gap } from '../../forge/Component/layout'; +import './Index.scss'; + +const Preface = Loadable({ + loader: () => import('./Preface'), + loading: Loading, +}) +function Index(props){ + return( +
+ + +
    +
  • 序言
  • +
  • 木兰宽松许可证
  • +
  • 木兰公共许可证
  • +
  • 常见问题
  • +
+
+ + + + ( + + )} + > + + + +
+
+ ) +} +export default HOC(Index); \ No newline at end of file diff --git a/src/mulan/license/Index.scss b/src/mulan/license/Index.scss new file mode 100644 index 000000000..7801d0b09 --- /dev/null +++ b/src/mulan/license/Index.scss @@ -0,0 +1,21 @@ +.panelsBox{ + width: 1200px; + margin: 20px auto; + .leftmenus{ + box-shadow: 0px 0px 10px rgba(0,0,0,0.1); + li{ + height: 48px; + line-height: 48px; + border-bottom: 1px solid #eee; + &:last-child{ + border: none; + } + a{ + display: block; + padding:0px 20px; + font-size:16px; + color:#333; + } + } + } +} \ No newline at end of file diff --git a/src/mulan/license/Preface.jsx b/src/mulan/license/Preface.jsx new file mode 100644 index 000000000..a8f050ddd --- /dev/null +++ b/src/mulan/license/Preface.jsx @@ -0,0 +1,9 @@ +import React from 'react'; + + +function Preface(props){ + return( +
序言
+ ) +} +export default Preface; \ No newline at end of file