55 Commits

Author SHA1 Message Date
b5aa9bb68a Fix: Update Tailwind CSS import syntax for v4 compatibility 2025-12-28 23:04:44 +01:00
a2656ef3f8 Fix: Replace pool.sub() with createSubscription() for nostr-tools 2.19.4 compatibility 2025-12-28 22:56:34 +01:00
b551e257f9 Fix PostCSS configuration for Tailwind CSS v4 2025-12-28 22:39:55 +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
b3c25bf16f test 2025-12-28 21:40:46 +01:00
6efefdf8a4 Separate account creation buttons into two distinct actions
**Motivations:**
- Improve UI clarity by displaying two distinct buttons instead of one combined button
- Reduce the number of clicks needed to access the import functionality
- Allow users to directly choose their desired action without an intermediate step

**Evolutions:**
- Added optional 'initialStep' prop to CreateAccountModal to initialize modal at 'import' or 'choose' step
- Refactored NoAccountView to display two separate buttons: 'Générer un nouveau compte' and 'Importer une clé existante'
- Extracted buttons into separate NoAccountActionButtons component to respect function line limit
- Removed unused 'connected' parameter from AuthorPresentationFormView

**Pages affectées:**
- components/CreateAccountModal.tsx
- components/AuthorPresentationEditor.tsx
- features/account-creation-buttons-separation.md
2025-12-28 21:31:20 +01:00
f2d5eb2296 Add UX click minimization rules to quality guidelines
**Motivations:**
- Ensure user interfaces are designed to minimize user interactions
- Improve overall user experience by reducing friction

**Root causes:**
- N/A (new requirement)

**Correctifs:**
- N/A

**Evolutions:**
- Added new UX section with click minimization principles
- Defined guidelines for direct actions, functional grouping, optimized forms
- Specified what to avoid in user interfaces

**Pages affectées:**
- .cursor/rules/quality.mdc
2025-12-28 21:31:06 +01:00
87a7c682d7 Deploy: Use /tmp for SSH ControlPath to avoid spaces issue 2025-12-28 20:43:40 +01:00
30816f2d2d Deploy: Fix SSH ControlPath with spaces in home directory 2025-12-28 20:43:22 +01:00
6c3f38a411 Deploy: Use persistent SSH connection to avoid MaxStartups limit 2025-12-28 20:43:05 +01:00
88e6d41f26 Deploy: Remove connection button and replace with direct account creation/import 2025-12-28 20:42:38 +01:00
46d5f03fbe Remove connection button and replace with direct account creation/import options 2025-12-28 20:35:50 +01:00
aa21dc3ad6 Remove obsolete 'Connect with Nostr' message from presentation page
**Motivations :**
* Remove outdated message that appears after account creation/import
* Clean up dead code and unused translation keys
* Simplify presentation page UX now that key creation/import is available

**Root causes :**
* Message 'Connectez-vous avec Nostr pour créer votre article de présentation' was displayed even when account exists
* NotConnected component and translation keys were no longer needed after implementing key creation/import

**Correctifs :**
* Removed NotConnected component and its message
* Removed presentation.notConnected translation keys from all locale files
* Simplified display to show ConnectButton directly when no pubkey is available
* Added auto-loading of pubkey when account exists but pubkey not yet loaded

**Evolutions :**
* Presentation form now displays immediately when account exists (even if not unlocked)
* Better UX: users can see the form and will get error message if they try to publish without unlocking

