Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent internal links to open a new tab and make some tweaks #557

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion shared.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@ import { Author } from './src/templates/author/shared';
export const webinarsUrl =
'https://try.estuary.dev/webinar-estuary101-ondemand';

export const dashboardRegisterUrl = 'https://dashboard.estuary.dev/register';
export const dashboardUrl = 'https://dashboard.estuary.dev';
export const dashboardRegisterUrl = `${dashboardUrl}/register`;
export const statusPageUrl = 'https://status.estuary.dev/';
export const docsPageUrl = 'https://docs.estuary.dev';
export const slackUrl =
'https://estuary-dev.slack.com/join/shared_invite/zt-86nal6yr-VPbv~YfZE9Q~6Zl~gmZdFQ#/shared-invite/email';
export const estuaryFlowGithubUrl = 'https://github.com/estuary/flow/';

export const estuaryProductFlowVideoUrl =
'https://www.youtube.com/embed/hlCh81ZbBik';
Expand Down Expand Up @@ -192,3 +194,5 @@ export interface Vendor {
}

export type DeploymentOption = keyof typeof features;

export const activeUsersAmount = '5500+';
6 changes: 5 additions & 1 deletion src/components/Advantages/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ type AdvantagesProps = {
link?: {
title: string;
href: string;
openNewTab?: boolean;
};
isDarkTheme?: boolean;
isImageOnTheLeft?: boolean;
Expand Down Expand Up @@ -60,7 +61,10 @@ const Advantages = ({
) : null}
{link ? (
<ButtonWrapper>
<OutboundLinkFilled href={link.href} target="_blank">
<OutboundLinkFilled
href={link.href}
target={link.openNewTab ? '_blank' : undefined}
>
{link.title}
</OutboundLinkFilled>
</ButtonWrapper>
Expand Down
2 changes: 1 addition & 1 deletion src/components/ConnectorsLink/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ const ConnectorsLink = ({
return `/integrations/${captureConnectors.find((c) => c.id === sourceId)?.slugified_name}-to-${
materializationConnectors.find((c) => c.id === destinationId)
?.slugified_name
}`;
}/`;
} else {
return '#';
}
Expand Down
4 changes: 1 addition & 3 deletions src/components/EtlToolsPage/LearnMoreArticles/Card/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,7 @@ const Card = ({ title, buttonHref }: CardProps) => {
<FileIcon color="#5072EB" />
</div>
<h3>{title}</h3>
<LinkOutlined href={buttonHref} target="_blank">
Read
</LinkOutlined>
<LinkOutlined href={buttonHref}>Read</LinkOutlined>
</div>
);
};
Expand Down
6 changes: 3 additions & 3 deletions src/components/EtlToolsPage/LearnMoreArticles/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@ const LearnMoreArticles = () => {
<div className={cardsWrapper}>
<Card
title="The Data Engineer's Guide to ELT Alternatives"
buttonHref="/ELT-alternatives-guide"
buttonHref="/ELT-alternatives-guide/"
/>
<Card
title="The Data Engineer's Guide to ETL Alternatives"
buttonHref="/ETL-alternatives-guide"
buttonHref="/ETL-alternatives-guide/"
/>
<Card
title="The Data Engineer's Guide to CDC for Analytics, Ops, and AI Pipelines"
buttonHref="/CDC-comparison-guide"
buttonHref="/CDC-comparison-guide/"
/>
</div>
</Container>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@ const XvsYCard = ({ xVendor, yVendor }: XvsYCardProps) => {
return (
<a
href={`/${getComparisonSlug(xVendor.slugKey, yVendor.slugKey)}`}
target="_blank"
rel="noreferrer"
className={container}
>
{xVendorLogo && yVendorLogo ? (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
font-weight: 700;
line-height: 28px;
color: #47506D;
text-align: center;

@media (max-width: 824px) {
font-size: 1rem;
Expand Down
2 changes: 1 addition & 1 deletion src/components/EtlToolsXvsYPage/GettingStarted/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ const GettingStarted = () => {
}
button={{
title: 'Contact us',
href: '/contact-us',
href: '/contact-us/',
}}
/>
</Container>
Expand Down
6 changes: 3 additions & 3 deletions src/components/EtlToolsXvsYPage/Hero/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import clsx from 'clsx';
import { defaultWrapperDarkBlue } from '../../../globalStyles/wrappers.module.less';
import VendorsLink from '../../VendorsLink';
import { Vendor } from '../../../../shared';
import NewTabLink from '../../NewTabLink';
import InternalLink from '../../InternalLink';
import ChevronRightIcon from '../../../svgs/chevron-right.svg';
import HeroSectionDetails from '../../HeroSectionDetails';
import Container from '../../Container';
Expand Down Expand Up @@ -48,10 +48,10 @@ const Hero = ({ vendors, xVendor, yVendor }: SectionOneProps) => {
yVendor={yVendor}
isDarkTheme
/>
<NewTabLink href="/etl-tools">
<InternalLink href="/etl-tools/">
View all comparisons
<ChevronRightIcon color="#5072EB" />
</NewTabLink>
</InternalLink>
</>
}
/>
Expand Down
14 changes: 9 additions & 5 deletions src/components/Footer/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,12 @@ import SlackIcon from '../../svgs/slack-outline.svg';
import TwitterIcon from '../../svgs/twitter-outline.svg';
import { ButtonOutlinedPrimary } from '../../globalStyles';
import NewsletterSignupForm from '../NewsletterSignupForm';
import { docsPageUrl, slackUrl, statusPageUrl } from '../../../shared';
import {
docsPageUrl,
estuaryFlowGithubUrl,
slackUrl,
statusPageUrl,
} from '../../../shared';
import {
footer,
globalFooterWrapper,
Expand Down Expand Up @@ -86,15 +91,14 @@ const Footer = () => {
</Link>
<OutboundLink
target="_blank"
href="https://github.com/estuary/flow"
href={estuaryFlowGithubUrl}
className={globalFooterRightLink}
>
Github
</OutboundLink>
<a
href="/contact-us"
href="/contact-us/"
className={globalFooterRightLink}
target="_blank"
>
Contact Us
</a>
Expand Down Expand Up @@ -168,7 +172,7 @@ const Footer = () => {
</OutboundLink>
<OutboundLink
target="_blank"
href="https://github.com/estuary/flow"
href={estuaryFlowGithubUrl}
aria-label="Github Repo Link"
>
<GithubIcon className={footerSocialIconStyle} />
Expand Down
11 changes: 8 additions & 3 deletions src/components/Header/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,12 @@ import {
globalHeaderLogo,
globalHeaderTitle,
} from '../styles.module.less';
import { dashboardRegisterUrl, slackUrl } from '../../../shared';
import {
dashboardRegisterUrl,
dashboardUrl,
estuaryFlowGithubUrl,
slackUrl,
} from '../../../shared';
import {
globalHeader,
globalHeaderWrapper,
Expand Down Expand Up @@ -211,7 +216,7 @@ const Header = ({ fixedHeader }: HeaderProps) => {
</OutboundLink>
<OutboundLink
target="_blank"
href="https://github.com/estuary/flow"
href={estuaryFlowGithubUrl}
className={headerSocialIcon}
aria-label="Github Repo Link"
>
Expand All @@ -222,7 +227,7 @@ const Header = ({ fixedHeader }: HeaderProps) => {
<OutboundLink
target="_blank"
className={globalHeaderLink}
href="https://dashboard.estuary.dev"
href={dashboardUrl}
style={{ marginRight: '1rem' }}
>
Log in
Expand Down
2 changes: 1 addition & 1 deletion src/components/HeaderNavbar/Resources/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ const HeaderNavbarResources = ({ active, setActive }) => {
</ImageWrapper>
<LinkOutlined
target="_blank"
href="/why"
href="/why/"
theme="dark"
$fullWidth
>
Expand Down
6 changes: 1 addition & 5 deletions src/components/HeroSectionDetails/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,7 @@ const HeroSectionDetails = ({
>
Build a Pipeline
</OutboundLinkFilled>
<LinkOutlined
href="/contact-us"
target="_blank"
theme="dark"
>
<LinkOutlined href="/contact-us/" theme="dark">
Contact Us
</LinkOutlined>
</div>
Expand Down
1 change: 0 additions & 1 deletion src/components/Homepage/CaseStudies/Card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ const Card = ({ href, title, description, image }: CardProps) => {
<CaseStudyDescription>{description}.</CaseStudyDescription>
<Button
href={href}
target="_blank"
rel="noopener"
aria-label={`Read case study for ${title}`}
>
Expand Down
2 changes: 1 addition & 1 deletion src/components/Homepage/CaseStudies/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ const CaseStudies = () => {
key={caseStudy.id}
title={caseStudy.Title}
description={caseStudy.Description}
href={`/customers/${caseStudy.Slug}`}
href={`/customers/${caseStudy.Slug}/`}
image={
<GatsbyImage
image={
Expand Down
2 changes: 1 addition & 1 deletion src/components/Homepage/DeploymentModes/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ const DeploymentModes = () => {
<Tabs handleTabChange={handleTabChange} />
<TabPanels />
</TabContext>
<LinkFilled href="/deployment-options" target="_blank">
<LinkFilled href="/deployment-options/">
See Details
</LinkFilled>
</div>
Expand Down
4 changes: 1 addition & 3 deletions src/components/Homepage/Do4xMoreWith25xLess/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@ const Do4xMoreWith25xLess = () => {
deliver new projects in days, not months. And they spend
2-5x less on Estuary than on batch ELT.
</p>
<Button href="/pricing" target="_blank">
See Pricing
</Button>
<Button href="/pricing/">See Pricing</Button>
</LeftColumn>
<RightColumn>
<PricingCalculator />
Expand Down
3 changes: 2 additions & 1 deletion src/components/Homepage/Hero/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import SingleDataflowIcon from '../../../svgs/metric-single-dataflow.svg';
import MetricCard from '../../MetricCard';
import VanityLogosMarquee from '../../VanityLogosMarquee';
import HeroSectionDetails from '../../HeroSectionDetails';
import { activeUsersAmount } from '../../../../shared';
import AnimFallback from './AnimFallback';
import AnimatedHero from './AnimatedHero';
import {
Expand Down Expand Up @@ -44,7 +45,7 @@ const Hero = () => {
<MetricCardsList>
<MetricCard
icon={<ActiveUsersIcon color={metricIconColor} />}
value="5500+"
value={activeUsersAmount}
label="Active users"
/>
<MetricCard
Expand Down
2 changes: 1 addition & 1 deletion src/components/Homepage/SeeHow/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const SeeHow = () => {
<OutboundLinkOutlined href={webinarsUrl} target="_blank">
Watch Demo
</OutboundLinkOutlined>
<HubspotButton href="/contact-us" target="_blank">
<HubspotButton href="/contact-us/">
Contact Us
</HubspotButton>
</Buttons>
Expand Down
4 changes: 1 addition & 3 deletions src/components/Homepage/TheBestRealTimeCdc/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,7 @@ const TheBestRealTimeCdc = () => {
<Advantage title="Most versatile writes that maintain a current view or all change history" />
<Advantage title="Most scalable pipelines, with true elastic scaling" />
</AdvantagesList>
<Link href="/integrations" target="_blank" rel="noopener">
View Connectors
</Link>
<Link href="/integrations/">View Connectors</Link>
</LeftColumn>
<RightColumn>
<StaticImage
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { defaultWrapperDarkBlue } from '../../../globalStyles/wrappers.module.le
import SingleDataflowIcon from '../../../svgs/metric-single-dataflow.svg';
import Advantages from '../../Advantages';

const SectionSeven = () => {
const DataopsMadeSimple = () => {
return (
<section className={defaultWrapperDarkBlue}>
<Advantages
Expand All @@ -30,4 +30,4 @@ const SectionSeven = () => {
);
};

export default SectionSeven;
export default DataopsMadeSimple;
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import {
title,
} from './styles.module.less';

const SectionFive = () => {
const EstuaryFlowVideo = () => {
return (
<section className={defaultWrapperDarkBlue}>
<div className={container}>
Expand Down Expand Up @@ -39,4 +39,4 @@ const SectionFive = () => {
);
};

export default SectionFive;
export default EstuaryFlowVideo;
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import {
whiteFilledCircle,
} from '../styles.module.less';

const SectionTwo = ({
const FromConnector = ({
title,
longDescription,
shortDescription,
Expand Down Expand Up @@ -83,4 +83,4 @@ const SectionTwo = ({
);
};

export default SectionTwo;
export default FromConnector;
Loading
Loading