diff --git a/README.md b/README.md index b0f2660..a8d8796 100644 --- a/README.md +++ b/README.md @@ -6,10 +6,10 @@ AniX is an unofficial web client for the Android application Anixart. It allows ## Changelog [RU] -- [3.5.0](./public/changelog/3.5.0.md) - [3.4.0](./public/changelog/3.4.0.md) - [3.3.0](./public/changelog/3.3.0.md) - [3.2.3](./public/changelog/3.2.3.md) +- [3.2.2](./public/changelog/3.2.2.md) [other versions](./public/changelog) diff --git a/app/about/page.tsx b/app/about/page.tsx deleted file mode 100644 index a44f27e..0000000 --- a/app/about/page.tsx +++ /dev/null @@ -1,16 +0,0 @@ -export const metadata = { - title: "О приложении", - openGraph: { - title: "AniX - Неофициальный веб клиент для Anixart", - description: - "AniX - это неофициальный веб-клиент для Android-приложения Anixart. Он позволяет вам получать доступ к своей учетной записи Anixart и управлять ею из веб-браузера. Так-же можно синхронизировать и управлять списками и избранным. И самое главное смотреть все доступные аниме из базы Anixart.", - }, -}; - -export const dynamic = "force-static"; - -import { AboutPage } from "#/pages/About"; - -export default function Index() { - return ; -} diff --git a/app/api/config.ts b/app/api/config.ts index d3a25d0..b0b7b9c 100644 --- a/app/api/config.ts +++ b/app/api/config.ts @@ -1,4 +1,4 @@ -export const CURRENT_APP_VERSION = "3.5.0"; +export const CURRENT_APP_VERSION = "3.4.0"; export const API_URL = "https://api.anixart.tv"; export const API_PREFIX = "/api/proxy"; diff --git a/app/components/Navbar/NavbarUpdate.tsx b/app/components/Navbar/NavbarUpdate.tsx index a6219c0..71b74d0 100644 --- a/app/components/Navbar/NavbarUpdate.tsx +++ b/app/components/Navbar/NavbarUpdate.tsx @@ -87,8 +87,8 @@ export const Navbar = () => { return ( <>
-
-
+
+
{menuItems.map((item) => { return ( { item.isAuthRequired && !userStore.isAuth ? "hidden" : item.isShownOnMobile ? "flex" : "hidden sm:flex" - } ${[item.href, item.hrefInCategory].includes("/" + pathname.split("/")[1]) ? "font-bold" : "font-medium"} transition-all`} + } ${[item.href, item.hrefInCategory].includes("/" + pathname.split("/")[1]) ? "font-bold" : "font-medium"}`} > { ); })}
-
+
{!userStore.isAuth ? { : <> { width={24} height={24} /> - + {userStore.user.login} - {preferenceStore.flags.showFifthButton ? - - - - {menuItems[preferenceStore.flags.showFifthButton].title} - - - : ""} { width={24} height={24} /> - + {userStore.user.login} @@ -184,11 +165,7 @@ export const Navbar = () => { onClick={() => setIsSettingModalOpen(true)} > - - Настройки - + Настройки {userStore.isAuth && ( diff --git a/app/components/ReleasePlayer/ReleasePlayerCustom.tsx b/app/components/ReleasePlayer/ReleasePlayerCustom.tsx index 75f62ca..feec08c 100644 --- a/app/components/ReleasePlayer/ReleasePlayerCustom.tsx +++ b/app/components/ReleasePlayer/ReleasePlayerCustom.tsx @@ -342,8 +342,6 @@ export const ReleasePlayerCustom = (props: { setIsLoading(false); }; if (episode.selected) { - setIsLoading(true); - setPlayerError(null); __getInfo(); } }, [episode.selected]); diff --git a/app/components/ReleasePoster/PosterWithStuff.tsx b/app/components/ReleasePoster/PosterWithStuff.tsx index 7ffbee2..adffc49 100644 --- a/app/components/ReleasePoster/PosterWithStuff.tsx +++ b/app/components/ReleasePoster/PosterWithStuff.tsx @@ -83,7 +83,7 @@ export const PosterWithStuff = (props: { return ( {index > 0 && ", "} {genre} @@ -91,18 +91,18 @@ export const PosterWithStuff = (props: { ); })} {props.title_ru && ( -

+

{props.title_ru}

)} {props.title_original && ( -

+

{props.title_original}

)}
{settings.showDescription && props.description && ( -

+

{props.description}

)} diff --git a/app/components/SettingsModal/SettingsModal.tsx b/app/components/SettingsModal/SettingsModal.tsx index 3786e80..39ae318 100644 --- a/app/components/SettingsModal/SettingsModal.tsx +++ b/app/components/SettingsModal/SettingsModal.tsx @@ -1,7 +1,5 @@ "use client"; -import { CURRENT_APP_VERSION } from "#/api/config"; -import { useUserStore } from "#/store/auth"; import { usePreferencesStore } from "#/store/preferences"; import { Modal, @@ -34,17 +32,10 @@ const NavbarTitles = { links: "Только ссылки", selected: "Только выбранные", never: "Никогда", -}; - -const FifthButton = { - 3: "Избранное", - 4: "Коллекции", - 5: "История", -}; +} export const SettingsModal = (props: { isOpen: boolean; setIsOpen: any }) => { const preferenceStore = usePreferencesStore(); - const userStore = useUserStore(); const { computedMode, setMode } = useThemeMode(); @@ -177,66 +168,26 @@ export const SettingsModal = (props: { isOpen: boolean; setIsOpen: any }) => {

- {Object.keys(NavbarTitles).map( - (key: "always" | "links" | "selected" | "never") => { - return ( - - preferenceStore.setFlags({ - showNavbarTitles: key, - }) - } - > - {NavbarTitles[key]} - - ); - } - )} + {Object.keys(NavbarTitles).map((key: "always" | "links" | "selected" | "never") => { + return ( + + preferenceStore.setFlags({ + showNavbarTitles: key, + }) + } + > + {NavbarTitles[key]} + + ); + })}
- {userStore.isAuth ? -
-

- Пятый пункт в навигации -

- - - preferenceStore.setFlags({ - showFifthButton: null, - }) - } - > - Не показывать - - {Object.keys(FifthButton).map((key) => { - return ( - - preferenceStore.setFlags({ - showFifthButton: Number(key) as 3 | 4 | 5, - }) - } - > - {FifthButton[key]} - - ); - })} - -
- : ""}
@@ -327,15 +278,26 @@ export const SettingsModal = (props: { isOpen: boolean; setIsOpen: any }) => {
props.setIsOpen(false)} > - +
-

О приложении

+

Телеграм канал

- v{CURRENT_APP_VERSION} + @anix_web +

+
+ + + +
+

Разработчик

+

+ Radiquum

diff --git a/app/pages/About.tsx b/app/pages/About.tsx deleted file mode 100644 index 851641e..0000000 --- a/app/pages/About.tsx +++ /dev/null @@ -1,136 +0,0 @@ -"use server"; - -import { Card } from "flowbite-react"; -import Image from "next/image"; - -import * as fs from "node:fs"; -import * as path from "node:path"; -import { CURRENT_APP_VERSION } from "#/api/config"; -import Styles from "../components/ChangelogModal/ChangelogModal.module.css"; -import Markdown from "markdown-to-jsx"; - -import { - Accordion, - AccordionContent, - AccordionPanel, - AccordionTitle, -} from "flowbite-react"; -import { version } from "node:os"; -import Link from "next/link"; - -export const AboutPage = () => { - const directoryPath = path.join(process.cwd(), "public/changelog"); - const files = fs.readdirSync(directoryPath); - const current = { - version: CURRENT_APP_VERSION, - changelog: `#${CURRENT_APP_VERSION}\r\nНет списка изменений`, - }; - const previous = []; - - if (files.includes(`${CURRENT_APP_VERSION}.md`)) { - const changelog = fs.readFileSync( - path.join(directoryPath, `${CURRENT_APP_VERSION}.md`), - "utf8" - ); - current.changelog = changelog; - } - - files.forEach((file) => { - if (file != `${CURRENT_APP_VERSION}.md`) { - const changelog = fs.readFileSync(path.join(directoryPath, file), "utf8"); - previous.push({ - version: file.replace(".md", ""), - changelog: changelog, - }); - } - }); - - return ( -
- -
- about image -
-

- AniX - Неофициальный веб клиент для Anixart -

-

- AniX - это неофициальный веб-клиент для Android-приложения - Anixart. Он позволяет вам получать доступ к своей учетной записи - Anixart и управлять ею из веб-браузера. Так-же можно - синхронизировать и управлять списками и избранным. И самое главное - смотреть все доступные аниме из базы Anixart. -

-
-
-
- - -
- developer image -
-

Radiquum

-

- Разработчик -

-
-
-
- - - -
- -
-

Телеграм канал

-

- @anix_web -

-
-
-
- - - -
- -
-

Код на GitHub

-

- github.com/Radiquum/AniX -

-
-
-
- - -

Список изменений

- {current.changelog} - - {previous.reverse().map((changelog) => ( - - v{changelog.version} - - - {changelog.changelog} - - - - ))} - -
-
- ); -}; diff --git a/app/pages/MobileMenuPage.tsx b/app/pages/MobileMenuPage.tsx index f1f73b8..a075e2a 100644 --- a/app/pages/MobileMenuPage.tsx +++ b/app/pages/MobileMenuPage.tsx @@ -6,11 +6,9 @@ import { useRouter } from "next/navigation"; import { SettingsModal } from "#/components/SettingsModal/SettingsModal"; import { useEffect, useState } from "react"; import Image from "next/image"; -import { usePreferencesStore } from "#/store/preferences"; export const MenuPage = () => { const userStore = useUserStore(); - const preferenceStore = usePreferencesStore(); const router = useRouter(); const [isSettingModalOpen, setIsSettingModalOpen] = useState(false); @@ -24,7 +22,7 @@ export const MenuPage = () => { return ( <> {userStore.user && ( -
+
{
- {preferenceStore.flags.showFifthButton != 3 ? - - -
- -

Избранное

+ + +
+ +

Избранное

+
+
+ + + +
+ +

Коллекции

+
+
+ + + +
+ +

История

+
+
+ + + +
+ +
+

Телеграм канал

+

+ @anix_web +

- - - : ""} - {preferenceStore.flags.showFifthButton != 4 ? - - -
- -

Коллекции

+
+
+ + + +
+ +
+

Разработчик

+

+ Radiquum +

- - - : ""} - {preferenceStore.flags.showFifthButton != 5 ? - - -
- -

История

-
-
- - : ""} +
+
+ ()( showChangelog: true, enableAnalytics: true, showNavbarTitles: "always", - showFifthButton: null, }, params: { isFirstLaunch: true, @@ -56,8 +54,8 @@ export const usePreferencesStore = create()( bookmarksCategory: "watching", }, experimental: { - newPlayer: false, - }, + newPlayer: false + } }, setHasHydrated: (state) => { set({ @@ -76,12 +74,9 @@ export const usePreferencesStore = create()( onRehydrateStorage: (state) => { return () => state.setHasHydrated(true); }, - merge: (persistedState, currentState) => { - return deepmerge( - currentState as preferencesState, - persistedState as preferencesState - ); - }, + merge: (persistedState , currentState) => { + return deepmerge(currentState as preferencesState, persistedState as preferencesState); + } } ) ); diff --git a/docs/REAME.RU.md b/docs/REAME.RU.md index b62c36e..cfb0f9f 100644 --- a/docs/REAME.RU.md +++ b/docs/REAME.RU.md @@ -6,10 +6,10 @@ AniX - это неофициальный веб-клиент для Android-пр ## Список изменений -- [3.5.0](/public/changelog/3.5.0.md) - [3.4.0](/public/changelog/3.4.0.md) - [3.3.0](/public/changelog/3.3.0.md) - [3.2.3](/public/changelog/3.2.3.md) +- [3.2.2](/public/changelog/3.2.2.md) [другие версии](/public/changelog) diff --git a/public/changelog/3.5.0.md b/public/changelog/3.5.0.md deleted file mode 100644 index af13131..0000000 --- a/public/changelog/3.5.0.md +++ /dev/null @@ -1,17 +0,0 @@ -# 3.5.0 - -## Добавлено - -- Добавлена страница о приложении -- Добавлена возможность добавить пятую кнопку в меню навигации на мобильных устройствах - -## Изменено - -- Стиль карточек для релизов был изменён на вертикальный -- На мобильных устройствах постер на странице релиза теперь по середине -- Позиция лицензированных сервисов теперь под постером -- На мобильных устройствах позиция меню была смещена вниз - -## Исправлено - -- Ошибка своего плеера не сбрасывалась, если удалось получить ссылку при переключении серии