Skip to content

Commit

Permalink
feat: modularize Hero section into a Hero.vue component
Browse files Browse the repository at this point in the history
  • Loading branch information
aekasitt committed Aug 11, 2024
1 parent 3f515f4 commit 6fa3d22
Show file tree
Hide file tree
Showing 4 changed files with 55 additions and 47 deletions.
48 changes: 2 additions & 46 deletions src/App.vue
Original file line number Diff line number Diff line change
@@ -1,54 +1,10 @@
<script lang="ts" setup>
/* components */
import { Button } from '@/components/ui/button'
import { HeroCards, Navbar, Sponsors } from '@/components'
/* vectors */
import { Github } from 'lucide-vue-next'
import KruttCrest from '@/assets/krutt.svg'
/* functions */
let openGitHub = () => window.open('https://github.com/krutt', '_blank', 'noreferrer, noopener')
import { Hero, Navbar, Sponsors } from '@/components'
</script>

<template>
<Navbar />
<section class="container grid lg:grid-cols-2 place-items-center py-20 md:py-32 gap-10">
<div class="text-center lg:text-start space-y-6">
<main class="text-5xl md:text-6xl font-bold">
<h1 class="inline">
<span
class="dark:drop-shadow-[0_1.2px_1.2px_rgba(255,255,255,0.6)] inline bg-gradient-to-r from-[#7B6A4B] via-[#B39F7B] to-[#7B6A4B] text-transparent bg-clip-text"
>
Krutt
</span>
brings Bitcoin to the mass
</h1>
with
<h2 class="inline">
<span
class="inline bg-gradient-to-r from-[#EB5E28] via-[#FCA311] to-[#BC13FE] text-transparent bg-clip-text"
>
Lightning &amp; Nostr
</span>
liquidity unlocks.
</h2>
</main>

<p class="text-xl text-muted-foreground md:w-10/12 mx-auto lg:mx-0">
Commited to open-sourcing no second best. Krutt is ahead of its peers sharing these
following projects:
</p>

<div class="space-y-4 md:space-y-0 md:space-x-4">
<Button class="w-full md:w-1/3">Get Started</Button>
<Button @click.prevent="openGitHub" class="w-full md:w-1/3" variant="outline">
Github Profile
<Github class="inline ml-2 w-5 h-5" />
</Button>
</div>
</div>
<HeroCards class="w-full" />
</section>
<Hero />
<Sponsors />
</template>
51 changes: 51 additions & 0 deletions src/components/Hero.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
<script lang="ts" setup>
/* components */
import { Button } from '@/components/ui/button'
import { HeroCards } from '@/components'
/* vectors */
import { Github } from 'lucide-vue-next'
/* functions */
let openGitHub = () => window.open('https://github.com/krutt', '_blank', 'noreferrer, noopener')
</script>

<template>
<section class="container grid lg:grid-cols-2 place-items-center py-20 md:py-32 gap-10">
<div class="text-center lg:text-start space-y-6">
<main class="text-5xl md:text-6xl font-bold">
<h1 class="inline">
<span
class="dark:drop-shadow-[0_1.2px_1.2px_rgba(255,255,255,0.6)] inline bg-gradient-to-r from-[#7B6A4B] via-[#B39F7B] to-[#7B6A4B] text-transparent bg-clip-text"
>
Krutt
</span>
brings Bitcoin to the mass
</h1>
with
<h2 class="inline">
<span
class="inline bg-gradient-to-r from-[#EB5E28] via-[#FCA311] to-[#BC13FE] text-transparent bg-clip-text"
>
Lightning &amp; Nostr
</span>
liquidity unlocks.
</h2>
</main>

<p class="text-xl text-muted-foreground md:w-10/12 mx-auto lg:mx-0">
Commited to open-sourcing no second best. Krutt is ahead of its peers sharing these
following projects:
</p>

<div class="space-y-4 md:space-y-0 md:space-x-4">
<Button class="w-full md:w-1/3">Get Started</Button>
<Button @click.prevent="openGitHub" class="w-full md:w-1/3" variant="outline">
Github Profile
<Github class="inline ml-2 w-5 h-5" />
</Button>
</div>
</div>
<HeroCards class="w-full" />
</section>
</template>
2 changes: 1 addition & 1 deletion src/components/HeroCards.vue
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ let gitHubTayanPage = () => {
<Badge variant="secondary"> JavaScript </Badge>
<Badge variant="secondary"> Statechain </Badge>
<Badge class="bg-gradient-to-r from-[#EB5E28] to-[#FCA311] via-[#EB5E28]">
Alpha
Alpha
</Badge>
</p>
</CardDescription>
Expand Down
1 change: 1 addition & 0 deletions src/components/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/* ~~/src/components/index.js */

export { default as Hero } from './Hero.vue'
export { default as HeroCards } from './HeroCards.vue'
export { default as Navbar } from './Navbar.vue'
export { default as Sponsors } from './Sponsors.vue'
Expand Down

0 comments on commit 6fa3d22

Please sign in to comment.