Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
5 changes: 4 additions & 1 deletion web/src/components/layout/components/public-header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,10 @@ export function PublicHeader(props: PublicHeaderProps) {
)}
</span>
</Link>
<SystemUpdateAction presentation='version' />
<SystemUpdateAction
presentation='version'
hideWhenVersionUnknown
/>
</div>

{/* Desktop nav */}
Expand Down
1 change: 0 additions & 1 deletion web/src/features/home/components/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,3 @@ export { CTA } from './sections/cta'
export { Features } from './sections/features'
export { Hero } from './sections/hero'
export { HowItWorks } from './sections/how-it-works'
export { Stats } from './sections/stats'
2 changes: 1 addition & 1 deletion web/src/features/home/components/sections/cta.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ export function CTA(props: CTAProps) {
</h2>
<p className='text-muted-foreground/80 mx-auto mt-5 max-w-md text-sm leading-relaxed md:text-base'>
{t(
'Deploy your own gateway and start routing requests through your configured upstream services.'
'Create an account to get your API key and start routing requests through the gateway.'
)}
</p>
<div className='mt-8 flex items-center justify-center gap-3'>
Expand Down
213 changes: 29 additions & 184 deletions web/src/features/home/components/sections/features.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,13 @@ along with this program. If not, see <https://www.gnu.org/licenses/>.

For commercial licensing, please contact support@quantumnous.com
*/
import {
Zap,
Shield,
Globe,
Code,
Gauge,
DollarSign,
Users,
HeartHandshake,
} from 'lucide-react'
import { BarChart3, KeyRound, Network, Route } from 'lucide-react'
import { useTranslation } from 'react-i18next'

import { AnimateInView } from '@/components/animate-in-view'

import { FeatureItem } from '../feature-item'

interface FeaturesProps {
className?: string
}
Expand All @@ -39,199 +32,51 @@ export function Features(_props: FeaturesProps) {

const features = [
{
id: 'fast',
num: '01',
title: t('Lightning Fast'),
title: t('Unified access'),
desc: t(
'Optimized network architecture ensures millisecond response times'
),
span: 'md:col-span-2',
icon: <Zap className='size-4 text-blue-400' />,
visual: (
<div className='mt-4 grid grid-cols-3 gap-2'>
{['OpenAI', 'Claude', 'Gemini', 'DeepSeek', 'Qwen', 'Llama'].map(
(name) => (
<div
key={name}
className='border-border/30 bg-muted/20 text-muted-foreground flex items-center justify-center rounded-lg border px-3 py-2 text-xs transition-colors duration-300 hover:border-blue-500/30 hover:bg-blue-500/5'
>
{name}
</div>
)
)}
</div>
'Reach many AI models and providers through one standard API endpoint.'
),
icon: <Network className='size-5 text-amber-500' />,
},
{
id: 'secure',
num: '02',
title: t('Secure & Reliable'),
title: t('Routing and load balancing'),
desc: t(
'Enterprise-grade security with comprehensive permission management'
),
span: 'md:col-span-1',
icon: <Shield className='size-4 text-emerald-400' />,
visual: (
<div className='mt-4 flex items-center justify-center'>
<div className='relative'>
<div className='flex size-16 items-center justify-center rounded-2xl border border-emerald-500/20 bg-emerald-500/5'>
<Shield
className='size-7 text-emerald-500/70'
strokeWidth={1.5}
/>
</div>
<div className='absolute -top-1 -right-1 flex size-4 items-center justify-center rounded-full bg-emerald-500'>
<svg
className='size-2.5 text-white'
fill='none'
viewBox='0 0 24 24'
stroke='currentColor'
strokeWidth={3}
>
<path
strokeLinecap='round'
strokeLinejoin='round'
d='m4.5 12.75 6 6 9-13.5'
/>
</svg>
</div>
</div>
</div>
'Route requests across channels with groups, priorities, weights, and automatic retry.'
),
icon: <Route className='size-5 text-amber-500' />,
},
{
id: 'global',
num: '03',
title: t('Global Coverage'),
desc: t('Multi-region deployment for stable global access'),
span: 'md:col-span-1',
icon: <Globe className='size-4 text-violet-400' />,
visual: (
<div className='mt-4 space-y-2'>
{[t('Load Balancing'), t('Rate Limiting'), t('Cost Tracking')].map(
(step, i) => (
<div key={step} className='flex items-center gap-2'>
<div
className={`flex size-6 items-center justify-center rounded-full text-[10px] font-bold ${
i === 1
? 'border border-blue-500/30 bg-blue-500/20 text-blue-500'
: 'border-border/40 bg-muted text-muted-foreground border'
}`}
>
{i + 1}
</div>
<div className='bg-border/40 h-px flex-1' />
<span className='text-muted-foreground text-xs'>{step}</span>
</div>
)
)}
</div>
title: t('Usage monitoring and analytics'),
desc: t(
'Track requests, tokens, latency, and cost with logs and dashboards.'
),
icon: <BarChart3 className='size-5 text-amber-500' />,
},
{
id: 'developer',
num: '04',
title: t('Developer Friendly'),
desc: t('Compatible API routes for common AI application workflows'),
span: 'md:col-span-2',
icon: <Code className='size-4 text-amber-400' />,
visual: (
<div className='mt-4 flex items-center gap-3'>
<div className='flex -space-x-2'>
{['API', 'SDK', 'CLI', 'Docs'].map((n) => (
<div
key={n}
className='border-background from-muted to-muted/60 text-muted-foreground flex size-8 items-center justify-center rounded-full border-2 bg-gradient-to-br text-[9px] font-bold'
>
{n}
</div>
))}
</div>
<div className='text-muted-foreground flex items-center gap-1.5 text-xs'>
<Code className='size-3.5 text-blue-500' />
{t('Multi-protocol Compatible')}
</div>
</div>
title: t('Key and billing management'),
desc: t(
'Issue API keys with quotas and limits, and manage balances and billing.'
),
},
]

const additionalFeatures = [
{
icon: <Gauge className='size-5' strokeWidth={1.5} />,
title: t('High Performance'),
desc: t('Support for high concurrency with automatic load balancing'),
},
{
icon: <DollarSign className='size-5' strokeWidth={1.5} />,
title: t('Transparent Billing'),
desc: t('Pay-as-you-go with real-time usage monitoring'),
},
{
icon: <Users className='size-5' strokeWidth={1.5} />,
title: t('Team Collaboration'),
desc: t('Multi-user management with flexible permission allocation'),
},
{
icon: <HeartHandshake className='size-5' strokeWidth={1.5} />,
title: t('Open Source'),
desc: t('Community driven, self-hosted, and extensible'),
icon: <KeyRound className='size-5 text-amber-500' />,
},
]

return (
<section className='relative z-10 px-6 py-24 md:py-32'>
<section className='border-border/40 relative z-10 border-y px-6 py-20 md:py-24'>
<div className='mx-auto max-w-6xl'>
<AnimateInView className='mb-16 max-w-lg'>
<p className='text-muted-foreground mb-3 text-xs font-medium tracking-widest uppercase'>
{t('Core Features')}
</p>
<h2 className='text-2xl leading-tight font-bold tracking-tight md:text-3xl'>
{t('Built for developers,')}
<br />
{t('designed for scale')}
<AnimateInView className='mb-12 text-center'>
<h2 className='text-2xl font-bold tracking-tight md:text-3xl'>
{t('Manage, route, monitor, and analyze AI API access')}
</h2>
</AnimateInView>

{/* Bento grid */}
<div className='border-border/40 bg-border/40 grid gap-px overflow-hidden rounded-xl border md:grid-cols-3'>
{features.map((f, i) => (
<AnimateInView
key={f.id}
delay={i * 100}
animation='scale-in'
className={`bg-background group hover:bg-muted/20 p-7 transition-colors duration-300 md:p-8 ${f.span}`}
>
<div className='mb-3 flex items-center gap-3'>
<span className='border-border/40 bg-muted text-muted-foreground flex size-7 items-center justify-center rounded-md border text-[10px] font-semibold tabular-nums'>
{f.num}
</span>
<h3 className='text-sm font-semibold'>{f.title}</h3>
</div>
<p className='text-muted-foreground text-sm leading-relaxed'>
{f.desc}
</p>
{f.visual}
</AnimateInView>
))}
</div>

{/* Additional features row */}
<div className='mt-12 grid grid-cols-2 gap-8 md:grid-cols-4 md:gap-12'>
{additionalFeatures.map((f, i) => (
<AnimateInView
key={f.title}
delay={i * 100}
animation='fade-up'
className='flex flex-col items-center text-center'
>
<div className='text-muted-foreground border-border/50 bg-muted/30 group-hover:text-foreground mb-3 flex size-12 items-center justify-center rounded-xl border transition-colors'>
{f.icon}
</div>
<h3 className='mb-1.5 text-sm font-semibold'>{f.title}</h3>
<p className='text-muted-foreground max-w-[200px] text-xs leading-relaxed'>
{f.desc}
</p>
<div className='grid gap-6 sm:grid-cols-2 lg:grid-cols-4'>
{features.map((feature, i) => (
<AnimateInView key={feature.title} delay={i * 100}>
<FeatureItem
title={feature.title}
description={feature.desc}
icon={feature.icon}
/>
</AnimateInView>
))}
</div>
Expand Down
26 changes: 17 additions & 9 deletions web/src/features/home/components/sections/hero.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,11 @@ const MoreIcon = () => (
export function Hero(props: HeroProps) {
const { t } = useTranslation()
const { status } = useStatus()
const docsUrl =
(status?.docs_link as string | undefined) || 'https://docs.newapi.pro'
const systemName = (status?.system_name as string | undefined)?.trim()
const docsUrl = (status?.docs_link as string | undefined)?.trim()

const renderDocsButton = () => {
if (!docsUrl) return null
const isExternal = docsUrl.startsWith('http')
if (isExternal) {
return (
Expand Down Expand Up @@ -111,25 +112,32 @@ export function Hero(props: HeroProps) {
<span className='absolute inline-flex h-full w-full animate-ping rounded-full bg-blue-400 opacity-75' />
<span className='relative inline-flex size-1.5 rounded-full bg-blue-500 dark:bg-blue-400' />
</span>
<span>{t('AI Application Infrastructure Foundation')}</span>
<span>{t('Unified API gateway and SaaS platform')}</span>
</div>

{systemName && (
<p
className='landing-animate-fade-up text-[clamp(2.75rem,6vw,4.25rem)] leading-none font-extrabold tracking-tight'
style={{ animationDelay: '30ms' }}
>
{systemName}
</p>
)}
<h1
className='landing-animate-fade-up text-[clamp(2.25rem,4.5vw,3.25rem)] leading-[1.15] font-bold tracking-tight'
className='landing-animate-fade-up mt-4 text-[clamp(1.5rem,3vw,2.25rem)] leading-[1.2] font-bold tracking-tight'
style={{ animationDelay: '60ms' }}
>
{t('Unified API Gateway for')}
<br />
{t('Unified API Gateway for')}{' '}
<span className='bg-gradient-to-r from-blue-400 via-violet-400 to-purple-500 bg-clip-text text-transparent'>
{t('Vast Range of AI Models')}
</span>
</h1>
<p
className='landing-animate-fade-up text-muted-foreground/80 mt-5 max-w-xl text-base leading-relaxed opacity-0 md:text-[15px]'
className='landing-animate-fade-up text-muted-foreground mt-5 max-w-xl text-base leading-relaxed opacity-0'
style={{ animationDelay: '120ms' }}
>
{t(
'Access a vast selection of models via a standard, unified API protocol. Power AI applications, manage digital assets, and connect the Future.'
'A unified API gateway and SaaS platform for managing, routing, monitoring, and analyzing access to and use of AI models and APIs.'
)}
</p>

Expand Down Expand Up @@ -180,7 +188,7 @@ export function Hero(props: HeroProps) {
</span>
<p className='text-muted-foreground/60 text-xs leading-relaxed'>
{t(
'Supports one-click configuration and perfectly adapts to NewAPI multi-protocol configuration.'
'Supports one-click configuration for popular AI clients and standard API protocols.'
)}
</p>
</div>
Expand Down
Loading