diff --git a/app/src/main/java/app/myzel394/alibi/ui/components/AboutScreen/atoms/DonationsTile.kt b/app/src/main/java/app/myzel394/alibi/ui/components/AboutScreen/atoms/DonationsTile.kt
index 7e12526..1cd47f6 100644
--- a/app/src/main/java/app/myzel394/alibi/ui/components/AboutScreen/atoms/DonationsTile.kt
+++ b/app/src/main/java/app/myzel394/alibi/ui/components/AboutScreen/atoms/DonationsTile.kt
@@ -4,6 +4,7 @@ import android.content.ClipData
import android.content.ClipboardManager
import android.content.Context
import androidx.compose.animation.AnimatedVisibility
+import androidx.compose.animation.core.animateFloatAsState
import androidx.compose.animation.expandVertically
import androidx.compose.foundation.background
import androidx.compose.foundation.clickable
@@ -17,6 +18,7 @@ import androidx.compose.foundation.layout.size
import androidx.compose.foundation.lazy.LazyColumn
import androidx.compose.foundation.rememberScrollState
import androidx.compose.material.icons.Icons
+import androidx.compose.material.icons.filled.ArrowDropDown
import androidx.compose.material.icons.filled.ContentCopy
import androidx.compose.material.icons.filled.CurrencyBitcoin
import androidx.compose.material.icons.filled.CurrencyFranc
@@ -38,6 +40,7 @@ import androidx.compose.runtime.setValue
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.draw.clip
+import androidx.compose.ui.draw.rotate
import androidx.compose.ui.platform.LocalContext
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.semantics.contentDescription
@@ -69,26 +72,44 @@ fun DonationsTile() {
MaterialTheme.colorScheme.surfaceVariant
)
.padding(16.dp),
- horizontalArrangement = Arrangement.spacedBy(8.dp),
+ horizontalArrangement = Arrangement.SpaceBetween,
verticalAlignment = Alignment.CenterVertically,
) {
- Icon(
- listOf(
- Icons.Default.CurrencyBitcoin,
- Icons.Default.CurrencyFranc,
- Icons.Default.CurrencyLira,
- Icons.Default.CurrencyPound,
- Icons.Default.CurrencyRuble,
- Icons.Default.CurrencyRupee,
- Icons.Default.CurrencyYen,
- Icons.Default.CurrencyYuan,
- ).asSequence().shuffled().first(),
- contentDescription = null,
- modifier = Modifier.size(ButtonDefaults.IconSize.times(1.2f))
+ Row(
+ horizontalArrangement = Arrangement.spacedBy(8.dp),
+ verticalAlignment = Alignment.CenterVertically,
+ ) {
+ Icon(
+ listOf(
+ Icons.Default.CurrencyBitcoin,
+ Icons.Default.CurrencyFranc,
+ Icons.Default.CurrencyLira,
+ Icons.Default.CurrencyPound,
+ Icons.Default.CurrencyRuble,
+ Icons.Default.CurrencyRupee,
+ Icons.Default.CurrencyYen,
+ Icons.Default.CurrencyYuan,
+ ).asSequence().shuffled().first(),
+ contentDescription = null,
+ modifier = Modifier.size(ButtonDefaults.IconSize.times(1.2f))
+ )
+ Text(
+ stringResource(R.string.ui_about_contribute_donatation),
+ fontWeight = FontWeight.Bold,
+ )
+ }
+
+ val rotation by animateFloatAsState(
+ if (donationsOpened) -180f else 0f,
+ label = "iconRotation"
)
- Text(
- stringResource(R.string.ui_about_contribute_donatation),
- fontWeight = FontWeight.Bold,
+
+ Icon(
+ Icons.Default.ArrowDropDown,
+ contentDescription = null,
+ modifier = Modifier
+ .size(ButtonDefaults.IconSize.times(1.2f))
+ .rotate(rotation)
)
}
@@ -109,7 +130,7 @@ fun DonationsTile() {
val clip = ClipData.newPlainText("text", crypto.value)
clipboardManager.setPrimaryClip(clip)
}
- .padding(8.dp)
+ .padding(16.dp)
.horizontalScroll(rememberScrollState()),
horizontalArrangement = Arrangement.spacedBy(8.dp),
verticalAlignment = Alignment.CenterVertically,
diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml
index 6d76829..42d3aca 100644
--- a/app/src/main/res/values/strings.xml
+++ b/app/src/main/res/values/strings.xml
@@ -95,6 +95,6 @@
Open link in browser: %s
Translate Alibi into your language
Make a donation
- You can copy my GPG key here. This key only exists once and I can use it to prove to you that I\'m really who I am. Please save it now so that you don\'t fall for a phishing attack later on.
+ You can copy my GPG key here. This key only exists once and I can use it to prove to you that I\'m really who I am. Please save it now so that you can verify my signature later.
Copy GPG Key
\ No newline at end of file