akveo / nebular

:boom: Customizable Angular UI Library based on Eva Design System :new_moon_with_face::sparkles:Dark Mode
https://akveo.github.io/nebular
MIT License
8.06k stars 1.51k forks source link

[Chat UI] message input "date" should allow for different date formatting #1621

Open rhuang opened 5 years ago

rhuang commented 5 years ago

Issue type

I'm submitting a ... (check one with "x")

Issue description

Current behavior:

I saw in https://github.com/akveo/nebular/blob/master/src/framework/theme/components/chat/chat-message-text.component.ts#L15 that the date input into nb-chat-message is always piped into shortTime. This is confusing if the messages span multiple days. Can something like datePipeFormat: string (https://angular.io/api/common/DatePipe#pre-defined-format-options) be added as an input as well?

Expected behavior:

The chat messages would display the date as well to prevent confusing over messages spanning multiple days.

Steps to reproduce:

Add messages to nb-chat-message where the dates span multiple days.

Other information:

npm, node, OS, Browser

<!--
Node, npm: `node --version` and `npm --version`
OS: Windows (7/8/10). Linux (incl. distribution). macOS (El Capitan? Sierra?)
Browser: Chrome/Safari/Firefox/etc?
-->
node --version
v10.16.0

npm --version
6.9.0

OS: macOS Mojave
Browser: Chrome
erickconcepcion commented 5 years ago

I want it too.

rhuang commented 5 years ago

It should also have the ability to scroll up and load more messages.

adarshmenon commented 5 years ago

Also, I am struggling to order the messages by date ascending. The UI somehow always orders it by message date descending. Any ideas?

rhuang commented 5 years ago

@adarshmenon You have to sort the messages yourself by the date.

viandanteoscuro commented 4 years ago

I need this feature. too..

piotrbrzuska commented 4 years ago

For my own perpose I change those lines of code and publish @nebular/theme to our own npm registry.

piotrbrzuska commented 4 years ago

sounds like done. this issue should be closed