mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
Initial debug pop-out window
This commit is contained in:
6
nodes/core/core/lib/debug/debug.js
Normal file
6
nodes/core/core/lib/debug/debug.js
Normal file
@@ -0,0 +1,6 @@
|
||||
$(function() {
|
||||
window.addEventListener('message',function(evt) {
|
||||
console.log(evt.data);
|
||||
$('<div>').text(evt.data).appendTo(document.body);
|
||||
},false)
|
||||
});
|
51
nodes/core/core/lib/debug/style.css
Normal file
51
nodes/core/core/lib/debug/style.css
Normal file
@@ -0,0 +1,51 @@
|
||||
#debug-content {
|
||||
position: absolute;
|
||||
top: 43px;
|
||||
bottom: 0px;
|
||||
left:0px;
|
||||
right: 0px;
|
||||
overflow-y: scroll;
|
||||
}
|
||||
.debug-message {
|
||||
cursor: pointer;
|
||||
border-bottom: 1px solid #eee;
|
||||
border-left: 8px solid #eee;
|
||||
border-right: 8px solid #eee;
|
||||
padding: 2px;
|
||||
}
|
||||
.debug-message-date {
|
||||
background: #fff;
|
||||
font-size: 9px;
|
||||
color: #aaa;
|
||||
padding: 1px 5px 1px 1px;
|
||||
}
|
||||
.debug-message-topic {
|
||||
display: block;
|
||||
background: #fff;
|
||||
padding: 1px;
|
||||
font-size: 10px;
|
||||
color: #a66;
|
||||
}
|
||||
.debug-message-name {
|
||||
background: #fff;
|
||||
padding: 1px 5px;
|
||||
font-size: 9px;
|
||||
color: #aac;
|
||||
}
|
||||
.debug-message-payload {
|
||||
display: block;
|
||||
padding: 2px;
|
||||
background: #fff;
|
||||
}
|
||||
.debug-message-level-log {
|
||||
border-left-color: #eee;
|
||||
border-right-color: #eee;
|
||||
}
|
||||
.debug-message-level-30 {
|
||||
border-left-color: #ffdf9d;
|
||||
border-right-color: #ffdf9d;
|
||||
}
|
||||
.debug-message-level-20 {
|
||||
border-left-color: #f99;
|
||||
border-right-color: #f99;
|
||||
}
|
8
nodes/core/core/lib/debug/view.html
Normal file
8
nodes/core/core/lib/debug/view.html
Normal file
@@ -0,0 +1,8 @@
|
||||
<html>
|
||||
<head>
|
||||
<link rel="stylesheet" href="style.css">
|
||||
</head>
|
||||
<body></body>
|
||||
<script src="../../vendor/vendor-jquery.js"></script>
|
||||
<script src="debug.js"></script>
|
||||
</html>
|
Reference in New Issue
Block a user