@sync-in/server 1.4.0 → 1.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (229) hide show
  1. package/CHANGELOG.md +19 -0
  2. package/README.md +2 -1
  3. package/package.json +5 -5
  4. package/server/applications/comments/comments.controller.spec.js +103 -4
  5. package/server/applications/comments/comments.controller.spec.js.map +1 -1
  6. package/server/applications/comments/services/comments-manager.service.spec.js +409 -9
  7. package/server/applications/comments/services/comments-manager.service.spec.js.map +1 -1
  8. package/server/applications/files/adapters/files-indexer-mysql.service.spec.js +333 -0
  9. package/server/applications/files/adapters/files-indexer-mysql.service.spec.js.map +1 -0
  10. package/server/applications/files/constants/routes.js +6 -1
  11. package/server/applications/files/constants/routes.js.map +1 -1
  12. package/server/applications/files/files-only-office.controller.js +11 -0
  13. package/server/applications/files/files-only-office.controller.js.map +1 -1
  14. package/server/applications/files/files-only-office.controller.spec.js +97 -3
  15. package/server/applications/files/files-only-office.controller.spec.js.map +1 -1
  16. package/server/applications/files/files-tasks.controller.spec.js +91 -1
  17. package/server/applications/files/files-tasks.controller.spec.js.map +1 -1
  18. package/server/applications/files/files.controller.spec.js +268 -46
  19. package/server/applications/files/files.controller.spec.js.map +1 -1
  20. package/server/applications/files/guards/files-only-office.guard.spec.js +77 -1
  21. package/server/applications/files/guards/files-only-office.guard.spec.js.map +1 -1
  22. package/server/applications/files/services/files-only-office-manager.service.js +5 -0
  23. package/server/applications/files/services/files-only-office-manager.service.js.map +1 -1
  24. package/server/applications/links/links.controller.spec.js +91 -58
  25. package/server/applications/links/links.controller.spec.js.map +1 -1
  26. package/server/applications/links/services/links-manager.service.js +4 -6
  27. package/server/applications/links/services/links-manager.service.js.map +1 -1
  28. package/server/applications/links/services/links-manager.service.spec.js +378 -14
  29. package/server/applications/links/services/links-manager.service.spec.js.map +1 -1
  30. package/server/applications/links/services/links-queries.service.js +1 -1
  31. package/server/applications/links/services/links-queries.service.js.map +1 -1
  32. package/server/applications/notifications/notifications.controller.spec.js +56 -1
  33. package/server/applications/notifications/notifications.controller.spec.js.map +1 -1
  34. package/server/applications/notifications/services/notifications-manager.service.spec.js +461 -5
  35. package/server/applications/notifications/services/notifications-manager.service.spec.js.map +1 -1
  36. package/server/applications/shares/services/shares-manager.service.spec.js +590 -14
  37. package/server/applications/shares/services/shares-manager.service.spec.js.map +1 -1
  38. package/server/applications/sync/interceptors/sync-diff-gzip-body.interceptor.spec.js +120 -0
  39. package/server/applications/sync/interceptors/sync-diff-gzip-body.interceptor.spec.js.map +1 -0
  40. package/server/applications/sync/services/sync-clients-manager.service.spec.js +548 -8
  41. package/server/applications/sync/services/sync-clients-manager.service.spec.js.map +1 -1
  42. package/server/applications/sync/services/sync-manager.service.spec.js +837 -5
  43. package/server/applications/sync/services/sync-manager.service.spec.js.map +1 -1
  44. package/server/applications/sync/services/sync-paths-manager.service.spec.js +900 -7
  45. package/server/applications/sync/services/sync-paths-manager.service.spec.js.map +1 -1
  46. package/server/applications/users/services/admin-users-manager.service.js +22 -24
  47. package/server/applications/users/services/admin-users-manager.service.js.map +1 -1
  48. package/server/applications/users/services/admin-users-manager.service.spec.js +763 -17
  49. package/server/applications/users/services/admin-users-manager.service.spec.js.map +1 -1
  50. package/server/applications/users/services/users-manager.service.js +1 -1
  51. package/server/applications/users/services/users-manager.service.js.map +1 -1
  52. package/server/applications/users/services/users-manager.service.spec.js +938 -49
  53. package/server/applications/users/services/users-manager.service.spec.js.map +1 -1
  54. package/server/applications/webdav/decorators/if-header.decorator.js +4 -1
  55. package/server/applications/webdav/decorators/if-header.decorator.js.map +1 -1
  56. package/server/applications/webdav/filters/webdav.filter.spec.js +77 -0
  57. package/server/applications/webdav/filters/webdav.filter.spec.js.map +1 -0
  58. package/server/applications/webdav/guards/webdav-protocol.guard.js +3 -7
  59. package/server/applications/webdav/guards/webdav-protocol.guard.js.map +1 -1
  60. package/server/applications/webdav/guards/webdav-protocol.guard.spec.js +580 -0
  61. package/server/applications/webdav/guards/webdav-protocol.guard.spec.js.map +1 -0
  62. package/server/applications/webdav/services/webdav-methods.service.spec.js +1582 -3
  63. package/server/applications/webdav/services/webdav-methods.service.spec.js.map +1 -1
  64. package/server/applications/webdav/services/webdav-spaces.service.spec.js +390 -2
  65. package/server/applications/webdav/services/webdav-spaces.service.spec.js.map +1 -1
  66. package/server/applications/webdav/webdav.controller.js +2 -2
  67. package/server/applications/webdav/webdav.controller.js.map +1 -1
  68. package/server/authentication/guards/auth-basic.guard.js.map +1 -1
  69. package/server/authentication/guards/auth-digest.guard.js +1 -2
  70. package/server/authentication/guards/auth-digest.guard.js.map +1 -1
  71. package/server/authentication/guards/auth-local.guard.js.map +1 -1
  72. package/server/infrastructure/context/interceptors/context.interceptor.spec.js +135 -0
  73. package/server/infrastructure/context/interceptors/context.interceptor.spec.js.map +1 -0
  74. package/static/3rdpartylicenses.txt +26 -26
  75. package/static/assets/pdfjs/build/pdf.mjs +1177 -255
  76. package/static/assets/pdfjs/build/pdf.mjs.map +1 -1
  77. package/static/assets/pdfjs/build/pdf.sandbox.mjs +25 -2
  78. package/static/assets/pdfjs/build/pdf.sandbox.mjs.map +1 -1
  79. package/static/assets/pdfjs/build/pdf.worker.mjs +140 -16
  80. package/static/assets/pdfjs/build/pdf.worker.mjs.map +1 -1
  81. package/static/assets/pdfjs/version +1 -1
  82. package/static/assets/pdfjs/web/debugger.css +31 -0
  83. package/static/assets/pdfjs/web/debugger.mjs +144 -2
  84. package/static/assets/pdfjs/web/images/comment-editButton.svg +6 -1
  85. package/static/assets/pdfjs/web/locale/ach/viewer.ftl +0 -63
  86. package/static/assets/pdfjs/web/locale/af/viewer.ftl +0 -71
  87. package/static/assets/pdfjs/web/locale/an/viewer.ftl +0 -63
  88. package/static/assets/pdfjs/web/locale/ast/viewer.ftl +0 -60
  89. package/static/assets/pdfjs/web/locale/az/viewer.ftl +0 -63
  90. package/static/assets/pdfjs/web/locale/be/viewer.ftl +38 -0
  91. package/static/assets/pdfjs/web/locale/bg/viewer.ftl +0 -37
  92. package/static/assets/pdfjs/web/locale/bn/viewer.ftl +0 -63
  93. package/static/assets/pdfjs/web/locale/bo/viewer.ftl +0 -63
  94. package/static/assets/pdfjs/web/locale/br/viewer.ftl +0 -37
  95. package/static/assets/pdfjs/web/locale/brx/viewer.ftl +0 -63
  96. package/static/assets/pdfjs/web/locale/bs/viewer.ftl +22 -0
  97. package/static/assets/pdfjs/web/locale/ca/viewer.ftl +0 -54
  98. package/static/assets/pdfjs/web/locale/cak/viewer.ftl +0 -54
  99. package/static/assets/pdfjs/web/locale/ckb/viewer.ftl +0 -63
  100. package/static/assets/pdfjs/web/locale/cs/viewer.ftl +38 -0
  101. package/static/assets/pdfjs/web/locale/cy/viewer.ftl +38 -0
  102. package/static/assets/pdfjs/web/locale/da/viewer.ftl +38 -0
  103. package/static/assets/pdfjs/web/locale/de/viewer.ftl +38 -0
  104. package/static/assets/pdfjs/web/locale/dsb/viewer.ftl +38 -0
  105. package/static/assets/pdfjs/web/locale/el/viewer.ftl +38 -0
  106. package/static/assets/pdfjs/web/locale/en-CA/viewer.ftl +38 -0
  107. package/static/assets/pdfjs/web/locale/en-GB/viewer.ftl +38 -0
  108. package/static/assets/pdfjs/web/locale/en-US/viewer.ftl +25 -0
  109. package/static/assets/pdfjs/web/locale/eo/viewer.ftl +38 -0
  110. package/static/assets/pdfjs/web/locale/es-AR/viewer.ftl +38 -0
  111. package/static/assets/pdfjs/web/locale/es-CL/viewer.ftl +38 -0
  112. package/static/assets/pdfjs/web/locale/es-MX/viewer.ftl +0 -6
  113. package/static/assets/pdfjs/web/locale/et/viewer.ftl +0 -57
  114. package/static/assets/pdfjs/web/locale/fa/viewer.ftl +0 -37
  115. package/static/assets/pdfjs/web/locale/ff/viewer.ftl +0 -63
  116. package/static/assets/pdfjs/web/locale/fi/viewer.ftl +38 -0
  117. package/static/assets/pdfjs/web/locale/fr/viewer.ftl +38 -0
  118. package/static/assets/pdfjs/web/locale/fy-NL/viewer.ftl +38 -0
  119. package/static/assets/pdfjs/web/locale/ga-IE/viewer.ftl +0 -71
  120. package/static/assets/pdfjs/web/locale/gd/viewer.ftl +0 -54
  121. package/static/assets/pdfjs/web/locale/gl/viewer.ftl +8 -0
  122. package/static/assets/pdfjs/web/locale/gn/viewer.ftl +38 -0
  123. package/static/assets/pdfjs/web/locale/gu-IN/viewer.ftl +0 -63
  124. package/static/assets/pdfjs/web/locale/he/viewer.ftl +38 -0
  125. package/static/assets/pdfjs/web/locale/hi-IN/viewer.ftl +0 -60
  126. package/static/assets/pdfjs/web/locale/hsb/viewer.ftl +38 -0
  127. package/static/assets/pdfjs/web/locale/hu/viewer.ftl +38 -0
  128. package/static/assets/pdfjs/web/locale/hy-AM/viewer.ftl +0 -49
  129. package/static/assets/pdfjs/web/locale/hye/viewer.ftl +0 -60
  130. package/static/assets/pdfjs/web/locale/ia/viewer.ftl +38 -0
  131. package/static/assets/pdfjs/web/locale/is/viewer.ftl +0 -3
  132. package/static/assets/pdfjs/web/locale/it/viewer.ftl +31 -0
  133. package/static/assets/pdfjs/web/locale/ja/viewer.ftl +8 -0
  134. package/static/assets/pdfjs/web/locale/ka/viewer.ftl +48 -10
  135. package/static/assets/pdfjs/web/locale/kab/viewer.ftl +5 -0
  136. package/static/assets/pdfjs/web/locale/kk/viewer.ftl +8 -0
  137. package/static/assets/pdfjs/web/locale/km/viewer.ftl +0 -63
  138. package/static/assets/pdfjs/web/locale/kn/viewer.ftl +0 -71
  139. package/static/assets/pdfjs/web/locale/ko/viewer.ftl +38 -0
  140. package/static/assets/pdfjs/web/locale/lij/viewer.ftl +0 -63
  141. package/static/assets/pdfjs/web/locale/lo/viewer.ftl +0 -54
  142. package/static/assets/pdfjs/web/locale/lt/viewer.ftl +0 -60
  143. package/static/assets/pdfjs/web/locale/ltg/viewer.ftl +0 -63
  144. package/static/assets/pdfjs/web/locale/lv/viewer.ftl +0 -63
  145. package/static/assets/pdfjs/web/locale/meh/viewer.ftl +0 -75
  146. package/static/assets/pdfjs/web/locale/mk/viewer.ftl +0 -63
  147. package/static/assets/pdfjs/web/locale/ml/viewer.ftl +0 -3
  148. package/static/assets/pdfjs/web/locale/mr/viewer.ftl +0 -63
  149. package/static/assets/pdfjs/web/locale/ms/viewer.ftl +0 -63
  150. package/static/assets/pdfjs/web/locale/my/viewer.ftl +0 -71
  151. package/static/assets/pdfjs/web/locale/nb-NO/viewer.ftl +44 -6
  152. package/static/assets/pdfjs/web/locale/ne-NP/viewer.ftl +0 -71
  153. package/static/assets/pdfjs/web/locale/nl/viewer.ftl +38 -0
  154. package/static/assets/pdfjs/web/locale/nn-NO/viewer.ftl +45 -1
  155. package/static/assets/pdfjs/web/locale/oc/viewer.ftl +0 -31
  156. package/static/assets/pdfjs/web/locale/pa-IN/viewer.ftl +38 -0
  157. package/static/assets/pdfjs/web/locale/pl/viewer.ftl +39 -1
  158. package/static/assets/pdfjs/web/locale/pt-BR/viewer.ftl +38 -0
  159. package/static/assets/pdfjs/web/locale/ro/viewer.ftl +355 -1
  160. package/static/assets/pdfjs/web/locale/ru/viewer.ftl +38 -0
  161. package/static/assets/pdfjs/web/locale/sat/viewer.ftl +0 -54
  162. package/static/assets/pdfjs/web/locale/sc/viewer.ftl +0 -38
  163. package/static/assets/pdfjs/web/locale/scn/viewer.ftl +0 -92
  164. package/static/assets/pdfjs/web/locale/sco/viewer.ftl +0 -60
  165. package/static/assets/pdfjs/web/locale/si/viewer.ftl +0 -51
  166. package/static/assets/pdfjs/web/locale/sk/viewer.ftl +38 -0
  167. package/static/assets/pdfjs/web/locale/skr/viewer.ftl +0 -27
  168. package/static/assets/pdfjs/web/locale/sl/viewer.ftl +8 -0
  169. package/static/assets/pdfjs/web/locale/son/viewer.ftl +0 -71
  170. package/static/assets/pdfjs/web/locale/sr/viewer.ftl +0 -33
  171. package/static/assets/pdfjs/web/locale/sv-SE/viewer.ftl +38 -0
  172. package/static/assets/pdfjs/web/locale/szl/viewer.ftl +0 -63
  173. package/static/assets/pdfjs/web/locale/ta/viewer.ftl +0 -63
  174. package/static/assets/pdfjs/web/locale/te/viewer.ftl +0 -60
  175. package/static/assets/pdfjs/web/locale/tg/viewer.ftl +38 -0
  176. package/static/assets/pdfjs/web/locale/tl/viewer.ftl +0 -63
  177. package/static/assets/pdfjs/web/locale/tr/viewer.ftl +40 -2
  178. package/static/assets/pdfjs/web/locale/trs/viewer.ftl +0 -72
  179. package/static/assets/pdfjs/web/locale/ur/viewer.ftl +0 -60
  180. package/static/assets/pdfjs/web/locale/uz/viewer.ftl +0 -71
  181. package/static/assets/pdfjs/web/locale/vi/viewer.ftl +38 -0
  182. package/static/assets/pdfjs/web/locale/wo/viewer.ftl +0 -77
  183. package/static/assets/pdfjs/web/locale/xh/viewer.ftl +0 -71
  184. package/static/assets/pdfjs/web/locale/zh-CN/viewer.ftl +38 -0
  185. package/static/assets/pdfjs/web/locale/zh-TW/viewer.ftl +38 -0
  186. package/static/assets/pdfjs/web/viewer.css +649 -120
  187. package/static/assets/pdfjs/web/viewer.html +19 -0
  188. package/static/assets/pdfjs/web/viewer.mjs +489 -38
  189. package/static/assets/pdfjs/web/viewer.mjs.map +1 -1
  190. package/static/chunk-22EANI6R.js +1 -0
  191. package/static/{chunk-3GC2BQZD.js → chunk-2UWN7IQF.js} +1 -1
  192. package/static/{chunk-TCFKH6K6.js → chunk-2VSPDSJS.js} +1 -1
  193. package/static/{chunk-KZQCFEPT.js → chunk-34UZ7SYI.js} +1 -1
  194. package/static/{chunk-5YKWZT33.js → chunk-45UQJGGY.js} +1 -1
  195. package/static/{chunk-N2LYWNTC.js → chunk-5TEXH3LJ.js} +1 -1
  196. package/static/{chunk-MOVWEZ7J.js → chunk-66FMKVJX.js} +1 -1
  197. package/static/{chunk-XE5YHU5J.js → chunk-BIUNUYZ5.js} +1 -1
  198. package/static/chunk-CK4BY2NX.js +27 -0
  199. package/static/{chunk-T55FAU2O.js → chunk-CSBDAY77.js} +1 -1
  200. package/static/{chunk-6F55D74O.js → chunk-CXXPLBDZ.js} +1 -1
  201. package/static/{chunk-YCINY2YI.js → chunk-EILQG525.js} +1 -1
  202. package/static/{chunk-DGVNNICG.js → chunk-ENWABUR4.js} +1 -1
  203. package/static/{chunk-Y2CDUS4J.js → chunk-FR4AOLYL.js} +4 -4
  204. package/static/chunk-HW2H3ISM.js +559 -0
  205. package/static/{chunk-VHYIXL7R.js → chunk-HYMDGBZL.js} +1 -1
  206. package/static/{chunk-W3QXNDI5.js → chunk-IML5UYQG.js} +1 -1
  207. package/static/{chunk-GBCYYDCI.js → chunk-IPSMJHMQ.js} +1 -1
  208. package/static/{chunk-TXPODW5Q.js → chunk-JVCWYSNP.js} +1 -1
  209. package/static/{chunk-VMQMD36Z.js → chunk-KGPCIUD2.js} +1 -1
  210. package/static/{chunk-TNW2CGK6.js → chunk-KQZJSEM3.js} +1 -1
  211. package/static/{chunk-HZA7R43P.js → chunk-NPEMJJIU.js} +1 -1
  212. package/static/{chunk-WWIC7UW3.js → chunk-OEFBC4GG.js} +1 -1
  213. package/static/{chunk-VMUOUCEI.js → chunk-P734A3XZ.js} +1 -1
  214. package/static/{chunk-FQ4AFNGE.js → chunk-RASR4CK6.js} +1 -1
  215. package/static/{chunk-LJIGRUEF.js → chunk-RFMOUC22.js} +1 -1
  216. package/static/{chunk-TTQ37MUV.js → chunk-RSS6GYNE.js} +1 -1
  217. package/static/{chunk-TDQAEVZN.js → chunk-SBOQGGZX.js} +1 -1
  218. package/static/{chunk-PF4K7MVG.js → chunk-SJAFPXQV.js} +1 -1
  219. package/static/{chunk-C23BPTJZ.js → chunk-XTYGMF2V.js} +1 -1
  220. package/static/{chunk-B2Y2RNFP.js → chunk-YCWMV2YR.js} +1 -1
  221. package/static/{chunk-X43VWRFP.js → chunk-YGD22MWQ.js} +1 -1
  222. package/static/{chunk-MTRNPGS4.js → chunk-ZC5NIT55.js} +1 -1
  223. package/static/{chunk-PY3BGNJN.js → chunk-ZVY37DKS.js} +1 -1
  224. package/static/index.html +1 -1
  225. package/static/main-N5CZRHAO.js +7 -0
  226. package/static/chunk-RSNLYAN6.js +0 -560
  227. package/static/chunk-WHMS3PJ3.js +0 -24
  228. package/static/chunk-ZZ3LHYOY.js +0 -1
  229. package/static/main-7LDKYVXO.js +0 -10
