attachments.css 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190
  1. .hidden {
  2. display: none;
  3. }
  4. .attachment-upload {
  5. text-align: center;
  6. font-weight: bold;
  7. }
  8. .attachment-gallery {
  9. display: flex;
  10. flex-direction: column;
  11. }
  12. .attachment-item {
  13. display: flex;
  14. flex-direction: row;
  15. align-items: center;
  16. margin-top: 16px;
  17. }
  18. .attachment-item:hover {
  19. background: #e0e0e0;
  20. }
  21. .attachment-thumbnail-container {
  22. display: block;
  23. width: 150px;
  24. min-width: 150px;
  25. max-height: 150px;
  26. padding-right: 16px;
  27. }
  28. .attachment-thumbnail {
  29. max-width: 150px;
  30. max-height: 150px;
  31. min-height: 2em;
  32. cursor: pointer;
  33. }
  34. .attachment-thumbnail-text {
  35. min-height: 2em;
  36. display: flex;
  37. align-items: center;
  38. justify-content: center;
  39. font-size: 2em;
  40. cursor: pointer;
  41. border: 1px solid #ccc;
  42. border-radius: 5px;
  43. }
  44. .attachment-details-container {
  45. display: block;
  46. flex-grow: 1;
  47. }
  48. .attachment-details {
  49. display: flex;
  50. justify-content: space-between;
  51. margin-right: 25px; /* Make sure the icons are not to far to the right */
  52. }
  53. .attachment-actions {
  54. display: flex;
  55. flex-direction: row;
  56. align-items: center;
  57. }
  58. .add-attachment {
  59. display: flex;
  60. align-items: center;
  61. justify-content: center;
  62. border: 1px dashed #555;
  63. border-radius: 5px;
  64. padding: 10px;
  65. cursor: pointer;
  66. margin-top: 16px;
  67. }
  68. .icon {
  69. font-size: 1.5em;
  70. cursor: pointer;
  71. margin-left: 10px;
  72. }
  73. .icon:hover {
  74. color: #666;
  75. }
  76. #viewer-overlay {
  77. width: 100%;
  78. height: 100vh;
  79. position: fixed;
  80. top: 48px; /* height of the navbar */
  81. left: 0;
  82. z-index: 9999 !important;
  83. background: rgba(13,13,13,0.95);
  84. }
  85. #viewer-container {
  86. display: flex;
  87. flex-direction: row;
  88. justify-content: space-between;
  89. height: 100%;
  90. }
  91. #viewer-top-bar {
  92. display: flex;
  93. flex-direction: row;
  94. justify-content: space-between;
  95. width: 100%;
  96. padding: 16px;
  97. }
  98. #attachment-name {
  99. color: white;
  100. font-size: 1.5em;
  101. max-width: calc(100% - 50px); /* Make sure the name does not overlap the close button */
  102. }
  103. #viewer-close {
  104. color:white;
  105. cursor: pointer;
  106. font-size: 4em;
  107. top: 0;
  108. right: 8px;
  109. position: absolute;
  110. }
  111. .attachment-arrow {
  112. font-size: 4em;
  113. color:white;
  114. cursor: pointer;
  115. align-self: center;
  116. margin: 0 20px;
  117. }
  118. #image-viewer {
  119. background:
  120. repeating-conic-gradient(#808080 0% 25%, transparent 0% 50%)
  121. 50% / 20px 20px; /* Checkerboard background for transparent images */
  122. max-width: 100%;
  123. }
  124. #pdf-viewer {
  125. width: 40vw;
  126. height: 100vh;
  127. }
  128. #txt-viewer{
  129. background-color: white;
  130. width: 40vw;
  131. height: 100vh;
  132. }
  133. .pdf-preview-error {
  134. margin-top: 20vh;
  135. display: block;
  136. font-size: 2em;
  137. color: white;
  138. }
  139. @media screen and (max-width: 1600px) {
  140. #pdf-viewer {
  141. width: 60vw;
  142. }
  143. }
  144. @media screen and (max-width: 800px) {
  145. #viewer-container {
  146. display: block;
  147. }
  148. .attachment-arrow{
  149. position: absolute;
  150. bottom: 2.2em;
  151. font-size: 1.6em;
  152. padding: 16px;
  153. }
  154. #prev-attachment{
  155. left: 0;
  156. }
  157. #next-attachment{
  158. right: 0;
  159. }
  160. #pdf-viewer {
  161. width: 100%;
  162. height: calc(100vh - 155px); /* Full height - height of top and bottom bars */
  163. }
  164. #txt-viewer {
  165. width: 100%;
  166. height: calc(100vh - 155px); /* Full height - height of top and bottom bars */
  167. }
  168. #audio-viewer {
  169. margin-top: 20%;
  170. width: 100%;
  171. }
  172. .attachment-thumbnail-container {
  173. width: 100px;
  174. min-width: 100px;
  175. }
  176. .attachment-thumbnail {
  177. max-width: 100px;
  178. }
  179. .attachment-details {
  180. flex-direction: column;
  181. margin-right: 0px;
  182. }
  183. .attachment-actions {
  184. flex-direction: row;
  185. margin-top: 10px;
  186. }
  187. }