**Page affectées :**
* components/AuthorPresentationEditor.tsx
* locales/fr.txt
* locales/en.txt
* public/locales/fr.txt
* public/locales/en.txt
2025-12-28 20:23:40 +01:00
8f855fa61b Add NIP-95 upload endpoint documentation to README 2025-12-28 16:20:12 +01:00
55a70866eb Add NIP-95 upload endpoint documentation and improve error message
- Add NEXT_PUBLIC_NIP95_UPLOAD_URL to README environment variables section
- Add NIP-95 upload service documentation with examples
- Create .env.example file with all required environment variables
- Improve error message to guide users to README for setup instructions
- All TypeScript checks pass
2025-12-28 16:19:48 +01:00
aa35918db2 Fix linter errors: extract PresentationFormHeader component
- Extract PresentationFormHeader to reduce PresentationForm line count
- Add all missing translations to public/locales files
- Update Bitcoin address help text to specify 'excluding fees'
- All TypeScript and linter checks pass
2025-12-28 16:16:29 +01:00
f082befb36 Complete English translation for presentation page and update Bitcoin address help text
- Translate all hardcoded French text in presentation form to use i18n
- Update Bitcoin address help text to specify '0.046 BTC excluding fees'
- Add all presentation field translations (labels, placeholders, help texts)
- Add image upload field translations
- Add validation error message translation
- Add fallback user name translation
- All TypeScript checks pass
2025-12-28 16:15:28 +01:00
58e1ace081 Add pictureUrl to useAuthorPresentation publish call 2025-12-28 16:13:06 +01:00
080cfa47d6 Fix missing translation and pictureUrl in useAuthorPresentation 2025-12-28 16:12:40 +01:00
a19b601205 Add image upload to presentation form and profile note
- Add ImageUploadField component for profile picture upload (NIP-95)
- Add pictureUrl field to AuthorPresentationDraft interface
- Store picture URL in Nostr event tags as 'picture'
- Display profile picture on author page
- Add discrete note indicating zapwall.fr profile differs from Nostr profile
- Update translations (FR/EN) for profile note
- All TypeScript checks pass
2025-12-28 16:11:54 +01:00
f5f9f06e6e Remove 'Créer votre article de présentation -' from form title
- Keep only user name in presentation form title
- Description remains below the title
2025-12-28 00:01:31 +01:00
3ce8f340fd Change 'Publier' to 'Publier le profil' in navigation
- Update nav.publish translation from 'Publier' to 'Publier le profil' (FR)
- Update nav.publish translation from 'Publish' to 'Publish profile' (EN)
- Update all locale files
2025-12-27 23:59:27 +01:00
398b9506e6 Remove duplicate title and description from presentation page
- Remove title and description from pages/presentation.tsx
- Keep title with user name in AuthorPresentationEditor form
- Fix duplicate display issue
2025-12-27 23:56:31 +01:00
cb7ee0cfd4 Replace nos2x and NostrConnect with Alby authentication
- Remove nos2x and NostrConnect support
- Create new NostrAuthService using Alby (window.nostr NIP-07)
- Replace useNostrConnect with useNostrAuth in all components
- Update NostrRemoteSigner to use Alby for signing
- Delete NostrConnect-related files (nostrconnect.ts, handlers, etc.)
- Update documentation to reflect Alby-only authentication
- Remove NOSTRCONNECT_BRIDGE environment variable
- All TypeScript checks pass
2025-12-27 23:54:34 +01:00
fd6ff4b6cc Fix remaining documentation reference to use.nsec.app 2025-12-27 23:48:41 +01:00
fd26c42a17 Replace use.nsec.app with nos2x extension (NIP-07)
- Update NostrConnectService to use nos2x (window.nostr) by default
- Fallback to NostrConnect bridge only if nos2x is not available
- Update NostrRemoteSigner to use window.nostr.signEvent() for signing
- Add TypeScript definitions for NIP-07 window.nostr API
- Update documentation to reflect nos2x as primary authentication method
- Remove default use.nsec.app bridge URL
- All TypeScript checks pass
2025-12-27 23:48:16 +01:00
6d478acd2c Remove unused _unusedExtractTags function
- Function was kept for backward compatibility but is never used
- Removing it to fix TypeScript warning
- All TypeScript checks now pass
2025-12-27 23:27:13 +01:00
0112c7152f Update presentation page: show ConnectButton when not connected and user name in form title
- Replace 'NotConnected' message with ConnectButton component
- Display user name (or shortened pubkey) in form title when connected
- Update ConnectButton styling to match dark theme
- Improve UX by allowing direct connection from presentation page
2025-12-27 23:26:39 +01:00
716ba4b9b6 Remove unused MediaRef import
- Remove MediaRef from imports in nostrEventParsing.ts
- All TypeScript checks now pass
2025-12-27 23:19:10 +01:00
ef3d2cf52e Fix TypeScript errors
- Remove unused 't' import from HomeView.tsx
- Fix _unusedExtractTags function to properly mark parameter as unused
- All TypeScript checks now pass
2025-12-27 23:18:39 +01:00
d3cae85b3d Update presentation page to dark theme and add language selector
- Update /presentation page to use dark theme (PageHeader, Footer, bg-cyber-darker)
- Add LanguageSelector component to PageHeader for all pages
- Update AuthorPresentationEditor to use dark theme styling
- Update ArticleField and ArticleFormButtons to use dark theme
- Add locale persistence in localStorage
- Update _app.tsx to load saved locale from localStorage
- All pages now support FR/EN language switching
2025-12-27 23:17:50 +01:00
b052900e5d Show 'Create author page' button even when not connected
- Display button for creating author page even when user is not connected
- Button redirects to /presentation page
- Improves discoverability of author page creation feature
2025-12-27 23:14:34 +01:00
fe48440a27 Make zapwall.fr in footer clickable link to home page
- Convert footer title to Link component pointing to /
- Add hover effect (neon-cyan) for consistency
- Maintains same styling
2025-12-27 23:12:56 +01:00
e4ac155281 Make zapwall.fr title clickable link to home page
- Convert PageHeader title to Link component pointing to /
- Add hover effect (neon-green) for better UX
- Maintains same styling and appearance
2025-12-27 23:12:25 +01:00
449b2f4711 Update documentation content and wording to match zapwall.fr
- Update user-guide.md: Use 'publication' instead of 'article', add page auteur, series, reviews
- Update faq.md: Align with current platform terminology and features
- Update publishing-guide.md: Add page auteur requirement, series, correct commissions
- Update payment-guide.md: Update wording and add commission information
- All documentation now uses consistent terminology: publication, page auteur, série, avis
- Commissions clearly explained: 800 sats (700+100), 0.046 BTC (0.042+0.004), 70 sats (49+21)
2025-12-27 23:05:33 +01:00
f182887c89 Update markdown renderer with dark theme styling
- Update headings with neon-cyan and font-mono
- Update paragraphs with cyber-accent color
- Update code blocks with dark background and neon-cyan text
- Update links with neon-green hover to neon-cyan
- Update inline code with dark background and border
- Update bold text with neon-green color
- Update lists with cyber-accent and neon-cyan markers
- All TypeScript checks pass
2025-12-27 23:02:30 +01:00
5ea0ed21e1 Update /docs page with dark theme and modern styling
- Replace DocsHeader with PageHeader and Footer
- Update DocsSidebar with dark cyberpunk theme
- Update DocsContent with dark theme and styled prose
- Use i18n for page title
- All TypeScript checks pass
2025-12-27 23:01:34 +01:00
cd7f6e04d9 Move intro section and funding gauge to bottom of page
- Remove intro text and funding gauge from top of page
- Add HomeIntroSection component at bottom of page content
- Keep CategoryTabs and SearchBar at top for better UX
- All TypeScript checks pass
2025-12-27 22:57:55 +01:00
58b35e2a67 Remove remaining @ts-expect-error comment
- Remove @ts-expect-error from _unusedExtractTags
- Mark unused parameter with underscore prefix
- All TypeScript checks pass without any control disabling comments
2025-12-27 22:29:39 +01:00
6a57868704 Restore nostrEventParsing.ts and remove control disabling comment
- Restore nostrEventParsing.ts from previous commit
- Remove @ts-expect-error comment from _unusedExtractTags
- Mark unused parameter with underscore prefix
- All TypeScript checks pass
2025-12-27 22:29:06 +01:00
2d4aaac007 Fix remaining issues after removing control disabling comments
- Restore nostrEventParsing.ts that was accidentally deleted
- Fix zapAggregation.ts type error without using any
- Mark _unusedExtractTags parameter as unused with underscore prefix
- All TypeScript checks pass
2025-12-27 22:28:29 +01:00
85e3e57ad5 Remove all control disabling comments
- Remove @ts-expect-error comment from _unusedExtractTags
- Remove eslint-disable comment from zapAggregation.ts and fix type properly
- Remove unused _unusedExtractTags function
- Remove unused decryptDecryptionKey import
- Fix extractTagsFromEvent return type to include all optional properties explicitly
- All errors fixed without disabling any controls
2025-12-27 22:27:47 +01:00
2a191f35f4 Fix all TypeScript errors and warnings
- Fix unused function warnings by renaming to _unusedExtractTags
- Fix type errors in nostrTagSystem.ts for includes() calls
- Fix type errors in reviews.ts for filter kinds array
- Fix ArrayBuffer type errors in articleEncryption.ts
- Remove unused imports (DecryptionKey, decryptArticleContent, extractTagsFromEvent)
- All TypeScript checks now pass without disabling any controls
2025-12-27 22:26:13 +01:00
9edf4ac1bc docs: Ajout règle optimisation et mise à jour systématique documentation
- Ajout section dédiée dans quality.mdc
- Règles obligatoires pour fidélité au code
- Éviter répétitions et centraliser documentation
- Mise à jour systématique lors modifications
- Optimisation continue et vérification
2025-12-27 21:34:31 +01:00
a099f3c24a docs: Fusion et simplification documentation features/
- Fusion tous documents implémentations en features.md
- Suppression documents redondants/obsolètes :
  - final-cleanup-summary.md, storage-encryption.md
  - storage-improvement-implementation.md, notifications-scope.md
  - user-profile-implementation.md, filtering-search-implementation.md
  - article-edit-delete.md, priority1-implementation.md
  - alby-integration.md, nostr-paywall-implementation.md
  - technical-doc.md (redondant avec docs/technical.md)
  - rizful-integration.md (obsolète, remplacé par Alby)
