Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release Candidate 1.7.0 #557

Merged
merged 131 commits into from
Sep 19, 2024
Merged
Show file tree
Hide file tree
Changes from 120 commits
Commits
Show all changes
131 commits
Select commit Hold shift + click to select a range
ea3d845
Initialize 1.4.0-dev.0
Shaquu Apr 6, 2021
f4529d4
Merge remote-tracking branch 'origin/master' into dev
Shaquu Apr 24, 2021
22b258f
Fixed customCharacteristics incorrect refresh in UI
Shaquu Apr 25, 2021
ad2209a
Update demo examples for 1.x (#381)
crxporter Apr 26, 2021
c73284f
Persistent accessory identifier for subflows (#395)
kevinkub Apr 27, 2021
e2c4b50
Merge branch 'dev' of https://github.com/NRCHKB/node-red-contrib-home…
Shaquu Apr 27, 2021
85dc377
Changelog update + code maintenance
Shaquu Apr 27, 2021
d4fcd34
Warn about unexpected behaviour of new Bridge in a Subflow #393 (#401)
Shaquu Jul 1, 2021
1c1a84e
Merge remote-tracking branch 'origin/master' into dev
Shaquu Jul 1, 2021
1b84fdb
Code maintenance.
Shaquu Jul 1, 2021
19effea
Merge remote-tracking branch 'origin/master' into dev
Shaquu Jul 16, 2021
d364b16
Fixed Custom MDNS Configuration not showing in UI for Standalone Acce…
Shaquu Jul 16, 2021
5fe35a7
Notice during app launch: Node.js 10 will be deprecated in Node-RED 2…
Shaquu Jul 16, 2021
a7d5555
Stop components from clearing other components node.status call
Shaquu Jul 16, 2021
4c361fd
deps update
Shaquu Jul 16, 2021
2aded94
Output Home.app refresh event #392
Shaquu Jul 16, 2021
092c33a
Get node to fetch Serialized Service #210
Shaquu Jul 16, 2021
0f89b1c
--ignore-engines
Shaquu Jul 18, 2021
a294205
--ignore-engines
Shaquu Jul 18, 2021
bc18fac
Get node to fetch Serialized Service #210 - fixes
Shaquu Jul 18, 2021
8f99c06
Merge remote-tracking branch 'origin/dev' into dev
Shaquu Jul 18, 2021
f30a13b
Fix discord notification on dev release
Shaquu Jul 18, 2021
f3a2fde
Event output is now in service version 2 which is available in NRCHKB…
Shaquu Aug 2, 2021
596ccd7
Merge remote-tracking branch 'origin/dev' into dev
Shaquu Aug 2, 2021
3fce8b7
Fix missing file + prettier
Shaquu Aug 2, 2021
28dc3b4
Support for environment variables in characteristic properties #217
Shaquu Aug 2, 2021
64d09ff
Using get callback is now optional with useEventCallback (Service 2 n…
Shaquu Aug 2, 2021
7a9cfef
Fixed Status node default label
Shaquu Aug 2, 2021
f603697
Allow Status node to see Service 2 node
Shaquu Aug 2, 2021
e4e0387
Add missing advertiser selector in UI for Standalone Accessory
Shaquu Aug 5, 2021
519ac9e
Not naming the host node causes a crash #424
Shaquu Aug 5, 2021
abb79df
Update README.md (#426)
Shaquu Aug 5, 2021
d4d0fd2
Bump versions for Readme rework (#427)
Shaquu Aug 5, 2021
061dfd1
Readme fixes (#428)
Shaquu Aug 5, 2021
fd928a1
Updated hap-nodejs to 0.9.5 and project cleanup
Shaquu Sep 27, 2021
1598a0d
More descriptive error when incorrect Characteristic has been used in…
Shaquu Sep 27, 2021
782704a
Remove hap.context from Service 2 #437
Shaquu Sep 28, 2021
6a05da6
Add msg.hap.allChars to service nodes #438
Shaquu Sep 28, 2021
af465c8
Changelog and version bump
Shaquu Sep 28, 2021
5f3e9f0
Do not output oldValue for onSet as it does not have access to old value
Shaquu Sep 30, 2021
43ca486
Fixed allChars output in msg.hap to contain proper values
Shaquu Sep 30, 2021
b072fe6
Fixed oldValue not being attached when 0 or false
Shaquu Sep 30, 2021
51134bc
Fixed multiple env variables evaluation in characteristicProperties #217
Shaquu Oct 2, 2021
4ae7fc6
Version 1.4.0
Shaquu Oct 4, 2021
671691c
Merge remote-tracking branch 'origin/master' into dev
Shaquu Oct 5, 2021
77a04b1
Version 1.4.2
Shaquu Oct 5, 2021
b872346
Version 1.4.2
Shaquu Oct 5, 2021
e543420
Merge remote-tracking branch 'origin/dev' into dev
Shaquu Oct 5, 2021
ddf5d40
Revert hap-nodejs to stable
Shaquu Oct 5, 2021
ac0bd52
Pass Characteristic key in event context for Service2
Shaquu Oct 6, 2021
2787bb5
Merge remote-tracking branch 'origin/dev' into dev
Shaquu Oct 6, 2021
eefb504
Updated hap-nodejs to 0.9.6 (bug fixes and security fixes)
Shaquu Oct 8, 2021
5bb7ea1
Bugfix Release Candidate 1.4.3
Shaquu Oct 11, 2021
bdf312f
Merge commit 'd96c745dfc18032e49d16ead525a2eb751db83d6' into dev
Shaquu Oct 14, 2021
7d3765e
Ignore files created by dev run
Shaquu Oct 14, 2021
24d12b2
Update deps and init 1.5.0-dev
Shaquu Oct 26, 2021
31409b3
Fixed props type convertion for Custom Chars
Shaquu Oct 26, 2021
4c47ae4
Updated hap-nodejs to 0.9.7 (bug fixes)
Shaquu Nov 11, 2021
6ca2f87
Fixed: Accessory could not be recovered from NO_RESPONSE using single…
Shaquu Nov 11, 2021
2886f43
Fixed: Make unsupported Characteristic error more descriptive #456
Shaquu Nov 14, 2021
f618f34
Updated deps and added supported node-red versions
Shaquu Feb 8, 2022
28c54b1
Replace yarn with npm
Shaquu Apr 12, 2022
99c2458
Updated deps
Shaquu Apr 12, 2022
d7e1f23
Set strict hap-nodejs version
Shaquu Apr 12, 2022
4aa8f3a
Added support for new advertiser AVAHI
Shaquu Apr 12, 2022
b68a3f1
Update hap-nodejs to 0.10.1
Shaquu Apr 13, 2022
32d8773
Update hap-nodejs to 0.10.2
Shaquu Aug 28, 2022
0a0b264
fix FFmpeg No such file or directory (#495)
twocolors Aug 31, 2022
5d6bcaf
Dependencies update
Shaquu Aug 31, 2022
fd22a83
allChars: properties have spaces in names #496
Shaquu Aug 31, 2022
fc90dbe
Resolve issues with CI builds
Shaquu Aug 31, 2022
e6215bd
Resolve issues with CI builds
Shaquu Aug 31, 2022
4a641e7
Merge remote-tracking branch 'origin/dev' into dev
Shaquu Aug 31, 2022
581b1f8
Updated hap-nodejs to 0.10.3
Shaquu Sep 16, 2022
f62907d
Updated hap-nodejs to 0.10.4
Shaquu Sep 19, 2022
883f2bc
Small fixes to HostNode close handler
Shaquu Oct 1, 2022
2056305
Added `msg.hap.reachable` parameter
Shaquu Oct 1, 2022
19594a7
More tests + small adjustments for clean code
Shaquu Oct 1, 2022
276755d
Bigger timeout for tests
Shaquu Oct 1, 2022
64be57f
Update CHANGELOG.md
Shaquu Oct 1, 2022
039943c
Marked CameraEventRecordingManagement as deprecated
Shaquu Oct 1, 2022
410872f
Tests improvements
Shaquu Oct 1, 2022
787ddde
Fixed support for Avahi in Standalone Accessory
Shaquu Oct 1, 2022
286c4e9
Fix status timeout and reachability status propagation and code impro…
Shaquu Oct 3, 2022
865b877
Updated hap-nodejs to 0.11.0
Shaquu Nov 20, 2022
9624da5
Github changelog configuration
Shaquu Nov 20, 2022
bd55bb3
Support for new advertiser RESOLVED
Shaquu Nov 20, 2022
7644b7d
Updated the changelog
Shaquu Nov 20, 2022
005bb93
dev version bump
Shaquu Nov 20, 2022
22ce792
Version 1.5.0
Shaquu Nov 20, 2022
e5d6316
Merge remote-tracking branch 'origin/master' into dev
Shaquu Feb 15, 2023
99b82d8
Dependencies upgrade (hap-nodejs 0.11.1) + types cleanup
Shaquu Aug 15, 2023
e0d0a53
Removed React from dependencies
Shaquu Aug 15, 2023
05925ca
Pin Code format for new devices changed to XXXX-XXXX
Jan 7, 2024
15ec916
NodeJS <12 no longer supported + upgraded deps
Jan 7, 2024
958eb7e
dev version bump
Jan 7, 2024
79ebaf4
Github Actions updates
Jan 7, 2024
55ef33b
Bump version to 1.6.0
Shaquu Jan 11, 2024
39f4489
Merge remote-tracking branch 'origin' into dev
Shaquu Jan 12, 2024
feaffdd
Fix scope in publish-gpr build step
Shaquu Jan 12, 2024
73b800d
Added ip as dependency #545
Shaquu Feb 19, 2024
c602d00
Code prettier
Shaquu Feb 19, 2024
e1ebbe8
Updated version and changelog
Shaquu Feb 19, 2024
01b4b73
Updated @nrchkb/logger
Shaquu Feb 19, 2024
c9dbbf5
Merge remote-tracking branch 'origin/master' into dev
Shaquu Feb 19, 2024
450ada4
GithubActions updated packages and using automatic node-red flows update
Shaquu Jun 15, 2024
09076e0
Updated hap-nodejs 0.11.1 to 0.12.2
Shaquu Jun 15, 2024
06a865e
Fixed undefined error when reading network interfaces
Shaquu Jun 15, 2024
ffb13c0
Dropping support for Node.js older then 18
Shaquu Jun 15, 2024
80f28c7
Resolved ip module vulnerability
Shaquu Jun 15, 2024
853545b
Changelog update
Shaquu Jun 15, 2024
5039a13
Adaptive Lighting support #335
Shaquu Jun 17, 2024
053b755
Temporarily disable Adaptive Lighting MANUAL mode
Shaquu Jun 18, 2024
189e54e
msg.context now handled properly
Shaquu Jun 18, 2024
c061760
cleanup ServiceUtils
Shaquu Jun 18, 2024
9030a92
Delay configureAdaptiveLightning after additional Characteristic Prop…
Shaquu Jun 18, 2024
f975043
dev deps upgrade
Shaquu Jun 18, 2024
348011e
Fixed Circular error
Shaquu Jun 20, 2024
aa625f9
Fixed Adaptive Lightning
Shaquu Jun 20, 2024
cff18e5
By default, registered Eve.app Characteristics for power management -…
Shaquu Jun 20, 2024
8421072
Fixed regression for Adaptive Lightning
Shaquu Jun 21, 2024
bd712d8
Updated dependencies (node-red@4 and more)
Shaquu Jun 22, 2024
271d027
Adaptive Lightning manual mode WIP, update event output
Shaquu Jun 22, 2024
6536c43
Fixed few warnings related to Adaptive Lightning
Shaquu Jun 23, 2024
316349c
Trivial pincodes are now forbidden
Shaquu Jun 25, 2024
301180a
Improved Host not found error
Shaquu Jun 26, 2024
d885236
MDNS Configuration is now deprecated, use Bind instead
Shaquu Jun 26, 2024
b4df110
Updated to hap-nodejs 0.12.3-beta.7 which resolves Adaptive Lightning…
Shaquu Jun 26, 2024
2424c16
Revert node-persist to 3.1.3 to regain backward compatibility
Shaquu Jun 26, 2024
2e08ab5
bump deps
Shaquu Jul 12, 2024
0f2c86d
version bump to 1.7.0
Shaquu Sep 19, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,16 @@ jobs:
language: [ 'javascript' ]

steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Checkout repository
uses: actions/checkout@v4

- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{ matrix.language }}
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{ matrix.language }}

- name: Autobuild
uses: github/codeql-action/autobuild@v1
- name: Autobuild
uses: github/codeql-action/autobuild@v1

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
16 changes: 8 additions & 8 deletions .github/workflows/publish-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18
node-version: 20
- run: |
npm ci
npm run build
Expand All @@ -22,10 +22,10 @@ jobs:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18
node-version: 20
registry-url: https://registry.npmjs.org/
always-auth: true
- name: Extract PACKAGE_VERSION
Expand All @@ -34,8 +34,8 @@ jobs:
- name: Prepare Discord notification messages
id: discord-prepare
run: |
echo ::set-output name=DISCORD_MSG_DEV_ANN::'{"title":"New dev version `${{ steps.package-version.outputs.current-version }}` has been released.","description":"Changelog is available [here](https://github.com/NRCHKB/node-red-contrib-homekit-bridged/commits/dev/CHANGELOG.md)","url":"https://github.com/NRCHKB/node-red-contrib-homekit-bridged/tree/dev","color":9371648,"fields":[{"name":"How to install","value":"1. Stop node-red\n2. Backup `~/.node-red` folder\n3. `cd ~/.node-red`\n4. `npm i node-red-contrib-homekit-bridged@${{ steps.package-version.outputs.current-version }}`\n5. Start node-red"}]}'
echo ::set-output name=DISCORD_MSG_ERROR::'{"title":"Dev version `${{ steps.package-version.outputs.current-version }}` failed to be released.","description":"Changelog is available [here](https://github.com/NRCHKB/node-red-contrib-homekit-bridged/commits/dev/CHANGELOG.md)","url":"https://github.com/NRCHKB/node-red-contrib-homekit-bridged/tree/dev","color":9371648,"fields":[{"name":"How to install","value":"1. Stop node-red\n2. Backup `~/.node-red` folder\n3. `cd ~/.node-red`\n4. `npm i node-red-contrib-homekit-bridged@${{ steps.package-version.outputs.current-version }}`\n5. Start node-red"}]}'
echo ::set-output name=DISCORD_MSG_DEV_ANN::'{"title":"New dev version `${{ steps.package-version.outputs.current-version }}` has been released.","description":"Changelog is available [here](https://github.com/NRCHKB/node-red-contrib-homekit-bridged/commits/dev/CHANGELOG.md)","url":"https://github.com/NRCHKB/node-red-contrib-homekit-bridged/tree/dev","color":9371648,"fields":[{"name":"How to install","value":"1. Stop node-red\n2. Backup `~/.node-red` folder\n3. `cd ~/.node-red`\n4. `npm i node-red-contrib-homekit-bridged@${{ steps.package-version.outputs.current-version }}`\n5. Start node-red"}]}'
echo ::set-output name=DISCORD_MSG_ERROR::'{"title":"Dev version `${{ steps.package-version.outputs.current-version }}` failed to be released.","description":"Changelog is available [here](https://github.com/NRCHKB/node-red-contrib-homekit-bridged/commits/dev/CHANGELOG.md)","url":"https://github.com/NRCHKB/node-red-contrib-homekit-bridged/tree/dev","color":9371648,"fields":[{"name":"How to install","value":"1. Stop node-red\n2. Backup `~/.node-red` folder\n3. `cd ~/.node-red`\n4. `npm i node-red-contrib-homekit-bridged@${{ steps.package-version.outputs.current-version }}`\n5. Start node-red"}]}'
- name: Publish
if: contains(steps.package-version.outputs.current-version, 'dev') == true
run: |
Expand Down
24 changes: 15 additions & 9 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18
node-version: 20
- run: |
npm ci
npm run build
Expand All @@ -22,10 +22,10 @@ jobs:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18
node-version: 20
registry-url: https://registry.npmjs.org/
always-auth: true
- name: Extract PACKAGE_VERSION
Expand All @@ -47,10 +47,10 @@ jobs:
contents: read
packages: write
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18
node-version: 20
registry-url: https://npm.pkg.github.com/
scope: '@nrchkb'
- name: Extract PACKAGE_VERSION
Expand All @@ -64,3 +64,9 @@ jobs:
npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.GHUB_TKN}}
- name: Update Node-Red flow-library
if: contains(steps.package-version.outputs.current-version, 'dev') != true
uses: Zehir/update-package-node-red-flow-library-action@v1.0.5
continue-on-error: true
with:
package-name: 'node-red-contrib-homekit-bridged'
10 changes: 5 additions & 5 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
name: Tests

on: [pull_request]
on: [ pull_request ]

jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
node_version: [12, 14, 16, 18]
os: [ubuntu-latest, windows-latest, macOS-latest]
node_version: [ 18, 20, 22 ]
os: [ ubuntu-latest, windows-latest, macOS-latest ]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: build and test
Expand Down
22 changes: 20 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,33 @@

##### Before upgrading make sure that you are using the latest version of [Node-RED](https://nodered.org/docs/getting-started/local) and latest LTS version of [Node.js](https://nodejs.org/en/download/)

###### Upgrading from versions 0.X to 1.X is a breaking change, all devices will be reset in the Home app. Please review the [release notes](https://github.com/NRCHKB/node-red-contrib-homekit-bridged/releases/tag/v1.0.1) thoroughly before updating!

# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres
to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [1.7.0]

### Fixed

- Removed vulnerable module 'ip' [#545](https://github.com/NRCHKB/node-red-contrib-homekit-bridged/issues/545)
- msg.context now handled properly

### Added

- Adaptive Lighting support [#335](https://github.com/NRCHKB/node-red-contrib-homekit-bridged/issues/335)
- By default, registered Eve.app Characteristics for power management - for existing setup, requires old custom characteristics file to be removed

### Changed

- Updated hap-nodejs [0.11.1 to 0.12.2](https://github.com/homebridge/HAP-NodeJS/blob/latest/CHANGELOG.md) (features
and bug fixes)
- Dependencies upgrade
- Node `10`, `12` and `16` no longer supported
- Updated GitHub Actions

## [1.6.1] - 2024-02-19

### Fixed
Expand Down
43 changes: 42 additions & 1 deletion build/nodes/service.html
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,25 @@
</div>
</div>

<div id="adaptive-lightning-configuration" style="display: none; border: 1px solid var(--red-ui-secondary-border-color); padding: 12px 12px 0 12px; margin-bottom: 12px;">
<label>&nbsp;&nbsp;<i class="fa fa-cog"></i> Adaptive Lightning Configuration</label>
<div class="form-row">
<label for="node-input-adaptiveLightingOptionsEnable"><i class="fa fa-toggle-on"></i> Enable</label>
<input type="checkbox" id="node-input-adaptiveLightingOptionsEnable">
</div>
<div class="form-row">
<label for="node-input-adaptiveLightingOptionsMode"><i class="fa fa-hand-o-up"></i> Mode</label>
<select id="node-input-adaptiveLightingOptionsMode">
<option value="1" selected="selected">AUTOMATIC</option>
<option value="2" disabled>MANUAL</option>
</select>
</div>
<div class="form-row">
<label for="node-input-adaptiveLightingOptionsCustomTemperatureAdjustment"><i class="fa fa-thermometer-quarter"></i> Custom Temperature Adjustment</label>
<input type="number" id="node-input-adaptiveLightingOptionsCustomTemperatureAdjustment">
</div>
</div>

<div class="form-row">
<label for="node-input-characteristicProperties"><i class="fa fa-wrench"></i> Characteristic Properties</label>
<input type="text" id="node-input-characteristicProperties" style="width: 70%">
Expand Down Expand Up @@ -474,7 +493,18 @@ <h2 id="toc_8">Characteristic Properties</h2>
},
outputs: {
value: 2,
}
},
adaptiveLightingOptionsEnable: {
value: false,
},
adaptiveLightingOptionsMode: {
value: 1,
validate: RED.validators.number()
},
adaptiveLightingOptionsCustomTemperatureAdjustment: {
value: 0,
validate: RED.validators.number()
Shaquu marked this conversation as resolved.
Show resolved Hide resolved
},
},
inputs: 1,
outputs: 2,
Expand Down Expand Up @@ -581,6 +611,7 @@ <h2 id="toc_8">Characteristic Properties</h2>
})

