|
| 1 | +# Changelog |
| 2 | + |
| 3 | +All notable changes to this project are documented here. |
| 4 | + |
| 5 | +--- |
| 6 | + |
| 7 | +## [1.1.0] — 2026-04-10 |
| 8 | + |
| 9 | +### New Features |
| 10 | + |
| 11 | +#### Delete Message |
| 12 | +- WhatsApp-style delete confirmation modal with three options: |
| 13 | + - **Delete for everyone** — calls Evolution API `DELETE /message/delete/`; only available when every selected message was sent by you (`fromMe`); works within ~60 hours of sending |
| 14 | + - **Delete for me** — calls `DELETE /message/deleteMessage/` (best-effort); always removes the message from your local view regardless of API result |
| 15 | + - **Cancel** — dismisses without action |
| 16 | +- Available from the **right-click context menu** (single message) and the **select-mode toolbar** (multi-message batch delete) |
| 17 | +- Toolbar delete button is disabled when no messages are selected |
| 18 | +- Modal auto-dismissed when switching or closing a conversation |
| 19 | +- Escape key closes the modal |
| 20 | +- Toast notification on partial failure (e.g. message too old to delete for everyone) |
| 21 | + |
| 22 | +#### RTL / LTR Text Direction |
| 23 | +- All message text elements now carry `dir="auto"` — Hebrew/Arabic renders right-to-left, English/Latin stays left-to-right, automatically per bubble |
| 24 | +- Applied to: plain text, image/video/document captions, contact messages, poll title and options, quoted message previews, chat list contact names and last-message previews |
| 25 | + |
| 26 | +### Bug Fixes |
| 27 | + |
| 28 | +#### Security |
| 29 | +- **XSS** — avatar `onerror` attribute no longer uses `innerHTML` with unescaped initials; switched to sibling-element show/hide pattern |
| 30 | +- **XSS** — `quotedMsg.id` is now sanitised (`/[^a-zA-Z0-9_-]/g`) before being embedded in `onclick` |
| 31 | +- **XSS** — image lightbox `onclick` now reads URL from `data-src` attribute instead of embedding the raw URL in the inline handler string |
| 32 | +- **XSS** — group name, subject, and description now escaped with `chatEsc()` in all render paths |
| 33 | +- Group description snippet in group manager now escaped |
| 34 | + |
| 35 | +#### Crashes / Runtime Errors |
| 36 | +- `chatState.allFetchedMessages` was not initialised in the state object — accessing it before the first conversation opened threw `TypeError` |
| 37 | +- `case 'location'` crashed when `m.text` was `null` or `undefined` |
| 38 | +- Location coordinates were not passed through `encodeURIComponent` before being placed in a Google Maps URL |
| 39 | +- `FileReader` base64 result was indexed with `[1]` without checking that a comma was present in the data URL |
| 40 | + |
| 41 | +#### API |
| 42 | +- `chatApiCall` was silently dropping the request body on `DELETE` calls — the Evolution API delete endpoints require a JSON body, so deletes were failing with 400/422 errors |
| 43 | + |
| 44 | +#### Lifecycle |
| 45 | +- Delete modal was not dismissed when switching conversations — the wrong `remoteJid` (new conversation's JID) would be used if the user confirmed deletion after switching |
| 46 | +- Delete modal was not dismissed when closing a conversation |
| 47 | +- `chatCloseConversation` did not reset `selectMode`, `selectedMsgs`, or the toolbar visibility |
| 48 | +- `chatConfirmDeleteForEveryone` and `chatConfirmDeleteForMe` now guard against `activeJid` being `null` |
| 49 | + |
| 50 | +#### UI / State |
| 51 | +- Select-mode toolbar delete button used a fragile `[onclick="..."]` CSS attribute selector to find itself; replaced with a stable `id` |
| 52 | +- Delete button incorrectly started in an enabled state before `chatUpdateSelectCount` ran; now starts `disabled` in HTML |
| 53 | +- `chatCopySelected` and `chatForwardSelected` used `Array.includes()` (O(n)) to filter selected messages; replaced with `Set.has()` (O(1)) |
| 54 | +- Quoted message text defaulted to `undefined` if `m.quotedMsg.text` was missing; now defaults to `''` |
| 55 | + |
| 56 | +--- |
| 57 | + |
| 58 | +## [1.0.1] — 2026-04-07 |
| 59 | + |
| 60 | +### Bug Fixes |
| 61 | +- Fixed scroll-up pagination to correctly load older messages from the API |
| 62 | +- Ghost unread indicators no longer appear after marking chats as read |
| 63 | + |
| 64 | +--- |
| 65 | + |
| 66 | +## [1.0.0] — 2026-04-05 |
| 67 | + |
| 68 | +### Initial Release |
| 69 | +- Full chat inbox with conversation list and real-time polling |
| 70 | +- Message types: text, image, video, audio, document, sticker, location, contact, poll, reactions |
| 71 | +- Read receipts (double blue ticks) via `MessageUpdate` status history |
| 72 | +- Select mode with copy and forward |
| 73 | +- Drag-and-drop reordering of message queues |
| 74 | +- Compose panel: text, media, voice note, location, contact, reaction, poll, buttons, list, status/story |
| 75 | +- Group management: browse, create, manage participants and settings |
| 76 | +- Bulk sending with randomized delay |
| 77 | +- Scheduled sending with IndexedDB persistence |
| 78 | +- Phone number validation and E.164 normalisation |
| 79 | +- `config.json` support for server-hosted deployments |
0 commit comments