Sign in to your account
-
Welcome back, we are lucky to have you.
+
+ Welcome back, we are lucky to have you.
+
-
+
Don't have an account?{' '}
Sign up
diff --git a/apps/web/src/app/(unauthenticated)/signup/page.tsx b/apps/web/src/app/(unauthenticated)/signup/page.tsx
index 58bddea1a..b398e6990 100644
--- a/apps/web/src/app/(unauthenticated)/signup/page.tsx
+++ b/apps/web/src/app/(unauthenticated)/signup/page.tsx
@@ -10,20 +10,24 @@ export default function SignUpPage() {
-
+
Create a shiny, new Documenso Account ✨
-
+
Create your account and start using state-of-the-art document signing. Open and
beautiful signing is within your grasp.
-
+
Already have an account?{' '}
Sign in instead
diff --git a/apps/web/src/app/layout.tsx b/apps/web/src/app/layout.tsx
index b4af6d7e5..9ce82a4c0 100644
--- a/apps/web/src/app/layout.tsx
+++ b/apps/web/src/app/layout.tsx
@@ -3,6 +3,7 @@ import { Inter } from 'next/font/google';
import { TrpcProvider } from '@documenso/trpc/react';
import { Toaster } from '@documenso/ui/primitives/toaster';
+import { ThemeProvider } from '~/providers/next-theme';
import { PlausibleProvider } from '~/providers/plausible';
import './globals.css';
@@ -45,7 +46,9 @@ export default function RootLayout({ children }: { children: React.ReactNode })
- {children}
+
+ {children}
+
diff --git a/apps/web/src/components/(dashboard)/document-dropzone/document-dropzone.tsx b/apps/web/src/components/(dashboard)/document-dropzone/document-dropzone.tsx
index 2ce754e6c..c3c53d32e 100644
--- a/apps/web/src/components/(dashboard)/document-dropzone/document-dropzone.tsx
+++ b/apps/web/src/components/(dashboard)/document-dropzone/document-dropzone.tsx
@@ -2,6 +2,7 @@
import { Variants, motion } from 'framer-motion';
import { Plus } from 'lucide-react';
+import { useTheme } from 'next-themes';
import { useDropzone } from 'react-dropzone';
import { cn } from '@documenso/ui/lib/utils';
@@ -91,6 +92,8 @@ export const DocumentDropzone = ({ className, onDrop, ...props }: DocumentDropzo
},
});
+ const { theme } = useTheme();
+
return (
@@ -111,39 +118,41 @@ export const DocumentDropzone = ({ className, onDrop, ...props }: DocumentDropzo
{/* */}
- Add a document
+
+ Add a document
+
- Drag & drop your document here.
+ Drag & drop your document here.
diff --git a/apps/web/src/components/(dashboard)/layout/desktop-nav.tsx b/apps/web/src/components/(dashboard)/layout/desktop-nav.tsx
index 97851a534..d0927c323 100644
--- a/apps/web/src/components/(dashboard)/layout/desktop-nav.tsx
+++ b/apps/web/src/components/(dashboard)/layout/desktop-nav.tsx
@@ -16,17 +16,23 @@ export const DesktopNav = ({ className, ...props }: DesktopNavProps) => {
Dashboard
Documents
diff --git a/apps/web/src/components/(dashboard)/layout/header.tsx b/apps/web/src/components/(dashboard)/layout/header.tsx
index 5a83ccbd8..c10fa9e5e 100644
--- a/apps/web/src/components/(dashboard)/layout/header.tsx
+++ b/apps/web/src/components/(dashboard)/layout/header.tsx
@@ -29,7 +29,10 @@ export const Header = ({ className, user, ...props }: HeaderProps) => {
{...props}
>
-
+
diff --git a/apps/web/src/components/(dashboard)/layout/profile-dropdown.tsx b/apps/web/src/components/(dashboard)/layout/profile-dropdown.tsx
index a69d547b9..e07b786c3 100644
--- a/apps/web/src/components/(dashboard)/layout/profile-dropdown.tsx
+++ b/apps/web/src/components/(dashboard)/layout/profile-dropdown.tsx
@@ -2,8 +2,18 @@
import Link from 'next/link';
-import { CreditCard, Github, Key, LogOut, User as LucideUser } from 'lucide-react';
+import {
+ CreditCard,
+ Github,
+ Key,
+ LogOut,
+ User as LucideUser,
+ Monitor,
+ Moon,
+ Sun,
+} from 'lucide-react';
import { signOut } from 'next-auth/react';
+import { useTheme } from 'next-themes';
import { IS_SUBSCRIPTIONS_ENABLED } from '@documenso/lib/constants/features';
import { User } from '@documenso/prisma/client';
@@ -26,10 +36,12 @@ export const ProfileDropdown = ({ user }: ProfileDropdownProps) => {
const initials =
user.name
?.split(' ')
- .map((name) => name.slice(0, 1).toUpperCase())
+ .map((name: string) => name.slice(0, 1).toUpperCase())
.slice(0, 2)
.join('') ?? 'UK';
+ const { theme, setTheme } = useTheme();
+
return (
@@ -68,6 +80,28 @@ export const ProfileDropdown = ({ user }: ProfileDropdownProps) => {
+ {theme === 'light' ? null : (
+ setTheme('light')}>
+
+ Light Mode
+
+ )}
+ {theme === 'dark' ? null : (
+ setTheme('dark')}>
+
+ Dark Mode
+
+ )}
+
+ {theme === 'system' ? null : (
+ setTheme('system')}>
+
+ System Theme
+
+ )}
+
+
+
diff --git a/apps/web/src/components/(dashboard)/metric-card/metric-card.tsx b/apps/web/src/components/(dashboard)/metric-card/metric-card.tsx
index 885feda12..c9c36cc47 100644
--- a/apps/web/src/components/(dashboard)/metric-card/metric-card.tsx
+++ b/apps/web/src/components/(dashboard)/metric-card/metric-card.tsx
@@ -13,7 +13,7 @@ export type CardMetricProps = {
export const CardMetric = ({ icon: Icon, title, value, className }: CardMetricProps) => {
return (
-
+
{Icon && }
@@ -21,7 +21,7 @@ export const CardMetric = ({ icon: Icon, title, value, className }: CardMetricPr
{title}
-
+
{typeof value === 'number' ? value.toLocaleString('en-US') : value}
diff --git a/apps/web/src/components/(dashboard)/pdf-viewer/pdf-viewer.tsx b/apps/web/src/components/(dashboard)/pdf-viewer/pdf-viewer.tsx
index cc98d1dfa..f35e5d48a 100644
--- a/apps/web/src/components/(dashboard)/pdf-viewer/pdf-viewer.tsx
+++ b/apps/web/src/components/(dashboard)/pdf-viewer/pdf-viewer.tsx
@@ -132,7 +132,7 @@ export const PDFViewer = ({ className, document, onPageClick, ...props }: PDFVie
.map((_, i) => (
import('~/components/(dashboard)/pdf-viewer/pdf-viewer'), {
ssr: false,
loading: () => (
-
-
+
+
-
Loading document...
+
Loading document...
),
});
@@ -59,6 +60,8 @@ export const EditDocumentForm = ({ className, document, user: _user }: EditDocum
resolver: zodResolver(ZEditDocumentFormSchema),
});
+ const { theme } = useTheme();
+
const canGoBack = step > 0;
const canGoNext = isValid && step < MAX_STEP;
@@ -67,14 +70,18 @@ export const EditDocumentForm = ({ className, document, user: _user }: EditDocum
return (
-
+
-
+
{step === 0 && (
)}
-
+
Add Signers ({step + 1}/{MAX_STEP + 1})
-
+
diff --git a/apps/web/src/components/forms/edit-document/add-fields.tsx b/apps/web/src/components/forms/edit-document/add-fields.tsx
index 4a5e495f8..edad9de68 100644
--- a/apps/web/src/components/forms/edit-document/add-fields.tsx
+++ b/apps/web/src/components/forms/edit-document/add-fields.tsx
@@ -34,6 +34,7 @@ export type AddFieldsFormProps = {
watch: UseFormWatch
;
errors: FieldErrors;
isSubmitting: boolean;
+ theme: string;
};
export const AddFieldsFormPartial = ({
@@ -42,6 +43,7 @@ export const AddFieldsFormPartial = ({
watch,
errors: _errors,
isSubmitting: _isSubmitting,
+ theme,
}: AddFieldsFormProps) => {
const signers = watch('signers');
@@ -51,7 +53,9 @@ export const AddFieldsFormPartial = ({
Edit Document
-
Add all relevant fields for each recipient.
+
+ Add all relevant fields for each recipient.
+
@@ -60,7 +64,7 @@ export const AddFieldsFormPartial = ({
{selectedSigner.name && (
@@ -103,56 +107,80 @@ export const AddFieldsFormPartial = ({
-
+
-
+
{selectedSigner.name || 'Signature'}
- Signature
+ Signature
-
+
-
+
{'Email'}
- Email
+ Email
-
+
-
+
{'Name'}
- Name
+ Name
-
+
-
+
{'Date'}
- Date
+ Date
diff --git a/apps/web/src/components/forms/edit-document/add-signers.tsx b/apps/web/src/components/forms/edit-document/add-signers.tsx
index 2f0f1c6ec..9292d6e3a 100644
--- a/apps/web/src/components/forms/edit-document/add-signers.tsx
+++ b/apps/web/src/components/forms/edit-document/add-signers.tsx
@@ -37,11 +37,13 @@ export const AddSignersFormPartial = ({
return (
-
Add Signers
+
Add Signers
-
Add the people who will sign the document.
+
+ Add the people who will sign the document.
+
-
+
@@ -58,7 +60,7 @@ export const AddSignersFormPartial = ({
@@ -76,7 +78,7 @@ export const AddSignersFormPartial = ({
diff --git a/apps/web/src/components/forms/password.tsx b/apps/web/src/components/forms/password.tsx
index 8c6c09e8d..eba0c9a43 100644
--- a/apps/web/src/components/forms/password.tsx
+++ b/apps/web/src/components/forms/password.tsx
@@ -89,7 +89,12 @@ export const PasswordForm = ({ className }: PasswordFormProps) => {
Password
-
+
@@ -102,7 +107,7 @@ export const PasswordForm = ({ className }: PasswordFormProps) => {
diff --git a/apps/web/src/components/forms/profile.tsx b/apps/web/src/components/forms/profile.tsx
index c619090fd..6eceef65f 100644
--- a/apps/web/src/components/forms/profile.tsx
+++ b/apps/web/src/components/forms/profile.tsx
@@ -87,7 +87,7 @@ export const ProfileForm = ({ className, user }: ProfileFormProps) => {
Full Name
-
+
@@ -97,7 +97,7 @@ export const ProfileForm = ({ className, user }: ProfileFormProps) => {
Email
-
+
@@ -111,7 +111,7 @@ export const ProfileForm = ({ className, user }: ProfileFormProps) => {
name="signature"
render={({ field: { onChange } }) => (
onChange(v ?? '')}
/>
)}
diff --git a/apps/web/src/components/forms/signin.tsx b/apps/web/src/components/forms/signin.tsx
index 57600d143..be1991e95 100644
--- a/apps/web/src/components/forms/signin.tsx
+++ b/apps/web/src/components/forms/signin.tsx
@@ -86,7 +86,7 @@ export const SignInForm = ({ className }: SignInFormProps) => {
Email
-
+
{errors.email && {errors.email.message}}
@@ -96,29 +96,34 @@ export const SignInForm = ({ className }: SignInFormProps) => {
Password
-
+
{errors.password && (
{errors.password.message}
)}
-
+
{isSubmitting && }
Sign In
-
-
Or continue with
-
+
+
Or continue with
+
diff --git a/apps/web/src/components/forms/signup.tsx b/apps/web/src/components/forms/signup.tsx
index 2892d6856..773d90f1a 100644
--- a/apps/web/src/components/forms/signup.tsx
+++ b/apps/web/src/components/forms/signup.tsx
@@ -79,44 +79,49 @@ export const SignUpForm = ({ className }: SignUpFormProps) => {
onSubmit={handleSubmit(onFormSubmit)}
>
-
-
+
Email
-
+
{errors.email && {errors.email.message}}
-
+
Password
-
+
-
+
{isSubmitting && }
Sign Up
diff --git a/apps/web/src/components/signature-pad/signature-pad.tsx b/apps/web/src/components/signature-pad/signature-pad.tsx
index 71262d7bb..4ff0a6137 100644
--- a/apps/web/src/components/signature-pad/signature-pad.tsx
+++ b/apps/web/src/components/signature-pad/signature-pad.tsx
@@ -192,7 +192,7 @@ export const SignaturePad = ({ className, onChange, ...props }: SignaturePadProp