logo

pleroma-fe

My custom branche(s) on git.pleroma.social/pleroma/pleroma-fe git clone https://anongit.hacktivis.me/git/pleroma-fe.git/

announcement_editor.vue (1595B)


  1. <template>
  2. <div class="announcement-editor">
  3. <textarea
  4. ref="textarea"
  5. v-model="announcement.content"
  6. class="input post-textarea"
  7. rows="1"
  8. cols="1"
  9. :placeholder="$t('announcements.post_placeholder')"
  10. :disabled="disabled"
  11. />
  12. <span class="announcement-metadata">
  13. <label for="announcement-start-time">{{ $t('announcements.start_time_prompt') }}</label>
  14. <input
  15. id="announcement-start-time"
  16. v-model="announcement.startsAt"
  17. class="input"
  18. :type="announcement.allDay ? 'date' : 'datetime-local'"
  19. :disabled="disabled"
  20. >
  21. </span>
  22. <span class="announcement-metadata">
  23. <label for="announcement-end-time">{{ $t('announcements.end_time_prompt') }}</label>
  24. <input
  25. id="announcement-end-time"
  26. v-model="announcement.endsAt"
  27. class="input"
  28. :type="announcement.allDay ? 'date' : 'datetime-local'"
  29. :disabled="disabled"
  30. >
  31. </span>
  32. <span class="announcement-metadata">
  33. <Checkbox
  34. id="announcement-all-day"
  35. v-model="announcement.allDay"
  36. :disabled="disabled"
  37. >
  38. {{ $t('announcements.all_day_prompt') }}
  39. </Checkbox>
  40. </span>
  41. </div>
  42. </template>
  43. <script src="./announcement_editor.js"></script>
  44. <style lang="scss">
  45. .announcement-editor {
  46. display: flex;
  47. align-items: stretch;
  48. flex-direction: column;
  49. .announcement-metadata {
  50. margin-top: 0.5em;
  51. }
  52. .post-textarea {
  53. resize: vertical;
  54. height: 10em;
  55. overflow: none;
  56. box-sizing: content-box;
  57. }
  58. }
  59. </style>