www_zola_template/templates/shortcodes/feature_card.html
2025-03-18 16:37:12 +02:00

23 lines
836 B
HTML

{% set title = title | default(value="Feature") %}
{% set description = description | default(value="") %}
{% set icon = icon | default(value="") %}
{% set bg_color = bg_color | default(value="bg-white") %}
{% set hover_color = hover_color | default(value="hover:bg-gray-50") %}
<div class="relative {{ bg_color }} {{ hover_color }} shadow rounded-lg p-6 transition-all duration-300">
{% if icon %}
<div class="flex items-center justify-center h-12 w-12 rounded-md bg-indigo-500 text-white mb-4">
<span class="text-xl">{{ icon | safe }}</span>
</div>
{% endif %}
<h3 class="text-lg font-medium text-gray-900">{{ title }}</h3>
{% if description %}
<p class="mt-2 text-base text-gray-500">{{ description }}</p>
{% endif %}
{% if caller %}
<div class="mt-4">
{{ caller() }}
</div>
{% endif %}
</div>