1
0
Fork 0
mirror of https://github.com/muerwre/vault-frontend.git synced 2025-04-25 12:56:41 +07:00

added superpowers toggle to sidebar

This commit is contained in:
Fedor Katurov 2022-08-05 21:23:18 +07:00
parent 32aaa1e8db
commit d652a76640
25 changed files with 400 additions and 283 deletions

View file

@ -1,15 +1,17 @@
import React, { FC } from 'react';
import React, { FC } from "react";
import { useAuth } from '~/hooks/auth/useAuth';
import { observer } from "mobx-react-lite";
import { useAuth } from "~/hooks/auth/useAuth";
interface IProps {}
const Superpower: FC<IProps> = ({ children }) => {
const Superpower: FC<IProps> = observer(({ children }) => {
const { isTester } = useAuth();
if (!isTester) return null;
return <>{children}</>;
};
});
export { Superpower };