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

#2 - homepage frontend #16

Merged
merged 62 commits into from
Aug 19, 2024
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
Show all changes
62 commits
Select commit Hold shift + click to select a range
0f1aed4
build: Installed vue heroicons
tiankongldp Aug 8, 2024
58345b1
chore: added colors to the tailwind configuration
tiankongldp Aug 11, 2024
34b4c67
chore: add assets
tiankongldp Aug 11, 2024
9be0dc5
chore: configure default transition in vue
tiankongldp Aug 11, 2024
6ee9667
chore: add homepage route
tiankongldp Aug 11, 2024
ee1106a
feat: add homepage
tiankongldp Aug 11, 2024
0746034
feat: added "forgot password" link
tiankongldp Aug 11, 2024
9852b15
fix: uncanny line removed
tiankongldp Aug 12, 2024
7a11829
fix: line added
tiankongldp Aug 12, 2024
4d94241
fix: corrected tailwind dependency
tiankongldp Aug 12, 2024
7af6be6
chore: added `xs` property for responsivness in tailwind
tiankongldp Aug 12, 2024
b398123
fix: corrected responsivness for extra small mobile layout
tiankongldp Aug 12, 2024
fc02c9b
fix: renamed `RegisterBanner` component to `AuthBanner`
tiankongldp Aug 12, 2024
87f5b06
fix: renamed login button to `Sign In`
tiankongldp Aug 12, 2024
52314e8
fix: renamed both auth buttons to "Continue"
tiankongldp Aug 12, 2024
aea9b4b
fix: changed "/home" path to "/"
tiankongldp Aug 12, 2024
54184d8
chore: added red color to config
tiankongldp Aug 12, 2024
ac74a4b
fix: responsiveness for ultra small screens
tiankongldp Aug 12, 2024
2769bb4
fix: added fields requirements
tiankongldp Aug 12, 2024
73a5b8a
style: change fields' outline color
tiankongldp Aug 12, 2024
5b3485f
style: change font "Forgot password?" font size
tiankongldp Aug 12, 2024
f270426
style: added animations for fields
tiankongldp Aug 12, 2024
a24f232
fix: add absent submitForm function
tiankongldp Aug 13, 2024
682f104
refactor: remove redundant styles
tiankongldp Aug 13, 2024
4ddcede
feat: added underdeveloped search (option click doesn't always work)
tiankongldp Aug 13, 2024
a4bd8a0
fix: animation disabled due to inconsistent behaviour
tiankongldp Aug 13, 2024
3c4767b
fix: option click always works
tiankongldp Aug 13, 2024
ed3e380
fix: changed language to polish
tiankongldp Aug 13, 2024
9e9de08
doc: added screenshots
tiankongldp Aug 13, 2024
87428d2
Merge branch 'main' into 2-home-page-frontend
JokeUrSelf Aug 13, 2024
3f0fb55
Update resources/js/components/Home/RegisterForm.vue
JokeUrSelf Aug 13, 2024
4c5215d
Update resources/js/components/Home/InformationButton.vue
JokeUrSelf Aug 13, 2024
8c6c5ce
Update resources/js/components/Home/Footer.vue
JokeUrSelf Aug 13, 2024
a4dc638
Update resources/js/components/Home/RegisterForm.vue
JokeUrSelf Aug 13, 2024
7a1c767
Update resources/js/components/Home/LoginForm.vue
JokeUrSelf Aug 13, 2024
cdd2135
Update resources/js/components/Home/LoginForm.vue
JokeUrSelf Aug 13, 2024
a0eb34a
style: rephrasing sentences
JokeUrSelf Aug 13, 2024
f664a55
rephrasing words and sentences; removing a comment
JokeUrSelf Aug 13, 2024
1f0e25b
rephrasing and removing a line
JokeUrSelf Aug 13, 2024
5e484ba
style: changed the position of a school searchbar
tiankongldp Aug 13, 2024
04fb205
fix: vertical responsiveness
tiankongldp Aug 14, 2024
43f7945
fix: incorrect banner text color with a dark mode turned on
tiankongldp Aug 14, 2024
d521f8e
style: naming banner title to "Testy"
tiankongldp Aug 14, 2024
bf04dc0
fix: footer is now visible on the screen for large displays
tiankongldp Aug 14, 2024
4feb39e
fix: information button hover proportions optimization
tiankongldp Aug 14, 2024
d67cc57
refactor: rewriting a comment
tiankongldp Aug 14, 2024
01e86d8
fix: fixed error on login
tiankongldp Aug 14, 2024
b789a0e
feat: applied styled scrollbar globally
tiankongldp Aug 14, 2024
246d992
fix: sponsors' proper positioning
tiankongldp Aug 14, 2024
c3973c0
refactor: clean sponsors block
tiankongldp Aug 14, 2024
7aba545
refactor: move searchbar from registration to its own component
tiankongldp Aug 14, 2024
592deaa
fix: proper animation for searchbar
tiankongldp Aug 14, 2024
b296f51
refactor: deleted empty line
tiankongldp Aug 14, 2024
d605393
fix: background responsiveness
tiankongldp Aug 15, 2024
371643c
refactor: indentation corrections
JokeUrSelf Aug 19, 2024
eab876c
refactor: remove empty functions
tiankongldp Aug 19, 2024
d1bad96
fix: localization in the banner
tiankongldp Aug 19, 2024
51d46c8
style: added icon to indicate searchbar
tiankongldp Aug 19, 2024
7c134f7
style: correction of titles
tiankongldp Aug 19, 2024
58389e7
fix: responsiveness for fields on small screens
tiankongldp Aug 19, 2024
3cf8140
doc: add screenshots
tiankongldp Aug 19, 2024
d556a40
doc: revert changes in readme
tiankongldp Aug 19, 2024
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
11 changes: 10 additions & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@
"tsc": "vue-tsc"
},
"dependencies": {
"@heroicons/vue": "^2.1.5",
"@inertiajs/vue3": "^1.0.14",
"@tailwindcss/forms": "^0.5.7",
"@tailwindcss/typography": "^0.5.10",
"laravel-vite-plugin": "^1.0.2",
"lodash": "^4.17.21",
"tailwindcss": "^3.4.1",
"vue": "^3.4.21"
},
"devDependencies": {
Expand All @@ -28,6 +28,7 @@
"eslint-plugin-tailwindcss": "^3.15.1",
"eslint-plugin-vue": "^9.23.0",
"postcss": "^8.4.31",
"tailwindcss": "^3.4.8",
JokeUrSelf marked this conversation as resolved.
Show resolved Hide resolved
"vite": "^5.2.6",
"vue-tsc": "^2.0.7"
}
Expand Down
Binary file added resources/assets/header-logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
80 changes: 80 additions & 0 deletions resources/assets/logo-nowe.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 10 additions & 0 deletions resources/css/app.css
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
@tailwind base;
@tailwind components;
@tailwind utilities;

