CSNET commited on
Commit
b9e5343
·
verified ·
1 Parent(s): e92b848

ช่วยทำแผนที่ที่เคยไปเที่ยวมาแล้วหน่อย

Browse files

ใส่พิกัน กรุงเทพ ภูเก็ต ฮ่องกง จีน สิงคโปร มาเลย์เซีย เวียดนาม

Files changed (8) hide show
  1. README.md +8 -5
  2. components/footer.js +181 -0
  3. components/navbar.js +188 -0
  4. components/travel-card.js +157 -0
  5. index.html +284 -19
  6. script.js +168 -0
  7. style.css +142 -18
  8. timeline.html +294 -0
README.md CHANGED
@@ -1,10 +1,13 @@
1
  ---
2
- title: Wanderpin Visual Travel Diary Map
3
- emoji: 🐢
4
- colorFrom: pink
5
- colorTo: yellow
6
  sdk: static
7
  pinned: false
 
 
8
  ---
9
 
10
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
 
1
  ---
2
+ title: WanderPin - Visual Travel Diary Map 🌍
3
+ colorFrom: green
4
+ colorTo: red
5
+ emoji: 🐳
6
  sdk: static
7
  pinned: false
8
+ tags:
9
+ - deepsite-v3
10
  ---
11
 
12
+ # Welcome to your new DeepSite project!
13
+ This project was created with [DeepSite](https://huggingface.co/deepsite).
components/footer.js ADDED
@@ -0,0 +1,181 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ class CustomFooter extends HTMLElement {
2
+ connectedCallback() {
3
+ this.attachShadow({ mode: 'open' });
4
+ this.shadowRoot.innerHTML = `
5
+ <style>
6
+ :host {
7
+ display: block;
8
+ width: 100%;
9
+ }
10
+
11
+ footer {
12
+ background: linear-gradient(135deg, #1e293b, #0f172a);
13
+ color: white;
14
+ }
15
+
16
+ .footer-link {
17
+ transition: all 0.3s ease;
18
+ position: relative;
19
+ }
20
+
21
+ .footer-link::before {
22
+ content: '';
23
+ position: absolute;
24
+ bottom: -2px;
25
+ left: 0;
26
+ width: 0;
27
+ height: 2px;
28
+ background: #60a5fa;
29
+ transition: width 0.3s ease;
30
+ }
31
+
32
+ .footer-link:hover::before {
33
+ width: 100%;
34
+ }
35
+
36
+ .social-icon {
37
+ transition: all 0.3s ease;
38
+ }
39
+
40
+ .social-icon:hover {
41
+ transform: translateY(-3px);
42
+ }
43
+
44
+ .back-to-top {
45
+ animation: float 3s ease-in-out infinite;
46
+ }
47
+
48
+ @keyframes float {
49
+ 0%, 100% {
50
+ transform: translateY(0);
51
+ }
52
+ 50% {
53
+ transform: translateY(-5px);
54
+ }
55
+ }
56
+ </style>
57
+
58
+ <footer class="mt-16">
59
+ <div class="container mx-auto px-4 py-12">
60
+ <div class="grid grid-cols-1 md:grid-cols-4 gap-8">
61
+ <!-- Brand Section -->
62
+ <div class="space-y-4">
63
+ <div class="flex items-center space-x-2">
64
+ <i data-feather="map-pin" class="w-8 h-8 text-blue-400"></i>
65
+ <span class="text-2xl font-bold bg-gradient-to-r from-blue-400 to-purple-400 bg-clip-text text-transparent">WanderPin</span>
66
+ </div>
67
+ <p class="text-gray-400 text-sm">
68
+ Visualize your travel memories. Pin your journey. Share your story.
69
+ </p>
70
+ <div class="flex space-x-4">
71
+ <a href="#" class="social-icon">
72
+ <i data-feather="instagram" class="w-5 h-5 text-gray-400 hover:text-pink-400"></i>
73
+ </a>
74
+ <a href="#" class="social-icon">
75
+ <i data-feather="twitter" class="w-5 h-5 text-gray-400 hover:text-blue-400"></i>
76
+ </a>
77
+ <a href="#" class="social-icon">
78
+ <i data-feather="facebook" class="w-5 h-5 text-gray-400 hover:text-blue-600"></i>
79
+ </a>
80
+ <a href="#" class="social-icon">
81
+ <i data-feather="github" class="w-5 h-5 text-gray-400 hover:text-gray-200"></i>
82
+ </a>
83
+ </div>
84
+ </div>
85
+
86
+ <!-- Quick Links -->
87
+ <div>
88
+ <h3 class="text-lg font-semibold mb-4 text-white">Quick Links</h3>
89
+ <ul class="space-y-2">
90
+ <li><a href="index.html" class="footer-link text-gray-400 hover:text-white">Home</a></li>
91
+ <li><a href="timeline.html" class="footer-link text-gray-400 hover:text-white">Timeline</a></li>
92
+ <li><a href="gallery.html" class="footer-link text-gray-400 hover:text-white">Gallery</a></li>
93
+ <li><a href="stats.html" class="footer-link text-gray-400 hover:text-white">Statistics</a></li>
94
+ <li><a href="about.html" class="footer-link text-gray-400 hover:text-white">About</a></li>
95
+ </ul>
96
+ </div>
97
+
98
+ <!-- Destinations -->
99
+ <div>
100
+ <h3 class="text-lg font-semibold mb-4 text-white">Destinations</h3>
101
+ <ul class="space-y-2">
102
+ <li><a href="#" class="footer-link text-gray-400 hover:text-white">Bangkok</a></li>
103
+ <li><a href="#" class="footer-link text-gray-400 hover:text-white">Phuket</a></li>
104
+ <li><a href="#" class="footer-link text-gray-400 hover:text-white">Hong Kong</a></li>
105
+ <li><a href="#" class="footer-link text-gray-400 hover:text-white">China</a></li>
106
+ <li><a href="#" class="footer-link text-gray-400 hover:text-white">Singapore</a></li>
107
+ </ul>
108
+ </div>
109
+
110
+ <!-- Newsletter -->
111
+ <div>
112
+ <h3 class="text-lg font-semibold mb-4 text-white">Stay Updated</h3>
113
+ <p class="text-gray-400 text-sm mb-4">
114
+ Subscribe to get travel tips and updates
115
+ </p>
116
+ <div class="flex">
117
+ <input type="email" placeholder="Your email"
118
+ class="flex-grow px-4 py-2 rounded-l-lg bg-gray-800 text-white border border-gray-700 focus:outline-none focus:border-blue-500">
119
+ <button class="px-4 py-2 bg-blue-500 hover:bg-blue-600 text-white rounded-r-lg transition-colors">
120
+ <i data-feather="send" class="w-4 h-4"></i>
121
+ </button>
122
+ </div>
123
+ </div>
124
+ </div>
125
+
126
+ <!-- Divider -->
127
+ <div class="border-t border-gray-800 my-8"></div>
128
+
129
+ <!-- Bottom Bar -->
130
+ <div class="flex flex-col md:flex-row justify-between items-center">
131
+ <p class="text-gray-500 text-sm">
132
+ © 2024 WanderPin. All rights reserved. Made with <i data-feather="heart" class="w-4 h-4 inline text-red-400"></i> for travelers.
133
+ </p>
134
+
135
+ <div class="flex items-center space-x-6 mt-4 md:mt-0">
136
+ <a href="#" class="footer-link text-gray-500 hover:text-white text-sm">Privacy Policy</a>
137
+ <a href="#" class="footer-link text-gray-500 hover:text-white text-sm">Terms of Service</a>
138
+ <a href="#" class="footer-link text-gray-500 hover:text-white text-sm">Cookie Policy</a>
139
+ </div>
140
+ </div>
141
+
142
+ <!-- Back to Top -->
143
+ <button id="backToTop" class="back-to-top fixed bottom-8 right-8 p-3 bg-blue-500 hover:bg-blue-600 text-white rounded-full shadow-lg transition-all duration-300 opacity-0">
144
+ <i data-feather="arrow-up" class="w-5 h-5"></i>
145
+ </button>
146
+ </div>
147
+ </footer>
148
+ `;
149
+
150
+ this.initEventListeners();
151
+ }
152
+
153
+ initEventListeners() {
154
+ // Back to top button
155
+ const backToTop = this.shadowRoot.getElementById('backToTop');
156
+
157
+ window.addEventListener('scroll', () => {
158
+ if (window.scrollY > 300) {
159
+ backToTop.style.opacity = '1';
160
+ backToTop.style.transform = 'translateY(0)';
161
+ } else {
162
+ backToTop.style.opacity = '0';
163
+ backToTop.style.transform = 'translateY(20px)';
164
+ }
165
+ });
166
+
167
+ backToTop.addEventListener('click', () => {
168
+ window.scrollTo({
169
+ top: 0,
170
+ behavior: 'smooth'
171
+ });
172
+ });
173
+
174
+ // Update feather icons
175
+ setTimeout(() => {
176
+ feather.replace();
177
+ }, 100);
178
+ }
179
+ }
180
+
181
+ customElements.define('custom-footer', CustomFooter);
components/navbar.js ADDED
@@ -0,0 +1,188 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ class CustomNavbar extends HTMLElement {
2
+ connectedCallback() {
3
+ this.attachShadow({ mode: 'open' });
4
+ this.shadowRoot.innerHTML = `
5
+ <style>
6
+ :host {
7
+ display: block;
8
+ width: 100%;
9
+ position: sticky;
10
+ top: 0;
11
+ z-index: 1000;
12
+ }
13
+
14
+ nav {
15
+ background: rgba(255, 255, 255, 0.95);
16
+ backdrop-filter: blur(10px);
17
+ border-bottom: 1px solid rgba(0, 0, 0, 0.1);
18
+ transition: all 0.3s ease;
19
+ }
20
+
21
+ .nav-scrolled {
22
+ box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
23
+ }
24
+
25
+ .nav-link {
26
+ position: relative;
27
+ padding: 0.5rem 1rem;
28
+ transition: color 0.3s ease;
29
+ }
30
+
31
+ .nav-link::after {
32
+ content: '';
33
+ position: absolute;
34
+ bottom: 0;
35
+ left: 50%;
36
+ transform: translateX(-50%);
37
+ width: 0;
38
+ height: 2px;
39
+ background: linear-gradient(90deg, #3b82f6, #8b5cf6);
40
+ transition: width 0.3s ease;
41
+ }
42
+
43
+ .nav-link:hover::after {
44
+ width: 80%;
45
+ }
46
+
47
+ .mobile-menu {
48
+ max-height: 0;
49
+ overflow: hidden;
50
+ transition: max-height 0.5s ease;
51
+ }
52
+
53
+ .mobile-menu.open {
54
+ max-height: 300px;
55
+ }
56
+
57
+ @media (max-width: 768px) {
58
+ .desktop-menu {
59
+ display: none;
60
+ }
61
+ }
62
+
63
+ @media (min-width: 769px) {
64
+ .mobile-menu-button {
65
+ display: none;
66
+ }
67
+ }
68
+ </style>
69
+
70
+ <nav class="py-4">
71
+ <div class="container mx-auto px-4">
72
+ <div class="flex justify-between items-center">
73
+ <!-- Logo -->
74
+ <a href="index.html" class="flex items-center space-x-2 text-2xl font-bold gradient-text">
75
+ <i data-feather="map-pin" class="w-8 h-8"></i>
76
+ <span>WanderPin</span>
77
+ </a>
78
+
79
+ <!-- Desktop Menu -->
80
+ <div class="desktop-menu hidden md:flex items-center space-x-6">
81
+ <a href="index.html" class="nav-link text-gray-700 hover:text-blue-600 font-medium">Home</a>
82
+ <a href="timeline.html" class="nav-link text-gray-700 hover:text-blue-600 font-medium">Timeline</a>
83
+ <a href="gallery.html" class="nav-link text-gray-700 hover:text-blue-600 font-medium">Gallery</a>
84
+ <a href="stats.html" class="nav-link text-gray-700 hover:text-blue-600 font-medium">Stats</a>
85
+ <a href="about.html" class="nav-link text-gray-700 hover:text-blue-600 font-medium">About</a>
86
+ <button id="themeToggle" class="p-2 rounded-full bg-gray-100 hover:bg-gray-200 transition-colors">
87
+ <i data-feather="moon" class="w-5 h-5 text-gray-700"></i>
88
+ </button>
89
+ </div>
90
+
91
+ <!-- Mobile Menu Button -->
92
+ <button id="mobileMenuButton" class="mobile-menu-button md:hidden p-2 rounded-lg hover:bg-gray-100">
93
+ <i data-feather="menu" class="w-6 h-6 text-gray-700"></i>
94
+ </button>
95
+ </div>
96
+
97
+ <!-- Mobile Menu -->
98
+ <div id="mobileMenu" class="mobile-menu md:hidden">
99
+ <div class="flex flex-col space-y-3 py-4">
100
+ <a href="index.html" class="nav-link text-gray-700 hover:text-blue-600 font-medium">Home</a>
101
+ <a href="timeline.html" class="nav-link text-gray-700 hover:text-blue-600 font-medium">Timeline</a>
102
+ <a href="gallery.html" class="nav-link text-gray-700 hover:text-blue-600 font-medium">Gallery</a>
103
+ <a href="stats.html" class="nav-link text-gray-700 hover:text-blue-600 font-medium">Stats</a>
104
+ <a href="about.html" class="nav-link text-gray-700 hover:text-blue-600 font-medium">About</a>
105
+ <div class="flex items-center justify-between pt-3 border-t">
106
+ <span class="text-gray-600">Theme</span>
107
+ <button id="mobileThemeToggle" class="p-2 rounded-full bg-gray-100 hover:bg-gray-200">
108
+ <i data-feather="moon" class="w-5 h-5 text-gray-700"></i>
109
+ </button>
110
+ </div>
111
+ </div>
112
+ </div>
113
+ </div>
114
+ </nav>
115
+ `;
116
+
117
+ this.initEventListeners();
118
+ }
119
+
120
+ initEventListeners() {
121
+ // Mobile menu toggle
122
+ const mobileMenuButton = this.shadowRoot.getElementById('mobileMenuButton');
123
+ const mobileMenu = this.shadowRoot.getElementById('mobileMenu');
124
+ const themeToggle = this.shadowRoot.getElementById('themeToggle');
125
+ const mobileThemeToggle = this.shadowRoot.getElementById('mobileThemeToggle');
126
+
127
+ mobileMenuButton.addEventListener('click', () => {
128
+ mobileMenu.classList.toggle('open');
129
+ const icon = mobileMenuButton.querySelector('i');
130
+ if (mobileMenu.classList.contains('open')) {
131
+ feather.icons.x.toSvg().then(svg => {
132
+ icon.outerHTML = svg;
133
+ });
134
+ } else {
135
+ feather.icons.menu.toSvg().then(svg => {
136
+ icon.outerHTML = svg;
137
+ });
138
+ }
139
+ });
140
+
141
+ // Theme toggle
142
+ const toggleThemeHandler = () => {
143
+ const isDark = document.documentElement.classList.toggle('dark');
144
+ const icons = this.shadowRoot.querySelectorAll('[data-feather]');
145
+ icons.forEach(icon => {
146
+ if (icon.getAttribute('data-feather') === 'moon') {
147
+ feather.icons[isDark ? 'sun' : 'moon'].toSvg().then(svg => {
148
+ icon.outerHTML = svg;
149
+ });
150
+ }
151
+ });
152
+
153
+ // Dispatch event for other components
154
+ document.dispatchEvent(new CustomEvent('themeChange', { detail: { isDark } }));
155
+ };
156
+
157
+ themeToggle?.addEventListener('click', toggleThemeHandler);
158
+ mobileThemeToggle?.addEventListener('click', toggleThemeHandler);
159
+
160
+ // Navbar scroll effect
161
+ window.addEventListener('scroll', () => {
162
+ const nav = this.shadowRoot.querySelector('nav');
163
+ if (window.scrollY > 50) {
164
+ nav.classList.add('nav-scrolled');
165
+ } else {
166
+ nav.classList.remove('nav-scrolled');
167
+ }
168
+ });
169
+
170
+ // Close mobile menu when clicking outside
171
+ document.addEventListener('click', (event) => {
172
+ if (!this.contains(event.target) && mobileMenu.classList.contains('open')) {
173
+ mobileMenu.classList.remove('open');
174
+ const icon = mobileMenuButton.querySelector('i');
175
+ feather.icons.menu.toSvg().then(svg => {
176
+ icon.outerHTML = svg;
177
+ });
178
+ }
179
+ });
180
+
181
+ // Update feather icons
182
+ setTimeout(() => {
183
+ feather.replace();
184
+ }, 100);
185
+ }
186
+ }
187
+
188
+ customElements.define('custom-navbar', CustomNavbar);
components/travel-card.js ADDED
@@ -0,0 +1,157 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ class TravelCard extends HTMLElement {
2
+ static get observedAttributes() {
3
+ return ['name', 'country', 'description', 'image', 'icon', 'color'];
4
+ }
5
+
6
+ constructor() {
7
+ super();
8
+ this.attachShadow({ mode: 'open' });
9
+ }
10
+
11
+ connectedCallback() {
12
+ this.render();
13
+ }
14
+
15
+ attributeChangedCallback(name, oldValue, newValue) {
16
+ if (oldValue !== newValue) {
17
+ this.render();
18
+ }
19
+ }
20
+
21
+ render() {
22
+ const name = this.getAttribute('name') || 'Destination';
23
+ const country = this.getAttribute('country') || 'Country';
24
+ const description = this.getAttribute('description') || 'A beautiful destination worth visiting.';
25
+ const image = this.getAttribute('image') || 'http://static.photos/travel/640x360/100';
26
+ const icon = this.getAttribute('icon') || 'map-pin';
27
+ const color = this.getAttribute('color') || 'blue';
28
+
29
+ const colorClasses = {
30
+ blue: 'bg-blue-100 text-blue-800',
31
+ green: 'bg-green-100 text-green-800',
32
+ red: 'bg-red-100 text-red-800',
33
+ yellow: 'bg-yellow-100 text-yellow-800',
34
+ purple: 'bg-purple-100 text-purple-800',
35
+ pink: 'bg-pink-100 text-pink-800',
36
+ indigo: 'bg-indigo-100 text-indigo-800'
37
+ };
38
+
39
+ const iconColors = {
40
+ blue: '#3b82f6',
41
+ green: '#10b981',
42
+ red: '#ef4444',
43
+ yellow: '#f59e0b',
44
+ purple: '#8b5cf6',
45
+ pink: '#ec4899',
46
+ indigo: '#6366f1'
47
+ };
48
+
49
+ this.shadowRoot.innerHTML = `
50
+ <style>
51
+ :host {
52
+ display: block;
53
+ margin: 0;
54
+ padding: 0;
55
+ }
56
+
57
+ .card {
58
+ transition: all 0.3s ease;
59
+ height: 100%;
60
+ }
61
+
62
+ .card:hover {
63
+ transform: translateY(-8px);
64
+ }
65
+
66
+ .image-container {
67
+ position: relative;
68
+ overflow: hidden;
69
+ }
70
+
71
+ .image-container::after {
72
+ content: '';
73
+ position: absolute;
74
+ bottom: 0;
75
+ left: 0;
76
+ right: 0;
77
+ height: 50%;
78
+ background: linear-gradient(to top, rgba(0,0,0,0.3), transparent);
79
+ }
80
+
81
+ .icon-container {
82
+ transition: transform 0.3s ease;
83
+ }
84
+
85
+ .card:hover .icon-container {
86
+ transform: scale(1.1) rotate(5deg);
87
+ }
88
+
89
+ .description {
90
+ display: -webkit-box;
91
+ -webkit-line-clamp: 3;
92
+ -webkit-box-orient: vertical;
93
+ overflow: hidden;
94
+ }
95
+ </style>
96
+
97
+ <div class="card bg-white rounded-2xl shadow-lg overflow-hidden hover-lift h-full border border-gray-100">
98
+ <!-- Image -->
99
+ <div class="image-container h-48 relative">
100
+ <img src="${image}"
101
+ alt="${name}"
102
+ class="w-full h-full object-cover transition-transform duration-500 hover:scale-110"
103
+ loading="lazy">
104
+
105
+ <!-- Icon Badge -->
106
+ <div class="absolute top-4 right-4 icon-container">
107
+ <div class="${colorClasses[color] || colorClasses.blue} p-3 rounded-full shadow-lg">
108
+ <i data-feather="${icon}" class="w-5 h-5"></i>
109
+ </div>
110
+ </div>
111
+ </div>
112
+
113
+ <!-- Content -->
114
+ <div class="p-6">
115
+ <div class="flex justify-between items-start mb-3">
116
+ <div>
117
+ <h3 class="text-xl font-bold text-gray-800">${name}</h3>
118
+ <div class="flex items-center mt-1">
119
+ <i data-feather="flag" class="w-4 h-4 text-gray-500 mr-2"></i>
120
+ <span class="text-gray-600 text-sm">${country}</span>
121
+ </div>
122
+ </div>
123
+ </div>
124
+
125
+ <p class="description text-gray-600 mb-4">${description}</p>
126
+
127
+ <!-- Tags -->
128
+ <div class="flex flex-wrap gap-2 mb-4">
129
+ <span class="px-3 py-1 bg-gray-100 text-gray-700 rounded-full text-xs font-medium">
130
+ <i data-feather="calendar" class="w-3 h-3 inline mr-1"></i>
131
+ Visited
132
+ </span>
133
+ <span class="px-3 py-1 bg-gray-100 text-gray-700 rounded-full text-xs font-medium">
134
+ <i data-feather="star" class="w-3 h-3 inline mr-1"></i>
135
+ Recommended
136
+ </span>
137
+ </div>
138
+
139
+ <!-- Action Button -->
140
+ <button class="w-full py-2 px-4 bg-gradient-to-r from-blue-500 to-blue-600 hover:from-blue-600 hover:to-blue-700 text-white rounded-lg transition-all duration-300 flex items-center justify-center group">
141
+ <span>View Details</span>
142
+ <i data-feather="arrow-right" class="w-4 h-4 ml-2 group-hover:translate-x-1 transition-transform"></i>
143
+ </button>
144
+ </div>
145
+ </div>
146
+ `;
147
+
148
+ // Update feather icons
149
+ setTimeout(() => {
150
+ if (typeof feather !== 'undefined') {
151
+ feather.replace();
152
+ }
153
+ }, 100);
154
+ }
155
+ }
156
+
157
+ customElements.define('travel-card', TravelCard);
index.html CHANGED
@@ -1,19 +1,284 @@
1
- <!doctype html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <meta name="viewport" content="width=device-width" />
6
- <title>My static Space</title>
7
- <link rel="stylesheet" href="style.css" />
8
- </head>
9
- <body>
10
- <div class="card">
11
- <h1>Welcome to your static Space!</h1>
12
- <p>You can modify this app directly by editing <i>index.html</i> in the Files and versions tab.</p>
13
- <p>
14
- Also don't forget to check the
15
- <a href="https://huggingface.co/docs/hub/spaces" target="_blank">Spaces documentation</a>.
16
- </p>
17
- </div>
18
- </body>
19
- </html>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>WanderPin - My Travel Map</title>
7
+ <link rel="icon" type="image/x-icon" href="/static/favicon.ico">
8
+ <script src="https://cdn.tailwindcss.com"></script>
9
+ <script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
10
+ <script src="https://unpkg.com/feather-icons"></script>
11
+ <link rel="stylesheet" href="style.css">
12
+ <script src="components/navbar.js"></script>
13
+ <script src="components/footer.js"></script>
14
+ <script src="components/travel-card.js"></script>
15
+ <script src="https://unpkg.com/leaflet@1.9.4/dist/leaflet.js"></script>
16
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.9.4/dist/leaflet.css" />
17
+ <script src="https://unpkg.com/leaflet.markercluster@1.5.3/dist/leaflet.markercluster.js"></script>
18
+ <link rel="stylesheet" href="https://unpkg.com/leaflet.markercluster@1.5.3/dist/MarkerCluster.css" />
19
+ <link rel="stylesheet" href="https://unpkg.com/leaflet.markercluster@1.5.3/dist/MarkerCluster.Default.css" />
20
+ <style>
21
+ #map { height: 500px; }
22
+ .leaflet-popup-content { font-family: 'Inter', sans-serif; }
23
+ .custom-marker { background: none; border: none; }
24
+ </style>
25
+ </head>
26
+ <body class="bg-gradient-to-br from-gray-50 to-blue-50 min-h-screen">
27
+ <custom-navbar></custom-navbar>
28
+
29
+ <main class="container mx-auto px-4 py-8 max-w-7xl">
30
+ <!-- Hero Section -->
31
+ <section class="text-center mb-12">
32
+ <h1 class="text-5xl font-bold text-gray-800 mb-4">My Travel Journey <i data-feather="map-pin" class="inline-block text-blue-500"></i></h1>
33
+ <p class="text-xl text-gray-600 max-w-3xl mx-auto">A visual diary of all the amazing places I've visited across Southeast Asia and beyond. Each pin tells a story!</p>
34
+ <div class="mt-6">
35
+ <span class="inline-block px-4 py-2 bg-blue-100 text-blue-800 rounded-full text-sm font-semibold mr-2 mb-2">📍 7 Destinations</span>
36
+ <span class="inline-block px-4 py-2 bg-green-100 text-green-800 rounded-full text-sm font-semibold mr-2 mb-2">🌏 4 Countries</span>
37
+ <span class="inline-block px-4 py-2 bg-purple-100 text-purple-800 rounded-full text-sm font-semibold mr-2 mb-2">✈️ 1 Adventurer</span>
38
+ </div>
39
+ </section>
40
+
41
+ <!-- Interactive Map Section -->
42
+ <section class="mb-16">
43
+ <div class="bg-white rounded-2xl shadow-xl p-4 md:p-6 border border-gray-200">
44
+ <div class="flex justify-between items-center mb-4">
45
+ <h2 class="text-2xl font-bold text-gray-800 flex items-center">
46
+ <i data-feather="map" class="mr-2 text-blue-500"></i> Interactive Travel Map
47
+ </h2>
48
+ <button id="resetView" class="px-4 py-2 bg-blue-500 hover:bg-blue-600 text-white rounded-lg transition duration-300 flex items-center">
49
+ <i data-feather="refresh-cw" class="mr-2 w-4 h-4"></i> Reset View
50
+ </button>
51
+ </div>
52
+ <p class="text-gray-600 mb-6">Click on any pin to see details about my visit. Drag and zoom to explore!</p>
53
+ <div id="map" class="rounded-xl overflow-hidden border border-gray-300"></div>
54
+ <div class="mt-4 text-sm text-gray-500 flex items-center">
55
+ <i data-feather="info" class="mr-2 w-4 h-4"></i>
56
+ <span>Map data © OpenStreetMap contributors | Icons by Feather Icons</span>
57
+ </div>
58
+ </div>
59
+ </section>
60
+
61
+ <!-- Destinations Grid -->
62
+ <section class="mb-16">
63
+ <h2 class="text-3xl font-bold text-gray-800 mb-8 text-center">My Travel Destinations</h2>
64
+ <div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-6">
65
+ <!-- Destination cards will be populated by JavaScript -->
66
+ </div>
67
+ </section>
68
+
69
+ <!-- Travel Stats -->
70
+ <section class="mb-16">
71
+ <div class="bg-gradient-to-r from-blue-500 to-purple-600 rounded-2xl shadow-xl p-8 text-white">
72
+ <h2 class="text-3xl font-bold mb-6 text-center">Travel Statistics</h2>
73
+ <div class="grid grid-cols-2 md:grid-cols-4 gap-6">
74
+ <div class="text-center">
75
+ <div class="text-4xl font-bold mb-2">7</div>
76
+ <div class="text-blue-100">Destinations</div>
77
+ </div>
78
+ <div class="text-center">
79
+ <div class="text-4xl font-bold mb-2">4</div>
80
+ <div class="text-blue-100">Countries</div>
81
+ </div>
82
+ <div class="text-center">
83
+ <div class="text-4xl font-bold mb-2">1</div>
84
+ <div class="text-blue-100">Continent</div>
85
+ </div>
86
+ <div class="text-center">
87
+ <div class="text-4xl font-bold mb-2">∞</div>
88
+ <div class="text-blue-100">Memories</div>
89
+ </div>
90
+ </div>
91
+ <div class="mt-8 text-center">
92
+ <p class="text-blue-100 italic">"The world is a book and those who do not travel read only one page." - Saint Augustine</p>
93
+ </div>
94
+ </div>
95
+ </section>
96
+
97
+ <!-- Timeline Preview -->
98
+ <section class="mb-16">
99
+ <div class="bg-white rounded-2xl shadow-xl p-6 border border-gray-200">
100
+ <h2 class="text-2xl font-bold text-gray-800 mb-6 flex items-center">
101
+ <i data-feather="clock" class="mr-2 text-blue-500"></i> Travel Timeline
102
+ </h2>
103
+ <div class="relative">
104
+ <div class="absolute left-1/2 transform -translate-x-1/2 h-full w-1 bg-blue-200"></div>
105
+
106
+ <div class="mb-8 flex items-center">
107
+ <div class="w-1/2 pr-8 text-right">
108
+ <div class="bg-blue-100 p-4 rounded-lg inline-block">
109
+ <h3 class="font-bold text-blue-800">Bangkok, Thailand</h3>
110
+ <p class="text-sm text-blue-600">The City of Angels</p>
111
+ </div>
112
+ </div>
113
+ <div class="absolute left-1/2 transform -translate-x-1/2 w-4 h-4 bg-blue-500 rounded-full border-4 border-white"></div>
114
+ <div class="w-1/2 pl-8">
115
+ <p class="text-gray-600">Vibrant street markets and majestic temples</p>
116
+ </div>
117
+ </div>
118
+
119
+ <div class="mb-8 flex items-center">
120
+ <div class="w-1/2 pr-8 text-right">
121
+ <p class="text-gray-600">Island paradise with stunning beaches</p>
122
+ </div>
123
+ <div class="absolute left-1/2 transform -translate-x-1/2 w-4 h-4 bg-green-500 rounded-full border-4 border-white"></div>
124
+ <div class="w-1/2 pl-8">
125
+ <div class="bg-green-100 p-4 rounded-lg inline-block">
126
+ <h3 class="font-bold text-green-800">Phuket, Thailand</h3>
127
+ <p class="text-sm text-green-600">Tropical Paradise</p>
128
+ </div>
129
+ </div>
130
+ </div>
131
+ </div>
132
+ <div class="text-center mt-6">
133
+ <a href="timeline.html" class="inline-flex items-center px-6 py-3 bg-blue-500 hover:bg-blue-600 text-white rounded-lg transition duration-300">
134
+ View Full Timeline
135
+ <i data-feather="arrow-right" class="ml-2 w-4 h-4"></i>
136
+ </a>
137
+ </div>
138
+ </div>
139
+ </section>
140
+ </main>
141
+
142
+ <custom-footer></custom-footer>
143
+
144
+ <script src="script.js"></script>
145
+ <script>
146
+ feather.replace();
147
+
148
+ // Initialize map after DOM is loaded
149
+ document.addEventListener('DOMContentLoaded', function() {
150
+ // Map initialization
151
+ const map = L.map('map').setView([15.8700, 100.9925], 5);
152
+
153
+ L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
154
+ attribution: '© OpenStreetMap contributors',
155
+ maxZoom: 18,
156
+ }).addTo(map);
157
+
158
+ // Destination data with coordinates
159
+ const destinations = [
160
+ {
161
+ name: "Bangkok, Thailand",
162
+ lat: 13.7563,
163
+ lng: 100.5018,
164
+ country: "Thailand",
165
+ description: "Vibrant capital city with amazing street food and temples",
166
+ icon: "map-pin",
167
+ color: "blue",
168
+ image: "http://static.photos/cityscape/640x360/101"
169
+ },
170
+ {
171
+ name: "Phuket, Thailand",
172
+ lat: 7.8804,
173
+ lng: 98.3923,
174
+ country: "Thailand",
175
+ description: "Tropical island paradise with stunning beaches",
176
+ icon: "sun",
177
+ color: "green",
178
+ image: "http://static.photos/nature/640x360/102"
179
+ },
180
+ {
181
+ name: "Hong Kong",
182
+ lat: 22.3193,
183
+ lng: 114.1694,
184
+ country: "China",
185
+ description: "Bustling metropolis with stunning skyline",
186
+ icon: "trending-up",
187
+ color: "red",
188
+ image: "http://static.photos/cityscape/640x360/103"
189
+ },
190
+ {
191
+ name: "Beijing, China",
192
+ lat: 39.9042,
193
+ lng: 116.4074,
194
+ country: "China",
195
+ description: "Ancient capital with rich history",
196
+ icon: "flag",
197
+ color: "red",
198
+ image: "http://static.photos/travel/640x360/104"
199
+ },
200
+ {
201
+ name: "Singapore",
202
+ lat: 1.3521,
203
+ lng: 103.8198,
204
+ country: "Singapore",
205
+ description: "Garden city with modern architecture",
206
+ icon: "feather",
207
+ color: "blue",
208
+ image: "http://static.photos/technology/640x360/105"
209
+ },
210
+ {
211
+ name: "Kuala Lumpur, Malaysia",
212
+ lat: 3.1390,
213
+ lng: 101.6869,
214
+ country: "Malaysia",
215
+ description: "Cultural melting pot with iconic towers",
216
+ icon: "home",
217
+ color: "yellow",
218
+ image: "http://static.photos/cityscape/640x360/106"
219
+ },
220
+ {
221
+ name: "Hanoi, Vietnam",
222
+ lat: 21.0285,
223
+ lng: 105.8542,
224
+ country: "Vietnam",
225
+ description: "Charming city with French colonial architecture",
226
+ icon: "coffee",
227
+ color: "green",
228
+ image: "http://static.photos/travel/640x360/107"
229
+ }
230
+ ];
231
+
232
+ // Create marker cluster group
233
+ const markers = L.markerClusterGroup();
234
+
235
+ destinations.forEach(dest => {
236
+ // Create custom icon
237
+ const customIcon = L.divIcon({
238
+ html: `<div class="custom-marker"><i data-feather="${dest.icon}" style="color: ${dest.color}; width: 24px; height: 24px;"></i></div>`,
239
+ className: 'custom-div-icon',
240
+ iconSize: [30, 30],
241
+ iconAnchor: [15, 30]
242
+ });
243
+
244
+ const marker = L.marker([dest.lat, dest.lng], { icon: customIcon });
245
+
246
+ marker.bindPopup(`
247
+ <div class="p-2">
248
+ <h3 class="font-bold text-lg">${dest.name}</h3>
249
+ <p class="text-gray-600">${dest.country}</p>
250
+ <p class="mt-2">${dest.description}</p>
251
+ <img src="${dest.image}" alt="${dest.name}" class="mt-2 rounded-lg w-full h-32 object-cover">
252
+ </div>
253
+ `);
254
+
255
+ markers.addLayer(marker);
256
+ });
257
+
258
+ map.addLayer(markers);
259
+
260
+ // Reset view button
261
+ document.getElementById('resetView').addEventListener('click', () => {
262
+ map.setView([15.8700, 100.9925], 5);
263
+ });
264
+
265
+ // Populate destination cards
266
+ const gridContainer = document.querySelector('.grid');
267
+ destinations.forEach(dest => {
268
+ const card = document.createElement('travel-card');
269
+ card.setAttribute('name', dest.name);
270
+ card.setAttribute('country', dest.country);
271
+ card.setAttribute('description', dest.description);
272
+ card.setAttribute('image', dest.image);
273
+ card.setAttribute('icon', dest.icon);
274
+ card.setAttribute('color', dest.color);
275
+ gridContainer.appendChild(card);
276
+ });
277
+
278
+ // Update feather icons for markers
279
+ setTimeout(() => feather.replace(), 100);
280
+ });
281
+ </script>
282
+ <script src="https://huggingface.co/deepsite/deepsite-badge.js"></script>
283
+ </body>
284
+ </html>
script.js ADDED
@@ -0,0 +1,168 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Global utility functions and shared JavaScript code
2
+
3
+ // Debounce function for performance optimization
4
+ function debounce(func, wait) {
5
+ let timeout;
6
+ return function executedFunction(...args) {
7
+ const later = () => {
8
+ clearTimeout(timeout);
9
+ func(...args);
10
+ };
11
+ clearTimeout(timeout);
12
+ timeout = setTimeout(later, wait);
13
+ };
14
+ }
15
+
16
+ // Format date to readable string
17
+ function formatDate(dateString) {
18
+ const options = { year: 'numeric', month: 'long', day: 'numeric' };
19
+ return new Date(dateString).toLocaleDateString('en-US', options);
20
+ }
21
+
22
+ // Smooth scroll to element
23
+ function smoothScrollTo(elementId) {
24
+ const element = document.getElementById(elementId);
25
+ if (element) {
26
+ element.scrollIntoView({
27
+ behavior: 'smooth',
28
+ block: 'start'
29
+ });
30
+ }
31
+ }
32
+
33
+ // Create toast notification
34
+ function showToast(message, type = 'info') {
35
+ const toast = document.createElement('div');
36
+ toast.className = `fixed top-4 right-4 px-6 py-3 rounded-lg shadow-lg text-white transform translate-x-full transition-transform duration-300 ${
37
+ type === 'success' ? 'bg-green-500' :
38
+ type === 'error' ? 'bg-red-500' :
39
+ type === 'warning' ? 'bg-yellow-500' : 'bg-blue-500'
40
+ }`;
41
+ toast.textContent = message;
42
+ document.body.appendChild(toast);
43
+
44
+ // Animate in
45
+ setTimeout(() => {
46
+ toast.style.transform = 'translateX(0)';
47
+ }, 10);
48
+
49
+ // Remove after 3 seconds
50
+ setTimeout(() => {
51
+ toast.style.transform = 'translateX(100%)';
52
+ setTimeout(() => {
53
+ document.body.removeChild(toast);
54
+ }, 300);
55
+ }, 3000);
56
+ }
57
+
58
+ // Check if element is in viewport
59
+ function isInViewport(element) {
60
+ const rect = element.getBoundingClientRect();
61
+ return (
62
+ rect.top >= 0 &&
63
+ rect.left >= 0 &&
64
+ rect.bottom <= (window.innerHeight || document.documentElement.clientHeight) &&
65
+ rect.right <= (window.innerWidth || document.documentElement.clientWidth)
66
+ );
67
+ }
68
+
69
+ // Lazy load images
70
+ function lazyLoadImages() {
71
+ const images = document.querySelectorAll('img[data-src]');
72
+
73
+ const imageObserver = new IntersectionObserver((entries, observer) => {
74
+ entries.forEach(entry => {
75
+ if (entry.isIntersecting) {
76
+ const img = entry.target;
77
+ img.src = img.dataset.src;
78
+ img.removeAttribute('data-src');
79
+ observer.unobserve(img);
80
+ }
81
+ });
82
+ });
83
+
84
+ images.forEach(img => imageObserver.observe(img));
85
+ }
86
+
87
+ // Initialize tooltips for feather icons
88
+ function initTooltips() {
89
+ const icons = document.querySelectorAll('[data-feather]');
90
+ icons.forEach(icon => {
91
+ const title = icon.getAttribute('title');
92
+ if (title) {
93
+ icon.setAttribute('aria-label', title);
94
+ }
95
+ });
96
+ }
97
+
98
+ // Theme management
99
+ function initTheme() {
100
+ const theme = localStorage.getItem('theme') || 'light';
101
+ document.documentElement.classList.toggle('dark', theme === 'dark');
102
+ }
103
+
104
+ function toggleTheme() {
105
+ const isDark = document.documentElement.classList.toggle('dark');
106
+ localStorage.setItem('theme', isDark ? 'dark' : 'light');
107
+ showToast(`Switched to ${isDark ? 'dark' : 'light'} mode`, 'info');
108
+ }
109
+
110
+ // Initialize everything when DOM is loaded
111
+ document.addEventListener('DOMContentLoaded', function() {
112
+ // Initialize tooltips
113
+ initTooltips();
114
+
115
+ // Initialize theme
116
+ initTheme();
117
+
118
+ // Lazy load images
119
+ lazyLoadImages();
120
+
121
+ // Add scroll animations
122
+ const observerOptions = {
123
+ threshold: 0.1,
124
+ rootMargin: '0px 0px -50px 0px'
125
+ };
126
+
127
+ const observer = new IntersectionObserver((entries) => {
128
+ entries.forEach(entry => {
129
+ if (entry.isIntersecting) {
130
+ entry.target.classList.add('animate-fade-in-up');
131
+ }
132
+ });
133
+ }, observerOptions);
134
+
135
+ // Observe elements with animation class
136
+ document.querySelectorAll('.animate-on-scroll').forEach(el => {
137
+ observer.observe(el);
138
+ });
139
+
140
+ // Add click handlers for smooth scrolling links
141
+ document.querySelectorAll('a[href^="#"]').forEach(anchor => {
142
+ anchor.addEventListener('click', function(e) {
143
+ e.preventDefault();
144
+ const targetId = this.getAttribute('href').substring(1);
145
+ smoothScrollTo(targetId);
146
+ });
147
+ });
148
+
149
+ // Initialize feather icons
150
+ if (typeof feather !== 'undefined') {
151
+ feather.replace();
152
+ }
153
+ });
154
+
155
+ // Export functions for use in other modules
156
+ if (typeof module !== 'undefined' && module.exports) {
157
+ module.exports = {
158
+ debounce,
159
+ formatDate,
160
+ smoothScrollTo,
161
+ showToast,
162
+ isInViewport,
163
+ lazyLoadImages,
164
+ initTooltips,
165
+ initTheme,
166
+ toggleTheme
167
+ };
168
+ }
style.css CHANGED
@@ -1,28 +1,152 @@
 
 
 
 
 
 
 
 
 
