mirror of
https://github.com/thegecko/web-bluetooth-dfu.git
synced 2025-12-13 20:48:15 +08:00
Bounded results output in web example
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
input { font-size: 20px; }
|
||||
button { font-size: 20px; padding: 0 20px; display: block; margin: 20px auto; }
|
||||
.device-type { width: 160px; margin: 20px auto; white-space: nowrap; }
|
||||
#results { height: 300px; overflow: auto; border: 1px solid lightgray; margin: 5px; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
@@ -36,6 +37,7 @@
|
||||
function log(message) {
|
||||
console.log(message);
|
||||
resultsEl.innerText += message + "\n";
|
||||
resultsEl.scrollTop = resultsEl.scrollHeight;
|
||||
}
|
||||
dfu.addLogger(log);
|
||||
hex2bin.addLogger(log);
|
||||
|
||||
Reference in New Issue
Block a user