Files
mmpSearch/pages/projetos.md
T
2025-12-16 17:22:43 -03:00

15 KiB
Executable File

layout, title, permalink
layout title permalink
default MMPSearch - Projetos /projetos/

<div class="tabs is-centered is-boxed is-medium mb-6">
  {% include sidebar.html %}
</div>

<div class="has-text-centered mb-6">
  <h1 class="title is-3 has-text-grey-dark">📁 Projetos Disponíveis</h1>
  <p class="subtitle is-6 has-text-grey">
    Explore, ouça e reutilize projetos da comunidade LMMS.
  </p>
  <div style="width: 60px; height: 4px; background-color: #3273dc; margin: 1rem auto; border-radius: 2px;"></div>
</div>

<div class="columns is-multiline">
  {% assign project_pages = site.pages | where_exp: "page", "page.path contains 'projetos/'" | sort: "title" %}
  {% for page in project_pages %}
    {% if page.url != '/projetos/' %}
      <div class="column is-12-mobile is-6-tablet is-4-desktop is-3-widescreen">

        <div class="card project-card"
             style="height: 100%; background-color: #f0f8ff; border: 1px solid #cfe8fc; border-radius: 12px; display: flex; flex-direction: column; position: relative;">

          <a href="{{ page.url | relative_url }}" style="text-decoration: none; flex: 1; display: flex; flex-direction: column;">
              <div class="card-content has-text-centered p-4" style="flex: 1; display: flex; flex-direction: column;">

                <div style="width: 50px; height: 50px; background-color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 0.5rem auto; box-shadow: 0 2px 5px rgba(0,0,0,0.05);">
                  <span class="icon" style="color: #3273dc;">
                     <i class="fa-solid fa-music fa-lg"></i>
                  </span>
                </div>

                <p class="title is-6 mb-2" style="color: #205081; word-break: break-word; font-weight: 700; line-height: 1.2;">
                  {{ page.title | default: page.name | replace: '.html', '' }}
                </p>

                {% if page.bpm %}
                  <div class="mb-3">
                      <span class="tag is-dark is-rounded is-light" style="font-size: 0.7rem; font-weight: bold; border: 1px solid #ccc;">
                          🎵 {{ page.bpm }} BPM
                      </span>
                  </div>
                {% else %}
                  <div class="mb-3" style="height: 24px;"></div>
                {% endif %}

                <div style="flex: 1;"></div>

                <div class="mt-auto pt-2" style="width: 100%; border-top: 1px dashed #eef6fc;">

                    {% assign inst_tags = page.tags.instruments | default: page.tags.instrument %}
                    {% if inst_tags and inst_tags.size > 0 %}
                        <details class="category-reveal mb-1" style="width: 100%;">
                            <summary class="tag is-white summary-btn">
                                <div class="tag-label">
                                    <span>🎸</span> <span class="tag-text">INSTRUMENTS</span>
                                </div>
                                <span class="icon is-small chevron"><i class="fa-solid fa-chevron-down"></i></span>
                            </summary>
                            <div class="tags is-centered mt-1 mb-2 px-1" style="gap: 3px;">
                                {% for tag in inst_tags %}
                                    {% if tag != "" %}
                                        <a href="{{ '/instruments/?instrument=' | append: tag | relative_url }}" class="tag is-light is-info clickable-tag">{{ tag | truncate: 18 }}</a>
                                    {% endif %}
                                {% endfor %}
                            </div>
                        </details>
                    {% endif %}

                    {% if page.tags.plugin and page.tags.plugin.size > 0 %}
                        <details class="category-reveal mb-1" style="width: 100%;">
                            <summary class="tag is-white summary-btn">
                                <div class="tag-label">
                                    <span>🔌</span> <span class="tag-text">PLUGINS</span>
                                </div>
                                <span class="icon is-small chevron"><i class="fa-solid fa-chevron-down"></i></span>
                            </summary>
                            <div class="tags is-centered mt-1 mb-2 px-1" style="gap: 3px;">
                                {% for tag in page.tags.plugin %}
                                    {% if tag != "" %}
                                        <a href="{{ '/plugin/?plugin=' | append: tag | relative_url }}" class="tag is-light is-info clickable-tag">{{ tag | truncate: 18 }}</a>
                                    {% endif %}
                                {% endfor %}
                            </div>
                        </details>
                    {% endif %}

                    {% if page.tags.bassline and page.tags.bassline.size > 0 %}
                        <details class="category-reveal mb-1" style="width: 100%;">
                            <summary class="tag is-white summary-btn">
                                <div class="tag-label">
                                    <span>🎹</span> <span class="tag-text">BASSLINE</span>
                                </div>
                                <span class="icon is-small chevron"><i class="fa-solid fa-chevron-down"></i></span>
                            </summary>
                            <div class="tags is-centered mt-1 mb-2 px-1" style="gap: 3px;">
                                {% for tag in page.tags.bassline %}
                                    {% if tag != "" %}
                                        <a href="{{ '/bassline/?bassline=' | append: tag | relative_url }}" class="tag is-light is-info clickable-tag">{{ tag | truncate: 18 }}</a>
                                    {% endif %}
                                {% endfor %}
                            </div>
                        </details>
                    {% endif %}

                    {% if page.tags.automation and page.tags.automation.size > 0 %}
                        <details class="category-reveal mb-1" style="width: 100%;">
                            <summary class="tag is-white summary-btn">
                                <div class="tag-label">
                                    <span>🎚️</span> <span class="tag-text">AUTOMATION</span>
                                </div>
                                <span class="icon is-small chevron"><i class="fa-solid fa-chevron-down"></i></span>
                            </summary>
                            <div class="tags is-centered mt-1 mb-2 px-1" style="gap: 3px;">
                                {% for tag in page.tags.automation %}
                                    {% if tag != "" %}
                                        <a href="{{ '/automation/?automation=' | append: tag | relative_url }}" class="tag is-light is-info clickable-tag">{{ tag | truncate: 18 }}</a>
                                    {% endif %}
                                {% endfor %}
                            </div>
                        </details>
                    {% endif %}

                    {% if page.tags.sample and page.tags.sample.size > 0 %}
                        <details class="category-reveal mb-1" style="width: 100%;">
                            <summary class="tag is-white summary-btn">
                                <div class="tag-label">
                                    <span>🎤</span> <span class="tag-text">SAMPLES</span>
                                </div>
                                <span class="icon is-small chevron"><i class="fa-solid fa-chevron-down"></i></span>
                            </summary>
                            <div class="tags is-centered mt-1 mb-2 px-1" style="gap: 3px;">
                                {% for tag in page.tags.sample %}
                                    {% if tag != "" %}
                                        <a href="{{ '/sample/?sample=' | append: tag | relative_url }}" class="tag is-light is-info clickable-tag">{{ tag | truncate: 18 }}</a>
                                    {% endif %}
                                {% endfor %}
                            </div>
                        </details>
                    {% endif %}

                </div>
              </div>
          </a>

          <footer class="card-footer" style="border-top: 1px solid #cfe8fc; background-color: #fff; border-radius: 0 0 12px 12px; overflow: hidden;">
            <a href="#" class="card-footer-item js-open-modal"
               data-target-url="{{ page.url | relative_url }}"
               data-modal-title="Detalhes: {{ page.file }}"
               data-full-btn-text="Ir para Página"
               data-full-btn-link="{{ page.url | relative_url }}"
               style="color: #5b7da3; font-size: 0.8rem; font-weight: 600; border-right: 1px solid #eee; transition: background 0.2s;">
               Ver
            </a>

            {% assign creation_url = '/mmpSearch/creation.html?project=' | append: page.file %}
            {% assign embed_url = creation_url | append: '&embed=true' %}

            <a href="#" class="card-footer-item js-open-modal"
               data-target-url="{{ embed_url }}"
               data-modal-title="Editor: {{ page.file }}"
               data-full-btn-text="Abrir Editor"
               data-full-btn-link="{{ creation_url }}"
               style="color: #3273dc; font-size: 0.8rem; font-weight: 600; transition: background 0.2s;">
               Editar
            </a>
          </footer>

        </div>
      </div>
    {% endif %}
  {% endfor %}
