generated from pinecone-io/pinecone-vercel-starter
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
finish the logic for free users. Need to add the logic for pro users.
- Loading branch information
Showing
15 changed files
with
346 additions
and
44 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,15 @@ | ||
import React from "react"; | ||
import SubscriptionButton from "@/components/subcription-button"; | ||
import { checkSubscription } from "@/lib/subscriptions"; | ||
|
||
const settingsPage = () => { | ||
return <div>settingsPage</div>; | ||
const settingsPage = async () => { | ||
const hasSubscription = await checkSubscription(); | ||
|
||
return ( | ||
<div className="items-center"> | ||
<SubscriptionButton hasSubscription={hasSubscription} /> | ||
</div> | ||
); | ||
}; | ||
|
||
export default settingsPage; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import React from "react"; | ||
import { Button } from "./ui/button"; | ||
import Link from "next/link"; | ||
|
||
interface SubscriptionProps { | ||
hasSubscription: boolean; | ||
} | ||
|
||
const SubscriptionButton: React.FC<SubscriptionProps> = ({ | ||
hasSubscription, | ||
}) => { | ||
if (hasSubscription) { | ||
return ( | ||
<Link href="/"> | ||
<Button>Manage Subscription</Button> | ||
</Link> | ||
); | ||
} | ||
return ( | ||
<Link href="/"> | ||
<Button>Upgrade</Button> | ||
</Link> | ||
); | ||
}; | ||
|
||
export default SubscriptionButton; |
Oops, something went wrong.