diff --git a/src/types.jl b/src/types.jl index f97e679..e4e5a63 100644 --- a/src/types.jl +++ b/src/types.jl @@ -50,17 +50,20 @@ end using Dates function Base.show(io::IO, m::MatrixMsg; muser::Union{Nothing,MatrixUser} = nothing) global user + dirforward = false if muser === nothing if isdefined(MatrixChat, :user) - direction = m.sender == user ? - " ««« " : " »»» " - else - direction = " »»» " + dirforward = m.sender == user end else - direction = " »»» " + dirforward = m.sender == muser end + # read = m.isread + read = false + direction = dirforward ? (read ? " ««« " : " <<< ") : + (read ? " »»» " : " >>> ") + d = Dates.epochms2datetime(m.timestamp + Dates.datetime2epochms(Dates.unix2datetime(0))) dtfmt = if Dates.Hour(now()) - Dates.Hour(d) < Dates.Hour(24)