Skip to content

Commit 2968120

Browse files
committed
bit more theming
1 parent b693598 commit 2968120

8 files changed

Lines changed: 117 additions & 96 deletions

File tree

src/components/CommunitySection.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ import { MessageCircle } from 'lucide-vue-next'
3333
href="https://discord.gg/QcRRzXX"
3434
target="_blank"
3535
rel="noreferrer"
36-
class="group inline-flex items-center justify-center gap-2 rounded-xl bg-gradient-to-r from-brand-600 to-indigo-600 px-7 py-3.5 text-base font-semibold text-white shadow-lg shadow-brand-600/30 transition-all hover:-translate-y-0.5 hover:shadow-xl"
36+
class="group inline-flex items-center justify-center gap-2 rounded-xl bg-indigo-600 px-7 py-3.5 text-base font-semibold text-white shadow-lg shadow-indigo-600/30 transition-all hover:-translate-y-0.5 hover:shadow-xl"
3737
>
3838
<MessageCircle class="h-5 w-5" />
3939
Join the Community

src/components/FaqSection.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ import { faqs } from '../content.js'
3030
href="https://docs.waterdog.dev"
3131
target="_blank"
3232
rel="noreferrer"
33-
class="inline-flex items-center justify-center rounded-xl bg-gradient-to-r from-brand-500 to-indigo-500 px-8 py-3.5 text-base font-semibold text-white shadow-lg shadow-brand-500/30 transition-all hover:-translate-y-0.5 hover:shadow-xl"
33+
class="inline-flex items-center justify-center rounded-xl bg-indigo-500 px-8 py-3.5 text-base font-semibold text-white shadow-lg shadow-indigo-500/30 transition-all hover:-translate-y-0.5 hover:shadow-xl"
3434
>
3535
Documentation
3636
</a>

src/components/FeaturesSection.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ import { features } from '../content.js'
2828
class="pointer-events-none absolute -right-10 -top-10 h-32 w-32 rounded-full bg-brand-500/10 blur-2xl transition-opacity duration-300 group-hover:opacity-100 md:opacity-0"
2929
></div>
3030
<div
31-
class="inline-flex h-12 w-12 items-center justify-center rounded-xl bg-gradient-to-br from-brand-500 to-indigo-500 text-white shadow-lg shadow-brand-500/30"
31+
class="inline-flex h-12 w-12 items-center justify-center rounded-xl bg-gradient-to-br from-brand-500 to-deep-500 text-white shadow-lg shadow-brand-500/30"
3232
>
3333
<component :is="feature.icon" class="h-6 w-6" />
3434
</div>

src/components/HeroBackground.vue

