From cca7df3fb110d14f0eae03afe4d2fc94d71869dc Mon Sep 17 00:00:00 2001 From: Skeptic-systems Date: Fri, 26 Dec 2025 17:45:13 +0100 Subject: [PATCH] chore: update project configuration and add new components - Added .dockerignore and updated .biomeignore to exclude build artifacts. - Introduced compose.yml for Docker configuration. - Enhanced biome.json with additional ignore patterns. - Created new components for the UI, including layout, buttons, and forms. - Added global styles and utility functions for better styling management. - Implemented hooks for language and theme management. - Included translations for multi-language support. - Added various assets for branding and UI elements. --- .biomeignore | 3 + .dockerignore | 13 + CODE_OF_CONDUCT.md | 2 + CONTRIBUTING.md | 2 + LICENSE | 2 + SECURITY.md | 2 + apps/www/.biomeignore | 6 + apps/www/.gitignore | 37 +- apps/www/app/globals.css | 128 + apps/www/app/layout.tsx | 47 + apps/www/app/page.tsx | 21 + apps/www/components.json | 21 + apps/www/components/download-section.tsx | 201 ++ apps/www/components/features-section.tsx | 85 + apps/www/components/footer.tsx | 123 + apps/www/components/header.tsx | 127 + apps/www/components/hero-section.tsx | 69 + apps/www/components/open-source-section.tsx | 94 + apps/www/components/theme-provider.tsx | 7 + apps/www/components/ui/accordion.tsx | 66 + apps/www/components/ui/alert-dialog.tsx | 157 + apps/www/components/ui/alert.tsx | 66 + apps/www/components/ui/aspect-ratio.tsx | 11 + apps/www/components/ui/avatar.tsx | 53 + apps/www/components/ui/badge.tsx | 46 + apps/www/components/ui/breadcrumb.tsx | 109 + apps/www/components/ui/button-group.tsx | 83 + apps/www/components/ui/button.tsx | 60 + apps/www/components/ui/calendar.tsx | 213 ++ apps/www/components/ui/card.tsx | 92 + apps/www/components/ui/carousel.tsx | 241 ++ apps/www/components/ui/chart.tsx | 353 +++ apps/www/components/ui/checkbox.tsx | 32 + apps/www/components/ui/collapsible.tsx | 33 + apps/www/components/ui/command.tsx | 184 ++ apps/www/components/ui/context-menu.tsx | 252 ++ apps/www/components/ui/dialog.tsx | 143 + apps/www/components/ui/drawer.tsx | 135 + apps/www/components/ui/dropdown-menu.tsx | 257 ++ apps/www/components/ui/empty.tsx | 104 + apps/www/components/ui/field.tsx | 244 ++ apps/www/components/ui/form.tsx | 167 ++ apps/www/components/ui/hover-card.tsx | 44 + apps/www/components/ui/input-group.tsx | 169 ++ apps/www/components/ui/input-otp.tsx | 77 + apps/www/components/ui/input.tsx | 21 + apps/www/components/ui/item.tsx | 193 ++ apps/www/components/ui/kbd.tsx | 28 + apps/www/components/ui/label.tsx | 24 + apps/www/components/ui/menubar.tsx | 276 ++ apps/www/components/ui/navigation-menu.tsx | 166 ++ apps/www/components/ui/pagination.tsx | 127 + apps/www/components/ui/popover.tsx | 48 + apps/www/components/ui/progress.tsx | 31 + apps/www/components/ui/radio-group.tsx | 45 + apps/www/components/ui/resizable.tsx | 56 + apps/www/components/ui/scroll-area.tsx | 58 + apps/www/components/ui/select.tsx | 185 ++ apps/www/components/ui/separator.tsx | 28 + apps/www/components/ui/sheet.tsx | 139 + apps/www/components/ui/sidebar.tsx | 726 +++++ apps/www/components/ui/skeleton.tsx | 13 + apps/www/components/ui/slider.tsx | 63 + apps/www/components/ui/sonner.tsx | 25 + apps/www/components/ui/spinner.tsx | 16 + apps/www/components/ui/switch.tsx | 31 + apps/www/components/ui/table.tsx | 116 + apps/www/components/ui/tabs.tsx | 66 + apps/www/components/ui/textarea.tsx | 18 + apps/www/components/ui/toast.tsx | 129 + apps/www/components/ui/toaster.tsx | 35 + apps/www/components/ui/toggle-group.tsx | 73 + apps/www/components/ui/toggle.tsx | 47 + apps/www/components/ui/tooltip.tsx | 61 + apps/www/components/ui/use-mobile.tsx | 19 + apps/www/components/ui/use-toast.ts | 191 ++ apps/www/dockerfile | 49 + apps/www/hooks/use-language.tsx | 28 + apps/www/hooks/use-mobile.ts | 19 + apps/www/hooks/use-theme.tsx | 25 + apps/www/hooks/use-toast.ts | 189 ++ apps/www/lib/translations.ts | 171 ++ apps/www/lib/utils.ts | 6 + apps/www/next-env.d.ts | 4 +- apps/www/next.config.mjs | 12 + apps/www/next.config.ts | 5 - apps/www/package.json | 74 +- apps/www/postcss.config.mjs | 8 + apps/www/public/apple-icon.png | Bin 0 -> 2626 bytes apps/www/public/icon-dark-32x32.png | Bin 0 -> 585 bytes apps/www/public/icon-light-32x32.png | Bin 0 -> 566 bytes apps/www/public/icon.svg | 26 + apps/www/public/placeholder-logo.png | Bin 0 -> 568 bytes apps/www/public/placeholder-logo.svg | 1 + apps/www/public/placeholder-user.jpg | Bin 0 -> 1635 bytes apps/www/public/placeholder.jpg | Bin 0 -> 1064 bytes apps/www/public/placeholder.svg | 1 + apps/www/public/robots.txt | 4 - apps/www/styles/globals.css | 125 + apps/www/tsconfig.json | 30 +- apps/www/vite.config.ts | 6 - biome.json | 7 + compose.yml | 13 + pnpm-lock.yaml | 2873 +++++++++++++++++-- 104 files changed, 10820 insertions(+), 291 deletions(-) create mode 100644 .dockerignore create mode 100644 apps/www/.biomeignore create mode 100644 apps/www/app/globals.css create mode 100644 apps/www/app/layout.tsx create mode 100644 apps/www/app/page.tsx create mode 100644 apps/www/components.json create mode 100644 apps/www/components/download-section.tsx create mode 100644 apps/www/components/features-section.tsx create mode 100644 apps/www/components/footer.tsx create mode 100644 apps/www/components/header.tsx create mode 100644 apps/www/components/hero-section.tsx create mode 100644 apps/www/components/open-source-section.tsx create mode 100644 apps/www/components/theme-provider.tsx create mode 100644 apps/www/components/ui/accordion.tsx create mode 100644 apps/www/components/ui/alert-dialog.tsx create mode 100644 apps/www/components/ui/alert.tsx create mode 100644 apps/www/components/ui/aspect-ratio.tsx create mode 100644 apps/www/components/ui/avatar.tsx create mode 100644 apps/www/components/ui/badge.tsx create mode 100644 apps/www/components/ui/breadcrumb.tsx create mode 100644 apps/www/components/ui/button-group.tsx create mode 100644 apps/www/components/ui/button.tsx create mode 100644 apps/www/components/ui/calendar.tsx create mode 100644 apps/www/components/ui/card.tsx create mode 100644 apps/www/components/ui/carousel.tsx create mode 100644 apps/www/components/ui/chart.tsx create mode 100644 apps/www/components/ui/checkbox.tsx create mode 100644 apps/www/components/ui/collapsible.tsx create mode 100644 apps/www/components/ui/command.tsx create mode 100644 apps/www/components/ui/context-menu.tsx create mode 100644 apps/www/components/ui/dialog.tsx create mode 100644 apps/www/components/ui/drawer.tsx create mode 100644 apps/www/components/ui/dropdown-menu.tsx create mode 100644 apps/www/components/ui/empty.tsx create mode 100644 apps/www/components/ui/field.tsx create mode 100644 apps/www/components/ui/form.tsx create mode 100644 apps/www/components/ui/hover-card.tsx create mode 100644 apps/www/components/ui/input-group.tsx create mode 100644 apps/www/components/ui/input-otp.tsx create mode 100644 apps/www/components/ui/input.tsx create mode 100644 apps/www/components/ui/item.tsx create mode 100644 apps/www/components/ui/kbd.tsx create mode 100644 apps/www/components/ui/label.tsx create mode 100644 apps/www/components/ui/menubar.tsx create mode 100644 apps/www/components/ui/navigation-menu.tsx create mode 100644 apps/www/components/ui/pagination.tsx create mode 100644 apps/www/components/ui/popover.tsx create mode 100644 apps/www/components/ui/progress.tsx create mode 100644 apps/www/components/ui/radio-group.tsx create mode 100644 apps/www/components/ui/resizable.tsx create mode 100644 apps/www/components/ui/scroll-area.tsx create mode 100644 apps/www/components/ui/select.tsx create mode 100644 apps/www/components/ui/separator.tsx create mode 100644 apps/www/components/ui/sheet.tsx create mode 100644 apps/www/components/ui/sidebar.tsx create mode 100644 apps/www/components/ui/skeleton.tsx create mode 100644 apps/www/components/ui/slider.tsx create mode 100644 apps/www/components/ui/sonner.tsx create mode 100644 apps/www/components/ui/spinner.tsx create mode 100644 apps/www/components/ui/switch.tsx create mode 100644 apps/www/components/ui/table.tsx create mode 100644 apps/www/components/ui/tabs.tsx create mode 100644 apps/www/components/ui/textarea.tsx create mode 100644 apps/www/components/ui/toast.tsx create mode 100644 apps/www/components/ui/toaster.tsx create mode 100644 apps/www/components/ui/toggle-group.tsx create mode 100644 apps/www/components/ui/toggle.tsx create mode 100644 apps/www/components/ui/tooltip.tsx create mode 100644 apps/www/components/ui/use-mobile.tsx create mode 100644 apps/www/components/ui/use-toast.ts create mode 100644 apps/www/dockerfile create mode 100644 apps/www/hooks/use-language.tsx create mode 100644 apps/www/hooks/use-mobile.ts create mode 100644 apps/www/hooks/use-theme.tsx create mode 100644 apps/www/hooks/use-toast.ts create mode 100644 apps/www/lib/translations.ts create mode 100644 apps/www/lib/utils.ts create mode 100644 apps/www/next.config.mjs delete mode 100644 apps/www/next.config.ts create mode 100644 apps/www/postcss.config.mjs create mode 100644 apps/www/public/apple-icon.png create mode 100644 apps/www/public/icon-dark-32x32.png create mode 100644 apps/www/public/icon-light-32x32.png create mode 100644 apps/www/public/icon.svg create mode 100644 apps/www/public/placeholder-logo.png create mode 100644 apps/www/public/placeholder-logo.svg create mode 100644 apps/www/public/placeholder-user.jpg create mode 100644 apps/www/public/placeholder.jpg create mode 100644 apps/www/public/placeholder.svg delete mode 100644 apps/www/public/robots.txt create mode 100644 apps/www/styles/globals.css delete mode 100644 apps/www/vite.config.ts create mode 100644 compose.yml diff --git a/.biomeignore b/.biomeignore index ed5fb08..63e5820 100644 --- a/.biomeignore +++ b/.biomeignore @@ -2,7 +2,10 @@ node_modules dist build .turbo +.next +apps/*/.next apps/*/dist apps/*/build apps/*/src-tauri/target + diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..a7e6728 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,13 @@ +node_modules +.pnpm-store +.turbo +dist +build +tmp +apps/*/node_modules +apps/*/.next +apps/*/dist +apps/*/build +apps/*/src-tauri/target +.git + diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index e3bd216..e4efcd4 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -28,3 +28,5 @@ Report issues to the maintainers via GitHub issues or direct contact. All compla ## Attribution Adapted from the Contributor Covenant, version 2.1. + + diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index a3ae593..6f4ee26 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -24,3 +24,5 @@ Thank you for your interest in improving MiniFy. Please follow these guidelines - Be concise and respectful. - If something blocks you, describe what you tried and where you are stuck. + + diff --git a/LICENSE b/LICENSE index 7e87b5d..8e08ba7 100644 --- a/LICENSE +++ b/LICENSE @@ -20,3 +20,5 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + diff --git a/SECURITY.md b/SECURITY.md index 39171d8..e407343 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -12,3 +12,5 @@ - Do not test or exploit vulnerabilities in production environments you do not own. - Give us a reasonable time to investigate and fix before public disclosure. + + diff --git a/apps/www/.biomeignore b/apps/www/.biomeignore new file mode 100644 index 0000000..74823a9 --- /dev/null +++ b/apps/www/.biomeignore @@ -0,0 +1,6 @@ +.next +node_modules +dist +build +components/ui/** + diff --git a/apps/www/.gitignore b/apps/www/.gitignore index c2f4acf..f650315 100644 --- a/apps/www/.gitignore +++ b/apps/www/.gitignore @@ -1,20 +1,27 @@ -node_modules -.next -out -.turbo -.vercel -.cache -dist -coverage +# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. + +# dependencies +/node_modules + +# next.js +/.next/ +/out/ + +# production +/build + +# debug npm-debug.log* yarn-debug.log* yarn-error.log* -pnpm-debug.log* -.env -.env.* -!.env.example -*.local -*.DS_Store -Thumbs.db +.pnpm-debug.log* + +# env files +.env* +# vercel +.vercel +# typescript +*.tsbuildinfo +next-env.d.ts \ No newline at end of file diff --git a/apps/www/app/globals.css b/apps/www/app/globals.css new file mode 100644 index 0000000..19baf98 --- /dev/null +++ b/apps/www/app/globals.css @@ -0,0 +1,128 @@ +@import "tailwindcss"; +@import "tw-animate-css"; + +@custom-variant dark (&:is(.dark *)); + +:root { + --background: oklch(1 0 0); + --foreground: oklch(0.145 0 0); + --card: oklch(1 0 0); + --card-foreground: oklch(0.145 0 0); + --popover: oklch(1 0 0); + --popover-foreground: oklch(0.145 0 0); + --primary: oklch(0.205 0 0); + --primary-foreground: oklch(0.985 0 0); + --secondary: oklch(0.97 0 0); + --secondary-foreground: oklch(0.205 0 0); + --muted: oklch(0.97 0 0); + --muted-foreground: oklch(0.556 0 0); + --accent: oklch(0.97 0 0); + --accent-foreground: oklch(0.205 0 0); + --destructive: oklch(0.577 0.245 27.325); + --destructive-foreground: oklch(0.577 0.245 27.325); + --border: oklch(0.922 0 0); + --input: oklch(0.922 0 0); + --ring: oklch(0.708 0 0); + --chart-1: oklch(0.646 0.222 41.116); + --chart-2: oklch(0.6 0.118 184.704); + --chart-3: oklch(0.398 0.07 227.392); + --chart-4: oklch(0.828 0.189 84.429); + --chart-5: oklch(0.769 0.188 70.08); + --radius: 0.625rem; + --sidebar: oklch(0.985 0 0); + --sidebar-foreground: oklch(0.145 0 0); + --sidebar-primary: oklch(0.205 0 0); + --sidebar-primary-foreground: oklch(0.985 0 0); + --sidebar-accent: oklch(0.97 0 0); + --sidebar-accent-foreground: oklch(0.205 0 0); + --sidebar-border: oklch(0.922 0 0); + --sidebar-ring: oklch(0.708 0 0); +} + +.dark { + --background: oklch(0.145 0 0); + --foreground: oklch(0.985 0 0); + --card: oklch(0.145 0 0); + --card-foreground: oklch(0.985 0 0); + --popover: oklch(0.145 0 0); + --popover-foreground: oklch(0.985 0 0); + --primary: oklch(0.985 0 0); + --primary-foreground: oklch(0.205 0 0); + --secondary: oklch(0.269 0 0); + --secondary-foreground: oklch(0.985 0 0); + --muted: oklch(0.269 0 0); + --muted-foreground: oklch(0.708 0 0); + --accent: oklch(0.269 0 0); + --accent-foreground: oklch(0.985 0 0); + --destructive: oklch(0.396 0.141 25.723); + --destructive-foreground: oklch(0.637 0.237 25.331); + --border: oklch(0.269 0 0); + --input: oklch(0.269 0 0); + --ring: oklch(0.439 0 0); + --chart-1: oklch(0.488 0.243 264.376); + --chart-2: oklch(0.696 0.17 162.48); + --chart-3: oklch(0.769 0.188 70.08); + --chart-4: oklch(0.627 0.265 303.9); + --chart-5: oklch(0.645 0.246 16.439); + --sidebar: oklch(0.205 0 0); + --sidebar-foreground: oklch(0.985 0 0); + --sidebar-primary: oklch(0.488 0.243 264.376); + --sidebar-primary-foreground: oklch(0.985 0 0); + --sidebar-accent: oklch(0.269 0 0); + --sidebar-accent-foreground: oklch(0.985 0 0); + --sidebar-border: oklch(0.269 0 0); + --sidebar-ring: oklch(0.439 0 0); +} + +@theme inline { + /* optional: --font-sans, --font-serif, --font-mono if they are applied in the layout.tsx */ + --color-background: var(--background); + --color-foreground: var(--foreground); + --color-card: var(--card); + --color-card-foreground: var(--card-foreground); + --color-popover: var(--popover); + --color-popover-foreground: var(--popover-foreground); + --color-primary: var(--primary); + --color-primary-foreground: var(--primary-foreground); + --color-secondary: var(--secondary); + --color-secondary-foreground: var(--secondary-foreground); + --color-muted: var(--muted); + --color-muted-foreground: var(--muted-foreground); + --color-accent: var(--accent); + --color-accent-foreground: var(--accent-foreground); + --color-destructive: var(--destructive); + --color-destructive-foreground: var(--destructive-foreground); + --color-border: var(--border); + --color-input: var(--input); + --color-ring: var(--ring); + --color-chart-1: var(--chart-1); + --color-chart-2: var(--chart-2); + --color-chart-3: var(--chart-3); + --color-chart-4: var(--chart-4); + --color-chart-5: var(--chart-5); + --radius-sm: calc(var(--radius) - 4px); + --radius-md: calc(var(--radius) - 2px); + --radius-lg: var(--radius); + --radius-xl: calc(var(--radius) + 4px); + --color-sidebar: var(--sidebar); + --color-sidebar-foreground: var(--sidebar-foreground); + --color-sidebar-primary: var(--sidebar-primary); + --color-sidebar-primary-foreground: var(--sidebar-primary-foreground); + --color-sidebar-accent: var(--sidebar-accent); + --color-sidebar-accent-foreground: var(--sidebar-accent-foreground); + --color-sidebar-border: var(--sidebar-border); + --color-sidebar-ring: var(--sidebar-ring); +} + +@layer base { + * { + @apply border-border outline-ring/50; + } + body { + @apply bg-background text-foreground; + } + + html { + scroll-behavior: smooth; + } +} diff --git a/apps/www/app/layout.tsx b/apps/www/app/layout.tsx new file mode 100644 index 0000000..ba43e6f --- /dev/null +++ b/apps/www/app/layout.tsx @@ -0,0 +1,47 @@ +import { Analytics } from "@vercel/analytics/next"; +import type { Metadata } from "next"; +import { Geist, Geist_Mono } from "next/font/google"; +import type React from "react"; +import "./globals.css"; + +const _geist = Geist({ subsets: ["latin"] }); +const _geistMono = Geist_Mono({ subsets: ["latin"] }); + +export const metadata: Metadata = { + title: "MiniFy - Lightweight Spotify Mini Player", + description: + "A beautiful desktop mini player for Spotify. Built with Tauri + React, featuring OAuth authentication, multiple layouts, and customizable themes.", + generator: "v0.app", + icons: { + icon: [ + { + url: "/icon-light-32x32.png", + media: "(prefers-color-scheme: light)", + }, + { + url: "/icon-dark-32x32.png", + media: "(prefers-color-scheme: dark)", + }, + { + url: "/icon.svg", + type: "image/svg+xml", + }, + ], + apple: "/apple-icon.png", + }, +}; + +export default function RootLayout({ + children, +}: Readonly<{ + children: React.ReactNode; +}>) { + return ( + + + {children} + + + + ); +} diff --git a/apps/www/app/page.tsx b/apps/www/app/page.tsx new file mode 100644 index 0000000..c7c5286 --- /dev/null +++ b/apps/www/app/page.tsx @@ -0,0 +1,21 @@ +import { DownloadSection } from "@/components/download-section"; +import { FeaturesSection } from "@/components/features-section"; +import { Footer } from "@/components/footer"; +import { Header } from "@/components/header"; +import { HeroSection } from "@/components/hero-section"; +import { OpenSourceSection } from "@/components/open-source-section"; + +export default function Page() { + return ( +
+
+
+ + + + +
+
+
+ ); +} diff --git a/apps/www/components.json b/apps/www/components.json new file mode 100644 index 0000000..4ee62ee --- /dev/null +++ b/apps/www/components.json @@ -0,0 +1,21 @@ +{ + "$schema": "https://ui.shadcn.com/schema.json", + "style": "new-york", + "rsc": true, + "tsx": true, + "tailwind": { + "config": "", + "css": "app/globals.css", + "baseColor": "neutral", + "cssVariables": true, + "prefix": "" + }, + "aliases": { + "components": "@/components", + "utils": "@/lib/utils", + "ui": "@/components/ui", + "lib": "@/lib", + "hooks": "@/hooks" + }, + "iconLibrary": "lucide" +} diff --git a/apps/www/components/download-section.tsx b/apps/www/components/download-section.tsx new file mode 100644 index 0000000..a763676 --- /dev/null +++ b/apps/www/components/download-section.tsx @@ -0,0 +1,201 @@ +"use client"; + +import { Button } from "@/components/ui/button"; +import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "@/components/ui/card"; +import { useLanguage } from "@/hooks/use-language"; +import { Download, ExternalLink, Github } from "lucide-react"; +import { useEffect, useState } from "react"; + +interface Release { + version: string; + date: string; + downloadUrl: { + windows?: string; + linux?: string; + }; +} + +export function DownloadSection() { + const { t } = useLanguage(); + const [release, setRelease] = useState(null); + const [loading, setLoading] = useState(true); + + useEffect(() => { + fetch("https://api.github.com/repos/ModioStudio/MiniFy/releases/latest") + .then((res) => res.json()) + .then((data) => { + const windowsAsset = data.assets?.find( + (asset: { name: string }) => asset.name.includes(".exe") || asset.name.includes("windows") + ); + const linuxAsset = data.assets?.find( + (asset: { name: string }) => + asset.name.includes(".AppImage") || asset.name.includes("linux") + ); + + setRelease({ + version: data.tag_name || "v0.1.0", + date: new Date(data.published_at).toLocaleDateString(), + downloadUrl: { + windows: windowsAsset?.browser_download_url, + linux: linuxAsset?.browser_download_url, + }, + }); + }) + .catch(() => { + // Fallback if API fails + setRelease({ + version: "v0.1.0", + date: new Date().toLocaleDateString(), + downloadUrl: {}, + }); + }) + .finally(() => setLoading(false)); + }, []); + + return ( +
+
+ +
+
+

+ {t.download.sectionTitle} +

+

+ {t.download.sectionDescription} +

+
+ + {loading ? ( +
+
+
+ {t.download.loading} +
+
+ ) : ( +
+
+
+ + {t.download.latestVersion}: + + + {release?.version} + + ({release?.date}) +
+
+ +
+ + +
+ + Windows download icon + + +
+ Windows + {t.download.windowsDescription} +
+ + {release?.downloadUrl.windows ? ( + + ) : ( + + )} + +
+ + + +
+ + Linux download icon + + + +
+ Linux + {t.download.linuxDescription} +
+ + {release?.downloadUrl.linux ? ( + + ) : ( + + )} + +
+
+ +
+

+ {t.download.systemRequirements}{" "} + + {t.download.learnMore} + +

+
+
+ )} +
+
+ ); +} diff --git a/apps/www/components/features-section.tsx b/apps/www/components/features-section.tsx new file mode 100644 index 0000000..7da3f45 --- /dev/null +++ b/apps/www/components/features-section.tsx @@ -0,0 +1,85 @@ +"use client"; + +import { Card, CardContent } from "@/components/ui/card"; +import { useLanguage } from "@/hooks/use-language"; +import { Layout, Lock, Music, Palette, Settings, Zap } from "lucide-react"; + +export function FeaturesSection() { + const { t } = useLanguage(); + + const features = [ + { + icon: Music, + title: t.features.spotify.title, + description: t.features.spotify.description, + gradient: "from-[#1DB954] to-[#1ed760]", + }, + { + icon: Layout, + title: t.features.layouts.title, + description: t.features.layouts.description, + gradient: "from-blue-500 to-cyan-500", + }, + { + icon: Palette, + title: t.features.themes.title, + description: t.features.themes.description, + gradient: "from-purple-500 to-pink-500", + }, + { + icon: Zap, + title: t.features.performance.title, + description: t.features.performance.description, + gradient: "from-yellow-500 to-orange-500", + }, + { + icon: Lock, + title: t.features.secure.title, + description: t.features.secure.description, + gradient: "from-red-500 to-rose-500", + }, + { + icon: Settings, + title: t.features.customizable.title, + description: t.features.customizable.description, + gradient: "from-teal-500 to-emerald-500", + }, + ]; + + return ( +
+
+
+

+ {t.features.sectionTitle} +

+

+ {t.features.sectionDescription} +

+
+ +
+ {features.map((feature) => { + const Icon = feature.icon; + return ( + + +
+ +
+

{feature.title}

+

{feature.description}

+
+
+ ); + })} +
+
+
+ ); +} diff --git a/apps/www/components/footer.tsx b/apps/www/components/footer.tsx new file mode 100644 index 0000000..741093f --- /dev/null +++ b/apps/www/components/footer.tsx @@ -0,0 +1,123 @@ +"use client"; + +import { useLanguage } from "@/hooks/use-language"; +import { Github, Heart, Twitter } from "lucide-react"; + +export function Footer() { + const { t } = useLanguage(); + const currentYear = new Date().getFullYear(); + + return ( + + ); +} diff --git a/apps/www/components/header.tsx b/apps/www/components/header.tsx new file mode 100644 index 0000000..5695ac1 --- /dev/null +++ b/apps/www/components/header.tsx @@ -0,0 +1,127 @@ +"use client"; + +import { Button } from "@/components/ui/button"; +import { useLanguage } from "@/hooks/use-language"; +import { useTheme } from "@/hooks/use-theme"; +import { Menu, Moon, Sun, X } from "lucide-react"; +import { useState } from "react"; + +export function Header() { + const { theme, toggleTheme } = useTheme(); + const { t, language, setLanguage } = useLanguage(); + const [mobileMenuOpen, setMobileMenuOpen] = useState(false); + + const handleMobileNav = (target: string) => { + const element = document.querySelector(target); + if (element instanceof HTMLElement) { + element.scrollIntoView({ behavior: "smooth" }); + } + setMobileMenuOpen(false); + }; + + return ( +
+
+
+
+ M +
+ MiniFy +
+ + + +
+ + + +
+
+ + {mobileMenuOpen && ( +
+ +
+ )} +
+ ); +} diff --git a/apps/www/components/hero-section.tsx b/apps/www/components/hero-section.tsx new file mode 100644 index 0000000..420db0f --- /dev/null +++ b/apps/www/components/hero-section.tsx @@ -0,0 +1,69 @@ +"use client"; + +import { Button } from "@/components/ui/button"; +import { useLanguage } from "@/hooks/use-language"; +import { ArrowRight, Download, Github } from "lucide-react"; + +export function HeroSection() { + const { t } = useLanguage(); + + return ( +
+
+ +
+
+
+ + + + + {t.hero.badge} +
+ +

+ {t.hero.title} +

+ +

+ {t.hero.description} +

+ + + +
+
+ MiniFy Screenshot +
+
+
+
+
+ ); +} diff --git a/apps/www/components/open-source-section.tsx b/apps/www/components/open-source-section.tsx new file mode 100644 index 0000000..72c4453 --- /dev/null +++ b/apps/www/components/open-source-section.tsx @@ -0,0 +1,94 @@ +"use client"; + +import { Button } from "@/components/ui/button"; +import { Card, CardContent } from "@/components/ui/card"; +import { useLanguage } from "@/hooks/use-language"; +import { GitFork, Heart, Star, Users } from "lucide-react"; + +export function OpenSourceSection() { + const { t } = useLanguage(); + + const stats = [ + { icon: Star, label: t.opensource.stars, value: "4+" }, + { icon: GitFork, label: t.opensource.forks, value: "0+" }, + { icon: Users, label: t.opensource.contributors, value: "2+" }, + ]; + + return ( +
+
+ +
+
+
+ + Open Source +
+ +

+ {t.opensource.title} +

+

+ {t.opensource.description} +

+ +
+ {stats.map((stat) => { + const Icon = stat.icon; + return ( + + + +
{stat.value}
+
{stat.label}
+
+
+ ); + })} +
+ + + +
+

+ {t.opensource.license}{" "} + + MIT License + +

+
+
+
+
+ ); +} diff --git a/apps/www/components/theme-provider.tsx b/apps/www/components/theme-provider.tsx new file mode 100644 index 0000000..e478fc4 --- /dev/null +++ b/apps/www/components/theme-provider.tsx @@ -0,0 +1,7 @@ +"use client"; + +import { ThemeProvider as NextThemesProvider, type ThemeProviderProps } from "next-themes"; + +export function ThemeProvider({ children, ...props }: ThemeProviderProps) { + return {children}; +} diff --git a/apps/www/components/ui/accordion.tsx b/apps/www/components/ui/accordion.tsx new file mode 100644 index 0000000..e538a33 --- /dev/null +++ b/apps/www/components/ui/accordion.tsx @@ -0,0 +1,66 @@ +'use client' + +import * as React from 'react' +import * as AccordionPrimitive from '@radix-ui/react-accordion' +import { ChevronDownIcon } from 'lucide-react' + +import { cn } from '@/lib/utils' + +function Accordion({ + ...props +}: React.ComponentProps) { + return +} + +function AccordionItem({ + className, + ...props +}: React.ComponentProps) { + return ( + + ) +} + +function AccordionTrigger({ + className, + children, + ...props +}: React.ComponentProps) { + return ( + + svg]:rotate-180', + className, + )} + {...props} + > + {children} + + + + ) +} + +function AccordionContent({ + className, + children, + ...props +}: React.ComponentProps) { + return ( + +
{children}
+
+ ) +} + +export { Accordion, AccordionItem, AccordionTrigger, AccordionContent } diff --git a/apps/www/components/ui/alert-dialog.tsx b/apps/www/components/ui/alert-dialog.tsx new file mode 100644 index 0000000..9704452 --- /dev/null +++ b/apps/www/components/ui/alert-dialog.tsx @@ -0,0 +1,157 @@ +'use client' + +import * as React from 'react' +import * as AlertDialogPrimitive from '@radix-ui/react-alert-dialog' + +import { cn } from '@/lib/utils' +import { buttonVariants } from '@/components/ui/button' + +function AlertDialog({ + ...props +}: React.ComponentProps) { + return +} + +function AlertDialogTrigger({ + ...props +}: React.ComponentProps) { + return ( + + ) +} + +function AlertDialogPortal({ + ...props +}: React.ComponentProps) { + return ( + + ) +} + +function AlertDialogOverlay({ + className, + ...props +}: React.ComponentProps) { + return ( + + ) +} + +function AlertDialogContent({ + className, + ...props +}: React.ComponentProps) { + return ( + + + + + ) +} + +function AlertDialogHeader({ + className, + ...props +}: React.ComponentProps<'div'>) { + return ( +
+ ) +} + +function AlertDialogFooter({ + className, + ...props +}: React.ComponentProps<'div'>) { + return ( +
+ ) +} + +function AlertDialogTitle({ + className, + ...props +}: React.ComponentProps) { + return ( + + ) +} + +function AlertDialogDescription({ + className, + ...props +}: React.ComponentProps) { + return ( + + ) +} + +function AlertDialogAction({ + className, + ...props +}: React.ComponentProps) { + return ( + + ) +} + +function AlertDialogCancel({ + className, + ...props +}: React.ComponentProps) { + return ( + + ) +} + +export { + AlertDialog, + AlertDialogPortal, + AlertDialogOverlay, + AlertDialogTrigger, + AlertDialogContent, + AlertDialogHeader, + AlertDialogFooter, + AlertDialogTitle, + AlertDialogDescription, + AlertDialogAction, + AlertDialogCancel, +} diff --git a/apps/www/components/ui/alert.tsx b/apps/www/components/ui/alert.tsx new file mode 100644 index 0000000..e6751ab --- /dev/null +++ b/apps/www/components/ui/alert.tsx @@ -0,0 +1,66 @@ +import * as React from 'react' +import { cva, type VariantProps } from 'class-variance-authority' + +import { cn } from '@/lib/utils' + +const alertVariants = cva( + 'relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current', + { + variants: { + variant: { + default: 'bg-card text-card-foreground', + destructive: + 'text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90', + }, + }, + defaultVariants: { + variant: 'default', + }, + }, +) + +function Alert({ + className, + variant, + ...props +}: React.ComponentProps<'div'> & VariantProps) { + return ( +
+ ) +} + +function AlertTitle({ className, ...props }: React.ComponentProps<'div'>) { + return ( +
+ ) +} + +function AlertDescription({ + className, + ...props +}: React.ComponentProps<'div'>) { + return ( +
+ ) +} + +export { Alert, AlertTitle, AlertDescription } diff --git a/apps/www/components/ui/aspect-ratio.tsx b/apps/www/components/ui/aspect-ratio.tsx new file mode 100644 index 0000000..40bb120 --- /dev/null +++ b/apps/www/components/ui/aspect-ratio.tsx @@ -0,0 +1,11 @@ +'use client' + +import * as AspectRatioPrimitive from '@radix-ui/react-aspect-ratio' + +function AspectRatio({ + ...props +}: React.ComponentProps) { + return +} + +export { AspectRatio } diff --git a/apps/www/components/ui/avatar.tsx b/apps/www/components/ui/avatar.tsx new file mode 100644 index 0000000..aa98465 --- /dev/null +++ b/apps/www/components/ui/avatar.tsx @@ -0,0 +1,53 @@ +'use client' + +import * as React from 'react' +import * as AvatarPrimitive from '@radix-ui/react-avatar' + +import { cn } from '@/lib/utils' + +function Avatar({ + className, + ...props +}: React.ComponentProps) { + return ( + + ) +} + +function AvatarImage({ + className, + ...props +}: React.ComponentProps) { + return ( + + ) +} + +function AvatarFallback({ + className, + ...props +}: React.ComponentProps) { + return ( + + ) +} + +export { Avatar, AvatarImage, AvatarFallback } diff --git a/apps/www/components/ui/badge.tsx b/apps/www/components/ui/badge.tsx new file mode 100644 index 0000000..fc4126b --- /dev/null +++ b/apps/www/components/ui/badge.tsx @@ -0,0 +1,46 @@ +import * as React from 'react' +import { Slot } from '@radix-ui/react-slot' +import { cva, type VariantProps } from 'class-variance-authority' + +import { cn } from '@/lib/utils' + +const badgeVariants = cva( + 'inline-flex items-center justify-center rounded-md border px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-[color,box-shadow] overflow-hidden', + { + variants: { + variant: { + default: + 'border-transparent bg-primary text-primary-foreground [a&]:hover:bg-primary/90', + secondary: + 'border-transparent bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90', + destructive: + 'border-transparent bg-destructive text-white [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60', + outline: + 'text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground', + }, + }, + defaultVariants: { + variant: 'default', + }, + }, +) + +function Badge({ + className, + variant, + asChild = false, + ...props +}: React.ComponentProps<'span'> & + VariantProps & { asChild?: boolean }) { + const Comp = asChild ? Slot : 'span' + + return ( + + ) +} + +export { Badge, badgeVariants } diff --git a/apps/www/components/ui/breadcrumb.tsx b/apps/www/components/ui/breadcrumb.tsx new file mode 100644 index 0000000..1750ff2 --- /dev/null +++ b/apps/www/components/ui/breadcrumb.tsx @@ -0,0 +1,109 @@ +import * as React from 'react' +import { Slot } from '@radix-ui/react-slot' +import { ChevronRight, MoreHorizontal } from 'lucide-react' + +import { cn } from '@/lib/utils' + +function Breadcrumb({ ...props }: React.ComponentProps<'nav'>) { + return