diff --git a/src/components/Blockquote.tsx b/src/components/Blockquote.tsx index 36e29c1cdba..c932b153f59 100644 --- a/src/components/Blockquote.tsx +++ b/src/components/Blockquote.tsx @@ -43,14 +43,28 @@ export const BlockquoteWithLogoBottom: FunctionComponent<{ )} {link && (link.href.includes('http') ? ( - + {link.text} ) : ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - +

{link.text}

@@ -105,7 +119,8 @@ export const Blockquote: FunctionComponent<{ {logo && (logo.href ? ( - + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + {logo.alt} @@ -116,7 +131,15 @@ export const Blockquote: FunctionComponent<{ ))} {link && (link?.href.includes('http') ? ( - + {link.text} @@ -125,6 +148,7 @@ export const Blockquote: FunctionComponent<{ {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} {} @@ -11,7 +12,15 @@ export const BlogHeader: FunctionComponent = ({ title, belowTitle, baseUr

{/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - {title} + + {title} +

diff --git a/src/components/Blog/LinkPost.tsx b/src/components/Blog/LinkPost.tsx index 6a2f8d2e66d..f94115be8e9 100644 --- a/src/components/Blog/LinkPost.tsx +++ b/src/components/Blog/LinkPost.tsx @@ -3,6 +3,7 @@ import { FunctionComponent } from 'react' import { MDXRemote } from 'next-mdx-remote' import Link from 'next/link' +import { buttonStyle, buttonLocation } from '@data' import { PostComponentProps } from '@interfaces/posts' interface Props extends PostComponentProps { @@ -24,7 +25,17 @@ export const LinkPost: FunctionComponent = ({ const titleClassName = 'text-base link-post__html d-inline' const title = post.frontmatter.canonical ? (

- {post.frontmatter.title} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + {post.frontmatter.title} + +

) : (

{post.frontmatter.title}

@@ -44,7 +55,15 @@ export const LinkPost: FunctionComponent = ({
{/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - {post.frontmatter.publishDate} + + {post.frontmatter.publishDate} +
diff --git a/src/components/Blog/PodcastListItem.tsx b/src/components/Blog/PodcastListItem.tsx index f030807c0c9..b946e8f4d38 100644 --- a/src/components/Blog/PodcastListItem.tsx +++ b/src/components/Blog/PodcastListItem.tsx @@ -3,6 +3,7 @@ import { FunctionComponent } from 'react' import Link from 'next/link' import { PostListItem, PodcastAudioPlayer } from '@components' +import { buttonStyle, buttonLocation } from '@data' import { PostIndexItemProps } from '@interfaces/posts' /** @@ -45,16 +46,40 @@ export const PodcastListItem: FunctionComponent = ({
{/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - Permalink + + Permalink + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - Show notes + + Show notes + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - Transcript + + Transcript + {frontmatter.videoID && ( = ({ className="text-muted mr-4 font-weight-bold" target="_blank" rel="noreferrer" + title="Watch the video" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > Watch the video diff --git a/src/components/Blog/PostLayout.tsx b/src/components/Blog/PostLayout.tsx index 8b38c396f1d..639bfb63f92 100644 --- a/src/components/Blog/PostLayout.tsx +++ b/src/components/Blog/PostLayout.tsx @@ -3,7 +3,17 @@ import { FunctionComponent } from 'react' import { MDXRemote } from 'next-mdx-remote' import Link from 'next/link' -import { Alert, Blockquote, EmbeddedHubSpot, Figure, TableWrapper, Video, YouTube, TrySourcegraph } from '@components' +import { + Alert, + Blockquote, + EmbeddedHubSpot, + Figure, + TableWrapper, + Video, + YouTube, + TrySourcegraph, +} from '@components' +import { buttonStyle, buttonLocation } from '@data' import { PostComponentProps } from '@interfaces/posts' import { formatDate } from '@util' @@ -32,7 +42,15 @@ export const PostLayout: FunctionComponent = ({ {renderTitleAsLink === true ? ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - {post.frontmatter.title} + + {post.frontmatter.title} + ) : ( post.frontmatter.title @@ -45,11 +63,29 @@ export const PostLayout: FunctionComponent = ({ {a.url ? ( a.url.includes('http') ? ( - + {a.name} ) : ( - {a.name} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + {a.name} + + ) ) : ( a.name diff --git a/src/components/Blog/PostListItem.tsx b/src/components/Blog/PostListItem.tsx index d3f20b7a3fb..9801bcb0ee6 100644 --- a/src/components/Blog/PostListItem.tsx +++ b/src/components/Blog/PostListItem.tsx @@ -3,6 +3,7 @@ import { FunctionComponent } from 'react' import { truncate } from 'lodash' import Link from 'next/link' +import { buttonStyle, buttonLocation } from '@data' import { PostIndexItemProps } from '@interfaces/posts' import { formatDate } from '@util' @@ -24,7 +25,15 @@ export const PostListItem: FunctionComponent = ({ {renderTitleAsLink === true ? ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - {frontmatter.title} + + {frontmatter.title} + ) : ( frontmatter.title @@ -37,11 +46,29 @@ export const PostListItem: FunctionComponent = ({ {a.url ? ( a.url.includes('http') ? ( - + {a.name} ) : ( - {a.name} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + {a.name} + + ) ) : ( a.name @@ -72,7 +99,15 @@ export const PostListItem: FunctionComponent = ({
{/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - Read more + + Read more +
@@ -80,7 +115,12 @@ export const PostListItem: FunctionComponent = ({
{/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - + = ({ href={url} className="release-post__item d-md-flex list-group-item list-group-item-action" key={url} + title={`${category}: ${description}`} + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > {category} @@ -53,21 +58,55 @@ export const ReleasePost: FunctionComponent = ({
- * Please contact Sourcegraph with any licensing questions. + * Please{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + contact Sourcegraph + + {' '} + with any licensing questions.
) @@ -79,7 +118,15 @@ export const ReleasePost: FunctionComponent = ({ {renderTitleAsLink === true ? ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - {post.frontmatter.title} + + {post.frontmatter.title} + ) : ( post.frontmatter.title diff --git a/src/components/BlogResourceItem.tsx b/src/components/BlogResourceItem.tsx index 13c79fc1706..3446a9a954a 100644 --- a/src/components/BlogResourceItem.tsx +++ b/src/components/BlogResourceItem.tsx @@ -1,5 +1,7 @@ import { FunctionComponent } from 'react' +import { buttonStyle, buttonLocation } from '@data' + interface Props { blog: Blog } @@ -20,7 +22,14 @@ interface Blog { export const BlogResourceItem: FunctionComponent = ({ blog }) => (
- +

{blog.title}

{blog.type}

diff --git a/src/components/CaseStudies/CaseStudyCard.tsx b/src/components/CaseStudies/CaseStudyCard.tsx index 17578bdbcb2..432ac7a3bc3 100644 --- a/src/components/CaseStudies/CaseStudyCard.tsx +++ b/src/components/CaseStudies/CaseStudyCard.tsx @@ -4,6 +4,8 @@ import classNames from 'classnames' import ArrowRightIcon from 'mdi-react/ArrowRightIcon' import Link from 'next/link' +import { buttonStyle, buttonLocation } from '@data' + import styles from './CaseStudyCard.module.scss' interface CaseStudy { @@ -122,9 +124,13 @@ export const CaseStudyCard: FunctionComponent<{ study: CaseStudy; bwLogo?: boole {url.includes('http') ? ( {linkText} @@ -132,13 +138,20 @@ export const CaseStudyCard: FunctionComponent<{ study: CaseStudy; bwLogo?: boole ) : ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - + {linkText} )} + .

diff --git a/src/components/CaseStudies/CaseStudyLayout.tsx b/src/components/CaseStudies/CaseStudyLayout.tsx index 88e0745a09e..c31f7cb1145 100644 --- a/src/components/CaseStudies/CaseStudyLayout.tsx +++ b/src/components/CaseStudies/CaseStudyLayout.tsx @@ -3,6 +3,7 @@ import { FunctionComponent } from 'react' import { kebabCase } from 'lodash' import { ContentSection, RequestDemoForm, MediaQuote } from '@components' +import { buttonStyle, buttonLocation } from '@data' import { CaseStudyJumbotron } from './CaseStudyJumbotron' @@ -43,7 +44,14 @@ export const CaseStudyLayout: FunctionComponent = ({ {heroImage && (
@@ -59,7 +67,16 @@ export const CaseStudyLayout: FunctionComponent = ({ )} {quote && !heroImage && } {pdf && ( - + Download PDF diff --git a/src/components/CustomerLogos.tsx b/src/components/CustomerLogos.tsx index 343f8ba551e..f40cb05ed8f 100644 --- a/src/components/CustomerLogos.tsx +++ b/src/components/CustomerLogos.tsx @@ -2,6 +2,8 @@ import { FunctionComponent } from 'react' import Link from 'next/link' +import { buttonStyle, buttonLocation } from '@data' + interface Logo { name: string src: string @@ -75,7 +77,13 @@ export const CustomerLogos: FunctionComponent = () => ( {logos.map((logo: Logo) => ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - + {`${logo.name} { target="_blank" rel="noreferrer" className="btn btn-outline-primary mt-2" + title={`Learn more about ${startCase(feature.productFeature)}`} data-button-style={buttonStyle.outline} data-button-location={buttonLocation.body} data-button-type="cta" @@ -185,9 +186,10 @@ export const FeatureWalkthrough: FunctionComponent = () => { ) : ( + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} { (
    {renderListItems(codeHosts)}
  • - + Have a repository not covered here?
  • @@ -111,7 +119,14 @@ export const IntegrationsSection: FunctionComponent = () => (
      {renderListItems(languages)}
    • - + Need a different language?
    • @@ -124,7 +139,14 @@ export const IntegrationsSection: FunctionComponent = () => (
        {renderListItems(tools)}
      • - + See all integrations or build your own
      • @@ -149,7 +171,14 @@ export const IntegrationsSection: FunctionComponent = () => (
      • - + Learn about deploying Sourcegraph
      • diff --git a/src/components/Layout/Footer.tsx b/src/components/Layout/Footer.tsx index 05a9127ab01..0bda67b7046 100644 --- a/src/components/Layout/Footer.tsx +++ b/src/components/Layout/Footer.tsx @@ -1,13 +1,11 @@ import { FunctionComponent } from 'react' -import DiscordIcon from 'mdi-react/DiscordIcon' -import GithubIcon from 'mdi-react/GithubIcon' -import LinkedinIcon from 'mdi-react/LinkedinIcon' -import SpotifyIcon from 'mdi-react/SpotifyIcon' -import TwitterIcon from 'mdi-react/TwitterIcon' -import YouTubeIcon from 'mdi-react/YoutubeIcon' import Link from 'next/link' +import { buttonStyle, buttonLocation } from '@data' + +import { footerLinks, socialLinks, postscriptLinks } from './navLinks' + interface Props { minimal?: boolean className?: string @@ -18,80 +16,16 @@ const Footer: FunctionComponent = ({ minimal, className }) => (
        {!minimal && (
        -
        -

        About Sourcegraph

        -
          -
        • - Use cases -
        • -
        • - Case studies -
        • -
        • - Pricing -
        • -
        • - Sourcegraph overview -
        • -
        -
        - -
        -

        Resources

        - -
        - -
        -

        Company

        - -
        - -
        + + + {footerLinks.map(section => ( +
        +

        {section.section}

        +
          + {section.items.map(item => ( +
        • + {item.href.includes('http') ? ( + + {item.title} + + ) : ( + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + {item.title} + + + )} +
        • + ))} +
        +
        + ))}
        )} @@ -169,27 +96,23 @@ const Footer: FunctionComponent = ({ minimal, className }) => ( >
        diff --git a/src/components/Layout/Header/DesktopNav.tsx b/src/components/Layout/Header/DesktopNav.tsx index 315bf3d7088..1d45454fc5a 100644 --- a/src/components/Layout/Header/DesktopNav.tsx +++ b/src/components/Layout/Header/DesktopNav.tsx @@ -6,7 +6,7 @@ import NavDropdown from 'react-bootstrap/NavDropdown' import { buttonStyle, buttonLocation } from '@data' -import { NavLink } from './navLinks' +import { NavLink } from '../navLinks' interface Props { navLinks: NavLink[] @@ -20,11 +20,27 @@ const DesktopNav: FunctionComponent = ({ navLinks, hideGetStartedButton } navLink.items.length === 1 ? ( navLink.items.map((item: { href: string; title: string }) => item.href.includes('http') ? ( - + {item.title} ) : ( - + {item.title} ) @@ -38,11 +54,22 @@ const DesktopNav: FunctionComponent = ({ navLinks, hideGetStartedButton } href={item.href} target="_blank" rel="noreferrer" + title={item.title} + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.nav} + data-button-type="cta" > {item.title} ) : ( - + {item.title} ) diff --git a/src/components/Layout/Header/MobileNav.tsx b/src/components/Layout/Header/MobileNav.tsx index b6ded730e9d..700528a7282 100644 --- a/src/components/Layout/Header/MobileNav.tsx +++ b/src/components/Layout/Header/MobileNav.tsx @@ -6,7 +6,7 @@ import Link from 'next/link' import { buttonStyle, buttonLocation } from '@data' -import { NavLink } from './navLinks' +import { NavLink } from '../navLinks' interface Props { navLinks: NavLink[] @@ -29,7 +29,16 @@ const MobileNav: FunctionComponent = ({ navLinks, hideGetStartedButton, i navLink.items.map(item => item.href.includes('http') ? (
      • - + {item.title}
      • @@ -37,7 +46,15 @@ const MobileNav: FunctionComponent = ({ navLinks, hideGetStartedButton, i
      • {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - {item.title} + + {item.title} +
      • ) @@ -76,13 +93,31 @@ const MobileNav: FunctionComponent = ({ navLinks, hideGetStartedButton, i {navLink.items.map(item => item.href.includes('http') ? (
      • - + {item.title}
      • ) : (
      • - {item.title} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + {item.title} + +
      • ) )} @@ -94,6 +129,7 @@ const MobileNav: FunctionComponent = ({ navLinks, hideGetStartedButton, i = ({ navLinks, hideGetStartedButton, i = ({ navLinks, hideGetStartedButton, i {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} = ({ navLinks, hideGetStartedButton, i {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} , + }, + { + title: 'Twitter', + href: 'https://twitter.com/sourcegraph', + icon: , + }, + { + title: 'LinkedIn', + href: 'https://www.linkedin.com/company/4803356/', + icon: , + }, + { + title: 'YouTube', + href: 'https://www.youtube.com/c/Sourcegraph/featured', + icon: , + }, + { + title: 'Discord', + href: 'https://discord.gg/s2qDtYGnAE', + icon: , + }, + { + title: 'Spotify', + href: 'https://open.spotify.com/user/p3ntuomfda8r7czdbsgy36ogk?si=8095204aefc24587', + icon: , + }, + ], +} + +export const postscriptLinks: NavLink = { + section: 'Legal', + items: [ + { + title: 'Terms', + href: '/terms', + }, + { + title: 'Security', + href: '/terms/security', + }, + { + title: 'Privacy', + href: '/terms/privacy', + }, + ], +} diff --git a/src/components/LeadershipSection.tsx b/src/components/LeadershipSection.tsx index 870acd8d131..059350aa311 100644 --- a/src/components/LeadershipSection.tsx +++ b/src/components/LeadershipSection.tsx @@ -4,6 +4,8 @@ import GithubIcon from 'mdi-react/GithubIcon' import LinkedinIcon from 'mdi-react/LinkedinIcon' import TwitterIcon from 'mdi-react/TwitterIcon' +import { buttonStyle, buttonLocation } from '@data' + const LEADERS: { name: string image: string @@ -93,7 +95,13 @@ export const LeadershipSection: FunctionComponent<{ className?: string }> = ({ c
        {LEADERS.map(staff => (
        - + = ({ c />
        - + {staff.name}
        @@ -114,6 +129,10 @@ export const LeadershipSection: FunctionComponent<{ className?: string }> = ({ c rel="nofollow noreferrer" aria-label="GitHub" className="text-dark" + title="Github icon" + data-button-style={buttonStyle.image} + data-button-location={buttonLocation.body} + data-button-type="cta" > @@ -125,6 +144,10 @@ export const LeadershipSection: FunctionComponent<{ className?: string }> = ({ c rel="nofollow noreferrer" aria-label="Twitter" className="text-dark" + title="Twitter icon" + data-button-style={buttonStyle.image} + data-button-location={buttonLocation.body} + data-button-type="cta" > @@ -136,6 +159,10 @@ export const LeadershipSection: FunctionComponent<{ className?: string }> = ({ c rel="nofollow noreferrer" aria-label="LinkedIn" className="text-dark" + title="Linkedin icon" + data-button-style={buttonStyle.image} + data-button-location={buttonLocation.body} + data-button-type="cta" > diff --git a/src/components/Podcast/PodcastSubscribeLinks.tsx b/src/components/Podcast/PodcastSubscribeLinks.tsx index 5c22d9ae084..fe459ebd8fa 100644 --- a/src/components/Podcast/PodcastSubscribeLinks.tsx +++ b/src/components/Podcast/PodcastSubscribeLinks.tsx @@ -2,6 +2,8 @@ import { FunctionComponent } from 'react' import classNames from 'classnames' +import { buttonStyle, buttonLocation } from '@data' + interface Props { linkClassName?: string } @@ -14,6 +16,10 @@ export const PodcastSubscribeLinks: FunctionComponent = ({ linkClassName rel="noreferrer" href="https://www.youtube.com/playlist?list=PL6zLuuRVa1_jf5GDl61SvEOXvwvKS1IXA" className={classNames(linkClassName, 'font-weight-bold')} + title="YouTube" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > YouTube @@ -22,6 +28,10 @@ export const PodcastSubscribeLinks: FunctionComponent = ({ linkClassName rel="noreferrer" href="https://podcasts.apple.com/us/podcast/the-sourcegraph-podcast/id1516219009" className={classNames(linkClassName, 'font-weight-bold')} + title="Apple" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > Apple @@ -30,6 +40,10 @@ export const PodcastSubscribeLinks: FunctionComponent = ({ linkClassName rel="noreferrer" href="https://open.spotify.com/show/1YlDYvCxNB7jAndbZPt5a6" className={classNames(linkClassName, 'font-weight-bold')} + title="Spotify" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > Spotify @@ -38,6 +52,10 @@ export const PodcastSubscribeLinks: FunctionComponent = ({ linkClassName rel="noreferrer" href="https://podcasts.google.com/?feed=aHR0cHM6Ly9mZWVkcy5idXp6c3Byb3V0LmNvbS8xMDk3OTc4LnJzcw==" className={classNames(linkClassName, 'font-weight-bold')} + title="Google" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > Google @@ -46,6 +64,10 @@ export const PodcastSubscribeLinks: FunctionComponent = ({ linkClassName rel="noreferrer" href="https://feeds.buzzsprout.com/1097978.rss" className={classNames(linkClassName, 'font-weight-bold')} + title="RSS" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > RSS diff --git a/src/components/Pricing/PricingPlan.tsx b/src/components/Pricing/PricingPlan.tsx index 619fee5d3e6..86c5e23549e 100644 --- a/src/components/Pricing/PricingPlan.tsx +++ b/src/components/Pricing/PricingPlan.tsx @@ -1,5 +1,7 @@ import { ReactFragment, FunctionComponent } from 'react' +import { buttonStyle, buttonLocation } from '@data' + import { Features, FeatureInfo } from './interfaces' import { PricingPlanFeature } from './PricingPlanFeature' @@ -164,7 +166,15 @@ export const PricingPlan: FunctionComponent = ({ buttonHref, }) => { const button = ( - + {buttonLabel} ) diff --git a/src/components/RequestDemoForm.tsx b/src/components/RequestDemoForm.tsx index 06391a19d24..6d0c0b864e7 100644 --- a/src/components/RequestDemoForm.tsx +++ b/src/components/RequestDemoForm.tsx @@ -1,6 +1,7 @@ import { FunctionComponent } from 'react' import { ContentSection } from '@components' +import { buttonStyle, buttonLocation } from '@data' interface Props { title?: string @@ -17,7 +18,14 @@ export const RequestDemoForm: FunctionComponent = ({

        {title}

        {description}

        - + Schedule a demo
        diff --git a/src/components/RequestDemoTrySourcegraph.tsx b/src/components/RequestDemoTrySourcegraph.tsx index a2e8eb7fff3..b19f5fd10b4 100644 --- a/src/components/RequestDemoTrySourcegraph.tsx +++ b/src/components/RequestDemoTrySourcegraph.tsx @@ -14,26 +14,38 @@ interface Props { export const RequestDemoTrySourcegraph: FunctionComponent = () => ( -
        -

        Get started with Sourcegraph

        -

        Understand, fix, and automate changes across your entire codebase.

        -
        -
        - -
        Schedule a demo
        - - - {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - - Try Sourcegraph now - - - +
        +
        +

        Get started with Sourcegraph

        +

        Understand, fix, and automate changes across your entire codebase.

        +
        +
        + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + +
        Request a demo
        +
        + + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + +

        + Try Sourcegraph now + +

        +
        + +
        ) diff --git a/src/components/SelfHostedSection.tsx b/src/components/SelfHostedSection.tsx index 3b37d018df9..3d83d0ccb9d 100644 --- a/src/components/SelfHostedSection.tsx +++ b/src/components/SelfHostedSection.tsx @@ -38,9 +38,10 @@ export const SelfHostedSection: FunctionComponent = () => (
      + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( = ({ demoFormURL = '/demo'
      {demoFormURL && ( - + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + Schedule a demo )} - + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + Try Sourcegraph now diff --git a/src/components/WhitePaperPage/index.tsx b/src/components/WhitePaperPage/index.tsx index 9b5b767e720..225341f2eb0 100644 --- a/src/components/WhitePaperPage/index.tsx +++ b/src/components/WhitePaperPage/index.tsx @@ -2,6 +2,7 @@ import { FunctionComponent, ReactNode } from 'react' import classNames from 'classnames' +import { buttonStyle, buttonLocation } from '@data' import { TrySourcegraph } from 'components/TrySourcegraph' import styles from './whitePaperPage.module.scss' @@ -27,7 +28,16 @@ export const WhitePaperPage: FunctionComponent = ({ title, className, pdf white paper

      {title}

      {pdf && ( - + Download PDF diff --git a/src/data/tracking.ts b/src/data/tracking.ts index 2eff9b3c7b5..2042d770835 100644 --- a/src/data/tracking.ts +++ b/src/data/tracking.ts @@ -7,6 +7,7 @@ export const buttonStyle = { textWithBoxedArrow: 4, outlineWithArrow: 5, text: 6, + image: 7, } export const buttonLocation = { @@ -15,4 +16,5 @@ export const buttonLocation = { bodyDemo: 3, trySourcegraph: 4, body: 5, + footer: 6, } diff --git a/src/pages/about.tsx b/src/pages/about.tsx index 72d51bdac0d..55f1828a7d9 100644 --- a/src/pages/about.tsx +++ b/src/pages/about.tsx @@ -1,6 +1,7 @@ import { FunctionComponent } from 'react' import { BoardSection, ContentSection, Layout, LeadershipSection } from '@components' +import { buttonStyle, buttonLocation } from '@data' const INVESTORS: { name: string @@ -53,16 +54,64 @@ const About: FunctionComponent = () => (

      Learn all about Sourcegraph

      - The Sourcegraph handbook has everything from our - high-level strategy and{' '} - values, to documentation of - business processes including{' '} - messaging and{' '} - + The{' '} + + Sourcegraph handbook + {' '} + has everything from our high-level{' '} + + strategy + {' '} + and{' '} + + values + + , to documentation of business processes including{' '} + + messaging + {' '} + and{' '} + engineering principles . It's public for everyone to read because we are{' '} - + open and transparent . @@ -72,14 +121,46 @@ const About: FunctionComponent = () => (

      Sourcegraph team

      - Sourcegraph is an all-remote company, - working asynchronously across time zones and continents. Meet our{' '} - team members and learn about our - commitment to{' '} - inclusion + Sourcegraph is an{' '} + + all-remote + {' '} + company, working asynchronously across time zones and continents. Meet our{' '} + + team members + {' '} + and learn about our commitment to{' '} + + inclusion + .

      - + Open roles - we're hiring!
      diff --git a/src/pages/accelerate-dev-onboarding.tsx b/src/pages/accelerate-dev-onboarding.tsx index 658833a359d..9a3ba1d295f 100644 --- a/src/pages/accelerate-dev-onboarding.tsx +++ b/src/pages/accelerate-dev-onboarding.tsx @@ -73,8 +73,10 @@ const AccelerateDevOnboarding: FunctionComponent = () => { {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} Request a demo diff --git a/src/pages/batch-changes.tsx b/src/pages/batch-changes.tsx index 29987ba2008..e1c68cae691 100644 --- a/src/pages/batch-changes.tsx +++ b/src/pages/batch-changes.tsx @@ -90,7 +90,15 @@ export const BatchChangesPage: FunctionComponent = () => (
      • Find all occurrences of code to change with Sourcegraph{' '} - universal code search + + universal code search +
      • Programmatically define changes by creating a declarative specification file diff --git a/src/pages/better-dev-onboarding.tsx b/src/pages/better-dev-onboarding.tsx index c618e52d9d6..ab1b1c5839d 100644 --- a/src/pages/better-dev-onboarding.tsx +++ b/src/pages/better-dev-onboarding.tsx @@ -113,6 +113,7 @@ const BetterDeveloperOnboarding: FunctionComponent = () => { {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} { {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} request a demo diff --git a/src/pages/case-studies/convoy-improved-on-boarding.tsx b/src/pages/case-studies/convoy-improved-on-boarding.tsx index b2316354e28..6fe0a9c10cd 100644 --- a/src/pages/case-studies/convoy-improved-on-boarding.tsx +++ b/src/pages/case-studies/convoy-improved-on-boarding.tsx @@ -1,6 +1,7 @@ import { FunctionComponent } from 'react' import { Layout, CaseStudyLayout, ContentSection, Blockquote } from '@components' +import { buttonStyle, buttonLocation } from '@data' export const CaseStudy: FunctionComponent = () => ( ( For Brandon Bloom, a new hire who was eager to start contributing, using GitHub's native search across Convoy's voluminous repositories rarely gave him the results he needed. His frustration led him to Sourcegraph. As an{' '} - + on-prem and self-hosted product , he could safely and independently set up a Sourcegraph instance locally, and was able to get diff --git a/src/pages/case-studies/indeed-accelerates-development-velocity.tsx b/src/pages/case-studies/indeed-accelerates-development-velocity.tsx index 0852906ad40..7f4a1854907 100644 --- a/src/pages/case-studies/indeed-accelerates-development-velocity.tsx +++ b/src/pages/case-studies/indeed-accelerates-development-velocity.tsx @@ -3,6 +3,7 @@ import { FunctionComponent } from 'react' import Link from 'next/link' import { Layout, CaseStudyLayout, ContentSection, Blockquote } from '@components' +import { buttonStyle, buttonLocation } from '@data' export const CaseStudy: FunctionComponent = () => { const jaredHodge = 'Jared Hodge, Senior Manager, Developer Experience' @@ -85,8 +86,19 @@ export const CaseStudy: FunctionComponent = () => { happened or to even nudge them towards completion. “I actually did a bit of prototyping to see if I could create JIRA issues based on the code searches,” Hodge said, as part of a search for a way to help other team members actually make the changes that need to happen. - When Sourcegraph's Batch Changes came - out, Hodge immediately saw the value in further removing friction by letting one person + When Sourcegraph's{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Batch Changes + + {' '} + came out, Hodge immediately saw the value in further removing friction by letting one person update all versions of a library across the codebase and then notify all the service owners so they could review.

        diff --git a/src/pages/case-studies/nutanix-fixed-log4j-with-sourcegraph.tsx b/src/pages/case-studies/nutanix-fixed-log4j-with-sourcegraph.tsx index cc4401ed5f1..2d18e3799e3 100644 --- a/src/pages/case-studies/nutanix-fixed-log4j-with-sourcegraph.tsx +++ b/src/pages/case-studies/nutanix-fixed-log4j-with-sourcegraph.tsx @@ -12,6 +12,7 @@ import { ThreeUpText, UseChallengeSolutionResults, } from '@components' +import { buttonStyle, buttonLocation } from '@data' const threeUpTextItems = [ { @@ -107,7 +108,15 @@ export const CaseStudy: FunctionComponent = () => ( In December of 2021, software companies around the world discovered that Log4j, an open-source logging library bundled in many software packages, contained significant vulnerabilities, one of which was a{' '} - + 10/10 on the CVSS scale {'. '} @@ -116,6 +125,10 @@ export const CaseStudy: FunctionComponent = () => ( target="_blank" rel="noreferrer" href="https://www.ftc.gov/policy/advocacy-research/tech-at-ftc/2022/01/ftc-warns-companies-remediate-log4j-security-vulnerability" + title="ubiquitous" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > ubiquitous @@ -149,13 +162,27 @@ export const CaseStudy: FunctionComponent = () => ( target="_blank" rel="noreferrer" href="https://logging.apache.org/log4j/1.2/apidocs/org/apache/log4j/net/JMSAppender.html" + title="JMSAppender" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > {' '} JMSAppender . Jon used Sourcegraph to see where JMSAppender existed, fixed it, and sent out a release. “That - took almost less than five minutes,” Jon said. Sourcegraph released a - blog post + took almost less than five minutes,” Jon said. Sourcegraph released a{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + blog post + + {' '} that explained how other companies addressing Log4j could use code search for similar benefits.

        This speed gave the team a head start on mitigation.

        diff --git a/src/pages/case-studies/sofi-moves-fast-on-hundreds-of-microservices.tsx b/src/pages/case-studies/sofi-moves-fast-on-hundreds-of-microservices.tsx index 4562f263058..b669e615c46 100644 --- a/src/pages/case-studies/sofi-moves-fast-on-hundreds-of-microservices.tsx +++ b/src/pages/case-studies/sofi-moves-fast-on-hundreds-of-microservices.tsx @@ -3,6 +3,7 @@ import { FunctionComponent } from 'react' import Link from 'next/link' import { Layout, CaseStudyLayout, ContentSection } from '@components' +import { buttonStyle, buttonLocation } from '@data' export const CaseStudy: FunctionComponent = () => ( ( committed their code changes. The need for fast and accurate code search and cross-repository code navigation led the engineering team to install Sourcegraph. As a FinTech company that contains highly sensitive data from their customers, SoFi emphasizes on security and appreciated - Sourcegraph's on-prem solution. + Sourcegraph's{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + on-prem solution + + + .

        Move fast and don't break things

        diff --git a/src/pages/case-studies/workiva-automates-large-scale-code-changes.tsx b/src/pages/case-studies/workiva-automates-large-scale-code-changes.tsx index 7cf162272b8..5bb28e7b2ec 100644 --- a/src/pages/case-studies/workiva-automates-large-scale-code-changes.tsx +++ b/src/pages/case-studies/workiva-automates-large-scale-code-changes.tsx @@ -3,6 +3,7 @@ import { FunctionComponent } from 'react' import Link from 'next/link' import { Layout, CaseStudyLayout, ContentSection, Blockquote } from '@components' +import { buttonStyle, buttonLocation } from '@data' export const CaseStudy: FunctionComponent = () => { const trentGrover = 'Trent Grover, Director of Architecture, Workiva' @@ -71,9 +72,20 @@ export const CaseStudy: FunctionComponent = () => {

        As an organization that values paying down tech debt, Workiva's Client Platform team started - using Sourcegraph Batch Changes to help them efficiently - propagate updates to dependencies across all of their repositories without any ongoing - maintenance. The team has already used Batch Changes to: + using Sourcegraph{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Batch Changes + + {' '} + to help them efficiently propagate updates to dependencies across all of their repositories + without any ongoing maintenance. The team has already used Batch Changes to:

          diff --git a/src/pages/code-insights.tsx b/src/pages/code-insights.tsx index 6164724e1c2..682945bec92 100644 --- a/src/pages/code-insights.tsx +++ b/src/pages/code-insights.tsx @@ -489,6 +489,9 @@ const CodeInsightsPage: FunctionComponent = () => { className="btn btn-link px-0 py-4 col-7 docs-cta font-weight-bold" href="https://docs.sourcegraph.com/code_insights" title="Code Insights on docs." + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > See Docs for more use cases @@ -527,6 +530,9 @@ const CodeInsightsPage: FunctionComponent = () => { className="btn btn-link px-0 py-4 col-7 docs-cta font-weight-bold" href="https://docs.sourcegraph.com/code_insights" title="Code Insights on docs." + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > See Docs for more use cases diff --git a/src/pages/code-search.tsx b/src/pages/code-search.tsx index a3be8411b38..913fa889f8c 100644 --- a/src/pages/code-search.tsx +++ b/src/pages/code-search.tsx @@ -30,7 +30,7 @@ export const CodeSearchPage: FunctionComponent = () => ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} (
        • Extensible. Connect all your other tools to get things like test coverage, 1-click open file in editor, custom highlighting, and information from your other favorite - services all in one place with - extensions. + services all in one place with{' '} + + extensions + + .
      @@ -162,8 +171,13 @@ export const CodeSearchPage: FunctionComponent = () => (
      {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - - Criteo Tackles Big Code + + Criteo Tackles Big Code
      @@ -192,6 +206,10 @@ export const CodeSearchPage: FunctionComponent = () => ( target="_blank" rel="noreferrer" href="https://sourcegraph.com/search?q=repo:%5Egithub%5C.com/sourcegraph/+f:dockerfile+apt-get%7Capk&patternType=regexp" + title="installing packages in a Dockerfile" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > installing packages in a Dockerfile diff --git a/src/pages/community.tsx b/src/pages/community.tsx index 2166b6b06d6..9f9a608fc01 100644 --- a/src/pages/community.tsx +++ b/src/pages/community.tsx @@ -29,10 +29,10 @@ export const Community: FunctionComponent = () => (

      Join our Discord @@ -53,15 +53,48 @@ export const Community: FunctionComponent = () => (

      Get up to speed

      - We can’t give you a 25-hour day, but here is a speed sheet{' '} + We can’t give you a 25-hour day, but here is a{' '} + + speed sheet + {' '} with the most useful Sourcegraph shortcuts. Need even more speed? Fasten your seat belt and dive - into our curated tutorials & other{' '} - tip documents. + into our curated{' '} + + tutorials + {' '} + & other{' '} + + tip documents + + .

    - + Join us on Discord
@@ -106,7 +146,16 @@ export const Community: FunctionComponent = () => (

@@ -118,8 +167,16 @@ export const Community: FunctionComponent = () => (

Cool hardware. Most-wanted guests. And hot topics. Check our{' '} - YouTube channel and subscribe to - keep up with new episodes. + + YouTube channel + {' '} + and subscribe to keep up with new episodes.

@@ -130,20 +187,55 @@ export const Community: FunctionComponent = () => (

Subscribe:  - + YouTube   - + Apple   - Spotify  - + + Spotify + +   + Google   - RSS + + RSS +

@@ -157,7 +249,17 @@ export const Community: FunctionComponent = () => (

We’d love to hear from you!


Connect with us on the Sourcegraph Community Discord server, direct message us on Twitter, LinkedIn, - or email us at community@sourcegraph.com. + or email us at{' '} + + community@sourcegraph.com + + .
( href="https://github.com/sourcegraph/sourcegraph/issues" target="_blank" rel="noreferrer" + title="File a public issue" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > File a public issue @@ -47,6 +52,10 @@ const ContactHome: FunctionComponent = () => ( href="mailto:support@sourcegraph.com" target="_blank" rel="noreferrer" + title="Email support@sourcegraph.com" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > Email support@sourcegraph.com @@ -60,7 +69,15 @@ const ContactHome: FunctionComponent = () => (

For information about products and purchasing:

{/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - Contact sales + + Contact sales +
@@ -73,6 +90,10 @@ const ContactHome: FunctionComponent = () => ( See career opportunities @@ -88,6 +109,10 @@ const ContactHome: FunctionComponent = () => ( href="mailto:hi@sourcegraph.com" target="_blank" rel="noreferrer" + title="hi@sourcegraph.com" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > hi@sourcegraph.com @@ -96,6 +121,10 @@ const ContactHome: FunctionComponent = () => ( href="https://twitter.com/sourcegraph" target="_blank" rel="noreferrer" + title="@sourcegraph" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > @sourcegraph @@ -104,6 +133,10 @@ const ContactHome: FunctionComponent = () => ( target="_blank" href="https://github.com/sourcegraph" rel="noreferrer" + title="github.com/sourcegraph" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > github.com/sourcegraph @@ -112,6 +145,10 @@ const ContactHome: FunctionComponent = () => ( target="_blank" href="https://www.linkedin.com/company/sourcegraph" rel="noreferrer" + title="Sourcegraph on LinkedIn" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > Sourcegraph on LinkedIn @@ -129,6 +166,10 @@ const ContactHome: FunctionComponent = () => ( target="_blank" href="https://goo.gl/maps/LqTFnekUjRb9N12q6" rel="noreferrer" + title="View on Google Maps" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > View on Google Maps diff --git a/src/pages/fixing-vulnerabilities.tsx b/src/pages/fixing-vulnerabilities.tsx index d4f5ee3f0e1..7324da46540 100644 --- a/src/pages/fixing-vulnerabilities.tsx +++ b/src/pages/fixing-vulnerabilities.tsx @@ -76,6 +76,7 @@ const FixingVulnerabilities: FunctionComponent = () => { {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} { >

Search open source code

No account required.

-
+ Start searching now @@ -73,6 +81,10 @@ export const CloudPage: FunctionComponent = () => { { { href="https://sourcegraph.com/sign-up?_ga=2.155066808.1628120401.1642532503-600077800.1642532503&showEmail=true" title="continue with email" className="text-reset text-black underline mt-3" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > continue with email @@ -115,14 +134,28 @@ export const CloudPage: FunctionComponent = () => { By registering, you agree to our{' '} {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - + Terms of Service {' '} and{' '} {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - Privacy Policy + + Privacy Policy + . @@ -136,6 +169,9 @@ export const CloudPage: FunctionComponent = () => { href="https://sourcegraph.com/sign-in" title="Search public code with Sourcegraph Cloud" className="text-reset text-black underline" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > Log in diff --git a/src/pages/get-started/index.tsx b/src/pages/get-started/index.tsx index 42d78b8d132..80516530fa1 100644 --- a/src/pages/get-started/index.tsx +++ b/src/pages/get-started/index.tsx @@ -4,6 +4,7 @@ import ArrowRightIcon from 'mdi-react/ArrowRightIcon' import Link from 'next/link' import { Layout } from '@components' +import { buttonStyle, buttonLocation } from '@data' import { useQueryString } from '@hooks' import styles from './getStarted.module.scss' @@ -25,7 +26,13 @@ export const GetStartedPage: FunctionComponent = () => { const GetStartedCTA: FunctionComponent<{ href: string }> = ({ href }) => ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - + Get started for free @@ -91,9 +98,12 @@ export const GetStartedPage: FunctionComponent = () => {

Already have a Sourcegraph Cloud account?{' '} Sign in diff --git a/src/pages/get-started/self-hosted.tsx b/src/pages/get-started/self-hosted.tsx index c74408226b1..c36ba9d39c8 100644 --- a/src/pages/get-started/self-hosted.tsx +++ b/src/pages/get-started/self-hosted.tsx @@ -61,6 +61,7 @@ export const SelfHostedPage: FunctionComponent = () => {

{ @@ -38,7 +39,15 @@ export const Pricing: FunctionComponent = () => {
  • We'll give you access to all of our{' '} - Enterprise features + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Enterprise features +
  • We'll give you live tech support
  • @@ -47,7 +56,15 @@ export const Pricing: FunctionComponent = () => {

    Fill out the form or tweet us{' '} - + @sourcegraph , and we'll get back to you ASAP on how to get started! @@ -59,9 +76,14 @@ export const Pricing: FunctionComponent = () => { target="_blank" rel="noreferrer" href="https://docs.sourcegraph.com/admin/install/docker" + title="Installation docs" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > - installation docs. + installation docs + .

    When you're ready to present, check out the{' '} @@ -69,6 +91,10 @@ export const Pricing: FunctionComponent = () => { target="_blank" rel="noreferrer" href="https://docs.sourcegraph.com/getting-started/tour" + title="Sourcegraph tour" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > Sourcegraph tour {' '} diff --git a/src/pages/home/_Hero.tsx b/src/pages/home/_Hero.tsx index 4e591312e0e..4160f1ff43a 100644 --- a/src/pages/home/_Hero.tsx +++ b/src/pages/home/_Hero.tsx @@ -54,9 +54,9 @@ const Hero: FunctionComponent = () => {

    + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} {
    + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} {

    Product or installation questions?{' '} - + Talk to an expert . @@ -100,17 +106,28 @@ const Hero: FunctionComponent = () => { Over{' '} {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - 1.2M engineers + + 1.2M engineers + {' '} use Sourcegraph to build software you rely on - - Learn how our customers use Sourcegraph + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Learn how our customers use Sourcegraph +

    diff --git a/src/pages/home/_UseCases.tsx b/src/pages/home/_UseCases.tsx index 0cb292c8481..284df96c772 100644 --- a/src/pages/home/_UseCases.tsx +++ b/src/pages/home/_UseCases.tsx @@ -112,13 +112,16 @@ const UseCases: FunctionComponent = () => {

    {useCase.description}

    {useCase.link && ( - - {useCase.link.text} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + {useCase.link.text} + )}
    @@ -137,13 +140,35 @@ const UseCases: FunctionComponent = () => { Want to use Sourcegraph at your company?

    - Get started for free with up to 10 teammates or{' '} - request a demo to learn about our enterprise plan and to see Sourcegraph - in your own environment. + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Get started + + {' '} + for free with up to 10 teammates or{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + request a demo + + {' '} + to learn about our enterprise plan and to see Sourcegraph in your own environment. + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} { const glassdoorReviewItems = [ @@ -199,6 +200,9 @@ const CareersPage: FunctionComponent = () => { title="Explore our jobs" target="_blank" rel="nofollow noreferrer" + data-button-style={buttonStyle.primary} + data-button-location={buttonLocation.hero} + data-button-type="cta" > Explore our jobs @@ -235,6 +239,10 @@ const CareersPage: FunctionComponent = () => { rel="noreferrer" className="handbook-benefits-link" href="https://handbook.sourcegraph.com/benefits-pay-perks/benefits-perks" + title="our handbook" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > our handbook @@ -349,6 +357,9 @@ const CareersPage: FunctionComponent = () => { title="Explore our jobs" target="_blank" rel="nofollow noreferrer" + data-button-style={buttonStyle.primary} + data-button-location={buttonLocation.body} + data-button-type="cta" > Explore our jobs diff --git a/src/pages/news/index.tsx b/src/pages/news/index.tsx index 39a6d4d4190..f13a4ea8177 100644 --- a/src/pages/news/index.tsx +++ b/src/pages/news/index.tsx @@ -3,6 +3,7 @@ import { FunctionComponent } from 'react' import Link from 'next/link' import { Layout } from '@components' +import { buttonStyle, buttonLocation } from '@data' import articles from './articles' @@ -17,7 +18,18 @@ const News: FunctionComponent = () => (

    Sourcegraph News

    - The latest Sourcegraph news and press releases + The latest Sourcegraph news and{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + press releases + +

    @@ -25,7 +37,15 @@ const News: FunctionComponent = () => (
    @@ -48,7 +68,15 @@ const News: FunctionComponent = () => ( {article.articles.map(a => (
    - + ( href={a.newsLink} target="_blank" rel="nofollow noreferrer" + title={a.newsTitle} + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > {a.newsTitle} diff --git a/src/pages/partner-podcast.tsx b/src/pages/partner-podcast.tsx index fb6e926f79a..0237ed7fe9c 100644 --- a/src/pages/partner-podcast.tsx +++ b/src/pages/partner-podcast.tsx @@ -3,6 +3,7 @@ import { FunctionComponent } from 'react' import Link from 'next/link' import { Layout, CaseStudyCard, FormLegal, BlogResourceItem } from '@components' +import { buttonStyle, buttonLocation } from '@data' import { useHubSpot, useChiliPiper } from '@hooks' const blogResourceItems = [ @@ -121,12 +122,32 @@ const PartnerPodcastPage: FunctionComponent = () => {

    Want to use Sourcegraph at your company?

    - Get started - - for free with up to 10 teammates or + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Get started + + + {' '} + for free with up to 10 teammates or{' '} - request a demo - + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + request a demo + + + {' '} to learn about our enterprise plan and to see Sourcegraph in your own environment.
    @@ -148,6 +169,10 @@ const PartnerPodcastPage: FunctionComponent = () => { Changelog diff --git a/src/pages/pricing.tsx b/src/pages/pricing.tsx index daed5e447b3..7f96aa309b6 100644 --- a/src/pages/pricing.tsx +++ b/src/pages/pricing.tsx @@ -194,6 +194,10 @@ const PricingPage: FunctionComponent = () => ( Contact us @@ -208,7 +212,19 @@ const PricingPage: FunctionComponent = () => (

    Sourcegraph supports the work of educational organizations and nonprofits.
    - Please contact us about discounts for your development teams. + Please{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + contact us + + {' '} + about discounts for your development teams.

    diff --git a/src/pages/resources/abcs-book.tsx b/src/pages/resources/abcs-book.tsx index 83dfc9470ff..32d2986c106 100644 --- a/src/pages/resources/abcs-book.tsx +++ b/src/pages/resources/abcs-book.tsx @@ -3,6 +3,7 @@ import { FunctionComponent } from 'react' import Link from 'next/link' import { Layout, ContentSection, YouTube } from '@components' +import { buttonStyle, buttonLocation } from '@data' export const AbcsEbook: FunctionComponent = () => ( ( className="button btn btn-primary" id="abc-dlbook" href="https://about.sourcegraph.com/resources/our-abcs-childrens-book-download" + title="Download your book" + data-button-style={buttonStyle.primary} + data-button-location={buttonLocation.hero} + data-button-type="cta" > Download your book @@ -47,8 +52,15 @@ export const AbcsEbook: FunctionComponent = () => (

    That's why we created a new digital children's book titled{' '} - - "Our ABCs: Always Be Coding" + + "Our ABCs: Always Be Coding" —for all children at home that wonder what their techie parents do all day, night, and some weekends too! @@ -64,6 +76,10 @@ export const AbcsEbook: FunctionComponent = () => ( href="https://about.sourcegraph.com/resources/our-abcs-childrens-book-download" className="d-block" id="abc-dlbook" + title="Book cover: Our ABCs" + data-button-style={buttonStyle.image} + data-button-location={buttonLocation.body} + data-button-type="cta" > ( className="button btn btn-primary" id="abc-dlbook" href="https://about.sourcegraph.com/resources/our-abcs-childrens-book-download" + title="Download your book" + data-button-style={buttonStyle.text} + data-button-location={buttonLocation.body} + data-button-type="cta" > Download your book

    We hope you enjoy the book and would love to get your feedback{' '} - + via Twitter {' '} - or email. + or{' '} + + email + + .

    @@ -127,13 +167,33 @@ export const AbcsEbook: FunctionComponent = () => (

    About Sourcegraph

    Sourcegraph empowers all developers to explore, navigate and better understand all code, faster, - with Universal Code Search. Sourcegraph's mission is - to make it easier and faster for developers to work on solving problems. + with{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Universal Code Search + + + . Sourcegraph's mission is to make it easier and faster for developers to work on solving + problems.

    To learn more, get our ebook:{' '} - - Sourcegraph: Universal code search and intelligence + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Sourcegraph: Universal code search and intelligence + .

    diff --git a/src/pages/support.tsx b/src/pages/support.tsx index b2980dac88c..2808d6b9c7a 100644 --- a/src/pages/support.tsx +++ b/src/pages/support.tsx @@ -4,6 +4,7 @@ import CheckIcon from 'mdi-react/CheckIcon' import Link from 'next/link' import { ContentSection, Layout, TrySourcegraph } from '@components' +import { buttonStyle, buttonLocation } from '@data' const CLASS_NAMES = { featureOffered: 'list-group-item bg-transparent border-0', @@ -39,7 +40,19 @@ const Support: FunctionComponent = () => (

    Sourcegraph Support

    - See Pricing to learn more about these tiers. + See{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Pricing + + {' '} + to learn more about these tiers.

    @@ -51,6 +64,10 @@ const Support: FunctionComponent = () => ( Deploy @@ -59,7 +76,13 @@ const Support: FunctionComponent = () => (
  • {SUPPORT_FEATURES.communitySupport} - + {SUPPORT_FEATURES.publicIssueTracker}
  • @@ -101,6 +124,10 @@ const Support: FunctionComponent = () => ( Buy now @@ -109,7 +136,13 @@ const Support: FunctionComponent = () => (
  • {SUPPORT_FEATURES.communitySupport} - + {SUPPORT_FEATURES.publicIssueTracker}
  • @@ -153,7 +186,13 @@ const Support: FunctionComponent = () => ( passHref={true} > {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - + Contact us @@ -162,7 +201,13 @@ const Support: FunctionComponent = () => (
  • {SUPPORT_FEATURES.communitySupport} - + {SUPPORT_FEATURES.publicIssueTracker}
  • @@ -189,16 +234,38 @@ const Support: FunctionComponent = () => (
  • {SUPPORT_FEATURES.sharedSlackChannelContact}{' '} - - contact us + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + contact us + )
  • Dedicated customer engineer assigned to you (available,{' '} - - contact us + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + contact us + )
  • @@ -209,7 +276,16 @@ const Support: FunctionComponent = () => (

    * We will use commercially reasonable efforts to adhere to the SLAs and uptime defined above. SLAs apply to tickets submitted via email to{' '} - support@sourcegraph.com. + + support@sourcegraph.com + + .


    diff --git a/src/pages/use-cases/code-health.tsx b/src/pages/use-cases/code-health.tsx index 5e6992399c0..ee50c503765 100644 --- a/src/pages/use-cases/code-health.tsx +++ b/src/pages/use-cases/code-health.tsx @@ -39,6 +39,7 @@ const items = [ {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} Create living, actionable documentation with{' '} - Notebooks that show your best practices - with real-life examples you can share with your team. + + Notebooks + {' '} + that show your best practices with real-life examples you can share with your team.

    } /> @@ -106,7 +116,16 @@ const items = [

    Make sure deprecated endpoints don't sneak back into your code. Get alerts for new occurrences of deprecated methods or restricted patterns with{' '} - code monitoring. + + code monitoring + + .

    } /> @@ -121,7 +140,19 @@ const items = [ text={

    Create dashboards to track mitigations, package use, version adoption, code smells, codebase - size, and more to understand code health with Code Insights. + size, and more to understand code health with{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Code Insights + + + .

    } /> @@ -359,6 +390,7 @@ const UseCasePage: FunctionComponent = () => ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} Find out if a teammate has already solved your problem. With{' '} - Code Search, you can quickly search across all your - repositories to find the code you need. + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Code Search + + + , you can quickly search across all your repositories to find the code you need.

    } /> @@ -68,7 +78,18 @@ const items = [

    Spend less time on manual updates. Whether refactoring duplicate code or updating a shared library, automate changes seamlessly across your entire codebase with{' '} - Batch Changes. + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Batch Changes + + + .

    } /> @@ -82,10 +103,18 @@ const items = [ header="Alert for deprecated code use" text={

    - Catch deprecated code as it’s committed with - code monitoring. Monitor and get - alerts when someone uses out-of-date libraries or deprecated functions, so you know who to work - with on updates and adoption. + Catch deprecated code as it’s committed with{' '} + + code monitoring + + . Monitor and get alerts when someone uses out-of-date libraries or deprecated functions, so you + know who to work with on updates and adoption.

    } /> @@ -100,7 +129,19 @@ const items = [ text={

    Get visibility into code reuse progress. Track the prevalence of shared code in your codebase - over time with Code Insights.. + over time with{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Code Insights + + + .

    } /> @@ -293,7 +334,13 @@ const CodeReusePage: FunctionComponent = () => ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - + Explore other use cases @@ -324,6 +371,7 @@ const CodeReusePage: FunctionComponent = () => ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} Vulnerabilities are inevitable, but they don't have to be disruptive. With{' '} - Code Search, you can find vulnerabilities across your - repositories in a single search. Relieve your engineers from manual work, get a headstart on - remediation, and act confidently knowing that you've located all affected code. + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Code Search + + + , you can find vulnerabilities across your repositories in a single search. Relieve your + engineers from manual work, get a headstart on remediation, and act confidently knowing that + you've located all affected code.

    } /> @@ -53,9 +64,19 @@ const items = [ text={

    Deploy fixes at scale. Don't let the size and complexity of your codebase hold you back. With{' '} - Batch Changes, you can automate the merging and deployment of - fixes. Move faster than your competitors, free up your engineers, and return your codebase to a - healthy state. + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Batch Changes + + + , you can automate the merging and deployment of fixes. Move faster than your competitors, free + up your engineers, and return your codebase to a healthy state.

    } /> @@ -69,10 +90,19 @@ const items = [ header="Proactively monitor for the presence of vulnerable code" text={

    - Get ahead of vulnerabilities. With - code monitoring, get alerts whenever - specified patterns enter your codebase. Monitors ensure new occurrences are detected immediately - and allow you to catch them before merging—and before customers have reason to worry. + Get ahead of vulnerabilities. With{' '} + + code monitoring + + , get alerts whenever specified patterns enter your codebase. Monitors ensure new occurrences + are detected immediately and allow you to catch them before merging—and before customers have + reason to worry.

    } /> @@ -88,8 +118,19 @@ const items = [

    Get the full picture of an incident. Track how long the vulnerable code has been in your codebase and how quickly you're removing it. With{' '} - Code Insights, you can measure the progress of applying - longer-term fixes for vulnerabilities and incidents across all your code. + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Code Insights + + + , you can measure the progress of applying longer-term fixes for vulnerabilities and incidents + across all your code.

    } /> @@ -311,7 +352,15 @@ const UseCasePage: FunctionComponent = () => (
    Learn how to use Sourcegraph to identify and resolve every instance of Log4j.
    {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - Read the blog post. + + Read the blog post. +
    @@ -354,7 +403,13 @@ const UseCasePage: FunctionComponent = () => ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - + Explore other use cases @@ -384,6 +439,7 @@ const UseCasePage: FunctionComponent = () => ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} No heroics required: Quickly understand all the context and dependencies around your codebase - with Code Search so you can find the root cause of an incident - with confidence and speed. Document work in progress with{' '} - Notebooks so teammates can get up to speed - quickly. + with{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Code Search + + {' '} + so you can find the root cause of an incident with confidence and speed. Document work in + progress with{' '} + + Notebooks + {' '} + so teammates can get up to speed quickly.

    } /> @@ -54,9 +74,20 @@ const items = [ text={

    Automate the deployment of fixes everywhere and at scale. With{' '} - Batch Changes, you can automate code changes and monitor the - merge status of each resulting PR. Refactor code to replace insecure functions, update - vulnerable packages, or modify container configurations across hundreds of repositories. + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Batch Changes + + + , you can automate code changes and monitor the merge status of each resulting PR. Refactor code + to replace insecure functions, update vulnerable packages, or modify container configurations + across hundreds of repositories.

    } /> @@ -71,8 +102,19 @@ const items = [ text={

    Visualize fixes in progress and track their deployment. With{' '} - Code Insights, get visibility into remediation efforts and - share progress with team leaders and all of your customers. + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Code Insights + + + , get visibility into remediation efforts and share progress with team leaders and all of your + customers.

    } /> @@ -87,8 +129,17 @@ const items = [ text={

    Close the loop on your incident response efforts. After finding the root cause, use{' '} - code monitoring to track whether - similarly unsafe code is ever merged. Get alerts and stop incidents before they occur. + + code monitoring + {' '} + to track whether similarly unsafe code is ever merged. Get alerts and stop incidents before they + occur.

    } /> @@ -284,7 +335,15 @@ const IncidentResponsePage: FunctionComponent = () => ( passHref={true} > {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - Read the Cloudflare case study + + Read the Cloudflare case study + ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - + Explore other use cases @@ -365,6 +430,7 @@ const IncidentResponsePage: FunctionComponent = () => ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} (
  • Reduce time to recovery with a single search
  • Automate fixing, merging, and deploying changes with{' '} - Batch Changes + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Batch Changes + +
  • Alert for known vulnerabilities and risky code changes with code monitoring
  • @@ -103,6 +114,7 @@ const UseCases: React.FunctionComponent = () => ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - Learn more + + Learn more +
    diff --git a/src/pages/use-cases/onboarding.tsx b/src/pages/use-cases/onboarding.tsx index 1a7dcb780b8..c211a2ecb52 100644 --- a/src/pages/use-cases/onboarding.tsx +++ b/src/pages/use-cases/onboarding.tsx @@ -52,8 +52,20 @@ const items = [ header="Enable developers to learn by example" text={

    - With Code Search, you can find examples to learn from across - all of your company's private repositories and the open source universe. + With{' '} + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Code Search + + + , you can find examples to learn from across all of your company's private repositories and the + open source universe.

    } /> @@ -83,8 +95,19 @@ const items = [ header="Visualize contributions and chart team progress" text={

    - Code Insights allows onboarding developers to understand - in-process work and visualize how their contributions advance team goals. + + {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} + + Code Insights + + {' '} + allows onboarding developers to understand in-process work and visualize how their contributions + advance team goals.

    } /> @@ -98,9 +121,18 @@ const items = [ header="Document and share actionable code snippets" text={

    - With Notebooks, teams can create always - up-to-date, living documentation with familiar features like Markdown and novel capabilities - like embedded searches, snippets, and symbols. + With{' '} + + Notebooks + + , teams can create always up-to-date, living documentation with familiar features like Markdown + and novel capabilities like embedded searches, snippets, and symbols.

    } /> @@ -313,7 +345,13 @@ const UseCasePage: FunctionComponent = () => ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - + Explore other use cases @@ -346,6 +384,7 @@ const UseCasePage: FunctionComponent = () => ( {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} ( (

    We have compiled some excellent tips and tricks from fellow{' '} - teammates on how to live your best - distributed work life! + + teammates + {' '} + on how to live your best distributed work life!

    Tips for working remotely

    Home office and desk setup

    @@ -159,7 +168,17 @@ export const RemoteWorkEasier: FunctionComponent = () => ( Sourcegraph's search also makes it more likely that you will discover documentation that is stored inside your repositories but outside your code. This increases traffic to documentation and leads to people relying on it more, which in turn causes people to improve it. We have seen - this extensively in the Sourcegraph handbook. + this extensively in the{' '} + + Sourcegraph handbook + + .

    Share code more easily

    @@ -173,10 +192,25 @@ export const RemoteWorkEasier: FunctionComponent = () => ( author="Uwe Hoffmann, Software Engineer at Sourcegraph" />

    - With Sourcegraph editor extensions + With{' '} + + Sourcegraph editor extensions + , you can easily use a shortcut key to open your current selection on Sourcegraph. You can also use our{' '} - + browser search engine shortcuts {' '} to quickly search across your entire organization's code. Both allow you to instantly get a link @@ -208,7 +242,15 @@ export const RemoteWorkEasier: FunctionComponent = () => (

    @@ -218,10 +260,14 @@ export const RemoteWorkEasier: FunctionComponent = () => ( Tweet {' '} @@ -252,7 +298,13 @@ export const RemoteWorkEasier: FunctionComponent = () => ( passHref={true} > {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */} - + Free download diff --git a/src/styles/globals.scss b/src/styles/globals.scss index b2bfc2146ff..f34dc89cc7c 100644 --- a/src/styles/globals.scss +++ b/src/styles/globals.scss @@ -236,6 +236,19 @@ table tbody + tbody { border-bottom-width: 1px; } +.tab-header { + background-color: transparent; + color: $black; + font-weight: 600 !important; +} +.nav-tabs .nav-link.active { + color: $black !important; + background-color: transparent !important; + @include media-breakpoint-up(md) { + border-bottom: solid $vivid-violet 3px; + } +} + /* ==================== Misc ==================== */ .virtual-br::before { diff --git a/src/styles/pages/_code-insights.scss b/src/styles/pages/_code-insights.scss index 4541b580a2f..0c10f40fed6 100644 --- a/src/styles/pages/_code-insights.scss +++ b/src/styles/pages/_code-insights.scss @@ -73,20 +73,6 @@ } } - /* Bootstrap overrides */ - .tab-header { - background-color: transparent; - color: $blurple; - font-weight: 600 !important; - } - .nav-tabs .nav-link.active { - color: $black !important; - background-color: transparent !important; - @include media-breakpoint-up(md) { - border-bottom: solid $vivid-violet 3px; - } - } - .btn-link, .btn-primary { @media only screen and (max-width: 768px) {