Skip to content
This repository was archived by the owner on May 6, 2024. It is now read-only.

Commit

Permalink
Implement logout (#76)
Browse files Browse the repository at this point in the history
* Fixed backnavigation

* Implement navigation about logout

* Implement search

* fixed color stable

* Fixed detekt issue
  • Loading branch information
VovaStelmashchuk authored Jun 29, 2023
1 parent a2425cc commit e3941d4
Show file tree
Hide file tree
Showing 45 changed files with 1,142 additions and 508 deletions.
10 changes: 10 additions & 0 deletions androidApp/src/androidMain/kotlin/org/mixdrinks/MainActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ class MainActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
val deepLink = intent?.data?.toString()
window.statusBarColor = android.graphics.Color.parseColor("#FF2B4718")
setContent {
MainView(deepLink)
}
Expand Down Expand Up @@ -82,6 +83,15 @@ class MainActivity : AppCompatActivity() {

override fun onStart() {
super.onStart()
firebaseAuth.currentUser?.getIdToken(true)
?.addOnCompleteListener {
it.result?.token?.let { token ->
NewToken(token)
}
}
?.addOnFailureListener {
Firebase.crashlytics.recordException(it)
}
register = registerForActivityResult(ActivityResultContracts.StartActivityForResult()) { result ->
if (result.resultCode == RESULT_OK) {
val task: Task<GoogleSignInAccount> = GoogleSignIn.getSignedInAccountFromIntent(result.data)
Expand Down
5 changes: 5 additions & 0 deletions androidApp/src/androidMain/res/drawable/ic_clear.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<vector android:height="24dp" android:tint="#000000"
android:viewportHeight="24" android:viewportWidth="24"
android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
<path android:fillColor="@android:color/white" android:pathData="M19,6.41L17.59,5 12,10.59 6.41,5 5,6.41 10.59,12 5,17.59 6.41,19 12,13.41 17.59,19 19,17.59 13.41,12z"/>
</vector>
5 changes: 5 additions & 0 deletions androidApp/src/androidMain/res/drawable/ic_search.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<vector android:height="24dp" android:tint="#000000"
android:viewportHeight="24" android:viewportWidth="24"
android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
<path android:fillColor="@android:color/white" android:pathData="M15.5,14h-0.79l-0.28,-0.27C15.41,12.59 16,11.11 16,9.5 16,5.91 13.09,3 9.5,3S3,5.91 3,9.5 5.91,16 9.5,16c1.61,0 3.09,-0.59 4.23,-1.57l0.27,0.28v0.79l5,4.99L20.49,19l-4.99,-5zM9.5,14C7.01,14 5,11.99 5,9.5S7.01,5 9.5,5 14,7.01 14,9.5 11.99,14 9.5,14z"/>
</vector>
8 changes: 8 additions & 0 deletions iosApp/.idea/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

21 changes: 21 additions & 0 deletions iosApp/.idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions iosApp/.idea/modules.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions iosApp/.idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions iosApp/.idea/xcode.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit e3941d4

Please sign in to comment.