A beautiful, modern chatbot interface built with React, TypeScript, and Tailwind CSS.
- ⚡ Fast Performance - Built with Vite for lightning-fast development and builds
- 🔧 TypeScript - Full type safety and excellent developer experience
- 🎯 Responsive - Works perfectly on desktop and mobile devices
- 🌙 Dark Theme - Elegant dark theme with proper contrast ratios
- 💬 Interactive Chat - Real-time chat interface with loading states
- 🚀 Modern Stack - React 18, TypeScript, Tailwind CSS, Vite
- Node.js 16.0 or later
- npm or yarn
- Clone the repository:
git clone <repository-url>
cd react-chatbot-template- Install dependencies:
npm install- Start the development server:
npm run dev- Open your browser and navigate to
http://localhost:3000
npm run dev- Start development servernpm run build- Build for productionnpm run preview- Preview production buildnpm run lint- Run ESLint
src/
├── components/
│ ├── Chat.tsx # Main chat interface
│ ├── ChatInput.tsx # Message input component
│ ├── ChatMessage.tsx # Individual message component
│ └── EmptyState.tsx # Welcome screen with suggestions
├── types/
│ └── chat.ts # TypeScript type definitions
├── App.tsx # Root component
├── main.tsx # Application entry point
└── index.css # Global styles and Tailwind imports
The color scheme is defined in tailwind.config.js. You can customize the chat colors by modifying the theme:
theme: {
extend: {
colors: {
'chat-bg': '#343541', // Main background
'chat-sidebar': '#202123', // Sidebar background
'chat-input': '#40414f', // Input background
// ... more colors
}
}
}The current implementation uses mock responses. To integrate with a real API:
- Replace the
generateResponsefunction inChat.tsx - Add your API endpoint and authentication
- Handle streaming responses if needed
The interface uses Tailwind CSS for styling. You can customize the appearance by:
- Modifying classes in component files
- Adding new utility classes in
index.css - Extending the Tailwind configuration
- React 18 - Modern React with hooks and concurrent features
- TypeScript - Type-safe development
- Vite - Next-generation frontend tooling
- Tailwind CSS - Utility-first CSS framework
- Lucide React - Beautiful, customizable icons
- ESLint - Code linting and formatting
- Fork the repository
- Create a feature branch
- Make your changes
- Run tests and linting
- Submit a pull request
MIT License - see LICENSE file for details