fix: SITE_URL
This commit is contained in:
1 parent
1fe912f4bd
commit
dfdfb79169
66 files changed
+1352
-240
No files matched your search
+9
-3
@@ -1,12 +1,18 @@
|
||||
{
|
||||
"extends": ["next/core-web-vitals", "plugin:tailwindcss/recommended"],
|
||||
"plugins": ["simple-import-sort", "tailwindcss"],
|
||||
"extends": ["next/core-web-vitals", "plugin:tailwindcss/recommended", "prettier"],
|
||||
"plugins": ["prettier", "simple-import-sort", "tailwindcss"],
|
||||
"rules": {
|
||||
"@next/next/no-img-element": "off",
|
||||
"tailwindcss/classnames-order": "error",
|
||||
"simple-import-sort/imports": "error",
|
||||
"simple-import-sort/exports": "error",
|
||||
"quotes": ["error", "single"]
|
||||
"quotes": ["error", "single"],
|
||||
"prettier/prettier": [
|
||||
"warn",
|
||||
{
|
||||
"endOfLine": "auto"
|
||||
}
|
||||
]
|
||||
},
|
||||
"settings": {
|
||||
"tailwindcss": {
|
||||
|
||||
+1
-1
@@ -1 +1 @@
|
||||
npm run lint && git add -A .
|
||||
npm run lint-staged && git add -A .
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"**/*.ts?(x)": ["prettier --write", "eslint --fix"],
|
||||
"**/*.(ts)?(x)": "npm run type-check",
|
||||
"./*.md": ["prettier --write"]
|
||||
}
|
||||
@@ -1,5 +0,0 @@
|
||||
import Http from './Http';
|
||||
|
||||
const movieAdvisor = new Http('http://localhost:3000/api/tmdb');
|
||||
|
||||
export default movieAdvisor;
|
||||
@@ -1,5 +0,0 @@
|
||||
import UsersList from '@/components/UsersLists';
|
||||
|
||||
const Container = () => <UsersList list='favorite' label='favorites' />;
|
||||
|
||||
export default Container;
|
||||
@@ -1,29 +1,31 @@
|
||||
import { dehydrate, HydrationBoundary } from '@tanstack/react-query';
|
||||
import { Metadata } from 'next';
|
||||
|
||||
import { session } from '@/api';
|
||||
import usersShowsQuery from '@/api/queries/usersShows';
|
||||
import UsersList from '@/components/UsersLists';
|
||||
import { session as getSession } from '@/data';
|
||||
import usersShowsQuery from '@/data/queries/usersShows';
|
||||
import { TITLE } from '@/env';
|
||||
import getQueryClient from '@/lib/queryClient';
|
||||
|
||||
import Container from './container';
|
||||
|
||||
export const metadata: Metadata = {
|
||||
title: 'My Favorite Shows - Movie Advisor',
|
||||
description:
|
||||
'View your favorite shows on Movie Advisor. Keep track of films you’ve added and revisit your top picks anytime.'
|
||||
title: `My Favorite Shows - ${TITLE}`,
|
||||
description: `View your favorite shows on ${TITLE}. Keep track of films you’ve added and revisit your top picks anytime.`
|
||||
};
|
||||
|
||||
const Favorites = () => {
|
||||
const Favorites = async () => {
|
||||
const session = await getSession();
|
||||
const queryClient = getQueryClient();
|
||||
|
||||
const list = 'favorite';
|
||||
const showType = 'movie';
|
||||
|
||||
queryClient.prefetchInfiniteQuery(usersShowsQuery({ showType, list, session: session() }));
|
||||
if (session) {
|
||||
await queryClient.prefetchInfiniteQuery(usersShowsQuery({ showType, list, session }));
|
||||
}
|
||||
|
||||
return (
|
||||
<HydrationBoundary state={dehydrate(queryClient)}>
|
||||
<Container />
|
||||
<UsersList session={session} list={list} label='favorites' />
|
||||
</HydrationBoundary>
|
||||
);
|
||||
};
|
||||
|
||||
+3
-3
@@ -1,14 +1,14 @@
|
||||
import { dehydrate, HydrationBoundary } from '@tanstack/react-query';
|
||||
|
||||
import randomQuery from '@/api/queries/random';
|
||||
import randomQuery from '@/data/queries/random';
|
||||
import getQueryClient from '@/lib/queryClient';
|
||||
|
||||
import Container from './container';
|
||||
|
||||
const Random = () => {
|
||||
const Random = async () => {
|
||||
const queryClient = getQueryClient();
|
||||
|
||||
queryClient.prefetchInfiniteQuery(randomQuery());
|
||||
await queryClient.prefetchInfiniteQuery(randomQuery());
|
||||
|
||||
return (
|
||||
<HydrationBoundary state={dehydrate(queryClient)}>
|
||||
|
||||
@@ -1,21 +1,21 @@
|
||||
import { dehydrate, HydrationBoundary } from '@tanstack/react-query';
|
||||
import { Metadata } from 'next';
|
||||
|
||||
import popularQuery from '@/api/queries/popular';
|
||||
import popularQuery from '@/data/queries/popular';
|
||||
import { TITLE } from '@/env';
|
||||
import getQueryClient from '@/lib/queryClient';
|
||||
|
||||
import Container from './container';
|
||||
|
||||
export const metadata: Metadata = {
|
||||
title: 'Popular Movies | Movie Advisor',
|
||||
description:
|
||||
'Check out the most popular movies right now on Movie Advisor. See what’s trending and don’t miss out on the latest hits.'
|
||||
title: `Popular Movies | ${TITLE}`,
|
||||
description: `Check out the most popular movies right now on ${TITLE}. See what’s trending and don’t miss out on the latest hits.`
|
||||
};
|
||||
|
||||
const Popular = () => {
|
||||
const Popular = async () => {
|
||||
const queryClient = getQueryClient();
|
||||
|
||||
queryClient.prefetchInfiniteQuery(popularQuery());
|
||||
await queryClient.prefetchInfiniteQuery(popularQuery());
|
||||
|
||||
return (
|
||||
<HydrationBoundary state={dehydrate(queryClient)}>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
'use client';
|
||||
|
||||
import popularQuery from '@/api/queries/popular';
|
||||
import popularQuery from '@/data/queries/popular';
|
||||
import useInfiniteList from '@/hooks/useInfiniteList';
|
||||
|
||||
const usePopular = () => useInfiniteList(popularQuery());
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
import { dehydrate, HydrationBoundary } from '@tanstack/react-query';
|
||||
|
||||
import similarQuery from '@/api/queries/similar';
|
||||
import similarQuery from '@/data/queries/similar';
|
||||
import getQueryClient from '@/lib/queryClient';
|
||||
|
||||
import Container from './container';
|
||||
|
||||
const Similar = ({ searchParams }: { searchParams: Record<string, string> }) => {
|
||||
const Similar = async ({ searchParams }: { searchParams: Record<string, string> }) => {
|
||||
const queryClient = getQueryClient();
|
||||
|
||||
const { id, type } = searchParams || {};
|
||||
|
||||
queryClient.prefetchInfiniteQuery(similarQuery({ showId: id, showType: type as Show['type'] }));
|
||||
await queryClient.prefetchInfiniteQuery(similarQuery({ showId: id, showType: type as Show['type'] }));
|
||||
|
||||
return (
|
||||
<HydrationBoundary state={dehydrate(queryClient)}>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
'use client';
|
||||
|
||||
import similarQuery from '@/api/queries/similar';
|
||||
import similarQuery from '@/data/queries/similar';
|
||||
import useInfiniteList from '@/hooks/useInfiniteList';
|
||||
|
||||
interface Props {
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
import { dehydrate, HydrationBoundary } from '@tanstack/react-query';
|
||||
|
||||
import popularQuery from '@/api/queries/popular';
|
||||
import popularQuery from '@/data/queries/popular';
|
||||
import getQueryClient from '@/lib/queryClient';
|
||||
|
||||
import Container from './container';
|
||||
|
||||
const Starring = ({ searchParams }: { searchParams: Record<string, string> }) => {
|
||||
const Starring = async ({ searchParams }: { searchParams: Record<string, string> }) => {
|
||||
const queryClient = getQueryClient();
|
||||
|
||||
const { actorId } = searchParams || {};
|
||||
|
||||
queryClient.prefetchInfiniteQuery(popularQuery({ sortBy: 'vote_average.desc', starring: actorId }));
|
||||
await queryClient.prefetchInfiniteQuery(popularQuery({ sortBy: 'vote_average.desc', starring: actorId }));
|
||||
|
||||
return (
|
||||
<HydrationBoundary state={dehydrate(queryClient)}>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
'use client';
|
||||
|
||||
import popularQuery from '@/api/queries/popular';
|
||||
import popularQuery from '@/data/queries/popular';
|
||||
import useInfiniteList from '@/hooks/useInfiniteList';
|
||||
|
||||
const useStarring = ({ actorId }: { actorId?: string }) =>
|
||||
|
||||
@@ -1,21 +1,21 @@
|
||||
import { dehydrate, HydrationBoundary } from '@tanstack/react-query';
|
||||
import { Metadata } from 'next';
|
||||
|
||||
import popularQuery from '@/api/queries/popular';
|
||||
import popularQuery from '@/data/queries/popular';
|
||||
import { TITLE } from '@/env';
|
||||
import getQueryClient from '@/lib/queryClient';
|
||||
|
||||
import Container from './container';
|
||||
|
||||
export const metadata: Metadata = {
|
||||
title: 'Top Rated Movies | Movie Advisor',
|
||||
description:
|
||||
'Discover the top-rated movies on Movie Advisor. Find the highest-rated films and make informed viewing choices.'
|
||||
title: `Top Rated Movies | ${TITLE}`,
|
||||
description: `Discover the top-rated movies on ${TITLE}. Find the highest-rated films and make informed viewing choices.`
|
||||
};
|
||||
|
||||
const Top = () => {
|
||||
const Top = async () => {
|
||||
const queryClient = getQueryClient();
|
||||
|
||||
queryClient.prefetchInfiniteQuery(popularQuery({ sortBy: 'vote_average.desc' }));
|
||||
await queryClient.prefetchInfiniteQuery(popularQuery({ sortBy: 'vote_average.desc' }));
|
||||
|
||||
return (
|
||||
<HydrationBoundary state={dehydrate(queryClient)}>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
'use client';
|
||||
|
||||
import popularQuery from '@/api/queries/popular';
|
||||
import popularQuery from '@/data/queries/popular';
|
||||
import useInfiniteList from '@/hooks/useInfiniteList';
|
||||
|
||||
const useTop = () => useInfiniteList(popularQuery({ sortBy: 'vote_average.desc' }));
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
import UsersList from '@/components/UsersLists';
|
||||
|
||||
const Container = () => <UsersList list='watchlist' label='watch' />;
|
||||
|
||||
export default Container;
|
||||
@@ -1,29 +1,31 @@
|
||||
import { dehydrate, HydrationBoundary } from '@tanstack/react-query';
|
||||
import { Metadata } from 'next';
|
||||
|
||||
import { session } from '@/api';
|
||||
import usersShowsQuery from '@/api/queries/usersShows';
|
||||
import UsersList from '@/components/UsersLists';
|
||||
import { session as getSession } from '@/data';
|
||||
import usersShowsQuery from '@/data/queries/usersShows';
|
||||
import { TITLE } from '@/env';
|
||||
import getQueryClient from '@/lib/queryClient';
|
||||
|
||||
import Container from './container';
|
||||
|
||||
export const metadata: Metadata = {
|
||||
title: 'My watch list - Movie Advisor',
|
||||
description:
|
||||
'View your favorite shows on Movie Advisor. Keep track of films you’ve added and revisit your top picks anytime.'
|
||||
title: `My watch list - ${TITLE}`,
|
||||
description: `View your favorite shows on ${TITLE}. Keep track of films you’ve added and revisit your top picks anytime.`
|
||||
};
|
||||
|
||||
const WatchList = () => {
|
||||
const WatchList = async () => {
|
||||
const session = await getSession();
|
||||
const queryClient = getQueryClient();
|
||||
|
||||
const list = 'watchlist';
|
||||
const showType = 'movie';
|
||||
|
||||
queryClient.prefetchInfiniteQuery(usersShowsQuery({ showType, list, session: session() }));
|
||||
if (session) {
|
||||
await queryClient.prefetchInfiniteQuery(usersShowsQuery({ showType, list, session }));
|
||||
}
|
||||
|
||||
return (
|
||||
<HydrationBoundary state={dehydrate(queryClient)}>
|
||||
<Container />
|
||||
<UsersList session={session} list={list} label='watch' />
|
||||
</HydrationBoundary>
|
||||
);
|
||||
};
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { NextRequest, NextResponse } from 'next/server';
|
||||
|
||||
import tlk from '@/api/parsers/tlk';
|
||||
import tlk from '@/data/parsers/tlk';
|
||||
|
||||
export async function GET({ nextUrl: { searchParams } }: NextRequest) {
|
||||
const url = searchParams.get('url') as string;
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
import { NextRequest, NextResponse } from 'next/server';
|
||||
|
||||
import { MOVIE_DB_TOKEN } from '@/env';
|
||||
|
||||
type TMDBParams = {
|
||||
params: {
|
||||
path: string[];
|
||||
@@ -11,7 +13,7 @@ export async function GET({ nextUrl: { searchParams } }: NextRequest, { params:
|
||||
const response = await fetch(`https://api.themoviedb.org/3/${path.join('/')}?${searchParams.toString()}`, {
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
Authorization: `Bearer ${process.env.MOVIE_DB_TOKEN}`
|
||||
Authorization: `Bearer ${MOVIE_DB_TOKEN}`
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import { NextRequest, NextResponse } from 'next/server';
|
||||
|
||||
import { Sort } from '@/api/parsers';
|
||||
import tlk from '@/api/parsers/tlk';
|
||||
import tpb from '@/api/parsers/tpb';
|
||||
import yts from '@/api/parsers/yts';
|
||||
import { Sort } from '@/data/parsers';
|
||||
import tlk from '@/data/parsers/tlk';
|
||||
import tpb from '@/data/parsers/tpb';
|
||||
import yts from '@/data/parsers/yts';
|
||||
|
||||
export async function GET({ nextUrl: { searchParams } }: NextRequest) {
|
||||
const key = searchParams.get('key') as keyof typeof providers;
|
||||
|
||||
+14
-14
@@ -4,20 +4,20 @@ import { Jost } from 'next/font/google';
|
||||
import { cookies } from 'next/headers';
|
||||
|
||||
import Header from '@/components/Header';
|
||||
import { SITE_URL, TITLE } from '@/env';
|
||||
import Providers from '@/providers';
|
||||
|
||||
import '@/styles/index.css';
|
||||
|
||||
const title = 'Movie Advisor';
|
||||
const productionUrl = `https://${process.env.NEXT_PUBLIC_VERCEL_PROJECT_PRODUCTION_URL}`;
|
||||
|
||||
export const metadata: Metadata = {
|
||||
title: `${title} | Discover Your Next Favorite Movie`,
|
||||
description: `Explore a diverse selection of movies with ${title}. Get random movie recommendations and find out top-rated, popular, and user-favorite films.`
|
||||
title: `${TITLE} | Discover Your Next Favorite Movie`,
|
||||
description: `Explore a diverse selection of movies with ${TITLE}. Get random movie recommendations and find out top-rated, popular, and user-favorite films.`
|
||||
};
|
||||
|
||||
export const viewport: Viewport = {
|
||||
width: 'device-width'
|
||||
width: 'device-width',
|
||||
initialScale: 1,
|
||||
viewportFit: 'cover'
|
||||
};
|
||||
|
||||
const font = Jost({ subsets: ['latin', 'cyrillic'], weight: ['400'] });
|
||||
@@ -34,22 +34,22 @@ const RootLayout = ({ children }: { children: ReactNode }) => {
|
||||
<link rel='icon' type='image/svg+xml' href='/favicon.svg' />
|
||||
<link rel='shortcut icon' href='/favicon.ico' />
|
||||
<link rel='apple-touch-icon' sizes='180x180' href='/apple-touch-icon.png' />
|
||||
<meta name='apple-mobile-web-app-title' content='Movie Advisor' />
|
||||
<meta name='apple-mobile-web-app-title' content={TITLE} />
|
||||
|
||||
<link rel='manifest' href='/manifest.json' />
|
||||
|
||||
<meta name='twitter:card' content={metadata.description!} />
|
||||
<meta name='twitter:url' content={productionUrl} />
|
||||
<meta name='twitter:title' content={title} />
|
||||
<meta name='twitter:url' content={SITE_URL} />
|
||||
<meta name='twitter:title' content={TITLE} />
|
||||
<meta name='twitter:description' content={metadata.description!} />
|
||||
<meta name='twitter:image' content={`${productionUrl}/web-app-manifest-512x512.png`} />
|
||||
<meta name='twitter:image' content={`${SITE_URL}/web-app-manifest-512x512.png`} />
|
||||
<meta name='twitter:creator' content='https://github.com/noisy5ilence' />
|
||||
<meta property='og:type' content='website' />
|
||||
<meta property='og:title' content={title} />
|
||||
<meta property='og:title' content={TITLE} />
|
||||
<meta property='og:description' content={metadata.description!} />
|
||||
<meta property='og:site_name' content={title} />
|
||||
<meta property='og:url' content={productionUrl} />
|
||||
<meta property='og:image' content={`${productionUrl}/apple-touch-icon.png`} />
|
||||
<meta property='og:site_name' content={TITLE} />
|
||||
<meta property='og:url' content={SITE_URL} />
|
||||
<meta property='og:image' content={`${SITE_URL}/apple-touch-icon.png`} />
|
||||
</head>
|
||||
<body className={font.className}>
|
||||
<Providers theme={theme}>
|
||||
|
||||
@@ -1,27 +0,0 @@
|
||||
import type { MetadataRoute } from 'next';
|
||||
|
||||
const manifest = (): MetadataRoute.Manifest => ({
|
||||
name: 'Movie Advisor',
|
||||
short_name: 'Movie Advisor',
|
||||
description:
|
||||
'Explore a diverse selection of movies with Movie Advisor. Get random movie recommendations and find out top-rated, popular, and user-favorite films.',
|
||||
start_url: '/',
|
||||
display: 'standalone',
|
||||
orientation: 'portrait',
|
||||
background_color: '#ffffff',
|
||||
theme_color: '#000000',
|
||||
icons: [
|
||||
{
|
||||
src: '/web-app-manifest-192x192.png',
|
||||
sizes: '192x192',
|
||||
type: 'image/png'
|
||||
},
|
||||
{
|
||||
src: '/web-app-manifest-512x512.png',
|
||||
sizes: '512x512',
|
||||
type: 'image/png'
|
||||
}
|
||||
]
|
||||
});
|
||||
|
||||
export default manifest;
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useRef } from 'react';
|
||||
|
||||
import searchQuery, { SearchQueryProps } from '@/api/queries/search';
|
||||
import searchQuery, { SearchQueryProps } from '@/data/queries/search';
|
||||
import useInfiniteList from '@/hooks/useInfiniteList';
|
||||
|
||||
const useSearch = (props: SearchQueryProps) => {
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
import { useRef } from 'react';
|
||||
import { useMutation } from '@tanstack/react-query';
|
||||
|
||||
import { createRequestToken, createSession } from '@/api';
|
||||
import { useSetSession } from '@/hooks/useSession';
|
||||
|
||||
import { createRequestToken, createSession } from '../../../../data';
|
||||
|
||||
const useAuth = () => {
|
||||
const setSession = useSetSession();
|
||||
const tabRef = useRef<Window | null>(null);
|
||||
|
||||
@@ -5,7 +5,7 @@ import { useSetSession } from '@/hooks/useSession';
|
||||
const useLogOut = () => {
|
||||
const setSession = useSetSession();
|
||||
|
||||
return useCallback(() => setSession(null), [setSession]);
|
||||
return useCallback(() => setSession(undefined), [setSession]);
|
||||
};
|
||||
|
||||
export default useLogOut;
|
||||
@@ -2,6 +2,7 @@ import { FC } from 'react';
|
||||
import Link from 'next/link';
|
||||
|
||||
import { Badge } from '@/components/ui/badge';
|
||||
import { TITLE } from '@/env';
|
||||
import { cn } from '@/lib/utils';
|
||||
|
||||
import { DesktopNavigation, MobileNavigation } from './components/Navigation';
|
||||
@@ -23,9 +24,7 @@ const Header: FC<Props> = ({ className }) => (
|
||||
<div className='container'>
|
||||
<div className='flex items-center justify-between gap-2 xs:flex-nowrap'>
|
||||
<Link shallow href='/'>
|
||||
<Badge className='cursor-pointer whitespace-nowrap text-[15px] font-normal leading-[18px]'>
|
||||
Movie advisor
|
||||
</Badge>
|
||||
<Badge className='cursor-pointer whitespace-nowrap text-[15px] font-normal leading-[18px]'>{TITLE}</Badge>
|
||||
</Link>
|
||||
<DesktopNavigation />
|
||||
<div className='flex items-center gap-2'>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
|
||||
import creditsQuery, { CreditsQueryProps } from '@/api/queries/credits';
|
||||
import creditsQuery, { CreditsQueryProps } from '@/data/queries/credits';
|
||||
|
||||
const useCredits = ({ showId, showType }: CreditsQueryProps) => {
|
||||
return useQuery(creditsQuery({ showId, showType }));
|
||||
|
||||
@@ -1,16 +1,15 @@
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
|
||||
import { STREAM_URL as BASE_STREAM_URL } from '../../constants';
|
||||
import { STREAM_URL } from '@/env';
|
||||
|
||||
export type Source = { name: string; src: string; type: string };
|
||||
type Sources = { subtitles: Source[]; videos: Source[] };
|
||||
|
||||
const useFiles = (magnet: string) => {
|
||||
const STREAM_URL = `${BASE_STREAM_URL}${encodeURIComponent(magnet)}`;
|
||||
|
||||
const streamUrl = `${STREAM_URL}?link=${encodeURIComponent(magnet)}`;
|
||||
const query = useQuery<Stream>({
|
||||
queryKey: ['files', magnet],
|
||||
queryFn: () => fetch(`${STREAM_URL}&stat`).then((response) => response.json())
|
||||
queryFn: () => fetch(`${streamUrl}&stat`).then((response) => response.json())
|
||||
});
|
||||
|
||||
return {
|
||||
@@ -18,11 +17,11 @@ const useFiles = (magnet: string) => {
|
||||
data: (query.data?.file_stats || []).reduce<Sources>(
|
||||
(sources, file) => {
|
||||
if (file.path.endsWith('.mp4')) {
|
||||
sources.videos.push({ src: `${STREAM_URL}&index=${file.id}&play`, name: file.path, type: 'video/mp4' });
|
||||
sources.videos.push({ src: `${streamUrl}&index=${file.id}&play`, name: file.path, type: 'video/mp4' });
|
||||
}
|
||||
|
||||
if (file.path.endsWith('.srt')) {
|
||||
sources.subtitles.push({ src: `${STREAM_URL}&index=${file.id}&play`, name: file.path, type: 'srt' });
|
||||
sources.subtitles.push({ src: `${streamUrl}&index=${file.id}&play`, name: file.path, type: 'srt' });
|
||||
}
|
||||
|
||||
return sources;
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import { FC } from 'react';
|
||||
import { ArrowDownIcon } from 'lucide-react';
|
||||
|
||||
import { Sort } from '@/api/parsers';
|
||||
import { TableHead } from '@/components/ui/table';
|
||||
import { Sort } from '@/data/parsers';
|
||||
import { cn } from '@/lib/utils';
|
||||
|
||||
interface Props {
|
||||
|
||||
+3
-2
@@ -1,9 +1,10 @@
|
||||
import { FC } from 'react';
|
||||
import { Cast, Download, ListVideo, Loader, Magnet, Play } from 'lucide-react';
|
||||
|
||||
import { Quality } from '@/api/parsers/yts/models';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import ButtonsGroup from '@/components/ui/buttons-group';
|
||||
import { Quality } from '@/data/parsers/yts/models';
|
||||
import { STREAM_URL } from '@/env';
|
||||
import { cn } from '@/lib/utils';
|
||||
|
||||
import { providers } from '../../../../constants';
|
||||
@@ -55,7 +56,7 @@ const Actions: FC<Props> = ({ torrent, backdrop, title, provider }) => {
|
||||
<Button variant='outline' className='relative grow-0 px-3' title='Download m3u playlist'>
|
||||
<a
|
||||
className='absolute left-0 top-0 size-full'
|
||||
href={`${process.env.NEXT_PUBLIC_TORRENT_PROXY}/stream?m3u&link=${encodeURIComponent(magnet)}`}
|
||||
href={`${STREAM_URL}?m3u&link=${encodeURIComponent(magnet)}`}
|
||||
/>
|
||||
<ListVideo size={20} />
|
||||
</Button>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { FC, Fragment } from 'react';
|
||||
|
||||
import { Sort } from '@/api/parsers';
|
||||
import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow } from '@/components/ui/table';
|
||||
import { Sort } from '@/data/parsers';
|
||||
|
||||
import showHostManagerModal from '../HostManager';
|
||||
import TableHeadSortable from '../TableHeadSortable';
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import { Sort } from '@/api/parsers';
|
||||
|
||||
export const STREAM_URL = `${process.env.NEXT_PUBLIC_TORRENT_PROXY}/stream?link=`;
|
||||
import { Sort } from '@/data/parsers';
|
||||
|
||||
type Options = { query: string; sort: Sort; imdbID: string };
|
||||
|
||||
|
||||
@@ -3,10 +3,10 @@ import { create, InstanceProps } from 'react-modal-promise';
|
||||
import { TabsContent } from '@radix-ui/react-tabs';
|
||||
import { Loader } from 'lucide-react';
|
||||
|
||||
import { Sort } from '@/api/parsers';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Modal } from '@/components/ui/dialog';
|
||||
import { Tabs, TabsList, TabsTrigger } from '@/components/ui/tabs';
|
||||
import { Sort } from '@/data/parsers';
|
||||
|
||||
import TorrentsTable from './components/TorrentsTable';
|
||||
import { providers } from './constants';
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
|
||||
import { Sort } from '@/api/parsers';
|
||||
import { Sort } from '@/data/parsers';
|
||||
|
||||
const useTorrents = ({
|
||||
query,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
|
||||
import detailsQuery from '@/api/queries/details';
|
||||
import detailsQuery from '@/data/queries/details';
|
||||
|
||||
interface Props {
|
||||
showId?: Show['id'];
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
import { startTransition, useCallback } from 'react';
|
||||
import { atom, getDefaultStore, useAtom } from 'jotai';
|
||||
|
||||
import randomQuery from '@/api/queries/random';
|
||||
import randomQuery from '@/data/queries/random';
|
||||
import useInfiniteList from '@/hooks/useInfiniteList';
|
||||
|
||||
const indexAtom = atom(0);
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
|
||||
import trendingQuery, { TrendingQueryProps } from '@/api/queries/trending';
|
||||
import trendingQuery, { TrendingQueryProps } from '@/data/queries/trending';
|
||||
|
||||
const useTrending = ({ type }: TrendingQueryProps) => useQuery(trendingQuery({ type }));
|
||||
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
import { FC } from 'react';
|
||||
|
||||
import List from '@/components/List';
|
||||
import useMounted from '@/hooks/useMounted';
|
||||
import useUsersShows from '@/hooks/useUsersShows';
|
||||
|
||||
import { Tabs, TabsContent, TabsList, TabsTrigger } from '../ui/tabs';
|
||||
@@ -11,21 +10,18 @@ import { Tabs, TabsContent, TabsList, TabsTrigger } from '../ui/tabs';
|
||||
interface Props {
|
||||
list: 'favorite' | 'watchlist';
|
||||
label: string;
|
||||
session?: string;
|
||||
}
|
||||
|
||||
const UsersList: FC<Props> = ({ list, label }) => {
|
||||
const isMounted = useMounted();
|
||||
|
||||
const movies = useUsersShows({ list, showType: 'movie' });
|
||||
const series = useUsersShows({ list, showType: 'tv' });
|
||||
const UsersList: FC<Props> = ({ list, label, session }) => {
|
||||
const movies = useUsersShows({ list, showType: 'movie', session });
|
||||
const series = useUsersShows({ list, showType: 'tv', session });
|
||||
|
||||
const tabs = [
|
||||
{ query: movies, title: 'Movies', key: 'movie' as const },
|
||||
{ query: series, title: 'Series', key: 'tv' as const }
|
||||
];
|
||||
|
||||
if (!isMounted) return null;
|
||||
|
||||
return (
|
||||
<Tabs defaultValue='movie' className='flex w-full flex-col items-center'>
|
||||
<TabsList className='grid w-full grid-cols-2 sm:w-[300px]'>
|
||||
|
||||
@@ -178,11 +178,10 @@ const Modal: React.FC<{
|
||||
React.useLayoutEffect(() => {
|
||||
const viewport = document.querySelector('[name="viewport"]');
|
||||
|
||||
viewport?.setAttribute('content', 'width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no');
|
||||
|
||||
return () => {
|
||||
viewport?.setAttribute('content', 'width=device-width, initial-scale=1.0');
|
||||
};
|
||||
viewport?.setAttribute(
|
||||
'content',
|
||||
'width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, viewport-fit=cover'
|
||||
);
|
||||
}, []);
|
||||
|
||||
const handleClose = () => {
|
||||
|
||||
File renamed without changes.
@@ -0,0 +1,10 @@
|
||||
import Http from './Http';
|
||||
|
||||
const BASE =
|
||||
process.env.NEXT_PUBLIC_VERCEL_ENV === 'production'
|
||||
? process.env.NEXT_PUBLIC_VERCEL_PROJECT_PRODUCTION_URL
|
||||
: process.env.NEXT_PUBLIC_VERCEL_URL;
|
||||
|
||||
const movieAdvisor = new Http(`${BASE?.startsWith('http') ? BASE : `https://${BASE}`}/api/tmdb`);
|
||||
|
||||
export default movieAdvisor;
|
||||
@@ -1,5 +1,7 @@
|
||||
import { MOVIE_DB_TOKEN } from '@/env';
|
||||
|
||||
import Http from './Http';
|
||||
|
||||
const theMovieDb = new Http('https://api.themoviedb.org/3', `Bearer ${process.env.MOVIE_DB_TOKEN}`);
|
||||
const theMovieDb = new Http('https://api.themoviedb.org/3', `Bearer ${MOVIE_DB_TOKEN}`);
|
||||
|
||||
export default theMovieDb;
|
||||
File renamed without changes.
@@ -2,10 +2,10 @@
|
||||
|
||||
import { cookies } from 'next/headers';
|
||||
|
||||
import mapMoviesSeriesResponseToShows from './dto/Show';
|
||||
import http from './clients/theMovieDb';
|
||||
import mapMoviesSeriesResponseToShows from './dto/Show';
|
||||
|
||||
export const session = () => cookies().get('session')?.value;
|
||||
export const session = async () => cookies().get('session')?.value;
|
||||
|
||||
export const createRequestToken = async () => {
|
||||
return http.get<RequestToken>('/authentication/token/new', { preventCache: true }).then(({ request_token }) => ({
|
||||
@@ -23,14 +23,14 @@ export const createSession = async ({ requestToken }: { requestToken: string })
|
||||
|
||||
export const account = async () => {
|
||||
return http.get<Account>('/account/null', {
|
||||
params: { session_id: session() },
|
||||
params: { session_id: await session() },
|
||||
preventCache: true
|
||||
});
|
||||
};
|
||||
|
||||
export const accountStates = async ({ showId, showType }: { showId: Show['id']; showType: Show['type'] }) => {
|
||||
return http.get<ShowState>(`/${showType}/${showId}/account_states`, {
|
||||
params: { session_id: session() },
|
||||
params: { session_id: await session() },
|
||||
preventCache: true
|
||||
});
|
||||
};
|
||||
@@ -48,7 +48,7 @@ export const updateAccountStates = async ({
|
||||
}) => {
|
||||
http.post(
|
||||
`/account/null/${list}`,
|
||||
{ params: { session_id: session() }, preventCache: true },
|
||||
{ params: { session_id: await session() }, preventCache: true },
|
||||
{
|
||||
media_id: showId,
|
||||
media_type: showType,
|
||||
@@ -68,7 +68,7 @@ export const usersShows = async ({
|
||||
}): Promise<Pagination<Show>> => {
|
||||
return http
|
||||
.get<TMDBPagination<Movie>>(`/account/null/${list}/${showType === 'tv' ? 'tv' : 'movies'}`, {
|
||||
params: { page, sort_by: 'created_at.desc', session_id: session() },
|
||||
params: { page, sort_by: 'created_at.desc', session_id: await session() },
|
||||
preventCache: true
|
||||
})
|
||||
.then((response) => mapMoviesSeriesResponseToShows(response, showType));
|
||||
File renamed without changes.
@@ -1,11 +1,11 @@
|
||||
import axios, { AxiosInstance } from 'axios';
|
||||
import torrentTitle from 'parse-torrent-title';
|
||||
import { load } from 'cheerio';
|
||||
|
||||
import parseTorrent, { Instance } from 'parse-torrent';
|
||||
|
||||
import { CookieJar } from 'tough-cookie';
|
||||
import { wrapper } from 'axios-cookiejar-support';
|
||||
import { load } from 'cheerio';
|
||||
import parseTorrent, { Instance } from 'parse-torrent';
|
||||
import torrentTitle from 'parse-torrent-title';
|
||||
import { CookieJar } from 'tough-cookie';
|
||||
|
||||
import { TOLOKA_HOST, TOLOKA_PASSWORD, TOLOKA_USERNAME } from '@/env';
|
||||
|
||||
import { Sort } from '../index';
|
||||
|
||||
@@ -22,7 +22,7 @@ export class Toloka {
|
||||
private magnets: Record<string, string> = {};
|
||||
|
||||
constructor() {
|
||||
this.host = process.env.TOLOKA_HOST || 'https://toloka.to';
|
||||
this.host = TOLOKA_HOST || 'https://toloka.to';
|
||||
|
||||
this.client = wrapper(
|
||||
axios.create({
|
||||
@@ -40,8 +40,8 @@ export class Toloka {
|
||||
private async auth() {
|
||||
const data = new FormData();
|
||||
|
||||
data.append('username', process.env.TOLOKA_USERNAME as string);
|
||||
data.append('password', process.env.TOLOKA_PASSWORD as string);
|
||||
data.append('username', TOLOKA_USERNAME as string);
|
||||
data.append('password', TOLOKA_PASSWORD as string);
|
||||
data.append('autologin', 'on');
|
||||
data.append('ssl', 'on');
|
||||
data.append('login', 'Вхід');
|
||||
@@ -2,6 +2,8 @@ import axios, { AxiosInstance } from 'axios';
|
||||
import { load } from 'cheerio';
|
||||
import torrentTitle from 'parse-torrent-title';
|
||||
|
||||
import { PIRATE_BAY_HOST } from '@/env';
|
||||
|
||||
import { Sort } from '../index';
|
||||
|
||||
export class PirateBay {
|
||||
@@ -13,7 +15,7 @@ export class PirateBay {
|
||||
};
|
||||
|
||||
constructor() {
|
||||
this.host = process.env.PIRATE_BAY_HOST || 'https://thepiratebay10.info';
|
||||
this.host = PIRATE_BAY_HOST || 'https://thepiratebay10.info';
|
||||
|
||||
this.client = axios.create({
|
||||
baseURL: this.host
|
||||
@@ -1,5 +1,7 @@
|
||||
import axios, { AxiosInstance } from 'axios';
|
||||
|
||||
import { YTS_HOST } from '@/env';
|
||||
|
||||
import { Sort } from '../index';
|
||||
|
||||
import { YTSResponse } from './models';
|
||||
@@ -9,7 +11,7 @@ export class YTS {
|
||||
private host: string;
|
||||
|
||||
constructor() {
|
||||
this.host = process.env.YTS_HOST || 'https://yts.mx/api/v2/list_movies.json';
|
||||
this.host = YTS_HOST || 'https://yts.mx/api/v2/list_movies.json';
|
||||
|
||||
this.client = axios.create({
|
||||
baseURL: this.host
|
||||
File renamed without changes.
File renamed without changes.
@@ -10,9 +10,9 @@ const creditsQuery = ({ showId, showType }: CreditsQueryProps) => ({
|
||||
queryKey: ['credits', showId, showType],
|
||||
queryFn: () =>
|
||||
movieAdvisor
|
||||
.get<{ cast: Array<Actor | AggregatedActor> }>(
|
||||
`/${showType}/${showId}/${showType === 'tv' ? 'aggregate_credits' : 'credits'}`
|
||||
)
|
||||
.get<{
|
||||
cast: Array<Actor | AggregatedActor>;
|
||||
}>(`/${showType}/${showId}/${showType === 'tv' ? 'aggregate_credits' : 'credits'}`)
|
||||
.then(({ cast }) => {
|
||||
return cast
|
||||
.filter((person) => person.profile_path)
|
||||
File renamed without changes.
File renamed without changes.
@@ -1,4 +1,5 @@
|
||||
import { createUniqueRandomGenerator } from '@/lib/utils';
|
||||
|
||||
import movieAdvisor from '../clients/movieAdvisor';
|
||||
import mapMoviesSeriesResponseToShows from '../dto/Show';
|
||||
|
||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -0,0 +1,16 @@
|
||||
export const TITLE = process.env.NEXT_PUBLIC_TITLE || 'Movie Advisor';
|
||||
|
||||
const BASE =
|
||||
process.env.NEXT_PUBLIC_VERCEL_ENV === 'production'
|
||||
? process.env.NEXT_PUBLIC_VERCEL_PROJECT_PRODUCTION_URL
|
||||
: process.env.NEXT_PUBLIC_VERCEL_URL;
|
||||
export const SITE_URL = `${BASE?.startsWith('http') ? BASE : `https://${BASE}`}`;
|
||||
export const MOVIE_DB_TOKEN = process.env.MOVIE_DB_TOKEN;
|
||||
export const STREAM_URL = `${process.env.NEXT_PUBLIC_TORRENT_PROXY}/stream`;
|
||||
|
||||
export const TOLOKA_HOST = process.env.TOLOKA_HOST;
|
||||
export const TOLOKA_USERNAME = process.env.TOLOKA_USERNAME;
|
||||
export const TOLOKA_PASSWORD = process.env.TOLOKA_PASSWORD;
|
||||
|
||||
export const PIRATE_BAY_HOST = process.env.PIRATE_BAY_HOST;
|
||||
export const YTS_HOST = process.env.YTS_HOST;
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
import { useQuery, useQueryClient } from '@tanstack/react-query';
|
||||
|
||||
import accountQuery from '@/data/queries/account';
|
||||
import { useSession } from '@/hooks/useSession';
|
||||
import accountQuery from '@/api/queries/account';
|
||||
|
||||
const useAccount = () => {
|
||||
const queryClient = useQueryClient();
|
||||
|
||||
+2
-2
@@ -2,7 +2,7 @@ import { useCallback } from 'react';
|
||||
import { atom, useAtomValue, useSetAtom } from 'jotai';
|
||||
import Cookies from 'js-cookie';
|
||||
|
||||
const sessionAtom = atom<string | null>(Cookies.get('session') as string);
|
||||
const sessionAtom = atom<string | undefined>(Cookies.get('session') as string);
|
||||
|
||||
export const useSession = () => useAtomValue(sessionAtom);
|
||||
|
||||
@@ -10,7 +10,7 @@ export const useSetSession = () => {
|
||||
const setSession = useSetAtom(sessionAtom);
|
||||
|
||||
return useCallback(
|
||||
(session: string | null) => {
|
||||
(session: string | undefined) => {
|
||||
typeof session === 'string' ? Cookies.set('session', session) : Cookies.remove('session');
|
||||
setSession(session);
|
||||
},
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import { useMutation, useQuery, useQueryClient } from '@tanstack/react-query';
|
||||
|
||||
import { accountStates, updateAccountStates } from '@/api';
|
||||
import { KEY as USERS_SHOWS_KEY } from '@/data/queries/usersShows';
|
||||
|
||||
import { accountStates, updateAccountStates } from '../data';
|
||||
|
||||
import { useFavorites, useFavoritesStateToggle, useWatchList, useWatchListStateToggle } from './useLocalUsersLists';
|
||||
import { useSession } from './useSession';
|
||||
import { KEY as USERS_SHOWS_KEY } from '@/api/queries/usersShows';
|
||||
|
||||
const KEY = ['show-state'];
|
||||
|
||||
|
||||
+28
-10
@@ -1,28 +1,46 @@
|
||||
'use client';
|
||||
|
||||
import usersShowsQuery from '@/data/queries/usersShows';
|
||||
import useMounted from '@/hooks/useMounted';
|
||||
|
||||
import useInfiniteList from './useInfiniteList';
|
||||
import { useFavorites, useWatchList } from './useLocalUsersLists';
|
||||
import { useSession } from './useSession';
|
||||
import usersShowsQuery from '@/api/queries/usersShows';
|
||||
|
||||
const useUsersShows = ({ showType, list = 'favorite' }: { showType: Show['type']; list: 'favorite' | 'watchlist' }) => {
|
||||
const session = useSession();
|
||||
const useUsersShows = ({
|
||||
showType,
|
||||
list = 'favorite',
|
||||
session: serverSession
|
||||
}: {
|
||||
showType: Show['type'];
|
||||
list: 'favorite' | 'watchlist';
|
||||
session?: string;
|
||||
}) => {
|
||||
const isMounted = useMounted();
|
||||
const clientSession = useSession();
|
||||
|
||||
const session = isMounted ? clientSession : serverSession;
|
||||
|
||||
const { shows: favorite } = useFavorites();
|
||||
const { shows: watchlist } = useWatchList();
|
||||
|
||||
const query = useInfiniteList(usersShowsQuery({ showType, list, session }));
|
||||
const query = useInfiniteList({
|
||||
...usersShowsQuery({ showType, list, session }),
|
||||
enabled: Boolean(session)
|
||||
});
|
||||
|
||||
return session
|
||||
? query
|
||||
: {
|
||||
fetchNextPage: undefined,
|
||||
isLoading: false,
|
||||
isFetched: true,
|
||||
shows: {
|
||||
favorite: favorite.filter((show) => show.type === showType),
|
||||
watchlist: watchlist.filter((show) => show.type === showType)
|
||||
}[list]
|
||||
isLoading: isMounted,
|
||||
isFetched: isMounted,
|
||||
shows: isMounted
|
||||
? {
|
||||
favorite: favorite.filter((show) => show.type === showType),
|
||||
watchlist: watchlist.filter((show) => show.type === showType)
|
||||
}[list]
|
||||
: []
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
Generated
+1140
-53
File diff suppressed because it is too large.
Load diff
+6
-1
@@ -7,6 +7,8 @@
|
||||
"build": "npm run lint && next build",
|
||||
"start": "next start",
|
||||
"lint": "next lint --fix .",
|
||||
"lint-staged": "lint-staged",
|
||||
"type-check": "tsc --project tsconfig.json --pretty --noEmit && echo ",
|
||||
"prepare": "husky"
|
||||
},
|
||||
"dependencies": {
|
||||
@@ -49,12 +51,15 @@
|
||||
"critters": "^0.0.25",
|
||||
"eslint": "8.45.0",
|
||||
"eslint-config-next": "^14.2.7",
|
||||
"eslint-config-prettier": "^9.1.0",
|
||||
"eslint-plugin-prettier": "^5.2.1",
|
||||
"eslint-plugin-simple-import-sort": "^10.0.0",
|
||||
"eslint-plugin-tailwindcss": "^3.17.4",
|
||||
"husky": "^9.1.6",
|
||||
"lint-staged": "^15.2.10",
|
||||
"parse-torrent-title": "^1.4.0",
|
||||
"postcss": "^8.4.27",
|
||||
"prettier": "^3.0.0",
|
||||
"prettier": "^3.3.3",
|
||||
"tailwind-merge": "^1.14.0",
|
||||
"tailwindcss": "^3.3.3",
|
||||
"tailwindcss-animate": "^1.0.7",
|
||||
|
||||
+1
-1
@@ -1 +1 @@
|
||||
if(!self.define){let e,s={};const a=(a,i)=>(a=new URL(a+".js",i).href,s[a]||new Promise((s=>{if("document"in self){const e=document.createElement("script");e.src=a,e.onload=s,document.head.appendChild(e)}else e=a,importScripts(a),s()})).then((()=>{let e=s[a];if(!e)throw new Error(`Module ${a} didn’t register its module`);return e})));self.define=(i,n)=>{const t=e||("document"in self?document.currentScript.src:"")||location.href;if(s[t])return;let c={};const r=e=>a(e,t),d={module:{uri:t},exports:c,require:r};s[t]=Promise.all(i.map((e=>d[e]||r(e)))).then((e=>(n(...e),c)))}}define(["./workbox-4754cb34"],(function(e){"use strict";importScripts(),self.skipWaiting(),e.clientsClaim(),e.precacheAndRoute([{url:"/_next/app-build-manifest.json",revision:"66340b5db798bcae1a642885e64cd821"},{url:"/_next/static/chunks/139-b4e6a1746bb8b121.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/152.3bffe565de0b275e.js",revision:"3bffe565de0b275e"},{url:"/_next/static/chunks/209-017fd57ea964c1ad.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/23-e95fe3862375276d.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/26.286553a5ff2812fc.js",revision:"286553a5ff2812fc"},{url:"/_next/static/chunks/276.c3c1130f2adade69.js",revision:"c3c1130f2adade69"},{url:"/_next/static/chunks/305-b973937e3a05106a.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/344.05938a041227e582.js",revision:"05938a041227e582"},{url:"/_next/static/chunks/383.78d47f7582340f53.js",revision:"78d47f7582340f53"},{url:"/_next/static/chunks/460.ac20021c7496f1d6.js",revision:"ac20021c7496f1d6"},{url:"/_next/static/chunks/497.a16beaad36f500fe.js",revision:"a16beaad36f500fe"},{url:"/_next/static/chunks/61.e269d4a699fba0b6.js",revision:"e269d4a699fba0b6"},{url:"/_next/static/chunks/621-fa4d2ff1cf645813.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/673.362c29137dd3e968.js",revision:"362c29137dd3e968"},{url:"/_next/static/chunks/695.156d21364de6e419.js",revision:"156d21364de6e419"},{url:"/_next/static/chunks/755.5cd959eac5682527.js",revision:"5cd959eac5682527"},{url:"/_next/static/chunks/792.b51012549074b93f.js",revision:"b51012549074b93f"},{url:"/_next/static/chunks/810.6105e84414768b0d.js",revision:"6105e84414768b0d"},{url:"/_next/static/chunks/922.9ce4bf0553cfb724.js",revision:"9ce4bf0553cfb724"},{url:"/_next/static/chunks/931-be9a8cfc748a35be.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/app/(site)/favorites/page-49ed09441e28f9f8.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/app/(site)/loading-96645736797edde7.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/app/(site)/page-e6a63cfd3bebb325.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/app/(site)/popular/page-050c2f1a9ec0177c.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/app/(site)/similar/page-6bce557a9fe61889.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/app/(site)/starring/page-d3c2aba0a8ddf3f7.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/app/(site)/top/page-c81e4ef7f6bae95d.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/app/(site)/watch-list/page-f98db390fd077a72.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/app/_not-found/page-aa0c8e90320336c2.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/app/layout-7a6507735703bbe8.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/c8bcbd21.63daf74955ffea8b.js",revision:"63daf74955ffea8b"},{url:"/_next/static/chunks/fd9d1056-bdf7d185613ab264.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/framework-f66176bb897dc684.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/main-6d2460f512032b99.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/main-app-51cdaff1a81e6b49.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/pages/_app-6a626577ffa902a4.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/pages/_error-1be831200e60c5c0.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/chunks/polyfills-42372ed130431b0a.js",revision:"846118c33b2c0e922d7b3a7676f81f6f"},{url:"/_next/static/chunks/webpack-d508fdfc653a9115.js",revision:"kviqPM4M8-k6Bb4da0rI9"},{url:"/_next/static/css/0d5f6452b2682b9b.css",revision:"0d5f6452b2682b9b"},{url:"/_next/static/css/30fc28b4ca88767d.css",revision:"30fc28b4ca88767d"},{url:"/_next/static/kviqPM4M8-k6Bb4da0rI9/_buildManifest.js",revision:"2ec694eb52ae4f523f265a46bae4d768"},{url:"/_next/static/kviqPM4M8-k6Bb4da0rI9/_ssgManifest.js",revision:"b6652df95db52feb4daf4eca35380933"},{url:"/_next/static/media/a9b1453781eac9e6-s.p.woff2",revision:"c754cf60aba699077f00948285bf54b5"},{url:"/_next/static/media/dd843ebd3ff03195-s.p.woff2",revision:"333341dc4117f45b7fcee6b5223a56db"},{url:"/_next/static/media/e9ecf55e71a874cd-s.woff2",revision:"62348655e2d5baed97a39f0590491d09"},{url:"/apple-touch-icon.png",revision:"6ed7ad7Line truncated
|
||||
if(!self.define){let e,s={};const a=(a,i)=>(a=new URL(a+".js",i).href,s[a]||new Promise((s=>{if("document"in self){const e=document.createElement("script");e.src=a,e.onload=s,document.head.appendChild(e)}else e=a,importScripts(a),s()})).then((()=>{let e=s[a];if(!e)throw new Error(`Module ${a} didn’t register its module`);return e})));self.define=(i,n)=>{const t=e||("document"in self?document.currentScript.src:"")||location.href;if(s[t])return;let c={};const r=e=>a(e,t),o={module:{uri:t},exports:c,require:r};s[t]=Promise.all(i.map((e=>o[e]||r(e)))).then((e=>(n(...e),c)))}}define(["./workbox-4754cb34"],(function(e){"use strict";importScripts(),self.skipWaiting(),e.clientsClaim(),e.precacheAndRoute([{url:"/_next/app-build-manifest.json",revision:"f415a7ade9051b0c1537acf9ed55a083"},{url:"/_next/static/chunks/152.f47729bb9b123937.js",revision:"f47729bb9b123937"},{url:"/_next/static/chunks/18-10b5aadb2f65dcdd.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/209-122137a04eb2adce.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/23-e95fe3862375276d.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/26.286553a5ff2812fc.js",revision:"286553a5ff2812fc"},{url:"/_next/static/chunks/276.c3c1130f2adade69.js",revision:"c3c1130f2adade69"},{url:"/_next/static/chunks/305-b973937e3a05106a.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/344.05938a041227e582.js",revision:"05938a041227e582"},{url:"/_next/static/chunks/383.78d47f7582340f53.js",revision:"78d47f7582340f53"},{url:"/_next/static/chunks/43-1b27b4a4ece03023.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/460.ac20021c7496f1d6.js",revision:"ac20021c7496f1d6"},{url:"/_next/static/chunks/497.48f1dfd129122432.js",revision:"48f1dfd129122432"},{url:"/_next/static/chunks/61.e269d4a699fba0b6.js",revision:"e269d4a699fba0b6"},{url:"/_next/static/chunks/621-fa4d2ff1cf645813.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/673.362c29137dd3e968.js",revision:"362c29137dd3e968"},{url:"/_next/static/chunks/695.156d21364de6e419.js",revision:"156d21364de6e419"},{url:"/_next/static/chunks/755.5cd959eac5682527.js",revision:"5cd959eac5682527"},{url:"/_next/static/chunks/792.b51012549074b93f.js",revision:"b51012549074b93f"},{url:"/_next/static/chunks/810.6105e84414768b0d.js",revision:"6105e84414768b0d"},{url:"/_next/static/chunks/922.9ce4bf0553cfb724.js",revision:"9ce4bf0553cfb724"},{url:"/_next/static/chunks/app/(site)/favorites/page-0dcef32535bf7681.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/app/(site)/loading-96645736797edde7.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/app/(site)/page-391352edf67d4bf1.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/app/(site)/popular/page-047d9b7c4949d909.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/app/(site)/similar/page-0b2f61ca98aff38e.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/app/(site)/starring/page-a30349fc64784ca7.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/app/(site)/top/page-8ed26b82343f54cf.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/app/(site)/watch-list/page-526c511ac32b4e16.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/app/_not-found/page-aa0c8e90320336c2.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/app/layout-aa70c1250bb51638.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/c8bcbd21.63daf74955ffea8b.js",revision:"63daf74955ffea8b"},{url:"/_next/static/chunks/fd9d1056-bdf7d185613ab264.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/framework-f66176bb897dc684.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/main-a339d49e77d6dbd3.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/main-app-51cdaff1a81e6b49.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/pages/_app-6a626577ffa902a4.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/pages/_error-1be831200e60c5c0.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/chunks/polyfills-42372ed130431b0a.js",revision:"846118c33b2c0e922d7b3a7676f81f6f"},{url:"/_next/static/chunks/webpack-0c8c94a0b2c005e4.js",revision:"y3saS9mrX4-jigNe-MjDa"},{url:"/_next/static/css/0d5f6452b2682b9b.css",revision:"0d5f6452b2682b9b"},{url:"/_next/static/css/30fc28b4ca88767d.css",revision:"30fc28b4ca88767d"},{url:"/_next/static/media/a9b1453781eac9e6-s.p.woff2",revision:"c754cf60aba699077f00948285bf54b5"},{url:"/_next/static/media/dd843ebd3ff03195-s.p.woff2",revision:"333341dc4117f45b7fcee6b5223a56db"},{url:"/_next/static/media/e9ecf55e71a874cd-s.woff2",revision:"62348655e2d5baed97a39f0590491d09"},{url:"/_next/static/y3saS9mrX4-jigNe-MjDa/_buildManifest.js",revision:"2ec694eb52ae4f523f265a46bae4d768"},{url:"/_next/static/y3saS9mrX4-jigNe-MjDa/_ssgManifest.js",revision:"b6652df95db52feb4daf4eca35380933"},{url:"/apple-touch-icon.png",revision:"6ed7ad78bLine truncated
|
||||
Reference in new issue
Block a user