Skip to content

Commit

Permalink
feat: go live, beta version
Browse files Browse the repository at this point in the history
  • Loading branch information
TheJoin95 committed Aug 22, 2022
1 parent cd9548f commit 40259b1
Show file tree
Hide file tree
Showing 6 changed files with 295 additions and 146 deletions.
44 changes: 2 additions & 42 deletions snackjob-frontend/components/Footer.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,52 +56,12 @@ export default function Footer () {
color: "white",
}}
>
All rights reserved
Made with ❤️ by @schrodinger_hat
</p>

<Flex mx="-2">
<a
href="#"
mx="2"
color="gray.600"
_dark={{
color: "gray.300",
_hover: {
color: "gray.400",
},
}}
_hover={{
color: "gray.500",
}}
aria-label="Reddit"
>
<Icon boxSize="5" viewBox="0 0 24 24" fill="currentColor">
<path d="M12 22C6.47715 22 2 17.5228 2 12C2 6.47715 6.47715 2 12 2C17.5228 2 22 6.47715 22 12C21.9939 17.5203 17.5203 21.9939 12 22ZM6.807 10.543C6.20862 10.5433 5.67102 10.9088 5.45054 11.465C5.23006 12.0213 5.37133 12.6558 5.807 13.066C5.92217 13.1751 6.05463 13.2643 6.199 13.33C6.18644 13.4761 6.18644 13.6229 6.199 13.769C6.199 16.009 8.814 17.831 12.028 17.831C15.242 17.831 17.858 16.009 17.858 13.769C17.8696 13.6229 17.8696 13.4761 17.858 13.33C18.4649 13.0351 18.786 12.3585 18.6305 11.7019C18.475 11.0453 17.8847 10.5844 17.21 10.593H17.157C16.7988 10.6062 16.458 10.7512 16.2 11C15.0625 10.2265 13.7252 9.79927 12.35 9.77L13 6.65L15.138 7.1C15.1931 7.60706 15.621 7.99141 16.131 7.992C16.1674 7.99196 16.2038 7.98995 16.24 7.986C16.7702 7.93278 17.1655 7.47314 17.1389 6.94094C17.1122 6.40873 16.6729 5.991 16.14 5.991C16.1022 5.99191 16.0645 5.99491 16.027 6C15.71 6.03367 15.4281 6.21641 15.268 6.492L12.82 6C12.7983 5.99535 12.7762 5.993 12.754 5.993C12.6094 5.99472 12.4851 6.09583 12.454 6.237L11.706 9.71C10.3138 9.7297 8.95795 10.157 7.806 10.939C7.53601 10.6839 7.17843 10.5422 6.807 10.543ZM12.18 16.524C12.124 16.524 12.067 16.524 12.011 16.524C11.955 16.524 11.898 16.524 11.842 16.524C11.0121 16.5208 10.2054 16.2497 9.542 15.751C9.49626 15.6958 9.47445 15.6246 9.4814 15.5533C9.48834 15.482 9.52348 15.4163 9.579 15.371C9.62737 15.3318 9.68771 15.3102 9.75 15.31C9.81233 15.31 9.87275 15.3315 9.921 15.371C10.4816 15.7818 11.159 16.0022 11.854 16C11.9027 16 11.9513 16 12 16C12.059 16 12.119 16 12.178 16C12.864 16.0011 13.5329 15.7863 14.09 15.386C14.1427 15.3322 14.2147 15.302 14.29 15.302C14.3653 15.302 14.4373 15.3322 14.49 15.386C14.5985 15.4981 14.5962 15.6767 14.485 15.786V15.746C13.8213 16.2481 13.0123 16.5208 12.18 16.523V16.524ZM14.307 14.08H14.291L14.299 14.041C13.8591 14.011 13.4994 13.6789 13.4343 13.2429C13.3691 12.8068 13.6162 12.3842 14.028 12.2269C14.4399 12.0697 14.9058 12.2202 15.1478 12.5887C15.3899 12.9572 15.3429 13.4445 15.035 13.76C14.856 13.9554 14.6059 14.0707 14.341 14.08H14.306H14.307ZM9.67 14C9.11772 14 8.67 13.5523 8.67 13C8.67 12.4477 9.11772 12 9.67 12C10.2223 12 10.67 12.4477 10.67 13C10.67 13.5523 10.2223 14 9.67 14Z"></path>
</Icon>
</a>

