mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-12-19 12:51:51 +03:00
Messages start at bottom and flow upwards
This commit is contained in:
parent
d581c20fa1
commit
cbf4a17573
@ -201,7 +201,7 @@ export class ChatScreen extends Component {
|
||||
.slice(messages.length - (50 * state.numPages), messages.length);
|
||||
}
|
||||
|
||||
let chatMessages = messages.map(this.buildMessage);
|
||||
let chatMessages = messages.reverse().map(this.buildMessage);
|
||||
let peers = props.peers[state.station] || [window.ship];
|
||||
|
||||
return (
|
||||
@ -214,7 +214,7 @@ export class ChatScreen extends Component {
|
||||
numPeers={peers.length} />
|
||||
</div>
|
||||
<div
|
||||
className="overflow-y-scroll pt3"
|
||||
className="overflow-y-scroll pt3 flex flex-column-reverse"
|
||||
style={{ height: 'calc(100% - 157px)' }}
|
||||
onScroll={this.onScroll}>
|
||||
{chatMessages}
|
||||
|
Loading…
Reference in New Issue
Block a user