From c03741c3962da228b25c1292f1b0da6005678874 Mon Sep 17 00:00:00 2001
From: liuweiqing <liuweiqing147@gmail.com>
Date: Wed, 14 Feb 2024 21:37:52 +0800
Subject: [PATCH] chore: email template

---
 components/Settings.tsx         |  1 +
 supabase/email template.html    | 56 +++++++++++++++++++++++++++++++++
 utils/supabase/serversignout.ts | 10 ------
 3 files changed, 57 insertions(+), 10 deletions(-)
 create mode 100644 supabase/email template.html
 delete mode 100644 utils/supabase/serversignout.ts

diff --git a/components/Settings.tsx b/components/Settings.tsx
index 99c298a8..53c048d1 100644
--- a/components/Settings.tsx
+++ b/components/Settings.tsx
@@ -39,6 +39,7 @@ const Settings = ({ lng }: { lng: string }) => {
       upstreamUrl: "",
     },
   ];
+  //https://freeapi.iil.im  sk-GdUOBeCCCpeB16G877C8C62b849c4653A561550bEb79Fe7e
   //redux
   const dispatch = useAppDispatch();
   const apiKey = useAppSelector((state) => state.auth.apiKey);
diff --git a/supabase/email template.html b/supabase/email template.html
new file mode 100644
index 00000000..deba0a50
--- /dev/null
+++ b/supabase/email template.html	
@@ -0,0 +1,56 @@
+<!DOCTYPE html>
+<html lang="en">
+  <head>
+    <meta charset="UTF-8" />
+    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
+    <title>Confirm Your Signup</title>
+    <style>
+      body {
+        font-family: Arial, sans-serif;
+        margin: 0;
+        padding: 20px;
+        background-color: #f4f4f4;
+      }
+      .container {
+        background-color: #fff;
+        max-width: 600px;
+        margin: 0 auto;
+        padding: 20px;
+        text-align: center;
+        box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
+      }
+      h1 {
+        color: #333;
+      }
+      p {
+        color: #666;
+      }
+      .button {
+        display: inline-block;
+        margin-top: 20px;
+        padding: 10px 20px;
+        background-color: #28a745;
+        color: #ffffff;
+        text-decoration: none;
+        border-radius: 5px;
+      }
+    </style>
+  </head>
+  <body>
+    <div class="container">
+      <h1>Welcome to PaperAI!</h1>
+      <p>
+        You're almost ready to start exploring all the powerful features of
+        PaperAI, including AI writing, literature search, and more.
+      </p>
+      <p>
+        Please click the button below to confirm your signup and activate your
+        account:
+      </p>
+      <a href="{{ .ConfirmationURL }}" class="button">Confirm Signup</a>
+      <p>
+        If you didn't sign up for a PaperAI account, please ignore this email.
+      </p>
+    </div>
+  </body>
+</html>
diff --git a/utils/supabase/serversignout.ts b/utils/supabase/serversignout.ts
deleted file mode 100644
index 6a6245f7..00000000
--- a/utils/supabase/serversignout.ts
+++ /dev/null
@@ -1,10 +0,0 @@
-"use server";
-
-import { cookies } from "next/headers";
-import { createClient } from "@/utils/supabase/server";
-
-export const signOut = async () => {
-  const cookieStore = cookies();
-  const supabase = createClient(cookieStore);
-  await supabase.auth.signOut();
-};