{% extends 'base.html.twig' %} {% block title %}Landing Social Proof - Design System - Bubul{% endblock %} {% block body %}
{% include '_atoms/icon/icon.html.twig' with { name: 'chevron-left', size: 'sm', color: 'gray' } %}
Organisme /

Landing Social Proof

Barre de stats avec chiffres en gradient

{# ===== EXPLICATION ===== #}
{% include '_atoms/icon/icon.html.twig' with { name: 'chart', size: 'lg', color: 'white' } %}

Social Proof — Barre de Statistiques

Public

Barre horizontale affichant 4 statistiques cles avec des valeurs en gradient de couleur. Chaque stat est separee par une ligne verticale (rendue via CSS ::after). Entierement parametrable via le tableau stats.

4

Stats defaut

CSS

Separateurs

gradient

Valeurs

reveal

Animation

{# ===== DEMO VISUELLE ===== #}

Demo

Apercu des valeurs par defaut

{% include '_organisms/landing/social-proof.html.twig' only %}
{# ===== UTILISATION ===== #}

Utilisation

Exemple de code Twig

{% verbatim %}{# Defaut (4 stats Bubul) #}
{% include '_organisms/landing/social-proof.html.twig' only %}

{# Personnalise #}
{% include '_organisms/landing/social-proof.html.twig' with {
    stats: [
        {
            value: '14',
            label: 'Voix disponibles',
            sublabel: 'francaises',
            gradient: 'linear-gradient(135deg, #7C3AED, #A78BFA)'
        },
        {
            value: '99%',
            label: 'Satisfaction',
            sublabel: 'utilisateurs',
            gradient: 'linear-gradient(135deg, var(--color-success-dark), var(--color-success))'
        }
    ]
} only %}{% endverbatim %}
{# ===== PARAMETRES ===== #}

Parametres

Options de configuration

Parametre Type Defaut Description
stats array (4 stats Bubul) Tableau de stats. Chaque stat: { value, label, sublabel, gradient }
class string '' Classes CSS additionnelles sur la section

Structure d'une stat (stats[])

Cle Type Description
value string Valeur affichee en grand (ex: '80+', '20min')
label string Label principal sous la valeur
sublabel string Label secondaire (plus petit)
gradient string CSS gradient pour la valeur (ex: 'linear-gradient(135deg, ...)')
{# ===== NOTES TECHNIQUES ===== #}

Notes Techniques

Implementation

1

Separateurs CSS ::after

Les lignes verticales entre les stats sont generees via section .grid > div:not(:last-child)::after dans une balise <style> incluse dans le composant.

2

Grille dynamique

La grille utilise grid-cols-{{ "{{" }} stats|length {{ "}}" }} pour s'adapter automatiquement au nombre de stats.

3

Gradient via style inline

Les valeurs colorees utilisent -webkit-background-clip: text avec le gradient passe en style inline.

{% endblock %}