Lines changed: 29 additions & 75 deletions
Original file line numberDiff line numberDiff line change
@@ -1,46 +1,34 @@
11
<script setup>
22
import { onMounted, onBeforeUnmount, ref } from 'vue'
33
4-
// Floating isometric voxel blocks — the unmistakable Minecraft cube.
5-
// Grass / dirt / stone / oak / diamond / gold drift slowly upward and wrap.
4+
// Underwater ambiance: a field of bubbles rising and gently wobbling.
65
// Pure canvas, no deps.
76
const canvas = ref(null)
87
let ctx = null
98
let rafId = 0
10-
let blocks = []
9+
let bubbles = []
1110
let width = 0
1211
let height = 0
1312
let dpr = 1
1413
let running = false
1514
16-
// top / left / right face shades per block type (Minecraft-ish palette)
17-
const PALETTES = [
18-
{ top: '#7bc043', left: '#9c6b43', right: '#7d5436' }, // grass
19-
{ top: '#9c6b43', left: '#825736', right: '#69472f' }, // dirt
20-
{ top: '#a8a8a8', left: '#8a8a8a', right: '#6f6f6f' }, // stone
21-
{ top: '#c2954f', left: '#a87c3d', right: '#8a6530' }, // oak planks
22-
{ top: '#5fd6cb', left: '#48b3ab', right: '#369089' }, // diamond
23-
{ top: '#f2cb4d', left: '#d4ab33', right: '#b08c24' }, // gold
24-
]
25-
2615
let seed = 7
2716
function rnd() {
2817
seed = (seed * 1664525 + 1013904223) % 4294967296
2918
return seed / 4294967296
3019
}
3120
32-
function makeBlock(initial) {
33-
const depth = 0.35 + rnd() * 0.65 // 0..1, drives size/speed/opacity (parallax)
21+
function makeBubble(initial) {
22+
const depth = rnd()
3423
return {
3524
x: rnd() * width,
36-
y: initial ? rnd() * height : height + 60,
37-
size: 12 + depth * 30,
38-
speed: 8 + depth * 22, // px per second, upward
39-
drift: (rnd() - 0.5) * 0.6, // gentle horizontal sway amount
25+
y: initial ? rnd() * height : height + 20,
26+
r: 1.5 + depth * 5,
27+
speed: 25 + depth * 55, // px per second, rising
28+
drift: (rnd() - 0.5) * 0.8,
4029
phase: rnd() * Math.PI * 2,
41-
spin: 0.3 + rnd() * 0.5, // sway frequency
42-
opacity: 0.35 + depth * 0.45,
43-
palette: PALETTES[Math.floor(rnd() * PALETTES.length)],
30+
spin: 0.8 + rnd() * 1.2,
31+
opacity: 0.12 + depth * 0.28,
4432
}
4533
}
4634
@@ -54,59 +42,28 @@ function resize() {
5442
canvas.value.height = height * dpr
5543
ctx.setTransform(dpr, 0, 0, dpr, 0, 0)
5644
57-
const target = Math.min(20, Math.max(10, Math.round((width * height) / 42000)))
58-
if (blocks.length < target) {
59-
for (let i = blocks.length; i < target; i++) blocks.push(makeBlock(true))
45+
const target = Math.min(46, Math.max(16, Math.round((width * height) / 20000)))
46+
if (bubbles.length < target) {
47+
for (let i = bubbles.length; i < target; i++) bubbles.push(makeBubble(true))
6048
} else {
61-
blocks.length = target
49+
bubbles.length = target
6250
}
63-
// keep painter's order: far (small) drawn first
64-
blocks.sort((a, b) => a.size - b.size)
6551
}
6652
67-
function drawCube(cx, cy, s, pal, opacity) {
68-
const a = s // horizontal half-width
69-
const b = s / 2 // vertical half of top diamond
70-
const vh = s // vertical edge length
71-
53+
function drawBubble(cx, cy, r, opacity) {
7254
ctx.globalAlpha = opacity
73-
ctx.lineJoin = 'round'
74-
ctx.strokeStyle = 'rgba(0,0,0,0.25)'
75-
ctx.lineWidth = 1
76-
77-
// top face (diamond)
78-
ctx.beginPath()
79-
ctx.moveTo(cx, cy)
80-
ctx.lineTo(cx + a, cy + b)
81-
ctx.lineTo(cx, cy + 2 * b)
82-
ctx.lineTo(cx - a, cy + b)
83-
ctx.closePath()
84-
ctx.fillStyle = pal.top
85-
ctx.fill()
86-
ctx.stroke()
87-
88-
// left face
8955
ctx.beginPath()
90-
ctx.moveTo(cx - a, cy + b)
91-
ctx.lineTo(cx, cy + 2 * b)
92-
ctx.lineTo(cx, cy + 2 * b + vh)
93-
ctx.lineTo(cx - a, cy + b + vh)
94-
ctx.closePath()
95-
ctx.fillStyle = pal.left
56+
ctx.arc(cx, cy, r, 0, Math.PI * 2)
57+
ctx.fillStyle = 'rgba(220, 245, 255, 0.35)'
9658
ctx.fill()
59+
ctx.lineWidth = 1
60+
ctx.strokeStyle = 'rgba(190, 235, 255, 0.7)'
9761
ctx.stroke()
98-
99-
// right face
62+
// little highlight
10063
ctx.beginPath()
101-
ctx.moveTo(cx + a, cy + b)
102-
ctx.lineTo(cx, cy + 2 * b)
103-
ctx.lineTo(cx, cy + 2 * b + vh)
104-
ctx.lineTo(cx + a, cy + b + vh)
105-
ctx.closePath()
106-
ctx.fillStyle = pal.right
64+
ctx.arc(cx - r * 0.3, cy - r * 0.3, Math.max(0.6, r * 0.28), 0, Math.PI * 2)
65+
ctx.fillStyle = 'rgba(255, 255, 255, 0.8)'
10766
ctx.fill()
108-
ctx.stroke()
109-
11067
ctx.globalAlpha = 1
11168
}
11269
@@ -118,15 +75,12 @@ function step(ts) {
11875
11976
ctx.clearRect(0, 0, width, height)
12077
121-
for (const blk of blocks) {
122-
blk.y -= blk.speed * dt
123-
blk.phase += blk.spin * dt
124-
const sway = Math.sin(blk.phase) * blk.drift * 20
125-
if (blk.y + blk.size * 2 < -20) {
126-
// recycle from the bottom
127-
Object.assign(blk, makeBlock(false))
128-
}
129-
drawCube(blk.x + sway, blk.y, blk.size, blk.palette, blk.opacity)
78+
for (const bub of bubbles) {
79+
bub.y -= bub.speed * dt
80+
bub.phase += bub.spin * dt
81+
if (bub.y + bub.r * 2 < -20) Object.assign(bub, makeBubble(false))
82+
const sway = Math.sin(bub.phase) * bub.drift * 14
83+
drawBubble(bub.x + sway, bub.y, bub.r, bub.opacity)
13084
}
13185
13286
rafId = requestAnimationFrame(step)
@@ -146,7 +100,7 @@ function stop() {
146100
147101
function drawStatic() {
148102
ctx.clearRect(0, 0, width, height)
149-
for (const blk of blocks) drawCube(blk.x, blk.y, blk.size, blk.palette, blk.opacity)
103+
for (const bub of bubbles) drawBubble(bub.x, bub.y, bub.r, bub.opacity)
150104
}
151105
152106
let onResize = null

src/components/HeroSection.vue

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
<script setup>
22
import { ArrowRight, Github } from 'lucide-vue-next'
33
import HeroBackground from './HeroBackground.vue'
4+
import WaveDivider from './WaveDivider.vue'
45
</script>
56

67
<template>
@@ -16,7 +17,7 @@ import HeroBackground from './HeroBackground.vue'
1617
<div class="absolute inset-0 bg-slate-950/40"></div>
1718
</div>
1819

19-
<!-- Floating Minecraft voxel blocks -->
20+
<!-- Rising bubbles -->
2021
<HeroBackground class="opacity-90" />
2122

2223
<!-- Drifting aurora glows -->
@@ -28,7 +29,7 @@ import HeroBackground from './HeroBackground.vue'
2829
class="absolute -right-20 bottom-0 h-96 w-96 rounded-full bg-cyan-400/20 blur-3xl motion-safe:animate-aurora-slower"
2930
></div>
3031
<div
31-
class="absolute left-1/2 top-1/3 h-72 w-72 -translate-x-1/2 rounded-full bg-indigo-500/20 blur-3xl motion-safe:animate-aurora-slow"
32+
class="absolute left-1/2 top-1/3 h-72 w-72 -translate-x-1/2 rounded-full bg-deep-500/20 blur-3xl motion-safe:animate-aurora-slow"
3233
></div>
3334
</div>
3435

@@ -54,7 +55,7 @@ import HeroBackground from './HeroBackground.vue'
5455
<h1 v-reveal:80 class="text-4xl font-extrabold tracking-tight text-white sm:text-5xl lg:text-6xl">
5556
<span class="block drop-shadow-[0_2px_20px_rgba(15,23,42,0.6)]">Powerful, Efficient &amp; Extendable</span>
5657
<span
57-
class="block bg-[length:200%_auto] bg-gradient-to-r from-brand-300 via-cyan-300 to-brand-300 bg-clip-text text-transparent motion-safe:animate-shimmer"
58+
class="block bg-gradient-to-r from-cyan-200 to-brand-300 bg-clip-text text-transparent"
5859
>
5960
Minecraft Bedrock Proxy
6061
</span>
@@ -67,7 +68,7 @@ import HeroBackground from './HeroBackground.vue'
6768
<div v-reveal:240 class="mt-10 flex flex-col items-center justify-center gap-4 sm:flex-row">
6869
<a
6970
href="https://docs.waterdog.dev/books/waterdogpe-setup/page/starting-waterdog"
70-
class="group inline-flex w-full items-center justify-center gap-2 rounded-xl bg-gradient-to-r from-brand-500 to-indigo-500 px-8 py-3.5 text-base font-semibold text-white shadow-lg shadow-brand-500/30 transition-all hover:shadow-xl hover:shadow-brand-500/40 hover:-translate-y-0.5 sm:w-auto"
71+
class="group inline-flex w-full items-center justify-center gap-2 rounded-xl bg-indigo-500 px-8 py-3.5 text-base font-semibold text-white shadow-lg shadow-indigo-500/30 transition-all hover:shadow-xl hover:shadow-indigo-500/40 hover:-translate-y-0.5 sm:w-auto"
7172
>
7273
Get started
7374
<ArrowRight class="h-5 w-5 transition-transform group-hover:translate-x-1" />
@@ -85,7 +86,7 @@ import HeroBackground from './HeroBackground.vue'
8586
</div>
8687
</div>
8788

88-
<!-- Fade into the next section -->
89-
<div class="pointer-events-none absolute inset-x-0 bottom-0 h-24 bg-gradient-to-b from-transparent to-slate-50 dark:to-slate-900"></div>
89+
<!-- Animated water surface flowing into the next section -->
90+
<WaveDivider class="absolute inset-x-0 bottom-0 z-10 text-slate-50 dark:text-slate-900" />
9091
</section>
9192
</template>

src/components/PatreonSection.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { Heart } from 'lucide-vue-next'
77
<div class="mx-auto max-w-4xl px-4 sm:px-6 lg:px-8">
88
<div
99
v-reveal
10-
class="relative overflow-hidden rounded-3xl bg-gradient-to-br from-brand-600 to-indigo-700 px-6 py-16 text-center shadow-2xl shadow-brand-600/30 sm:px-12"
10+
class="relative overflow-hidden rounded-3xl bg-gradient-to-br from-brand-600 to-deep-700 px-6 py-16 text-center shadow-2xl shadow-brand-600/30 sm:px-12"
1111
>
1212
<div class="pointer-events-none absolute -right-10 -top-10 h-48 w-48 rounded-full bg-white/10 blur-2xl"></div>
1313
<div class="pointer-events-none absolute -bottom-12 -left-8 h-48 w-48 rounded-full bg-cyan-300/20 blur-2xl"></div>
@@ -24,7 +24,7 @@ import { Heart } from 'lucide-vue-next'
2424
href="https://www.patreon.com/waterdog"
2525
target="_blank"
2626
rel="noreferrer"
27-
class="relative mt-8 inline-flex items-center justify-center gap-2 rounded-xl bg-white px-8 py-3.5 text-base font-semibold text-brand-700 shadow-lg transition-all hover:-translate-y-0.5 hover:bg-brand-50"
27+
class="relative mt-8 inline-flex items-center justify-center gap-2 rounded-xl bg-white px-8 py-3.5 text-base font-semibold text-indigo-700 shadow-lg transition-all hover:-translate-y-0.5 hover:bg-indigo-50"
2828
>
2929
<Heart class="h-5 w-5" />
3030
Become a patreon

src/components/WaveDivider.vue

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
<script setup>
2+
// Animated layered water waves. Color follows the parent's text color
3+
// (use text-* utilities) so it can flow into whatever section sits below.
4+
// Set `flip` to mirror it (waves hanging from the top of a section).
5+
defineProps({
6+
flip: { type: Boolean, default: false },
7+
})
8+
</script>
9+
10+
<template>
11+
<div
12+
class="pointer-events-none relative h-12 w-full overflow-hidden sm:h-20"
13+
:class="flip ? 'rotate-180' : ''"
14+
aria-hidden="true"
15+
>
16+
<!-- back wave (slower, translucent) -->
17+
<div class="absolute inset-0 flex w-[200%] motion-safe:animate-wave-slow">
18+
<svg class="h-full w-1/2 shrink-0" viewBox="0 0 1440 100" preserveAspectRatio="none">
19+
<path
20+
fill="currentColor"
21+
fill-opacity="0.45"
22+
d="M0,45 C300,85 600,5 900,45 C1140,77 1320,20 1440,45 L1440,100 L0,100 Z"
23+
/>
24+
</svg>
25+
<svg class="h-full w-1/2 shrink-0" viewBox="0 0 1440 100" preserveAspectRatio="none">
26+
<path
27+
fill="currentColor"
28+
fill-opacity="0.45"
29+
d="M0,45 C300,85 600,5 900,45 C1140,77 1320,20 1440,45 L1440,100 L0,100 Z"
30+
/>
31+
</svg>
32+
</div>
33+
34+
<!-- front wave (faster, solid) -->
35+
<div class="absolute inset-0 flex w-[200%] motion-safe:animate-wave-fast">
36+
<svg class="h-full w-1/2 shrink-0" viewBox="0 0 1440 100" preserveAspectRatio="none">
37+
<path
38+
fill="currentColor"
39+
d="M0,55 C240,90 480,15 720,55 C960,95 1200,15 1440,55 L1440,100 L0,100 Z"
40+
/>
41+
</svg>
42+
<svg class="h-full w-1/2 shrink-0" viewBox="0 0 1440 100" preserveAspectRatio="none">
43+
<path
44+
fill="currentColor"
45+
d="M0,55 C240,90 480,15 720,55 C960,95 1200,15 1440,55 L1440,100 L0,100 Z"
46+
/>
47+
</svg>
48+
</div>
49+
</div>
50+
</template>

tailwind.config.js

Lines changed: 26 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,27 @@ export default {
55
theme: {
66
extend: {
77
colors: {
8+
// "brand" = Waterdog water blue (ocean cyan/azure ramp)
89
brand: {
9-
50: '#eef2ff',
10-
100: '#e0e7ff',
11-
200: '#c7d2fe',
12-
300: '#a5b4fc',
13-
400: '#818cf8',
14-
500: '#6366f1',
15-
600: '#4f46e5',
16-
700: '#4338ca',
17-
800: '#3730a3',
18-
900: '#312e81',
10+
50: '#ecfdff',
11+
100: '#cef6fd',
12+
200: '#a3ecfa',
13+
300: '#67ddf4',
14+
400: '#28c3e8',
15+
500: '#0ba6ce',
16+
600: '#0a85ad',
17+
700: '#0e6a8c',
18+
800: '#155874',
19+
900: '#164a63',
20+
},
21+
// deep-water companion used for gradient ends and depth
22+
deep: {
23+
400: '#3b82f6',
24+
500: '#2563eb',
25+
600: '#1d4ed8',
26+
700: '#1e40af',
27+
800: '#1e3a8a',
28+
900: '#172554',
1929
},
2030
},
2131
fontFamily: {
@@ -52,6 +62,10 @@ export default {
5262
'0%': { transform: 'scale(1) translate(0, 0)' },
5363
'100%': { transform: 'scale(1.12) translate(-1.5%, -1.5%)' },
5464
},
65+
'wave-x': {
66+
'0%': { transform: 'translateX(0)' },
67+
'100%': { transform: 'translateX(-50%)' },
68+
},
5569
},
5670
animation: {
5771
'fade-up': 'fade-up 0.7s ease-out both',
@@ -60,6 +74,8 @@ export default {
6074
'aurora-slower': 'aurora 26s ease-in-out infinite',
6175
shimmer: 'shimmer 6s linear infinite',
6276
kenburns: 'kenburns 24s ease-out infinite alternate',
77+
'wave-slow': 'wave-x 18s linear infinite',
78+
'wave-fast': 'wave-x 11s linear infinite',
6379
},
6480
},
6581
},

0 commit comments

Comments
 (0)