25 lines
1.1 KiB
Plaintext
25 lines
1.1 KiB
Plaintext
<%#
|
|
Dashboard (todo §1): the app-shell "People" list. Composes the building-block partials around
|
|
the shell using the view model from src/dashboard.ts. EJS `include()` returns the rendered
|
|
string, so each partial is captured and handed to the shell as a slot. The filter form,
|
|
sortable headers and pager are real GET links — q/sort/page round-trip the URL, zero-JS.
|
|
%><%
|
|
const nav = include("partials/nav-tree", { nodes: model.nav });
|
|
const filters = include("partials/filter-bar", model.filterBar);
|
|
const table = include("partials/data-table", model.table);
|
|
const pager = include("partials/pagination", model.pagination);
|
|
const actions =
|
|
'<button class="btn"><svg class="ico ico-sm" aria-hidden="true"><use href="#i-download"/></svg>Export</button>' +
|
|
'<button class="btn btn-primary"><svg class="ico ico-sm" aria-hidden="true"><use href="#i-plus"/></svg>Add person</button>';
|
|
-%>
|
|
<%- include("partials/shell", {
|
|
actions,
|
|
body: filters + table + pager,
|
|
brand: model.shell.brand,
|
|
breadcrumbs: model.shell.breadcrumbs,
|
|
nav,
|
|
theme: model.shell.theme,
|
|
title: model.shell.title,
|
|
user: model.shell.user,
|
|
}) %>
|