-
Notifications
You must be signed in to change notification settings - Fork 1
/
config.js
55 lines (53 loc) · 935 Bytes
/
config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
const { Regex } = require('@companion-module/base')
// noinspection JSUnusedGlobalSymbols
/**
* Creates the configuration fields for web config.
*
* @access public
* @since 1.0.0
* @returns {Array} the config fields
*/
const get_config_fields = () => {
return [
{
type: 'textinput',
id: 'host',
label: 'Target IP',
width: 6,
default: '192.168.255.250',
regex: Regex.IP,
},
{
type: 'textinput',
id: 'host_port',
label: 'Target Port',
width: 6,
default: '80',
regex: Regex.PORT,
},
{
type: 'textinput',
id: 'username',
label: 'Username',
width: 6,
default: 'admin',
},
{
type: 'textinput',
id: 'password',
label: 'Password',
width: 6,
default: '',
},
{
type: 'number',
id: 'pollfreq',
label: 'Feedback polling frequency in seconds',
width: 6,
default: 10,
min: 1,
max: 300,
},
]
}
module.exports = { get_config_fields }