diff --git a/.env.example b/.env.example index 7da56a2e3..12a455ed6 100644 --- a/.env.example +++ b/.env.example @@ -37,6 +37,12 @@ SMTP_MAIL_PASSWORD='' # Sender for signing requests and completion mails. MAIL_FROM='documenso@localhost.com' +# STRIPE +STRIPE_API_KEY= +STRIPE_WEBHOOK_SECRET= +STRIPE_PRICE_ID= + #FEATURE FLAGS # Allow users to register via the /signup page. Otherwise they will be redirect to the home page. ALLOW_SIGNUP=true +ALLOW_SUBSCRIPTIONS=true \ No newline at end of file diff --git a/.vscode/settings.json b/.vscode/settings.json index 17ceca23e..41c0f1a88 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -13,7 +13,7 @@ "editor.codeActionsOnSave": { "source.removeUnusedImports": false }, - "typescript.tsdk": "node_modules\\typescript\\lib", + "typescript.tsdk": "node_modules/typescript/lib", "spellright.language": ["de"], "spellright.documentTypes": ["markdown", "latex", "plaintext"] } diff --git a/apps/web/components/settings.tsx b/apps/web/components/settings.tsx index 32d868804..5556d3198 100644 --- a/apps/web/components/settings.tsx +++ b/apps/web/components/settings.tsx @@ -5,7 +5,7 @@ import { useRouter } from "next/router"; import { updateUser } from "@documenso/features"; import { getUser } from "@documenso/lib/api"; import { Button } from "@documenso/ui"; -import { KeyIcon, UserCircleIcon } from "@heroicons/react/24/outline"; +import { CreditCardIcon, KeyIcon, UserCircleIcon } from "@heroicons/react/24/outline"; import { useSession } from "next-auth/react"; const subNavigation = [ @@ -21,6 +21,12 @@ const subNavigation = [ icon: KeyIcon, current: false, }, + { + name: "Billing", + href: "/settings/billing", + icon: CreditCardIcon, + current: false, + }, ]; function classNames(...classes: any) { @@ -33,7 +39,6 @@ export default function Setttings() { email: "", name: "", }); - useEffect(() => { getUser().then((res: any) => { res.json().then((j: any) => { @@ -158,6 +163,7 @@ export default function Setttings() { + + + +