summaryrefslogtreecommitdiff
path: root/public/stylesheets/admin.css
diff options
context:
space:
mode:
authorerdgeist <erdgeist@erdgeist.org>2026-07-12 02:15:44 +0200
committererdgeist <erdgeist@erdgeist.org>2026-07-12 02:15:44 +0200
commit45bf65d04d046c0ea4a1150096b2a9b846d6c0b8 (patch)
tree24dad426779cb3b0ac59c405245aac1d28109982 /public/stylesheets/admin.css
parent13c8cb415813e90c883a44b0c0888382161de92a (diff)
Give the sitemap its own view, with collapse and descendant counts
Extracted from admin#index's inline table into NodesController#sitemap. Nested <details>/<summary> per branch, one linear pass over the existing flat [node, level] list (no added queries) -- each node's own descendant count computed the same way, via a small stack rather than re-walking the tree per node. Branches under updates/, club/erfas, club/chaostreffs, and disclosure start collapsed by default (CccConventions::SITEMAP_COLLAPSED_PATHS); any branch currently collapsed, whether by that default or because someone just closed it, is highlighted via a plain :not([open]) selector -- no state tracked outside the DOM itself. Dropped the update?-post exclusion this view used to rely on -- no longer needed now that updates/ collapses instead of being filtered out, so its real children (previously silently absent) now show up correctly. admin#index's own, separate @sitemap query is unchanged; that view has no collapse mechanism to compensate and wasn't part of this.
Diffstat (limited to 'public/stylesheets/admin.css')
-rw-r--r--public/stylesheets/admin.css40
1 files changed, 40 insertions, 0 deletions
diff --git a/public/stylesheets/admin.css b/public/stylesheets/admin.css
index aa8b288..5c1e489 100644
--- a/public/stylesheets/admin.css
+++ b/public/stylesheets/admin.css
@@ -25,6 +25,7 @@ a:hover {
25 body content, node listing tables, the child-creation shortcuts on 25 body content, node listing tables, the child-creation shortcuts on
26 nodes#show, and the dashboard draft list's Show/Revisions links. */ 26 nodes#show, and the dashboard draft list's Show/Revisions links. */
27#page_editor a, 27#page_editor a,
28#sitemap a,
28table.node_table a, 29table.node_table a,
29table.assets_table a, 30table.assets_table a,
30table.events_table a, 31table.events_table a,
@@ -104,6 +105,11 @@ input[type=radio] {
104 width: 100%; 105 width: 100%;
105 box-sizing: border-box; 106 box-sizing: border-box;
106 } 107 }
108
109 #sitemap details details {
110 margin-left: 0.75rem;
111 padding-left: 0.5rem;
112 }
107} 113}
108 114
109#metadata, 115#metadata,
@@ -773,6 +779,40 @@ form.button_to button[type="submit"] {
773 white-space: nowrap; 779 white-space: nowrap;
774} 780}
775 781
782.sitemap_node {
783 padding-bottom: 0.5rem;
784 margin-bottom: 0.5rem;
785 border-bottom: 1px solid #ececec;
786}
787
788.sitemap_node h4 {
789 margin: 0;
790}
791
792.sitemap_node .field_hint {
793 display: block;
794 margin: 2px 0 0;
795}
796
797.sitemap_node p {
798 margin: 2px 0 0;
799}
800
801#sitemap details details {
802 margin-left: 1.5rem;
803 border-left: 1px solid #e8e8e8;
804 padding-left: 0.75rem;
805}
806
807#sitemap summary {
808 padding: 4px 0;
809}
810
811#sitemap details:not([open]) > summary {
812 color: #ff9600;
813 font-weight: bold;
814}
815
776/* ============================================================ 816/* ============================================================
777 Page editor / metadata forms 817 Page editor / metadata forms
778 ============================================================ */ 818 ============================================================ */