Changes in src/views/pages/admin-videos.ejs [156baa3:daa8eb8] in Klonkt
- File:
-
- 1 edited
-
src/views/pages/admin-videos.ejs (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
src/views/pages/admin-videos.ejs
r156baa3 rdaa8eb8 1 <%# Beheer → Media → Video's (Robins opdracht, 30-7): the videos C2S uploads 2 brought in (Shaer's composer, the help buoy), with usage and cleanup. 3 Same shape as the image page; the preview is the video itself with 4 preload="metadata", so the browser shows the first frame as its 5 thumbnail until real poster generation lands (bead: ffmpeg ontbreekt). %> 6 <div class="admin-wrap" style="max-width:980px;margin:0 auto;padding:1.5rem 1rem;"> 7 <a href="/admin" class="btn" style="margin-bottom:1rem;display:inline-block;">← <%= t('nav.admin') %></a> 8 <h1 style="font-family:var(--display,serif);margin:.2rem 0 1rem;"><%= t('admin.t_media') %></h1> 1 <%# Beheer -> Media -> Video's (Robins opdracht, 30-7): de video's die via C2S 2 binnenkwamen (Shaers composer, de reddingsboei), met gebruik en opruiming. 9 3 4 De voorvertoning is de video zelf met preload="metadata", zodat de browser 5 het eerste beeld als miniatuur toont tot echte poster-generatie landt 6 (bead: ffmpeg ontbreekt). 7 8 Zelfde romp als de andere mediapagina's; stond hiervoor op inline styles. %> 9 <%- include('../partials/admin-styles') %> 10 <div class="container ax-page"> 11 12 <%- include('../partials/admin-back') %> 10 13 <%- include('../partials/media-tabs', { active: 'videos', audioOn: audioOn }) %> 14 <header class="ax-header"> 15 <div> 16 <h1><%= t('admin.t_media') %></h1> 17 <p class="ax-tagline"><%= items.length %> <%= t('admin.videos_count') %></p> 18 </div> 19 </header> 11 20 12 <% if (success) { %><p style="background:rgba(60,160,90,.15);border:1px solid rgba(60,160,90,.4);padding:.5rem .8rem;border-radius:8px;"><%= success %></p><% } %> 13 14 <p style="margin:0 0 1rem;opacity:.75;"><%= items.length %> <%= t('admin.videos_count') %></p> 21 <% if (success) { %><div class="ax-flash ax-flash-ok"><%= success %></div><% } %> 15 22 16 23 <% if (!items.length) { %> 17 <p style="opacity:.7;"><%= t('admin.videos_empty') %></p> 24 <div class="ax-empty"> 25 <div class="ax-empty-icon">🎬</div> 26 <p><%= t('admin.videos_empty') %></p> 27 </div> 18 28 <% } else { %> 19 <div style="display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:1rem;">29 <div class="ax-grid" style="--ax-tile:220px;"> 20 30 <% items.forEach(function(it){ %> 21 <div class=" media-card" data-file="<%= it.file %>" style="border:1px solid var(--rule,rgba(128,128,128,.25));border-radius:10px;overflow:hidden;background:var(--paper-2,rgba(128,128,128,.06));">22 <div style="position:relative;aspect-ratio:16/10;background:#000;">23 <video src="<%= it.url %>" preload="metadata" controls playsinline style=" width:100%;height:100%;object-fit:contain;display:block;"></video>24 <% if (!it.usedCount) { %><span style="position:absolute;top:6px;left:6px;background:#b4452e;color:#fff;border-radius:6px;padding:1px 6px;font-size:11px;z-index:1;"><%= t('admin.media_unused') %></span><% } %>31 <div class="ax-tile media-card" data-file="<%= it.file %>"> 32 <div class="ax-tile-media" style="aspect-ratio:16/10;background:#000;"> 33 <video src="<%= it.url %>" preload="metadata" controls playsinline style="height:100%;object-fit:contain;"></video> 34 <% if (!it.usedCount) { %><span class="ax-tile-badge"><%= t('admin.media_unused') %></span><% } %> 25 35 </div> 26 <div style="padding:.5rem .6rem;font-size:13px;">27 <div style="opacity:.7;word-break:break-all;"><%= it.file %></div>28 <div style="opacity:.7;"><%= it.kb %> KB · <%= it.usedCount %>×</div>29 <div style="display:flex;gap:.4rem;margin-top:.45rem;">30 <button type="button" class=" btn" style="padding:3px 8px;font-size:12px;" data-copy="<%= it.url %>"><%= t('admin.media_copy') %></button>36 <div class="ax-tile-body"> 37 <div class="ax-tile-meta" style="word-break:break-all;"><%= it.file %></div> 38 <div class="ax-tile-meta"><%= it.kb %> KB · <%= it.usedCount %>×</div> 39 <div class="ax-tile-actions"> 40 <button type="button" class="ax-btn ax-btn-sm" data-copy="<%= it.url %>"><%= t('admin.media_copy') %></button> 31 41 <% if (!it.usedCount) { %> 32 <button type="button" class=" btn" style="padding:3px 8px;font-size:12px;background:transparent;border-color:#b4452e;color:#b4452e;" data-del="<%= it.file %>">🗑</button>42 <button type="button" class="ax-btn ax-btn-sm ax-btn-danger" data-del="<%= it.file %>">🗑</button> 33 43 <% } %> 34 44 </div>
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)