.v-enter-active,
.v-leave-active {
transition: opacity 0.3s ease;
}

.v-enter-from,
.v-leave-to {
opacity: 0;
}
JokeUrSelf marked this conversation as resolved.
Show resolved Hide resolved
JokeUrSelf marked this conversation as resolved.
Show resolved Hide resolved
21 changes: 21 additions & 0 deletions resources/js/Pages/Home.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<script lang="ts" setup>
import { ref, provide } from 'vue'
import Footer from '@/components/Home/Footer.vue'
import RegisterBanner from '@/components/Home/RegisterBanner.vue'
import GeneralSection from '@/components/Home/GeneralSection.vue'
import AuthSection from '@/components/Home/AuthSection.vue'
import BackgroundEffect from '@/components/Home/BackgroundEffect.vue'

const isLogin = ref(null)
provide('isLoginRef', isLogin)
</script>

<template>
<BackgroundEffect />
<RegisterBanner :is-login="isLogin" />
<div class="flex flex-col lg:flex-row lg:justify-evenly lg:gap-x-[5vw] lg:px-[5vw]">
<GeneralSection />
<AuthSection ref="isLogin" />
</div>
<Footer />
</template>
22 changes: 22 additions & 0 deletions resources/js/components/Common/AuthButton.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<script setup lang="ts">

const props = defineProps<{isLogin: boolean}>()

const emit = defineEmits<(e: 'update:isLogin', value: boolean) => void>()

const handleCheckboxChange = () => {
emit('update:isLogin', !props.isLogin)
}
</script>