</div>

<br><br>

Preview

Fechar Abrir
<style> /* Estilos do Card */ .project-card:hover { transform: translateY(-5px); box-shadow: 0 8px 20px rgba(50, 115, 220, 0.15); border-color: #3273dc !important; background-color: #fff !important; } .project-card:hover .title { color: #3273dc !important; } /* Estilos do Accordion de Tags */ .category-reveal summary { list-style: none; transition: all 0.2s ease; } .category-reveal summary::-webkit-details-marker { display: none; } .summary-btn { width: 100%; justify-content: space-between; cursor: pointer; border: 1px solid #deeaf6; color: #5b7da3; padding: 2px 8px; min-height: 22px; margin-bottom: 2px; display: flex !important; } .tag-label { display: flex; align-items: center; gap: 6px; } .tag-text { font-weight: 700; font-size: 0.6rem; text-transform: uppercase; letter-spacing: 0.5px; } .chevron { font-size: 0.6rem; opacity: 0.7; transition: transform 0.2s ease; } .category-reveal summary:hover { background-color: #f8fbff; border-color: #3273dc; } .category-reveal[open] summary { background-color: #eef6fc !important; border-color: #3273dc !important; color: #3273dc !important; } .category-reveal[open] summary .chevron { transform: rotate(180deg); } /* Estilos das Tags Clicáveis */ .clickable-tag { font-size: 0.6rem; height: 1.5em; border: 1px solid #cfe8fc; text-decoration: none; padding: 0 6px; transition: all 0.2s ease; } .clickable-tag:hover { background-color: #3273dc !important; color: #fff !important; border-color: #3273dc !important; transform: translateY(-1px); } </style> <script> document.addEventListener('DOMContentLoaded', () => { const modal = document.getElementById('preview-modal'); const iframe = document.getElementById('preview-iframe'); const modalTitle = document.getElementById('modal-title'); const fullEditBtn = document.getElementById('full-edit-btn'); const closeButtons = document.querySelectorAll('.modal-background, .modal-card-head .delete, #close-modal-btn'); function openModal(url, title, btnText, btnLink) { if(!modal) return; modalTitle.textContent = title; iframe.src = url; fullEditBtn.textContent = btnText; fullEditBtn.href = btnLink; modal.classList.add('is-active'); document.documentElement.classList.add('is-clipped'); } function closeModal() { if(!modal) return; modal.classList.remove('is-active'); document.documentElement.classList.remove('is-clipped'); iframe.src = ""; } document.querySelectorAll('.js-open-modal').forEach(btn => { btn.addEventListener('click', (e) => { e.preventDefault(); const url = btn.dataset.targetUrl; const title = btn.dataset.modalTitle; const btnText = btn.dataset.fullBtnText; const btnLink = btn.dataset.fullBtnLink; openModal(url, title, btnText, btnLink); }); }); iframe.addEventListener('load', () => { try { const iframeDoc = iframe.contentDocument || iframe.contentWindow.document; const style = iframeDoc.createElement('style'); style.textContent = ` .tabs, .navbar, .sidebar-wrapper, .main-header { display: none !important; } .publication { padding-top: 0 !important; } body { background-color: #fff !important; } `; iframeDoc.head.appendChild(style); } catch(e) { } }); closeButtons.forEach(el => el.addEventListener('click', closeModal)); document.addEventListener('keydown', (e) => { if (e.key === "Escape") closeModal(); }); }); </script>