mirror of
https://github.com/PR0M3TH3AN/bitvid.git
synced 2026-10-29 17:02:28 +00:00
- Fix `nostr-tools` v2 compatibility: - Update `js/nostr/adapters/nsecAdapter.js` to convert hex private keys to `Uint8Array` before passing to `getPublicKey`. - Update `js/nostr/nip46Client.js` to ensure keys are bytes for `getPublicKey`. - Update `tests/nostr/nip46Client.test.js` and `tests/nostr-private-key-signer.test.mjs` to use `Uint8Array` for keys. - Fix `VideoModal` regressions: - Add missing delegation methods (`setCommentsVisibility`, `clearComments`, `resetCommentComposer`, `setCommentStatus`, `setCommentComposerState`, `appendComment`, `renderComments`, `setCommentSectionCallbacks`, `hideCommentsDisabledMessage`, `showCommentsDisabledMessage`, `updateCommentCharCount`, `updateCommentSubmitState`) to `js/ui/components/VideoModal.js`. - Expose getters for `commentsList`, `commentsComposer`, etc., in `VideoModal.js` to support tests. - Implement `setCallbacks` in `js/ui/components/video-modal/commentsController.js` and ensure robust initialization when DOM elements are missing. - Fix `open()` and `updateSourceAvailability()` in `VideoModal.js` to correctly re-enable Share, Embed, and Copy Magnet buttons. - Fix `DeleteModal` tests to comply with linting rules (avoid direct `.style` assignment). Co-authored-by: PR0M3TH3AN <[email protected]>