feat: add Notion-style breadcrumb navigation with dropdown menus
Backend: - Added _nav_breadcrumb() to build page hierarchy chain (root → current) - New /api/nav/menu endpoint returns workspace/folder children with has_children flag - view_page() and view_page_root() now pass breadcrumb_items, nav_workspace_id, nav_page_id to template Header template (_header.html): - Replaced static breadcrumb with Alpine.js fdBreadcrumb() component - Breadcrumb items now clickable with dropdown menus showing
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
{% block page_icon %}🔗{% endblock %}
|
||||
|
||||
{% block topbar %}
|
||||
{% set breadcrumb_items = [{"label": "Home", "url": "/workspaces"}, {"label": owner ~ "/" ~ repo, "url": None}] %}
|
||||
{% set breadcrumb_items = [{"label": owner ~ "/" ~ repo, "url": None}] %}
|
||||
{% set page_icon = "🔗" %}
|
||||
{% set right_actions = '<button class="page-action-btn" @click="showNewFile=!showNewFile" title="New file">📄+</button><button class="page-action-btn" @click="triggerUpload()" title="Upload file">📤</button><input type="file" id="gitea-upload-input" style="display:none" @change="doUpload($event)" multiple><button class="page-action-btn" @click="refreshTree()" title="Refresh">🔄</button><a href="/accounts/settings" class="topbar-btn" title="Settings">⚙</a>' %}
|
||||
{% include '_header.html' %}
|
||||
|
||||
Reference in New Issue
Block a user