App.tsx 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. import React, { useState } from 'react';
  2. import AppRoutes from './routes';
  3. import type { ContactData } from './types';
  4. const App: React.FC = () => {
  5. // Mock data for the contact, now managed by state
  6. const [contactData, setContactData] = useState<ContactData>({
  7. name: 'Alex Doe',
  8. avatarUrl: 'https://picsum.photos/200',
  9. virtualId: 'VID-2024-8A4B-C7D2-F1E0',
  10. bio: 'Senior Frontend Engineer with a passion for creating beautiful and functional user interfaces. Expert in React, TypeScript, and modern web technologies. In my free time, I explore the intersection of AI and art.',
  11. socials: {
  12. linkedin: 'https://www.linkedin.com/in/alex-doe',
  13. x: 'https://x.com/alex_doe',
  14. github: 'https://github.com/alexdoe',
  15. tiktok: 'https://www.tiktok.com/@alexdoe.dev',
  16. instagram: 'https://www.instagram.com/alex.doe',
  17. facebook: 'https://www.facebook.com/alex.doe',
  18. discord: 'alex.doe#1234',
  19. },
  20. authenticityScore: {
  21. videoVerification: 15, // max 15
  22. socialBinding: 45, // max 45
  23. cloneMaturity: 48, // max 60
  24. },
  25. videoIntroUrl: 'https://storage.googleapis.com/web-dev-assets/video-introduction-demo.mp4',
  26. videoPosterUrl: 'https://picsum.photos/seed/video-poster/800/450',
  27. });
  28. const handleSave = (newData: ContactData) => {
  29. setContactData(newData);
  30. };
  31. return (
  32. <div className="min-h-screen bg-slate-50 font-sans text-slate-800">
  33. <AppRoutes contactData={contactData} onSave={handleSave} />
  34. <footer className="text-center p-4 text-slate-500 text-sm">
  35. <p>&copy; 2024 Virtual Identity System. All rights reserved.</p>
  36. </footer>
  37. </div>
  38. );
  39. };
  40. export default App;