mirror of
https://github.com/zoriya/Kyoo.git
synced 2026-06-04 13:25:16 -04:00
Parse watch status on the front
This commit is contained in:
@@ -19,7 +19,7 @@
|
||||
*/
|
||||
|
||||
import { ReactElement } from "react";
|
||||
import { MeQuery, Navbar } from "./navbar";
|
||||
import { Navbar } from "./navbar";
|
||||
import { useYoshiki, vw } from "yoshiki/native";
|
||||
import { Main } from "@kyoo/primitives";
|
||||
|
||||
@@ -60,4 +60,3 @@ export const DefaultLayout = ({
|
||||
</>
|
||||
);
|
||||
};
|
||||
DefaultLayout.getFetchUrls = () => [MeQuery];
|
||||
|
||||
@@ -18,15 +18,7 @@
|
||||
* along with Kyoo. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import {
|
||||
deleteAccount,
|
||||
logout,
|
||||
QueryIdentifier,
|
||||
useAccount,
|
||||
useAccounts,
|
||||
User,
|
||||
UserP,
|
||||
} from "@kyoo/models";
|
||||
import { deleteAccount, logout, useAccount, useAccounts } from "@kyoo/models";
|
||||
import {
|
||||
Alert,
|
||||
Input,
|
||||
@@ -49,10 +41,8 @@ import Login from "@material-symbols/svg-400/rounded/login.svg";
|
||||
import Register from "@material-symbols/svg-400/rounded/app_registration.svg";
|
||||
import Logout from "@material-symbols/svg-400/rounded/logout.svg";
|
||||
import Delete from "@material-symbols/svg-400/rounded/delete.svg";
|
||||
import { FetchNE } from "../fetch";
|
||||
import { KyooLongLogo } from "./icon";
|
||||
import { forwardRef, useContext, useEffect, useRef, useState } from "react";
|
||||
import { useQueryClient } from "@tanstack/react-query";
|
||||
import { forwardRef, useEffect, useRef, useState } from "react";
|
||||
|
||||
export const NavbarTitle = (props: Stylable & { onLayout?: ViewProps["onLayout"] }) => {
|
||||
const { t } = useTranslation();
|
||||
@@ -95,11 +85,6 @@ const SearchBar = forwardRef<TextInput, Stylable>(function SearchBar(props, ref)
|
||||
);
|
||||
});
|
||||
|
||||
export const MeQuery: QueryIdentifier<User> = {
|
||||
path: ["auth", "me"],
|
||||
parser: UserP,
|
||||
};
|
||||
|
||||
const getDisplayUrl = (url: string) => {
|
||||
url = url.replace(/\/api$/, "");
|
||||
url = url.replace(/https?:\/\//, "");
|
||||
|
||||
Reference in New Issue
Block a user