remove nav
This commit is contained in:
parent
3104c841df
commit
189d1023c6
@ -2,7 +2,7 @@ const preact = require('preact');
|
|||||||
const { connect } = require('preact-redux');
|
const { connect } = require('preact-redux');
|
||||||
|
|
||||||
const Main = require('./main');
|
const Main = require('./main');
|
||||||
const Nav = require('./nav');
|
// const Nav = require('./nav');
|
||||||
const Controls = require('./controls');
|
const Controls = require('./controls');
|
||||||
const Footer = require('./footer');
|
const Footer = require('./footer');
|
||||||
|
|
||||||
@ -12,7 +12,6 @@ const addState = connect(
|
|||||||
|
|
||||||
const Mnml = ({ showNav }) =>
|
const Mnml = ({ showNav }) =>
|
||||||
<div id="mnml" class={showNav ? 'nav-visible' : ''}>
|
<div id="mnml" class={showNav ? 'nav-visible' : ''}>
|
||||||
<Nav />
|
|
||||||
<Main />
|
<Main />
|
||||||
<Controls />
|
<Controls />
|
||||||
<Footer />
|
<Footer />
|
||||||
|
|||||||
@ -58,6 +58,7 @@ pub enum Event {
|
|||||||
Invite(Id),
|
Invite(Id),
|
||||||
Join(Id, String),
|
Join(Id, String),
|
||||||
Joined(Id),
|
Joined(Id),
|
||||||
|
Chat(Id, Uuid, String)
|
||||||
}
|
}
|
||||||
|
|
||||||
struct WsClient {
|
struct WsClient {
|
||||||
|
|||||||
@ -158,6 +158,28 @@ impl Connection {
|
|||||||
self.events.send(Event::Join(self.id, code))?;
|
self.events.send(Event::Join(self.id, code))?;
|
||||||
Ok(RpcMessage::Joining(()))
|
Ok(RpcMessage::Joining(()))
|
||||||
},
|
},
|
||||||
|
|
||||||
|
RpcRequest::InstanceChat { instance_id, index } => {
|
||||||
|
if !account.subscribed {
|
||||||
|
return Err(err_msg("subscribe to unlock chat"))
|
||||||
|
}
|
||||||
|
|
||||||
|
let chat = vec![
|
||||||
|
"gl",
|
||||||
|
"hf",
|
||||||
|
"gg",
|
||||||
|
"thx",
|
||||||
|
"nice",
|
||||||
|
"hmm",
|
||||||
|
"ok",
|
||||||
|
"...",
|
||||||
|
];
|
||||||
|
|
||||||
|
self.events.send(Event::Chat(self.id, instance_id, chat[index]))?;
|
||||||
|
|
||||||
|
// evnts sends to subs
|
||||||
|
Ok(RpcMessage::Joining(()))
|
||||||
|
},
|
||||||
_ => {
|
_ => {
|
||||||
// all good, let's make a tx and process
|
// all good, let's make a tx and process
|
||||||
let mut tx = db.transaction()?;
|
let mut tx = db.transaction()?;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user