instagram cta changes, mail fixes
This commit is contained in:
+3
-1
@@ -7,7 +7,9 @@ POSTGRES_PASSWORD=gw_Pg_7Jm9!Qx4#Ld2@Vr8
|
|||||||
POSTGRES_PASSWORD_URLENCODED=gw_Pg_7Jm9%21Qx4%23Ld2%40Vr8
|
POSTGRES_PASSWORD_URLENCODED=gw_Pg_7Jm9%21Qx4%23Ld2%40Vr8
|
||||||
|
|
||||||
RESEND_API_KEY=re_hcDByLp8_HEBW93wDirr7o9g16FgCeYNF
|
RESEND_API_KEY=re_hcDByLp8_HEBW93wDirr7o9g16FgCeYNF
|
||||||
OWNER_EMAIL=mattcohen0@gmail.com
|
OWNER_EMAIL=info@goodwalk.co.nz
|
||||||
|
OWNER_BCC=mattcohen0@gmail.com
|
||||||
|
CLIENT_BCC=mattcohen0@gmail.com
|
||||||
FROM_EMAIL=GoodWalk <info@goodwalk.co.nz>
|
FROM_EMAIL=GoodWalk <info@goodwalk.co.nz>
|
||||||
REPLY_TO=info@goodwalk.co.nz
|
REPLY_TO=info@goodwalk.co.nz
|
||||||
ENABLE_GENERAL_ENQUIRIES=false
|
ENABLE_GENERAL_ENQUIRIES=false
|
||||||
|
|||||||
@@ -31,6 +31,8 @@ services:
|
|||||||
APP_VERSION: ${APP_VERSION:-4.0.2}
|
APP_VERSION: ${APP_VERSION:-4.0.2}
|
||||||
RESEND_API_KEY: ${RESEND_API_KEY}
|
RESEND_API_KEY: ${RESEND_API_KEY}
|
||||||
OWNER_EMAIL: ${OWNER_EMAIL}
|
OWNER_EMAIL: ${OWNER_EMAIL}
|
||||||
|
OWNER_BCC: ${OWNER_BCC:-}
|
||||||
|
CLIENT_BCC: ${CLIENT_BCC:-}
|
||||||
FROM_EMAIL: ${FROM_EMAIL:-GoodWalk <bookings@goodwalk.co.nz>}
|
FROM_EMAIL: ${FROM_EMAIL:-GoodWalk <bookings@goodwalk.co.nz>}
|
||||||
REPLY_TO: ${REPLY_TO:-aless@goodwalk.co.nz}
|
REPLY_TO: ${REPLY_TO:-aless@goodwalk.co.nz}
|
||||||
ENABLE_GENERAL_ENQUIRIES: ${ENABLE_GENERAL_ENQUIRIES:-false}
|
ENABLE_GENERAL_ENQUIRIES: ${ENABLE_GENERAL_ENQUIRIES:-false}
|
||||||
|
|||||||
+4
-2
@@ -24,8 +24,10 @@ services:
|
|||||||
APP_VERSION: ${APP_VERSION:-4.0.2}
|
APP_VERSION: ${APP_VERSION:-4.0.2}
|
||||||
RESEND_API_KEY: ${RESEND_API_KEY}
|
RESEND_API_KEY: ${RESEND_API_KEY}
|
||||||
OWNER_EMAIL: ${OWNER_EMAIL}
|
OWNER_EMAIL: ${OWNER_EMAIL}
|
||||||
FROM_EMAIL: ${FROM_EMAIL:-GoodWalk <bookings@goodwalk.co.nz>}
|
OWNER_BCC: ${OWNER_BCC:-}
|
||||||
REPLY_TO: ${REPLY_TO:-aless@goodwalk.co.nz}
|
CLIENT_BCC: ${CLIENT_BCC:-}
|
||||||
|
FROM_EMAIL: ${FROM_EMAIL:-GoodWalk <info@goodwalk.co.nz>}
|
||||||
|
REPLY_TO: ${REPLY_TO:-info@goodwalk.co.nz}
|
||||||
ENABLE_GENERAL_ENQUIRIES: ${ENABLE_GENERAL_ENQUIRIES:-false}
|
ENABLE_GENERAL_ENQUIRIES: ${ENABLE_GENERAL_ENQUIRIES:-false}
|
||||||
TZ: ${TZ:-Pacific/Auckland}
|
TZ: ${TZ:-Pacific/Auckland}
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
|||||||
+23
-9
@@ -89,6 +89,8 @@ def _load_config() -> dict:
|
|||||||
"owner_email": os.environ["OWNER_EMAIL"],
|
"owner_email": os.environ["OWNER_EMAIL"],
|
||||||
"from_email": os.environ.get("FROM_EMAIL", "GoodWalk <bookings@goodwalk.co.nz>"),
|
"from_email": os.environ.get("FROM_EMAIL", "GoodWalk <bookings@goodwalk.co.nz>"),
|
||||||
"reply_to": os.environ.get("REPLY_TO", "aless@goodwalk.co.nz"),
|
"reply_to": os.environ.get("REPLY_TO", "aless@goodwalk.co.nz"),
|
||||||
|
"owner_bcc": os.environ.get("OWNER_BCC", "example@example.com").strip(),
|
||||||
|
"client_bcc": os.environ.get("CLIENT_BCC", "").strip(),
|
||||||
"enable_general_enquiries": os.environ.get("ENABLE_GENERAL_ENQUIRIES", "false").strip().lower() in {"1", "true", "yes", "on", "enabled"},
|
"enable_general_enquiries": os.environ.get("ENABLE_GENERAL_ENQUIRIES", "false").strip().lower() in {"1", "true", "yes", "on", "enabled"},
|
||||||
"max_attempts": max(1, int(os.environ.get("MAIL_MAX_ATTEMPTS", "3"))),
|
"max_attempts": max(1, int(os.environ.get("MAIL_MAX_ATTEMPTS", "3"))),
|
||||||
"form_min_seconds": max(1, int(os.environ.get("FORM_MIN_SECONDS", "4"))),
|
"form_min_seconds": max(1, int(os.environ.get("FORM_MIN_SECONDS", "4"))),
|
||||||
@@ -104,6 +106,8 @@ _config = _load_config()
|
|||||||
APP_VERSION = os.environ.get("APP_VERSION", "unknown")
|
APP_VERSION = os.environ.get("APP_VERSION", "unknown")
|
||||||
resend.api_key = _config["resend_api_key"]
|
resend.api_key = _config["resend_api_key"]
|
||||||
OWNER_EMAIL = _config["owner_email"]
|
OWNER_EMAIL = _config["owner_email"]
|
||||||
|
OWNER_BCC = _config["owner_bcc"]
|
||||||
|
CLIENT_BCC = _config["client_bcc"]
|
||||||
FROM_EMAIL = _config["from_email"]
|
FROM_EMAIL = _config["from_email"]
|
||||||
REPLY_TO = _config["reply_to"]
|
REPLY_TO = _config["reply_to"]
|
||||||
ENABLE_GENERAL_ENQUIRIES = _config["enable_general_enquiries"]
|
ENABLE_GENERAL_ENQUIRIES = _config["enable_general_enquiries"]
|
||||||
@@ -118,12 +122,14 @@ RATE_LIMIT_MIN_INTERVAL_SECONDS = _config["rate_limit_min_interval_seconds"]
|
|||||||
LOGO_URL = "https://www.goodwalk.co.nz/images/goodwalk-auckland-dog-walking-logo.png"
|
LOGO_URL = "https://www.goodwalk.co.nz/images/goodwalk-auckland-dog-walking-logo.png"
|
||||||
|
|
||||||
logger.info(
|
logger.info(
|
||||||
"Mail API config: version=%r timezone=%r from=%r reply_to=%r owner=%r general_enquiries=%r max_attempts=%d form_min=%ss form_max=%ss rate_window=%ss per_ip=%d per_email=%d min_interval=%ss",
|
"Mail API config: version=%r timezone=%r from=%r reply_to=%r owner=%r owner_bcc=%r client_bcc=%r general_enquiries=%r max_attempts=%d form_min=%ss form_max=%ss rate_window=%ss per_ip=%d per_email=%d min_interval=%ss",
|
||||||
APP_VERSION,
|
APP_VERSION,
|
||||||
os.environ.get("TZ", "system-default"),
|
os.environ.get("TZ", "system-default"),
|
||||||
FROM_EMAIL,
|
FROM_EMAIL,
|
||||||
REPLY_TO,
|
REPLY_TO,
|
||||||
OWNER_EMAIL,
|
OWNER_EMAIL,
|
||||||
|
OWNER_BCC,
|
||||||
|
CLIENT_BCC,
|
||||||
ENABLE_GENERAL_ENQUIRIES,
|
ENABLE_GENERAL_ENQUIRIES,
|
||||||
MAX_SEND_ATTEMPTS,
|
MAX_SEND_ATTEMPTS,
|
||||||
FORM_MIN_SECONDS,
|
FORM_MIN_SECONDS,
|
||||||
@@ -891,15 +897,19 @@ async def submit_booking(data: BookingSubmission, request: Request):
|
|||||||
|
|
||||||
failures: list[dict] = []
|
failures: list[dict] = []
|
||||||
|
|
||||||
try:
|
client_payload = {
|
||||||
await _send_email(
|
|
||||||
{
|
|
||||||
"from": FROM_EMAIL,
|
"from": FROM_EMAIL,
|
||||||
"to": [data.email],
|
"to": [data.email],
|
||||||
"reply_to": REPLY_TO,
|
"reply_to": REPLY_TO,
|
||||||
"subject": f"We received your {'general enquiry' if _is_general_enquiry(data) else 'enquiry'}, {first_name}! 🐾",
|
"subject": f"We received your {'general enquiry' if _is_general_enquiry(data) else 'enquiry'}, {first_name}! 🐾",
|
||||||
"html": client_email(data),
|
"html": client_email(data),
|
||||||
},
|
}
|
||||||
|
if CLIENT_BCC:
|
||||||
|
client_payload["bcc"] = [CLIENT_BCC]
|
||||||
|
|
||||||
|
try:
|
||||||
|
await _send_email(
|
||||||
|
client_payload,
|
||||||
label="client_email",
|
label="client_email",
|
||||||
request_id=request_id,
|
request_id=request_id,
|
||||||
)
|
)
|
||||||
@@ -911,9 +921,7 @@ async def submit_booking(data: BookingSubmission, request: Request):
|
|||||||
"status": getattr(exc, "status_code", None) or getattr(exc, "code", None),
|
"status": getattr(exc, "status_code", None) or getattr(exc, "code", None),
|
||||||
})
|
})
|
||||||
|
|
||||||
try:
|
owner_payload = {
|
||||||
await _send_email(
|
|
||||||
{
|
|
||||||
"from": FROM_EMAIL,
|
"from": FROM_EMAIL,
|
||||||
"to": [OWNER_EMAIL],
|
"to": [OWNER_EMAIL],
|
||||||
"reply_to": data.email,
|
"reply_to": data.email,
|
||||||
@@ -923,7 +931,13 @@ async def submit_booking(data: BookingSubmission, request: Request):
|
|||||||
else f"New GoodWalk lead — {data.fullName} ({data.petName})"
|
else f"New GoodWalk lead — {data.fullName} ({data.petName})"
|
||||||
),
|
),
|
||||||
"html": owner_email(data, ip, browser),
|
"html": owner_email(data, ip, browser),
|
||||||
},
|
}
|
||||||
|
if OWNER_BCC:
|
||||||
|
owner_payload["bcc"] = [OWNER_BCC]
|
||||||
|
|
||||||
|
try:
|
||||||
|
await _send_email(
|
||||||
|
owner_payload,
|
||||||
label="owner_email",
|
label="owner_email",
|
||||||
request_id=request_id,
|
request_id=request_id,
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
export let instagram: HomePageContent['instagram'];
|
export let instagram: HomePageContent['instagram'];
|
||||||
|
|
||||||
const dogCutoutSrc = '/images/smiling-dog-cutout.webp';
|
const dogCutoutSrc = '/images/smiling-dogs-instagram-cta.png';
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<section id="instagram">
|
<section id="instagram">
|
||||||
@@ -30,7 +30,7 @@
|
|||||||
<style>
|
<style>
|
||||||
#instagram {
|
#instagram {
|
||||||
overflow: visible;
|
overflow: visible;
|
||||||
padding-bottom: 102px;
|
padding-bottom: 40px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.instagram-stage {
|
.instagram-stage {
|
||||||
@@ -40,8 +40,10 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.instagram-panel {
|
.instagram-panel {
|
||||||
padding: 42px 44px 112px;
|
position: relative;
|
||||||
border-radius: 32px;
|
min-height: 150px;
|
||||||
|
padding: 24px 320px 24px 44px;
|
||||||
|
border-radius: 24px;
|
||||||
background:
|
background:
|
||||||
radial-gradient(circle at top left, rgba(255, 255, 255, 0.52), transparent 42%),
|
radial-gradient(circle at top left, rgba(255, 255, 255, 0.52), transparent 42%),
|
||||||
linear-gradient(135deg, rgba(255, 252, 242, 0.98), rgba(255, 243, 198, 0.96));
|
linear-gradient(135deg, rgba(255, 252, 242, 0.98), rgba(255, 243, 198, 0.96));
|
||||||
@@ -52,75 +54,62 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.instagram-copy {
|
.instagram-copy {
|
||||||
padding-top: 10px;
|
max-width: 580px;
|
||||||
max-width: 620px;
|
margin: 0;
|
||||||
margin: 0 auto;
|
text-align: left;
|
||||||
text-align: center;
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: flex-start;
|
||||||
}
|
}
|
||||||
|
|
||||||
.instagram-kicker {
|
.instagram-kicker {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
margin-bottom: 16px;
|
margin-bottom: 10px;
|
||||||
padding: 8px 14px;
|
padding: 6px 12px;
|
||||||
border-radius: 999px;
|
border-radius: 999px;
|
||||||
background: rgba(33, 48, 33, 0.08);
|
background: rgba(33, 48, 33, 0.08);
|
||||||
color: var(--green);
|
color: var(--green);
|
||||||
font-size: 12px;
|
font-size: 11px;
|
||||||
font-weight: 700;
|
font-weight: 700;
|
||||||
letter-spacing: 0.08em;
|
letter-spacing: 0.08em;
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
}
|
}
|
||||||
|
|
||||||
.instagram-copy :global(h2) {
|
.instagram-copy :global(h2) {
|
||||||
max-width: 12ch;
|
max-width: none;
|
||||||
margin-left: auto;
|
margin: 0 0 6px;
|
||||||
margin-right: auto;
|
font-size: 22px;
|
||||||
|
line-height: 1.2;
|
||||||
}
|
}
|
||||||
|
|
||||||
.instagram-blurb {
|
.instagram-blurb {
|
||||||
max-width: 520px;
|
max-width: 520px;
|
||||||
margin-bottom: 0;
|
margin: 0;
|
||||||
margin-left: auto;
|
font-size: 14px;
|
||||||
margin-right: auto;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.instagram-button {
|
.instagram-button {
|
||||||
margin-top: 28px;
|
margin-top: 14px;
|
||||||
|
position: relative;
|
||||||
|
z-index: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.instagram-dog-wrap {
|
.instagram-dog-wrap {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: 50%;
|
right: 24px;
|
||||||
bottom: -74px;
|
bottom: 0;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: flex-end;
|
align-items: flex-end;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
width: clamp(300px, 36vw, 430px);
|
width: 280px;
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
transform: translateX(-50%);
|
z-index: 0;
|
||||||
z-index: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
.instagram-dog-wrap::before {
|
|
||||||
content: '';
|
|
||||||
position: absolute;
|
|
||||||
left: 50%;
|
|
||||||
bottom: 54px;
|
|
||||||
width: 92%;
|
|
||||||
height: 56%;
|
|
||||||
border-radius: 999px 999px 40px 40px;
|
|
||||||
background:
|
|
||||||
radial-gradient(circle at 50% 35%, rgba(255, 244, 194, 0.95), rgba(255, 224, 122, 0.88));
|
|
||||||
transform: translateX(-50%);
|
|
||||||
filter: blur(2px);
|
|
||||||
z-index: -1;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.instagram-dog {
|
.instagram-dog {
|
||||||
display: block;
|
display: block;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: auto;
|
height: auto;
|
||||||
filter: drop-shadow(0 20px 28px rgba(33, 48, 33, 0.16));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (min-width: 1800px) {
|
@media (min-width: 1800px) {
|
||||||
@@ -131,24 +120,31 @@
|
|||||||
|
|
||||||
@media (max-width: 768px) {
|
@media (max-width: 768px) {
|
||||||
#instagram {
|
#instagram {
|
||||||
padding-bottom: 76px;
|
padding-bottom: 120px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.instagram-panel {
|
.instagram-panel {
|
||||||
padding: 30px 24px 120px;
|
padding: 30px 24px 180px;
|
||||||
border-radius: 28px;
|
border-radius: 28px;
|
||||||
|
min-height: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.instagram-copy {
|
.instagram-copy {
|
||||||
max-width: none;
|
max-width: none;
|
||||||
|
margin: 0 auto;
|
||||||
|
text-align: center;
|
||||||
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.instagram-copy :global(h2) {
|
.instagram-copy :global(h2) {
|
||||||
max-width: none;
|
max-width: none;
|
||||||
|
font-size: inherit;
|
||||||
|
line-height: inherit;
|
||||||
}
|
}
|
||||||
|
|
||||||
.instagram-blurb {
|
.instagram-blurb {
|
||||||
max-width: none;
|
max-width: none;
|
||||||
|
font-size: inherit;
|
||||||
margin-left: auto;
|
margin-left: auto;
|
||||||
margin-right: auto;
|
margin-right: auto;
|
||||||
}
|
}
|
||||||
@@ -160,17 +156,11 @@
|
|||||||
.instagram-dog-wrap {
|
.instagram-dog-wrap {
|
||||||
left: 50%;
|
left: 50%;
|
||||||
right: auto;
|
right: auto;
|
||||||
bottom: -10px;
|
bottom: -80px;
|
||||||
width: min(260px, calc(100% - 40px));
|
width: min(260px, calc(100% - 40px));
|
||||||
transform: translateX(-50%);
|
transform: translateX(-50%);
|
||||||
}
|
}
|
||||||
|
|
||||||
.instagram-dog-wrap::before {
|
|
||||||
width: 86%;
|
|
||||||
height: 52%;
|
|
||||||
bottom: 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.instagram-dog {
|
.instagram-dog {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 313 KiB |
Reference in New Issue
Block a user