web3district commited on
Commit
30bf8c2
Β·
verified Β·
1 Parent(s): 57f16be

ULTRA SIMPLE: Direct inline JavaScript - search and mobile menu with alerts

Browse files
Files changed (1) hide show
  1. index.html +3 -64
index.html CHANGED
@@ -274,7 +274,7 @@
274
  <path d="M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z"></path>
275
  </svg>
276
  </button>
277
- <button id="search-btn" class="p-1 rounded-full hover:bg-muted transition-colors focus:outline focus:outline-2 focus:outline-accent search-btn" title="Search Web3 District" onclick="handleSearchClick()">
278
  <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linejoin="round">
279
  <circle cx="11" cy="11" r="8"></circle>
280
  <line x1="21" y1="21" x2="16.65" y2="16.65"></line>
@@ -285,7 +285,7 @@
285
  </button>
286
 
287
  <!-- Mobile Menu Button -->
288
- <button id="mobile-menu-btn" class="lg:hidden p-1 rounded-lg hover:bg-muted transition-colors focus:outline focus:outline-2 focus:outline-accent" onclick="handleMobileMenuClick()">
289
  <svg id="menu-icon" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
290
  <line x1="3" y1="12" x2="21" y2="12"></line>
291
  <line x1="3" y1="6" x2="21" y2="6"></line>
@@ -1458,65 +1458,7 @@
1458
 
1459
  <!-- JavaScript Interactions -->
1460
  <script>
1461
- // SIMPLE BULLETPROOF FUNCTIONS - NO DOM READY NEEDED
1462
-
1463
- // Search button function
1464
- function handleSearchClick() {
1465
- console.log('πŸ” Search button clicked!');
1466
- alert('πŸ” Search button clicked!'); // TEST ALERT
1467
-
1468
- // Visual feedback
1469
- const searchBtn = document.getElementById('search-btn');
1470
- if (searchBtn) {
1471
- searchBtn.style.transform = 'scale(0.95)';
1472
- searchBtn.style.backgroundColor = 'rgba(124, 76, 228, 0.3)';
1473
-
1474
- setTimeout(() => {
1475
- searchBtn.style.transform = '';
1476
- searchBtn.style.backgroundColor = '';
1477
- }, 200);
1478
- }
1479
-
1480
- // Scroll to search section
1481
- const searchSection = document.getElementById('search');
1482
- if (searchSection) {
1483
- searchSection.scrollIntoView({
1484
- behavior: 'smooth',
1485
- block: 'start'
1486
- });
1487
-
1488
- // Focus search input
1489
- setTimeout(() => {
1490
- const searchInput = document.getElementById('main-search-input');
1491
- if (searchInput) {
1492
- searchInput.focus();
1493
- console.log('βœ… Search input focused');
1494
- }
1495
- }, 1000);
1496
- } else {
1497
- console.log('❌ Search section not found');
1498
- }
1499
- }
1500
-
1501
- // Mobile menu function
1502
- function handleMobileMenuClick() {
1503
- console.log('πŸ“± Mobile menu clicked!');
1504
-
1505
- const mobileMenu = document.getElementById('mobile-menu');
1506
- if (mobileMenu) {
1507
- if (mobileMenu.classList.contains('open')) {
1508
- mobileMenu.classList.remove('open');
1509
- console.log('πŸ“± Menu closed');
1510
- } else {
1511
- mobileMenu.classList.add('open');
1512
- console.log('πŸ“± Menu opened');
1513
- }
1514
- } else {
1515
- console.log('❌ Mobile menu not found');
1516
- }
1517
- }
1518
-
1519
- // Navigation links - add onclick handlers
1520
  document.addEventListener('DOMContentLoaded', function() {
1521
  const navLinks = document.querySelectorAll('a[href^="#"]');
1522
  navLinks.forEach(link => {
@@ -1549,7 +1491,6 @@
1549
  chip.onclick = function() {
1550
  filterChips.forEach(c => c.classList.remove('bg-accent', 'text-white'));
1551
  this.classList.add('bg-accent', 'text-white');
1552
- console.log('🎯 Filter selected:', this.dataset.type);
1553
  };
1554
  });
1555
 
@@ -1577,8 +1518,6 @@
1577
  }, 2000);
1578
 
1579
  showSlide(0);
1580
-
1581
- console.log('πŸŽ‰ All functionality initialized!');
1582
  });
1583
 
1584
  <p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=web3district/web3portal" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
 
274
  <path d="M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z"></path>
275
  </svg>
276
  </button>
277
+ <button id="search-btn" class="p-1 rounded-full hover:bg-muted transition-colors focus:outline focus:outline-2 focus:outline-accent search-btn" title="Search Web3 District" onclick="alert('SEARCH CLICKED!'); document.getElementById('search').scrollIntoView({behavior: 'smooth'});">
278
  <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linejoin="round">
279
  <circle cx="11" cy="11" r="8"></circle>
280
  <line x1="21" y1="21" x2="16.65" y2="16.65"></line>
 
285
  </button>
286
 
287
  <!-- Mobile Menu Button -->
288
+ <button id="mobile-menu-btn" class="lg:hidden p-1 rounded-lg hover:bg-muted transition-colors focus:outline focus:outline-2 focus:outline-accent" onclick="alert('MOBILE MENU CLICKED!'); document.getElementById('mobile-menu').classList.toggle('open');">
289
  <svg id="menu-icon" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
290
  <line x1="3" y1="12" x2="21" y2="12"></line>
291
  <line x1="3" y1="6" x2="21" y2="6"></line>
 
1458
 
1459
  <!-- JavaScript Interactions -->
1460
  <script>
1461
+ // SIMPLE NAVIGATION LINKS
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1462
  document.addEventListener('DOMContentLoaded', function() {
1463
  const navLinks = document.querySelectorAll('a[href^="#"]');
1464
  navLinks.forEach(link => {
 
1491
  chip.onclick = function() {
1492
  filterChips.forEach(c => c.classList.remove('bg-accent', 'text-white'));
1493
  this.classList.add('bg-accent', 'text-white');
 
1494
  };
1495
  });
1496
 
 
1518
  }, 2000);
1519
 
1520
  showSlide(0);
 
 
1521
  });
1522
 
1523
  <p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=web3district/web3portal" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>