Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mr-julyedu
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
baiguangyao
mr-julyedu
Commits
62d5e62d
Commit
62d5e62d
authored
Dec 06, 2019
by
xuzhenghua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pull
parent
fdf98450
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
94 additions
and
20 deletions
+94
-20
src/common/closable-popup/index.js
+13
-3
src/common/closable-popup/index.scss
+11
-0
src/components/activity/newyear-2019/box-container/box-container.scss
+32
-0
src/components/activity/newyear-2019/box-container/container.js
+15
-0
src/components/activity/newyear-2019/landing/index.js
+0
-0
src/components/activity/newyear-2019/landing/landing.scss
+0
-0
src/router/index.js
+15
-16
src/router/router-config.js
+8
-1
No files found.
src/common/closable-popup/index.js
View file @
62d5e62d
...
...
@@ -3,9 +3,16 @@ import ReactDOM from 'react-dom'
import
'./index.scss'
import
classnames
from
'classnames'
const
re
=
/
(
https
?
|ftp
)
:
\/\/[
-A-Za-z0-9+&@#
/
%?=~_|!:,.;
]
+
[
-A-Za-z0-9+&@#
/
%=~_|
]
/
function
ClosablePopup
({
title
,
content
,
className
,
closable
=
true
,
close
=
function
()
{
}
title
,
content
,
className
,
closable
=
true
,
close
=
function
()
{
},
closeIcon
=
'iconiconfront-2'
}
=
{})
{
function
unmountComponent
()
{
...
...
@@ -35,7 +42,10 @@ function ClosablePopup({
{
content
}
<
/div
>
{
closable
&&
<
i
className
=
{
'close iconfont iconiconfront-2'
}
onClick
=
{
_close
}
/
>
closable
&&
re
.
test
(
closeIcon
)
?
<
img
src
=
{
closeIcon
}
alt
=
""
className
=
{
'close-icon'
}
onClick
=
{
_close
}
/
>
:
<
i
className
=
{
`close iconfont
${
closeIcon
}
`
}
onClick
=
{
_close
}
/
>
}
<
/div
>
<
/div
>
...
...
src/common/closable-popup/index.scss
View file @
62d5e62d
...
...
@@ -31,5 +31,16 @@
font-size
:
36px
;
color
:
#fff
;
}
.close-icon
{
position
:
absolute
;
bottom
:
-66px
;
left
:
50%
;
width
:
33px
;
height
:
33px
;
transform
:
translateX
(
-50%
);
font-size
:
36px
;
color
:
#fff
;
}
}
}
src/components/activity/newyear-2019/box-container/box-container.scss
0 → 100644
View file @
62d5e62d
.box-container
{
position
:
relative
;
background
:
#327443
;
padding
:
14px
0
;
.image-box
{
height
:
100%
;
background
:
url("https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/PC/sd_nr_bj2.png")
repeat-y
;
background-size
:
100%
auto
;
}
@mixin
common-deco
(
$bg
)
{
content
:
''
;
position
:
absolute
;
left
:
0
;
width
:
100%
;
height
:
14px
;
display
:
block
;
background
:
url($bg)
no-repeat
;
background-size
:
375px
auto
;
}
&
:
:
before
{
@include
common-deco
(
"https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/PC/sd_nr_bj1.png"
);
top
:
0
;
}
&
:
:
after
{
@include
common-deco
(
"https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/PC/sd_nr_bj3.png"
);
bottom
:
0
;
}
}
src/components/activity/newyear-2019/box-container/container.js
0 → 100644
View file @
62d5e62d
import
React
,
{
Component
}
from
'react'
import
'./box-container.scss'
class
Container
extends
Component
{
render
()
{
return
(
<
div
className
=
{
'box-container'
}
>
<
div
className
=
"image-box"
>
{
this
.
props
.
children
}
<
/div
>
<
/div
>
)
}
}
export
default
Container
src/components/activity/newyear-2019/landing/index.js
0 → 100644
View file @
62d5e62d
This diff is collapsed.
Click to expand it.
src/components/activity/newyear-2019/landing/landing.scss
0 → 100644
View file @
62d5e62d
This diff is collapsed.
Click to expand it.
src/router/index.js
View file @
62d5e62d
...
...
@@ -14,18 +14,18 @@ import PrivateRoute from './privateRoute'
// };
export
default
function
()
{
return
(
<
Switch
>
{
RouterConfig
.
map
((
item
,
index
)
=>
{
let
{
isPrivate
,
...
rest
}
=
item
if
(
isPrivate
)
{
return
<
PrivateRoute
{...
rest
}
key
=
{
index
}
/
>
}
else
{
return
(
<
Route
{...
rest
}
key
=
{
index
}
/
>
)
}
})}
<
/Switch
>
)
}
\ No newline at end of file
return
(
<
Switch
>
{
RouterConfig
.
map
((
item
,
index
)
=>
{
let
{
isPrivate
,
...
rest
}
=
item
if
(
isPrivate
)
{
return
<
PrivateRoute
{...
rest
}
key
=
{
index
}
/
>
}
else
{
return
(
<
Route
{...
rest
}
key
=
{
index
}
/
>
)
}
})}
<
/Switch
>
)
}
src/router/router-config.js
View file @
62d5e62d
...
...
@@ -220,10 +220,17 @@ export default [
},
{
path
:
'/activity'
,
exact
:
true
,
component
:
Activity
,
},
{
path
:
'/invite'
,
component
:
Invite
,
}
},
//双旦活动
{
path
:
'/activity/newyear-2019/landing'
,
component
:
loadable
(()
=>
import
(
/* webpackChunkName: 'newyear-2019-landing'*/
'@components/activity/newyear-2019/landing/index'
))
},
]
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment