feat: add project logo support and rename to Personal Projects
Changes: - Created /static/images/projects/ folder for project logos - Added ProjectLogo field to Project struct - Updated cv-en.json and cv-es.json with projectLogo fields: - somosunaola.png for Somos Una Ola - herrumbre-vivo.png for Herrumbre Vivo Arte - Updated template to display project logos with fallback to web icon - Added CSS styling for project logo images (80×80px) - Renamed section from "Projects" to "Personal Projects" Logo images will display when PNG files are added to /static/images/projects/
This commit is contained in:
@@ -706,6 +706,7 @@
|
|||||||
{
|
{
|
||||||
"title": "Somos Una Ola - Beach Cleaning Initiative",
|
"title": "Somos Una Ola - Beach Cleaning Initiative",
|
||||||
"url": "https://somosunaola.org",
|
"url": "https://somosunaola.org",
|
||||||
|
"projectLogo": "somosunaola.png",
|
||||||
"location": "La Palma, Canary Islands",
|
"location": "La Palma, Canary Islands",
|
||||||
"startDate": "2023-07",
|
"startDate": "2023-07",
|
||||||
"current": true,
|
"current": true,
|
||||||
@@ -720,6 +721,7 @@
|
|||||||
{
|
{
|
||||||
"title": "Herrumbre Vivo Arte - Artist Portfolio Website",
|
"title": "Herrumbre Vivo Arte - Artist Portfolio Website",
|
||||||
"url": "https://herrumbrevivoarte.com",
|
"url": "https://herrumbrevivoarte.com",
|
||||||
|
"projectLogo": "herrumbre-vivo.png",
|
||||||
"location": "Fuencaliente, La Palma",
|
"location": "Fuencaliente, La Palma",
|
||||||
"startDate": "2024",
|
"startDate": "2024",
|
||||||
"current": true,
|
"current": true,
|
||||||
|
|||||||
@@ -738,6 +738,7 @@
|
|||||||
{
|
{
|
||||||
"title": "Somos Una Ola - Iniciativa de Limpieza de Playas",
|
"title": "Somos Una Ola - Iniciativa de Limpieza de Playas",
|
||||||
"url": "https://somosunaola.org",
|
"url": "https://somosunaola.org",
|
||||||
|
"projectLogo": "somosunaola.png",
|
||||||
"location": "La Palma, Islas Canarias",
|
"location": "La Palma, Islas Canarias",
|
||||||
"startDate": "2023-07",
|
"startDate": "2023-07",
|
||||||
"current": true,
|
"current": true,
|
||||||
@@ -752,6 +753,7 @@
|
|||||||
{
|
{
|
||||||
"title": "Herrumbre Vivo Arte - Sitio Web Portfolio de Artista",
|
"title": "Herrumbre Vivo Arte - Sitio Web Portfolio de Artista",
|
||||||
"url": "https://herrumbrevivoarte.com",
|
"url": "https://herrumbrevivoarte.com",
|
||||||
|
"projectLogo": "herrumbre-vivo.png",
|
||||||
"location": "Fuencaliente, La Palma",
|
"location": "Fuencaliente, La Palma",
|
||||||
"startDate": "2024",
|
"startDate": "2024",
|
||||||
"current": true,
|
"current": true,
|
||||||
|
|||||||
@@ -101,6 +101,7 @@ type Language struct {
|
|||||||
type Project struct {
|
type Project struct {
|
||||||
Title string `json:"title"`
|
Title string `json:"title"`
|
||||||
URL string `json:"url"`
|
URL string `json:"url"`
|
||||||
|
ProjectLogo string `json:"projectLogo,omitempty"` // Optional logo filename
|
||||||
Location string `json:"location"`
|
Location string `json:"location"`
|
||||||
StartDate string `json:"startDate"`
|
StartDate string `json:"startDate"`
|
||||||
Current bool `json:"current"`
|
Current bool `json:"current"`
|
||||||
|
|||||||
@@ -954,6 +954,16 @@ iconify-icon {
|
|||||||
justify-content: center;
|
justify-content: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.project-icon img {
|
||||||
|
width: 80px;
|
||||||
|
height: 80px;
|
||||||
|
object-fit: contain;
|
||||||
|
border-radius: 4px;
|
||||||
|
border: 1px solid #ddd;
|
||||||
|
background: #f5f5f5;
|
||||||
|
padding: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
.default-project-icon {
|
.default-project-icon {
|
||||||
width: 80px;
|
width: 80px;
|
||||||
height: 80px;
|
height: 80px;
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 8.2 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 8.2 KiB After Width: | Height: | Size: 17 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 24 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 24 KiB After Width: | Height: | Size: 36 KiB |
@@ -206,13 +206,19 @@
|
|||||||
<section id="projects" class="cv-section">
|
<section id="projects" class="cv-section">
|
||||||
<h3 class="section-title">
|
<h3 class="section-title">
|
||||||
<iconify-icon icon="mdi:web" width="24" height="24" class="section-icon"></iconify-icon>
|
<iconify-icon icon="mdi:web" width="24" height="24" class="section-icon"></iconify-icon>
|
||||||
{{if eq .Lang "es"}}Proyectos{{else}}Projects{{end}}
|
{{if eq .Lang "es"}}Proyectos Personales{{else}}Personal Projects{{end}}
|
||||||
</h3>
|
</h3>
|
||||||
{{range .CV.Projects}}
|
{{range .CV.Projects}}
|
||||||
<div class="project-item">
|
<div class="project-item">
|
||||||
|
{{if .ProjectLogo}}
|
||||||
|
<div class="project-icon">
|
||||||
|
<img src="/static/images/projects/{{.ProjectLogo}}" alt="{{.Title}} logo" onerror="this.parentElement.innerHTML='<iconify-icon icon=\'mdi:web\' width=\'80\' height=\'80\' class=\'default-project-icon\'></iconify-icon>'">
|
||||||
|
</div>
|
||||||
|
{{else}}
|
||||||
<div class="project-icon">
|
<div class="project-icon">
|
||||||
<iconify-icon icon="mdi:web" width="80" height="80" class="default-project-icon"></iconify-icon>
|
<iconify-icon icon="mdi:web" width="80" height="80" class="default-project-icon"></iconify-icon>
|
||||||
</div>
|
</div>
|
||||||
|
{{end}}
|
||||||
<div class="project-content">
|
<div class="project-content">
|
||||||
<div class="project-header">
|
<div class="project-header">
|
||||||
<h4 class="project-title">
|
<h4 class="project-title">
|
||||||
|
|||||||
Reference in New Issue
Block a user