upload de projetos funcional + busca por bpm
Deploy / Deploy (push) Failing after 52s Details

This commit is contained in:
JotaChina 2025-12-08 11:08:12 -03:00
parent 75b2a2dbe6
commit 40975c964e
1 changed files with 43 additions and 41 deletions

View File

@ -26,52 +26,54 @@ permalink: /beats/
{% if site.data.beats %}
{% for filename in site.data.beats %}
<div class="column is-12-mobile is-6-tablet is-4-desktop is-3-widescreen">
<div class="card beat-card"
style="height: 100%; background-color: #f0f8ff; border: 1px solid #cfe8fc; border-radius: 12px; display: flex; flex-direction: column; transition: all 0.3s ease;">
<div class="column is-12-mobile is-6-tablet is-4-desktop is-3-widescreen">
<div class="card beat-card"
style="height: 100%; background-color: #f0f8ff; border: 1px solid #cfe8fc; border-radius: 12px; display: flex; flex-direction: column; transition: all 0.3s ease;">
<div class="card-content has-text-centered p-4" style="flex: 1; display: flex; flex-direction: column; justify-content: center;">
<div class="card-content has-text-centered p-4" style="flex: 1; display: flex; flex-direction: column; justify-content: center;">
<div class="mb-3" style="width: 60px; height: 60px; background: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto; box-shadow: 0 4px 10px rgba(0,0,0,0.05);">
<span class="icon is-large has-text-info"><i class="fa-solid fa-compact-disc fa-2x fa-spin-hover"></i></span>
</div>
{% assign file_name_clean = filename | remove: '.wav' | remove: '.mp3' %}
{% assign project_url = "" %}
{% for projeto in site.data.all %}
{% if projeto.file == file_name_clean %}
{% assign project_slug = projeto.file | slugify %}
{% assign project_url = "/projetos/" | append: project_slug | append: ".html" %}
{% endif %}
{% endfor %}
<h3 class="title is-6 mb-3" style="color: #205081; word-break: break-word;">
{% if project_url != "" %}
<a href="{{ project_url | relative_url }}" class="beat-link" title="Ir para o projeto">
{{ file_name_clean }} <i class="fa-solid fa-arrow-up-right-from-square" style="font-size: 0.7em; margin-left: 4px;"></i>
</a>
{% else %}
{{ file_name_clean }}
{% endif %}
</h3>
<div class="audio-wrapper" style="width: 100%;">
<audio class="audio-player" controls style="width: 100%; height: 32px; border-radius: 20px;">
<source src="/mmpSearch/src_mmpSearch/wav/{{ filename }}" type="audio/wav">
Seu navegador não suporta áudio.
</audio>
</div>
</div>
<div class="mb-3" style="width: 60px; height: 60px; background: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto; box-shadow: 0 4px 10px rgba(0,0,0,0.05);">
<span class="icon is-large has-text-info"><i class="fa-solid fa-compact-disc fa-2x fa-spin-hover"></i></span>
</div>
{% assign file_name_clean = filename | remove: '.wav' | remove: '.mp3' %}
{% assign project_url = "" %}
{% for projeto in site.data.all %}
{% assign proj_slug = projeto.file | slugify %}
{% assign beat_slug = file_name_clean | slugify %}
{% if proj_slug == beat_slug %}
{% assign project_url = "/projetos/" | append: proj_slug | append: ".html" %}
{% endif %}
{% endfor %}
<h3 class="title is-6 mb-3" style="color: #205081; word-break: break-word;">
{% if project_url != "" %}
<a href="{{ project_url | relative_url }}" class="beat-link" title="Ir para o projeto">
{{ file_name_clean }} <i class="fa-solid fa-arrow-up-right-from-square" style="font-size: 0.7em; margin-left: 4px;"></i>
</a>
{% else %}
{{ file_name_clean }}
{% endif %}
</h3>
<div class="audio-wrapper" style="width: 100%;">
<audio class="audio-player" controls style="width: 100%; height: 32px; border-radius: 20px;">
<source src="/mmpSearch/src_mmpSearch/wav/{{ filename | url_encode }}" type="audio/wav">
Seu navegador não suporta áudio.
</audio>
</div>
</div>
</div>
</div>
{% endfor %}
{% else %}
<div class="column is-12">
<div class="notification is-warning has-text-centered">
Nenhum beat encontrado no manifesto (beats.json). Tente fazer um upload novo para regenerar a lista.
Nenhum beat encontrado (beats.json vazio ou inexistente).
</div>
</div>
{% endif %}