import * as React from "react"; import { useStaticQuery, graphql } from "gatsby"; import styled from "@emotion/styled"; import { SocialLink } from "../SocialLink"; const ProfileLinksContainer = styled.address` display: flex; flex-direction: row; flex-wrap: wrap; `; export interface SocialLinksQuery { site: { siteMetadata: { social: { name: string; id: string; url: string; }[]; }; }; } export const SocialLinks = ( properties: React.ComponentProps<"section"> ): React.ReactElement => { const { site: { siteMetadata: { social }, }, } = useStaticQuery(graphql` query KeplerSocialLinksQuery { site { siteMetadata { social { name id url } } } } `); return ( {social.map( (platform): React.ReactElement => ( ) )} ); };