1
  body {
2
- padding: 2rem;
3
- font-family: -apple-system, BlinkMacSystemFont, "Arial", sans-serif;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4
  }
5
 
6
- h1 {
7
- font-size: 16px;
8
- margin-top: 0;
9
  }
10
 
11
- p {
12
- color: rgb(107, 114, 128);
13
- font-size: 15px;
14
- margin-bottom: 10px;
15
- margin-top: 5px;
16
  }
17
 
18
- .card {
19
- max-width: 620px;
20
- margin: 0 auto;
21
- padding: 16px;
22
- border: 1px solid lightgray;
23
- border-radius: 16px;
24
  }
25
 
26
- .card p:last-child {
27
- margin-bottom: 0;
 
28
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* Global Styles */
2
+ @import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');
3
+
4
+ * {
5
+ margin: 0;
6
+ padding: 0;
7
+ box-sizing: border-box;
8
+ }
9
+
10
  body {
11
+ font-family: 'Inter', sans-serif;
12
+ scroll-behavior: smooth;
13
+ }
14
+
15
+ /* Custom Animations */
16
+ @keyframes fadeInUp {
17
+ from {
18
+ opacity: 0;
19
+ transform: translateY(20px);
20
+ }
21
+ to {
22
+ opacity: 1;
23
+ transform: translateY(0);
24
+ }
25
+ }
26
+
27
+ @keyframes pulse {
28
+ 0%, 100% {
29
+ opacity: 1;
30
+ }
31
+ 50% {
32
+ opacity: 0.7;
33
+ }
34
+ }
35
+
36
+ @keyframes float {
37
+ 0%, 100% {
38
+ transform: translateY(0);
39
+ }
40
+ 50% {
41
+ transform: translateY(-10px);
42
+ }
43
+ }
44
+
45
+ /* Custom Classes */
46
+ .animate-fade-in-up {
47
+ animation: fadeInUp 0.6s ease-out;
48
+ }
49
+
50
+ .animate-pulse-slow {
51
+ animation: pulse 2s infinite;
52
+ }
53
+
54
+ .animate-float {
55
+ animation: float 3s ease-in-out infinite;
56
+ }
57
+
58
+ /* Map Customization */
59
+ .leaflet-popup-content-wrapper {
60
+ border-radius: 12px;
61
+ box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
62
  }
63
 
64
+ .leaflet-popup-content {
65
+ margin: 12px;
66
+ min-width: 200px;
67
  }
68
 
69
+ /* Custom Scrollbar */
70
+ ::-webkit-scrollbar {
71
+ width: 8px;
 
 
72
  }
73
 
74
+ ::-webkit-scrollbar-track {
75
+ background: #f1f1f1;
76
+ border-radius: 4px;
 
 
 
77
  }
78
 
79
+ ::-webkit-scrollbar-thumb {
80
+ background: #888;
81
+ border-radius: 4px;
82
  }
83
+
84
+ ::-webkit-scrollbar-thumb:hover {
85
+ background: #555;
86
+ }
87
+
88
+ /* Gradient Text */
89
+ .gradient-text {
90
+ background: linear-gradient(135deg, #3b82f6, #8b5cf6);
91
+ -webkit-background-clip: text;
92
+ -webkit-text-fill-color: transparent;
93
+ background-clip: text;
94
+ }
95
+
96
+ /* Card Hover Effects */
97
+ .hover-lift {
98
+ transition: transform 0.3s ease, box-shadow 0.3s ease;
99
+ }
100
+
101
+ .hover-lift:hover {
102
+ transform: translateY(-5px);
103
+ box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
104
+ }
105
+
106
+ /* Timeline Custom Styles */
107
+ .timeline-dot {
108
+ position: relative;
109
+ z-index: 2;
110
+ }
111
+
112
+ .timeline-dot::before {
113
+ content: '';
114
+ position: absolute;
115
+ top: 50%;
116
+ left: 50%;
117
+ transform: translate(-50%, -50%);
118
+ width: 20px;
119
+ height: 20px;
120
+ background: inherit;
121
+ border-radius: 50%;
122
+ z-index: -1;
123
+ opacity: 0.2;
124
+ }
125
+
126
+ /* Responsive Adjustments */
127
+ @media (max-width: 768px) {
128
+ .timeline-dot {
129
+ width: 16px;
130
+ height: 16px;
131
+ }
132
+
133
+ .timeline-dot::before {
134
+ width: 32px;
135
+ height: 32px;
136
+ }
137
+ }
138
+
139
+ /* Loading Animation */
140
+ .loading-spinner {
141
+ width: 40px;
142
+ height: 40px;
143
+ border: 4px solid #f3f3f3;
144
+ border-top: 4px solid #3b82f6;
145
+ border-radius: 50%;
146
+ animation: spin 1s linear infinite;
147
+ }
148
+
149
+ @keyframes spin {
150
+ 0% { transform: rotate(0deg); }
151
+ 100% { transform: rotate(360deg); }
152
+ }
timeline.html ADDED
@@ -0,0 +1,294 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>Travel Timeline - WanderPin</title>
7
+ <link rel="icon" type="image/x-icon" href="/static/favicon.ico">
8
+ <script src="https://cdn.tailwindcss.com"></script>
9
+ <script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
10
+ <script src="https://unpkg.com/feather-icons"></script>
11
+ <link rel="stylesheet" href="style.css">
12
+ <script src="components/navbar.js"></script>
13
+ <script src="components/footer.js"></script>
14
+ <style>
15
+ .timeline-container {
16
+ position: relative;
17
+ }
18
+
19
+ .timeline-line {
20
+ position: absolute;
21
+ left: 50%;
22
+ transform: translateX(-50%);
23
+ width: 4px;
24
+ height: 100%;
25
+ background: linear-gradient(to bottom, #3b82f6, #8b5cf6);
26
+ }
27
+
28
+ @media (max-width: 768px) {
29
+ .timeline-line {
30
+ left: 30px;
31
+ }
32
+ }
33
+ </style>
34
+ </head>
35
+ <body class="bg-gradient-to-br from-gray-50 to-blue-50 min-h-screen">
36
+ <custom-navbar></custom-navbar>
37
+
38
+ <main class="container mx-auto px-4 py-8 max-w-6xl">
39
+ <!-- Header -->
40
+ <section class="text-center mb-12">
41
+ <h1 class="text-5xl font-bold text-gray-800 mb-4">Travel Timeline <i data-feather="clock" class="inline-block text-blue-500"></i></h1>
42
+ <p class="text-xl text-gray-600 max-w-3xl mx-auto">Follow my journey through time and space. Each stop tells a unique story of adventure and discovery.</p>
43
+ <div class="mt-6">
44
+ <a href="index.html" class="inline-flex items-center px-6 py-3 bg-white hover:bg-gray-50 text-gray-800 rounded-lg shadow-md transition duration-300">
45
+ <i data-feather="map" class="mr-2 w-5 h-5"></i>
46
+ Back to Map View
47
+ </a>
48
+ </div>
49
+ </section>
50
+
51
+ <!-- Timeline -->
52
+ <section class="mb-16">
53
+ <div class="bg-white rounded-2xl shadow-xl p-6 border border-gray-200">
54
+ <div class="timeline-container">
55
+ <div class="timeline-line"></div>
56
+
57
+ <!-- Timeline Items -->
58
+ <div class="space-y-12">
59
+ <!-- Bangkok -->
60
+ <div class="relative flex flex-col md:flex-row items-center">
61
+ <div class="md:w-1/2 md:pr-12 md:text-right mb-4 md:mb-0">
62
+ <div class="bg-blue-50 p-6 rounded-2xl shadow-sm border border-blue-100">
63
+ <div class="text-sm text-blue-600 font-semibold mb-2">January 2023</div>
64
+ <h3 class="text-2xl font-bold text-gray-800 mb-2">Bangkok, Thailand</h3>
65
+ <p class="text-gray-600 mb-4">Started the year exploring the vibrant streets of Bangkok. Visited Wat Arun, Grand Palace, and experienced the famous floating markets.</p>
66
+ <div class="flex flex-wrap gap-2 justify-end">
67
+ <span class="px-3 py-1 bg-blue-100 text-blue-800 rounded-full text-sm">Temples</span>
68
+ <span class="px-3 py-1 bg-blue-100 text-blue-800 rounded-full text-sm">Street Food</span>
69
+ <span class="px-3 py-1 bg-blue-100 text-blue-800 rounded-full text-sm">Markets</span>
70
+ </div>
71
+ </div>
72
+ </div>
73
+ <div class="absolute left-1/2 transform -translate-x-1/2 md:relative md:left-0 md:transform-none">
74
+ <div class="w-12 h-12 bg-blue-500 rounded-full flex items-center justify-center border-4 border-white shadow-lg">
75
+ <i data-feather="map-pin" class="w-6 h-6 text-white"></i>
76
+ </div>
77
+ </div>
78
+ <div class="md:w-1/2 md:pl-12 mt-4 md:mt-0">
79
+ <img src="http://static.photos/cityscape/640x360/201" alt="Bangkok" class="rounded-xl shadow-md w-full h-48 object-cover">
80
+ </div>
81
+ </div>
82
+
83
+ <!-- Phuket -->
84
+ <div class="relative flex flex-col md:flex-row items-center">
85
+ <div class="md:w-1/2 md:pr-12 mb-4 md:mb-0 order-2 md:order-1">
86
+ <img src="http://static.photos/nature/640x360/202" alt="Phuket" class="rounded-xl shadow-md w-full h-48 object-cover">
87
+ </div>
88
+ <div class="absolute left-1/2 transform -translate-x-1/2 md:relative md:left-0 md:transform-none order-1 md:order-2">
89
+ <div class="w-12 h-12 bg-green-500 rounded-full flex items-center justify-center border-4 border-white shadow-lg">
90
+ <i data-feather="sun" class="w-6 h-6 text-white"></i>
91
+ </div>
92
+ </div>
93
+ <div class="md:w-1/2 md:pl-12 md:text-left mt-4 md:mt-0 order-3">
94
+ <div class="bg-green-50 p-6 rounded-2xl shadow-sm border border-green-100">
95
+ <div class="text-sm text-green-600 font-semibold mb-2">March 2023</div>
96
+ <h3 class="text-2xl font-bold text-gray-800 mb-2">Phuket, Thailand</h3>
97
+ <p class="text-gray-600 mb-4">Island getaway to Phuket. Enjoyed pristine beaches, snorkeling in crystal clear waters, and breathtaking sunsets at Promthep Cape.</p>
98
+ <div class="flex flex-wrap gap-2">
99
+ <span class="px-3 py-1 bg-green-100 text-green-800 rounded-full text-sm">Beaches</span>
100
+ <span class="px-3 py-1 bg-green-100 text-green-800 rounded-full text-sm">Snorkeling</span>
101
+ <span class="px-3 py-1 bg-green-100 text-green-800 rounded-full text-sm">Sunsets</span>
102
+ </div>
103
+ </div>
104
+ </div>
105
+ </div>
106
+
107
+ <!-- Hong Kong -->
108
+ <div class="relative flex flex-col md:flex-row items-center">
109
+ <div class="md:w-1/2 md:pr-12 md:text-right mb-4 md:mb-0">
110
+ <div class="bg-red-50 p-6 rounded-2xl shadow-sm border border-red-100">
111
+ <div class="text-sm text-red-600 font-semibold mb-2">June 2023</div>
112
+ <h3 class="text-2xl font-bold text-gray-800 mb-2">Hong Kong</h3>
113
+ <p class="text-gray-600 mb-4">Urban adventure in Hong Kong. Explored Victoria Peak, enjoyed dim sum, and experienced the vibrant night markets.</p>
114
+ <div class="flex flex-wrap gap-2 justify-end">
115
+ <span class="px-3 py-1 bg-red-100 text-red-800 rounded-full text-sm">Skyline</span>
116
+ <span class="px-3 py-1 bg-red-100 text-red-800 rounded-full text-sm">Food</span>
117
+ <span class="px-3 py-1 bg-red-100 text-red-800 rounded-full text-sm">Shopping</span>
118
+ </div>
119
+ </div>
120
+ </div>
121
+ <div class="absolute left-1/2 transform -translate-x-1/2 md:relative md:left-0 md:transform-none">
122
+ <div class="w-12 h-12 bg-red-500 rounded-full flex items-center justify-center border-4 border-white shadow-lg">
123
+ <i data-feather="trending-up" class="w-6 h-6 text-white"></i>
124
+ </div>
125
+ </div>
126
+ <div class="md:w-1/2 md:pl-12 mt-4 md:mt-0">
127
+ <img src="http://static.photos/cityscape/640x360/203" alt="Hong Kong" class="rounded-xl shadow-md w-full h-48 object-cover">
128
+ </div>
129
+ </div>
130
+
131
+ <!-- China -->
132
+ <div class="relative flex flex-col md:flex-row items-center">
133
+ <div class="md:w-1/2 md:pr-12 mb-4 md:mb-0 order-2 md:order-1">
134
+ <img src="http://static.photos/travel/640x360/204" alt="China" class="rounded-xl shadow-md w-full h-48 object-cover">
135
+ </div>
136
+ <div class="absolute left-1/2 transform -translate-x-1/2 md:relative md:left-0 md:transform-none order-1 md:order-2">
137
+ <div class="w-12 h-12 bg-red-500 rounded-full flex items-center justify-center border-4 border-white shadow-lg">
138
+ <i data-feather="flag" class="w-6 h-6 text-white"></i>
139
+ </div>
140
+ </div>
141
+ <div class="md:w-1/2 md:pl-12 md:text-left mt-4 md:mt-0 order-3">
142
+ <div class="bg-red-50 p-6 rounded-2xl shadow-sm border border-red-100">
143
+ <div class="text-sm text-red-600 font-semibold mb-2">August 2023</div>
144
+ <h3 class="text-2xl font-bold text-gray-800 mb-2">Beijing, China</h3>
145
+ <p class="text-gray-600 mb-4">Historical journey through Beijing. Walked the Great Wall, explored the Forbidden City, and tasted authentic Peking duck.</p>
146
+ <div class="flex flex-wrap gap-2">
147
+ <span class="px-3 py-1 bg-red-100 text-red-800 rounded-full text-sm">History</span>
148
+ <span class="px-3 py-1 bg-red-100 text-red-800 rounded-full text-sm">Culture</span>
149
+ <span class="px-3 py-1 bg-red-100 text-red-800 rounded-full text-sm">Architecture</span>
150
+ </div>
151
+ </div>
152
+ </div>
153
+ </div>
154
+
155
+ <!-- Singapore -->
156
+ <div class="relative flex flex-col md:flex-row items-center">
157
+ <div class="md:w-1/2 md:pr-12 md:text-right mb-4 md:mb-0">
158
+ <div class="bg-blue-50 p-6 rounded-2xl shadow-sm border border-blue-100">
159
+ <div class="text-sm text-blue-600 font-semibold mb-2">October 2023</div>
160
+ <h3 class="text-2xl font-bold text-gray-800 mb-2">Singapore</h3>
161
+ <p class="text-gray-600 mb-4">Modern marvel in Singapore. Experienced Gardens by the Bay, Marina Bay Sands, and the diverse cultural neighborhoods.</p>
162
+ <div class="flex flex-wrap gap-2 justify-end">
163
+ <span class="px-3 py-1 bg-blue-100 text-blue-800 rounded-full text-sm">Gardens</span>
164
+ <span class="px-3 py-1 bg-blue-100 text-blue-800 rounded-full text-sm">Modern</span>
165
+ <span class="px-3 py-1 bg-blue-100 text-blue-800 rounded-full text-sm">Clean</span>
166
+ </div>
167
+ </div>
168
+ </div>
169
+ <div class="absolute left-1/2 transform -translate-x-1/2 md:relative md:left-0 md:transform-none">
170
+ <div class="w-12 h-12 bg-blue-500 rounded-full flex items-center justify-center border-4 border-white shadow-lg">
171
+ <i data-feather="feather" class="w-6 h-6 text-white"></i>
172
+ </div>
173
+ </div>
174
+ <div class="md:w-1/2 md:pl-12 mt-4 md:mt-0">
175
+ <img src="http://static.photos/technology/640x360/205" alt="Singapore" class="rounded-xl shadow-md w-full h-48 object-cover">
176
+ </div>
177
+ </div>
178
+
179
+ <!-- Malaysia -->
180
+ <div class="relative flex flex-col md:flex-row items-center">
181
+ <div class="md:w-1/2 md:pr-12 mb-4 md:mb-0 order-2 md:order-1">
182
+ <img src="http://static.photos/cityscape/640x360/206" alt="Malaysia" class="rounded-xl shadow-md w-full h-48 object-cover">
183
+ </div>
184
+ <div class="absolute left-1/2 transform -translate-x-1/2 md:relative md:left-0 md:transform-none order-1 md:order-2">
185
+ <div class="w-12 h-12 bg-yellow-500 rounded-full flex items-center justify-center border-4 border-white shadow-lg">
186
+ <i data-feather="home" class="w-6 h-6 text-white"></i>
187
+ </div>
188
+ </div>
189
+ <div class="md:w-1/2 md:pl-12 md:text-left mt-4 md:mt-0 order-3">
190
+ <div class="bg-yellow-50 p-6 rounded-2xl shadow-sm border border-yellow-100">
191
+ <div class="text-sm text-yellow-600 font-semibold mb-2">December 2023</div>
192
+ <h3 class="text-2xl font-bold text-gray-800 mb-2">Kuala Lumpur, Malaysia</h3>
193
+ <p class="text-gray-600 mb-4">Cultural exploration in Kuala Lumpur. Marveled at the Petronas Towers, explored Batu Caves, and enjoyed diverse Malaysian cuisine.</p>
194
+ <div class="flex flex-wrap gap-2">
195
+ <span class="px-3 py-1 bg-yellow-100 text-yellow-800 rounded-full text-sm">Towers</span>
196
+ <span class="px-3 py-1 bg-yellow-100 text-yellow-800 rounded-full text-sm">Culture</span>
197
+ <span class="px-3 py-1 bg-yellow-100 text-yellow-800 rounded-full text-sm">Food</span>
198
+ </div>
199
+ </div>
200
+ </div>
201
+ </div>
202
+
203
+ <!-- Vietnam -->
204
+ <div class="relative flex flex-col md:flex-row items-center">
205
+ <div class="md:w-1/2 md:pr-12 md:text-right mb-4 md:mb-0">
206
+ <div class="bg-green-50 p-6 rounded-2xl shadow-sm border border-green-100">
207
+ <div class="text-sm text-green-600 font-semibold mb-2">February 2024</div>
208
+ <h3 class="text-2xl font-bold text-gray-800 mb-2">Hanoi, Vietnam</h3>
209
+ <p class="text-gray-600 mb-4">Charming visit to Hanoi. Experienced the Old Quarter, tried authentic pho, and learned about Vietnamese history and culture.</p>
210
+ <div class="flex flex-wrap gap-2 justify-end">
211
+ <span class="px-3 py-1 bg-green-100 text-green-800 rounded-full text-sm">History</span>
212
+ <span class="px-3 py-1 bg-green-100 text-green-800 rounded-full text-sm">Food</span>
213
+ <span class="px-3 py-1 bg-green-100 text-green-800 rounded-full text-sm">Culture</span>
214
+ </div>
215
+ </div>
216
+ </div>
217
+ <div class="absolute left-1/2 transform -translate-x-1/2 md:relative md:left-0 md:transform-none">
218
+ <div class="w-12 h-12 bg-green-500 rounded-full flex items-center justify-center border-4 border-white shadow-lg">
219
+ <i data-feather="coffee" class="w-6 h-6 text-white"></i>
220
+ </div>
221
+ </div>
222
+ <div class="md:w-1/2 md:pl-12 mt-4 md:mt-0">
223
+ <img src="http://static.photos/travel/640x360/207" alt="Vietnam" class="rounded-xl shadow-md w-full h-48 object-cover">
224
+ </div>
225
+ </div>
226
+ </div>
227
+ </div>
228
+
229
+ <!-- Timeline End -->
230
+ <div class="text-center mt-12 pt-8 border-t border-gray-200">
231
+ <div class="inline-flex items-center justify-center w-16 h-16 bg-gradient-to-r from-blue-500 to-purple-600 rounded-full shadow-lg">
232
+ <i data-feather="compass" class="w-8 h-8 text-white"></i>
233
+ </div>
234
+ <h3 class="text-2xl font-bold text-gray-800 mt-4">The Journey Continues...</h3>
235
+ <p class="text-gray-600 mt-2 max-w-2xl mx-auto">More adventures await! Stay tuned for updates on future travels and new destinations.</p>
236
+ </div>
237
+ </div>
238
+ </section>
239
+
240
+ <!-- Stats Summary -->
241
+ <section class="mb-16">
242
+ <div class="grid grid-cols-1 md:grid-cols-3 gap-6">
243
+ <div class="bg-white p-6 rounded-2xl shadow-lg border border-gray-200 text-center">
244
+ <div class="text-4xl font-bold text-blue-600 mb-2">7</div>
245
+ <div class="text-gray-700 font-medium">Destinations</div>
246
+ <p class="text-gray-500 text-sm mt-2">Across Southeast Asia</p>
247
+ </div>
248
+ <div class="bg-white p-6 rounded-2xl shadow-lg border border-gray-200 text-center">
249
+ <div class="text-4xl font-bold text-green-600 mb-2">14</div>
250
+ <div class="text-gray-700 font-medium">Months</div>
251
+ <p class="text-gray-500 text-sm mt-2">Of travel adventures</p>
252
+ </div>
253
+ <div class="bg-white p-6 rounded-2xl shadow-lg border border-gray-200 text-center">
254
+ <div class="text-4xl font-bold text-purple-600 mb-2">∞</div>
255
+ <div class="text-gray-700 font-medium">Memories</div>
256
+ <p class="text-gray-500 text-sm mt-2">To last a lifetime</p>
257
+ </div>
258
+ </div>
259
+ </section>
260
+ </main>
261
+
262
+ <custom-footer></custom-footer>
263
+
264
+ <script src="script.js"></script>
265
+ <script>
266
+ feather.replace();
267
+
268
+ // Add animation to timeline items
269
+ document.addEventListener('DOMContentLoaded', function() {
270
+ const timelineItems = document.querySelectorAll('.relative.flex');
271
+
272
+ const observer = new IntersectionObserver((entries) => {
273
+ entries.forEach(entry => {
274
+ if (entry.isIntersecting) {
275
+ entry.target.style.opacity = '1';
276
+ entry.target.style.transform = 'translateY(0)';
277
+ }
278
+ });
279
+ }, {
280
+ threshold: 0.1,
281
+ rootMargin: '0px 0px -50px 0px'
282
+ });
283
+
284
+ timelineItems.forEach((item, index) => {
285
+ item.style.opacity = '0';
286
+ item.style.transform = 'translateY(20px)';
287
+ item.style.transition = 'opacity 0.6s ease, transform 0.6s ease';
288
+ item.style.transitionDelay = `${index * 0.1}s`;
289
+ observer.observe(item);
290
+ });
291
+ });
292
+ </script>
293
+ </body>
294
+ </html>