feat: Add markers and event listener to recording example

This commit is contained in:
Paul Gauthier 2025-03-13 18:04:16 -07:00 committed by Paul Gauthier (aider)
parent d916180ec8
commit 5318dd1a80

View file

@ -111,24 +111,21 @@ AsciinemaPlayer.create(
idleTimeLimit: 1,
theme : "aider",
poster : "npt:0:01",
markers : [
[3.0, "Hello!"],
[300.0, "Hello!"],
],
}
);
player.addEventListener('marker', ({ index, time, label }) => {
console.log(`marker! ${index} - ${time} - ${label}`);
}
})
</script>
<div class="transcript-container" style="margin-top: 30px; padding: 20px; background-color: #f8f8f8; border-radius: 6px; max-height: 50vh; overflow-y: auto; font-family: monospace; white-space: pre-wrap; line-height: 1.5;">
<div id="transcript-content">
Transcript goes here...<br/>
Transcript goes here...<br/>
Transcript goes here...<br/>
Transcript goes here...<br/>
Transcript goes here...<br/>
Transcript goes here...<br/>
</div>
</div>