feat: 修改以来地址
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
'use client';
|
||||
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { buttonVariants } from '@workspace/ui/components/button';
|
||||
import { cn } from '@workspace/ui/lib/utils';
|
||||
import { buttonVariants } from '@workspace/airo-ui/components/button';
|
||||
import { cn } from '@workspace/airo-ui/lib/utils';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import Image from 'next/legacy/image';
|
||||
import Link from 'next/link';
|
||||
|
||||
@@ -8,8 +8,8 @@ import {
|
||||
DialogHeader,
|
||||
DialogTitle,
|
||||
} from '@workspace/airo-ui/components/dialog';
|
||||
import { ProList } from '@workspace/ui/custom-components/pro-list/pro-list';
|
||||
import { formatDate } from '@workspace/ui/utils';
|
||||
import { ProList } from '@workspace/airo-ui/custom-components/pro-list/pro-list';
|
||||
import { formatDate } from '@workspace/airo-ui/utils';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useImperativeHandle, useState } from 'react';
|
||||
|
||||
|
||||
@@ -10,10 +10,10 @@ import SvgIcon from '@/components/SvgIcon';
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { queryUserAffiliate, queryUserAffiliateList } from '@/services/user/user';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Card, CardContent } from '@workspace/ui/components/card';
|
||||
import { Input } from '@workspace/ui/components/input';
|
||||
import { formatDate } from '@workspace/ui/utils';
|
||||
import { Button } from '@workspace/airo-ui/components/button';
|
||||
import { Card, CardContent } from '@workspace/airo-ui/components/card';
|
||||
import { Input } from '@workspace/airo-ui/components/input';
|
||||
import { formatDate } from '@workspace/airo-ui/utils';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useRef, useState } from 'react';
|
||||
import { CopyToClipboard } from 'react-copy-to-clipboard';
|
||||
|
||||
@@ -5,7 +5,7 @@ import {
|
||||
DialogHeader,
|
||||
DialogTitle,
|
||||
} from '@workspace/airo-ui/components/dialog';
|
||||
import { Markdown } from '@workspace/ui/custom-components/markdown';
|
||||
import { Markdown } from '@workspace/airo-ui/custom-components/markdown';
|
||||
import { getTranslations } from 'next-intl/server';
|
||||
|
||||
export default async function Announcement({
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { oAuthLogin } from '@/services/common/oauth';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Icon } from '@workspace/ui/custom-components/icon';
|
||||
import { Button } from '@workspace/airo-ui/components/button';
|
||||
import { Icon } from '@workspace/airo-ui/custom-components/icon';
|
||||
|
||||
const icons = {
|
||||
apple: 'uil:apple',
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
'use client';
|
||||
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { formatBytes, unitConversion } from '@workspace/ui/utils';
|
||||
import { formatBytes, unitConversion } from '@workspace/airo-ui/utils';
|
||||
import { useTranslations } from 'next-intl';
|
||||
|
||||
type DisplayType = 'currency' | 'traffic' | 'number' | 'trafficSpeed';
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
'use client';
|
||||
|
||||
import { default as _Empty } from '@workspace/ui/custom-components/empty';
|
||||
import { default as _Empty } from '@workspace/airo-ui/custom-components/empty';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useEffect, useState } from 'react';
|
||||
|
||||
|
||||
@@ -10,8 +10,8 @@ import {
|
||||
NEXT_PUBLIC_TWITTER_LINK,
|
||||
} from '@/config/constants';
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { Separator } from '@workspace/ui/components/separator';
|
||||
import { Icon } from '@workspace/ui/custom-components/icon';
|
||||
import { Separator } from '@workspace/airo-ui/components/separator';
|
||||
import { Icon } from '@workspace/airo-ui/custom-components/icon';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import Link from 'next/link';
|
||||
import { Fragment } from 'react';
|
||||
|
||||
@@ -8,9 +8,9 @@ import {
|
||||
SelectItem,
|
||||
SelectTrigger,
|
||||
SelectValue,
|
||||
} from '@workspace/ui/components/select';
|
||||
import { Icon } from '@workspace/ui/custom-components/icon';
|
||||
import { getCountry } from '@workspace/ui/utils';
|
||||
} from '@workspace/airo-ui/components/select';
|
||||
import { Icon } from '@workspace/airo-ui/custom-components/icon';
|
||||
import { getCountry } from '@workspace/airo-ui/utils';
|
||||
import { useLocale } from 'next-intl';
|
||||
import { useRouter } from 'next/navigation';
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
'use client';
|
||||
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Button } from '@workspace/airo-ui/components/button';
|
||||
import { useRef } from 'react';
|
||||
import OfferDialog, { OfferDialogRef } from './OfferDialog/index';
|
||||
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
import CloseSvg from '@/components/CustomIcon/icons/close.svg';
|
||||
import { getSubscription } from '@/services/user/portal';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Dialog, DialogContent, DialogTitle } from '@workspace/ui/components/dialog';
|
||||
import { ScrollArea } from '@workspace/ui/components/scroll-area';
|
||||
import { Tabs, TabsList, TabsTrigger } from '@workspace/ui/components/tabs';
|
||||
import { unitConversion } from '@workspace/ui/utils';
|
||||
import { Dialog, DialogContent, DialogTitle } from '@workspace/airo-ui/components/dialog';
|
||||
import { ScrollArea } from '@workspace/airo-ui/components/scroll-area';
|
||||
import { Tabs, TabsList, TabsTrigger } from '@workspace/airo-ui/components/tabs';
|
||||
import { unitConversion } from '@workspace/airo-ui/utils';
|
||||
import Image from 'next/image';
|
||||
import {
|
||||
forwardRef,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
'use client';
|
||||
|
||||
import { DotLottieReact } from '@lottiefiles/dotlottie-react';
|
||||
import GlobalMapLottie from '@workspace/ui/lotties/global-map.json';
|
||||
import GlobalMapLottie from '@workspace/airo-ui/lotties/global-map.json';
|
||||
import { motion } from 'framer-motion';
|
||||
import { useTranslations } from 'next-intl';
|
||||
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { DotLottieReact } from '@lottiefiles/dotlottie-react';
|
||||
import { HoverBorderGradient } from '@workspace/ui/components/hover-border-gradient';
|
||||
import { TextGenerateEffect } from '@workspace/ui/components/text-generate-effect';
|
||||
import NetworkSecurityLottie from '@workspace/ui/lotties/network-security.json';
|
||||
import { HoverBorderGradient } from '@workspace/airo-ui/components/hover-border-gradient';
|
||||
import { TextGenerateEffect } from '@workspace/airo-ui/components/text-generate-effect';
|
||||
import NetworkSecurityLottie from '@workspace/airo-ui/lotties/network-security.json';
|
||||
import { motion } from 'framer-motion';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import Link from 'next/link';
|
||||
|
||||
@@ -3,11 +3,11 @@
|
||||
import { Display } from '@/components/display';
|
||||
import { SubscribeDetail } from '@/components/subscribe/detail';
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Card, CardContent, CardFooter, CardHeader } from '@workspace/ui/components/card';
|
||||
import { Separator } from '@workspace/ui/components/separator';
|
||||
import { Icon } from '@workspace/ui/custom-components/icon';
|
||||
import { cn } from '@workspace/ui/lib/utils';
|
||||
import { Button } from '@workspace/airo-ui/components/button';
|
||||
import { Card, CardContent, CardFooter, CardHeader } from '@workspace/airo-ui/components/card';
|
||||
import { Separator } from '@workspace/airo-ui/components/separator';
|
||||
import { Icon } from '@workspace/airo-ui/custom-components/icon';
|
||||
import { cn } from '@workspace/airo-ui/lib/utils';
|
||||
import { motion } from 'framer-motion';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import Link from 'next/link';
|
||||
|
||||
@@ -6,9 +6,9 @@ import {
|
||||
NEXT_PUBLIC_HOME_USER_COUNT,
|
||||
} from '@/config/constants';
|
||||
import { DotLottieReact } from '@lottiefiles/dotlottie-react';
|
||||
import LocationsLittie from '@workspace/ui/lotties/locations.json';
|
||||
import ServersLottie from '@workspace/ui/lotties/servers.json';
|
||||
import UsersLottie from '@workspace/ui/lotties/users.json';
|
||||
import LocationsLittie from '@workspace/airo-ui/lotties/locations.json';
|
||||
import ServersLottie from '@workspace/airo-ui/lotties/servers.json';
|
||||
import UsersLottie from '@workspace/airo-ui/lotties/users.json';
|
||||
import { motion } from 'framer-motion';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useEffect, useState } from 'react';
|
||||
|
||||
@@ -12,9 +12,9 @@ import {
|
||||
StripeCardNumberElementOptions,
|
||||
StripeElementStyle,
|
||||
} from '@stripe/stripe-js';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Input } from '@workspace/ui/components/input';
|
||||
import { Label } from '@workspace/ui/components/label';
|
||||
import { Button } from '@workspace/airo-ui/components/button';
|
||||
import { Input } from '@workspace/airo-ui/components/input';
|
||||
import { Label } from '@workspace/airo-ui/components/label';
|
||||
import { CheckCircle } from 'lucide-react';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useTheme } from 'next-themes';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
'use client';
|
||||
|
||||
import { Display } from '@/components/display';
|
||||
import { Separator } from '@workspace/ui/components/separator';
|
||||
import { Separator } from '@workspace/airo-ui/components/separator';
|
||||
import { useTranslations } from 'next-intl';
|
||||
|
||||
interface SubscribeBillingProps {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
'use client';
|
||||
|
||||
import { Input } from '@workspace/ui/components/input';
|
||||
import { Input } from '@workspace/airo-ui/components/input';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import React from 'react';
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
'use client';
|
||||
|
||||
import { Badge } from '@workspace/ui/components/badge';
|
||||
import { Label } from '@workspace/ui/components/label';
|
||||
import { RadioGroup, RadioGroupItem } from '@workspace/ui/components/radio-group';
|
||||
import { Badge } from '@workspace/airo-ui/components/badge';
|
||||
import { Label } from '@workspace/airo-ui/components/label';
|
||||
import { RadioGroup, RadioGroupItem } from '@workspace/airo-ui/components/radio-group';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import React, { useCallback } from 'react';
|
||||
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
import { getAvailablePaymentMethods } from '@/services/user/portal';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Label } from '@workspace/ui/components/label';
|
||||
import { RadioGroup, RadioGroupItem } from '@workspace/ui/components/radio-group';
|
||||
import { cn } from '@workspace/ui/lib/utils';
|
||||
import { Label } from '@workspace/airo-ui/components/label';
|
||||
import { RadioGroup, RadioGroupItem } from '@workspace/airo-ui/components/radio-group';
|
||||
import { cn } from '@workspace/airo-ui/lib/utils';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import Image from 'next/image';
|
||||
import React, { memo } from 'react';
|
||||
|
||||
@@ -3,15 +3,15 @@
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { preCreateOrder, purchase } from '@/services/user/order';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Button } from '@workspace/airo-ui/components/button';
|
||||
import {
|
||||
Dialog,
|
||||
DialogContent,
|
||||
DialogHeader,
|
||||
DialogTitle,
|
||||
} from '@workspace/airo-ui/components/dialog';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Separator } from '@workspace/ui/components/separator';
|
||||
import { Tabs, TabsList, TabsTrigger } from '@workspace/ui/components/tabs';
|
||||
import { Separator } from '@workspace/airo-ui/components/separator';
|
||||
import { Tabs, TabsList, TabsTrigger } from '@workspace/airo-ui/components/tabs';
|
||||
import { LoaderCircle } from 'lucide-react';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useRouter } from 'next/navigation';
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { recharge } from '@/services/user/order';
|
||||
import { Button, ButtonProps } from '@workspace/ui/components/button';
|
||||
import { Button, ButtonProps } from '@workspace/airo-ui/components/button';
|
||||
import {
|
||||
Dialog,
|
||||
DialogContent,
|
||||
@@ -10,9 +10,9 @@ import {
|
||||
DialogHeader,
|
||||
DialogTitle,
|
||||
DialogTrigger,
|
||||
} from '@workspace/ui/components/dialog';
|
||||
import { EnhancedInput } from '@workspace/ui/custom-components/enhanced-input';
|
||||
import { unitConversion } from '@workspace/ui/utils';
|
||||
} from '@workspace/airo-ui/components/dialog';
|
||||
import { EnhancedInput } from '@workspace/airo-ui/custom-components/enhanced-input';
|
||||
import { unitConversion } from '@workspace/airo-ui/utils';
|
||||
import { LoaderCircle } from 'lucide-react';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useRouter } from 'next/navigation';
|
||||
|
||||
@@ -6,16 +6,16 @@ import PaymentMethods from '@/components/subscribe/payment-methods';
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { preCreateOrder, renewal } from '@/services/user/order';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Card, CardContent } from '@workspace/ui/components/card';
|
||||
import { Button } from '@workspace/airo-ui/components/button';
|
||||
import { Card, CardContent } from '@workspace/airo-ui/components/card';
|
||||
import {
|
||||
Dialog,
|
||||
DialogContent,
|
||||
DialogHeader,
|
||||
DialogTitle,
|
||||
DialogTrigger,
|
||||
} from '@workspace/ui/components/dialog';
|
||||
import { Separator } from '@workspace/ui/components/separator';
|
||||
} from '@workspace/airo-ui/components/dialog';
|
||||
import { Separator } from '@workspace/airo-ui/components/separator';
|
||||
import { LoaderCircle } from 'lucide-react';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useRouter } from 'next/navigation';
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
import { Display } from '@/components/display';
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { resetTraffic } from '@/services/user/order';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Button } from '@workspace/airo-ui/components/button';
|
||||
import {
|
||||
Dialog,
|
||||
DialogContent,
|
||||
@@ -11,7 +11,7 @@ import {
|
||||
DialogHeader,
|
||||
DialogTitle,
|
||||
DialogTrigger,
|
||||
} from '@workspace/ui/components/dialog';
|
||||
} from '@workspace/airo-ui/components/dialog';
|
||||
import { LoaderCircle } from 'lucide-react';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useRouter } from 'next/navigation';
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { preUnsubscribe, unsubscribe } from '@/services/user/user';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Button } from '@workspace/airo-ui/components/button';
|
||||
import {
|
||||
Dialog,
|
||||
DialogContent,
|
||||
@@ -12,7 +12,7 @@ import {
|
||||
DialogHeader,
|
||||
DialogTitle,
|
||||
DialogTrigger,
|
||||
} from '@workspace/ui/components/dialog';
|
||||
} from '@workspace/airo-ui/components/dialog';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useRouter } from 'next/navigation';
|
||||
import { useState } from 'react';
|
||||
|
||||
@@ -1,15 +1,15 @@
|
||||
'use client';
|
||||
|
||||
import { DotLottieReact } from '@lottiefiles/dotlottie-react';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Button } from '@workspace/airo-ui/components/button';
|
||||
import {
|
||||
DropdownMenu,
|
||||
DropdownMenuContent,
|
||||
DropdownMenuItem,
|
||||
DropdownMenuTrigger,
|
||||
} from '@workspace/ui/components/dropdown-menu';
|
||||
import MoonLottie from '@workspace/ui/lotties/moon.json';
|
||||
import SunLottie from '@workspace/ui/lotties/sun.json';
|
||||
} from '@workspace/airo-ui/components/dropdown-menu';
|
||||
import MoonLottie from '@workspace/airo-ui/lotties/moon.json';
|
||||
import SunLottie from '@workspace/airo-ui/lotties/sun.json';
|
||||
import { useTheme } from 'next-themes';
|
||||
|
||||
export default function ThemeSwitch() {
|
||||
|
||||
@@ -3,16 +3,15 @@
|
||||
import SvgIcon from '@/components/SvgIcon.tsx';
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import { Logout } from '@/utils/common';
|
||||
import { useSidebar } from '@workspace/airo-ui/components/sidebar';
|
||||
import { useIsMobile } from '@workspace/airo-ui/hooks/use-mobile';
|
||||
import { Avatar, AvatarFallback, AvatarImage } from '@workspace/ui/components/avatar';
|
||||
import { Avatar, AvatarFallback, AvatarImage } from '@workspace/airo-ui/components/avatar';
|
||||
import {
|
||||
DropdownMenu,
|
||||
DropdownMenuContent,
|
||||
DropdownMenuItem,
|
||||
DropdownMenuTrigger,
|
||||
} from '@workspace/ui/components/dropdown-menu';
|
||||
import { Icon } from '@workspace/ui/custom-components/icon';
|
||||
} from '@workspace/airo-ui/components/dropdown-menu';
|
||||
import { Icon } from '@workspace/airo-ui/custom-components/icon';
|
||||
import { useIsMobile } from '@workspace/airo-ui/hooks/use-mobile';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { usePathname, useRouter } from 'next/navigation';
|
||||
|
||||
@@ -21,7 +20,7 @@ export function UserNav({ from = '' }: { from?: string }) {
|
||||
const { user, setUser } = useGlobalStore();
|
||||
const router = useRouter();
|
||||
const pathname = usePathname();
|
||||
const { toggleSidebar } = useSidebar();
|
||||
// const { toggleSidebar } = useSidebar();
|
||||
const isMobile = useIsMobile();
|
||||
if (user) {
|
||||
return (
|
||||
@@ -98,7 +97,7 @@ export function UserNav({ from = '' }: { from?: string }) {
|
||||
data-active={pathname === item.url}
|
||||
onClick={() => {
|
||||
if (pathname === item.url) return;
|
||||
toggleSidebar();
|
||||
/* toggleSidebar();*/
|
||||
router.push(`${item.url}`);
|
||||
}}
|
||||
className='flex cursor-pointer items-center gap-3 rounded-full bg-white px-5 py-2 text-base font-medium focus:bg-[#0F2C53] focus:text-white data-[active=true]:bg-[#0F2C53] data-[active=true]:text-white md:text-xl'
|
||||
|
||||
Reference in New Issue
Block a user