8
8
*/
9
9
10
10
import React from "react" ;
11
- import { css } from "styled-components" ;
12
11
13
- import { WaveFooter } from "atoms/core/vectors/divider" ;
14
- import { P } from "atoms/core/html-elements" ;
12
+ import Button from "atoms/core/Button" ;
15
13
import Link from "atoms/core/Link" ;
16
- import Section , { Content } from "containers/core/Section" ;
17
- import EmptyState from "molecules/core/EmptyState" ;
14
+ import { Code } from "atoms/core/html-elements" ;
15
+ import { Image } from "atoms/core/mdx-elements" ;
16
+ import { Content } from "containers/core/Section" ;
17
+ import FeatureDuo , { Actions , Headline , Subline , Text , Visualization } from "molecules/page/shared/FeatureDuo" ;
18
+ import {
19
+ ROUTE_DOCS_PORTS_DIRCOLORS ,
20
+ ROUTE_DOCS_PORTS_DIRCOLORS_INSTALLATION ,
21
+ ROUTE_PORTS_DIRCOLORS
22
+ } from "config/routes/mappings" ;
23
+ import { usePortsAssetsPropTypes } from "hooks/shared/propTypes" ;
24
+ import { sectionIdFor } from "utils" ;
18
25
import { usePortsMetadata } from "hooks" ;
19
26
20
- import { emptyStateIllustrationStyles } from "../../../shared/styles" ;
27
+ import { Section } from "../../../shared" ;
28
+ import WaveDivider from "./styled/WaveDivider" ;
29
+
30
+ const SECTION_ID = sectionIdFor ( ROUTE_PORTS_DIRCOLORS , 0 ) ;
21
31
22
32
/**
23
33
* The component that represents the hero section for the landing page of the "Nord dircolors" port project.
@@ -26,32 +36,61 @@ import { emptyStateIllustrationStyles } from "../../../shared/styles";
26
36
* @author Sven Greb <[email protected] >
27
37
* @since 0.9.0
28
38
*/
29
- export default function SectionHero ( ) {
39
+ const SectionHero = ( { assets } ) => {
30
40
const portMetadata = usePortsMetadata ( ) ;
31
- const { gitHubRepositoryUrl } = portMetadata . find ( port => port . name === "nord-dircolors" ) ;
41
+ const { gitHubRepositoryUrl, projectUrl } = portMetadata . find ( port => port . name === "nord-dircolors" ) ;
32
42
33
43
return (
34
- < Section >
35
- < Content centered >
36
- < EmptyState
37
- headline = "Oh, there's nothing here yet"
38
- illustrationStyles = { emptyStateIllustrationStyles }
39
- illustrationVariant = "iglooHemisphere"
40
- subline = "Please check back later, we're working hard on this page!"
41
- />
42
- < P
43
- css = { css `
44
- text-align : center;
45
- ` }
46
- >
47
- In the meantime, please see the official{ " " }
48
- < Link href = { gitHubRepositoryUrl } target = "_blank" variant = "minimal" >
49
- repository on GitHub
50
- </ Link > { " " }
51
- for information about Nord dircolors.
52
- </ P >
44
+ < Section id = { SECTION_ID } >
45
+ < Content centered decorated >
46
+ < FeatureDuo verticalOnly >
47
+ < Text verticalOnly >
48
+ < Headline large > Nord dircolors</ Headline >
49
+ < Subline >
50
+ An arctic, north-bluish clean and elegant < Link href = { projectUrl } > dircolors</ Link > theme.
51
+ </ Subline >
52
+ < Subline >
53
+ Sets up colorized output for GNU core utils like{ " " }
54
+ < Link href = "https://en.wikipedia.org/wiki/Ls" >
55
+ < Code > ls</ Code >
56
+ </ Link > { " " }
57
+ and{ " " }
58
+ < Link href = "https://en.wikipedia.org/wiki/Tree_(command)" >
59
+ < Code > tree</ Code >
60
+ </ Link > { " " }
61
+ as well as other modern apps like{ " " }
62
+ < Link href = "https://github.com/sharkdp/fd" >
63
+ < Code > fd</ Code >
64
+ </ Link > { " " }
65
+ that respect the < Code > LS_COLORS</ Code > environment variable.
66
+ </ Subline >
67
+ < Actions >
68
+ < Button to = { ROUTE_DOCS_PORTS_DIRCOLORS_INSTALLATION } variant = "primary" >
69
+ Get Started
70
+ </ Button >
71
+ < Button ghost outlined quiet to = { ROUTE_DOCS_PORTS_DIRCOLORS } variant = "primary" >
72
+ Documentation
73
+ </ Button >
74
+ < Button ghost href = { gitHubRepositoryUrl } outlined quiet variant = "primary" >
75
+ GitHub
76
+ </ Button >
77
+ </ Actions >
78
+ </ Text >
79
+ < Visualization >
80
+ < Image
81
+ alt = "Screenshot showing an overview of various file and node types colorized by Nord"
82
+ dropShadow
83
+ fluid = { assets . images [ "overview.png" ] }
84
+ rounded
85
+ />
86
+ </ Visualization >
87
+ </ FeatureDuo >
53
88
</ Content >
54
- < WaveFooter />
89
+ < WaveDivider />
55
90
</ Section >
56
91
) ;
57
- }
92
+ } ;
93
+
94
+ SectionHero . propTypes = usePortsAssetsPropTypes ;
95
+
96
+ export default SectionHero ;
0 commit comments