|
| 1 | +{% assign item = project | default: page %} |
| 2 | + |
1 | 3 | <div class="projects-card mx-4 lg:mx-8 grid grid-cols-1 md:grid-cols-3 gap-4 mb-8 lg:mb-16 items-center"> |
2 | 4 | <!-- Tag & Title (Always First) --> |
3 | 5 | <div class="md:col-span-3"> |
4 | | - {% if include.category-name %} |
| 6 | + {% if item.tag %} |
5 | 7 | <div class="flex items-center"> |
6 | 8 | <svg width="64" height="2" viewBox="0 0 64 2" fill="none" xmlns="http://www.w3.org/2000/svg"> |
7 | 9 | <path d="M64 1H0" stroke="#6B7280" /> |
8 | 10 | </svg> |
9 | 11 | <p class="text-base leading-none text-gray-500 ml-2"> |
10 | | - {{ include.category-name }} |
| 12 | + {{ item.tag }} |
11 | 13 | </p> |
12 | 14 | </div> |
13 | 15 | {% endif %} |
14 | 16 |
|
15 | 17 | <div class="text-gray-900 font-bold text-xl font-ibmsans"> |
16 | | - {{ include.title }} |
| 18 | + {{ item.title }} |
17 | 19 | </div> |
18 | 20 | </div> |
19 | 21 |
|
20 | 22 | <!-- Image Section (Appears between title and text in mobile, right side in desktop) --> |
21 | 23 | <div class="w-full order-2 md:col-span-1 md:order-3"> |
| 24 | + |
22 | 25 | <img |
23 | | - src="/assets/images/projects/{{ include.image}}" |
| 26 | + src="/assets/images/projects/{{ item.image}}" |
24 | 27 | class="w-full h-10 sm:h-15 md:h-auto object-cover rounded-lg" |
25 | | - alt="{{include.image-alt}}" |
| 28 | + alt="{{ item.image_alt }}" |
26 | 29 | /> |
27 | 30 | </div> |
28 | 31 |
|
29 | 32 | <!-- Text Section (Takes 2/3 space on desktop, below image in mobile) --> |
30 | 33 |
|
31 | 34 | <div class="md:col-span-2 md:pr-6 order-3 md:order-2"> |
| 35 | + |
32 | 36 | {% capture first_paragraph %} |
33 | | - {{ project.content | markdownify | split: '</p>' | first | remove: '<p>' | rstrip }} |
| 37 | + {{ item.content | markdownify | split: '</p>' | first | remove: '<p>' | rstrip }} |
34 | 38 | {% endcapture %} |
35 | 39 |
|
36 | | - <p class="p-5 pt-3 text-base leading-6 mb-3 font-ibmserif bg-gray-100"> |
| 40 | + <div class="prose p-5 pt-3 text-base leading-6 mb-3 font-ibmserif bg-gray-100 prose"> |
37 | 41 | {{ first_paragraph }} |
38 | | - <a href="{{ project.url }}" class="text-sky-600 hover:underline text-xs |
| 42 | + <a href="{{ item.url }}" class="text-sky-600 hover:underline text-xs |
39 | 43 | font-ibmsans"> |
40 | 44 | [read more] |
41 | 45 | </a> |
42 | | - </p> |
| 46 | + </div> |
43 | 47 | </div> |
44 | 48 | </div> |
0 commit comments