Skip to content

Commit

Permalink
Merge pull request #20 from gary-Shen/fix/gist
Browse files Browse the repository at this point in the history
update: hide gist list when accessToken is none
  • Loading branch information
gary-Shen authored Jun 26, 2023
2 parents f8c0997 + a7eb70a commit 5557e14
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/partials/Setting/OAuth/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,10 @@ function GistList({ onSave }: GistListProps) {
return !oneGist.data || oneGist.isLoading || !(selectedFile in oneGist.data.files!);
}, [selectedFile, oneGist.data, oneGist.isLoading]);

if (gistOptions.length === 0 && !accessToken) {
return null;
}

return (
<div className="max-h-[60vh] mx-[-0.8rem] px-[0.8rem] my-[-3px] py-[3px]">
<div
Expand Down

1 comment on commit 5557e14

@vercel
Copy link

@vercel vercel bot commented on 5557e14 Jun 26, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

candi-tab – ./

candi-tab-git-master-gary-shen.vercel.app
candi-tab-gary-shen.vercel.app
candi-tab.vercel.app

Please sign in to comment.