<template>
<label class="flex p-2 relative w-full cursor-pointer border-2 border-primary/30 rounded-xl bg-white/30">
<input type="checkbox" class="sr-only" @change="handleCheckboxChange">
<span
:class="{ 'translate-x-full' : props.isLogin}"
class="left-2 w-[calc(50%-.5rem)] absolute h-[calc(100%-1rem)] rounded-md bg-primary duration-200"
/>
<span :class="{ 'text-white': !props.isLogin}" class="z-10 w-full text-center duration-200 py-3 text-primary font-bold">Sign Up</span>
<span :class="{ 'text-white': props.isLogin }" class="z-10 w-full text-center duration-200 py-3 text-primary font-bold">Sign In</span>
</label>
</template>
23 changes: 23 additions & 0 deletions resources/js/components/Common/Checkbox.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<template>
<div class="inline-flex items-center">
<label class="relative flex items-center rounded-full cursor-pointer" htmlFor="checkbox">
<input
id="checkbox"
type="checkbox"
class="before:content[''] peer relative size-5 cursor-pointer appearance-none rounded-md border border-blue-gray-200 transition-all before:absolute before:top-2/4 before:left-2/4 before:block before:size-12 before:-translate-y-2/4 before:-translate-x-2/4 before:rounded-full before:bg-blue-gray-500 before:opacity-0 before:transition-opacity checked:border-primary checked:bg-primary checked:before:bg-primary hover:before:opacity-10" checked
>
<span
class="absolute text-white transition-opacity opacity-0 pointer-events-none top-2/4 left-2/4 -translate-y-2/4 -translate-x-2/4 peer-checked:opacity-100"
>
<svg xmlns="http://www.w3.org/2000/svg" class="size-3.5" viewBox="0 0 20 20" fill="currentColor"
stroke="currentColor" stroke-width="1"
>
<path fill-rule="evenodd"
d="M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z"
clip-rule="evenodd"
/>
</svg>
</span>
</label>
</div>
</template>
45 changes: 45 additions & 0 deletions resources/js/components/Home/AuthSection.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
<script setup lang="ts">
import { ref, defineExpose } from 'vue'
import AuthButton from '@/components/Common/AuthButton.vue'
import RegisterForm from '@/components/Home/RegisterForm.vue'
import LoginForm from '@/components/Home/LoginForm.vue'
const isLogin = ref(false)
defineExpose({ isLogin })
</script>

JokeUrSelf marked this conversation as resolved.
Show resolved Hide resolved

<template>
<section class="h-screen w-full flex flex-col items-center overflow-hidden backdrop-blur bg-white/30 lg:backdrop-blur-none lg:bg-transparent">
<div class="w-full flex flex-col gap-10 max-w-lg px-5 pt-20">
<AuthButton v-model:is-login="isLogin" />
<div class="grid">
<Transition :name="isLogin ? 'slide-right' : 'slide-left'">
<LoginForm v-if="isLogin" key="on" />
<RegisterForm v-else key="off" />
</Transition>
</div>
</div>
</section>
</template>

<style>
.slide-left-enter-active,
.slide-right-enter-active,
.slide-left-leave-active,
.slide-right-leave-active {
transition: all .3s;
transition-timing-function: cubic-bezier(0,.5,.5,1);
}

.slide-left-enter-from,
.slide-right-leave-to {
transform: translateX(-100%);
opacity: 0;
}

.slide-left-leave-to,
.slide-right-enter-from {
transform: translateX(100%);
opacity: 0;
}
</style>
27 changes: 27 additions & 0 deletions resources/js/components/Home/BackgroundEffect.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<script setup lang="ts">
import { ref, onMounted, onUnmounted } from 'vue'
const margin = ref(0)
function setBannerVisibility() {
const scrollHeight = window.document.documentElement.scrollHeight / 2
margin.value = window.scrollY / scrollHeight * 10
}
onMounted(() => window.addEventListener('scroll', setBannerVisibility))
onUnmounted(() => window.removeEventListener('scroll', setBannerVisibility))
</script>

