Skip to content

Commit 3aadd4f

Browse files
committed
Add community page
1 parent cae406e commit 3aadd4f

File tree

2 files changed

+105
-0
lines changed

2 files changed

+105
-0
lines changed

src/assets/communities.json

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
[
2+
{
3+
"name": "Kernel Chaos",
4+
"description": "Kernel Chaos es un espacio hacker comunitario dedicado a fomentar la colaboración y el aprendizaje entre entusiastas de Linux y FOSS.",
5+
"links": {"website": "https://kernelchaos.org", "social": "https://instagram.com/kernelchaosec"},
6+
"tags": [
7+
"FOSS",
8+
"Open Source",
9+
"Programming"
10+
],
11+
"image": "https://images.unsplash.com/photo-1561070791-2526d30994b5?auto=format&fit=crop&q=80&w=300"
12+
},
13+
{
14+
"name": "Wordpress Guayaquil",
15+
"description": "Reuniones orientadas a hacer que WordPress sea abierto y accesible para quien esté interesadx en usarlo, desarrollarlo o hacer negocios con él.",
16+
"links": {"website": "https://www.meetup.com/wordpress-guayaquil-meetup", "social": "https://instagram.com/wpguayaquil"},
17+
"tags": [
18+
"Design",
19+
"UI",
20+
"UX",
21+
"Creative"
22+
],
23+
"image": "https://images.unsplash.com/photo-1561070791-2526d30994b5?auto=format&fit=crop&q=80&w=300"
24+
},
25+
{
26+
"name": "HerUX",
27+
"description": "Primera comunidad de Mujeres Profesionales apasionadas por la Experiencia del Usuario de #guayaquil.",
28+
"links": {"website": "https://ec.linkedin.com/company/her-ux", "social": "https://www.instagram.com/her.uxec"},
29+
"tags": [
30+
"UX",
31+
"UI",
32+
"Creative"
33+
],
34+
"image": "https://images.unsplash.com/photo-1561070791-2526d30994b5?auto=format&fit=crop&q=80&w=300"
35+
}
36+
]
37+

src/pages/communities.astro

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
---
2+
import Layout from '../layouts/Layout.astro';
3+
import communities from '../assets/communities.json'
4+
5+
---
6+
7+
<Layout title="Comunidades - Ecuador In Tech">
8+
<div class="container mx-auto px-4 py-12">
9+
<h1 class="text-4xl font-bold mb-8">Comunidades</h1>
10+
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
11+
{
12+
communities.map((community) => (
13+
<div class="bg-white rounded-xl shadow-lg overflow-hidden hover:shadow-xl transition-shadow duration-300">
14+
<div class="h-48 overflow-hidden">
15+
<img
16+
src={community.image}
17+
alt={community.name}
18+
class="w-full h-full object-cover transform hover:scale-105 transition-transform duration-300"
19+
/>
20+
</div>
21+
<div class="p-6">
22+
<div class="flex justify-between items-center mb-3">
23+
<h2 class="text-xl font-bold text-gray-800">
24+
{community.name}
25+
</h2>
26+
</div>
27+
<p class="text-gray-600 mb-4 line-clamp-2">
28+
{community.description}
29+
</p>
30+
<div class="mb-4 flex flex-wrap gap-2">
31+
{community.tags.map((tag) => (
32+
<span class="bg-gray-100 text-gray-700 px-3 py-1 rounded-full text-sm font-medium hover:bg-gray-200 transition-colors">
33+
{tag}
34+
</span>
35+
))}
36+
</div>
37+
<div class="pt-4 border-t border-gray-100">
38+
<div class="flex gap-3">
39+
{Object.entries(community.links).map(([key, value]) => {
40+
// const hostname = new URL(link).hostname;
41+
// const icon = hostname.includes("instagram")
42+
// ? "💬"
43+
// : hostname.includes("github")
44+
// ? "📚"
45+
// : hostname.includes("linkedin")
46+
// ? "🎨"
47+
// : "🔗";
48+
return (
49+
<a
50+
href={value}
51+
class="inline-flex items-center gap-1 text-blue-600 hover:text-blue-800 transition-colors text-sm"
52+
target="_blank"
53+
rel="noopener noreferrer"
54+
>
55+
<span>{key}</span>
56+
{/* {hostname.split(".")[0]} */}
57+
</a>
58+
);
59+
})}
60+
</div>
61+
</div>
62+
</div>
63+
</div>
64+
))
65+
}
66+
</div>
67+
</div>
68+
</Layout>

0 commit comments

Comments
 (0)