Skip to content

Enhance web UI with logging, entity management, and security features#146

Merged
asphaltbuffet merged 22 commits into
mainfrom
enhance-webui
May 26, 2026
Merged

Enhance web UI with logging, entity management, and security features#146
asphaltbuffet merged 22 commits into
mainfrom
enhance-webui

Conversation

@asphaltbuffet
Copy link
Copy Markdown
Owner

This pull request introduces several enhancements and infrastructure updates to the entity management and web UI components. The most significant changes include improvements to how entity trees are managed and displayed in the web interface, the addition of new API methods for entity manipulation, and the inclusion of licensing information for third-party fonts.

Entity Tree and Web UI Improvements:

  • Added tree.js to handle interactive behaviors for the inventory tree, add-modal, and detail pane, including keyboard navigation, selection, and modal dialog management. This provides a more accessible and dynamic UI for managing entities.
  • Introduced a new add_item_form.html template for adding entities via a modal form, supporting selection of entity type and user attribution.
  • Refactored the detail.html template to improve the detail section layout, add breadcrumbs, and provide contextual action buttons for editing, adding children, and marking items as missing or found. [1] [2]

Entity API and Data Model Enhancements:

  • Added the HasChildren field to the EntityResult struct and updated the logic in ListEntities and GetChildren to set this field, enabling the UI to accurately display expand/collapse controls for entities with children. [1] [2]
  • Implemented the GetEntityByID method in the app layer and updated the App interface and test fakes accordingly, allowing retrieval of entities by their stable ID. [1] [2] [3]

Licensing and Dependency Management:

  • Added third-party license documentation for iA Writer fonts, including the full SIL Open Font License text and a listing of included font files. [1] [2]

Configuration and Infrastructure:

  • Enabled official Claude plugins for frontend design and GitHub integration in .claude/settings.json.
  • Expanded the list of enabled skills and MCP plugin methods in .claude/settings.local.json to support new development workflows.
  • Removed the serena MCP server configuration from .mcp.json, leaving the mcpServers map empty.

These changes collectively improve the flexibility, usability, and maintainability of the entity management system, especially in the web UI, while ensuring compliance with third-party licensing requirements.

…limits

- csrfGuard requires Hx-Request: true and matching Origin/Referer on mutating methods (H1)
- securityHeaders sets CSP, X-Content-Type-Options, Referrer-Policy (M1)
- limitBody wraps POST bodies in MaxBytesReader (M12)
Templates now render into bytes.Buffer first; on success the buffer is
written to the ResponseWriter, on failure we return a sanitized 500
instead of a torn partial response.

Also logs OOB swap template errors (M6, M7) via renderHTMLAppend.
Removes all onclick=/hx-on::after-request attributes from templates and
implements them via delegated listeners in tree.js. Templates now expose
data-entity-id, data-parent-id, and data-action attributes for the JS
to act on.

This lets CSP drop 'unsafe-inline' from script-src and style-src.
@asphaltbuffet asphaltbuffet merged commit cae9bc2 into main May 26, 2026
6 checks passed
@asphaltbuffet asphaltbuffet deleted the enhance-webui branch May 26, 2026 11:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant