{%
set classes = [
'paragraph',
'media',
'clearfix',
'paragraph--type--' ~ paragraph.bundle|clean_class,
view_mode ? 'paragraph--view-mode--' ~ view_mode|clean_class,
not paragraph.isPublished() ? 'paragraph--unpublished'
]
%}
{% block paragraph %}
    <div{{ attributes.addClass(classes) }}>
        {% block content %}
            <div class="text {% if paragraph.field_image_position.value == 'left' %}{{ 'right' }}{% else %}{{ 'left' }}{% endif %}">
                <div class="title">{{ content.field_title }}</div>
                {{ content.field_content }}
            </div>
            <div class="image {% if paragraph.field_image_position.value == 'left' %}{{ 'left' }}{% else %}{{ 'right' }}{% endif %}">
                {{ content.field_image }}
            </div>
        {% endblock %}
    </div>
{% endblock paragraph %}