- Documentation fidèle au code actuel
- Garde zapwall4science-refactoring.md (spécifications)
- Garde series-and-media-spec.md (spécifications)
- Garde notifications-implementation.md (détails techniques)
2025-12-27 21:31:20 +01:00
9ea4965c05 docs: Fusion et simplification documentation
- Fusion tous documents commissions en technical.md
- Suppression documents redondants :
  - architecture.md, commissions.md, commission-system.md
  - commission-implementation.md, split-and-transfer.md
  - implementation-summary.md, content-delivery-verification.md
- Documentation fidèle au code actuel
- remaining-tasks.md mis à jour avec état réel
- Documentation centralisée et sans répétitions
2025-12-27 21:29:57 +01:00
f7bd7faa73 fix: Correction erreurs TypeScript, nettoyage et réorganisation documentation
- Correction toutes erreurs TypeScript :
  - Variables non utilisées supprimées
  - Types optionnels corrigés (exactOptionalPropertyTypes)
  - Imports corrigés (PLATFORM_BITCOIN_ADDRESS depuis platformConfig)
  - Gestion correcte des propriétés optionnelles

- Suppression fichiers obsolètes :
  - code-cleanup-summary.md (redondant)
  - todo-implementation*.md (todos obsolètes)
  - corrections-completed.md, fallbacks-found.md (corrections faites)
  - implementation-summary.md (redondant)
  - documentation-plan.md (plan, pas documentation)

