├── public ├── googlec2f92b121acd7f08.html ├── 404.avif ├── 404.png ├── 404.webp ├── logo.png ├── dashboard.png ├── readmeTop.png ├── prescription.png ├── patientDetails.png ├── placeholderIMG.avif ├── placeholderIMG.png ├── placeholderIMG.webp ├── patientsEmptyState.avif ├── patientsEmptyState.png ├── patientsEmptyState.webp ├── placeholderIMGlight.avif ├── placeholderIMGlight.png ├── placeholderIMGlight.webp ├── templateEmptyState.avif ├── templateEmptyState.png ├── templateEmptyState.webp ├── recentSectionEmptyState.avif ├── recentSectionEmptyState.png ├── recentSectionEmptyState.webp ├── recentActivityPageEmptyState.avif ├── recentActivityPageEmptyState.png ├── recentActivityPageEmptyState.webp └── favicon.svg ├── jsconfig.json ├── postcss.config.mjs ├── next.config.mjs ├── src ├── lib │ └── utils.js └── components │ └── ui │ └── sonner.jsx ├── components ├── SessionWrapper.js ├── TitleUpdater.js ├── ThemeScript.js ├── StoreDoctorId.js ├── icons │ └── DocPill.js ├── TitleManager.js ├── PlaceholderImageWithLogo.js ├── ConfirmationDialog.js ├── FluidToggle.js ├── OptimizedImage.js ├── DarkModeToggle.js ├── AuthGuard.js ├── ShareModal.js ├── PillSelector.js ├── CustomDropdown.js ├── KeyGeneratorModal.js ├── SharePDFButton.js └── CustomSelect.js ├── utils ├── api.js ├── dateUtils.js ├── auth.js ├── whatsapp.js ├── theme.js ├── imageUtils.js └── billGenerator.js ├── app ├── page.js ├── api │ ├── auth │ │ ├── verify-otp │ │ │ └── route.js │ │ ├── login │ │ │ └── route.js │ │ ├── validate-key │ │ │ └── route.js │ │ ├── unlink-google │ │ │ └── route.js │ │ ├── generate-key │ │ │ └── route.js │ │ ├── refresh │ │ │ └── route.js │ │ ├── send-otp │ │ │ └── route.js │ │ ├── link-account │ │ │ └── route.js │ │ ├── forgot-password │ │ │ └── route.js │ │ └── register │ │ │ └── route.js │ ├── bills │ │ ├── patient │ │ │ └── [patientId] │ │ │ │ └── route.js │ │ └── route.js │ ├── prescriptions │ │ ├── patient │ │ │ └── [patientId] │ │ │ │ └── route.js │ │ ├── single │ │ │ └── route.js │ │ └── route.js │ ├── activities │ │ ├── cleanup │ │ │ └── route.js │ │ ├── single │ │ │ └── route.js │ │ └── route.js │ ├── templates │ │ ├── [id] │ │ │ ├── route.js │ │ │ └── usage │ │ │ │ └── route.js │ │ ├── single │ │ │ └── route.js │ │ └── route.js │ ├── patients │ │ └── route.js │ ├── hospital-logo │ │ ├── route.js │ │ └── upload │ │ │ └── route.js │ ├── doctor │ │ └── profile │ │ │ └── route.js │ ├── custom-data │ │ └── [type] │ │ │ └── route.js │ ├── logout │ │ └── route.js │ └── upload-to-drive │ │ └── route.js ├── layout.js └── not-found.js ├── components.json ├── .gitignore ├── hooks ├── useScrollToTop.js └── usePageTitle.js ├── next.config.js ├── LICENSE ├── tailwind.config.js ├── lib ├── constants.js ├── mongodb.js ├── medicalData.js └── medicationData.js ├── package.json ├── README.md ├── middleware.js └── services └── imageOptimizationService.js /public/googlec2f92b121acd7f08.html: -------------------------------------------------------------------------------- 1 | google-site-verification: googlec2f92b121acd7f08.html -------------------------------------------------------------------------------- /public/404.avif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/404.avif -------------------------------------------------------------------------------- /public/404.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/404.png -------------------------------------------------------------------------------- /public/404.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/404.webp -------------------------------------------------------------------------------- /public/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/logo.png -------------------------------------------------------------------------------- /public/dashboard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/dashboard.png -------------------------------------------------------------------------------- /public/readmeTop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/readmeTop.png -------------------------------------------------------------------------------- /public/prescription.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/prescription.png -------------------------------------------------------------------------------- /public/patientDetails.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/patientDetails.png -------------------------------------------------------------------------------- /public/placeholderIMG.avif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/placeholderIMG.avif -------------------------------------------------------------------------------- /public/placeholderIMG.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/placeholderIMG.png -------------------------------------------------------------------------------- /public/placeholderIMG.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/placeholderIMG.webp -------------------------------------------------------------------------------- /jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "paths": { 4 | "@/*": ["./src/*"] 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /postcss.config.mjs: -------------------------------------------------------------------------------- 1 | const config = { 2 | plugins: ["@tailwindcss/postcss"], 3 | }; 4 | 5 | export default config; 6 | -------------------------------------------------------------------------------- /public/patientsEmptyState.avif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/patientsEmptyState.avif -------------------------------------------------------------------------------- /public/patientsEmptyState.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/patientsEmptyState.png -------------------------------------------------------------------------------- /public/patientsEmptyState.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/patientsEmptyState.webp -------------------------------------------------------------------------------- /public/placeholderIMGlight.avif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/placeholderIMGlight.avif -------------------------------------------------------------------------------- /public/placeholderIMGlight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/placeholderIMGlight.png -------------------------------------------------------------------------------- /public/placeholderIMGlight.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/placeholderIMGlight.webp -------------------------------------------------------------------------------- /public/templateEmptyState.avif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/templateEmptyState.avif -------------------------------------------------------------------------------- /public/templateEmptyState.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/templateEmptyState.png -------------------------------------------------------------------------------- /public/templateEmptyState.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/templateEmptyState.webp -------------------------------------------------------------------------------- /public/recentSectionEmptyState.avif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/recentSectionEmptyState.avif -------------------------------------------------------------------------------- /public/recentSectionEmptyState.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/recentSectionEmptyState.png -------------------------------------------------------------------------------- /public/recentSectionEmptyState.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/recentSectionEmptyState.webp -------------------------------------------------------------------------------- /public/recentActivityPageEmptyState.avif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/recentActivityPageEmptyState.avif -------------------------------------------------------------------------------- /public/recentActivityPageEmptyState.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/recentActivityPageEmptyState.png -------------------------------------------------------------------------------- /public/recentActivityPageEmptyState.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hiprathamesh/doc-prescrip/HEAD/public/recentActivityPageEmptyState.webp -------------------------------------------------------------------------------- /next.config.mjs: -------------------------------------------------------------------------------- 1 | /** @type {import('next').NextConfig} */ 2 | const nextConfig = { 3 | serverExternalPackages: ['mongodb'], 4 | }; 5 | 6 | export default nextConfig; 7 | -------------------------------------------------------------------------------- /src/lib/utils.js: -------------------------------------------------------------------------------- 1 | import { clsx } from "clsx"; 2 | import { twMerge } from "tailwind-merge" 3 | 4 | export function cn(...inputs) { 5 | return twMerge(clsx(inputs)); 6 | } 7 | -------------------------------------------------------------------------------- /components/SessionWrapper.js: -------------------------------------------------------------------------------- 1 | 'use client'; 2 | 3 | import { SessionProvider } from 'next-auth/react'; 4 | 5 | export default function SessionWrapper({ children }) { 6 | return {children}; 7 | } 8 | -------------------------------------------------------------------------------- /components/TitleUpdater.js: -------------------------------------------------------------------------------- 1 | 'use client'; 2 | 3 | import { useEffect } from 'react'; 4 | import usePageTitle from '../hooks/usePageTitle'; 5 | 6 | export default function TitleUpdater({ title }) { 7 | usePageTitle(title); 8 | return null; // This component doesn't render anything 9 | } -------------------------------------------------------------------------------- /utils/api.js: -------------------------------------------------------------------------------- 1 | /** 2 | * API endpoints configuration 3 | */ 4 | 5 | export const API_ENDPOINTS = { 6 | PATIENTS: '/api/patients', 7 | PRESCRIPTIONS: '/api/prescriptions', 8 | BILLS: '/api/bills', 9 | TEMPLATES: '/api/templates', 10 | CUSTOM_DATA: '/api/custom-data', 11 | ACTIVITIES: '/api/activities' 12 | }; -------------------------------------------------------------------------------- /app/page.js: -------------------------------------------------------------------------------- 1 | 'use client'; 2 | 3 | import Dashboard from '../components/Dashboard'; 4 | import { useEffect } from 'react'; 5 | import { initializeTheme } from '../utils/theme'; 6 | import usePageTitle from '../hooks/usePageTitle'; 7 | 8 | 9 | export default function Home() { 10 | usePageTitle('Dashboard'); 11 | 12 | useEffect(() => { 13 | initializeTheme(); 14 | }, []); 15 | return ; 16 | } -------------------------------------------------------------------------------- /app/api/auth/verify-otp/route.js: -------------------------------------------------------------------------------- 1 | // This file is no longer needed - authentication is now handled by NextAuth 2 | // Registration is done directly without OTP verification 3 | 4 | export async function POST(request) { 5 | return new Response(JSON.stringify({ 6 | success: false, 7 | error: 'This endpoint is deprecated. Please use NextAuth authentication.' 8 | }), { 9 | status: 410, 10 | headers: { 'Content-Type': 'application/json' } 11 | }); 12 | } -------------------------------------------------------------------------------- /app/api/auth/login/route.js: -------------------------------------------------------------------------------- 1 | // This file is no longer needed - authentication is now handled by NextAuth 2 | // All login functionality has been moved to NextAuth's built-in handlers 3 | 4 | export async function POST(request) { 5 | return new Response(JSON.stringify({ 6 | success: false, 7 | error: 'This endpoint is deprecated. Please use NextAuth authentication.' 8 | }), { 9 | status: 410, 10 | headers: { 'Content-Type': 'application/json' } 11 | }); 12 | } 13 | -------------------------------------------------------------------------------- /components.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://ui.shadcn.com/schema.json", 3 | "style": "new-york", 4 | "rsc": false, 5 | "tsx": false, 6 | "tailwind": { 7 | "config": "", 8 | "css": "app/globals.css", 9 | "baseColor": "neutral", 10 | "cssVariables": true, 11 | "prefix": "" 12 | }, 13 | "aliases": { 14 | "components": "@/components", 15 | "utils": "@/lib/utils", 16 | "ui": "@/components/ui", 17 | "lib": "@/lib", 18 | "hooks": "@/hooks" 19 | }, 20 | "iconLibrary": "lucide" 21 | } -------------------------------------------------------------------------------- /components/ThemeScript.js: -------------------------------------------------------------------------------- 1 | export default function ThemeScript() { 2 | return ( 3 |