diff --git a/.agents/skills/flotilla-model/kinds.md b/.agents/skills/flotilla-model/kinds.md index d8589748..2a57e120 100644 --- a/.agents/skills/flotilla-model/kinds.md +++ b/.agents/skills/flotilla-model/kinds.md @@ -10,7 +10,7 @@ and NIP-43 tables in [SKILL.md](SKILL.md). Routes are under `src/routes/`. |---|---|---|---|---| | Chat | `MESSAGE` (9) | none | `src/app/rooms.ts` | `spaces/[relay]/chat`, `spaces/[relay]/[h]` (`RoomChat`) | | Threads | `THREAD` (11) | `Thread` | none | `spaces/[relay]/threads`, `threads/[id]` (`ThreadCreate`) | -| Comments | `COMMENT` (1111) | `Comment` | `src/app/content.ts` (`makeCommentFilter`) | `CommentCompose`, `EventReply` | +| Comments | `COMMENT` (1111) | `Comment` | `src/app/content.ts` (`makeCommentFilter`), `src/app/rooms.ts` (`publishComment`) | `CommentCompose`, `EventReply`, `EventComments` | | Articles | `LONG_FORM` (30023) | `Article` | `src/app/articles.ts` | `spaces/[relay]/articles`, `articles/create`, `articles/[address]` | | Calendar | `EVENT_TIME` (31923) | `TimeEvent` | `src/app/feeds.ts` (`makeCalendarFeed`) | `spaces/[relay]/calendar`, `calendar/[address]` (`CalendarEventForm`) | | Classifieds | `CLASSIFIED` (30402) | `Classified` | `src/app/classifieds.ts` | `spaces/[relay]/classifieds`, `classifieds/[address]` (`ClassifiedForm`) | diff --git a/.agents/skills/flotilla-state/SKILL.md b/.agents/skills/flotilla-state/SKILL.md index 2908b0a2..a65ebaeb 100644 --- a/.agents/skills/flotilla-state/SKILL.md +++ b/.agents/skills/flotilla-state/SKILL.md @@ -379,8 +379,8 @@ Plugin mutators already return a `Command`: `roomLists.get().addRelay(url).then( Some call sites call `thunks.get().publish({event, relays, delay})` directly. Anything that honours the `send_delay` window does, because `Command` cannot carry it: room chat -(`RoomChat.svelte`), the comment composers (`CommentCompose.svelte` and `EventReply.svelte`) and -`publishRoomQuote` in `rooms.ts`. So do the push adapters and `ProfileDelete.svelte`. DMs go through +(`RoomChat.svelte`), and `publishComment` (behind both comment composers) and `publishRoomQuote` in +`rooms.ts`. So do the push adapters and `ProfileDelete.svelte`. DMs go through `wraps.get().publish({event, recipients})`, which returns a merged thunk (see `reactions.ts`). NIP-86 calls (`relayManagement.get().forUrl(url)`) are not thunks. They return `{result, error}`, and the caller handles `error`. diff --git a/e2e/specs/community.spec.ts b/e2e/specs/community.spec.ts index 72a81cdb..3ab9d7ca 100644 --- a/e2e/specs/community.spec.ts +++ b/e2e/specs/community.spec.ts @@ -573,14 +573,17 @@ test("US-052 comment on and react to community posts", async ({seed, as}) => { await expect(heroCard.getByRole("button", {name: PARTY})).toBeVisible() await bob.getByRole("button", {name: /^Discussion/}).click() - await bob.getByRole("button", {name: "Leave comment"}).click() + await bob.getByRole("button", {name: "Add a comment"}).click() const reply = bob.locator("form").filter({has: bob.locator(".note-editor")}) await noteEditor(reply).pressSequentially("Is there parking at The Green?") - await reply.getByRole("button", {name: "Post Reply"}).click() + await reply.getByRole("button", {name: "Comment"}).click() - await expect(bob.getByText("Is there parking at The Green?")).toBeVisible() + // The composer holds what was typed until the relay confirms it, so match the comment itself. + await expect( + bob.locator('[data-component="Comment"]').filter({hasText: "Is there parking at The Green?"}), + ).toBeVisible() const alice = await as(users.alice, calendarPath) @@ -594,14 +597,18 @@ test("US-052 comment on and react to community posts", async ({seed, as}) => { await expect(alice.getByText("Is there parking at The Green?")).toBeVisible() - await alice.getByRole("button", {name: "Leave comment"}).click() + await alice.getByRole("button", {name: "Add a comment"}).click() const alicesReply = alice.locator("form").filter({has: alice.locator(".note-editor")}) await noteEditor(alicesReply).pressSequentially("Yes, in the field behind the pub.") - await alicesReply.getByRole("button", {name: "Post Reply"}).click() + await alicesReply.getByRole("button", {name: "Comment"}).click() - await expect(alice.getByText("Yes, in the field behind the pub.")).toBeVisible() + await expect( + alice + .locator('[data-component="Comment"]') + .filter({hasText: "Yes, in the field behind the pub."}), + ).toBeVisible() }) test("US-053 browse and search the library", async ({seed, as}) => { diff --git a/src/app/components/CalendarEventDiscussion.svelte b/src/app/components/CalendarEventDiscussion.svelte deleted file mode 100644 index 6c85b84c..00000000 --- a/src/app/components/CalendarEventDiscussion.svelte +++ /dev/null @@ -1,78 +0,0 @@ - - -
No comments yet — start the conversation.
- -