First Commit

This commit is contained in:
2026-04-29 16:58:09 +01:00
parent c451e72807
commit 523d5531e1
145 changed files with 6615 additions and 0 deletions

70
docs/02_database.md Normal file
View File

@@ -0,0 +1,70 @@
# Base de Dados — Firestore
## 🔐 Users
users/
userId/
email: string
username: string
themeMode: "system" | "light" | "dark"
primaryColor: string (hex)
language: "pt" | "en"
favoriteGenres: [string]
createdAt: timestamp
---
## 🎵 Songs
songs/
songId/
title: string
artist: string
url: string
coverUrl: string
userId: string
genre: string
mood: string
duration: number
createdAt: timestamp
---
## 📂 Playlists
playlists/
playlistId/
name: string
userId: string
songs: [songId]
createdAt: timestamp
---
## 💬 Chats
chats/
chatId/
participants: [userId]
lastMessage: string
updatedAt: timestamp
---
## 📨 Messages
messages/
messageId/
chatId: string
senderId: string
text: string (optional)
songId: string (optional)
timestamp: timestamp
---
## ⚡ Regras importantes
- Nunca duplicar dados desnecessários
- Usar IDs para relações
- Otimizar leituras (Firestore billing)