forked from resoai/TileBoard
-
Notifications
You must be signed in to change notification settings - Fork 0
/
config.example.js
183 lines (176 loc) · 6.41 KB
/
config.example.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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
/*
This is an example configuration file. To make your own, copy or rename this
file to config.js. That file will not be overwritten as you pull in new updates.
Make sure you use real IDs from your HA entities.
*/
var CONFIG = {
customTheme: null, //CUSTOM_THEMES.TRANSPARENT
transition: TRANSITIONS.ANIMATED_GPU,
tileSize: 150,
tileMargin: 6,
timeFormat: 24,
serverUrl: "http://localhost:8123",
wsUrl: "ws://localhost:8123/api/websocket",
passwordType: PASSWORD_TYPES.MANUAL,
password: null,
//googleApiKey: "XXXXXXXXXX", // Required if you are using Google Maps for device tracker
events: [],
pages: [
{
title: 'Main page',
bg: 'images/bg1.jpeg',
icon: 'mdi-home-outline', // home icon
head: 'head.html', // you might need to comment this out if you have a small screen and header overlaps the tiles
groups: [
{
title: 'First group',
width: 2,
height: 3,
items: [
{
position: [0, 0],
width: 2,
type: TYPES.TEXT_LIST,
id: {}, // using empty object for an unknown id
state: false, // disable state element
list: [
{
title: 'Sun.sun state',
icon: 'mdi-weather-sunny',
value: '&sun.sun.state'
},
{
title: 'Custom',
icon: 'mdi-clock-outline',
value: 'value'
}
]
},
{
position: [0, 1], // [x, y]
width: 1,
type: TYPES.SENSOR,
id: 'updater.updater',
state: '@attributes.release_notes' // custom state
}
]
},
{
title: 'Second group',
width: 2,
height: 3,
items: [
{
position: [0, 0],
width: 1,
type: TYPES.SLIDER,
//id: "input_number.volume",
id: {state: 50}, // replace it with real string id
state: false,
title: 'Custom slider',
subtitle: 'Example of subtitle',
slider: {
min: 0,
max: 100,
step: 2,
request: {
type: "call_service",
domain: "input_number",
service: "set_value",
field: "value"
}
}
},
{
position: [1, 0],
width: 1,
type: TYPES.SWITCH,
//id: "switch.lights",
id: {state: 'off'}, // replace it with real string id (e.g. "switch.lights")
state: false,
title: 'Custom switch',
icons: {'off': 'mdi-volume-off', 'on': 'mdi-volume-high'}
},
]
},
{
title: '',
width: 1,
height: 3,
items: [
{
// please read README.md for more information
// this is just an example
position: [0, 0],
height: 2, // 1 for compact
//classes: ['-compact'],
type: TYPES.WEATHER,
id: {},
state: function () {return 'Sunny'},
fields: {
icon: 'clear-day',
iconMap: { 'clear-day': 'clear'},
summary: 'Sunny',
apparentTemperature: '15',
apparentTemperatureUnit: 'C',
temperature: '18',
temperatureUnit: 'C',
//precip: '&sensor.dark_sky_precip_1.state',
//precipIntensity: '&sensor.dark_sky_precip_intensity_1.state',
//precipIntensityUnit: '&sensor.dark_sky_precip_intensity_1.attributes.unit_of_measurement',
precipProbability: '5',
precipProbabilityUnit: '%',
windSpeed: '5',
windSpeedUnit: 'kmh',
humidity: '50',
humidityUnit: '%',
//pollen: '&sensor.pollen_count_1.state',
pressure: '1024',
pressureUnit: '', //'&sensor.dark_sky_pressure_1.attributes.unit_of_measurement',
}
}
]
}
]
},
{
title: 'Second page',
bg: 'images/bg2.png',
icon: 'mdi-numeric-2-box-outline',
groups: [
{
title: '',
width: 2,
height: 3,
items: [
{
position: [0, 0],
width: 2,
title: 'Short instruction',
type: TYPES.TEXT_LIST,
id: {}, // using empty object for an unknown id
state: false, // disable state element
list: [
{
title: 'Read',
icon: 'mdi-numeric-1-box-outline',
value: 'README.md'
},
{
title: 'Ask on forum',
icon: 'mdi-numeric-2-box-outline',
value: 'home-assistant.io'
},
{
title: 'Open an issue',
icon: 'mdi-numeric-3-box-outline',
value: 'github.com'
}
]
}
]
},
]
}
],
}