Skip to content
This repository was archived by the owner on Apr 21, 2026. It is now read-only.

Commit 1f46c6f

Browse files
author
dpatanin
committed
add social buttons in header instead of contact page
1 parent 37fbc08 commit 1f46c6f

9 files changed

Lines changed: 107 additions & 10 deletions

File tree

gatsby-config.js

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,6 @@ module.exports = {
3131
// name: 'Scanner',
3232
// link: '/scanner',
3333
// },
34-
{
35-
name: 'Contact',
36-
// link: '/contact',
37-
link: 'https://www.securecodebox.io/',
38-
},
3934
],
4035
},
4136

src/components/Menu.js

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
import React from 'react';
22
import { graphql, StaticQuery, Link } from 'gatsby';
3+
import { node } from 'prop-types';
34

45
const Menu = (props) => {
56
const { menuLinks } = props.data.site.siteMetadata;
7+
const json = props.data.allFeaturesJson.edges;
68
return (
79
<div id="main-menu" className="main-menu">
810
<ul>
@@ -12,6 +14,11 @@ const Menu = (props) => {
1214
<a href={link.link} target="_blank">{link.name}</a>
1315
</li>
1416
))}
17+
{json.map(edge =>(
18+
<li key={edge.node.title}>
19+
<a href={edge.node.link} target="_blank"><img src={edge.node.image} /></a>
20+
</li>
21+
))}
1522
</ul>
1623
</div>
1724
);
@@ -29,6 +36,17 @@ export default props => (
2936
}
3037
}
3138
}
39+
allFeaturesJson (filter: {tag: {eq: "social"}}){
40+
edges {
41+
node {
42+
id
43+
title
44+
link
45+
image
46+
tag
47+
}
48+
}
49+
}
3250
}
3351
`}
3452
render={data => <Menu data={data} />}

src/data/features.json

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,5 +22,23 @@
2222
"description": "Our Scans can dig deeply into your Network",
2323
"image": "/features/firewall.svg",
2424
"tag": "provision"
25+
},
26+
{
27+
"title": "Github",
28+
"image": "/features/github logo.svg",
29+
"link": "https://github.com/secureCodeBox",
30+
"tag": "social"
31+
},
32+
{
33+
"title": "Twitter",
34+
"image": "/features/twitter logo white.svg",
35+
"link": "https://twitter.com/securecodebox",
36+
"tag": "social"
37+
},
38+
{
39+
"title": "Slack",
40+
"image": "/features/slack-new-logo.svg",
41+
"link": "https://join.slack.com/t/securecodebox/shared_invite/enQtNDU3MTUyOTM0NTMwLTJiNzg3MmU2ZDY2NDFiMGI0Y2FkM2I5Mzc2ZmEzYTcyN2FlN2Y2NDFiZDE5NjAxMjg1M2IxNDViNzE3OTIxMGU",
42+
"tag": "social"
2543
}
2644
]

src/data/social.yaml

Lines changed: 0 additions & 3 deletions
This file was deleted.

src/scss/components/_logo.scss

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
}
88
img {
99
position: relative;
10-
top: 9.72px;
1110
width: 100%;
1211
height: 100%;
1312
}
@@ -26,7 +25,6 @@
2625
}
2726
img {
2827
position: relative;
29-
top: 9.72px;
3028
width: 100%;
3129
height: auto;
3230
}

src/scss/components/_main-menu.scss

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,11 @@
3535
color: #fff;
3636
text-decoration: none;
3737
}
38+
img {
39+
position: relative;
40+
width: 25px;
41+
height: auto;
42+
}
3843
}
3944
}
4045
> li.active {
@@ -48,6 +53,11 @@
4853
transition: all 225ms ease-in 0s;
4954
color: #fff;
5055
}
56+
img {
57+
position: relative;
58+
width: 25px;
59+
height: auto;
60+
}
5161
span {
5262
display: block;
5363
}

static/features/github logo.svg

Lines changed: 59 additions & 0 deletions
Loading

static/features/slack-new-logo.svg

Lines changed: 1 addition & 0 deletions
Loading
Lines changed: 1 addition & 0 deletions
Loading

0 commit comments

Comments
 (0)