let cameraConfiguration = $('#camera-configuration')
let adaptiveLightningConfiguration = $('#adaptive-lightning-configuration')

selectServiceName
.find('option')
Expand All @@ -601,6 +632,16 @@ <h2 id="toc_8">Characteristic Properties</h2>
})
.change()

selectServiceName
.change(function () {
if (this.value === 'Lightbulb') {
adaptiveLightningConfiguration.fadeIn('fast')
} else {
adaptiveLightningConfiguration.fadeOut('fast')
}
})
.change()

Shaquu marked this conversation as resolved.
Show resolved Hide resolved
$('#node-input-characteristicProperties').typedInput({
type: 'json',
types: ['json'],
Expand Down
43 changes: 42 additions & 1 deletion build/nodes/service2.html
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,25 @@
</div>
</div>

<div id="adaptive-lightning-configuration" style="display: none; border: 1px solid var(--red-ui-secondary-border-color); padding: 12px 12px 0 12px; margin-bottom: 12px;">
<label>&nbsp;&nbsp;<i class="fa fa-cog"></i> Adaptive Lightning Configuration</label>
<div class="form-row">
<label for="node-input-adaptiveLightingOptionsEnable"><i class="fa fa-toggle-on"></i> Enable</label>
<input type="checkbox" id="node-input-adaptiveLightingOptionsEnable">
</div>
<div class="form-row">
<label for="node-input-adaptiveLightingOptionsMode"><i class="fa fa-hand-o-up"></i> Mode</label>
<select id="node-input-adaptiveLightingOptionsMode">
<option value="1" selected="selected">AUTOMATIC</option>
<option value="2" disabled>MANUAL</option>
</select>
</div>
<div class="form-row">
<label for="node-input-adaptiveLightingOptionsCustomTemperatureAdjustment"><i class="fa fa-thermometer-quarter"></i> Custom Temperature Adjustment</label>
<input type="number" id="node-input-adaptiveLightingOptionsCustomTemperatureAdjustment">
</div>
</div>

<div class="form-row">
<label for="node-input-characteristicProperties"><i class="fa fa-wrench"></i> Characteristic Properties</label>
<input type="text" id="node-input-characteristicProperties" style="width: 70%">
Expand Down Expand Up @@ -484,7 +503,18 @@ <h2 id="toc_8">Characteristic Properties</h2>
},
outputs: {
value: 1,
}
},
adaptiveLightingOptionsEnable: {
value: false,
},
adaptiveLightingOptionsMode: {
value: 1,
validate: RED.validators.number()
},
adaptiveLightingOptionsCustomTemperatureAdjustment: {
value: 0,
validate: RED.validators.number()
Shaquu marked this conversation as resolved.
Show resolved Hide resolved
},
},
inputs: 1,
outputs: 1,
Expand Down Expand Up @@ -583,6 +613,7 @@ <h2 id="toc_8">Characteristic Properties</h2>
})

let cameraConfiguration = $('#camera-configuration')
let adaptiveLightningConfiguration = $('#adaptive-lightning-configuration')

selectServiceName
.find('option')
Expand All @@ -603,6 +634,16 @@ <h2 id="toc_8">Characteristic Properties</h2>
})
.change()

selectServiceName
.change(function () {
if (this.value === 'Lightbulb') {
adaptiveLightningConfiguration.fadeIn('fast')
} else {
adaptiveLightningConfiguration.fadeOut('fast')
}
})
.change()

Shaquu marked this conversation as resolved.
Show resolved Hide resolved
$('#node-input-characteristicProperties').typedInput({
type: 'json',
types: ['json'],
Expand Down
Loading
Loading