feat: Update ProfileNavigationItem to use a rounded corner shape with increased radius

This commit is contained in:
2026-01-21 03:09:39 +05:00
parent 5145388e02
commit dcfbb020be
7 changed files with 105 additions and 42 deletions

View File

@@ -34,5 +34,8 @@ data class EncryptedAccountEntity(
val lastUsed: String? = null,
@ColumnInfo(name = "is_active")
val isActive: Boolean = true
val isActive: Boolean = true,
@ColumnInfo(name = "username")
val username: String? = null
)

View File

@@ -14,7 +14,7 @@ import androidx.sqlite.db.SupportSQLiteDatabase
DialogEntity::class,
BlacklistEntity::class
],
version = 5,
version = 6,
exportSchema = false
)
abstract class RosettaDatabase : RoomDatabase() {
@@ -35,6 +35,13 @@ abstract class RosettaDatabase : RoomDatabase() {
database.execSQL("ALTER TABLE dialogs ADD COLUMN last_message_read INTEGER NOT NULL DEFAULT 0")
}
}
private val MIGRATION_5_6 = object : Migration(5, 6) {
override fun migrate(database: SupportSQLiteDatabase) {
// Добавляем поле username в encrypted_accounts
database.execSQL("ALTER TABLE encrypted_accounts ADD COLUMN username TEXT")
}
}
fun getDatabase(context: Context): RosettaDatabase {
return INSTANCE ?: synchronized(this) {
@@ -44,7 +51,7 @@ abstract class RosettaDatabase : RoomDatabase() {
"rosetta_secure.db"
)
.setJournalMode(JournalMode.WRITE_AHEAD_LOGGING) // WAL mode for performance
.addMigrations(MIGRATION_4_5)
.addMigrations(MIGRATION_4_5, MIGRATION_5_6)
.fallbackToDestructiveMigration() // Для разработки - только если миграция не найдена
.build()
INSTANCE = instance