Support sending less_explicit_mode for app store users
This commit is contained in:
parent
039d255fe3
commit
d7d6f0503b
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,3 +1,4 @@
|
|||||||
assets/main.js
|
assets/main.js
|
||||||
dist
|
dist
|
||||||
node_modules
|
node_modules
|
||||||
|
assets/xterm.css
|
@ -29,6 +29,8 @@ function connectTerm() {
|
|||||||
const wsurl = document.location.href.replace(/^https:\/\/(.*)\/game(.html)?(\?.*)?(\#.*)?/, 'wss:\/\/$1/wsgame');
|
const wsurl = document.location.href.replace(/^https:\/\/(.*)\/game(.html)?(\?.*)?(\#.*)?/, 'wss:\/\/$1/wsgame');
|
||||||
let webSocket = new WebSocket(wsurl);
|
let webSocket = new WebSocket(wsurl);
|
||||||
webSocket.addEventListener('open', (event) => {
|
webSocket.addEventListener('open', (event) => {
|
||||||
|
if (sendLessExplicit)
|
||||||
|
webSocket.send("less_explicit_mode");
|
||||||
fit.fit();
|
fit.fit();
|
||||||
lineHandler = (l: string) => { console.log("Send handler", l); webSocket.send(l); }
|
lineHandler = (l: string) => { console.log("Send handler", l); webSocket.send(l); }
|
||||||
term.writeln("\x1b[0mConnected");
|
term.writeln("\x1b[0mConnected");
|
||||||
@ -43,7 +45,7 @@ function connectTerm() {
|
|||||||
webSocket.addEventListener('message', (msg) => {
|
webSocket.addEventListener('message', (msg) => {
|
||||||
fit.fit();
|
fit.fit();
|
||||||
term.write(msg.data);
|
term.write(msg.data);
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function over18() {
|
function over18() {
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
npx webpack
|
npx webpack
|
||||||
|
cp ./node_modules/xterm/css/xterm.css ./assets/
|
||||||
cp dist/main.js ./assets/main.js
|
cp dist/main.js ./assets/main.js
|
||||||
|
Loading…
Reference in New Issue
Block a user