-
Notifications
You must be signed in to change notification settings - Fork 137
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #12099 from woocommerce/12074-woo-pos-move-floatin…
…g-toolbar-to-the-home-screen-from-the-root [Woo POS] M2: Move floating toolbar to the home screen from the root
- Loading branch information
Showing
21 changed files
with
550 additions
and
613 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 22 additions & 8 deletions
30
WooCommerce/src/main/kotlin/com/woocommerce/android/ui/woopos/home/WooPosHomeState.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,27 @@ | ||
package com.woocommerce.android.ui.woopos.home | ||
|
||
sealed class WooPosHomeState { | ||
sealed class Cart : WooPosHomeState() { | ||
data object Empty : Cart() | ||
data object NotEmpty : Cart() | ||
} | ||
import com.woocommerce.android.R | ||
|
||
data class WooPosHomeState( | ||
val screenPositionState: ScreenPositionState, | ||
val exitConfirmationDialog: WooPosExitConfirmationDialog? = null, | ||
) { | ||
sealed class ScreenPositionState { | ||
sealed class Cart : ScreenPositionState() { | ||
data object Empty : Cart() | ||
data object NotEmpty : Cart() | ||
} | ||
|
||
sealed class Checkout : WooPosHomeState() { | ||
data object NotPaid : Checkout() | ||
data object Paid : Checkout() | ||
sealed class Checkout : ScreenPositionState() { | ||
data object NotPaid : Checkout() | ||
data object Paid : Checkout() | ||
} | ||
} | ||
} | ||
|
||
data object WooPosExitConfirmationDialog { | ||
val title: Int = R.string.woopos_exit_confirmation_title | ||
val message: Int = R.string.woopos_exit_confirmation_message | ||
val confirmButton: Int = R.string.woopos_exit_confirmation_confirm_button | ||
val dismissButton: Int = R.string.woopos_exit_confirmation_dismiss_button | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.