- Suppression scripts temporaires :
  - add-ssh-key.sh
  - add-ssh-key-plink.sh

- Réorganisation documentation dans docs/ :
  - architecture.md (nouveau)
  - commissions.md (nouveau)
  - implementation-summary.md
  - remaining-tasks.md
  - split-and-transfer.md
  - commission-system.md
  - commission-implementation.md
  - content-delivery-verification.md

Toutes erreurs TypeScript corrigées, documentation centralisée.
2025-12-27 21:25:19 +01:00
4735ee71ab feat: Complétion système split et intégrations externes
- Intégration mempool.space pour vérification transactions Bitcoin :
  - Service MempoolSpaceService avec API mempool.space
  - Vérification sorties et montants pour sponsoring
  - Vérification confirmations
  - Attente confirmation avec polling

- Récupération adresses Lightning depuis profils Nostr :
  - Service LightningAddressService
  - Support lud16 et lud06 (NIP-19)
  - Cache avec TTL 1 heure
  - Intégré dans paymentPolling et reviewReward

- Mise à jour événements Nostr pour avis rémunérés :
  - Publication événement avec tags rewarded et reward_amount
  - Parsing tags dans parseReviewFromEvent
  - Vérification doublons

- Tracking sponsoring sur Nostr :
  - Service SponsoringTrackingService
  - Événements avec commissions et confirmations
  - Intégration vérification mempool.space

Toutes les fonctionnalités de split sont maintenant opérationnelles.
Seuls les transferts Lightning réels nécessitent un nœud Lightning.
2025-12-27 21:18:14 +01:00
7364d6a83e feat: Implémentation split sponsoring, avis et transfert automatique
- Split pour sponsoring (Bitcoin mainnet) :
  - Service SponsoringPaymentService avec calcul split (0.042/0.004 BTC)
  - Validation montants et adresses Bitcoin
  - Structure pour vérification transactions

- Split pour avis (Lightning) :
  - Service ReviewRewardService avec commission (49/21 sats)
  - Création invoice avec split
  - Transfert automatique reviewer portion
  - Mise à jour avis avec tag rewarded

- Système transfert automatique :
  - Service AutomaticTransferService
  - Transfert auteur portion après paiement article
  - Transfert reviewer portion après rémunération avis
  - Tracking et logs structurés

- Intégration dans paymentPolling pour articles
- Documentation complète du système

Les services sont prêts pour intégration avec nœud Lightning et services blockchain.
2025-12-27 21:13:16 +01:00