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.
 
 
 
 

28 lines
1.3 KiB

<modal class="modal color-text nolabel" key="modal2" enabled=(input.enabled) closable on-close("close") >
<h1>Add Story</h1>
<p key="error" class="color-error">${state.error}</p>
<label>Title</label>
<input key="name" autofocus placeholder="Name" class="big" on-change("change", "name") value=state.values.name />
<label>IC Date</label>
<input key="icdate" placeholder="IC Date" on-change("change", "fictionalDate") value=state.values.fictionalDate />
<label>Category</label>
<select key="category" placeholder="Kind" on-change("change", "category")>
<option for(category in input.categories) value=category.name selected=(state.values.category === category.name)>${category.name}</option>
</select>
<label>Options</label>
<toggle value=state.values.listed on="Listed" off="Unlisted"
onDesc="The story will be visible on the front page."
offDesc="A direct link is required to view this story."
on-change("change", "listed") />
<toggle value=state.values.open on="Open" off="Closed"
onDesc="Other authors can add chapters to this story."
offDesc="Only you can add chapters to this story."
on-change("change", "open") />
<button disabled=state.loading on-click("save")>Add Story</button>
</modal>