mirror of
https://github.com/OpenSignLabs/OpenSign.git
synced 2026-09-07 18:27:41 +02:00
feat: add pro logo in header for paid user
This commit is contained in:
@@ -13,9 +13,9 @@ const Header = ({ showSidebar }) => {
|
||||
let applogo = localStorage.getItem("appLogo") || "";
|
||||
let username = localStorage.getItem("username");
|
||||
const image = localStorage.getItem("profileImg") || dp;
|
||||
|
||||
const [isOpen, setIsOpen] = useState(false);
|
||||
const [isSubscribe, setIsSubscribe] = useState(true);
|
||||
const [isPro, setIsPro]= useState(false)
|
||||
|
||||
const toggleDropdown = () => {
|
||||
setIsOpen(!isOpen);
|
||||
@@ -27,6 +27,7 @@ const Header = ({ showSidebar }) => {
|
||||
async function checkSubscription() {
|
||||
if (isEnableSubscription) {
|
||||
const getIsSubscribe = await checkIsSubscribed();
|
||||
setIsPro(getIsSubscribe)
|
||||
setIsSubscribe(getIsSubscribe);
|
||||
}
|
||||
}
|
||||
@@ -105,6 +106,11 @@ const Header = ({ showSidebar }) => {
|
||||
</button>
|
||||
</div>
|
||||
)}
|
||||
{isPro && (
|
||||
<div className="w-[35px] h-[35px] rounded-full ring-[1px] ring-offset-2 ring-[#002862] text-[#002862] overflow-hidden font-semibold flex items-center justify-center">
|
||||
PRO
|
||||
</div>
|
||||
)}
|
||||
<div>
|
||||
<FullScreenButton />
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user