28 Commits

Author SHA1 Message Date
107571c378 Remove CreateAccountModal for generation, generate account directly and show recovery step then unlock modal 2025-12-28 23:28:57 +01:00
7cfd235a00 Fix: Update PaymentModal to use custom Tailwind CSS theme colors 2025-12-28 23:21:18 +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
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
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
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
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
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
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
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
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
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
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
90ff8282f1 feat: Implémentation système de commissions systématique et incontournable
- Création lib/platformCommissions.ts : configuration centralisée des commissions
  - Articles : 800 sats (700 auteur, 100 plateforme)
  - Avis : 70 sats (49 lecteur, 21 plateforme)
  - Sponsoring : 0.046 BTC (0.042 auteur, 0.004 plateforme)

- Validation des montants à chaque étape :
  - Publication : vérification du montant avant publication
  - Paiement : vérification du montant avant acceptation
  - Erreurs explicites si montant incorrect

- Tracking des commissions sur Nostr :
  - Tags author_amount et platform_commission dans événements
  - Interface ContentDeliveryTracking étendue
  - Traçabilité complète pour audit

- Logs structurés avec informations de commission
- Documentation complète du système

Les commissions sont maintenant systématiques, validées et traçables.
2025-12-27 21:11:09 +01:00
cf5ebeb6e9 \ 2025-12-23 02:20:57 +01:00
3000872dbc refactoring
- **Motivations :** Assurer passage du lint strict et clarifier la logique paiements/publications.

- **Root causes :** Fonctions trop longues, promesses non gérées et typages WebLN/Nostr incomplets.

- **Correctifs :** Refactor PaymentModal (handlers void), extraction helpers articlePublisher, simplification polling sponsoring/zap, corrections curly et awaits.

- **Evolutions :** Nouveau module articlePublisherHelpers pour présentation/aiguillage contenu privé.

- **Page affectées :** components/PaymentModal.tsx, lib/articlePublisher.ts, lib/articlePublisherHelpers.ts, lib/paymentPolling.ts, lib/sponsoring.ts, lib/nostrZapVerification.ts et dépendances liées.
2025-12-22 17:56:00 +01:00
40fe3e9389 Initial commit 2025-12-22 09:48:57 +01:00