diff --git a/clover/www/js/topics.js b/clover/www/js/topics.js index 8053502a..c8710277 100644 --- a/clover/www/js/topics.js +++ b/clover/www/js/topics.js @@ -3,11 +3,13 @@ const ros = new ROSLIB.Ros({ url: url }); ros.on('connection', function () { document.body.classList.add('connected'); + document.body.classList.remove('closed'); init(); }); ros.on('close', function () { document.body.classList.remove('connected'); + document.body.classList.add('closed'); setTimeout(function() { // reconnect ros.connect(url); diff --git a/clover/www/topics.html b/clover/www/topics.html index b42ac1c2..309c3969 100644 --- a/clover/www/topics.html +++ b/clover/www/topics.html @@ -17,6 +17,7 @@ } #topic-type { font-family: monospace; font-size: 0.5em; vertical-align: super; font-weight: normal; } .topic { font-family: monospace; } + body.closed { background-color: rgb(207, 207, 207); }