rahul7star commited on
Commit
4d868fb
·
verified ·
1 Parent(s): 1a480ba

remove Ready to create your AI Clone? when user click on pricing take them to choose your plan area. Also when user is signed in focus the page to upload image area . after signed in show signout option and when user click then take use back to orignal UI without image upload section - Follow Up Deployment

Browse files
Files changed (1) hide show
  1. index.html +34 -15
index.html CHANGED
@@ -80,9 +80,12 @@
80
  <i class="fab fa-google text-red-500 mr-2"></i>
81
  Sign In with Google
82
  </button>
83
- <div id="user-profile" class="hidden flex items-center">
84
- <img id="user-avatar" class="w-10 h-10 rounded-full mr-3" src="" alt="User Avatar">
85
  <span id="user-name" class="font-medium text-gray-700"></span>
 
 
 
86
  </div>
87
  </div>
88
  </header>
@@ -373,18 +376,10 @@
373
  </section>
374
  </main>
375
 
376
- <!-- Footer with Pricing Info -->
377
  <footer class="mt-12 bg-white py-8 border-t border-gray-200">
378
- <div class="container mx-auto px-4">
379
- <h3 class="text-xl font-bold text-center mb-4">Ready to create your AI Clone?</h3>
380
- <div class="flex justify-center">
381
- <a href="#pricing" class="bg-indigo-600 text-white px-6 py-3 rounded-lg font-medium hover:bg-indigo-700 transition">
382
- View Pricing Plans
383
- </a>
384
- </div>
385
- <div class="mt-8 text-center text-gray-600">
386
- <p>Choose the plan that works best for you</p>
387
- </div>
388
  </div>
389
  </footer>
390
 
@@ -403,6 +398,9 @@
403
  name: "John Doe",
404
  avatar: "https://randomuser.me/api/portraits/men/1.jpg"
405
  };
 
 
 
406
 
407
  // Mock generated avatars
408
  const mockAvatars = [
@@ -452,6 +450,7 @@
452
 
453
  // Event Listeners
454
  signInBtn.addEventListener('click', handleSignIn);
 
455
  imageUpload.addEventListener('click', () => imageInput.click());
456
  zipUpload.addEventListener('click', () => zipInput.click());
457
  imageInput.addEventListener('change', handleImageUpload);
@@ -472,8 +471,28 @@
472
  userName.textContent = mockUser.name;
473
  userAvatar.src = mockUser.avatar;
474
 
475
- // Show upload section after sign in
476
- document.getElementById('create').classList.remove('hidden');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
477
  }
478
 
479
  function handleImageUpload(e) {
 
80
  <i class="fab fa-google text-red-500 mr-2"></i>
81
  Sign In with Google
82
  </button>
83
+ <div id="user-profile" class="hidden flex items-center space-x-4">
84
+ <img id="user-avatar" class="w-10 h-10 rounded-full" src="" alt="User Avatar">
85
  <span id="user-name" class="font-medium text-gray-700"></span>
86
+ <button id="sign-out-btn" class="text-gray-500 hover:text-gray-700">
87
+ <i class="fas fa-sign-out-alt"></i>
88
+ </button>
89
  </div>
90
  </div>
91
  </header>
 
376
  </section>
377
  </main>
378
 
379
+ <!-- Footer -->
380
  <footer class="mt-12 bg-white py-8 border-t border-gray-200">
381
+ <div class="container mx-auto px-4 text-center text-gray-600">
382
+ <p>© 2023 AI Clone. All rights reserved.</p>
 
 
 
 
 
 
 
 
383
  </div>
384
  </footer>
385
 
 
398
  name: "John Doe",
399
  avatar: "https://randomuser.me/api/portraits/men/1.jpg"
400
  };
401
+
402
+ // DOM Elements
403
+ const signOutBtn = document.getElementById('sign-out-btn');
404
 
405
  // Mock generated avatars
406
  const mockAvatars = [
 
450
 
451
  // Event Listeners
452
  signInBtn.addEventListener('click', handleSignIn);
453
+ signOutBtn.addEventListener('click', handleSignOut);
454
  imageUpload.addEventListener('click', () => imageInput.click());
455
  zipUpload.addEventListener('click', () => zipInput.click());
456
  imageInput.addEventListener('change', handleImageUpload);
 
471
  userName.textContent = mockUser.name;
472
  userAvatar.src = mockUser.avatar;
473
 
474
+ // Show upload section after sign in and scroll to it
475
+ const uploadSection = document.getElementById('create');
476
+ uploadSection.classList.remove('hidden');
477
+ window.scrollTo({
478
+ top: uploadSection.offsetTop - 80,
479
+ behavior: 'smooth'
480
+ });
481
+ }
482
+
483
+ function handleSignOut() {
484
+ signInBtn.classList.remove('hidden');
485
+ userProfile.classList.add('hidden');
486
+
487
+ // Hide upload section and clear any uploaded images
488
+ document.getElementById('create').classList.add('hidden');
489
+ clearImages();
490
+
491
+ // Scroll back to top
492
+ window.scrollTo({
493
+ top: 0,
494
+ behavior: 'smooth'
495
+ });
496
  }
497
 
498
  function handleImageUpload(e) {