moved apps to separate shared package

This commit is contained in:
Abhinav 2023-11-02 09:15:48 +05:30
parent 92e493c411
commit 60f2729d0f
4 changed files with 16 additions and 8 deletions

View file

@ -2,7 +2,7 @@ import LoginPage from '@ente/accounts/pages/login';
import { useRouter } from 'next/router';
import { AppContext } from 'pages/_app';
import { useContext } from 'react';
import { APPS } from '@ente/shared/constants/apps';
import { APPS } from '@ente/shared/apps/constants';
export default function Login() {
const appContext = useContext(AppContext);

View file

@ -5,17 +5,17 @@ import { VerticallyCentered } from '@ente/shared/components/Container';
import { getData, LS_KEYS } from '@ente/shared/storage/localStorage';
import { PAGES } from '../constants/pages';
import FormPaper from '@ente/shared/components/Form/FormPaper';
import { NextRouter } from 'next/router';
import { PageProps } from '@ente/shared/apps/types';
interface HomeProps {
appContext: {
showNavBar: (show: boolean) => void;
};
router: NextRouter;
interface LoginPageProps extends PageProps {
appName: string;
}
export default function Home({ appContext, router, appName }: HomeProps) {
export default function LoginPage({
appContext,
router,
appName,
}: LoginPageProps) {
const [loading, setLoading] = useState(true);
useEffect(() => {

View file

@ -0,0 +1,8 @@
import { NextRouter } from 'next/router';
export interface PageProps {
appContext: {
showNavBar: (show: boolean) => void;
};
router: NextRouter;
}