Skip to content

Commit 2d180a1

Browse files
committed
Add health data sharing, protection features, and demo request form
- Add HealthDataContext with FHIR-aligned consent management, audit logging, and support for ABHA (India) and Nepal Health ID integration - Add ConsentManagement component with multilingual consent UI - Add comprehensive Health Data Sharing & Protection section to landing page covering DPDPA, Nepal Privacy Act, HIPAA alignment, and FHIR R4 compliance - Add RequestDemoForm component with multilingual support and validation - Update PatientProfile with health data consent fields - Add app.config.ts with creator info and system configuration - Update footer with creator attribution and contact email Made-with: Cursor
1 parent dd56db5 commit 2d180a1

7 files changed

Lines changed: 2031 additions & 14 deletions

File tree

src/app/Root.tsx

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
11
import { Outlet } from "react-router";
22
import { AppProvider } from "./contexts/AppContext";
3+
import { HealthDataProvider } from "./contexts/HealthDataContext";
34

45
export function Root() {
56
return (
67
<AppProvider>
7-
<div className="min-h-screen bg-background">
8-
<Outlet />
9-
</div>
8+
<HealthDataProvider>
9+
<div className="min-h-screen bg-background">
10+
<Outlet />
11+
</div>
12+
</HealthDataProvider>
1013
</AppProvider>
1114
);
1215
}

src/app/components/ConsentManagement.tsx

Lines changed: 524 additions & 0 deletions
Large diffs are not rendered by default.

src/app/components/RequestDemoForm.tsx

Lines changed: 551 additions & 0 deletions
Large diffs are not rendered by default.

src/app/config/app.config.ts

Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,97 @@
1+
/**
2+
* OPD Queue Management System - Application Configuration
3+
*
4+
* This file contains core application configuration including
5+
* creator information, contact details, and system metadata.
6+
*/
7+
8+
export const APP_CONFIG = {
9+
// Application Metadata
10+
name: "OPD Queue Management System",
11+
version: "1.0.0",
12+
description: "Real-time token tracking, guided navigation, assisted booking, and offline-first reliability for high-volume South Asian OPDs.",
13+
14+
// Creator Information
15+
creator: {
16+
name: "A Nepalese",
17+
email: "reganmaharjann@gmail.com",
18+
github: "https://github.com/rayraycodes",
19+
role: "Creator & Lead Developer",
20+
},
21+
22+
// Contact Information
23+
contact: {
24+
email: "reganmaharjann@gmail.com",
25+
phone: "+977-1-5522266",
26+
support: "reganmaharjann@gmail.com",
27+
demoRequests: "reganmaharjann@gmail.com",
28+
},
29+
30+
// Deployment
31+
urls: {
32+
demo: "https://rayraycodes.github.io/opdsystem",
33+
repository: "https://github.com/rayraycodes/opdsystem",
34+
},
35+
36+
// Supported Languages
37+
languages: ["en", "hi", "ne"] as const,
38+
defaultLanguage: "en" as const,
39+
40+
// Regional Support
41+
regions: {
42+
india: {
43+
name: "India",
44+
healthIdSystem: "ABHA (Ayushman Bharat Health Account)",
45+
regulations: ["DPDPA 2023", "ABDM Health Data Management Policy"],
46+
currency: "INR",
47+
currencySymbol: "₹",
48+
},
49+
nepal: {
50+
name: "Nepal",
51+
healthIdSystem: "Nepal National Health ID",
52+
regulations: ["Nepal Privacy Act 2018/2025", "Digital Privacy and Data Protection Act 2082"],
53+
currency: "NPR",
54+
currencySymbol: "₹",
55+
},
56+
},
57+
58+
// Compliance Standards
59+
compliance: {
60+
international: ["FHIR R4", "HL7 Consent Standard", "HIPAA (aligned)", "IHE Profiles"],
61+
security: {
62+
encryptionAtRest: "AES-256",
63+
encryptionInTransit: "TLS 1.3",
64+
mfaRequired: true,
65+
auditRetentionYears: 7,
66+
breachNotificationHours: 72,
67+
},
68+
},
69+
70+
// Feature Flags
71+
features: {
72+
healthDataSharing: true,
73+
consentManagement: true,
74+
abhaIntegration: true,
75+
nepalHealthIdIntegration: true,
76+
offlineMode: true,
77+
multiLanguage: true,
78+
elderMode: true,
79+
voiceGuidance: true,
80+
highContrast: true,
81+
},
82+
83+
// Data Retention Defaults
84+
dataRetention: {
85+
defaultYears: 7,
86+
minYears: 1,
87+
maxYears: 25,
88+
consentRecordRetentionYears: 7,
89+
},
90+
} as const;
91+
92+
// Export individual sections for convenience
93+
export const { creator, contact, compliance, features } = APP_CONFIG;
94+
95+
// Type exports
96+
export type SupportedLanguage = typeof APP_CONFIG.languages[number];
97+
export type Region = keyof typeof APP_CONFIG.regions;

src/app/contexts/AppContext.tsx

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,26 @@ interface AccessibilitySettings {
88
voiceGuidance: boolean;
99
}
1010

11+
interface HealthDataConsent {
12+
treatmentConsent: boolean;
13+
emergencyAccessConsent: boolean;
14+
dataSharingConsent: boolean;
15+
researchConsent: boolean;
16+
consentDate?: Date;
17+
consentVersion?: string;
18+
}
19+
1120
interface PatientProfile {
1221
id: string;
1322
name: string;
1423
age: number;
1524
gender: string;
1625
phone: string;
1726
abhaId?: string;
27+
nepalHealthId?: string;
28+
healthDataConsent?: HealthDataConsent;
29+
dataRetentionYears?: number;
30+
preferredLanguage?: "en" | "hi" | "ne";
1831
}
1932

2033
interface AppContextType {

0 commit comments

Comments
 (0)