实施基于 Lottie + Material 3 的暗黑奢华 + 玻璃拟态风格的现代化界面重构 主要变更: - 配色方案:深邃黑背景 + 皇家紫强调色 + 翡翠绿状态色 - 依赖升级:Lottie 6.3.0 + Material 3 1.11.0 + Blurry 4.0.1 - Lottie 动画:5 个优化的 JSON 动画文件(状态、加载、成功、刷新、空状态) - 玻璃拟态效果:半透明卡片 + 细腻边框 + 圆角设计 - 布局重构:主页、壁纸预览、相册管理、相册卡片全面重构 - 动画逻辑:HomeFragment 集成 Lottie 状态动画 - 设计规范:统一的尺寸系统(dimens.xml)和 Material 3 暗色主题 技术亮点: - 暗色主题让壁纸预览更突出 - 玻璃拟态创造深度和层次感 - Lottie 动画文件 < 50KB,性能优化 - Material 3 原生暗色主题支持 - 向后兼容旧的配色引用 文档:docs/ui-modernization-summary.md
66 lines
1.8 KiB
Groovy
66 lines
1.8 KiB
Groovy
plugins {
|
|
id 'com.android.application'
|
|
}
|
|
|
|
android {
|
|
namespace 'cn.hugh.bz.gk2'
|
|
compileSdk 34
|
|
|
|
defaultConfig {
|
|
applicationId "cn.hugh.bz.gk2"
|
|
minSdk 24
|
|
targetSdk 31
|
|
versionCode 1
|
|
versionName "1.0"
|
|
}
|
|
|
|
buildTypes {
|
|
release {
|
|
minifyEnabled false
|
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
|
}
|
|
}
|
|
|
|
compileOptions {
|
|
sourceCompatibility JavaVersion.VERSION_17
|
|
targetCompatibility JavaVersion.VERSION_17
|
|
}
|
|
}
|
|
|
|
configurations.all {
|
|
resolutionStrategy {
|
|
// 强制使用统一的 Kotlin 版本,避免依赖冲突
|
|
force 'org.jetbrains.kotlin:kotlin-stdlib:1.8.22'
|
|
eachDependency { DependencyResolveDetails details ->
|
|
if (details.requested.group == 'org.jetbrains.kotlin') {
|
|
details.useVersion '1.8.22'
|
|
}
|
|
}
|
|
// 排除已废弃的 kotlin-stdlib-jdk7 和 kotlin-stdlib-jdk8
|
|
exclude group: 'org.jetbrains.kotlin', module: 'kotlin-stdlib-jdk7'
|
|
exclude group: 'org.jetbrains.kotlin', module: 'kotlin-stdlib-jdk8'
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
implementation 'androidx.appcompat:appcompat:1.6.1'
|
|
implementation 'com.google.android.material:material:1.11.0'
|
|
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
|
|
|
|
// Glide for image loading
|
|
implementation 'com.github.bumptech.glide:glide:4.16.0'
|
|
annotationProcessor 'com.github.bumptech.glide:compiler:4.16.0'
|
|
|
|
// JSON parsing
|
|
implementation 'com.google.code.gson:gson:2.10.1'
|
|
|
|
// Permissions
|
|
implementation 'androidx.core:core:1.12.0'
|
|
|
|
// Lottie animations
|
|
implementation 'com.airbnb.android:lottie:6.3.0'
|
|
|
|
// Blur effect for glassmorphism
|
|
implementation 'jp.wasabeef:blurry:4.0.1'
|
|
}
|