<template>
<div :style="{marginTop: `${margin}rem`}" class="fixed blur-2xl size-7/12 -z-10">
<div class="
size-full
bg-gradient-to-r
from-[#ff80b5]
to-primary-600
opacity-30
" style="
clip-path: polygon(
75% 42%, 98% 74%, 100% 35%, 93% 0%, 86% 0%, 75% 27%, 59% 55%, 50% 57%, 47% 44%, 48% 17%, 25% 54%, 0% 28%, 12% 75%, 25% 54%, 67% 100%, 75% 42%
);"
/>
</div>
<div class="inset-0 top-16 h-[22rem] lg:top-0 bg-white/30 absolute -z-10" />
</template>
21 changes: 21 additions & 0 deletions resources/js/components/Home/Footer.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<template>
<footer class="bg-white shadow dark:bg-primary-950">
<div class="w-full mx-auto max-w-screen-xl p-4 md:flex md:items-center md:justify-between">
<span class="text-sm text-gray-500 sm:text-center dark:text-gray-200">© All rights reserved</span>
<ul class="flex flex-wrap items-center mt-3 text-sm font-medium text-gray-500 dark:text-gray-200 sm:mt-0">
<li>
<a href="#" class="hover:underline me-4 md:me-6">About</a>
</li>
<li>
<a href="#" class="hover:underline me-4 md:me-6">Privacy Policy</a>
</li>
<li>
<a href="#" class="hover:underline me-4 md:me-6">Licensing</a>
</li>
<li>
<a href="#" class="hover:underline">Contact</a>
</li>
</ul>
</div>
</footer>
</template>
29 changes: 29 additions & 0 deletions resources/js/components/Home/GeneralSection.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@

<script lang="ts" setup>
import InformationButton from '@/components/Home/InformationButton.vue'
</script>

<template>
<section class="w-full h-[calc(100vh-4rem)] lg:h-screen flex flex-col overflow-hidden">
<div data-name="left" class="flex flex-col justify-center w-full gap-10 p-10 pb-16">
<img class="h-40 object-contain" src="@/../assets/header-logo.png" alt="header logo">
<InformationButton />
</div>

<div data-name="right" class="flex flex-col size-full justify-center">
<h1 class="text-center text-[1.5rem] font-bold">SPONSORS</h1>
<div>
<div class="mx-auto max-w-7xl px-6 lg:px-8">
<h2 class="text-center text-lg font-semibold leading-8 text-gray-900">Trusted by the world’s most innovative teams</h2>
<div class="mx-auto mt-10 grid max-w-lg grid-cols-4 items-center gap-x-8 gap-y-10 sm:max-w-xl sm:grid-cols-6 sm:gap-x-10">
<img class="cursor-pointer duration-200 hover:scale-110 col-span-2 max-h-12 w-full object-contain" src="https://tailwindui.com/img/logos/158x48/transistor-logo-gray-900.svg" alt="Transistor" width="158" height="48">
<img class="cursor-pointer duration-200 hover:scale-110 col-span-2 max-h-12 w-full object-contain" src="https://tailwindui.com/img/logos/158x48/reform-logo-gray-900.svg" alt="Reform" width="158" height="48">
<img class="cursor-pointer duration-200 hover:scale-110 col-span-2 max-h-12 w-full object-contain" src="https://tailwindui.com/img/logos/158x48/tuple-logo-gray-900.svg" alt="Tuple" width="158" height="48">
<img class="cursor-pointer duration-200 hover:scale-110 col-span-2 max-h-12 w-full object-contain sm:col-start-2" src="https://tailwindui.com/img/logos/158x48/savvycal-logo-gray-900.svg" alt="SavvyCal" width="158" height="48">
<img class="cursor-pointer duration-200 hover:scale-110 col-span-2 col-start-2 max-h-12 w-full object-contain sm:col-start-auto" src="https://tailwindui.com/img/logos/158x48/statamic-logo-gray-900.svg" alt="Statamic" width="158" height="48">
</div>
</div>
</div>
</div>
</section>
</template>
17 changes: 17 additions & 0 deletions resources/js/components/Home/InformationButton.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<script setup lang="ts">
import InformationModalWindow from '@/components/Home/InformationModalWindow.vue'
import { ref } from 'vue'

const isInformationVisible = ref(false)
const setVisible = () => {
isInformationVisible.value = true
}
</script>

JokeUrSelf marked this conversation as resolved.
Show resolved Hide resolved

<template>
<div class="flex h-12 justify-center items-center">
<button class="text-primary text-[1.5rem] font-bold text-center hover:text-[1.75rem] duration-200" @click="setVisible">INFORMATION</button>
</div>
<InformationModalWindow v-model:is-visible="isInformationVisible" />
</template>
29 changes: 29 additions & 0 deletions resources/js/components/Home/InformationModalWindow.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<script setup lang="ts">
const props = defineProps<{ isVisible: boolean }>()
const emit = defineEmits<(e: 'update:isVisible', value: boolean) => void>()
function setHidden() {
emit('update:isVisible', false)
}
</script>

<template>
<Transition>
<div v-show="props.isVisible"
class="inset-0 h-screen w-full bg-black/15 backdrop-blur-md fixed z-20 p-5 flex justify-center items-center" @click="setHidden"
>
<div class="bg-white/85 backdrop-blur-md rounded-xl w-full flex flex-col max-w-2xl" @click.stop>
<h1 class="p-5 font-bold text-xl">Title</h1>
<hr>
<p class="p-5 text-[1.1rem]">
Lorem ipsum dolor sit amet consectetur adipisicing elit.
Esse corrupti provident voluptas ducimus neque libero reprehenderit eos voluptate quisquam minus.
Dolorum quos animi fugit blanditiis repellendus voluptas sequi ex ea.
</p>
<hr>
<div class="flex justify-end p-5">
<button class="font-bold text-primary" @click="setHidden">Return</button>
</div>
</div>
</div>
</Transition>
</template>
Loading
Loading