mobile: fix note rendering (HTML direct) + quick actions sans doublons
Some checks failed
CI / Lint, Unit Tests & Build (push) Failing after 1m7s
CI / Deploy production (on server) (push) Has been skipped

- note/[id].tsx: contenu TipTap = HTML -> afficher directement dans WebView
  (plus d'inline MD parser - c'était la cause du contenu vide)
  + javaScriptEnabled=true explicite (requis Android)
  + gestion erreur avec message visible
  + hitSlop sur bouton retour pour meilleur tap area
- home.tsx: quick actions uniques (Note du jour / Nouvelle note / Révision)
  - retiré Carnets et Recherche qui doublaient le tab bar du bas

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
Antigravity
2026-05-29 17:14:48 +00:00
parent d06ea93f11
commit 12d1e3dfdd
2 changed files with 73 additions and 109 deletions

View File

@@ -5,7 +5,7 @@ import {
} from 'react-native'
import { SafeAreaView } from 'react-native-safe-area-context'
import { useRouter } from 'expo-router'
import { CalendarDays, Search, BookOpen, Clock, ChevronRight } from 'lucide-react-native'
import { CalendarDays, PenLine, GraduationCap, Clock, ChevronRight } from 'lucide-react-native'
import { apiFetch } from '@/lib/api'
import { ENDPOINTS } from '@/lib/config'
import { useAuthStore } from '@/lib/store'
@@ -71,7 +71,7 @@ export default function HomeScreen() {
</TouchableOpacity>
</View>
{/* Quick actions */}
{/* Quick actions — actions uniques, pas de doublons avec le tab bar */}
<View style={s.quickRow}>
<TouchableOpacity onPress={handleDailyNote} style={s.quickCard} activeOpacity={0.7}>
<View style={[s.quickIcon, { backgroundColor: '#f3ece4' }]}>
@@ -79,17 +79,17 @@ export default function HomeScreen() {
</View>
<Text style={s.quickLabel}>Note du jour</Text>
</TouchableOpacity>
<TouchableOpacity onPress={() => router.push('/(tabs)/notebooks')} style={s.quickCard} activeOpacity={0.7}>
<TouchableOpacity onPress={() => router.push('/(tabs)/search')} style={s.quickCard} activeOpacity={0.7}>
<View style={[s.quickIcon, { backgroundColor: '#edf0f7' }]}>
<BookOpen size={20} color="#5b7ec7" />
<PenLine size={20} color="#5b7ec7" />
</View>
<Text style={s.quickLabel}>Carnets</Text>
<Text style={s.quickLabel}>Nouvelle note</Text>
</TouchableOpacity>
<TouchableOpacity onPress={() => router.push('/(tabs)/search')} style={s.quickCard} activeOpacity={0.7}>
<View style={[s.quickIcon, { backgroundColor: '#eef7ed' }]}>
<Search size={20} color="#4a9b61" />
<GraduationCap size={20} color="#4a9b61" />
</View>
<Text style={s.quickLabel}>Recherche</Text>
<Text style={s.quickLabel}>Révision</Text>
</TouchableOpacity>
</View>