feat: add highlight in project page and short description

This commit is contained in:
Matthieu Bessat 2022-08-25 17:53:57 +02:00
parent 041d96da58
commit e174b8efa9
4 changed files with 18 additions and 5 deletions

View file

@ -59,6 +59,7 @@ projects:
solution: Solutions solution: Solutions
technologies: Technologies used technologies: Technologies used
images: Gallery images: Gallery
highlights: Highlights
links: links:
name: Links name: Links

View file

@ -59,6 +59,7 @@ projects:
solution: Solutions solution: Solutions
technologies: Technologies utilisées technologies: Technologies utilisées
images: Gallerie images: Gallerie
highlights: Points forts
links: links:
name: Liens name: Liens

View file

@ -91,6 +91,10 @@
} }
} }
} }
.project-highlights {
list-style: square;
padding-left: 2em;
}
} }

View file

@ -10,6 +10,9 @@
<h1>{{ getLocalizedStr('projects.project') }} {{ getDynLocalizedStr(project.name) }}</h1> <h1>{{ getLocalizedStr('projects.project') }} {{ getDynLocalizedStr(project.name) }}</h1>
<div class="project-header"> <div class="project-header">
<div class="project-description">
{{ getDynLocalizedStr(project.description) | formatMd | raw }}
</div>
<div class="project-date"> <div class="project-date">
<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-calendar-event" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-calendar-event" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round">
<path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path>
@ -94,11 +97,6 @@
</div> </div>
{% endif %} {% endif %}
{% if project.description is defined and (projects.background is not defined or projects.solution is not defined) %}
<h2>{{ getLocalizedStr('description') }}</h2>
{{ getDynLocalizedStr(project.description) | formatMd | raw }}
{% endif %}
{% if project.background is defined %} {% if project.background is defined %}
<h2>{{ getLocalizedStr('projects.background') }}</h2> <h2>{{ getLocalizedStr('projects.background') }}</h2>
{{ getDynLocalizedStr(project.background) | formatMd | raw }} {{ getDynLocalizedStr(project.background) | formatMd | raw }}
@ -109,6 +107,15 @@
{{ getDynLocalizedStr(project.solution) | formatMd | raw }} {{ getDynLocalizedStr(project.solution) | formatMd | raw }}
{% endif %} {% endif %}
{% if project.highlights is defined %}
<h2>{{ getLocalizedStr('projects.highlights') }}</h2>
<ul class="project-highlights">
{% for highlight in project.highlights[getLocale()] %}
<li>{{ highlight }}</li>
{% endfor %}
</ul>
{% endif %}
<h2>{{ getLocalizedStr('projects.technologies') }}</h2> <h2>{{ getLocalizedStr('projects.technologies') }}</h2>
<div class="chips"> <div class="chips">
{% for tech in project.technologies %} {% for tech in project.technologies %}