Can be used to create strongly typed Svelte components.
Example:
You have component library on npm called component-library, from which
you export a component called MyComponent. For Svelte+TypeScript users,
you want to provide typings. Therefore you create a index.d.ts:
📦 Easy to switch in alternatives: Such as running on AWS, GCE, Azure instead of Cloudflare.
+Change Drizzle setup to connect to any db like Supabase, and add popular platform APIs with Lucia.
+
🖼️ Screenshots
+
+
⬇️ Installation
Install prerequisites Node.js or Bun curl -fsSL https://bun.sh/install | bash. Optional: Setup shell with dev tools like nvim, fish, system info with Server-Shell-Setup
Clone to localhost or server git clone https://github.com/vtempest/svelte-docs-starter.
@@ -55,4 +59,4 @@
Defines the common shape of expected and unexpected errors. Expected errors are thrown using the error function. Unexpected errors are handled by the handleError hooks which should return this shape.
Defines the common shape of the $page.data store - that is, the data that is shared between all pages.
-The Load and ServerLoad functions in ./$types will be narrowed accordingly.
-Use optional properties for data that is only present on specific pages. Do not add an index signature ([key: string]: any).
diff --git a/src/routes/(app)/app/settings/+page.server.ts b/src/routes/(app)/app/settings/+page.server.ts
index 842c043..dbcf5aa 100644
--- a/src/routes/(app)/app/settings/+page.server.ts
+++ b/src/routes/(app)/app/settings/+page.server.ts
@@ -1,7 +1,6 @@
import { redirect } from "sveltekit-flash-message/server";
import type { PageServerLoad } from "./$types";
-import { route } from "$lib/ROUTES";
export const load = (async () => {
- redirect(303, route("/app/settings/profile"));
+ redirect(303, ("/app/settings/profile"));
}) satisfies PageServerLoad;
diff --git a/src/routes/(app)/app/settings/account/+page.server.ts b/src/routes/(app)/app/settings/account/+page.server.ts
index 112da14..2100a96 100644
--- a/src/routes/(app)/app/settings/account/+page.server.ts
+++ b/src/routes/(app)/app/settings/account/+page.server.ts
@@ -1,15 +1,14 @@
import { message, superValidate } from "sveltekit-superforms";
import type { PageServerLoad } from "./$types";
import { zod } from "sveltekit-superforms/adapters";
-import { settingsAccountFormSchema, type SettingsAccountFormSchema } from "$validations/app/settings";
+import { settingsAccountFormSchema, type SettingsAccountFormSchema } from "$lib/middleware/validations";
import { fail, type Actions } from "@sveltejs/kit";
-import { FLASH_MESSAGE_STATUS } from "$configs/general";
-import { verifyRateLimiter } from "$lib/server/security";
-import { accountSettingsLimiter } from "$configs/rate-limiters/app";
-import { logger } from "$lib/logger";
+
+
+import { verifyRateLimiter, accountSettingsLimiter } from "$lib/middleware/ratelimits";
+import { logger } from "$lib/middleware/logger";
import { redirect, setFlash } from "sveltekit-flash-message/server";
-import { updateUserById } from "$lib/server/db/users";
-import { route } from "$lib/ROUTES";
+import { updateUserById } from "$lib/db/users";
export const load: PageServerLoad = async ({ locals: { user } }) => {
@@ -23,7 +22,7 @@ export const load: PageServerLoad = async ({ locals: { user } }) => {
export const actions: Actions = {
default: async (event) => {
const { request, locals, cookies } = event;
- const flashMessage = { status: FLASH_MESSAGE_STATUS.ERROR, text: "" };
+ const flashMessage = { status: "error", text: "" };
const minutes = await verifyRateLimiter(event, accountSettingsLimiter);
if (minutes) {
@@ -54,9 +53,9 @@ export const actions: Actions = {
return message(form, flashMessage, { status: 400 });
}
- flashMessage.status = FLASH_MESSAGE_STATUS.SUCCESS;
+ flashMessage.status = "success";
flashMessage.text = "Account updated successfully";
- redirect(route("/app/settings/account"), flashMessage, cookies);
+ redirect(("/app/settings/account"), flashMessage, cookies);
}
};
diff --git a/src/routes/(app)/app/settings/account/+page.svelte b/src/routes/(app)/app/settings/account/+page.svelte
index a11146f..8c69591 100644
--- a/src/routes/(app)/app/settings/account/+page.svelte
+++ b/src/routes/(app)/app/settings/account/+page.svelte
@@ -6,9 +6,9 @@
import { zodClient } from "sveltekit-superforms/adapters";
import * as flashModule from "sveltekit-flash-message/client";
import LoaderCircle from "lucide-svelte/icons/loader-circle";
- import { settingsAccountFormSchema } from "$validations/app/settings";
+ import { settingsAccountFormSchema } from "$lib/middleware/validations";
+ export let data = null;
- let { data } = $props();
const form = superForm(data.form, {
validators: zodClient(settingsAccountFormSchema),
diff --git a/src/routes/(app)/app/settings/notifications/+page.server.ts b/src/routes/(app)/app/settings/notifications/+page.server.ts
index 66678ad..d813caa 100644
--- a/src/routes/(app)/app/settings/notifications/+page.server.ts
+++ b/src/routes/(app)/app/settings/notifications/+page.server.ts
@@ -2,14 +2,19 @@ import { message, superValidate } from "sveltekit-superforms";
import type { PageServerLoad } from "./$types";
import { zod } from "sveltekit-superforms/adapters";
import { fail, type Actions } from "@sveltejs/kit";
-import { FLASH_MESSAGE_STATUS } from "$configs/general";
-import { verifyRateLimiter } from "$lib/server/security";
-import { logger } from "$lib/logger";
+
+
+
+
+import { verifyRateLimiter } from "$lib/middleware/ratelimits";
+
+
+
+import { logger } from "$lib/middleware/logger";
import { redirect, setFlash } from "sveltekit-flash-message/server";
-import { route } from "$lib/ROUTES";
-import { updateUserById } from "$lib/server/db/users";
-import { settingsNotificationsFormSchema, type SettingsNotificationsFormSchema } from "$validations/app/settings";
-import { notificationsSettingsLimiter } from "$configs/rate-limiters/app";
+import { updateUserById } from "$lib/db/users";
+import { settingsNotificationsFormSchema, type SettingsNotificationsFormSchema } from "$lib/middleware/validations";
+import { notificationsSettingsLimiter } from "$lib/middleware/ratelimits";
export const load: PageServerLoad = async ({ locals: { user } }) => {
@@ -23,7 +28,7 @@ export const load: PageServerLoad = async ({ locals: { user } }) => {
export const actions: Actions = {
default: async (event) => {
const { request, locals, cookies } = event;
- const flashMessage = { status: FLASH_MESSAGE_STATUS.ERROR, text: "" };
+ const flashMessage = { status: "error", text: "" };
const minutes = await verifyRateLimiter(event, notificationsSettingsLimiter);
if (minutes) {
@@ -54,9 +59,9 @@ export const actions: Actions = {
return message(form, flashMessage, { status: 400 });
}
- flashMessage.status = FLASH_MESSAGE_STATUS.SUCCESS;
+ flashMessage.status = "success";
flashMessage.text = "Profile updated successfully";
- redirect(route("/app/settings/notifications"), flashMessage, cookies);
+ redirect(("/app/settings/notifications"), flashMessage, cookies);
}
};
diff --git a/src/routes/(app)/app/settings/notifications/+page.svelte b/src/routes/(app)/app/settings/notifications/+page.svelte
index 9a9ea81..a5683af 100644
--- a/src/routes/(app)/app/settings/notifications/+page.svelte
+++ b/src/routes/(app)/app/settings/notifications/+page.svelte
@@ -5,10 +5,9 @@
import { zodClient } from "sveltekit-superforms/adapters";
import * as flashModule from "sveltekit-flash-message/client";
import LoaderCircle from "lucide-svelte/icons/loader-circle";
- import { settingsNotificationsFormSchema } from "$validations/app/settings";
+ import { settingsNotificationsFormSchema } from "$lib/middleware/validations";
import { Separator } from "$components/ui/separator";
-
- let { data } = $props();
+export let data = null;
const form = superForm(data.form, {
validators: zodClient(settingsNotificationsFormSchema),
diff --git a/src/routes/(app)/app/settings/profile/+page.server.ts b/src/routes/(app)/app/settings/profile/+page.server.ts
index 3556521..ee4150d 100644
--- a/src/routes/(app)/app/settings/profile/+page.server.ts
+++ b/src/routes/(app)/app/settings/profile/+page.server.ts
@@ -1,15 +1,15 @@
import { message, superValidate } from "sveltekit-superforms";
import type { PageServerLoad } from "./$types";
import { zod } from "sveltekit-superforms/adapters";
-import { settingsProfileFormSchema, type SettingsProfileFormSchema } from "$validations/app/settings";
+import { settingsProfileFormSchema, type SettingsProfileFormSchema } from "$lib/middleware/validations";
import { fail, type Actions } from "@sveltejs/kit";
-import { FLASH_MESSAGE_STATUS } from "$configs/general";
-import { verifyRateLimiter } from "$lib/server/security";
-import { profileSettingsLimiter } from "$configs/rate-limiters/app";
-import { logger } from "$lib/logger";
+
+
+import { verifyRateLimiter } from "$lib/middleware/ratelimits";
+import { profileSettingsLimiter } from "$lib/middleware/ratelimits";
+import { logger } from "$lib/middleware/logger";
import { redirect, setFlash } from "sveltekit-flash-message/server";
-import { route } from "$lib/ROUTES";
-import { getUserByUsername, updateUserById } from "$lib/server/db/users";
+import { getUserByUsername, updateUserById } from "$lib/db/users";
export const load: PageServerLoad = async ({ locals: { user } }) => {
@@ -23,7 +23,7 @@ export const load: PageServerLoad = async ({ locals: { user } }) => {
export const actions: Actions = {
default: async (event) => {
const { request, locals, cookies } = event;
- const flashMessage = { status: FLASH_MESSAGE_STATUS.ERROR, text: "" };
+ const flashMessage = { status: "error", text: "" };
const minutes = await verifyRateLimiter(event, profileSettingsLimiter);
if (minutes) {
@@ -61,9 +61,9 @@ export const actions: Actions = {
return message(form, flashMessage, { status: 400 });
}
- flashMessage.status = FLASH_MESSAGE_STATUS.SUCCESS;
+ flashMessage.status = "success";
flashMessage.text = "Profile updated successfully";
- redirect(route("/app/settings/profile"), flashMessage, cookies);
+ redirect(("/app/settings/profile"), flashMessage, cookies);
}
};
diff --git a/src/routes/(app)/app/settings/profile/+page.svelte b/src/routes/(app)/app/settings/profile/+page.svelte
index 4dfe440..f46ed47 100644
--- a/src/routes/(app)/app/settings/profile/+page.svelte
+++ b/src/routes/(app)/app/settings/profile/+page.svelte
@@ -5,10 +5,9 @@
import { zodClient } from "sveltekit-superforms/adapters";
import * as flashModule from "sveltekit-flash-message/client";
import LoaderCircle from "lucide-svelte/icons/loader-circle";
- import { settingsProfileFormSchema } from "$validations/app/settings";
+ import { settingsProfileFormSchema } from "$lib/middleware/validations";
import { Separator } from "$components/ui/separator";
-
- let { data } = $props();
+export let data = null;
const form = superForm(data.form, {
validators: zodClient(settingsProfileFormSchema),
diff --git a/src/routes/(auth)/auth/logout/+page.server.ts b/src/routes/(auth)/auth/logout/+page.server.ts
deleted file mode 100644
index edb30c7..0000000
--- a/src/routes/(auth)/auth/logout/+page.server.ts
+++ /dev/null
@@ -1,16 +0,0 @@
-import { route } from "$lib/ROUTES";
-import { destroySession } from "$lib/server/auth/auth-utils";
-import { isUserAuthenticated } from "$lib/server/security";
-import type { Actions } from "./$types";
-import { redirect } from "@sveltejs/kit";
-
-export const actions: Actions = {
- default: async ({ locals, url, cookies }) => {
- isUserAuthenticated(locals, cookies, url);
-
- await locals.lucia.invalidateSession(locals.session.id);
- destroySession(locals.lucia, cookies);
-
- redirect(302, route("/"));
- }
-} satisfies Actions;
diff --git a/src/routes/(auth)/auth/oauth/github/+server.ts b/src/routes/(auth)/auth/oauth/github/+server.ts
deleted file mode 100644
index 3339f07..0000000
--- a/src/routes/(auth)/auth/oauth/github/+server.ts
+++ /dev/null
@@ -1,23 +0,0 @@
-import { redirect } from "@sveltejs/kit";
-import { generateState } from "arctic";
-
-import { GITHUB_OAUTH_STATE_COOKIE_NAME } from "$configs/cookies-names";
-import { githubOauth } from "$lib/server/auth";
-import type { RequestHandler } from "./$types";
-import { dev } from "$app/environment";
-
-export const GET: RequestHandler = async ({ cookies }) => {
- const state = generateState();
-
- const url = await githubOauth.createAuthorizationURL(state, { scopes: ["user:email"] });
-
- cookies.set(GITHUB_OAUTH_STATE_COOKIE_NAME, state, {
- path: "/",
- secure: !dev,
- httpOnly: true,
- maxAge: 60 * 10, // TODO should we export into a constant?
- sameSite: "lax"
- });
-
- redirect(302, url);
-};
diff --git a/src/routes/(auth)/auth/oauth/github/callback/+server.ts b/src/routes/(auth)/auth/oauth/github/callback/+server.ts
deleted file mode 100644
index 3ae9756..0000000
--- a/src/routes/(auth)/auth/oauth/github/callback/+server.ts
+++ /dev/null
@@ -1,155 +0,0 @@
-import type { RequestHandler } from "./$types";
-import { OAuth2RequestError } from "arctic";
-import { generateId } from "lucia";
-import { route } from "$lib/ROUTES";
-import { GITHUB_OAUTH_STATE_COOKIE_NAME } from "$configs/cookies-names";
-import { error } from "@sveltejs/kit";
-import { githubOauth } from "$lib/server/auth";
-import { getUserByEmail, users } from "$lib/server/db/users";
-import { getOAuthAccountByProviderUserId, oauthAccounts } from "$lib/server/db/oauth-accounts";
-import { createAndSetSession } from "$lib/server/auth/auth-utils";
-import { logger } from "$lib/logger";
-import { redirect } from "sveltekit-flash-message/server";
-import { AUTH_METHODS } from "$configs/auth-methods";
-import { eq } from "drizzle-orm";
-
-
-type GitHubUser = {
- id: number;
- login: string;
- avatar_url: string;
- name: string;
-};
-
-type GitHubEmail = {
- email: string;
- primary: boolean;
- verified: boolean;
- visibility: string | null;
-};
-
-export const GET: RequestHandler = async ({ url, cookies, locals: { db, lucia } }) => {
- const code = url.searchParams.get("code");
- const state = url.searchParams.get("state");
- const storedState = cookies.get(GITHUB_OAUTH_STATE_COOKIE_NAME);
-
- if (!code || !state || !storedState || state !== storedState) {
- error(400, "Invalid OAuth state or code verifier");
- }
-
- try {
- // validate the authorization code and retrieve the tokens
- const tokens = await githubOauth.validateAuthorizationCode(code);
- console.log((tokens));
-
- // fetch the GitHub user associated with the access token
- const githubUserResponse = await fetch("https://api.github.com/user", {
- headers: {
- Authorization: `Bearer ${tokens.accessToken}`
- }
- });
-
- // fetch the primary email address of the GitHub user
- const githubEmailResponse = await fetch("https://api.github.com/user/emails", {
- headers: {
- Authorization: `Bearer ${tokens.accessToken}`
- }
- });
- console.log(JSON.stringify(githubUserResponse));
- const githubUser = (await githubUserResponse.json()) as GitHubUser;
- const githubEmail = (await githubEmailResponse.json()) as GitHubEmail[];
-
- const primaryEmail = githubEmail.find((email) => email.primary) ?? null;
-
- if (!primaryEmail) {
- error(400, "No primary email address");
- }
-
- if (!primaryEmail.verified) {
- error(400, "Unverified email");
- }
-
- // check if the user already exists
- const existingUser = await getUserByEmail(db, primaryEmail.email);
-
- if (existingUser) {
- // check if the user already has a GitHub OAuth account linked
- const existingOauthAccount = await getOAuthAccountByProviderUserId(db, AUTH_METHODS.GITHUB, githubUser.id.toString());
-
- if (!existingOauthAccount) {
- // add the 'github' auth provider to the user's authMethods list
- const authMethods = existingUser.authMethods || [];
- authMethods.push(AUTH_METHODS.GITHUB);
-
- await db.batch([
- // link the GitHub OAuth account to the existing user
- db
- .insert(oauthAccounts)
- .values({
- userId: existingUser.id,
- providerId: AUTH_METHODS.GITHUB,
- providerUserId: githubUser.id.toString()
- })
- .onConflictDoNothing()
- .returning(),
-
- // update the user's authMethods list
- db
- .update(users)
- .set({
- name: githubUser.name,
- avatarUrl: githubUser.avatar_url,
- authMethods
- })
- .where(eq(users.id, existingUser.id))
- .returning()
- ]);
- }
-
- await createAndSetSession(lucia, existingUser.id, cookies);
- } else {
- const userId = generateId(15);
-
- // if user doesn't exist in db
- await db.batch([
- // create a new user
- db
- .insert(users)
- .values({
- id: userId,
- name: githubUser.name,
- username: githubUser.login,
- avatarUrl: githubUser.avatar_url,
- email: primaryEmail.email,
- isVerified: true,
- authMethods: [AUTH_METHODS.GITHUB]
- })
- .onConflictDoNothing()
- .returning(),
-
- // create a new GitHub OAuth account
- db
- .insert(oauthAccounts)
- .values({
- userId,
- providerId: AUTH_METHODS.GITHUB,
- providerUserId: githubUser.id.toString()
- })
- .onConflictDoNothing()
- .returning()
- ]);
-
- await createAndSetSession(lucia, userId, cookies);
- }
- } catch (e) {
- logger.error(e);
-
- if (e instanceof OAuth2RequestError) {
- error(400);
- }
-
- error(500);
- }
-
- redirect(303, route("/app/dashboard"));
-};
diff --git a/src/routes/(auth)/auth/oauth/google/+server.ts b/src/routes/(auth)/auth/oauth/google/+server.ts
deleted file mode 100644
index 013b30b..0000000
--- a/src/routes/(auth)/auth/oauth/google/+server.ts
+++ /dev/null
@@ -1,34 +0,0 @@
-import { redirect } from "@sveltejs/kit";
-import { generateCodeVerifier, generateState } from "arctic";
-
-import { GOOGLE_OAUTH_CODE_VERIFIER_COOKIE_NAME, GOOGLE_OAUTH_STATE_COOKIE_NAME } from "$configs/cookies-names";
-import { googleOauth } from "$lib/server/auth";
-import type { RequestHandler } from "./$types";
-import { dev } from "$app/environment";
-
-export const GET: RequestHandler = async ({ cookies }) => {
- const state = generateState();
- const codeVerifier = generateCodeVerifier();
-
- const url = await googleOauth.createAuthorizationURL(state, codeVerifier, {
- scopes: ["profile", "email"]
- });
-
- cookies.set(GOOGLE_OAUTH_STATE_COOKIE_NAME, state, {
- path: "/",
- secure: !dev,
- httpOnly: true,
- maxAge: 60 * 10,
- sameSite: "lax"
- });
-
- cookies.set(GOOGLE_OAUTH_CODE_VERIFIER_COOKIE_NAME, codeVerifier, {
- path: "/",
- secure: !dev,
- httpOnly: true,
- maxAge: 60 * 10,
- sameSite: "lax"
- });
-
- redirect(302, url);
-};
diff --git a/src/routes/(landing)/+page.server.ts b/src/routes/(landing)/+page.server.ts
index ddc344d..aab9370 100644
--- a/src/routes/(landing)/+page.server.ts
+++ b/src/routes/(landing)/+page.server.ts
@@ -1,5 +1,4 @@
-import type { PageServerLoad } from "./$types";
-export const load: PageServerLoad = async ({ locals }) => {
+export const load = async ({ locals }) => {
return { user: locals.user };
};
diff --git a/src/routes/(landing)/+page.svelte b/src/routes/(landing)/+page.svelte
index 60e4af3..245892a 100644
--- a/src/routes/(landing)/+page.svelte
+++ b/src/routes/(landing)/+page.svelte
@@ -1,5 +1,5 @@
diff --git a/src/routes/(landing)/legal/privacy-policy/+page.svelte b/src/routes/(landing)/legal/privacy-policy/+page.svelte
deleted file mode 100644
index 4e28938..0000000
--- a/src/routes/(landing)/legal/privacy-policy/+page.svelte
+++ /dev/null
@@ -1,91 +0,0 @@
-
-
-
-
Privacy Policy
-
- {APP_NAME} ("we", "us", or "our") ("we", "us", or "our") is committed to protecting the privacy and security of your personal information.
-
-
This Privacy Policy explains how we collect, use, disclose, and protect your personal data when you use our website and platform.
-
-
Information We Collect
-
- We may collect the following types of personal information when you use our website and platform:
-
-
-
Account Information
-
When you sign up for an account, we may collect your name, email address, and other contact details.
-
-
-
Usage Data
-
- We may collect information about your interactions with our website and platform, including your IP address, browser type, operating system,
- and referring URLs.
-
-
-
-
Payment Information
-
- If you make a purchase or subscribe to our services, we may collect payment information such as credit card details or other billing
- information.
-
-
-
-
Communications
-
- When you contact us or participate in surveys or promotions, we may collect your communication preferences and any other information you
- provide.
-
-
-
-
-
-
How We Use Your Information
-
- We may use your personal information for the following purposes:
-
-
To provide and maintain our services, including processing transactions and delivering customer support.
-
To personalize your experience and tailor content and advertisements to your interests.
-
To communicate with you about updates, offers, and promotional materials related to our services.
-
To analyze website traffic and usage trends, and to improve the performance and design of our website and platform.
-
To comply with legal and regulatory requirements, and to protect the rights and safety of our users and others.
-
-
-
-
Information Sharing and Disclosure
-
- We may share your personal information with third parties for the following purposes:
-
-
With service providers and business partners who assist us in providing our services and conducting our business operations.
-
With your consent or at your direction, including when you choose to share information through our platform.
-
In response to a legal request or as required by law, such as to comply with a subpoena or other legal process.
-
- In connection with a merger, acquisition, or sale of assets, in which case your personal information may be transferred to the acquiring
- entity.
-
-
-
-
-
Data Security
-
We take reasonable measures to protect your personal information from unauthorized access, use, or disclosure.
-
- However, no method of transmission over the internet or electronic storage is 100% secure, and we cannot guarantee the absolute security of your
- data.
-
-
-
Your Rights and Choices
-
- You have the right to access, update, or delete your personal information and you may also have the right to object to or restrict certain
- processing of your data.
-
-
To exercise these rights, please contact us using the information provided below.
-
-
Changes to this Privacy Policy
-
We may update this Privacy Policy from time to time to reflect changes in our practices or legal requirements.
-
We will notify you of any material changes by posting the updated Privacy Policy on our website.
-
Your continued use of our services after the effective date of the revised Privacy Policy constitutes your acceptance of the changes.
-
-
Contact Us
-
If you have any questions or concerns about this Privacy Policy or our data practices, please contact us.
This Privacy Notice describes how {APP_NAME} ("we", "us," "our") collects, uses and discloses information about individuals who use our websites, applications, services, tools and features, purchase our products or otherwise interact with us (collectively, the "Services"). For the purposes of this Privacy Notice, "you" and "your" means you as the user of the Services, whether you are a customer, website visitor, job applicant, representative of a company with whom we do business, or another individual whose information we have collected pursuant to this Privacy Notice. Please note that the Services are designed for users in the United States only and are not intended for users located outside the United States.
+
+
Please read this Privacy Notice carefully. By using any of the Services, you agree to the collection, use, and disclosure of your information as described in this Privacy Notice. If you do not agree to this Privacy Notice, please do not use or access the Services.
+
+
CHANGES TO THIS PRIVACY NOTICE
+
We may modify this Privacy Notice from time to time, in which case we will update the "Last Updated" date at the top of this Privacy Notice. If we make material changes to the way in which we use or disclose information we collect, we will use reasonable efforts to notify you (such as by emailing you at the last email address you provided us, by posting notice of such changes on the Services, or by other means consistent with applicable law) and will take additional steps as required by applicable law. If you do not agree to any updates to this Privacy Notice, please do not continue using or accessing the Services.
+
+
COLLECTION AND USE OF YOUR INFORMATION
+
When you use or access the Services, we collect certain categories of information about you from a variety of sources.
+
+
Information You Provide to Us
+
Some features of the Services may require you to directly provide us with certain information about yourself. You may elect not to provide this information, but doing so may prevent you from using or accessing these features. Information that you directly submit through our Services includes:
+
+
+
Basic contact details, such as name, address, phone number, and email. We use this information to provide the Services, and to communicate with you (including to tell you about certain promotions or products or services that may be of interest to you).
+
Account information, such as name, username (email) and password. We use this information to provide the Services and to maintain and secure your account with us. If you choose to register an account, you are responsible for keeping your account credentials safe. We recommend you do not share your access details with anyone else. If you believe your account has been compromised, please contact us immediately.
+
Your Input and Output, such as questions, prompts and other content that you input, upload or submit to the Services, and the output that you create. This content may constitute or contain personal information, depending on the substance and how it is associated with your account. We use this information to generate and output new content as part of the Services.
+
Any other information you choose to include in communications with us, for example, when sending a message through the Services or provide your size when purchasing certain products.
+
+
+
Information We Collect Automatically
+
We also automatically collect certain information about your interaction with the Services ("Usage Data"). To do this, we may use cookies and other tracking technologies ("Tracking Technologies"). Usage Data includes:
+
+
+
Device information, such as device type, operating system, unique device identifier, and internet protocol (IP) address.
+
Location information, such as approximate location.
+
Other information regarding your interaction with the Services, such as browser type, log data, date and time stamps, clickstream data, interactions with marketing emails, and ad impressions.
+
+
+
We use Usage Data to tailor features and content to you, run analytics and better understand user interaction with the Services. For more information on how we use Tracking Technologies and your choices, see the section below, Cookies and Other Tracking Technologies.
+
+
Information Collected From Other Sources
+
We may obtain information about you from outside sources, including information that we collect directly from third parties and information from third parties that you choose to share with us. Such information includes:
+
+
+
Analytics data we receive from analytics providers such as Google Analytics.
+
Information we receive from consumer marketing databases or other data enrichment companies, which we use to better customize advertising and marketing to you.
+
+
+
Any information we receive from outside sources will be treated in accordance with this Privacy Notice. We are not responsible for the accuracy of the information provided to us by third parties and are not responsible for any third party's policies or practices. For more information, see the section below, Third Party Websites and Links.
+
+
In addition to the specific uses described above, we may use any of the above information to provide you with and improve the Services and to maintain our business relationship, including by enhancing the safety and security of our Services (e.g., troubleshooting, data analysis, testing, system maintenance, and reporting), providing customer support, sending service and other non-marketing communications, monitoring and analyzing trends, conducting internal research and development, complying with applicable legal obligations, enforcing any applicable terms of service, and protecting the Services, our rights, and the rights of our employees, users or other individuals.
+
+
Finally, we may deidentify or anonymize your information such that it cannot reasonably be used to infer information about you or otherwise be linked to you ("deidentified information") (or we may collect information that has already been deidentified/anonymized), and we may use such deidentified information for any purpose. To the extent we possess or process any deidentified information, we will maintain and use such information in deidentified/anonymized form and not attempt to re-identify the information, except solely for the purpose of determining whether our deidentification/anonymization process satisfies legal requirements.
+
+
COOKIES AND OTHER TRACKING TECHNOLOGIES
+
Most browsers accept cookies automatically, but you may be able to control the way in which your devices permit the use of Tracking Technologies. If you so choose, you may block or delete our cookies from your browser; however, blocking or deleting cookies may cause some of the Services, including certain features and general functionality, to work incorrectly. If you have questions regarding the specific information about you that we process or retain, as well as your choices regarding our collection and use practices, please contact us using the information listed below.
+
+
To opt out of tracking by Google Analytics, click here: https://tools.google.com/dlpage/gaoptout
+
+
Your browser settings may allow you to transmit a "do not track" signal, "opt-out preference" signal, or other mechanism for exercising your choice regarding the collection of your information when you visit various websites. Like many websites, our website is not designed to respond to such signals, and we do not use or disclose your information in any way that would legally require us to recognize opt-out preference signals. To learn more about "do not track" signals, you can visit http://www.allaboutdnt.com/.
+
+
DISCLOSURE OF YOUR INFORMATION
+
We may disclose your information to third parties for legitimate purposes subject to this Privacy Notice, including the following categories of third parties:
+
+
+
Company Group: Our affiliates or others within our corporate group.
+
Service Providers: Vendors or other service providers who help us provide the Services, including for system administration, cloud storage, security, customer relationship management, marketing communications, web analytics, payment networks, and payment processing.
+
Other Third Parties: Third parties to whom you request or direct us to disclose information, such as through your use of social media widgets or login integration.
+
Professional advisors: such as auditors, law firms, or accounting firms.
+
Business Transactions: Third parties in connection with or anticipation of an asset sale, merger, or other business transaction, including in the context of a bankruptcy.
+
+
+
We may also disclose your information as needed to comply with applicable law or any obligations thereunder or to cooperate with law enforcement, judicial orders, and regulatory inquiries, to enforce any applicable terms of service, and to ensure the safety and security of our business, employees, and users.
+
+
SOCIAL FEATURES
+
Certain features of the Services may allow you to initiate interactions between the Services and third-party services or platforms, such as social networks ("Social Features"). Social Features include features that allow you to access our pages on third-party platforms, and from there "like" or "share" our content. Use of Social Features may allow a third party to collect and/or use your information. If you use Social Features, information you post or make accessible may be publicly displayed by the third-party service. Both we and the third party may have access to information about you and your use of both the Services and the third-party service. For more information, see the section below, Third Party Websites and Links.
+
+
THIRD PARTY WEBSITES AND LINKS
+
We may provide links to third-party websites or platforms. If you follow links to sites or platforms that we do not control and are not affiliated with us, you should review the applicable privacy notice, policies and other terms. We are not responsible for the privacy or security of, or information found on, these sites or platforms. Information you provide on public or semi-public venues, such as third-party social networking platforms, may also be viewable by other users of the Services and/or users of those third-party platforms without limitation as to its use. Our inclusion of such links does not, by itself, imply any endorsement of the content on such platforms or of their owners or operators.
+
+
CHILDREN'S PRIVACY
+
Children under the age of 13 are not permitted to use the Services, and we do not seek or knowingly collect any personal information about children under 13 years of age. If we become aware that we have unknowingly collected information about a child under 13 years of age, we will make commercially reasonable efforts to delete such information. If you are the parent or guardian of a child under 13 years of age who has provided us with their personal information, you may contact us using the below information to request that it be deleted.
+
+
DATA SECURITY AND RETENTION
+
Despite our reasonable efforts to protect your information, no security measures are impenetrable, and we cannot guarantee "perfect security." Any information you send to us electronically, while using the Services or otherwise interacting with us, may not be secure while in transit. We recommend that you do not use unsecure channels to send us sensitive or confidential information.
+
+
We retain your information for as long as is reasonably necessary for the purposes specified in this Privacy Notice. When determining the length of time to retain your information, we consider various criteria, including whether we need the information to continue to provide you the Services, resolve a dispute, enforce our contractual agreements, prevent harm, promote safety, security and integrity, or protect ourselves, including our rights, property or products.
+
+
You may opt out of information collection for AI, which would prohibit us from using your search information to improve our AI models in your settings page if you are logged into the Services. If you delete your account, we will delete your personal information from our servers within 30 days. Please contact us at {APP_EMAIL} to request deletion.
+
+
CALIFORNIA RESIDENTS
+
This section applies to you only if you are a California resident ("resident" or "residents"). For purposes of this section, references to "personal information" shall include "sensitive personal information," as these terms are defined under the California Consumer Privacy Act ("CCPA").
+
+
Processing of Personal Information
+
In the preceding 12 months, we collected and disclosed for a business purpose the following categories of personal information and sensitive personal information (denoted by *) about residents:
+
+
+
Identifiers such as name, e-mail address, IP address
+
Personal information categories listed in the California Customer Records statute such as name, address and telephone number
+
Commercial information such as records of products or services purchased
+
Internet or other similar network activity such as information regarding your interaction with the Platform
+
Geolocation data such as IP address
+
Professional or employment-related information such as title of profession, employer, professional background and other information provided by you when you apply for a job with us
+
Non-public education information collected by certain federally funded institutions such as education records
+
Account access credentials* such as account log-in
+
+
+
The specific business or commercial purposes for which we collect your personal information and the categories of sources from which we collect your personal information are described in the section above, Collection and Use Your Information. We only use and disclose sensitive personal information for the purposes specified in the CCPA. The criteria we use to determine how long to retain your personal information is described in the section above, Data Security and Retention.
+
+
We disclosed personal information over the preceding 12 months for the following business or commercial purposes:
+
+
+
to communicate with you, provide you with products and services, to market to you, etc.
+
to maintain and secure your account with us
+
to process your payment, to provide you with products or services you have requested
+
to evaluate your candidacy and process your application for employment.
+
+
+
Selling and/or Sharing of Personal Information
+
We do not "sell" or "share" (as those terms are defined under the CCPA) personal information, nor have we done so in the preceding 12 months. Further, we do not have actual knowledge that we "sell" or "share" personal information of residents under 16 years of age.
+
+
Your California Privacy Rights
+
As a California resident, you may have the rights listed below in relation to personal information that we have collected about you. However, these rights are not absolute, and in certain cases, we may decline your request as permitted by law.
+
+
+
Right to Know. You have a right to request the following information about our collection, use and disclosure of your personal information:
+
+
categories of personal information we have collected, disclosed for a business purpose, ;
+
categories of sources from which we collected personal information;
+
the business or commercial purposes for collecting personal information;
+
categories of third parties to whom the personal information was disclosed for a business purpose; and
+
specific pieces of personal information we have collected.
+
+
+
Right to Delete. You have a right to request that we delete personal information we maintain about you.
+
Right to Correct. You have a right to request that we correct inaccurate personal information we maintain about you.
+
+
You may exercise any of these rights by contacting us using the information provided below. We will not discriminate against you for exercising any of these rights. We may need to collect information from you to verify your identity, such as your email address and government issued ID, before providing a substantive response to the request. You may designate, in writing or through a power of attorney document, an authorized agent to make requests on your behalf to exercise your rights. Before accepting such a request from an agent, we will require that the agent provide proof you have authorized them to act on your behalf, and we may need you to verify your identity directly with us.
+
HOW TO CONTACT US
+
Should you have any questions about our privacy practices or this Privacy Notice, please email us at {APP_EMAIL}
+
+
+
+
\ No newline at end of file
diff --git a/src/routes/(landing)/legal/terms-and-conditions/+page.svelte b/src/routes/(landing)/legal/terms-and-conditions/+page.svelte
deleted file mode 100644
index 3b432ed..0000000
--- a/src/routes/(landing)/legal/terms-and-conditions/+page.svelte
+++ /dev/null
@@ -1,124 +0,0 @@
-
-
-
-
Terms and Conditions
-
-
Welcome to {APP_NAME} ("we", "us", or "our"). These terms and conditions ("Terms") govern your use of our website and platform.
-
By accessing or using our website and platform, you agree to be bound by these Terms.
-
If you do not agree to these Terms, please do not access or use our website and platform.
-
-
-
1. Use of Our Services
-
-
-
License
-
- Subject to these Terms, we grant you a limited, non-exclusive, non-transferable license to access and use our platform for your personal or
- internal business purposes.
-
-
-
-
Account
-
You may be required to create an account to access certain features of our platform.
-
- You are responsible for maintaining the confidentiality of your account credentials and for all activities that occur under your account.
-
-
-
-
Prohibited Activities
-
- You agree not to engage in any prohibited activities, including but not limited to:
-
-
attempting to gain unauthorized access to our platform or systems;
-
interfering with the operation of our platform;
-
using our platform for illegal purposes;
-
infringing the intellectual property rights of others;
-
violating any applicable laws or regulations
-
-
-
-
-
-
2. Intellectual Property
-
-
-
Ownership
-
- All content and materials available on our website and platform, including but not limited to text, graphics, logos, and software, are the
- property of {APP_NAME} or its licensors and are protected by copyright and other intellectual property laws.
-
-
-
-
License Grant
-
You retain ownership of any data or content you submit or upload to our platform.
-
- By submitting or uploading content, you grant us a worldwide, royalty-free, non-exclusive license to use, reproduce, modify, adapt, publish,
- translate, distribute, and display such content for the purpose of providing our services.
-
-
-
-
-
3. Privacy
-
-
-
Privacy Policy
-
- Your use of our website and platform is subject to our Privacy Policy,
- which explains how we collect, use, and disclose your personal information.
-
-
- By using our website and platform, you consent to the collection and use of your personal information as described in our
- Privacy Policy
- .
-
-
-
-
-
4. Disclaimer of Warranties
-
-
-
As Is Basis
-
- Our website and platform are provided on an "as is" and "as available" basis, without any warranties of any kind, either express or implied.
-
-
We do not warrant that our website and platform will be uninterrupted, error-free, or free of viruses or other harmful components.
-
-
-
-
5. Limitation of Liability
-
-
-
Exclusion of Damages
-
- In no event shall {APP_NAME} be liable for any indirect, incidental, special, or consequential damages arising out of or in connection with your
- use of our website and platform, even if we have been advised of the possibility of such damages.
-
-
-
-
-
6. Changes to These Terms
-
-
-
Modification
-
We reserve the right to modify or revise these Terms at any time, in our sole discretion.
-
We will notify you of any material changes to these Terms by posting the updated Terms on our website.
-
- Your continued use of our website and platform after the effective date of the revised Terms constitutes your acceptance of the changes.
-
-
-
-
-
7. Contact Us
-
-
-
Questions
-
If you have any questions or concerns about these Terms, please contact.
-
-
-
diff --git a/src/routes/(landing)/legal/terms/+page.svelte b/src/routes/(landing)/legal/terms/+page.svelte
new file mode 100644
index 0000000..2ec7a5e
--- /dev/null
+++ b/src/routes/(landing)/legal/terms/+page.svelte
@@ -0,0 +1,156 @@
+
+
+
+ {APP_NAME} Terms of Service
+
+
+
+
{APP_NAME} Terms of Service
+
Revised Date: August 10, 2024
+
+
+
1. Introduction
+
These Terms of Service ("Terms") govern your use of {APP_NAME}'s products and services, along with any associated apps, software, and websites (together, our "Services"). These Terms are a contract between you and {APP_NAME}, and they include our Acceptable Use Policy. By accessing our Services, you agree to these Terms.
+
+
+
2. Artificial Intelligence Ethical Use Policy
+
+
+
+
Trust, But Verify Outputs
+
+
Artificial intelligence and large language models (LLMs) are frontier technologies that are still improving in accuracy, reliability and safety. When you use our Services, you acknowledge and agree:
+
+
+ Outputs may not always be accurate and may contain material inaccuracies even if they appear accurate because of their level of detail or specificity.
+
+ You should not rely on any Outputs without independently confirming their accuracy.
+
+ The Services and any Outputs may not reflect correct, current, or complete information.
+
+
+
+
Don't compromise the privacy of others, including:
+
+
Collecting, processing, disclosing, inferring or generating personal data without complying with applicable legal requirements
+
Using biometric systems for identification or assessment, including facial recognition
+
Facilitating spyware, communications surveillance, or unauthorized monitoring of individuals
+
+
+
+
Don't perform or facilitate activities that may significantly impair the safety, wellbeing, or rights of others, including:
+
+
Providing tailored legal, medical/health, or financial advice without review by a qualified professional and disclosure of the use of AI assistance and its potential limitations
+
Making high-stakes automated decisions in domains that affect an individual's safety, rights or well-being
+
Facilitating real money gambling or payday lending
+
Engaging in political campaigning or lobbying, including generating campaign materials personalized to or targeted at specific demographics
+
Deterring people from participation in democratic processes
+
+
+
+
Don't misuse our platform to cause harm by intentionally deceiving or misleading others, including:
+
+
Generating or promoting disinformation, misinformation, or false online engagement
+
Impersonating another individual or organization without consent or legal right
+
Engaging in or promoting academic dishonesty
+
Failing to ensure that automated systems disclose to people that they are interacting with AI, unless it's obvious from the context
+
+
+
+
+
+
3. Account creation and access
+
+
Your {APP_NAME} Account: To access our Services, we may ask you to create an Account. You agree to provide correct, current, and complete Account information. You may not share your Account login information with anyone else. You are responsible for all activity occurring under your Account.
+
+
You may close your Account at any time by contacting us at {APP_EMAIL}.
+
+
4. Use of our Services
+
You may access and use our Services only in compliance with our Terms, our Acceptable Use Policy, and any guidelines or supplemental terms we may post on the Services (the "Permitted Use").
+
+
You may not access or use, or help another person to access or use, our Services in any manner that violates these Terms or applicable laws.
+
+
5. Prompts, Outputs, and Materials
+
You may be allowed to submit text or other materials to our Services for processing (we call these "Prompts"). Our Services may generate responses based on your Prompts (we call these "Outputs"). Prompts and Outputs collectively are "Materials."
+
+
You are responsible for all Prompts you submit to our Services. By submitting Prompts, you represent and warrant that you have all necessary rights and permissions.
+
+
6. Feedback
+
If you provide Feedback to us, you agree that we may use the Feedback however we choose without any obligation or payment to you.
+
+
7. Disclaimer of warranties and limitations of liability
+
+
The services are provided "as is" and "as available" without warranties of any kind. {APP_NAME} disclaims all warranties, express or implied.
+
+
+
To the fullest extent permissible under applicable law, {APP_NAME} shall not be liable for any indirect, incidental, special, consequential, or punitive damages, or any loss of profits or revenues.
+
+
8. Changes to these terms
+
We may revise and update these Terms at our discretion. If you continue to access the Services after we post the updated Terms, you agree to the updated Terms.
+
+
9. Termination
+
We may suspend or terminate your access to the Services at any time if we believe that you have breached these Terms, or if we must do so to comply with law.
+
+
10. Contact Us
+
If you have any questions about these Terms of Service, please contact us at: {APP_EMAIL}
+
+
+
+
\ No newline at end of file
diff --git a/src/routes/+error.svelte b/src/routes/+error.svelte
deleted file mode 100644
index eae6007..0000000
--- a/src/routes/+error.svelte
+++ /dev/null
@@ -1,18 +0,0 @@
-
-
-
- {#if $page.status === 404}
-
404 - Page Not Found
-
-
Oops! The page you're looking for does not exist. It might have been moved, renamed, or might never existed.
Can be used to create strongly typed Svelte components.
+- Preparing search index...
- The search index is not available
qwksearch-web-appClass SidebarSettingsNav<Props, Events, Slots>
Can be used to create strongly typed Svelte components.
Example:
You have component library on npm called
@@ -49,4 +49,4 @@component-library
, from which you export a component calledMyComponent
. For Svelte+TypeScript users, you want to provide typings. Therefore you create aindex.d.ts
:$set
Parameters
Returns void
Deprecated
This method only exists when using one of the legacy compatibility helpers, which is a stop-gap solution. See https://svelte-5-preview.vercel.app/docs/breaking-changes#components-are-no-longer-classes for more info.
-Settings
On This Page
Constructors
Properties
- DO NOT USE!
$$events_- DO NOT USE!
$$slot_- DO NOT USE!
$$bindingsMethods