File tree Expand file tree Collapse file tree 5 files changed +65
-4
lines changed
assets/themes/blockchain/challenges
components/tc-communities/communities/blockchain/ChallengeListing/TopBanner Expand file tree Collapse file tree 5 files changed +65
-4
lines changed Original file line number Diff line number Diff line change
1
+ /**
2
+ * Head banner for challenge listing page in Blockchain community.
3
+ */
4
+
5
+ import Banner from 'components/tc-communities/Banner' ;
6
+ import React from 'react' ;
7
+ import style from './style.scss' ;
8
+
9
+ export default function TopBanner ( ) {
10
+ return (
11
+ < Banner
12
+ title = "Challenges"
13
+ text = "Browse our available challenges and compete."
14
+ theme = { {
15
+ container : style . bannerContainer ,
16
+ content : style . bannerContent ,
17
+ contentInner : style . bannerContentInner ,
18
+ } }
19
+ imageSrc = "/themes/blockchain/challenges/banner.jpg"
20
+ />
21
+ ) ;
22
+ }
Original file line number Diff line number Diff line change
1
+ @import " ~styles/mixins" ;
2
+
3
+ .bannerContainer {
4
+ height : 252px !important ;
5
+
6
+ @include xxs-to-xs {
7
+ height : 300px !important ;
8
+ }
9
+ }
10
+
11
+ .bannerContent {
12
+ bottom : 0 !important ;
13
+ top : 0 !important ;
14
+ transform : none !important ;
15
+ width : 600px !important ;
16
+
17
+ @include xxs-to-xs {
18
+ top : auto !important ;
19
+ width : 100% !important ;
20
+ }
21
+ }
22
+
23
+ .bannerContentInner {
24
+ @include xxs-to-xs {
25
+ padding-bottom : 20px !important ;
26
+ padding-top : 48px !important ;
27
+ }
28
+ }
Original file line number Diff line number Diff line change 2
2
* Routing of Wipro Community.
3
3
*/
4
4
5
+ import ChallengeListingTopBanner from
6
+ 'components/tc-communities/communities/blockchain/ChallengeListing/TopBanner' ;
5
7
import Error404 from 'components/Error404' ;
6
- import Footer from 'components /tc-communities/communities/wipro /Footer' ;
8
+ import Footer from 'containers /tc-communities/Footer' ;
7
9
import Header from 'containers/tc-communities/Header' ;
8
- import Home from 'components/tc-communities/communities/qa /Home' ;
9
- import Learn from 'components/tc-communities/communities/qa /Learn' ;
10
+ import Home from 'components/tc-communities/communities/blockchain /Home' ;
11
+ import Learn from 'components/tc-communities/communities/blockchain /Learn' ;
10
12
import PT from 'prop-types' ;
11
13
import React from 'react' ;
12
14
import { Route , Switch } from 'react-router-dom' ;
@@ -22,7 +24,12 @@ export default function Routes({ base, meta }) {
22
24
< Header pageId = { match . params . pageId || 'home' } />
23
25
< Switch >
24
26
< Route
25
- component = { ( ) => < ChallengeListing meta = { meta } /> }
27
+ component = { ( ) => (
28
+ < div >
29
+ < ChallengeListingTopBanner />
30
+ < ChallengeListing listingOnly meta = { meta } />
31
+ </ div >
32
+ ) }
26
33
exact
27
34
path = { `${ base } /challenges` }
28
35
/>
Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ import { SplitRoute } from 'utils/router';
11
11
12
12
export default function ChallengeListingRoute ( {
13
13
challengesUrl,
14
+ listingOnly,
14
15
meta,
15
16
newChallengeDetails,
16
17
} ) {
@@ -39,6 +40,7 @@ export default function ChallengeListingRoute({
39
40
* should be adopted. */
40
41
hideTcLinksInSidebarFooter = { meta . communityId === 'wipro' }
41
42
43
+ listingOnly = { listingOnly }
42
44
newChallengeDetails = { newChallengeDetails }
43
45
openChallengesInNewTabs = {
44
46
_ . get ( meta , 'challengeListing.openChallengesInNewTabs' )
@@ -55,11 +57,13 @@ export default function ChallengeListingRoute({
55
57
56
58
ChallengeListingRoute . defaultProps = {
57
59
challengesUrl : '/challenges' ,
60
+ listingOnly : false ,
58
61
newChallengeDetails : false ,
59
62
} ;
60
63
61
64
ChallengeListingRoute . propTypes = {
62
65
challengesUrl : PT . string ,
66
+ listingOnly : PT . bool ,
63
67
meta : PT . shape ( {
64
68
challengeListing : PT . shape ( {
65
69
openChallengesInNewTabs : PT . bool ,
You can’t perform that action at this time.
0 commit comments