mirror of
https://github.com/discourse/discourse.git
synced 2025-06-05 14:07:30 +08:00
FEATURE: Improving thread list item and header (#21749)
* Moved the settings cog from thread list to thread and put it in a new header component * Remove thread original message component, no longer needed and the list item and thread indicator styles/content will be quite different * Start adding content (unread indicator etc.) to the thread list item and changing structure to be more like designs * Serialize the last thread reply when opening the thread index, show in list and update with message bus
This commit is contained in:
@ -35,11 +35,19 @@ export default class ChatChannelsManager extends Service {
|
||||
return Object.values(this._cached);
|
||||
}
|
||||
|
||||
store(channelObject) {
|
||||
let model = this.#findStale(channelObject.id);
|
||||
store(channelObject, options = {}) {
|
||||
let model;
|
||||
|
||||
if (!options.replace) {
|
||||
model = this.#findStale(channelObject.id);
|
||||
}
|
||||
|
||||
if (!model) {
|
||||
model = ChatChannel.create(channelObject);
|
||||
if (channelObject instanceof ChatChannel) {
|
||||
model = channelObject;
|
||||
} else {
|
||||
model = ChatChannel.create(channelObject);
|
||||
}
|
||||
this.#cache(model);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user