Spaces:
Configuration error

File size: 977 Bytes
420bd16
 
 
 
 
 
 
 
b670b48
 
420bd16
 
b670b48
420bd16
 
 
b670b48
420bd16
 
b670b48
 
 
420bd16
 
 
 
 
 
 
 
 
 
 
b670b48
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
import React from 'react';
import { useAppState } from './hooks/useAppState';
import { LoadingScreen } from './components/LoadingScreen';
import { LoginScreen } from './components/LoginScreen';
import { MainLayout } from './components/MainLayout';
import { UserProfile } from './components/UserProfile';
import { MindmappingTab } from './components/MindmappingTab';
import './styles/App.css';

export default function App() {
  const appState = useAppState();
  const { loading, user } = appState;

  if (loading) {
    return <LoadingScreen />;
  }

  if (!user) {
    return <LoginScreen />;
  }

  return (
    <div className="app">
      <header className="app-header">
        <div className="title-section">
          <div className="title">Foundups AI Mind Map</div>
          <div className="version">version 0.026</div>
        </div>
        <UserProfile />
      </header>
      <main className="app-main">
        <MindmappingTab />
      </main>
    </div>
  );
}