diff --git a/src/components/UserProfile/UserProfile.tsx b/src/components/UserProfile/UserProfile.tsx index 807aab5..73cbaae 100644 --- a/src/components/UserProfile/UserProfile.tsx +++ b/src/components/UserProfile/UserProfile.tsx @@ -4,6 +4,8 @@ import { NextRouter, useRouter } from 'next/router'; import React, { FC, useCallback, useEffect, useState } from 'react'; import Skeleton from 'react-loading-skeleton'; +import { isLibraryEnabled } from '@constants/library/common'; + import { logout } from '@api/auth'; import LibraryIcon from '@icons/library/svg/library.svg'; @@ -171,7 +173,7 @@ const UserProfile: FC = ({ )} {isDropdownOpen && isAccessTokenExist && (
e.stopPropagation()}> - {username && ( + {isLibraryEnabled() && username && (
= ({ {t.myLibrary}
)} -
- - {t.createLibrary} -
+ onClick={handleCreateLibrary} + aria-disabled={!canCreateLibrary} + > + + {t.createLibrary} +
+ )}