Skip to content

Commit

Permalink
Redacted banner on all pages
Browse files Browse the repository at this point in the history
  • Loading branch information
calebjacob committed Sep 21, 2024
1 parent 5eb82aa commit e2e3b14
Show file tree
Hide file tree
Showing 5 changed files with 62 additions and 0 deletions.
Binary file added public/images/redacted/redacted-left.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/images/redacted/redacted-right.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
35 changes: 35 additions & 0 deletions src/components/RedactedBanner.module.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
.redactedBanner {
display: grid;
grid-template-columns: 1fr 1fr;

a {
display: block;
outline: none;
transition: box-shadow 300ms;
position: relative;

&::before {
content: '';
display: block;
position: absolute;
inset: 0;
transition: box-shadow 300ms;
}

&:hover {
z-index: 100;
box-shadow: 0 0 1rem rgba(0, 0, 0, 0.3);
}

&:focus-visible {
z-index: 100;
&::before {
box-shadow: inset 0 0 0 4px var(--violet5);
}
}

img {
width: 100%;
}
}
}
25 changes: 25 additions & 0 deletions src/components/RedactedBanner.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import { Container } from '@near-pagoda/ui';

import s from './RedactedBanner.module.scss';

export const RedactedBanner = () => {
return (
<Container>
<div className={s.redactedBanner}>
<a href="https://airtable.com/appdLXQkwmt4rqtW0/pag21sUeq3cAW994V/form" target="_blank">
<img
src="/images/redacted/redacted-left.png"
alt="Redacted: Reclaim your sovereignty at no cost. Click to be there IRL"
/>
</a>

<a href="https://redacted.devpost.com/" target="_blank">
<img
src="/images/redacted/redacted-right.png"
alt="Redacted: It's so much more than a hackathon. Click to learn more"
/>
</a>
</div>
</Container>
);
};
2 changes: 2 additions & 0 deletions src/components/layouts/DefaultLayout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { type ReactNode } from 'react';

import { Footer } from '../Footer';
import { Navigation } from '../navigation/Navigation';
import { RedactedBanner } from '../RedactedBanner';
import s from './DefaultLayout.module.scss';

interface Props {
Expand All @@ -14,6 +15,7 @@ export function DefaultLayout({ children }: Props) {
<Navigation />

<div className={s.content}>
<RedactedBanner />
{children}
<Footer />
</div>
Expand Down

0 comments on commit e2e3b14

Please sign in to comment.