Fix onChatMessage subscriber

This commit is contained in:
Alexis Faizeau 2021-10-11 18:39:34 +02:00
parent da8cc661b7
commit c29c4bfaa4

View File

@ -1,6 +1,7 @@
import { writable } from "svelte/store";
import { playersStore } from "./PlayersStore";
import type { PlayerInterface } from "../Phaser/Game/PlayerInterface";
import { iframeListener } from "../Api/IframeListener";
export const chatVisibilityStore = writable(false);
export const chatInputFocusStore = writable(false);
@ -78,6 +79,8 @@ function createChatMessagesStore() {
date: new Date(),
});
}
iframeListener.sendUserInputChat(text);
return list;
});
},
@ -94,6 +97,8 @@ function createChatMessagesStore() {
date: new Date(),
});
}
iframeListener.sendUserInputChat(text);
return list;
});
chatVisibilityStore.set(true);