feat(folders): allow videos in top-level folders too
1단계 폴더에도 영상을 직접 추가할 수 있게 한다 (하위 폴더와 혼합 가능). 플레이리스트 추가는 기존대로 2단계 폴더 한정. - op.ts: editor/upload/youtube start 의 parentId===null 차단 제거 (playlist probe/start/new 차단은 유지) - op/folder.ejs: 1단계에서 "하위 폴더 추가"+"영상 추가" 동시 노출, 서브폴더 그리드와 영상 그리드를 함께 표시 - folder.ejs(public): 1단계에서 하위 폴더 + 영상 함께 표시 - README: 폴더 구조/버튼 설명 갱신 Co-Authored-By: Claude Opus 4 <noreply@anthropic.com>
This commit is contained in:
@@ -30,7 +30,7 @@
|
||||
|
||||
<% if (!isSubFolder) { %>
|
||||
<section class="folderGrid">
|
||||
<% if (!subFolders || subFolders.length === 0) { %>
|
||||
<% if ((!subFolders || subFolders.length === 0) && videos.length === 0) { %>
|
||||
<p class="muted">아직 하위 폴더가 없습니다.</p>
|
||||
<% } %>
|
||||
<% (subFolders || []).forEach(function (sf) { %>
|
||||
@@ -40,22 +40,22 @@
|
||||
</a>
|
||||
<% }) %>
|
||||
</section>
|
||||
<% } else { %>
|
||||
<section class="videoGrid">
|
||||
<% if (videos.length === 0) { %>
|
||||
<p class="muted">이 폴더에 영상이 없습니다.</p>
|
||||
<% } %>
|
||||
<% videos.forEach(function (v) {
|
||||
var shareUrl = '/video/' + folderPathEnc + '/' + encodeURIComponent(v.id)
|
||||
%>
|
||||
<a class="videoCard" href="<%= shareUrl %>"
|
||||
data-video-id="<%= v.id %>" data-share-url="<%= shareUrl %>">
|
||||
<div class="videoThumb">▶</div>
|
||||
<div class="videoTitle"><%= v.title %></div>
|
||||
</a>
|
||||
<% }) %>
|
||||
</section>
|
||||
<% } %>
|
||||
|
||||
<section class="videoGrid">
|
||||
<% if (videos.length === 0 && isSubFolder) { %>
|
||||
<p class="muted">이 폴더에 영상이 없습니다.</p>
|
||||
<% } %>
|
||||
<% videos.forEach(function (v) {
|
||||
var shareUrl = '/video/' + folderPathEnc + '/' + encodeURIComponent(v.id)
|
||||
%>
|
||||
<a class="videoCard" href="<%= shareUrl %>"
|
||||
data-video-id="<%= v.id %>" data-share-url="<%= shareUrl %>">
|
||||
<div class="videoThumb">▶</div>
|
||||
<div class="videoTitle"><%= v.title %></div>
|
||||
</a>
|
||||
<% }) %>
|
||||
</section>
|
||||
</main>
|
||||
|
||||
<div class="ctxMenu" id="ctxMenu" hidden>
|
||||
|
||||
Reference in New Issue
Block a user