Skip to content

Commit

Permalink
Merge branch 'release-2.3'
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffyactive committed Jan 25, 2024
2 parents 3a01409 + 995f450 commit e0cb440
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
10 changes: 7 additions & 3 deletions js/cuttlefish-tables.js
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,8 @@ class DiscreteDataTable {
this.digitalTwins = options.digitalTwins || new Map();
this.propertiesToDisplay = options.propertiesToDisplay ||
[ 'isButtonPressed', 'isContactDetected',
'isMotionDetected', 'unicodeCodePoints' ];
'isLiquidDetected', 'isMotionDetected',
'unicodeCodePoints' ];

this.render();
periodicUpdate();
Expand Down Expand Up @@ -298,7 +299,7 @@ class DiscreteDataTable {
nextUpdateTime = Math.min(staleTimestamp, nextUpdateTime);
}
if(animateTimestamp < Date.now()) {
row.firstChild.setAttribute('class', '');
row.firstChild.setAttribute('class', 'text-body-secondary');
}
else {
nextUpdateTime = Math.min(animateTimestamp, nextUpdateTime);
Expand Down Expand Up @@ -330,7 +331,7 @@ class DiscreteDataTable {

if(event) {
self.discreteData.set(id, current);
let row = tbody.querySelector('#' + id);
let row = document.getElementById(id);

if(row) {
updateDiscreteDataRow(row, event, deviceName, dynamb.timestamp);
Expand Down Expand Up @@ -561,6 +562,9 @@ function determineDiscreteDataEvent(property, current, previous) {
case 'isContactDetected':
return (current.includes(true) ? 'Contact detected' :
'No contact detected');
case 'isLiquidDetected':
return (current.includes(true) ? 'Liquid detected' :
'No liquid detected');
case 'isMotionDetected':
return (current.includes(true) ? 'Motion detected' :
'No motion detected');
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"statid",
"client-side"
],
"version": "2.3.0",
"version": "2.3.1",
"files": [
"./js/cuttlefish-story.js",
"./js/cuttlefish-dynamb.js",
Expand Down

0 comments on commit e0cb440

Please sign in to comment.