@@ -1 +1 @@
1
- v5.4.54
1
+ v5.4.149
@@ -112,3 +112,34 @@
112
112
  background-color: rgb(255 255 255 / 0.6);
113
113
  color: rgb(0 0 0);
114
114
  }
115
+
116
+ .pdfBugGroupsLayer {
117
+ position: absolute;
118
+ inset: 0;
119
+ pointer-events: none;
120
+
121
+ > * {
122
+ position: absolute;
123
+ outline-color: red;
124
+ outline-width: 2px;
125
+
126
+ --hover-outline-style: solid !important;
127
+ --hover-background-color: rgb(255 0 0 / 0.2);
128
+
129
+ &:hover {
130
+ outline-style: var(--hover-outline-style);
131
+ background-color: var(--hover-background-color);
132
+ cursor: pointer;
133
+ }
134
+
135
+ .showDebugBoxes & {
136
+ outline-style: dashed;
137
+ }
138
+ }
139
+ }
140
+
141
+ .showDebugBoxes {
142
+ .pdfBugGroupsLayer {
143
+ pointer-events: all;
144
+ }
145
+ }
@@ -200,6 +200,10 @@ const StepperManager = (function StepperManagerClosure() {
200
200
  active: false,
201
201
  // Stepper specific functions.
202
202
  create(pageIndex) {
203
+ const pageContainer = document.querySelector(
204
+ `#viewer div[data-page-number="${pageIndex + 1}"]`
205
+ );
206
+
203
207
  const debug = document.createElement("div");
204
208
  debug.id = "stepper" + pageIndex;
205
209
  debug.hidden = true;
@@ -210,7 +214,12 @@ const StepperManager = (function StepperManagerClosure() {
210
214
  b.value = pageIndex;
211
215
  stepperChooser.append(b);
212
216
  const initBreakPoints = breakPoints[pageIndex] || [];
213
- const stepper = new Stepper(debug, pageIndex, initBreakPoints);
217
+ const stepper = new Stepper(
218
+ debug,
219
+ pageIndex,
220
+ initBreakPoints,
221
+ pageContainer
222
+ );
214
223
  steppers.push(stepper);
215
224
  if (steppers.length === 1) {
216
225
  this.selectStepper(pageIndex, false);
@@ -277,7 +286,7 @@ class Stepper {
277
286
  return simpleObj;
278
287
  }
279
288
 
280
- constructor(panel, pageIndex, initialBreakPoints) {
289
+ constructor(panel, pageIndex, initialBreakPoints, pageContainer) {
281
290
  this.panel = panel;
282
291
  this.breakPoint = 0;
283
292
  this.nextBreakPoint = null;
@@ -286,11 +295,20 @@ class Stepper {
286
295
  this.currentIdx = -1;
287
296
  this.operatorListIdx = 0;
288
297
  this.indentLevel = 0;
298
+ this.operatorGroups = null;
299
+ this.pageContainer = pageContainer;
289
300
  }
290
301
 
291
302
  init(operatorList) {
292
303
  const panel = this.panel;
293
304
  const content = this.#c("div", "c=continue, s=step");
305
+
306
+ const showBoxesToggle = this.#c("label", "Show bounding boxes");
307
+ const showBoxesCheckbox = this.#c("input");
308
+ showBoxesCheckbox.type = "checkbox";
309
+ showBoxesToggle.prepend(showBoxesCheckbox);
310
+ content.append(this.#c("br"), showBoxesToggle);
311
+
294
312
  const table = this.#c("table");
295
313
  content.append(table);
296
314
  table.cellSpacing = 0;
@@ -305,6 +323,22 @@ class Stepper {
305
323
  panel.append(content);
306
324
  this.table = table;
307
325
  this.updateOperatorList(operatorList);
326
+
327
+ const hoverStyle = this.#c("style");
328
+ this.hoverStyle = hoverStyle;
329
+ content.prepend(hoverStyle);
330
+ table.addEventListener("mouseover", this.#handleStepHover.bind(this));
331
+ table.addEventListener("mouseleave", e => {
332
+ hoverStyle.innerText = "";
333
+ });
334
+
335
+ showBoxesCheckbox.addEventListener("change", () => {
336
+ if (showBoxesCheckbox.checked) {
337
+ this.pageContainer.classList.add("showDebugBoxes");
338
+ } else {
339
+ this.pageContainer.classList.remove("showDebugBoxes");
340
+ }
341
+ });
308
342
  }
309
343
 
310
344
  updateOperatorList(operatorList) {
@@ -405,6 +439,114 @@ class Stepper {
405
439
  this.table.append(chunk);
406
440
  }
407
441
 
442
+ setOperatorGroups(groups) {
443
+ let boxesContainer = this.pageContainer.querySelector(".pdfBugGroupsLayer");
444
+ if (!boxesContainer) {
445
+ boxesContainer = this.#c("div");
446
+ boxesContainer.classList.add("pdfBugGroupsLayer");
447
+ this.pageContainer.append(boxesContainer);
448
+
449
+ boxesContainer.addEventListener(
450
+ "click",
451
+ this.#handleDebugBoxClick.bind(this)
452
+ );
453
+ boxesContainer.addEventListener(
454
+ "mouseover",
455
+ this.#handleDebugBoxHover.bind(this)
456
+ );
457
+ }
458
+ boxesContainer.innerHTML = "";
459
+
460
+ groups = groups.toSorted((a, b) => {
461
+ const diffs = [
462
+ a.minX - b.minX,
463
+ a.minY - b.minY,
464
+ b.maxX - a.maxX,
465
+ b.maxY - a.maxY,
466
+ ];
467
+ for (const diff of diffs) {
468
+ if (Math.abs(diff) > 0.01) {
469
+ return Math.sign(diff);
470
+ }
471
+ }
472
+ for (const diff of diffs) {
473
+ if (Math.abs(diff) > 0.0001) {
474
+ return Math.sign(diff);
475
+ }
476
+ }
477
+ return 0;
478
+ });
479
+ this.operatorGroups = groups;
480
+
481
+ for (let i = 0; i < groups.length; i++) {
482
+ const el = this.#c("div");
483
+ el.style.left = `${groups[i].minX * 100}%`;
484
+ el.style.top = `${groups[i].minY * 100}%`;
485
+ el.style.width = `${(groups[i].maxX - groups[i].minX) * 100}%`;
486
+ el.style.height = `${(groups[i].maxY - groups[i].minY) * 100}%`;
487
+ el.dataset.groupIdx = i;
488
+ boxesContainer.append(el);
489
+ }
490
+ }
491
+
492
+ #handleStepHover(e) {
493
+ const tr = e.target.closest("tr");
494
+ if (!tr || tr.dataset.idx === undefined) {
495
+ return;
496
+ }
497
+
498
+ const index = +tr.dataset.idx;
499
+
500
+ const closestGroupIndex =
501
+ this.operatorGroups?.findIndex(({ idx }) => idx === index) ?? -1;
502
+ if (closestGroupIndex === -1) {
503
+ this.hoverStyle.innerText = "";
504
+ return;
505
+ }
506
+
507
+ this.#highlightStepsGroup(closestGroupIndex);
508
+ }
509
+
510
+ #handleDebugBoxHover(e) {
511
+ if (e.target.dataset.groupIdx === undefined) {
512
+ return;
513
+ }
514
+
515
+ const groupIdx = Number(e.target.dataset.groupIdx);
516
+ this.#highlightStepsGroup(groupIdx);
517
+ }
518
+
519
+ #handleDebugBoxClick(e) {
520
+ if (e.target.dataset.groupIdx === undefined) {
521
+ return;
522
+ }
523
+
524
+ const groupIdx = Number(e.target.dataset.groupIdx);
525
+ const group = this.operatorGroups[groupIdx];
526
+
527
+ this.table.childNodes[group.idx].scrollIntoView();
528
+ }
529
+
530
+ #highlightStepsGroup(groupIndex) {
531
+ const group = this.operatorGroups[groupIndex];
532
+
533
+ this.hoverStyle.innerText = `#${this.panel.id} tr[data-idx="${group.idx}"] { background-color: rgba(0, 0, 0, 0.1); }`;
534
+
535
+ if (group.dependencies.length > 0) {
536
+ const selector = group.dependencies
537
+ .map(idx => `#${this.panel.id} tr[data-idx="${idx}"]`)
538
+ .join(", ");
539
+ this.hoverStyle.innerText += `${selector} { background-color: rgba(0, 255, 255, 0.1); }`;
540
+ }
541
+
542
+ this.hoverStyle.innerText += `
543
+ #viewer [data-page-number="${this.pageIndex + 1}"] .pdfBugGroupsLayer :nth-child(${groupIndex + 1}) {
544
+ background-color: var(--hover-background-color);
545
+ outline-style: var(--hover-outline-style);
546
+ }
547
+ `;
548
+ }
549
+
408
550
  getNextBreakPoint() {
409
551
  this.breakPoints.sort((a, b) => a - b);
410
552
  for (const breakPoint of this.breakPoints) {
@@ -1,3 +1,8 @@
1
1
  <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
2
- <path fill-rule="evenodd" clip-rule="evenodd" d="M13.4686 2.68492L12.9276 2.14392H2.40626L1.86526 2.68492V10.1102L2.40626 10.6512H6.71147C6.92794 10.6511 7.14165 10.7265 7.31497 10.8571L10.4357 13.3978V11.2299C10.4357 11.1049 10.485 10.9851 10.5795 10.8906C10.674 10.7961 10.7938 10.7468 10.9188 10.7468H12.9276L13.4686 10.2058V2.68492ZM2.52747 0.805556H12.7181C13.2412 0.805556 13.7478 1.01961 14.1371 1.40889C14.5264 1.79817 14.7405 2.30481 14.7405 2.82792V9.82792C14.7405 10.351 14.5264 10.8577 14.1371 11.247C13.7478 11.6363 13.2412 11.8503 12.7181 11.8503H11.4686V14.2055H10.4357L6.62747 11.8503H2.52747C2.00436 11.8503 1.49772 11.6363 1.10844 11.247C0.719162 10.8577 0.505107 10.351 0.505107 9.82792V2.82792C0.505107 2.30481 0.719162 1.79817 1.10844 1.40889C1.49772 1.01961 2.00436 0.805556 2.52747 0.805556ZM10.824 5.12016H4.46259C4.30418 5.12016 4.15436 5.05707 4.04541 4.94812C3.93646 4.83917 3.87337 4.68935 3.87337 4.53094C3.87337 4.37253 3.93646 4.22271 4.04541 4.11376C4.15436 4.00481 4.30418 3.94172 4.46259 3.94172H10.824C10.9824 3.94172 11.1322 4.00481 11.2412 4.11376C11.3501 4.22271 11.4132 4.37253 11.4132 4.53094C11.4132 4.68935 11.3501 4.83917 11.2412 4.94812C11.1322 5.05707 10.9824 5.12016 10.824 5.12016ZM8.82403 8.16137H4.46259C4.30418 8.16137 4.15436 8.09828 4.04541 7.98933C3.93646 7.88038 3.87337 7.73056 3.87337 7.57215C3.87337 7.41374 3.93646 7.26392 4.04541 7.15497C4.15436 7.04602 4.30418 6.98293 4.46259 6.98293H8.82403C8.98244 6.98293 9.13226 7.04602 9.24121 7.15497C9.35016 7.26392 9.41325 7.41374 9.41325 7.57215C9.41325 7.73056 9.35016 7.88038 9.24121 7.98933C9.13226 8.09828 8.98244 8.16137 8.82403 8.16137Z" fill="black"/>
2
+ <g>
3
+ <path d="M10.75 7H12.25V5.5H10.75V7Z" fill="black"/>
4
+ <path d="M7.5 7H9V5.5H7.5V7Z" fill="black"/>
5
+ <path d="M4.25 7H5.75V5.5H4.25V7Z" fill="black"/>
6
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M2 0C0.895786 0 0 0.895786 0 2V10.5C0 11.6042 0.895786 12.5 2 12.5H3V15.25C3 15.5405 3.16778 15.805 3.43066 15.9287C3.6937 16.0523 4.00473 16.0126 4.22852 15.8271L8.27051 12.4775L13.9941 12.4961C15.1007 12.4991 15.9999 11.6033 16 10.4961V2C16 0.895786 15.1042 0 14 0H2ZM14 1.5C14.2758 1.5 14.5 1.72421 14.5 2V10.4961C14.4999 10.7727 14.2753 10.9969 13.998 10.9961L8.00195 10.9775L7.87207 10.9893C7.74389 11.0115 7.62281 11.0664 7.52148 11.1504L4.5 13.6543V11.75C4.5 11.3358 4.16421 11 3.75 11H2C1.72421 11 1.5 10.7758 1.5 10.5V2C1.5 1.72421 1.72421 1.5 2 1.5H14Z" fill="black"/>
7
+ </g>
3
8
  </svg>
@@ -185,9 +185,6 @@ pdfjs-page-scale-actual = Dite kikome
185
185
  # $scale (Number) - percent value for page scale
186
186
  pdfjs-page-scale-percent = { $scale }%
187
187
 
188
- ## PDF page
189
-
190
-
191
188
  ## Loading indicator messages
192
189
 
193
190
  pdfjs-loading-error = Bal otime kun cano PDF.
@@ -213,63 +210,3 @@ pdfjs-password-invalid = Mung me donyo pe atir. Tim ber i tem doki.
213
210
  pdfjs-password-ok-button = OK
214
211
  pdfjs-password-cancel-button = Juki
215
212
  pdfjs-web-fonts-disabled = Kijuko dit pa coc me kakube woko: pe romo tic ki dit pa coc me PDF ma kiketo i kine.
216
-
217
- ## Editing
218
-
219
-
220
- ## Default editor aria labels
221
-
222
-
223
- ## Remove button for the various kind of editor.
224
-
225
-
226
- ##
227
-
228
-
229
- ## Alt-text dialog
230
-
231
-
232
- ## Editor resizers
233
- ## This is used in an aria label to help to understand the role of the resizer.
234
-
235
-
236
- ## Color picker
237
-
238
-
239
- ## Show all highlights
240
- ## This is a toggle button to show/hide all the highlights.
241
-
242
-
243
- ## New alt-text dialog
244
- ## Group note for entire feature: Alternative text (alt text) helps when people can't see the image. This feature includes a tool to create alt text automatically using an AI model that works locally on the user's device to preserve privacy.
245
-
246
-
247
- ## Image alt-text settings
248
-
249
-
250
- ## "Annotations removed" bar
251
-
252
-
253
- ## Add a signature dialog
254
-
255
-
256
- ## Tab names
257
-
258
-
259
- ## Tab panels
260
-
261
-
262
- ## Controls
263
-
264
-
265
- ## Dialog buttons
266
-
267
-
268
- ## Main menu for adding/removing signatures
269
-
270
-
271
- ## Editor toolbar
272
-
273
-
274
- ## Edit signature description dialog
275
-
@@ -94,14 +94,6 @@ pdfjs-document-properties-producer = PDF-vervaardiger:
94
94
  pdfjs-document-properties-version = PDF-weergawe:
95
95
  pdfjs-document-properties-page-count = Aantal bladsye:
96
96
 
97
- ## Variables:
98
- ## $width (Number) - the width of the (current) page
99
- ## $height (Number) - the height of the (current) page
100
- ## $unit (String) - the unit of measurement of the (current) page
101
- ## $name (String) - the name of the (current) page
102
- ## $orientation (String) - the orientation of the (current) page
103
-
104
-
105
97
  ##
106
98
 
107
99
  pdfjs-document-properties-close-button = Sluit
@@ -172,9 +164,6 @@ pdfjs-page-scale-actual = Werklike grootte
172
164
  # $scale (Number) - percent value for page scale
173
165
  pdfjs-page-scale-percent = { $scale }%
174
166
 
175
- ## PDF page
176
-
177
-
178
167
  ## Loading indicator messages
179
168
 
180
169
  pdfjs-loading-error = 'n Fout het voorgekom met die laai van die PDF.
@@ -200,63 +189,3 @@ pdfjs-password-invalid = Ongeldige wagwoord. Probeer gerus weer.
200
189
  pdfjs-password-ok-button = OK
201
190
  pdfjs-password-cancel-button = Kanselleer
202
191
  pdfjs-web-fonts-disabled = Webfonte is gedeaktiveer: kan nie PDF-fonte wat ingebed is, gebruik nie.
203
-
204
- ## Editing
205
-
206
-
207
- ## Default editor aria labels
208
-
209
-
210
- ## Remove button for the various kind of editor.
211
-
212
-
213
- ##
214
-
215
-
216
- ## Alt-text dialog
217
-
218
-
219
- ## Editor resizers
220
- ## This is used in an aria label to help to understand the role of the resizer.
221
-
222
-
223
- ## Color picker
224
-
225
-
226
- ## Show all highlights
227
- ## This is a toggle button to show/hide all the highlights.
228
-
229
-
230
- ## New alt-text dialog
231
- ## Group note for entire feature: Alternative text (alt text) helps when people can't see the image. This feature includes a tool to create alt text automatically using an AI model that works locally on the user's device to preserve privacy.
232
-
233
-
234
- ## Image alt-text settings
235
-
236
-
237
- ## "Annotations removed" bar
238
-
239
-
240
- ## Add a signature dialog
241
-
242
-
243
- ## Tab names
244
-
245
-
246
- ## Tab panels
247
-
248
-
249
- ## Controls
250
-
251
-
252
- ## Dialog buttons
253
-
254
-
255
- ## Main menu for adding/removing signatures
256
-
257
-
258
- ## Editor toolbar
259
-
260
-
261
- ## Edit signature description dialog
262
-
@@ -213,9 +213,6 @@ pdfjs-page-scale-actual = Grandaria actual
213
213
  # $scale (Number) - percent value for page scale
214
214
  pdfjs-page-scale-percent = { $scale }%
215
215
 
216
- ## PDF page
217
-
218
-
219
216
  ## Loading indicator messages
220
217
 
221
218
  pdfjs-loading-error = S'ha produciu una error en cargar o PDF.
@@ -245,63 +242,3 @@ pdfjs-password-invalid = Clau invalida. Torna a intentar-lo.
245
242
  pdfjs-password-ok-button = Acceptar
246
243
  pdfjs-password-cancel-button = Cancelar
247
244
  pdfjs-web-fonts-disabled = As fuents web son desactivadas: no se puet incrustar fichers PDF.
248
-
249
- ## Editing
250
-
251
-
252
- ## Default editor aria labels
253
-
254
-
255
- ## Remove button for the various kind of editor.
256
-
257
-
258
- ##
259
-
260
-
261
- ## Alt-text dialog
262
-
263
-
264
- ## Editor resizers
265
- ## This is used in an aria label to help to understand the role of the resizer.
266
-
267
-
268
- ## Color picker
269
-
270
-
271
- ## Show all highlights
272
- ## This is a toggle button to show/hide all the highlights.
273
-
274
-
275
- ## New alt-text dialog
276
- ## Group note for entire feature: Alternative text (alt text) helps when people can't see the image. This feature includes a tool to create alt text automatically using an AI model that works locally on the user's device to preserve privacy.
277
-
278
-
279
- ## Image alt-text settings
280
-
281
-
282
- ## "Annotations removed" bar
283
-
284
-
285
- ## Add a signature dialog
286
-
287
-
288
- ## Tab names
289
-
290
-
291
- ## Tab panels
292
-
293
-
294
- ## Controls
295
-
296
-
297
- ## Dialog buttons
298
-
299
-
300
- ## Main menu for adding/removing signatures
301
-
302
-
303
- ## Editor toolbar
304
-
305
-
306
- ## Edit signature description dialog
307
-
@@ -189,63 +189,3 @@ pdfjs-annotation-date-string = { $date }, { $time }
189
189
 
190
190
  pdfjs-password-ok-button = Aceptar
191
191
  pdfjs-password-cancel-button = Encaboxar
192
-
193
- ## Editing
194
-
195
-
196
- ## Default editor aria labels
197
-
198
-
199
- ## Remove button for the various kind of editor.
200
-
201
-
202
- ##
203
-
204
-
205
- ## Alt-text dialog
206
-
207
-
208
- ## Editor resizers
209
- ## This is used in an aria label to help to understand the role of the resizer.
210
-
211
-
212
- ## Color picker
213
-
214
-
215
- ## Show all highlights
216
- ## This is a toggle button to show/hide all the highlights.
217
-
218
-
219
- ## New alt-text dialog
220
- ## Group note for entire feature: Alternative text (alt text) helps when people can't see the image. This feature includes a tool to create alt text automatically using an AI model that works locally on the user's device to preserve privacy.
221
-
222
-
223
- ## Image alt-text settings
224
-
225
-
226
- ## "Annotations removed" bar
227
-
228
-
229
- ## Add a signature dialog
230
-
231
-
232
- ## Tab names
233
-
234
-
235
- ## Tab panels
236
-
237
-
238
- ## Controls
239
-
240
-
241
- ## Dialog buttons
242
-
243
-
244
- ## Main menu for adding/removing signatures
245
-
246
-
247
- ## Editor toolbar
248
-
249
-
250
- ## Edit signature description dialog
251
-
@@ -213,9 +213,6 @@ pdfjs-page-scale-actual = Hazırkı Həcm
213
213
  # $scale (Number) - percent value for page scale
214
214
  pdfjs-page-scale-percent = { $scale }%
215
215
 
216
- ## PDF page
217
-
218
-
219
216
  ## Loading indicator messages
220
217
 
221
218
  pdfjs-loading-error = PDF yüklenərkən bir səhv yarandı.
@@ -245,63 +242,3 @@ pdfjs-password-invalid = Parol səhvdir. Bir daha yoxlayın.
245
242
  pdfjs-password-ok-button = Tamam
246
243
  pdfjs-password-cancel-button = Ləğv et
247
244
  pdfjs-web-fonts-disabled = Web Şriftlər söndürülüb: yerləşdirilmiş PDF şriftlərini istifadə etmək mümkün deyil.
248
-
249
- ## Editing
250
-
251
-
252
- ## Default editor aria labels
253
-
254
-
255
- ## Remove button for the various kind of editor.
256
-
257
-
258
- ##
259
-
260
-
261
- ## Alt-text dialog
262
-
263
-
264
- ## Editor resizers
265
- ## This is used in an aria label to help to understand the role of the resizer.
266
-
267
-
268
- ## Color picker
269
-
270
-
271
- ## Show all highlights
272
- ## This is a toggle button to show/hide all the highlights.
273
-
274
-
275
- ## New alt-text dialog
276
- ## Group note for entire feature: Alternative text (alt text) helps when people can't see the image. This feature includes a tool to create alt text automatically using an AI model that works locally on the user's device to preserve privacy.
277
-
278
-
279
- ## Image alt-text settings
280
-
281
-
282
- ## "Annotations removed" bar
283
-
284
-
285
- ## Add a signature dialog
286
-
287
-
288
- ## Tab names
289
-
290
-
291
- ## Tab panels
292
-
293
-
294
- ## Controls
295
-
296
-
297
- ## Dialog buttons
298
-
299
-
300
- ## Main menu for adding/removing signatures
301
-
302
-
303
- ## Editor toolbar
304
-
305
-
306
- ## Edit signature description dialog
307
-
@@ -304,9 +304,13 @@ pdfjs-web-fonts-disabled = Шрыфты Сеціва забаронены: не
304
304
 
305
305
  pdfjs-editor-free-text-button =
306
306
  .title = Тэкст
307
+ pdfjs-editor-color-picker-free-text-input =
308
+ .title = Змяніць колер тэксту
307
309
  pdfjs-editor-free-text-button-label = Тэкст
308
310
  pdfjs-editor-ink-button =
309
311
  .title = Маляваць
312
+ pdfjs-editor-color-picker-ink-input =
313
+ .title = Змяніць колер малюнка
310
314
  pdfjs-editor-ink-button-label = Маляваць
311
315
  pdfjs-editor-stamp-button =
312
316
  .title = Дадаць або змяніць выявы
@@ -318,6 +322,10 @@ pdfjs-highlight-floating-button1 =
318
322
  .title = Падфарбаваць
319
323
  .aria-label = Падфарбаваць
320
324
  pdfjs-highlight-floating-button-label = Падфарбаваць
325
+ pdfjs-comment-floating-button =
326
+ .title = Каментаваць
327
+ .aria-label = Каментаваць
328
+ pdfjs-comment-floating-button-label = Каментаваць
321
329
  pdfjs-editor-signature-button =
322
330
  .title = Дадаць подпіс
323
331
  pdfjs-editor-signature-button-label = Дадаць подпіс
@@ -526,6 +534,14 @@ pdfjs-editor-alt-text-settings-show-dialog-button-label = Адразу пака
526
534
  pdfjs-editor-alt-text-settings-show-dialog-description = Дапамагае пераканацца, што ўсе вашы выявы маюць альтэрнатыўны тэкст.
527
535
  pdfjs-editor-alt-text-settings-close-button = Закрыць
528
536
 
537
+ ## Accessibility labels (announced by screen readers) for objects added to the editor.
538
+
539
+ pdfjs-editor-highlight-added-alert = Вылучэнне дададзена
540
+ pdfjs-editor-freetext-added-alert = Тэкст дададзены
541
+ pdfjs-editor-ink-added-alert = Малюнак дададзены
542
+ pdfjs-editor-stamp-added-alert = Выява дададзена
543
+ pdfjs-editor-signature-added-alert = Подпіс дададзены
544
+
529
545
  ## "Annotations removed" bar
530
546
 
531
547
  pdfjs-editor-undo-bar-message-highlight = Падсвятленне выдалена
@@ -595,6 +611,8 @@ pdfjs-editor-add-signature-save-checkbox = Захаваць подпіс
595
611
  pdfjs-editor-add-signature-save-warning-message = Вы дасягнулі ліміту ў 5 захаваных подпісаў. Выдаліце адзін, каб захаваць іншы.
596
612
  pdfjs-editor-add-signature-image-upload-error-title = Не ўдалося загрузіць выяву
597
613
  pdfjs-editor-add-signature-image-upload-error-description = Праверце падключэнне да сеткі ці паспрабуйце іншую выяву.
614
+ pdfjs-editor-add-signature-image-no-data-error-title = Не ўдалося пераўтварыць гэту выяву ў подпіс
615
+ pdfjs-editor-add-signature-image-no-data-error-description = Калі ласка, паспрабуйце зацягнуць іншую выяву.
598
616
  pdfjs-editor-add-signature-error-close-button = Закрыць
599
617
 
600
618
  ## Dialog buttons
@@ -603,6 +621,26 @@ pdfjs-editor-add-signature-cancel-button = Скасаваць
603
621
  pdfjs-editor-add-signature-add-button = Дадаць
604
622
  pdfjs-editor-edit-signature-update-button = Абнавіць
605
623
 
624
+ ## Edit a comment dialog
625
+
626
+ pdfjs-editor-edit-comment-actions-button-label = Дзеянні
627
+ pdfjs-editor-edit-comment-actions-button =
628
+ .title = Дзеянні
629
+ pdfjs-editor-edit-comment-close-button-label = Закрыць
630
+ pdfjs-editor-edit-comment-close-button =
631
+ .title = Закрыць
632
+ pdfjs-editor-edit-comment-actions-edit-button-label = Праўка
633
+ pdfjs-editor-edit-comment-actions-delete-button-label = Выдаліць
634
+ pdfjs-editor-edit-comment-manager-text-input =
635
+ .placeholder = Увядзіце свой каментарый
636
+ pdfjs-editor-edit-comment-manager-cancel-button = Скасаваць
637
+ pdfjs-editor-edit-comment-manager-save-button = Захаваць
638
+
639
+ ## Edit a comment button in the editor toolbar
640
+
641
+ pdfjs-editor-edit-comment-button =
642
+ .title = Змяніць каментарый
643
+
606
644
  ## Main menu for adding/removing signatures
607
645
 
608
646
  pdfjs-editor-delete-signature-button1 =