From 79a9adf720944c8f1dcec76644b8b04112c1aa36 Mon Sep 17 00:00:00 2001 From: OpenVelo Agent Date: Thu, 23 Jul 2026 10:37:49 +0000 Subject: [PATCH] docs: update documentation to OKF v0.1 format --- docs/architecture/frontend-structure.md | 2 +- docs/guides/blog.md | 10 +++++++++- docs/index.md | 2 +- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/docs/architecture/frontend-structure.md b/docs/architecture/frontend-structure.md index 125abc2..bf7c5f9 100644 --- a/docs/architecture/frontend-structure.md +++ b/docs/architecture/frontend-structure.md @@ -50,7 +50,7 @@ Routes live in `frontend/src/app/app.routes.ts`: | `BlogPage` | `frontend/src/app/features/blog/blog.page.ts` | Smart `/blog` page that loads published posts and derives loading, error, empty, and list states. | | `BlogPresenterComponent` | `frontend/src/app/features/blog/blog-presenter.component.ts` | Shared title/date/sanitized-Markdown renderer used by `/blog` and `/login`. | | `AdminBlogComponent` | `frontend/src/app/features/admin/blog/blog.component.ts` | Smart `/admin/blog` page coordinating list refresh and create/edit/delete modal state. | -| `BlogFormModalComponent` / `BlogDeleteModalComponent` | `frontend/src/app/features/admin/blog/` | Admin Markdown editor with live preview and destructive-action confirmation. | +| `BlogFormModalComponent` / `BlogDeleteModalComponent` | `frontend/src/app/features/admin/blog/` | Admin Markdown editor with live preview and destructive-action confirmation. `BlogFormModalComponent` also installs a `@HostListener('document:keydown.escape')` handler that closes the modal via `onCancel()` when the modal is open and not currently saving (mirrors the `change-password-modal` Escape contract). | # Authenticated SSE wiring diff --git a/docs/guides/blog.md b/docs/guides/blog.md index ba0e626..10add9b 100644 --- a/docs/guides/blog.md +++ b/docs/guides/blog.md @@ -3,7 +3,7 @@ type: guide title: Blog Publishing and Reading description: How administrators create, edit, publish, and delete Markdown posts and how users read published posts. tags: [guide, blog, admin, markdown, tester] -timestamp: 2026-07-23T10:12:24Z +timestamp: 2026-07-23T10:36:45Z --- # User views @@ -34,6 +34,14 @@ Both views use `BlogPresenterComponent` to show the post title, publication date * Click the trash action to open **Delete post**. The confirmation includes the title and warns that deletion cannot be undone. * Click **Delete** to remove the post. The table refreshes and displays `Post deleted.`. Click **Cancel** or the modal backdrop to leave the post unchanged. +# Closing modals with Escape + +Both the **New post / Edit post** modal and the **Delete post** confirmation honor the platform-wide Escape-to-close convention: + +* Pressing **Escape** while the modal is open closes it without saving or deleting. +* Escape is suppressed while a save/publish request is in flight (the modal stays open until the current operation completes), so an in-flight create or update cannot be silently cancelled by an accidental keypress. +* Escape, the **Cancel** / **Delete** buttons, and clicking the modal backdrop all close the modal via the same `onCancel()` → `cancel` output flow; no partial post is ever created or modified when Escape is pressed. + # Validation and expected errors | Input or operation | Expected behavior | diff --git a/docs/index.md b/docs/index.md index 2b8c2de..06d600b 100644 --- a/docs/index.md +++ b/docs/index.md @@ -12,7 +12,7 @@ controls, administrator-managed Markdown blog publishing, and public and signed-in blog views. The docs below are organized by purpose so agents can pull just the slice -they need. Last regenerated 2026-07-23T10:12:24Z. +they need. Last regenerated 2026-07-23T10:36:45Z. # Architecture