summaryrefslogtreecommitdiff
path: root/src/components/widgets/Contact.astro
diff options
context:
space:
mode:
authorDawid Rycerz <dawid@rycerz.xyz>2025-07-22 15:08:37 +0300
committerDawid Rycerz <dawid@rycerz.xyz>2025-07-22 15:08:37 +0300
commitfcc2f4704e39b0e69b377cc138f75027721dac22 (patch)
tree732fc94b354a26c08fba9cc9059f9c6c900182be /src/components/widgets/Contact.astro
Initial template
Diffstat (limited to 'src/components/widgets/Contact.astro')
-rw-r--r--src/components/widgets/Contact.astro40
1 files changed, 40 insertions, 0 deletions
diff --git a/src/components/widgets/Contact.astro b/src/components/widgets/Contact.astro
new file mode 100644
index 0000000..122f4b0
--- /dev/null
+++ b/src/components/widgets/Contact.astro
@@ -0,0 +1,40 @@
+---
+import FormContainer from '~/components/ui/Form.astro';
+import Headline from '~/components/ui/Headline.astro';
+import WidgetWrapper from '~/components/ui/WidgetWrapper.astro';
+import type { Contact as Props } from '~/types';
+
+const {
+ title = await Astro.slots.render('title'),
+ subtitle = await Astro.slots.render('subtitle'),
+ tagline = await Astro.slots.render('tagline'),
+ inputs,
+ textarea,
+ disclaimer,
+ button,
+ description,
+
+ id,
+ isDark = false,
+ classes = {},
+ bg = await Astro.slots.render('bg'),
+} = Astro.props;
+---
+
+<WidgetWrapper id={id} isDark={isDark} containerClass={`max-w-7xl mx-auto ${classes?.container ?? ''}`} bg={bg}>
+ <Headline title={title} subtitle={subtitle} tagline={tagline} />
+
+ {
+ inputs && (
+ <div class="flex flex-col max-w-xl mx-auto rounded-lg backdrop-blur border border-gray-200 dark:border-gray-700 bg-white dark:bg-slate-900 shadow p-4 sm:p-6 lg:p-8 w-full">
+ <FormContainer
+ inputs={inputs}
+ textarea={textarea}
+ disclaimer={disclaimer}
+ button={button}
+ description={description}
+ />
+ </div>
+ )
+ }
+</WidgetWrapper>