Skip to content

Commit b72533e

Browse files
author
LearningCoding101
committed
init proj
0 parents  commit b72533e

File tree

76 files changed

+11696
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

76 files changed

+11696
-0
lines changed

.eslintrc.cjs

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
module.exports = {
2+
root: true,
3+
env: { browser: true, es2020: true },
4+
extends: [
5+
"eslint:recommended",
6+
"plugin:react/recommended",
7+
"plugin:react/jsx-runtime",
8+
"plugin:react-hooks/recommended",
9+
],
10+
ignorePatterns: ["dist", ".eslintrc.cjs"],
11+
parserOptions: { ecmaVersion: "latest", sourceType: "module" },
12+
settings: { react: { version: "18.3" } },
13+
plugins: ["react-refresh"],
14+
rules: {
15+
"react-refresh/only-export-components": [
16+
"warn",
17+
{ allowConstantExport: true },
18+
],
19+
"react/prop-types": "off",
20+
},
21+
};

.gitignore

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
yarn-debug.log*
6+
yarn-error.log*
7+
pnpm-debug.log*
8+
lerna-debug.log*
9+
10+
node_modules
11+
dist
12+
dist-ssr
13+
*.local
14+
mcp.json
15+
# Editor directories and files
16+
.vscode/*
17+
!.vscode/extensions.json
18+
!.vscode/mcp.json
19+
.idea
20+
.DS_Store
21+
*.suo
22+
*.ntvs*
23+
*.njsproj
24+
*.sln
25+
*.sw?
26+
27+
# PWA
28+
dev-dist
29+
sw.js
30+
workbox-*.js

IMPLEMENTATION.md

Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
# Bong Capstone - Implementation Summary
2+
3+
## ✅ Project Setup Complete
4+
5+
### What Was Built
6+
7+
1. **Mobile-First React + Vite Application**
8+
- React 18.3 with modern hooks
9+
- Vite 5.4 for fast development
10+
- React Router 6 for routing
11+
- PWA support with service worker
12+
13+
2. **Figma Homepage Implementation**
14+
- Exact recreation of Figma design (node-id: 137-2497)
15+
- Vietnamese language support
16+
- All design assets downloaded and integrated:
17+
- Background pattern
18+
- Radial blur effect
19+
- Dragon illustration
20+
- Logo
21+
- Matching colors, spacing, and typography
22+
23+
### Key Features
24+
25+
- **Mobile-Optimized**: Touch targets, viewport settings, responsive design
26+
- **PWA Ready**: Installable on mobile devices with offline support
27+
- **Fast Performance**: Vite HMR, optimized builds, code splitting
28+
- **Modern Stack**: React 18, ES modules, CSS custom properties
29+
30+
### File Structure
31+
32+
```
33+
bong-capstone/
34+
├── src/
35+
│ ├── assets/ # Figma design images
36+
│ │ ├── background-pattern.png
37+
│ │ ├── radial-blur.png
38+
│ │ ├── dragon-illustration.png
39+
│ │ └── logo-438b93.png
40+
│ ├── components/ # Reusable components
41+
│ │ ├── Layout.jsx # App layout wrapper
42+
│ │ └── Navigation.jsx # Mobile navigation
43+
│ ├── pages/ # Page components
44+
│ │ ├── Home.jsx # Figma homepage
45+
│ │ └── About.jsx # About page
46+
│ ├── styles/ # Global styles
47+
│ │ └── index.css
48+
│ ├── App.jsx
49+
│ ├── main.jsx
50+
│ └── router.jsx
51+
├── public/
52+
├── index.html # Mobile meta tags
53+
├── vite.config.js # Vite + PWA config
54+
└── package.json
55+
56+
```
57+
58+
### Design Specifications Matched
59+
60+
- **Colors**:
61+
- Primary: `#F37327` (orange)
62+
- Secondary: `#4FC6E0` (blue button)
63+
- Text: `#FAEDD0` (light cream)
64+
- Background glow: `#FFFAF6`
65+
66+
- **Typography**:
67+
- Welcome text: 24px, letter-spacing -3%
68+
- Subtitle: Poppins 18px, weight 600
69+
- Button: Poppins 18px, weight 500
70+
71+
- **Layout**:
72+
- Max width: 393px (iPhone 14/15 Pro)
73+
- Full viewport height
74+
- Centered content
75+
- Layered background effects
76+
77+
### Running the Application
78+
79+
```bash
80+
# Install dependencies
81+
npm install
82+
83+
# Start development server
84+
npm run dev
85+
86+
# Build for production
87+
npm run build
88+
89+
# Preview production build
90+
npm run preview
91+
```
92+
93+
### Development Server
94+
95+
Currently running at:
96+
- Local: http://localhost:3000/
97+
- Network accessible for mobile testing
98+
99+
### Next Steps
100+
101+
The homepage from Figma has been successfully implemented. The application is:
102+
- ✅ Running and accessible
103+
- ✅ Mobile-optimized
104+
- ✅ Matching Figma design
105+
- ✅ Ready for additional pages/features
106+
107+
### Notes
108+
109+
- Homepage renders without navigation (as per Figma design)
110+
- Other routes (like /about) still use the Layout with navigation
111+
- All images optimized and properly loaded
112+
- Vietnamese text properly displayed
113+
- Touch interactions smooth and responsive

README.md

Lines changed: 104 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
# Bong Capstone - Mobile-First React App
2+
3+
A modern, mobile-first web application built with React 18 and Vite, optimized for mobile interfaces.
4+
5+
## Features
6+
7+
-**Lightning Fast** - Built with Vite for instant hot module replacement
8+
- 📱 **Mobile-First Design** - Optimized for mobile devices with touch-friendly interactions
9+
- 🎨 **Modern UI** - Clean and responsive design that works everywhere
10+
- 🔧 **PWA Ready** - Progressive Web App capabilities for app-like experience
11+
- 🌙 **Dark Mode** - Automatic dark mode support based on system preferences
12+
-**Accessible** - Follows WCAG guidelines for accessibility
13+
- 🚀 **Fast Loading** - Optimized bundle size and lazy loading
14+
15+
## Technology Stack
16+
17+
- **React 18.3+** - Modern UI library with concurrent features
18+
- **Vite 5.4+** - Next-generation frontend build tool
19+
- **React Router 6** - Declarative routing for React applications
20+
- **Vite PWA Plugin** - Progressive Web App capabilities
21+
- **ESLint** - Code quality and consistency
22+
23+
## Getting Started
24+
25+
### Prerequisites
26+
27+
- Node.js 18+ and npm/yarn/pnpm
28+
29+
### Installation
30+
31+
1. Clone the repository:
32+
```bash
33+
git clone <repository-url>
34+
cd bong-capstone
35+
```
36+
37+
2. Install dependencies:
38+
```bash
39+
npm install
40+
```
41+
42+
3. Start the development server:
43+
```bash
44+
npm run dev
45+
```
46+
47+
The application will open at `http://localhost:3000`
48+
49+
## Available Scripts
50+
51+
- `npm run dev` - Start development server with hot reload
52+
- `npm run build` - Build for production
53+
- `npm run preview` - Preview production build locally
54+
- `npm run lint` - Run ESLint for code quality checks
55+
56+
## Project Structure
57+
58+
```
59+
bong-capstone/
60+
├── public/ # Static assets
61+
├── src/
62+
│ ├── assets/ # Images, fonts, etc.
63+
│ ├── components/ # Reusable React components
64+
│ │ ├── Layout.jsx
65+
│ │ └── Navigation.jsx
66+
│ ├── pages/ # Page components
67+
│ │ ├── Home.jsx
68+
│ │ └── About.jsx
69+
│ ├── styles/ # Global styles
70+
│ │ └── index.css
71+
│ ├── App.jsx # Root component
72+
│ ├── main.jsx # Application entry point
73+
│ └── router.jsx # Route configuration
74+
├── index.html # HTML template
75+
├── vite.config.js # Vite configuration
76+
└── package.json # Project dependencies
77+
```
78+
79+
## Mobile Optimization
80+
81+
This application follows mobile-first best practices:
82+
83+
- **Touch Targets**: Minimum 44x44px touch targets for all interactive elements
84+
- **Viewport**: Properly configured viewport meta tags
85+
- **Responsive Design**: Mobile-first CSS with progressive enhancement
86+
- **Performance**: Optimized assets and lazy loading
87+
- **PWA**: Installable on mobile devices with offline support
88+
- **Safe Areas**: Support for device notches and safe areas
89+
90+
## Browser Support
91+
92+
- Chrome/Edge (last 2 versions)
93+
- Firefox (last 2 versions)
94+
- Safari (last 2 versions)
95+
- iOS Safari 12+
96+
- Chrome Android 90+
97+
98+
## Contributing
99+
100+
Contributions are welcome! Please feel free to submit a Pull Request.
101+
102+
## License
103+
104+
This project is licensed under the MIT License.

index.html

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
<!doctype html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8" />
5+
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
6+
7+
<!-- Mobile Optimization Meta Tags -->
8+
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=5.0, user-scalable=yes" />
9+
<meta name="mobile-web-app-capable" content="yes" />
10+
<meta name="apple-mobile-web-app-capable" content="yes" />
11+
<meta name="apple-mobile-web-app-status-bar-style" content="default" />
12+
<meta name="theme-color" content="#F37327" />
13+
14+
<!-- Touch Icons -->
15+
<link rel="apple-touch-icon" href="/apple-touch-icon.png" />
16+
17+
<!-- SEO Meta Tags -->
18+
<meta name="description" content="Mobile-first React application built with Vite" />
19+
<meta name="keywords" content="react, vite, mobile, pwa" />
20+
21+
<!-- Google Fonts -->
22+
<link rel="preconnect" href="https://fonts.googleapis.com" />
23+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
24+
<link href="https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap" rel="stylesheet" />
25+
26+
<title>Bong Capstone App</title>
27+
</head>
28+
<body>
29+
<div id="root"></div>
30+
<script type="module" src="/src/main.jsx"></script>
31+
</body>
32+
</html>

0 commit comments

Comments
 (0)