<a
href="#"
mx="2"
color="gray.600"
_dark={{
color: "gray.300",
_hover: {
color: "gray.400",
},
}}
_hover={{
color: "gray.500",
}}
aria-label="Facebook"
>
<Icon boxSize="5" viewBox="0 0 24 24" fill="currentColor">
<path d="M2.00195 12.002C2.00312 16.9214 5.58036 21.1101 10.439 21.881V14.892H7.90195V12.002H10.442V9.80204C10.3284 8.75958 10.6845 7.72064 11.4136 6.96698C12.1427 6.21332 13.1693 5.82306 14.215 5.90204C14.9655 5.91417 15.7141 5.98101 16.455 6.10205V8.56104H15.191C14.7558 8.50405 14.3183 8.64777 14.0017 8.95171C13.6851 9.25566 13.5237 9.68693 13.563 10.124V12.002H16.334L15.891 14.893H13.563V21.881C18.8174 21.0506 22.502 16.2518 21.9475 10.9611C21.3929 5.67041 16.7932 1.73997 11.4808 2.01722C6.16831 2.29447 2.0028 6.68235 2.00195 12.002Z"></path>
</Icon>
</a>

<a
href="#"
href="https://github.com/schrodinger-hat"
mx="2"
color="gray.600"
_dark={{
Expand Down
47 changes: 4 additions & 43 deletions snackjob-frontend/components/Header.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { MoonIcon, SunIcon } from '@chakra-ui/icons'
import { useViewportScroll } from 'framer-motion';

export default function Header() {
const mobileNav = useDisclosure();
const mobileNav = useDisclosure();
const { toggleColorMode: toggleMode } = useColorMode();
const text = useColorModeValue("dark", "light");
const SwitchIcon = useColorModeValue(MoonIcon, SunIcon);
Expand All @@ -24,8 +24,7 @@ export default function Header() {
}}
alignItems="center"
as="a"
aria-label="Sponsor Choc UI on Open Collective"
href={""}
href={"https://opencollective.com/schrodinger-hat"}
target="_blank"
rel="noopener noreferrer"
bg="gray.50"
Expand Down Expand Up @@ -55,44 +54,8 @@ export default function Header() {
</Box>
</Box>
);
const MobileNavContent = (
<VStack
pos="absolute"
top={0}
left={0}
right={0}
display={mobileNav.isOpen ? "flex" : "none"}
flexDirection="column"
p={2}
pb={4}
m={2}
bg={bg}
spacing={3}
rounded="sm"
shadow="sm"
>
<CloseButton
aria-label="Close menu"
justifySelf="self-start"
onClick={mobileNav.onClose}
/>
<Button w="full" variant="ghost">
Dashboard
</Button>
<Button
w="full"
variant="solid"
colorScheme="brand"
>
Inbox
</Button>
<Button w="full" variant="ghost">
Videos
</Button>
</VStack>
);
return (
<Box pos="relative">
<Box mt={5} pos="relative">
<header
ref={ref}
shadow={y > height ? "sm" : undefined}
Expand Down Expand Up @@ -129,8 +92,7 @@ export default function Header() {
>
<Link
isExternal
aria-label="Go to Choc UI GitHub page"
href="https://github.com/anubra266/choc-ui"
href="https://github.com/Schrodinger-Hat/snackjob"
>
Github
</Link>
Expand Down Expand Up @@ -165,7 +127,6 @@ export default function Header() {
/>
</Flex>
</Flex>
{MobileNavContent}
</div>
</header>
</Box>
Expand Down
20 changes: 20 additions & 0 deletions snackjob-frontend/components/Layout.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,29 @@
import Header from './Header'
import Footer from './Footer'
import Head from 'next/head'

export default function Layout({ children }) {
return (
<>
<Head>
<meta charset="utf-8" />
<title>Snackjob - The job title generator</title>
<meta name="viewport" content="width=device-width,initial-scale=1,shrink-to-fit=no" />
<meta name="msapplication-TileColor" content="#da532c" />
<meta name="theme-color" content="#ffffff" />
<meta name="description" content="Snackjob is a job title generator for any kind of business, positions and domains. Don't be afraid to be the one that is leading the trend" />
<meta property="og:title" content="Snackjob - The job title generator" />
<meta property="og:type" content="article" />
<meta property="og:url" content="https://jobs.schrodinger-hat.it/" />
<meta property="og:site_name" content="jobs.schrodinger-hat.it" />
<meta property="og:description" content="Snackjob is a job title generator for any kind of business, positions and domains." />
<meta name="twitter:widgets:csp" content="on" />
<meta name="twitter:card" content="summary" />
<meta name="twitter:site" content="https://twitter.com/schrodinger_hat" />
<meta name="twitter:domain" content="jobs.schrodinger-hat" />
<meta name="twitter:title" content="Snackjob - The job title generator" />
<meta name="twitter:description" content="Snackjob is a job title generator for any kind of business, positions and domains." />
</Head>
<Header />
<main>{children}</main>
<Footer />
Expand Down
110 changes: 67 additions & 43 deletions snackjob-frontend/pages/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,25 @@
import { Box, Button, Icon, Text, Stack } from '@chakra-ui/react'
import styles from '../styles/Home.module.css'
import { Box, Button, Icon, Text, Stack, Img, Input } from '@chakra-ui/react'
import { useState } from 'react'

export default function Home() {
const [formValues, setFormValues] = useState({
name: '',
title: ''
})

const createSnackjob = (e) => {
e.preventDefault()
if (formValues.name !== '' && formValues.title !== '') {
fetch(`https://snackjob-api.schrodinger-hat.it/api/v1/snackjob?name=${encodeURIComponent(formValues.name)}&title=${encodeURIComponent(formValues.title)}`)
.then((r) => r.json().then((j) => {
window.location.href = `/snackjob/${j.md5}`
}))
.catch((e) => console.log(e))
} else {
alert('Nope. Write down your name and title, thanks. Yes, this is an old style alert.');
}
}

return (
<Box px={8} py={24} mx="auto">
<Box
Expand All @@ -16,8 +34,8 @@ export default function Home() {
md: "center",
}}
>
<h1
mb={6}
<Text
mb={2}
fontSize={{
base: "4xl",
md: "6xl",
Expand All @@ -33,7 +51,7 @@ export default function Home() {
color: "gray.100",
}}
>
All your{" "}
Be{" "}
<Text
display={{
base: "block",
Expand All @@ -44,11 +62,39 @@ export default function Home() {
bgGradient="linear(to-r, green.400,purple.500)"
fontWeight="extrabold"
>
customer feedback
whoever you want to be
</Text>{" "}
in one single place.
</h1>
<p
anywhere.
</Text>
<Text
fontSize={{
base: "xl",
md: "3xl",
}}
>
<Text
px={{
base: 0,
lg: 24,
}}
fontSize={{
base: "xl",
md: "3xl",
}}
mb={6}
display={{
base: "block",
lg: "inline",
}}
w="full"
bgClip="text"
bgGradient="linear(to-r, green.400,purple.500)"
fontWeight="extrabold"
>
Unleash yourself
</Text>
</Text>
<Text
px={{
base: 0,
lg: 24,
Expand All @@ -63,10 +109,9 @@ export default function Home() {
color: "gray.300",
}}
>
Hellonext is a feature voting software where you can allow your users to
vote on features, publish roadmap, and complete your customer feedback
loop.
</p>
Snackjob is a job title generator for any kind of business, positions and domains.
Don't be afraid to be the one that is leading the trend
</Text>
<Stack
direction={{
base: "column",
Expand All @@ -76,16 +121,20 @@ export default function Home() {
base: 4,
md: 8,
}}
mt={10}
spacing={2}
justifyContent={{
sm: "left",
md: "center",
}}
>
<Input onChange={(e) => setFormValues((p) => { return { ...p, name: e.target.value }})} width={'sm'} placeholder='Your name' />
<Input onChange={(e) => setFormValues((p) => { return { ...p, title: e.target.value }})} width={'sm'} placeholder='Your Current Job Title' />
<Button
as="a"
variant="solid"
colorScheme="brand"
onClick={() => createSnackjob()}
href={'#snackjob-form'}
variant="outline"
display="inline-flex"
alignItems="center"
justifyContent="center"
Expand All @@ -97,10 +146,10 @@ export default function Home() {
base: 2,
sm: 0,
}}
size="lg"
size="md"
cursor="pointer"
>
Get Started
Go big now
<Icon boxSize={4} ml={1} viewBox="0 0 20 20" fill="currentColor">
<path
fillRule="evenodd"
Expand All @@ -109,33 +158,8 @@ export default function Home() {
/>
</Icon>
</Button>
<Button
as="a"
colorScheme="gray"
display="inline-flex"
alignItems="center"
justifyContent="center"
w={{
base: "full",
sm: "auto",
}}
mb={{
base: 2,
sm: 0,
}}
size="lg"
cursor="pointer"
>
Book a Demo
<Icon boxSize={4} ml={1} viewBox="0 0 20 20" fill="currentColor">
<path
fillRule="evenodd"
d="M6.672 1.911a1 1 0 10-1.932.518l.259.966a1 1 0 001.932-.518l-.26-.966zM2.429 4.74a1 1 0 10-.517 1.932l.966.259a1 1 0 00.517-1.932l-.966-.26zm8.814-.569a1 1 0 00-1.415-1.414l-.707.707a1 1 0 101.415 1.415l.707-.708zm-7.071 7.072l.707-.707A1 1 0 003.465 9.12l-.708.707a1 1 0 001.415 1.415zm3.2-5.171a1 1 0 00-1.3 1.3l4 10a1 1 0 001.823.075l1.38-2.759 3.018 3.02a1 1 0 001.414-1.415l-3.019-3.02 2.76-1.379a1 1 0 00-.076-1.822l-10-4z"
clipRule="evenodd"
/>
</Icon>
</Button>
</Stack>
<Img mt={10} mx={'auto'} src='/demo.gif' />
</Box>
</Box>
)
Expand Down
Loading

0 comments on commit 40259b1

Please sign in to comment.