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.

25 lines
1.0 KiB

  1. <menu user=input.user>
  2. <if-permitted user=input.user permission="post.add">
  3. <menu-header>Log</menu-header>
  4. <menu-link dark key="_create" on-click("select", "post.add", null) icon="+">Add Post</menu-link>
  5. <menu-gap />
  6. </if-permitted>
  7. <menu-header>Channel</menu-header>
  8. <menu-link href=("/logs/?channels="+encodeURIComponent(input.log.channel.name)) icon="#">${input.log.channel.name}</menu-link>
  9. <menu-gap />
  10. <if(input.log.eventName)>
  11. <menu-header>Event</menu-header>
  12. <menu-link href=("/logs/?events="+input.log.eventName) icon="E">${input.log.eventName}</menu-link>
  13. <menu-gap />
  14. </if>
  15. <if(input.log.characters.length > 0)>
  16. <menu-header>Characters</menu-header>
  17. <for(character in input.log.characters)>
  18. <menu-link weak=(state.highlights.length > 0 && !state.highlights.includes(character.id))
  19. icon="C"
  20. on-click("toggleHighlight", character.id)>
  21. ${character.name} <span class="weak">(${character.author})</span>
  22. </menu-link>
  23. </for>
  24. <menu-gap />
  25. </if>
  26. </menu>