Skip to content

Commit

Permalink
Add color, icon and palette label (#44)
Browse files Browse the repository at this point in the history
  • Loading branch information
ottoszika committed Dec 11, 2019
1 parent 7cf6e4d commit 033112e
Show file tree
Hide file tree
Showing 10 changed files with 50 additions and 10 deletions.
6 changes: 5 additions & 1 deletion src/channel-count/channel-count.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<script type="text/javascript">
RED.nodes.registerType('ewelink-channel-count', {
category: 'eWeLink',
color: '#a6bbcf',
color: '#7bb6ef',
icon: 'font-awesome/fa-hashtag',
defaults: {
name: { value: '' },
deviceId: { value: '' },
Expand All @@ -11,6 +12,9 @@
outputs: 1,
label: function () {
return this.name || 'eWeLink Channel Count';
},
paletteLabel: function () {
return 'channels';
}
});
</script>
Expand Down
6 changes: 5 additions & 1 deletion src/devices/devices.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<script type="text/javascript">
RED.nodes.registerType('ewelink-devices', {
category: 'eWeLink',
color: '#a6bbcf',
color: '#7bb6ef',
icon: 'font-awesome/fa-microchip',
defaults: {
name: { value: '' },
auth: { value: '', type: 'ewelink-credentials' }
Expand All @@ -10,6 +11,9 @@
outputs: 1,
label: function () {
return this.name || 'eWeLink Devices';
},
paletteLabel: function () {
return 'devices';
}
});
</script>
Expand Down
6 changes: 5 additions & 1 deletion src/event-listener/event-listener.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<script type="text/javascript">
RED.nodes.registerType('ewelink-event-listener', {
category: 'eWeLink',
color: '#a6bbcf',
color: '#7bb6ef',
icon: 'bridge.png',
defaults: {
name: { value: '' },
deviceId: { value: '' },
Expand All @@ -10,6 +11,9 @@
outputs: 1,
label: function () {
return this.name || 'eWeLink Event Listener';
},
paletteLabel: function () {
return 'event listener';
}
});
</script>
Expand Down
6 changes: 5 additions & 1 deletion src/firmware-version/firmware-version.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<script type="text/javascript">
RED.nodes.registerType('ewelink-firmware-version', {
category: 'eWeLink',
color: '#a6bbcf',
color: '#7bb6ef',
icon: 'font-awesome/fa-code',
defaults: {
name: { value: '' },
deviceId: { value: '' },
Expand All @@ -11,6 +12,9 @@
outputs: 1,
label: function () {
return this.name || 'eWeLink Firmware Version';
},
paletteLabel: function () {
return 'firmware';
}
});
</script>
Expand Down
6 changes: 5 additions & 1 deletion src/generic-device/generic-device.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<script type="text/javascript">
RED.nodes.registerType('ewelink-generic-device', {
category: 'eWeLink',
color: '#a6bbcf',
color: '#7bb6ef',
icon: 'font-awesome/fa-microchip',
defaults: {
name: { value: '' },
deviceId: { value: '' },
Expand All @@ -11,6 +12,9 @@
outputs: 1,
label: function () {
return this.name || 'eWeLink Generic Device';
},
paletteLabel: function () {
return 'device';
}
});
</script>
Expand Down
6 changes: 5 additions & 1 deletion src/humidity/humidity.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<script type="text/javascript">
RED.nodes.registerType('ewelink-humidity', {
category: 'eWeLink',
color: '#a6bbcf',
color: '#7bb6ef',
icon: 'font-awesome/fa-tint',
defaults: {
name: { value: '' },
deviceId: { value: '' },
Expand All @@ -11,6 +12,9 @@
outputs: 1,
label: function () {
return this.name || 'eWeLink Humidity';
},
paletteLabel: function () {
return 'humidity';
}
});
</script>
Expand Down
6 changes: 5 additions & 1 deletion src/power-state/power-state.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<script type="text/javascript">
RED.nodes.registerType('ewelink-power-state', {
category: 'eWeLink',
color: '#a6bbcf',
color: '#7bb6ef',
icon: 'font-awesome/fa-toggle-on',
defaults: {
name: { value: '' },
deviceId: { value: '' },
Expand All @@ -12,6 +13,9 @@
outputs: 1,
label: function () {
return this.name || 'eWeLink Power State';
},
paletteLabel: function () {
return 'power state';
}
});
</script>
Expand Down
6 changes: 5 additions & 1 deletion src/power-usage/power-usage.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<script type="text/javascript">
RED.nodes.registerType('ewelink-power-usage', {
category: 'eWeLink',
color: '#a6bbcf',
color: '#7bb6ef',
icon: 'font-awesome/fa-plug',
defaults: {
name: { value: '' },
deviceId: { value: '' },
Expand All @@ -11,6 +12,9 @@
outputs: 1,
label: function () {
return this.name || 'eWeLink Power Usage';
},
paletteLabel: function () {
return 'power usage';
}
});
</script>
Expand Down
6 changes: 5 additions & 1 deletion src/temperature-humidity/temperature-humidity.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<script type="text/javascript">
RED.nodes.registerType('ewelink-temperature-humidity', {
category: 'eWeLink',
color: '#a6bbcf',
color: '#7bb6ef',
icon: 'font-awesome/fa-cloud',
defaults: {
name: { value: '' },
deviceId: { value: '' },
Expand All @@ -11,6 +12,9 @@
outputs: 1,
label: function () {
return this.name || 'eWeLink Temperature-Humidity';
},
paletteLabel: function () {
return 'temp / hum';
}
});
</script>
Expand Down
6 changes: 5 additions & 1 deletion src/temperature/temperature.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<script type="text/javascript">
RED.nodes.registerType('ewelink-temperature', {
category: 'eWeLink',
color: '#a6bbcf',
color: '#7bb6ef',
icon: 'font-awesome/fa-fire',
defaults: {
name: { value: '' },
deviceId: { value: '' },
Expand All @@ -11,6 +12,9 @@
outputs: 1,
label: function () {
return this.name || 'eWeLink Temperature';
},
paletteLabel: function () {
return 'temperature';
}
});
</script>
Expand Down

0 comments on commit 033112e

Please sign in to comment.