{% if not tags is defined %}
    {% set tags = getProjectTags(app.request) %}
{% endif %}
<div class="content-section projects">
    {% set projectItems = getProjects({'projectsPage': true, 'query': app.request.get('s'), 'tags': app.request.get('tags')}, app.request) %}
    {% if projectItems|length == 0 %}
        <span class="project-not-found not-found">{{"project_not_found"|trans|capitalize}}</span>
    {% else %}
        {% for project in projectItems %}
            {% set projectLang = getLang(project.getProjectLangs(), app.request) %}

            <div class="project-item" onclick="window.open('{{ 'https://'~project.link }}', '_blank').focus()">
                <div class="project-item-top">
                    <h2>{{ projectLang.title|replace({'®': '<div class="registered">®</div>'})|raw }}</h2>
                    <div class="border-button big-button"><div class="arrow-right arrow-dark"></div></div>
                </div>
                <div class="project-item-content">
                    <div class="project-logo"><img src="{{ asset('img/projects/'~project.iconImage) }}" class="brand-logo"></div>
                    {% if project.tagIdentifierArray and project.tagIdentifierArray|length > 0 %}
                        <div class="project-tags tag-container">
                                {% for tag in project.tagIdentifierArray %}
                                    <div class="tag blog-tag">{{ tags[(tag)] }}</div>
                                {% endfor %}
                        </div>
                    {% endif %}
                    {% if project.link %}
                        <a class="black-button project-link standart-button arrow-anim">{{ project.link }}</a>                                
                    {% endif %}
                </div>
            </div>
        {% endfor %}
    {% endif %}
</div>