import React, { useState, useEffect } from 'react';
import { Header } from '../../components/Header';
import { useCallTool } from '../../hooks/useCallTool';
import '../../styles/global.css';

export function App() {
  const [data, setData] = useState<any>(null);
  const { callTool, loading, error } = useCallTool();

  useEffect(() => {
    loadData();
  }, []);

  const loadData = async () => {
    // Call appropriate Wrike API tool
    console.log('Loading data for task-board');
  };

  return (
    <div className="app-container">
      <Header 
        title="Task Board" 
        subtitle="Kanban board for tasks"
      />

      {loading && <div className="loading">Loading...</div>}
      {error && <div className="error">{error}</div>}

      <div className="card">
        <p>This is the Task Board app.</p>
        <p>It integrates with Wrike's API to provide Kanban board for tasks.</p>
      </div>
    </div>
  );
}
