Skip to content

feat(spaces): space title menu with calendar submenus and config shortcuts - #575

Merged
tkuhn merged 1 commit into
masterfrom
space-title-menu
Jul 30, 2026
Merged

feat(spaces): space title menu with calendar submenus and config shortcuts#575
tkuhn merged 1 commit into
masterfrom
space-title-menu

Conversation

@tkuhn

@tkuhn tkuhn commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

Summary

Reworks the dropdown next to a space title (formerly the labeled calendar menu) into a regular chevron menu, SpaceTitleMenu (renamed from CalendarMenu):

  • The calendar actions move into submenu flyouts: add to calendar ▸ (an Event space's own date: .ics / Google / Outlook) and add events to calendar ▸ (event-containing spaces: webcal / Google / Outlook subscribe, copy feed URL, download all). A space that is both gets both groups.
  • For viewers of maintainer tier or above, the menu adds two shortcuts below a separator: ⚙ configure (the space's About tab) and ➕ add view display... — the About tab's view-displays action as a direct link, built from the view nanopub's own gen:ViewResultAction declaration (template, target field, gen:isVisibleTo gate), so the shortcut stays in sync if the view is superseded. The menu now also appears on event-less spaces for maintainers.
  • Generic submenu CSS (.actionmenu-subitem/-sublabel/-subcontent) with a right-pointing chevron and hover flyout; nanodash.js flips the flyout leftward when the viewport's right edge lacks room (mirroring the existing dropdown repositioning).
  • .actionmenu-content now pins the body font stack, so dropdown entries render in Inter instead of inheriting Martian when a menu sits inside a heading.
  • Serialization fix: Group entry lists are defensively copied into ArrayLists. List.of() serializes via the java.util.CollSer proxy, and since the entries are also reachable through the page's component tree, restoring a stored page hit a ClassCastException assigning the proxy to ListDataProvider.list.

Test plan

  • Verified on a local jetty with Playwright: fdo-conference-2026 (both submenus), nanosessions (subscribe-only + maintainer shortcuts in Inter with correct hrefs: /space?…&tab=about and the publish link matching the About-tab action exactly).
  • Page-store round trip: loaded an event space, cycled six other pages, revisited the stateful page-id URL — restores cleanly, no ClassCastException.

🤖 Generated with Claude Code

…and config shortcuts

The labeled calendar dropdown next to a space title becomes a regular
chevron menu (SpaceTitleMenu, renamed from CalendarMenu): calendar action
groups ("add to calendar", "add events to calendar") open as submenu
flyouts, and maintainer-tier+ viewers additionally get "configure"
(linking to the About tab) and "add view display..." (the About tab's
view-displays action as a direct shortcut, built from the view nanopub's
own action declaration so it stays in sync).

Dropdown entries now keep the body font (Inter) when the menu sits inside
a heading. nanodash.js flips a submenu flyout leftward when the viewport's
right edge lacks room. Group entry lists are defensively copied into
ArrayLists: List.of()'s CollSer serialization proxy broke restoring stored
pages (ClassCastException on ListDataProvider.list) since the entries are
also reachable through the page's component tree.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@tkuhn
tkuhn merged commit f12a402 into master Jul 30, 2026
8 checks passed
@tkuhn
tkuhn deleted the space-title-menu branch July 30, 2026 06:48
@github-actions

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 5.8.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant