Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| d0d38fa3fd | |||
| 241ab68141 | |||
| 54dc618653 | |||
| ba89493c27 |
@@ -13,6 +13,22 @@ import FooterMedia from '@/components/sections/footer/FooterMedia';
|
|||||||
import { Clock, DollarSign, Shield, Star, Zap, Wrench } from 'lucide-react';
|
import { Clock, DollarSign, Shield, Star, Zap, Wrench } from 'lucide-react';
|
||||||
|
|
||||||
export default function LandingPage() {
|
export default function LandingPage() {
|
||||||
|
const handleHeroButtonClick = (href: string) => {
|
||||||
|
if (href.startsWith('tel:')) {
|
||||||
|
window.location.href = href;
|
||||||
|
} else if (href.startsWith('#')) {
|
||||||
|
const element = document.getElementById(href.substring(1));
|
||||||
|
if (element) {
|
||||||
|
element.scrollIntoView({ behavior: 'smooth' });
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
const handleContactSubmit = (data: Record<string, string>) => {
|
||||||
|
console.log('Form submitted:', data);
|
||||||
|
// Handle form submission logic here
|
||||||
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<ThemeProvider
|
<ThemeProvider
|
||||||
defaultButtonVariant="bounce-effect"
|
defaultButtonVariant="bounce-effect"
|
||||||
@@ -56,8 +72,8 @@ export default function LandingPage() {
|
|||||||
rating={5}
|
rating={5}
|
||||||
ratingText="4.6 stars from 105 reviews"
|
ratingText="4.6 stars from 105 reviews"
|
||||||
buttons={[
|
buttons={[
|
||||||
{ text: "Call Now: 064 143 7036", href: "tel:0641437036" },
|
{ text: "Call Now: 064 143 7036", href: "tel:0641437036", onClick: () => handleHeroButtonClick("tel:0641437036") },
|
||||||
{ text: "Schedule Service", href: "#contact" }
|
{ text: "Schedule Service", href: "#contact", onClick: () => handleHeroButtonClick("#contact") }
|
||||||
]}
|
]}
|
||||||
mediaAnimation="slide-up"
|
mediaAnimation="slide-up"
|
||||||
buttonAnimation="slide-up"
|
buttonAnimation="slide-up"
|
||||||
@@ -93,7 +109,12 @@ export default function LandingPage() {
|
|||||||
mediaAnimation="slide-up"
|
mediaAnimation="slide-up"
|
||||||
buttonAnimation="slide-up"
|
buttonAnimation="slide-up"
|
||||||
tagAnimation="slide-up"
|
tagAnimation="slide-up"
|
||||||
buttons={[{ text: "Get Help Today", href: "tel:0641437036" }]}
|
buttons={[
|
||||||
|
{
|
||||||
|
text: "Get Help Today",
|
||||||
|
href: "tel:0641437036", onClick: () => handleHeroButtonClick("tel:0641437036")
|
||||||
|
}
|
||||||
|
]}
|
||||||
imagePosition="right"
|
imagePosition="right"
|
||||||
ariaLabel="About R & R Electrical section"
|
ariaLabel="About R & R Electrical section"
|
||||||
/>
|
/>
|
||||||
@@ -247,6 +268,7 @@ export default function LandingPage() {
|
|||||||
mediaAnimation="slide-up"
|
mediaAnimation="slide-up"
|
||||||
mediaPosition="right"
|
mediaPosition="right"
|
||||||
buttonText="Request Service"
|
buttonText="Request Service"
|
||||||
|
onSubmit={handleContactSubmit}
|
||||||
ariaLabel="Contact form - R & R Electrical"
|
ariaLabel="Contact form - R & R Electrical"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user