|
|
|
@ -108,8 +108,9 @@ fun OnlineIndicator(room: RoomSummary, size: Dp, modifier: Modifier = Modifier) |
|
|
|
|
|
|
|
|
|
@Composable |
|
|
|
|
fun LastOnline(room: RoomSummary, size: TextUnit, modifier: Modifier) { |
|
|
|
|
if(room.directUserPresence?.isCurrentlyActive == true) return |
|
|
|
|
room.directUserPresence?.lastActiveAgo?.let { |
|
|
|
|
it.milliseconds.toComponents { days, hours, minutes, seconds, nanoseconds -> |
|
|
|
|
it.milliseconds.toComponents { days, hours, minutes, seconds, _ -> |
|
|
|
|
if(days > 0) "$days D" |
|
|
|
|
else if(hours > 0) "$hours H" |
|
|
|
|
else if(minutes > 0) "$minutes M" |
|
|
|
|