-
-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement landing and doc page for "Nord Xcode"
This includes the initial sections for features and basic documentation pages. GH-182
- Loading branch information
1 parent
cd00360
commit 6fbeaec
Showing
21 changed files
with
723 additions
and
36 deletions.
There are no files selected for viewing
53 changes: 53 additions & 0 deletions
53
src/components/organisms/page/docs/ports/xcode/SectionContents/SectionContents.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
/* | ||
* Copyright (C) 2018-present Arctic Ice Studio <[email protected]> | ||
* Copyright (C) 2018-present Sven Greb <[email protected]> | ||
* | ||
* Project: Nord Docs | ||
* Repository: https://github.com/arcticicestudio/nord-docs | ||
* License: MIT | ||
*/ | ||
|
||
import React from "react"; | ||
|
||
import { WaveFooter } from "atoms/core/vectors/divider"; | ||
import Section, { Content } from "containers/core/Section"; | ||
import { BookOpen, Zap } from "atoms/core/vectors/icons"; | ||
import { ROUTE_DOCS_PORTS_XCODE } from "config/routes/mappings"; | ||
import { topicsGettingStarted, topicsReferences } from "data/components/organisms/page/docs/ports/xcode/topics"; | ||
import { sectionIdFor } from "utils"; | ||
import { colors } from "styles/theme"; | ||
|
||
import { ContentsCard, CardGrid } from "../../../shared"; | ||
|
||
const SECTION_ID = sectionIdFor(ROUTE_DOCS_PORTS_XCODE, 1); | ||
|
||
/** | ||
* The component that represents the contents section of the docs page for the "Nord Xcode" port project. | ||
* | ||
* @author Arctic Ice Studio <[email protected]> | ||
* @author Sven Greb <[email protected]> | ||
* @since 0.22.0 | ||
*/ | ||
const SectionContents = () => ( | ||
<Section id={SECTION_ID} variant="tertiary"> | ||
<Content centered> | ||
<CardGrid> | ||
<ContentsCard | ||
accentColor={colors.nord8} | ||
logoComponent={Zap} | ||
svgType="stroke" | ||
title="Getting Started" | ||
topics={topicsGettingStarted} | ||
> | ||
Learn how to install and activate the theme. | ||
</ContentsCard> | ||
<ContentsCard accentColor={colors.nord10} logoComponent={BookOpen} title="References" topics={topicsReferences}> | ||
Learn about theme features and how to deal with occurring problems. | ||
</ContentsCard> | ||
</CardGrid> | ||
</Content> | ||
<WaveFooter /> | ||
</Section> | ||
); | ||
|
||
export default SectionContents; |
10 changes: 10 additions & 0 deletions
10
src/components/organisms/page/docs/ports/xcode/SectionContents/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
/* | ||
* Copyright (C) 2018-present Arctic Ice Studio <[email protected]> | ||
* Copyright (C) 2018-present Sven Greb <[email protected]> | ||
* | ||
* Project: Nord Docs | ||
* Repository: https://github.com/arcticicestudio/nord-docs | ||
* License: MIT | ||
*/ | ||
|
||
export { default } from "./SectionContents"; |
39 changes: 39 additions & 0 deletions
39
src/components/organisms/page/docs/ports/xcode/SectionHero/SectionHero.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
/* | ||
* Copyright (C) 2018-present Arctic Ice Studio <[email protected]> | ||
* Copyright (C) 2018-present Sven Greb <[email protected]> | ||
* | ||
* Project: Nord Docs | ||
* Repository: https://github.com/arcticicestudio/nord-docs | ||
* License: MIT | ||
*/ | ||
|
||
import React from "react"; | ||
|
||
import Section, { Content } from "containers/core/Section"; | ||
import { ROUTE_DOCS_PORTS_XCODE } from "config/routes/mappings"; | ||
import { sectionIdFor } from "utils"; | ||
|
||
import { Headline, Subline } from "../../../shared"; | ||
|
||
const SECTION_ID = sectionIdFor(ROUTE_DOCS_PORTS_XCODE, 0); | ||
|
||
/** | ||
* The component that represents the hero section of the docs page for the "Nord Xcode" port project. | ||
* | ||
* @author Arctic Ice Studio <[email protected]> | ||
* @author Sven Greb <[email protected]> | ||
* @since 0.22.0 | ||
*/ | ||
const SectionHero = () => ( | ||
<Section id={SECTION_ID} variant="tertiary"> | ||
<Content centered> | ||
<Headline>Nord Xcode</Headline> | ||
<Subline> | ||
Documentations to get to know the project and supported features, how to use the theme and find solutions for | ||
possible problems. | ||
</Subline> | ||
</Content> | ||
</Section> | ||
); | ||
|
||
export default SectionHero; |
10 changes: 10 additions & 0 deletions
10
src/components/organisms/page/docs/ports/xcode/SectionHero/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
/* | ||
* Copyright (C) 2018-present Arctic Ice Studio <[email protected]> | ||
* Copyright (C) 2018-present Sven Greb <[email protected]> | ||
* | ||
* Project: Nord Docs | ||
* Repository: https://github.com/arcticicestudio/nord-docs | ||
* License: MIT | ||
*/ | ||
|
||
export { default } from "./SectionHero"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
/* | ||
* Copyright (C) 2018-present Arctic Ice Studio <[email protected]> | ||
* Copyright (C) 2018-present Sven Greb <[email protected]> | ||
* | ||
* Project: Nord Docs | ||
* Repository: https://github.com/arcticicestudio/nord-docs | ||
* License: MIT | ||
*/ | ||
|
||
import SectionContents from "./SectionContents"; | ||
import SectionHero from "./SectionHero"; | ||
|
||
export { SectionContents, SectionHero }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,16 +8,20 @@ | |
*/ | ||
|
||
import React from "react"; | ||
import { css } from "styled-components"; | ||
|
||
import { WaveFooter } from "atoms/core/vectors/divider"; | ||
import { P } from "atoms/core/html-elements"; | ||
import Button from "atoms/core/Button"; | ||
import Link from "atoms/core/Link"; | ||
import { Image } from "atoms/core/mdx-elements"; | ||
import Section, { Content } from "containers/core/Section"; | ||
import EmptyState from "molecules/core/EmptyState"; | ||
import FeatureDuo, { Actions, Headline, Subline, Text, Visualization } from "molecules/page/shared/FeatureDuo"; | ||
import { ROUTE_DOCS_PORTS_XCODE, ROUTE_DOCS_PORTS_XCODE_INSTALLATION, ROUTE_PORTS_XCODE } from "config/routes/mappings"; | ||
import { usePortsMetadata } from "hooks"; | ||
import { usePortsAssetsPropTypes } from "hooks/shared/propTypes"; | ||
import { sectionIdFor } from "utils"; | ||
|
||
import { emptyStateIllustrationStyles } from "../../../shared/styles"; | ||
import WaveDivider from "./styled/WaveDivider"; | ||
|
||
const SECTION_ID = sectionIdFor(ROUTE_PORTS_XCODE, 0); | ||
|
||
/** | ||
* The component that represents the hero section for the landing page of the "Nord Xcode" port project. | ||
|
@@ -26,32 +30,51 @@ import { emptyStateIllustrationStyles } from "../../../shared/styles"; | |
* @author Sven Greb <[email protected]> | ||
* @since 0.9.0 | ||
*/ | ||
export default function SectionHero() { | ||
const SectionHero = ({ assets }) => { | ||
const portMetadata = usePortsMetadata(); | ||
const { gitHubRepositoryUrl } = portMetadata.find(port => port.name === "nord-xcode"); | ||
const { gitHubRepositoryUrl, projectUrl } = portMetadata.find(port => port.name === "nord-xcode"); | ||
|
||
return ( | ||
<Section> | ||
<Content centered> | ||
<EmptyState | ||
headline="Oh, there's nothing here yet" | ||
illustrationStyles={emptyStateIllustrationStyles} | ||
illustrationVariant="iglooHemisphere" | ||
subline="Please check back later, we're working hard on this page!" | ||
/> | ||
<P | ||
css={css` | ||
text-align: center; | ||
`} | ||
> | ||
In the meantime, please see the official{" "} | ||
<Link href={gitHubRepositoryUrl} target="_blank" variant="minimal"> | ||
repository on GitHub | ||
</Link>{" "} | ||
for information about Nord Xcode. | ||
</P> | ||
<Section id={SECTION_ID}> | ||
<Content centered decorated> | ||
<FeatureDuo verticalOnly> | ||
<Text verticalOnly> | ||
<Headline large>Nord Xcode</Headline> | ||
<Subline> | ||
An arctic, north-bluish clean and elegant <Link href={projectUrl}>Xcode</Link> color theme. | ||
</Subline> | ||
<Subline>Designed for a fluent and clear workflow.</Subline> | ||
<Actions> | ||
<Button to={ROUTE_DOCS_PORTS_XCODE_INSTALLATION} variant="primary"> | ||
Get Started | ||
</Button> | ||
<Button ghost outlined quiet to={ROUTE_DOCS_PORTS_XCODE} variant="primary"> | ||
Documentation | ||
</Button> | ||
<Button ghost href={gitHubRepositoryUrl} outlined quiet variant="primary"> | ||
GitHub | ||
</Button> | ||
</Actions> | ||
</Text> | ||
<Visualization> | ||
<Image | ||
alt="Screenshot showing the syntax highlighting in the Xcode source code editor" | ||
dropShadow | ||
fluid={assets.images["overview.png"]} | ||
rounded | ||
> | ||
<span> | ||
The syntax highlighting in the <em>Xcode</em> source code editor. | ||
</span> | ||
</Image> | ||
</Visualization> | ||
</FeatureDuo> | ||
</Content> | ||
<WaveFooter /> | ||
<WaveDivider /> | ||
</Section> | ||
); | ||
} | ||
}; | ||
|
||
SectionHero.propTypes = usePortsAssetsPropTypes; | ||
|
||
export default SectionHero; |
32 changes: 32 additions & 0 deletions
32
src/components/organisms/page/ports/xcode/SectionHero/styled/WaveDivider.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/* | ||
* Copyright (C) 2018-present Arctic Ice Studio <[email protected]> | ||
* Copyright (C) 2018-present Sven Greb <[email protected]> | ||
* | ||
* Project: Nord Docs | ||
* Repository: https://github.com/arcticicestudio/nord-docs | ||
* License: MIT | ||
*/ | ||
|
||
import styled from "styled-components"; | ||
|
||
import { WaveSmooth2 } from "atoms/core/vectors/divider"; | ||
import { colors, motion, themedMode, MODE_BRIGHT_SNOW_FLURRY, MODE_DARK_NIGHT_FROST } from "styles/theme"; | ||
|
||
const fillColor = themedMode({ | ||
[MODE_BRIGHT_SNOW_FLURRY]: colors.background.sectioning.secondary[MODE_BRIGHT_SNOW_FLURRY], | ||
[MODE_DARK_NIGHT_FROST]: colors.background.sectioning.secondary[MODE_DARK_NIGHT_FROST] | ||
}); | ||
|
||
/** | ||
* A "smooth" vector wave to render a visual differentiation to the next section. | ||
* | ||
* @author Arctic Ice Studio <[email protected]> | ||
* @author Sven Greb <[email protected]> | ||
* @since 0.22.0 | ||
*/ | ||
const WaveDivider = styled(WaveSmooth2)` | ||
fill: ${fillColor}; | ||
transition: fill ${motion.speed.duration.transition.base.themeModeSwitch}ms ease-in-out; | ||
`; | ||
|
||
export default WaveDivider; |
61 changes: 61 additions & 0 deletions
61
src/components/organisms/page/ports/xcode/SectionSetup/SectionSetup.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
/* | ||
* Copyright (C) 2018-present Arctic Ice Studio <[email protected]> | ||
* Copyright (C) 2018-present Sven Greb <[email protected]> | ||
* | ||
* Project: Nord Docs | ||
* Repository: https://github.com/arcticicestudio/nord-docs | ||
* License: MIT | ||
*/ | ||
|
||
import React from "react"; | ||
|
||
import Button from "atoms/core/Button"; | ||
import { WaveFooter } from "atoms/core/vectors/divider"; | ||
import { Content } from "containers/core/Section"; | ||
import FeatureDuo, { Actions, Headline, Subline, Text } from "molecules/page/shared/FeatureDuo"; | ||
import { ROUTE_DOCS_PORTS_XCODE, ROUTE_PORTS_XCODE } from "config/routes/mappings"; | ||
import { sectionIdFor } from "utils"; | ||
import { usePortsMetadata } from "hooks"; | ||
import { usePortsAssetsPropTypes } from "hooks/shared/propTypes"; | ||
|
||
import { Section } from "../../../shared"; | ||
|
||
const SECTION_ID = sectionIdFor(ROUTE_PORTS_XCODE, 3); | ||
|
||
/** | ||
* The component that represents the setup section for the landing page of the "Nord Xcode" port project. | ||
* | ||
* @author Arctic Ice Studio <[email protected]> | ||
* @author Sven Greb <[email protected]> | ||
* @since 0.22.0 | ||
*/ | ||
const SectionSetup = () => { | ||
const portMetadata = usePortsMetadata(); | ||
const { gitHubRepositoryUrl } = portMetadata.find(port => port.name === "nord-xcode"); | ||
|
||
return ( | ||
<Section id={SECTION_ID} variant="secondary"> | ||
<Content centered decorated> | ||
<FeatureDuo verticalOnly> | ||
<Text verticalOnly> | ||
<Headline>Installation in some lines of code.</Headline> | ||
<Subline>Download and install Nord Xcode with a few commands.</Subline> | ||
<Actions> | ||
<Button to={ROUTE_DOCS_PORTS_XCODE} variant="primary"> | ||
Get Started | ||
</Button> | ||
<Button ghost href={gitHubRepositoryUrl} outlined quiet variant="primary"> | ||
GitHub | ||
</Button> | ||
</Actions> | ||
</Text> | ||
</FeatureDuo> | ||
</Content> | ||
<WaveFooter /> | ||
</Section> | ||
); | ||
}; | ||
|
||
SectionSetup.propTypes = usePortsAssetsPropTypes; | ||
|
||
export default SectionSetup; |
10 changes: 10 additions & 0 deletions
10
src/components/organisms/page/ports/xcode/SectionSetup/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
/* | ||
* Copyright (C) 2018-present Arctic Ice Studio <[email protected]> | ||
* Copyright (C) 2018-present Sven Greb <[email protected]> | ||
* | ||
* Project: Nord Docs | ||
* Repository: https://github.com/arcticicestudio/nord-docs | ||
* License: MIT | ||
*/ | ||
|
||
export { default } from "./SectionSetup"; |
32 changes: 32 additions & 0 deletions
32
src/components/organisms/page/ports/xcode/SectionSetup/styled/WaveDivider.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/* | ||
* Copyright (C) 2018-present Arctic Ice Studio <[email protected]> | ||
* Copyright (C) 2018-present Sven Greb <[email protected]> | ||
* | ||
* Project: Nord Docs | ||
* Repository: https://github.com/arcticicestudio/nord-docs | ||
* License: MIT | ||
*/ | ||
|
||
import styled from "styled-components"; | ||
|
||
import { WaveSmooth2 } from "atoms/core/vectors/divider"; | ||
import { colors, motion, themedMode, MODE_BRIGHT_SNOW_FLURRY, MODE_DARK_NIGHT_FROST } from "styles/theme"; | ||
|
||
const fillColor = themedMode({ | ||
[MODE_BRIGHT_SNOW_FLURRY]: colors.background.sectioning.secondary[MODE_BRIGHT_SNOW_FLURRY], | ||
[MODE_DARK_NIGHT_FROST]: colors.background.sectioning.secondary[MODE_DARK_NIGHT_FROST] | ||
}); | ||
|
||
/** | ||
* A "smooth" vector wave to render a visual differentiation to the next section. | ||
* | ||
* @author Arctic Ice Studio <[email protected]> | ||
* @author Sven Greb <[email protected]> | ||
* @since 0.22.0 | ||
*/ | ||
const WaveDivider = styled(WaveSmooth2)` | ||
fill: ${fillColor}; | ||
transition: fill ${motion.speed.duration.transition.base.themeModeSwitch}ms ease-in-out; | ||
`; | ||
|
||
export default WaveDivider; |
Oops, something went wrong.