gen-ai-dashboard Tailwind Templates

Gen Ai Dashboard

An interactive data visualization dashboard built with React + TypeScript, featuring dynamic charts (Bar, Line, Pie), query history, and auto-suggestions. Powered by Recharts, Redux Toolkit, and Tailwind CSS.

šŸ“Š Gen AI Analytics Dashboard

A React + TypeScript project that provides an interactive data visualization dashboard using Recharts, Redux Toolkit, and Tailwind CSS. Users can input queries to retrieve and visualize business insights in various chart formats (Bar, Line, Pie).


šŸš€ Features

āœ… Query Input with Auto-Suggestions (Smart recommendations for business-related queries)
āœ… Multiple Chart Types (Bar, Line, Pie - switchable via dropdown)
āœ… History Tab (Click previous queries to reload their results)
āœ… Error Handling (Displays "No Data Found" for invalid queries)
āœ… Loading State (Indicates processing while fetching data)
āœ… Hover Effects (Enhanced Pie chart with better tooltip and interactivity)


šŸ–„ļø Demo

Gen AI Dashboard Preview


šŸ› ļø Tech Stack

  • Frontend: React + TypeScript + Redux Toolkit
  • UI Framework: Tailwind CSS
  • Charts: Recharts
  • State Management: Redux Toolkit
  • Mock Data: Randomized sample data

šŸ“‚ Project Structure

šŸ“‚ src
│── šŸ“ assets  
│── šŸ“ components  
│   ā”œā”€ā”€ QueryInput.tsx    
│   ā”œā”€ā”€ ResultDisplay.tsx    
│   ā”œā”€ā”€ ChartDisplay.tsx   
│   ā”œā”€ā”€ QueryHistory.tsx 
│── šŸ“ pages  
│   ā”œā”€ā”€ Dashboard.tsx   
│── šŸ“ redux  
│   ā”œā”€ā”€ querySlice.ts     
│   ā”œā”€ā”€ store.ts   
│── šŸ“ utils  
│   ā”œā”€ā”€ mockSuggestions.ts  
│── App.tsx
│── main.tsx   

šŸŽØ UI Preview

1ļøāƒ£ Query Input with Auto-Suggestions

User can enter a query related to Sales, Revenue, Orders, Profit, Expenses, etc.

šŸ”¹ Example Queries:

  • "Show me sales data for Q1"
  • "Revenue trends over the past 6 months"

2ļøāƒ£ Interactive Charts

šŸ”¹ Users can toggle between Bar, Line, and Pie charts using a dropdown.
šŸ”¹ Smooth transitions and tooltips enhance data visualization.

3ļøāƒ£ Query History

šŸ”¹ Click any past query from the history tab to reload its results.


šŸ”§ Installation & Setup

git clone https://github.com/Tomkndn/gen-ai-dashboard

cd gen-ai-dashboard

npm install

npm run dev

šŸš€ Open http://localhost:5173/ (or the specified port) in your browser.


šŸ”„ API & Mock Data

Since this is a frontend-based project, it does not fetch live data. Instead, it generates randomized mock data based on query keywords.

šŸ’” Valid Keywords: "sales", "revenue", "customer", "order", "profit", "expenses", "marketing", "inventory"
āŒ Invalid Keywords: Display "No data found for this query."

In future, this can be integrated with GPT-powered AI analytics APIs.


šŸ› ļø Customization

šŸ’” To change the default chart colors, update the gradient definitions in ChartDisplay.tsx:

<defs>
  <linearGradient id="barColor" x1="0" y1="0" x2="0" y2="1">
    <stop offset="0%" stopColor="#6366F1" />
    <stop offset="100%" stopColor="#4F46E5" />
  </linearGradient>
</defs>

Modify colors for Bar, Line, and Pie charts as needed! šŸŽØ


šŸ—ļø Future Enhancements

šŸš€ Possible Improvements:

  • āœ… Live Data Fetching (Integrate with a real-time API)
  • āœ… Export Charts (Save as PNG, SVG, or PDF)
  • āœ… Dark Mode (Toggle between light & dark themes)
  • āœ… More Chart Types (Radar, Scatter, etc.)

šŸ’” Contribution

Contributions are welcome! šŸŽ‰

1ļøāƒ£ Fork the repository
2ļøāƒ£ Create a new branch (feature/new-feature)
3ļøāƒ£ Commit your changes (git commit -m "Added new feature")
4ļøāƒ£ Push to GitHub (git push origin feature/new-feature)
5ļøāƒ£ Open a Pull Request šŸš€


šŸ’” Have Suggestions? Drop an issue or PR on GitHub! šŸš€

Top categories

Loading Svelte Themes