-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into feature/jaino/#75
- Loading branch information
Showing
66 changed files
with
997 additions
and
222 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
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
6 changes: 6 additions & 0 deletions
6
core/model/src/main/kotlin/com/bff/wespot/model/ReportType.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 |
---|---|---|
@@ -0,0 +1,6 @@ | ||
package com.bff.wespot.model | ||
|
||
enum class ReportType { | ||
MESSAGE, | ||
VOTE, | ||
} |
8 changes: 8 additions & 0 deletions
8
core/model/src/main/kotlin/com/bff/wespot/model/auth/request/RevokeReasonListDto.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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package com.bff.wespot.model.auth.request | ||
|
||
import kotlinx.serialization.Serializable | ||
|
||
@Serializable | ||
data class RevokeReasonListDto( | ||
val revokeReasons: List<String>, | ||
) |
11 changes: 1 addition & 10 deletions
11
core/model/src/main/kotlin/com/bff/wespot/model/vote/response/IndividualReceived.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,21 +1,12 @@ | ||
package com.bff.wespot.model.vote.response | ||
|
||
import com.bff.wespot.model.user.response.ProfileCharacter | ||
|
||
data class IndividualReceived( | ||
val voteResult: ReceivedResult, | ||
) | ||
|
||
data class ReceivedResult( | ||
val voteOption: VoteOption, | ||
val user: ReceivedUser, | ||
val user: VoteUser, | ||
val rate: Int, | ||
val voteCount: Int, | ||
) | ||
|
||
data class ReceivedUser( | ||
val id: Int, | ||
val name: String, | ||
val introduction: String, | ||
val profile: ProfileCharacter, | ||
) |
10 changes: 1 addition & 9 deletions
10
core/model/src/main/kotlin/com/bff/wespot/model/vote/response/IndividualSent.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,18 +1,10 @@ | ||
package com.bff.wespot.model.vote.response | ||
|
||
import com.bff.wespot.model.user.response.ProfileCharacter | ||
|
||
data class IndividualSent( | ||
val voteResult: SentResult, | ||
) | ||
|
||
data class SentResult( | ||
val voteOption: VoteOption, | ||
val voteUsers: List<SentUser>, | ||
) | ||
|
||
data class SentUser( | ||
val id: Int, | ||
val name: String, | ||
val profile: ProfileCharacter, | ||
val voteUsers: List<VoteUser>, | ||
) |
8 changes: 0 additions & 8 deletions
8
core/model/src/main/kotlin/com/bff/wespot/model/vote/response/Profile.kt
This file was deleted.
Oops, something went wrong.
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
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
3 changes: 3 additions & 0 deletions
3
core/navigation/src/main/kotlin/com/bff/wespot/navigation/util/ExtraConstants.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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package com.bff.wespot.navigation.util | ||
|
||
const val EXTRA_TOAST_MESSAGE = "extra_toast_message" |
63 changes: 63 additions & 0 deletions
63
core/ui/src/main/kotlin/com/bff/wespot/ui/ReportBottomSheet.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 |
---|---|---|
@@ -0,0 +1,63 @@ | ||
package com.bff.wespot.ui | ||
|
||
import androidx.compose.foundation.clickable | ||
import androidx.compose.foundation.layout.Box | ||
import androidx.compose.foundation.layout.Column | ||
import androidx.compose.foundation.layout.fillMaxWidth | ||
import androidx.compose.foundation.layout.padding | ||
import androidx.compose.material3.ExperimentalMaterial3Api | ||
import androidx.compose.material3.HorizontalDivider | ||
import androidx.compose.material3.SheetState | ||
import androidx.compose.material3.Text | ||
import androidx.compose.material3.rememberModalBottomSheetState | ||
import androidx.compose.runtime.Composable | ||
import androidx.compose.ui.Alignment | ||
import androidx.compose.ui.Modifier | ||
import androidx.compose.ui.graphics.Color | ||
import androidx.compose.ui.unit.dp | ||
import com.bff.wespot.designsystem.theme.StaticTypeScale | ||
|
||
@OptIn(ExperimentalMaterial3Api::class) | ||
@Composable | ||
fun ReportBottomSheet( | ||
closeSheet: () -> Unit, | ||
sheetState: SheetState = rememberModalBottomSheetState( | ||
skipPartiallyExpanded = true, | ||
), | ||
options: List<String>, | ||
optionsClickable: List<() -> Unit>, | ||
) { | ||
require(options.size == optionsClickable.size) { | ||
"options and optionsClickable must have the same size" | ||
} | ||
|
||
WSBottomSheet(closeSheet = closeSheet, sheetState = sheetState) { | ||
Column( | ||
modifier = Modifier | ||
.fillMaxWidth() | ||
.padding(horizontal = 20.dp, vertical = 28.dp), | ||
) { | ||
options.forEachIndexed { index, option -> | ||
ReportSection(text = option, onClick = optionsClickable[index]) | ||
if (index != options.size - 1) { | ||
HorizontalDivider( | ||
color = Color(0xFF4F5157), | ||
) | ||
} | ||
} | ||
} | ||
} | ||
} | ||
|
||
@Composable | ||
private fun ReportSection(text: String, onClick: () -> Unit) { | ||
Box( | ||
modifier = Modifier | ||
.fillMaxWidth() | ||
.clickable { onClick.invoke() } | ||
.padding(vertical = 16.dp), | ||
contentAlignment = Alignment.Center, | ||
) { | ||
Text(text = text, style = StaticTypeScale.Default.body4) | ||
} | ||
} |
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
8 changes: 8 additions & 0 deletions
8
data-remote/src/main/kotlin/com/bff/wespot/data/remote/model/MessageContentDto.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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package com.bff.wespot.data.remote.model | ||
|
||
import kotlinx.serialization.Serializable | ||
|
||
@Serializable | ||
data class ProfanityDto ( | ||
val message: String, | ||
) |
10 changes: 10 additions & 0 deletions
10
data-remote/src/main/kotlin/com/bff/wespot/data/remote/model/ReportDto.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 |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package com.bff.wespot.data.remote.model | ||
|
||
import com.bff.wespot.model.ReportType | ||
import kotlinx.serialization.Serializable | ||
|
||
@Serializable | ||
data class ReportDto ( | ||
val type: ReportType, | ||
val targetId: Int, | ||
) |
8 changes: 0 additions & 8 deletions
8
...ote/src/main/kotlin/com/bff/wespot/data/remote/model/message/request/MessageContentDto.kt
This file was deleted.
Oops, something went wrong.
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
Oops, something went wrong.