The Contact section (Documentation Index
Fetch the complete documentation index at: https://mintlify.com/lgomegarc/mi-portfolio/llms.txt
Use this file to discover all available pages before exploring further.
ContactSection.svelte) provides two ways to reach Leila: a direct contact info panel on the left, and a live EmailJS-powered contact form on the right. Messages are sent directly from the browser — no backend server required.
Contact Info Panel
The left panel displays three contact details and embeds the<SocialLinks /> component for GitHub, LinkedIn, and CV download links.
EmailJS Configuration
The component uses three EmailJS credentials to authenticate and route outgoing messages:serviceID— identifies the connected email service (e.g., Gmail, Outlook) configured in your EmailJS dashboardtemplateID— specifies which EmailJS template to populate with the submitted form datapublicKey— the public API key that authorises client-side sends from your EmailJS account
Form Fields
The contact form exposes three required fields:| Field | Input Type | Name Attribute | Required |
|---|---|---|---|
| Full name | text | name | Yes |
| Email address | email | email | Yes |
| Message | textarea (4 rows) | message | Yes |
name attribute, which EmailJS uses to match values to template variables (e.g., {{name}}, {{email}}, {{message}}).
Form Submission Flow
Form submitted
The user submits the form. The
handleSubmit(event) handler fires, calls event.preventDefault() to suppress the native browser submit, and sets isSubmitting = true — disabling the submit button and showing “Enviando…” text.EmailJS send called
emailjs.send(serviceID, templateID, { name, email, message }, publicKey) is called with the three form field values extracted from event.target.Success path
On a successful send, the Svelte writable store
statusMessage is set to '✅ ¡Mensaje enviado correctamente!' and form.reset() clears all fields.Error path
If the send throws, the
catch block sets statusMessage to '❌ Error al enviar el mensaje. Intenta de nuevo.' and logs the error to the console.handleSubmit Function
Setting Up EmailJS for a Fork
Create an EmailJS account
Sign up for a free account at https://www.emailjs.com.
Create an Email Service
In the EmailJS dashboard, go to Email Services and connect a provider (e.g., Gmail). Note the Service ID assigned.
Create an Email Template
Go to Email Templates and create a new template. Use the variables
{{name}}, {{email}}, and {{message}} in the template body. Note the Template ID.Find your Public Key
Navigate to Account → API Keys in the EmailJS dashboard and copy your Public Key.
EmailJS free tier allows up to 200 emails/month. The contact form works entirely client-side — no server or API routes are needed.