Skip to content

Commit

Permalink
Merge pull request #1453 from sanchitc05/patch-1
Browse files Browse the repository at this point in the history
Implemented Dynamic Hover Effects to newsletter section
  • Loading branch information
ANSHIKA-26 authored Oct 26, 2024
2 parents a9365b5 + fb510e5 commit 608c18b
Showing 1 changed file with 28 additions and 10 deletions.
38 changes: 28 additions & 10 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1235,20 +1235,38 @@ <h2>Word of the Day</h2>

<!-- Newsletter Section -->
<section id="wordwise-newsletter" class="wordwise-newsletter-section">
<div class="wordwise-newsletter-container">
<h2>Subscribe to Our Newsletter</h2>
<p>Stay updated with the latest articles and insights from WordWise.</p>
<form class="wordwise-newsletter-form" id="newsletterForm" novalidate>
<input type="email" id="emailInput" placeholder="Enter your email address" required>
<div id="error-message" style="color: red; display: none;">Please include '@' in your email address.</div>
<div id="sub"><button type="submit">Subscribe</button></div>
<div class="wordwise-newsletter-container">
<h2>Subscribe to Our Newsletter</h2>
<p>Stay updated with the latest articles and insights from WordWise.</p>
<form class="wordwise-newsletter-form" id="newsletterForm" novalidate>
<input type="email" id="emailInput" placeholder="Enter your email address" required
style="border: 1px solid pink; transition: transform 0.2s ease, box-shadow 0.2s ease;"
onmouseover="this.style.transform='scale(1.05)'; this.style.boxShadow='0 0 8px 2px pink';"
onmouseout="this.style.transform='scale(1)'; this.style.boxShadow='none';">
<div id="error-message" style="color: red; display: none;">Please include '@' in your email address.</div>
<div id="sub"><button type="submit">Subscribe</button></div>
</form>
</div>
</div>

<!-- Toast Popup -->
<div id="toast" class="toast hidden"></div>
<!-- Toast Popup -->
<div id="toast" class="toast hidden"></div>
</section>

<style>
/* Style the email input field */
#emailInput {
border: 1px solid pink;
transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

/* Hover effect for glow */
#emailInput:hover {
transform: scale(1.05);
box-shadow: 0 0 8px 2px pink;
}
</style>


<!-- Include the Newsletter.js script file -->
<script src="./backend/newsLetter.js"></script>
</main>
Expand Down

1 comment on commit 608c18b

@vercel
Copy link

@vercel vercel bot commented on 608c18b Oct 26, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.