The frontend/UI server, written in JS using the MarkoJS library
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

32 lines
1.3 KiB

import moment from "moment"
<modal class="modal color-text nolabel" key="modal" enabled=(input.enabled) closable on-close("close") on-open("open") >
<h1>Add Log</h1>
<p key="error" class="color-error">${state.error}</p>
<label>Title</label>
<input key="title" placeholder="(Optional)" class="big" on-change("change", "title") value=state.values.title />
<label>Date</label>
<input key="date" placeholder="(Required)" on-change("change", "date") value=state.values.date />
<label>Channel</label>
<input key="channel" placeholder="(Required)" on-change("change", "channel") value=state.values.channel />
<label>Event Name</label>
<input key="event" placeholder="(Optional)" on-change("change", "event") value=state.values.event />
<label>Description</label>
<textarea key="description" placeholder="(Optional)" on-change("change", "description") value=state.values.description />
<label>Options</label>
<toggle value=state.values.open on="Open" off="Closed"
onDesc=("IRC posts in "+state.values.channel.name+" will end up here.")
offDesc="The logbot will not append to this log."
on-change("change", "open") />
<p if(state.values.open) key="warning" class="color-danger">Opening a log will close all others for the same channels.</p>
<button disabled=state.loading on-click("save")>Save</button>
</modal>