Add missing buffer-header.js

This commit is contained in:
Simon Ser 2020-06-25 18:30:21 +02:00
parent 3e33999619
commit 4485950b67
No known key found for this signature in database
GPG Key ID: 0FDE7BE0E88F5E48

View File

@ -0,0 +1,20 @@
import { html, Component } from "/lib/index.js";
export default function BufferHeader(props) {
var topic = null;
if (props.buffer.topic) {
topic = html`<span class="topic">${props.buffer.topic}</span>`;
}
function handlePartClick(event) {
event.preventDefault();
props.onClose();
}
return html`
${topic}
<span class="actions">
<a href="#" onClick=${handlePartClick}>Part</a>
</span>
`;
}