4 Commits

Author SHA1 Message Date
d7a04dd8f8 Fix nsec import validation for Uint8Array data
**Motivations:**
- Fix import error when importing nsec private keys
- Support both string and Uint8Array formats from nip19.decode

**Root causes:**
- nip19.decode returns decoded.data as Uint8Array, not string
- Validation in KeyManagementManager only checked for string type
- importPrivateKey in keyManagement.ts only handled string type

**Correctifs:**
- Updated KeyManagementManager validation to accept Uint8Array
- Updated importPrivateKey to convert Uint8Array to hex using bytesToHex
- Improved error messages to show actual validation errors

**Evolutions:**
- None

**Pages affectées:**
- components/KeyManagementManager.tsx
- lib/keyManagement.ts
2026-01-05 22:38:21 +01:00
b8daab2bcd Remove initializeCookieCleanup function and migration code 2025-12-28 22:38:34 +01:00
42e3e7e692 Update all dependencies to latest versions and fix compatibility issues
**Motivations:**
- Keep dependencies up to date for security and features
- Automate dependency updates in deployment script
- Fix compatibility issues with major version updates (React 19, Next.js 16, nostr-tools 2.x)

**Root causes:**
- Dependencies were outdated
- Deployment script did not update dependencies before deploying
- Major version updates introduced breaking API changes

**Correctifs:**
- Updated all dependencies to latest versions using npm-check-updates
- Modified deploy.sh to run npm-check-updates before installing dependencies
- Fixed nostr-tools 2.x API changes (generatePrivateKey -> generateSecretKey, signEvent -> finalizeEvent, verifySignature -> verifyEvent)
- Fixed React 19 ref types to accept null
- Fixed JSX namespace issues (JSX.Element -> React.ReactElement)
- Added proper types for event callbacks
- Fixed SimplePool.sub typing issues with type assertions

**Evolutions:**
- Deployment script now automatically updates dependencies to latest versions before deploying
- All dependencies updated to latest versions (Next.js 14->16, React 18->19, nostr-tools 1->2, etc.)

**Pages affectées:**
- package.json
- deploy.sh
- lib/keyManagement.ts
- lib/nostr.ts
- lib/nostrRemoteSigner.ts
- lib/zapVerification.ts
- lib/platformTrackingEvents.ts
- lib/sponsoringTracking.ts
- lib/articlePublisherHelpersVerification.ts
- lib/contentDeliveryVerification.ts
- lib/paymentPollingZapReceipt.ts
- lib/nostrPrivateMessages.ts
- lib/nostrSubscription.ts
- lib/nostrZapVerification.ts
- lib/markdownRenderer.tsx
- components/AuthorFilter.tsx
- components/AuthorFilterButton.tsx
- components/UserArticlesList.tsx
- types/nostr-tools-extended.ts
2025-12-28 21:49:19 +01:00
46d5f03fbe Remove connection button and replace with direct account creation/import options 2025-12-28 20:35:50 +01:00