@ircam/comote-helpers 1.0.1 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -0
- package/package.json +4 -1
- package/.babelrc +0 -5
- package/.github/workflows/main.yml +0 -45
- package/.history/.gitignore_20250415160643 +0 -6
- package/.history/.gitignore_20250415160723 +0 -6
- package/.history/examples/simple-webview/package-lock_20250415130242.json +0 -5109
- package/.history/examples/simple-webview/package-lock_20250416103557.json +0 -5109
- package/.history/examples/simple-webview/package_20250415130704.json +0 -26
- package/.history/examples/simple-webview/package_20250415184837.json +0 -26
- package/.history/examples/simple-webview/package_20250415190300.json +0 -23
- package/.history/examples/simple-webview/src/server_20250415105733.js +0 -20
- package/.history/examples/simple-webview/src/server_20250415184604.js +0 -20
- package/.history/examples/soundworks/package_20250415132431.json +0 -35
- package/.history/examples/soundworks/package_20250416105956.json +0 -35
- package/.history/max/CoMote/examples/simple-webview/package_20250415184836.json +0 -26
- package/.history/max/CoMote/examples/simple-webview/package_20250415185949.json +0 -23
- package/.history/max/CoMote/examples/simple-webview/package_20250415185950.json +0 -23
- package/.history/max/CoMote/package-info_20241018173608.json +0 -41
- package/.history/max/CoMote/package-info_20250416105743.json +0 -27
- package/.history/max/CoMote/package-info_20250416105826.json +0 -27
- package/.history/max/CoMote/source/comote-connect/package_20250415132759.json +0 -19
- package/.history/max/CoMote/source/comote-connect/package_20250416110158.json +0 -19
- package/.history/max/CoMote/source/comote-connect/server_20250414175059.js +0 -193
- package/.history/max/CoMote/source/comote-connect/server_20250415180549.js +0 -193
- package/.history/package_20250415143437.json +0 -26
- package/.history/package_20250416105907.json +0 -26
- package/examples/simple-webview/README.md +0 -10
- package/examples/simple-webview/build/comote-simple-webview-server.js +0 -44
- package/examples/simple-webview/package-lock.json +0 -5109
- package/examples/simple-webview/package.json +0 -23
- package/examples/simple-webview/public/favicon.ico +0 -0
- package/examples/simple-webview/public/index.html +0 -13
- package/examples/simple-webview/public/index.mjs +0 -3623
- package/examples/simple-webview/public/styles.css +0 -99
- package/examples/simple-webview/src/client.js +0 -35
- package/examples/simple-webview/src/server.js +0 -20
- package/examples/soundworks/.build/clients/components/sw-audit.js +0 -64
- package/examples/soundworks/.build/clients/components/sw-audit.js.map +0 -1
- package/examples/soundworks/.build/clients/components/sw-credits.js +0 -73
- package/examples/soundworks/.build/clients/components/sw-credits.js.map +0 -1
- package/examples/soundworks/.build/clients/player/.editorbackup/PlayerExperience.js~ +0 -131
- package/examples/soundworks/.build/clients/player/index.js +0 -116
- package/examples/soundworks/.build/clients/player/index.js.map +0 -1
- package/examples/soundworks/.build/clients/styles/app.scss +0 -79
- package/examples/soundworks/.build/clients/styles/normalize.scss +0 -359
- package/examples/soundworks/.build/clients/webview/index.js +0 -72
- package/examples/soundworks/.build/clients/webview/index.js.map +0 -1
- package/examples/soundworks/.build/public/css/app.css +0 -76
- package/examples/soundworks/.build/public/css/app.css.map +0 -1
- package/examples/soundworks/.build/public/css/normalize.css +0 -321
- package/examples/soundworks/.build/public/css/normalize.css.map +0 -1
- package/examples/soundworks/.build/public/player.js +0 -98098
- package/examples/soundworks/.build/public/player.js.map +0 -1
- package/examples/soundworks/.build/public/webview.js +0 -50725
- package/examples/soundworks/.build/public/webview.js.map +0 -1
- package/examples/soundworks/.build/server/index.js +0 -57
- package/examples/soundworks/.build/server/index.js.map +0 -1
- package/examples/soundworks/.build/server/schemas/.gitkeep +0 -1
- package/examples/soundworks/.build/server/schemas/global.js +0 -19
- package/examples/soundworks/.build/server/schemas/global.js.map +0 -1
- package/examples/soundworks/.build/server/tmpl/default.tmpl +0 -27
- package/examples/soundworks/.build/utils/catch-unhandled-errors.js +0 -9
- package/examples/soundworks/.build/utils/catch-unhandled-errors.js.map +0 -1
- package/examples/soundworks/.editorconfig +0 -12
- package/examples/soundworks/.eslintrc +0 -3
- package/examples/soundworks/.soundworks +0 -7
- package/examples/soundworks/.vendors/public/webcomponentsjs/CHANGELOG.md +0 -76
- package/examples/soundworks/.vendors/public/webcomponentsjs/LICENSE.md +0 -19
- package/examples/soundworks/.vendors/public/webcomponentsjs/README.md +0 -259
- package/examples/soundworks/.vendors/public/webcomponentsjs/bundles/webcomponents-ce.js +0 -63
- package/examples/soundworks/.vendors/public/webcomponentsjs/bundles/webcomponents-ce.js.map +0 -1
- package/examples/soundworks/.vendors/public/webcomponentsjs/bundles/webcomponents-pf_dom.js +0 -62
- package/examples/soundworks/.vendors/public/webcomponentsjs/bundles/webcomponents-pf_dom.js.map +0 -1
- package/examples/soundworks/.vendors/public/webcomponentsjs/bundles/webcomponents-pf_js.js +0 -95
- package/examples/soundworks/.vendors/public/webcomponentsjs/bundles/webcomponents-pf_js.js.map +0 -1
- package/examples/soundworks/.vendors/public/webcomponentsjs/bundles/webcomponents-sd-ce-pf.js +0 -374
- package/examples/soundworks/.vendors/public/webcomponentsjs/bundles/webcomponents-sd-ce-pf.js.map +0 -1
- package/examples/soundworks/.vendors/public/webcomponentsjs/bundles/webcomponents-sd-ce.js +0 -240
- package/examples/soundworks/.vendors/public/webcomponentsjs/bundles/webcomponents-sd-ce.js.map +0 -1
- package/examples/soundworks/.vendors/public/webcomponentsjs/bundles/webcomponents-sd.js +0 -196
- package/examples/soundworks/.vendors/public/webcomponentsjs/bundles/webcomponents-sd.js.map +0 -1
- package/examples/soundworks/.vendors/public/webcomponentsjs/custom-elements-es5-adapter.js +0 -15
- package/examples/soundworks/.vendors/public/webcomponentsjs/package.json +0 -51
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/entrypoints/custom-elements-es5-adapter-index.js +0 -16
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/entrypoints/webcomponents-bundle-index.js +0 -55
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/entrypoints/webcomponents-ce-index.js +0 -17
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/entrypoints/webcomponents-pf_dom-index.js +0 -19
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/entrypoints/webcomponents-pf_js-index.js +0 -13
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/entrypoints/webcomponents-sd-ce-index.js +0 -19
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/entrypoints/webcomponents-sd-ce-pf-index.js +0 -25
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/entrypoints/webcomponents-sd-index.js +0 -18
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/flag-parser.js +0 -69
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/baseuri.js +0 -28
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/child-node/after.js +0 -47
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/child-node/before.js +0 -40
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/child-node/index.js +0 -14
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/child-node/remove.js +0 -37
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/child-node/replace-with.js +0 -42
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/custom-event.js +0 -79
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/es6-misc.js +0 -38
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/event-listener-options.js +0 -122
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/get-attribute-names.js +0 -27
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/matches.js +0 -21
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/parent-node/append.js +0 -31
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/parent-node/index.js +0 -13
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/parent-node/prepend.js +0 -42
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/parent-node/replace-children.js +0 -45
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/promise.js +0 -50
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/svg-element-class-list.js +0 -28
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/symbol.js +0 -64
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/platform/toggle-attribute.js +0 -39
- package/examples/soundworks/.vendors/public/webcomponentsjs/src/unresolved.js +0 -32
- package/examples/soundworks/.vendors/public/webcomponentsjs/webcomponents-bundle.d.ts +0 -175
- package/examples/soundworks/.vendors/public/webcomponentsjs/webcomponents-bundle.js +0 -384
- package/examples/soundworks/.vendors/public/webcomponentsjs/webcomponents-bundle.js.map +0 -1
- package/examples/soundworks/.vendors/public/webcomponentsjs/webcomponents-loader.js +0 -238
- package/examples/soundworks/LICENSE +0 -28
- package/examples/soundworks/README.md +0 -26
- package/examples/soundworks/config/application.yaml +0 -8
- package/examples/soundworks/config/env-default.yaml +0 -12
- package/examples/soundworks/package.json +0 -35
- package/examples/soundworks/public/favicon.ico +0 -0
- package/examples/soundworks/public/images/loader.gif +0 -0
- package/examples/soundworks/src/clients/components/sw-audit.js +0 -78
- package/examples/soundworks/src/clients/components/sw-credits.js +0 -80
- package/examples/soundworks/src/clients/player/.editorbackup/PlayerExperience.js~ +0 -131
- package/examples/soundworks/src/clients/player/index.js +0 -118
- package/examples/soundworks/src/clients/styles/app.scss +0 -79
- package/examples/soundworks/src/clients/styles/normalize.scss +0 -359
- package/examples/soundworks/src/clients/webview/index.js +0 -78
- package/examples/soundworks/src/server/index.js +0 -62
- package/examples/soundworks/src/server/schemas/.gitkeep +0 -1
- package/examples/soundworks/src/server/schemas/global.js +0 -18
- package/examples/soundworks/src/server/tmpl/default.tmpl +0 -27
- package/examples/soundworks/src/utils/catch-unhandled-errors.js +0 -9
- package/index.html +0 -51
- package/max/CoMote/docs/sw.shared-state.maxref.xml +0 -95
- package/max/CoMote/examples/simple-webview/README.md +0 -10
- package/max/CoMote/examples/simple-webview/build/comote-simple-webview-server.js +0 -44
- package/max/CoMote/examples/simple-webview/comote-simple-webview-server.maxpat +0 -186
- package/max/CoMote/examples/simple-webview/package-lock.json +0 -5109
- package/max/CoMote/examples/simple-webview/package.json +0 -23
- package/max/CoMote/examples/simple-webview/public/favicon.ico +0 -0
- package/max/CoMote/examples/simple-webview/public/index.html +0 -13
- package/max/CoMote/examples/simple-webview/public/index.mjs +0 -3623
- package/max/CoMote/examples/simple-webview/public/styles.css +0 -99
- package/max/CoMote/examples/simple-webview/src/client.js +0 -35
- package/max/CoMote/examples/simple-webview/src/server.js +0 -20
- package/max/CoMote/examples/soundworks/.editorconfig +0 -12
- package/max/CoMote/examples/soundworks/.eslintrc +0 -3
- package/max/CoMote/examples/soundworks/.soundworks +0 -7
- package/max/CoMote/examples/soundworks/LICENSE +0 -28
- package/max/CoMote/examples/soundworks/README.md +0 -26
- package/max/CoMote/examples/soundworks/config/application.yaml +0 -8
- package/max/CoMote/examples/soundworks/config/env-default.yaml +0 -12
- package/max/CoMote/examples/soundworks/package.json +0 -35
- package/max/CoMote/examples/soundworks/public/favicon.ico +0 -0
- package/max/CoMote/examples/soundworks/public/images/loader.gif +0 -0
- package/max/CoMote/examples/soundworks/src/clients/components/sw-audit.js +0 -78
- package/max/CoMote/examples/soundworks/src/clients/components/sw-credits.js +0 -80
- package/max/CoMote/examples/soundworks/src/clients/player/.editorbackup/PlayerExperience.js~ +0 -131
- package/max/CoMote/examples/soundworks/src/clients/player/index.js +0 -118
- package/max/CoMote/examples/soundworks/src/clients/styles/app.scss +0 -79
- package/max/CoMote/examples/soundworks/src/clients/styles/normalize.scss +0 -359
- package/max/CoMote/examples/soundworks/src/clients/webview/index.js +0 -78
- package/max/CoMote/examples/soundworks/src/server/index.js +0 -62
- package/max/CoMote/examples/soundworks/src/server/schemas/.gitkeep +0 -1
- package/max/CoMote/examples/soundworks/src/server/schemas/global.js +0 -18
- package/max/CoMote/examples/soundworks/src/server/tmpl/default.tmpl +0 -27
- package/max/CoMote/examples/soundworks/src/utils/catch-unhandled-errors.js +0 -9
- package/max/CoMote/extras/CoMote.maxpat +0 -1994
- package/max/CoMote/help/comote_osc_receive.maxhelp +0 -946
- package/max/CoMote/icon.png +0 -0
- package/max/CoMote/init/objectmappings.txt +0 -2
- package/max/CoMote/media/comote-screenshot.png +0 -0
- package/max/CoMote/package-info.json +0 -27
- package/max/CoMote/patchers/comote-connect/comote-connect-public/comote-connect-client.mjs +0 -2821
- package/max/CoMote/patchers/comote-connect/comote-connect-public/favicon.ico +0 -0
- package/max/CoMote/patchers/comote-connect/comote-connect-public/index.html +0 -22
- package/max/CoMote/patchers/comote-connect/comote-connect-server.js +0 -24775
- package/max/CoMote/patchers/comote-connect/comote-connect.maxpat +0 -1048
- package/max/CoMote/patchers/comote-connect/package.json +0 -4
- package/max/CoMote/patchers/comote_format_from_comote_v2.maxpat +0 -613
- package/max/CoMote/patchers/comote_format_from_v3.maxpat +0 -443
- package/max/CoMote/patchers/comote_format_gyro_v2_to_v3.maxpat +0 -240
- package/max/CoMote/patchers/comote_format_gyro_v3_to_v2.maxpat +0 -240
- package/max/CoMote/patchers/comote_format_heading_v2_to_v3.maxpat +0 -171
- package/max/CoMote/patchers/comote_osc_receive.maxpat +0 -440
- package/max/CoMote/patchers/comote_osc_to_list.maxpat +0 -161
- package/max/CoMote/readme.md +0 -22
- package/max/CoMote/source/comote-connect/client.js +0 -104
- package/max/CoMote/source/comote-connect/package-lock.json +0 -591
- package/max/CoMote/source/comote-connect/package.json +0 -19
- package/max/CoMote/source/comote-connect/server.js +0 -193
- package/max-update.bash +0 -44
|
@@ -1,118 +0,0 @@
|
|
|
1
|
-
import '@soundworks/helpers/polyfills.js';
|
|
2
|
-
import { Client } from '@soundworks/core/client.js';
|
|
3
|
-
import { loadConfig, launcher } from '@soundworks/helpers/browser.js';
|
|
4
|
-
import { html, render } from 'lit';
|
|
5
|
-
|
|
6
|
-
import '../components/sw-credits.js';
|
|
7
|
-
import * as CoMoteQRCode from '@ircam/comote-helpers/qrcode.js';
|
|
8
|
-
|
|
9
|
-
import '@ircam/sc-components/sc-text.js';
|
|
10
|
-
import '@ircam/sc-components/sc-toggle.js';
|
|
11
|
-
import '@ircam/sc-components/sc-editor.js';
|
|
12
|
-
import '@ircam/sc-components/sc-tab.js';
|
|
13
|
-
|
|
14
|
-
// - General documentation: https://soundworks.dev/
|
|
15
|
-
// - API documentation: https://soundworks.dev/api
|
|
16
|
-
// - Issue Tracker: https://github.com/collective-soundworks/soundworks/issues
|
|
17
|
-
// - Wizard & Tools: `npx soundworks`
|
|
18
|
-
|
|
19
|
-
async function main($container) {
|
|
20
|
-
/**
|
|
21
|
-
* Load configuration from config files and create the soundworks client
|
|
22
|
-
*/
|
|
23
|
-
const config = loadConfig();
|
|
24
|
-
const client = new Client(config);
|
|
25
|
-
launcher.register(client, { initScreensContainer: $container });
|
|
26
|
-
|
|
27
|
-
await client.start();
|
|
28
|
-
|
|
29
|
-
const global = await client.stateManager.attach('global');
|
|
30
|
-
|
|
31
|
-
let qrCode;
|
|
32
|
-
let data = {};
|
|
33
|
-
let buttonA = false;
|
|
34
|
-
let buttonB = false;
|
|
35
|
-
let control = {};
|
|
36
|
-
|
|
37
|
-
global.onUpdate(async updates => {
|
|
38
|
-
if ('comoteConfig' in updates) {
|
|
39
|
-
qrCode = await CoMoteQRCode.dataURL(updates.comoteConfig);
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
if ('data' in updates) {
|
|
43
|
-
({data} = updates);
|
|
44
|
-
|
|
45
|
-
if ('control' in updates.data) {
|
|
46
|
-
control = updates.data.control;
|
|
47
|
-
|
|
48
|
-
if ('buttonA' in updates.data.control) {
|
|
49
|
-
buttonA = !!updates.data.control.buttonA;
|
|
50
|
-
} else if ('buttonB' in updates.data.control) {
|
|
51
|
-
buttonB = !!updates.data.control.buttonB;
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
renderApp();
|
|
57
|
-
}, true);
|
|
58
|
-
|
|
59
|
-
function renderApp() {
|
|
60
|
-
render(html`
|
|
61
|
-
<div style="padding: 20px">
|
|
62
|
-
<h1 style="margin: 20px 0">CoMote dashboard</h1>
|
|
63
|
-
|
|
64
|
-
<div style="margin-bottom: 10px;">
|
|
65
|
-
<sc-text>WiFi infos</sc-text>
|
|
66
|
-
<sc-text style="height: 80px;">${JSON.stringify(global.get('wifiInfos'), null, 2)}</sc-text>
|
|
67
|
-
</div>
|
|
68
|
-
<div style="margin-bottom: 10px;">
|
|
69
|
-
<sc-text>Settings</sc-text>
|
|
70
|
-
<sc-editor
|
|
71
|
-
value=${JSON.stringify(global.get('comoteConfig'), null, 2)}
|
|
72
|
-
@change=${e => global.set({ comoteConfig: JSON.parse(e.detail.value) })}
|
|
73
|
-
></sc-editor>
|
|
74
|
-
</div>
|
|
75
|
-
|
|
76
|
-
<div style="display: inline-block; vertical-align: top; margin-right: 12px">
|
|
77
|
-
<sc-text style="display: block; margin-bottom: 4px;">Flash QR to retrieve settings in CoMote</sc-text>
|
|
78
|
-
<img src=${qrCode} width="300" height="300" style="image-rendering: pixelated;"/>
|
|
79
|
-
</div>
|
|
80
|
-
|
|
81
|
-
<div style="display: inline-block; vertical-align: top; margin-right: 12px">
|
|
82
|
-
<sc-text style="width: 300px; height: 350px">${JSON.stringify(data, null, 2)}</sc-text>
|
|
83
|
-
</div>
|
|
84
|
-
|
|
85
|
-
<div style="display: inline-block; vertical-align: top; margin-right: 12px">
|
|
86
|
-
<div style="margin-bottom: 6px">
|
|
87
|
-
<sc-text>buttonA</sc-text>
|
|
88
|
-
<sc-toggle .active=${buttonA}></sc-toggle>
|
|
89
|
-
</div>
|
|
90
|
-
<div style="margin-bottom: 6px">
|
|
91
|
-
<sc-text>buttonB</sc-text>
|
|
92
|
-
<sc-toggle .active=${buttonB}></sc-toggle>
|
|
93
|
-
</div>
|
|
94
|
-
<div style="margin-bottom: 6px">
|
|
95
|
-
<sc-text>Arbitrary control (webview)</sc-text>
|
|
96
|
-
<sc-text>${JSON.stringify(control)}</sc-text>
|
|
97
|
-
</div>
|
|
98
|
-
</div>
|
|
99
|
-
|
|
100
|
-
<div style="margin-top: 12px">
|
|
101
|
-
<sc-text>webview page</sc-text>
|
|
102
|
-
<sc-tab
|
|
103
|
-
.options=${['1', '2']}
|
|
104
|
-
value=${global.get('webviewPage')}
|
|
105
|
-
@change=${e => global.set({ webviewPage: e.detail.value })}
|
|
106
|
-
></sc-tab>
|
|
107
|
-
</div>
|
|
108
|
-
</div>
|
|
109
|
-
`, $container);
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
// The launcher enables instanciation of multiple clients in the same page to
|
|
114
|
-
// facilitate development and testing.
|
|
115
|
-
// e.g. `http://127.0.0.1:8000?emulate=10` to run 10 clients side-by-side
|
|
116
|
-
launcher.execute(main, {
|
|
117
|
-
numClients: parseInt(new URLSearchParams(window.location.search).get('emulate')) || 1,
|
|
118
|
-
});
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
:root {
|
|
2
|
-
--sw-background-color: #000000;
|
|
3
|
-
--sw-medium-background-color: #121212;
|
|
4
|
-
--sw-light-background-color: #242424;
|
|
5
|
-
--sw-lighter-background-color: #363636;
|
|
6
|
-
--sw-font-color: #ffffff;
|
|
7
|
-
--sw-light-font-color: #cccccc;
|
|
8
|
-
--sw-font-color-error: #a94442;
|
|
9
|
-
--sw-font-family: Consolas, monaco, monospace;
|
|
10
|
-
--sw-font-size: 62.5%; // such that 1rem == 10px
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
html, body {
|
|
14
|
-
width: 100%;
|
|
15
|
-
min-height: 100vh;
|
|
16
|
-
background-color: var(--sw-background-color);
|
|
17
|
-
color: var(--sw-font-color);
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
html {
|
|
21
|
-
font-size: var(--sw-font-size);
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
body {
|
|
25
|
-
display: flex;
|
|
26
|
-
flex-wrap: wrap;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
* {
|
|
30
|
-
box-sizing: border-box;
|
|
31
|
-
font-family: var(--sw-font-family);
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
body.loading {
|
|
35
|
-
background-image: url(../../images/loader.gif);
|
|
36
|
-
background-position: 50% 50%;
|
|
37
|
-
background-repeat: no-repeat;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
.simple-layout {
|
|
41
|
-
display: block;
|
|
42
|
-
flex-grow: 1;
|
|
43
|
-
padding: 20px;
|
|
44
|
-
position: relative;
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
// default styles for controller layout
|
|
48
|
-
.controller-layout {
|
|
49
|
-
display: block;
|
|
50
|
-
flex-grow: 1;
|
|
51
|
-
position: relative;
|
|
52
|
-
|
|
53
|
-
& > header {
|
|
54
|
-
display: block;
|
|
55
|
-
height: 38px;
|
|
56
|
-
line-height: 38px;
|
|
57
|
-
background-color: var(--sw-medium-background-color);
|
|
58
|
-
display: flex;
|
|
59
|
-
flex-direction: row;
|
|
60
|
-
justify-content: space-between;
|
|
61
|
-
border-bottom: 1px solid var(--sw-lighter-background-color);
|
|
62
|
-
|
|
63
|
-
h1 {
|
|
64
|
-
font-size: 12px;
|
|
65
|
-
margin: 0;
|
|
66
|
-
padding-left: 20px;
|
|
67
|
-
max-width: 50%;
|
|
68
|
-
overflow: hidden;
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
sc-audit {
|
|
72
|
-
max-width: 50%;
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
& > section {
|
|
77
|
-
padding: 20px;
|
|
78
|
-
}
|
|
79
|
-
}
|
|
@@ -1,359 +0,0 @@
|
|
|
1
|
-
/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */
|
|
2
|
-
/*
|
|
3
|
-
The MIT License (MIT)
|
|
4
|
-
Copyright © Nicolas Gallagher and Jonathan Neal
|
|
5
|
-
|
|
6
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
7
|
-
|
|
8
|
-
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
|
9
|
-
|
|
10
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
11
|
-
*/
|
|
12
|
-
|
|
13
|
-
/* Document
|
|
14
|
-
========================================================================== */
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* 1. Correct the line height in all browsers.
|
|
18
|
-
* 2. Prevent adjustments of font size after orientation changes in iOS.
|
|
19
|
-
*/
|
|
20
|
-
|
|
21
|
-
html {
|
|
22
|
-
line-height: 1.15; /* 1 */
|
|
23
|
-
-webkit-text-size-adjust: 100%; /* 2 */
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
/* Sections
|
|
27
|
-
========================================================================== */
|
|
28
|
-
|
|
29
|
-
/**
|
|
30
|
-
* Remove the margin in all browsers.
|
|
31
|
-
*/
|
|
32
|
-
|
|
33
|
-
body {
|
|
34
|
-
margin: 0;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
/**
|
|
38
|
-
* Render the `main` element consistently in IE.
|
|
39
|
-
*/
|
|
40
|
-
|
|
41
|
-
main {
|
|
42
|
-
display: block;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
/**
|
|
46
|
-
* Correct the font size and margin on `h1` elements within `section` and
|
|
47
|
-
* `article` contexts in Chrome, Firefox, and Safari.
|
|
48
|
-
*/
|
|
49
|
-
|
|
50
|
-
h1 {
|
|
51
|
-
font-size: 2em;
|
|
52
|
-
margin: 0.67em 0;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
/* Grouping content
|
|
56
|
-
========================================================================== */
|
|
57
|
-
|
|
58
|
-
/**
|
|
59
|
-
* 1. Add the correct box sizing in Firefox.
|
|
60
|
-
* 2. Show the overflow in Edge and IE.
|
|
61
|
-
*/
|
|
62
|
-
|
|
63
|
-
hr {
|
|
64
|
-
box-sizing: content-box; /* 1 */
|
|
65
|
-
height: 0; /* 1 */
|
|
66
|
-
overflow: visible; /* 2 */
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
/**
|
|
70
|
-
* 1. Correct the inheritance and scaling of font size in all browsers.
|
|
71
|
-
* 2. Correct the odd `em` font sizing in all browsers.
|
|
72
|
-
*/
|
|
73
|
-
|
|
74
|
-
pre {
|
|
75
|
-
font-family: monospace, monospace; /* 1 */
|
|
76
|
-
font-size: 1em; /* 2 */
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
/* Text-level semantics
|
|
80
|
-
========================================================================== */
|
|
81
|
-
|
|
82
|
-
/**
|
|
83
|
-
* Remove the gray background on active links in IE 10.
|
|
84
|
-
*/
|
|
85
|
-
|
|
86
|
-
a {
|
|
87
|
-
background-color: transparent;
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
/**
|
|
91
|
-
* 1. Remove the bottom border in Chrome 57-
|
|
92
|
-
* 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.
|
|
93
|
-
*/
|
|
94
|
-
|
|
95
|
-
abbr[title] {
|
|
96
|
-
border-bottom: none; /* 1 */
|
|
97
|
-
text-decoration: underline; /* 2 */
|
|
98
|
-
text-decoration: underline dotted; /* 2 */
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
/**
|
|
102
|
-
* Add the correct font weight in Chrome, Edge, and Safari.
|
|
103
|
-
*/
|
|
104
|
-
|
|
105
|
-
b,
|
|
106
|
-
strong {
|
|
107
|
-
font-weight: bolder;
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
/**
|
|
111
|
-
* 1. Correct the inheritance and scaling of font size in all browsers.
|
|
112
|
-
* 2. Correct the odd `em` font sizing in all browsers.
|
|
113
|
-
*/
|
|
114
|
-
|
|
115
|
-
code,
|
|
116
|
-
kbd,
|
|
117
|
-
samp {
|
|
118
|
-
font-family: monospace, monospace; /* 1 */
|
|
119
|
-
font-size: 1em; /* 2 */
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
/**
|
|
123
|
-
* Add the correct font size in all browsers.
|
|
124
|
-
*/
|
|
125
|
-
|
|
126
|
-
small {
|
|
127
|
-
font-size: 80%;
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
/**
|
|
131
|
-
* Prevent `sub` and `sup` elements from affecting the line height in
|
|
132
|
-
* all browsers.
|
|
133
|
-
*/
|
|
134
|
-
|
|
135
|
-
sub,
|
|
136
|
-
sup {
|
|
137
|
-
font-size: 75%;
|
|
138
|
-
line-height: 0;
|
|
139
|
-
position: relative;
|
|
140
|
-
vertical-align: baseline;
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
sub {
|
|
144
|
-
bottom: -0.25em;
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
sup {
|
|
148
|
-
top: -0.5em;
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
/* Embedded content
|
|
152
|
-
========================================================================== */
|
|
153
|
-
|
|
154
|
-
/**
|
|
155
|
-
* Remove the border on images inside links in IE 10.
|
|
156
|
-
*/
|
|
157
|
-
|
|
158
|
-
img {
|
|
159
|
-
border-style: none;
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
/* Forms
|
|
163
|
-
========================================================================== */
|
|
164
|
-
|
|
165
|
-
/**
|
|
166
|
-
* 1. Change the font styles in all browsers.
|
|
167
|
-
* 2. Remove the margin in Firefox and Safari.
|
|
168
|
-
*/
|
|
169
|
-
|
|
170
|
-
button,
|
|
171
|
-
input,
|
|
172
|
-
optgroup,
|
|
173
|
-
select,
|
|
174
|
-
textarea {
|
|
175
|
-
font-family: inherit; /* 1 */
|
|
176
|
-
font-size: 100%; /* 1 */
|
|
177
|
-
line-height: 1.15; /* 1 */
|
|
178
|
-
margin: 0; /* 2 */
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
/**
|
|
182
|
-
* Show the overflow in IE.
|
|
183
|
-
* 1. Show the overflow in Edge.
|
|
184
|
-
*/
|
|
185
|
-
|
|
186
|
-
button,
|
|
187
|
-
input { /* 1 */
|
|
188
|
-
overflow: visible;
|
|
189
|
-
}
|
|
190
|
-
|
|
191
|
-
/**
|
|
192
|
-
* Remove the inheritance of text transform in Edge, Firefox, and IE.
|
|
193
|
-
* 1. Remove the inheritance of text transform in Firefox.
|
|
194
|
-
*/
|
|
195
|
-
|
|
196
|
-
button,
|
|
197
|
-
select { /* 1 */
|
|
198
|
-
text-transform: none;
|
|
199
|
-
}
|
|
200
|
-
|
|
201
|
-
/**
|
|
202
|
-
* Correct the inability to style clickable types in iOS and Safari.
|
|
203
|
-
*/
|
|
204
|
-
|
|
205
|
-
button,
|
|
206
|
-
[type="button"],
|
|
207
|
-
[type="reset"],
|
|
208
|
-
[type="submit"] {
|
|
209
|
-
-webkit-appearance: button;
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
/**
|
|
213
|
-
* Remove the inner border and padding in Firefox.
|
|
214
|
-
*/
|
|
215
|
-
|
|
216
|
-
button::-moz-focus-inner,
|
|
217
|
-
[type="button"]::-moz-focus-inner,
|
|
218
|
-
[type="reset"]::-moz-focus-inner,
|
|
219
|
-
[type="submit"]::-moz-focus-inner {
|
|
220
|
-
border-style: none;
|
|
221
|
-
padding: 0;
|
|
222
|
-
}
|
|
223
|
-
|
|
224
|
-
/**
|
|
225
|
-
* Restore the focus styles unset by the previous rule.
|
|
226
|
-
*/
|
|
227
|
-
|
|
228
|
-
button:-moz-focusring,
|
|
229
|
-
[type="button"]:-moz-focusring,
|
|
230
|
-
[type="reset"]:-moz-focusring,
|
|
231
|
-
[type="submit"]:-moz-focusring {
|
|
232
|
-
outline: 1px dotted ButtonText;
|
|
233
|
-
}
|
|
234
|
-
|
|
235
|
-
/**
|
|
236
|
-
* Correct the padding in Firefox.
|
|
237
|
-
*/
|
|
238
|
-
|
|
239
|
-
fieldset {
|
|
240
|
-
padding: 0.35em 0.75em 0.625em;
|
|
241
|
-
}
|
|
242
|
-
|
|
243
|
-
/**
|
|
244
|
-
* 1. Correct the text wrapping in Edge and IE.
|
|
245
|
-
* 2. Correct the color inheritance from `fieldset` elements in IE.
|
|
246
|
-
* 3. Remove the padding so developers are not caught out when they zero out
|
|
247
|
-
* `fieldset` elements in all browsers.
|
|
248
|
-
*/
|
|
249
|
-
|
|
250
|
-
legend {
|
|
251
|
-
box-sizing: border-box; /* 1 */
|
|
252
|
-
color: inherit; /* 2 */
|
|
253
|
-
display: table; /* 1 */
|
|
254
|
-
max-width: 100%; /* 1 */
|
|
255
|
-
padding: 0; /* 3 */
|
|
256
|
-
white-space: normal; /* 1 */
|
|
257
|
-
}
|
|
258
|
-
|
|
259
|
-
/**
|
|
260
|
-
* Add the correct vertical alignment in Chrome, Firefox, and Opera.
|
|
261
|
-
*/
|
|
262
|
-
|
|
263
|
-
progress {
|
|
264
|
-
vertical-align: baseline;
|
|
265
|
-
}
|
|
266
|
-
|
|
267
|
-
/**
|
|
268
|
-
* Remove the default vertical scrollbar in IE 10+.
|
|
269
|
-
*/
|
|
270
|
-
|
|
271
|
-
textarea {
|
|
272
|
-
overflow: auto;
|
|
273
|
-
}
|
|
274
|
-
|
|
275
|
-
/**
|
|
276
|
-
* 1. Add the correct box sizing in IE 10.
|
|
277
|
-
* 2. Remove the padding in IE 10.
|
|
278
|
-
*/
|
|
279
|
-
|
|
280
|
-
[type="checkbox"],
|
|
281
|
-
[type="radio"] {
|
|
282
|
-
box-sizing: border-box; /* 1 */
|
|
283
|
-
padding: 0; /* 2 */
|
|
284
|
-
}
|
|
285
|
-
|
|
286
|
-
/**
|
|
287
|
-
* Correct the cursor style of increment and decrement buttons in Chrome.
|
|
288
|
-
*/
|
|
289
|
-
|
|
290
|
-
[type="number"]::-webkit-inner-spin-button,
|
|
291
|
-
[type="number"]::-webkit-outer-spin-button {
|
|
292
|
-
height: auto;
|
|
293
|
-
}
|
|
294
|
-
|
|
295
|
-
/**
|
|
296
|
-
* 1. Correct the odd appearance in Chrome and Safari.
|
|
297
|
-
* 2. Correct the outline style in Safari.
|
|
298
|
-
*/
|
|
299
|
-
|
|
300
|
-
[type="search"] {
|
|
301
|
-
-webkit-appearance: textfield; /* 1 */
|
|
302
|
-
outline-offset: -2px; /* 2 */
|
|
303
|
-
}
|
|
304
|
-
|
|
305
|
-
/**
|
|
306
|
-
* Remove the inner padding in Chrome and Safari on macOS.
|
|
307
|
-
*/
|
|
308
|
-
|
|
309
|
-
[type="search"]::-webkit-search-decoration {
|
|
310
|
-
-webkit-appearance: none;
|
|
311
|
-
}
|
|
312
|
-
|
|
313
|
-
/**
|
|
314
|
-
* 1. Correct the inability to style clickable types in iOS and Safari.
|
|
315
|
-
* 2. Change font properties to `inherit` in Safari.
|
|
316
|
-
*/
|
|
317
|
-
|
|
318
|
-
::-webkit-file-upload-button {
|
|
319
|
-
-webkit-appearance: button; /* 1 */
|
|
320
|
-
font: inherit; /* 2 */
|
|
321
|
-
}
|
|
322
|
-
|
|
323
|
-
/* Interactive
|
|
324
|
-
========================================================================== */
|
|
325
|
-
|
|
326
|
-
/*
|
|
327
|
-
* Add the correct display in Edge, IE 10+, and Firefox.
|
|
328
|
-
*/
|
|
329
|
-
|
|
330
|
-
details {
|
|
331
|
-
display: block;
|
|
332
|
-
}
|
|
333
|
-
|
|
334
|
-
/*
|
|
335
|
-
* Add the correct display in all browsers.
|
|
336
|
-
*/
|
|
337
|
-
|
|
338
|
-
summary {
|
|
339
|
-
display: list-item;
|
|
340
|
-
}
|
|
341
|
-
|
|
342
|
-
/* Misc
|
|
343
|
-
========================================================================== */
|
|
344
|
-
|
|
345
|
-
/**
|
|
346
|
-
* Add the correct display in IE 10+.
|
|
347
|
-
*/
|
|
348
|
-
|
|
349
|
-
template {
|
|
350
|
-
display: none;
|
|
351
|
-
}
|
|
352
|
-
|
|
353
|
-
/**
|
|
354
|
-
* Add the correct display in IE 10.
|
|
355
|
-
*/
|
|
356
|
-
|
|
357
|
-
[hidden] {
|
|
358
|
-
display: none;
|
|
359
|
-
}
|
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
import '@soundworks/helpers/polyfills.js';
|
|
2
|
-
import { Client } from '@soundworks/core/client.js';
|
|
3
|
-
import { loadConfig, launcher } from '@soundworks/helpers/browser.js';
|
|
4
|
-
import { html, render } from 'lit';
|
|
5
|
-
|
|
6
|
-
import '../components/sw-credits.js';
|
|
7
|
-
|
|
8
|
-
import '@ircam/sc-components/sc-button.js';
|
|
9
|
-
import '@ircam/sc-components/sc-slider.js';
|
|
10
|
-
import '@ircam/sc-components/sc-text.js';
|
|
11
|
-
import '@ircam/sc-components/sc-toggle.js';
|
|
12
|
-
|
|
13
|
-
// - General documentation: https://soundworks.dev/
|
|
14
|
-
// - API documentation: https://soundworks.dev/api
|
|
15
|
-
// - Issue Tracker: https://github.com/collective-soundworks/soundworks/issues
|
|
16
|
-
// - Wizard & Tools: `npx soundworks`
|
|
17
|
-
|
|
18
|
-
async function main($container) {
|
|
19
|
-
const config = loadConfig();
|
|
20
|
-
const client = new Client(config);
|
|
21
|
-
|
|
22
|
-
launcher.register(client, { initScreensContainer: $container });
|
|
23
|
-
|
|
24
|
-
await client.start();
|
|
25
|
-
|
|
26
|
-
const global = await client.stateManager.attach('global', ['webviewPage']);
|
|
27
|
-
global.onUpdate(updates => renderApp(), true);
|
|
28
|
-
|
|
29
|
-
function renderApp() {
|
|
30
|
-
render(html`
|
|
31
|
-
<div class="simple-layout">
|
|
32
|
-
<h1>CoMote Test WebView</h1>
|
|
33
|
-
|
|
34
|
-
${global.get('webviewPage') === '1'
|
|
35
|
-
? html`
|
|
36
|
-
<div style="margin: 4px 0;">
|
|
37
|
-
<h2>Page 1</h2>
|
|
38
|
-
<sc-text>w/ attributes</sc-text>
|
|
39
|
-
<sc-button
|
|
40
|
-
comote-key="my-button"
|
|
41
|
-
comote-touchstart="1"
|
|
42
|
-
comote-touchend="0"
|
|
43
|
-
>Simple Test</sc-button>
|
|
44
|
-
</div>
|
|
45
|
-
<div style="margin: 4px 0;">
|
|
46
|
-
<sc-text>w/ sendEvent</sc-text>
|
|
47
|
-
<sc-slider
|
|
48
|
-
@input=${e => sendEvent('my-slider', e.detail.value)}
|
|
49
|
-
></sc-slider>
|
|
50
|
-
<sc-toggle
|
|
51
|
-
@change=${e => sendEvent('my-toggle', e.detail.value)}
|
|
52
|
-
></sc-toggle>
|
|
53
|
-
</div>
|
|
54
|
-
`
|
|
55
|
-
: html`
|
|
56
|
-
<div style="margin: 4px 0;">
|
|
57
|
-
<h2>Page 2</h2>
|
|
58
|
-
<sc-text>my-second-slider</sc-text>
|
|
59
|
-
<sc-slider
|
|
60
|
-
@input=${e => sendEvent('my-second-slider', e.detail.value)}
|
|
61
|
-
></sc-slider>
|
|
62
|
-
</div>
|
|
63
|
-
`
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
<sw-credits .infos="${client.config.app}"></sw-credits>
|
|
68
|
-
</div>
|
|
69
|
-
`, $container);
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
// The launcher enables instanciation of multiple clients in the same page to
|
|
74
|
-
// facilitate development and testing.
|
|
75
|
-
// e.g. `http://127.0.0.1:8000?emulate=10` to run 10 clients side-by-side
|
|
76
|
-
launcher.execute(main, {
|
|
77
|
-
numClients: parseInt(new URLSearchParams(window.location.search).get('emulate')) || 1,
|
|
78
|
-
});
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
import '@soundworks/helpers/polyfills.js';
|
|
2
|
-
import { Server } from '@soundworks/core/server.js';
|
|
3
|
-
import { loadConfig } from '@soundworks/helpers/node.js';
|
|
4
|
-
|
|
5
|
-
import '../utils/catch-unhandled-errors.js';
|
|
6
|
-
|
|
7
|
-
import { Server as CoMoteServer } from '@ircam/comote-helpers/server.js';
|
|
8
|
-
import * as CoMoteQRCode from '@ircam/comote-helpers/qrcode.js';
|
|
9
|
-
import { getWifiInfos } from '@ircam/comote-helpers/wifi-infos.js';
|
|
10
|
-
|
|
11
|
-
import globalSchema from './schemas/global.js';
|
|
12
|
-
|
|
13
|
-
// - General documentation: https://soundworks.dev/
|
|
14
|
-
// - API documentation: https://soundworks.dev/api
|
|
15
|
-
// - Issue Tracker: https://github.com/collective-soundworks/soundworks/issues
|
|
16
|
-
// - Wizard & Tools: `npx soundworks`
|
|
17
|
-
|
|
18
|
-
const config = loadConfig(process.env.ENV, import.meta.url);
|
|
19
|
-
|
|
20
|
-
console.log(`
|
|
21
|
-
--------------------------------------------------------
|
|
22
|
-
- launching "${config.app.name}" in "${process.env.ENV || 'default'}" environment
|
|
23
|
-
- [pid: ${process.pid}]
|
|
24
|
-
--------------------------------------------------------
|
|
25
|
-
`);
|
|
26
|
-
|
|
27
|
-
const server = new Server(config);
|
|
28
|
-
server.useDefaultApplicationTemplate();
|
|
29
|
-
|
|
30
|
-
server.stateManager.registerSchema('global', globalSchema);
|
|
31
|
-
|
|
32
|
-
await server.start();
|
|
33
|
-
|
|
34
|
-
const wifiInfos = await getWifiInfos();
|
|
35
|
-
const comoteConfig = {
|
|
36
|
-
id: 0,
|
|
37
|
-
interval: 20, // period in ms
|
|
38
|
-
ws: {
|
|
39
|
-
port: 8901,
|
|
40
|
-
hostname: wifiInfos.ip,
|
|
41
|
-
autostart: true,
|
|
42
|
-
},
|
|
43
|
-
osc: null,
|
|
44
|
-
webview: `http://${wifiInfos.ip}:${config.env.port}/webview`,
|
|
45
|
-
// test raw HTML
|
|
46
|
-
// webview: `<button style="width: 500px; height: 300px;" comote-key="coucou-1" comote-touchstart="1" comote-touchend="0">Coucou</button>`
|
|
47
|
-
};
|
|
48
|
-
|
|
49
|
-
const comoteServer = new CoMoteServer(comoteConfig, { verbose: false });
|
|
50
|
-
await comoteServer.start();
|
|
51
|
-
|
|
52
|
-
// -----------------------------------------------------------
|
|
53
|
-
console.log('+ CoMote link:', CoMoteQRCode.rawLink(comoteConfig));
|
|
54
|
-
console.log('');
|
|
55
|
-
console.log(await CoMoteQRCode.terminal(comoteConfig));
|
|
56
|
-
|
|
57
|
-
const global = await server.stateManager.create('global', {
|
|
58
|
-
wifiInfos,
|
|
59
|
-
comoteConfig,
|
|
60
|
-
});
|
|
61
|
-
|
|
62
|
-
comoteServer.addWsListener(data => global.set({ data }));
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.gitkeep
|