@limetech/lime-crm-building-blocks 1.86.2 → 1.87.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 (225) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/dist/cjs/{highlight-item.handler-99d5a0b6.js → highlight-item.handler-584ab58a.js} +2 -2
  3. package/dist/cjs/{index-3da101cc.js → index-ff255a0d.js} +3 -28
  4. package/dist/cjs/{index.esm-d6513e37.js → index.esm-9effb196.js} +1 -1
  5. package/dist/cjs/lime-crm-building-blocks.cjs.js +1 -1
  6. package/dist/cjs/limebb-browser.cjs.entry.js +2 -2
  7. package/dist/cjs/limebb-chat-item_2.cjs.entry.js +8 -3
  8. package/dist/cjs/limebb-chat-list.cjs.entry.js +34 -16
  9. package/dist/cjs/limebb-component-config.cjs.entry.js +5 -3
  10. package/dist/cjs/limebb-component-picker.cjs.entry.js +2 -2
  11. package/dist/cjs/limebb-currency-picker.cjs.entry.js +3 -3
  12. package/dist/cjs/limebb-dashboard-widget.cjs.entry.js +1 -1
  13. package/dist/cjs/limebb-date-picker.cjs.entry.js +5 -5
  14. package/dist/cjs/limebb-date-range.cjs.entry.js +1 -1
  15. package/dist/cjs/limebb-empty-state.cjs.entry.js +1 -1
  16. package/dist/cjs/limebb-feed-timeline-item.cjs.entry.js +4 -5
  17. package/dist/cjs/limebb-feed.cjs.entry.js +4 -4
  18. package/dist/cjs/limebb-icon-picker.cjs.entry.js +10 -6
  19. package/dist/cjs/limebb-info-tile-currency-format.cjs.entry.js +1 -1
  20. package/dist/cjs/limebb-info-tile-date-format.cjs.entry.js +2 -2
  21. package/dist/cjs/limebb-info-tile-decimal-format.cjs.entry.js +1 -1
  22. package/dist/cjs/limebb-info-tile-format.cjs.entry.js +2 -1
  23. package/dist/cjs/limebb-info-tile-relative-date-format.cjs.entry.js +1 -1
  24. package/dist/cjs/limebb-info-tile-unit-format.cjs.entry.js +2 -2
  25. package/dist/cjs/limebb-info-tile.cjs.entry.js +21 -22
  26. package/dist/cjs/limebb-kanban-group.cjs.entry.js +3 -3
  27. package/dist/cjs/limebb-kanban-item.cjs.entry.js +3 -3
  28. package/dist/cjs/limebb-kanban.cjs.entry.js +1 -1
  29. package/dist/cjs/limebb-limeobject-file-viewer.cjs.entry.js +4 -4
  30. package/dist/cjs/limebb-loader.cjs.entry.js +3 -3
  31. package/dist/cjs/limebb-locale-picker.cjs.entry.js +14 -6
  32. package/dist/cjs/limebb-mention-group-counter.cjs.entry.js +1 -1
  33. package/dist/cjs/limebb-mention.cjs.entry.js +5 -6
  34. package/dist/cjs/limebb-navigation-button_2.cjs.entry.js +5 -5
  35. package/dist/cjs/limebb-notification-item.cjs.entry.js +2 -2
  36. package/dist/cjs/limebb-notification-list.cjs.entry.js +31 -14
  37. package/dist/cjs/limebb-percentage-visualizer.cjs.entry.js +7 -8
  38. package/dist/cjs/limebb-text-editor-picker.cjs.entry.js +1 -1
  39. package/dist/cjs/limebb-text-editor.cjs.entry.js +42 -39
  40. package/dist/cjs/limebb-trend-indicator.cjs.entry.js +8 -8
  41. package/dist/cjs/loader.cjs.js +1 -1
  42. package/dist/cjs/{non-null-b8d9b4b4.js → non-null-3bf14aa1.js} +5 -0
  43. package/dist/cjs/{percentage-class-9decca4f.js → percentage-class-e4f0a52d.js} +2 -2
  44. package/dist/collection/components/chat-list/chat-item/chat-item.css +4 -0
  45. package/dist/collection/components/chat-list/chat-item/chat-item.js +5 -0
  46. package/dist/collection/components/chat-list/chat-list.js +11 -7
  47. package/dist/collection/components/chat-list/{processChatItems.js → process-chat-items.js} +22 -8
  48. package/dist/collection/components/component-command-picker/component-config/component-config.js +3 -1
  49. package/dist/collection/components/date-picker/to-server-date.js +3 -3
  50. package/dist/collection/components/feed/feed-item/feed-timeline-item.css +4 -4
  51. package/dist/collection/components/feed/feed-item/feed-timeline-item.js +1 -2
  52. package/dist/collection/components/feed/feed.js +1 -1
  53. package/dist/collection/components/feed/highlight-item/highlight-item.handler.js +2 -2
  54. package/dist/collection/components/icon-picker/search.js +9 -0
  55. package/dist/collection/components/info-tile/format/config/info-tile-date-format.js +1 -1
  56. package/dist/collection/components/info-tile/format/config/info-tile-format.js +1 -0
  57. package/dist/collection/components/info-tile/format/config/info-tile-unit-format.js +1 -1
  58. package/dist/collection/components/info-tile/format/date-time.js +12 -11
  59. package/dist/collection/components/info-tile/format/number.js +3 -3
  60. package/dist/collection/components/info-tile/format/relative-date-time.js +2 -4
  61. package/dist/collection/components/info-tile/info-tile.js +2 -2
  62. package/dist/collection/components/kanban/kanban-group/kanban-group.css +4 -4
  63. package/dist/collection/components/kanban/kanban-item/kanban-item.css +4 -4
  64. package/dist/collection/components/limeobject/file-viewer/file-viewer.js +2 -2
  65. package/dist/collection/components/locale-picker/language.js +10 -1
  66. package/dist/collection/components/locale-picker/locale-picker.js +2 -3
  67. package/dist/collection/components/mention/mention.js +0 -1
  68. package/dist/collection/components/navigation-button/navigation-button.css +4 -3
  69. package/dist/collection/components/notification-list/notification-list.css +2 -2
  70. package/dist/collection/components/notification-list/notification-list.js +7 -4
  71. package/dist/collection/components/notification-list/{processNotificationItems.js → process-notification-items.js} +22 -8
  72. package/dist/collection/components/percentage-visualizer/percentage-visualizer.js +5 -6
  73. package/dist/collection/components/summary-popover/summary-popover.js +3 -3
  74. package/dist/collection/components/text-editor/mentions.js +6 -8
  75. package/dist/collection/components/text-editor/text-editor.js +2 -4
  76. package/dist/collection/components/text-editor/uploader/building-blocks-upload-handler.js +8 -9
  77. package/dist/collection/components/text-editor/uploader/building-blocks-uploader.js +1 -1
  78. package/dist/collection/components/text-editor/utils/searcher-utils.js +5 -0
  79. package/dist/collection/components/trend-indicator/trend-indicator.js +6 -6
  80. package/dist/collection/util/dom.js +3 -3
  81. package/dist/collection/util/limetype.js +11 -11
  82. package/dist/collection/util/non-null.js +5 -0
  83. package/dist/collection/util/percentage-class.js +2 -2
  84. package/dist/collection/util/random-string.js +6 -3
  85. package/dist/components/chat-item.js +6 -1
  86. package/dist/components/date-picker.js +3 -3
  87. package/dist/components/feed-timeline-item.js +2 -3
  88. package/dist/components/highlight-item.handler.js +2 -2
  89. package/dist/components/kanban-group.js +1 -1
  90. package/dist/components/kanban-item.js +1 -1
  91. package/dist/components/limebb-chat-list.js +32 -14
  92. package/dist/components/limebb-component-config.js +3 -1
  93. package/dist/components/limebb-feed.js +1 -1
  94. package/dist/components/limebb-icon-picker.js +9 -5
  95. package/dist/components/limebb-info-tile-date-format.js +1 -1
  96. package/dist/components/limebb-info-tile-format.js +1 -0
  97. package/dist/components/limebb-info-tile-unit-format.js +1 -1
  98. package/dist/components/limebb-info-tile.js +19 -20
  99. package/dist/components/limebb-limeobject-file-viewer.js +2 -2
  100. package/dist/components/limebb-locale-picker.js +12 -4
  101. package/dist/components/limebb-mention.js +3 -4
  102. package/dist/components/limebb-notification-list.js +29 -12
  103. package/dist/components/limebb-percentage-visualizer.js +5 -6
  104. package/dist/components/limebb-text-editor.js +39 -36
  105. package/dist/components/limebb-trend-indicator.js +6 -6
  106. package/dist/components/navigation-button.js +1 -1
  107. package/dist/components/non-null.js +5 -0
  108. package/dist/components/percentage-class.js +2 -2
  109. package/dist/components/summary-popover.js +3 -3
  110. package/dist/esm/{highlight-item.handler-96b59c20.js → highlight-item.handler-dfbf11c0.js} +2 -2
  111. package/dist/esm/{index-cdbbc18d.js → index-96dd111f.js} +3 -28
  112. package/dist/esm/{index.esm-5e14dac9.js → index.esm-10a8f67c.js} +1 -1
  113. package/dist/esm/lime-crm-building-blocks.js +2 -2
  114. package/dist/esm/limebb-browser.entry.js +2 -2
  115. package/dist/esm/limebb-chat-item_2.entry.js +8 -3
  116. package/dist/esm/limebb-chat-list.entry.js +34 -16
  117. package/dist/esm/limebb-component-config.entry.js +5 -3
  118. package/dist/esm/limebb-component-picker.entry.js +2 -2
  119. package/dist/esm/limebb-currency-picker.entry.js +3 -3
  120. package/dist/esm/limebb-dashboard-widget.entry.js +1 -1
  121. package/dist/esm/limebb-date-picker.entry.js +5 -5
  122. package/dist/esm/limebb-date-range.entry.js +1 -1
  123. package/dist/esm/limebb-empty-state.entry.js +1 -1
  124. package/dist/esm/limebb-feed-timeline-item.entry.js +4 -5
  125. package/dist/esm/limebb-feed.entry.js +4 -4
  126. package/dist/esm/limebb-icon-picker.entry.js +10 -6
  127. package/dist/esm/limebb-info-tile-currency-format.entry.js +1 -1
  128. package/dist/esm/limebb-info-tile-date-format.entry.js +2 -2
  129. package/dist/esm/limebb-info-tile-decimal-format.entry.js +1 -1
  130. package/dist/esm/limebb-info-tile-format.entry.js +2 -1
  131. package/dist/esm/limebb-info-tile-relative-date-format.entry.js +1 -1
  132. package/dist/esm/limebb-info-tile-unit-format.entry.js +2 -2
  133. package/dist/esm/limebb-info-tile.entry.js +21 -22
  134. package/dist/esm/limebb-kanban-group.entry.js +3 -3
  135. package/dist/esm/limebb-kanban-item.entry.js +3 -3
  136. package/dist/esm/limebb-kanban.entry.js +1 -1
  137. package/dist/esm/limebb-limeobject-file-viewer.entry.js +4 -4
  138. package/dist/esm/limebb-loader.entry.js +3 -3
  139. package/dist/esm/limebb-locale-picker.entry.js +14 -6
  140. package/dist/esm/limebb-mention-group-counter.entry.js +1 -1
  141. package/dist/esm/limebb-mention.entry.js +5 -6
  142. package/dist/esm/limebb-navigation-button_2.entry.js +5 -5
  143. package/dist/esm/limebb-notification-item.entry.js +2 -2
  144. package/dist/esm/limebb-notification-list.entry.js +31 -14
  145. package/dist/esm/limebb-percentage-visualizer.entry.js +7 -8
  146. package/dist/esm/limebb-text-editor-picker.entry.js +1 -1
  147. package/dist/esm/limebb-text-editor.entry.js +42 -39
  148. package/dist/esm/limebb-trend-indicator.entry.js +8 -8
  149. package/dist/esm/loader.js +2 -2
  150. package/dist/esm/non-null-5a66a269.js +10 -0
  151. package/dist/esm/{percentage-class-78377c1e.js → percentage-class-1e4748e8.js} +2 -2
  152. package/dist/lime-crm-building-blocks/lime-crm-building-blocks.esm.js +1 -1
  153. package/dist/lime-crm-building-blocks/{p-38eec842.entry.js → p-013b852a.entry.js} +1 -1
  154. package/dist/lime-crm-building-blocks/p-01cff04f.entry.js +1 -0
  155. package/dist/lime-crm-building-blocks/{p-ccc748a1.entry.js → p-0f925b3d.entry.js} +1 -1
  156. package/dist/lime-crm-building-blocks/{p-29e90714.entry.js → p-10ac8b3e.entry.js} +1 -1
  157. package/dist/lime-crm-building-blocks/p-1556b545.js +2 -0
  158. package/dist/lime-crm-building-blocks/p-1ff94c41.entry.js +1 -0
  159. package/dist/lime-crm-building-blocks/{p-b8d49d3e.entry.js → p-218b7f38.entry.js} +1 -1
  160. package/dist/lime-crm-building-blocks/p-235aec61.entry.js +1 -0
  161. package/dist/lime-crm-building-blocks/{p-ebbd8784.entry.js → p-25e1a434.entry.js} +1 -1
  162. package/dist/lime-crm-building-blocks/{p-e38afb31.entry.js → p-292631ea.entry.js} +1 -1
  163. package/dist/lime-crm-building-blocks/{p-67e1ea69.entry.js → p-302e0feb.entry.js} +1 -1
  164. package/dist/lime-crm-building-blocks/p-305a14bf.entry.js +1 -0
  165. package/dist/lime-crm-building-blocks/{p-99be75d5.entry.js → p-3a406a20.entry.js} +1 -1
  166. package/dist/lime-crm-building-blocks/{p-3dce616c.entry.js → p-3bd02e86.entry.js} +1 -1
  167. package/dist/lime-crm-building-blocks/{p-ca79dc23.entry.js → p-4aac81ef.entry.js} +1 -1
  168. package/dist/lime-crm-building-blocks/{p-eab00e3c.entry.js → p-4caa8bbe.entry.js} +1 -1
  169. package/dist/lime-crm-building-blocks/{p-d0ce5a35.entry.js → p-568b7520.entry.js} +1 -1
  170. package/dist/lime-crm-building-blocks/{p-0a331c84.entry.js → p-5f0d0df3.entry.js} +1 -1
  171. package/dist/lime-crm-building-blocks/p-66352a1e.js +1 -0
  172. package/dist/lime-crm-building-blocks/p-6b1a6487.entry.js +1 -0
  173. package/dist/lime-crm-building-blocks/p-6c56121c.entry.js +1 -0
  174. package/dist/lime-crm-building-blocks/{p-1eb8fb75.entry.js → p-70ab5db7.entry.js} +1 -1
  175. package/dist/lime-crm-building-blocks/p-75abe3ad.entry.js +1 -0
  176. package/dist/lime-crm-building-blocks/{p-58faab30.entry.js → p-8491aaa1.entry.js} +1 -1
  177. package/dist/lime-crm-building-blocks/p-8bf72bb4.entry.js +1 -0
  178. package/dist/lime-crm-building-blocks/p-8e316957.entry.js +1 -0
  179. package/dist/lime-crm-building-blocks/{p-3b9766cc.js → p-9b6ec98b.js} +1 -1
  180. package/dist/lime-crm-building-blocks/p-a9b0d2e5.entry.js +1 -0
  181. package/dist/lime-crm-building-blocks/p-ad52e723.entry.js +1 -0
  182. package/dist/lime-crm-building-blocks/p-af8c22c4.entry.js +1 -0
  183. package/dist/lime-crm-building-blocks/p-b107fe24.entry.js +1 -0
  184. package/dist/lime-crm-building-blocks/{p-27786967.entry.js → p-b5f15f73.entry.js} +1 -1
  185. package/dist/lime-crm-building-blocks/{p-af6e6696.entry.js → p-c45be80e.entry.js} +1 -1
  186. package/dist/lime-crm-building-blocks/p-c5d79dd5.entry.js +1 -0
  187. package/dist/lime-crm-building-blocks/{p-adcb57c6.entry.js → p-dd0370cd.entry.js} +1 -1
  188. package/dist/lime-crm-building-blocks/{p-0779e2b4.entry.js → p-e1e5f461.entry.js} +1 -1
  189. package/dist/lime-crm-building-blocks/{p-bf322752.entry.js → p-e2128caf.entry.js} +1 -1
  190. package/dist/lime-crm-building-blocks/p-f820c983.entry.js +1 -0
  191. package/dist/test/setup.js +15 -5
  192. package/dist/types/components/chat-list/{processChatItems.d.ts → process-chat-items.d.ts} +17 -5
  193. package/dist/types/components/date-picker/to-server-date.d.ts +3 -3
  194. package/dist/types/components/icon-picker/search.d.ts +9 -0
  195. package/dist/types/components/locale-picker/language.d.ts +9 -0
  196. package/dist/types/components/notification-list/{processNotificationItems.d.ts → process-notification-items.d.ts} +17 -5
  197. package/dist/types/components/text-editor/mentions.d.ts +2 -2
  198. package/dist/types/components/text-editor/uploader/building-blocks-upload-handler.d.ts +8 -8
  199. package/dist/types/components/text-editor/utils/searcher-utils.d.ts +5 -0
  200. package/dist/types/home/runner/work/lime-crm-building-blocks/lime-crm-building-blocks/.stencil/test/setup.d.ts +10 -0
  201. package/dist/types/util/dom.d.ts +3 -3
  202. package/dist/types/util/limetype.d.ts +11 -11
  203. package/dist/types/util/non-null.d.ts +4 -0
  204. package/dist/types/util/percentage-class.d.ts +2 -2
  205. package/package.json +8 -25
  206. package/dist/esm/non-null-d9b0b630.js +0 -5
  207. package/dist/lime-crm-building-blocks/p-06839012.entry.js +0 -1
  208. package/dist/lime-crm-building-blocks/p-10452278.entry.js +0 -1
  209. package/dist/lime-crm-building-blocks/p-2b8bfe92.entry.js +0 -1
  210. package/dist/lime-crm-building-blocks/p-2e496d18.entry.js +0 -1
  211. package/dist/lime-crm-building-blocks/p-31a55daa.entry.js +0 -1
  212. package/dist/lime-crm-building-blocks/p-37e0254e.entry.js +0 -1
  213. package/dist/lime-crm-building-blocks/p-3d961c1b.entry.js +0 -1
  214. package/dist/lime-crm-building-blocks/p-43c76027.entry.js +0 -1
  215. package/dist/lime-crm-building-blocks/p-46bf22fa.entry.js +0 -1
  216. package/dist/lime-crm-building-blocks/p-506dfcff.js +0 -1
  217. package/dist/lime-crm-building-blocks/p-51e87162.entry.js +0 -1
  218. package/dist/lime-crm-building-blocks/p-a581f635.entry.js +0 -1
  219. package/dist/lime-crm-building-blocks/p-acce6160.entry.js +0 -1
  220. package/dist/lime-crm-building-blocks/p-c4e6dcf4.entry.js +0 -1
  221. package/dist/lime-crm-building-blocks/p-cf06416b.entry.js +0 -1
  222. package/dist/lime-crm-building-blocks/p-d312f578.entry.js +0 -1
  223. package/dist/lime-crm-building-blocks/p-d736c794.js +0 -2
  224. /package/dist/lime-crm-building-blocks/{p-2b0ec58c.js → p-10e16feb.js} +0 -0
  225. /package/dist/lime-crm-building-blocks/{p-6fd28e32.js → p-1484e300.js} +0 -0
@@ -105,6 +105,7 @@ const InfoTileAdminConfig = /*@__PURE__*/ proxyCustomElement(class InfoTileAdmin
105
105
  }
106
106
  let type = this.value.type;
107
107
  if (this.isNumberFormat(this.value)) {
108
+ // eslint-disable-next-line @typescript-eslint/no-non-null-asserted-optional-chain
108
109
  type = (_b = this.value.options) === null || _b === void 0 ? void 0 : _b.style;
109
110
  }
110
111
  const ComponentName = `limebb-info-tile-${type}-format`;
@@ -61,7 +61,7 @@ const InfoTileAdminConfig = /*@__PURE__*/ proxyCustomElement(class InfoTileAdmin
61
61
  this.change = createEvent(this, "change", 7);
62
62
  this.getOptionValue = (option) => option.value;
63
63
  this.getAffixValue = (options) => {
64
- if (!options.length) {
64
+ if (options.length === 0) {
65
65
  return;
66
66
  }
67
67
  return options.map((o) => o.value);
@@ -158,28 +158,29 @@ class DateTimeFormatter {
158
158
  };
159
159
  }
160
160
  formatValue(date, format) {
161
- var _a, _b;
162
161
  const options = Object.assign({}, format.options);
163
- (_a = format.prefix) === null || _a === void 0 ? void 0 : _a.forEach((prefix) => {
164
- delete options[prefix];
165
- });
166
- (_b = format.suffix) === null || _b === void 0 ? void 0 : _b.forEach((suffix) => {
167
- delete options[suffix];
168
- });
162
+ if (format.prefix)
163
+ for (const prefix of format.prefix) {
164
+ delete options[prefix];
165
+ }
166
+ if (format.suffix)
167
+ for (const suffix of format.suffix) {
168
+ delete options[suffix];
169
+ }
169
170
  const formatter = new Intl.DateTimeFormat(this.locale, options);
170
171
  return formatter.format(date);
171
172
  }
172
173
  formatAffix(affix, date, format) {
173
174
  const options = Object.assign({}, format.options);
174
- Object.keys(options).forEach((option) => {
175
+ for (const option of Object.keys(options)) {
175
176
  if (option === 'hour12') {
176
- return;
177
+ continue;
177
178
  }
178
179
  if ((format[affix] || []).includes(option)) {
179
- return;
180
+ continue;
180
181
  }
181
182
  delete options[option];
182
- });
183
+ }
183
184
  if (Object.values(options).filter(Boolean).length === 0) {
184
185
  return;
185
186
  }
@@ -193,13 +194,13 @@ class NumberFormatter {
193
194
  this.locale = locale;
194
195
  }
195
196
  format(value, format) {
197
+ var _a, _b;
196
198
  const formatter = new Intl.NumberFormat(this.locale, format.options);
197
199
  const parts = formatter.formatToParts(value);
198
200
  let prefix = '';
199
201
  let number = '';
200
202
  let suffix = '';
201
- parts.forEach((part) => {
202
- var _a, _b;
203
+ for (const part of parts) {
203
204
  if ((_a = format.prefix) === null || _a === void 0 ? void 0 : _a.includes(part.type)) {
204
205
  prefix += part.value;
205
206
  }
@@ -209,7 +210,7 @@ class NumberFormatter {
209
210
  else {
210
211
  number += part.value;
211
212
  }
212
- });
213
+ }
213
214
  if (!number) {
214
215
  number = formatter.format(value);
215
216
  prefix = '';
@@ -234,7 +235,7 @@ class RelativeDateFormatter {
234
235
  let prefix = '';
235
236
  let formattedValue = '';
236
237
  let suffix = '';
237
- parts.forEach((part) => {
238
+ for (const part of parts) {
238
239
  if (part.type === 'literal' && !formattedValue) {
239
240
  prefix += part.value;
240
241
  }
@@ -244,7 +245,7 @@ class RelativeDateFormatter {
244
245
  else {
245
246
  formattedValue += part.value;
246
247
  }
247
- });
248
+ }
248
249
  if (!formattedValue) {
249
250
  formattedValue = prefix || suffix;
250
251
  prefix = '';
@@ -261,7 +262,6 @@ class RelativeDateFormatter {
261
262
  const now = new Date();
262
263
  const diffInMs = date.getTime() - now.getTime();
263
264
  const times = [
264
- /* eslint-disable no-magic-numbers */
265
265
  { unit: 'year', value: 1000 * 60 * 60 * 24 * 365 },
266
266
  { unit: 'month', value: 1000 * 60 * 60 * 24 * 30 },
267
267
  { unit: 'week', value: 1000 * 60 * 60 * 24 * 7 },
@@ -269,7 +269,6 @@ class RelativeDateFormatter {
269
269
  { unit: 'hour', value: 1000 * 60 * 60 },
270
270
  { unit: 'minute', value: 1000 * 60 },
271
271
  { unit: 'second', value: 1000 },
272
- /* eslint-enable no-magic-numbers */
273
272
  ];
274
273
  for (const time of times) {
275
274
  const diff = diffInMs / time.value;
@@ -354,7 +353,6 @@ const InfoTile = /*@__PURE__*/ proxyCustomElement(class InfoTile extends HTMLEle
354
353
  this.value = await this.loader.load(aggregator, this.context);
355
354
  }
356
355
  catch (error) {
357
- // eslint-disable-next-line no-console
358
356
  console.error(error);
359
357
  this.error = true;
360
358
  }
@@ -363,6 +361,7 @@ const InfoTile = /*@__PURE__*/ proxyCustomElement(class InfoTile extends HTMLEle
363
361
  getKey() {
364
362
  const RADIX = 36;
365
363
  const START = 2;
364
+ // eslint-disable-next-line sonarjs/pseudo-random
366
365
  return Math.random().toString(RADIX).slice(START);
367
366
  }
368
367
  render() {
@@ -378,7 +377,7 @@ const InfoTile = /*@__PURE__*/ proxyCustomElement(class InfoTile extends HTMLEle
378
377
  const errorProps = Object.assign(Object.assign({}, baseProps), { icon: 'error', prefix: 'ERROR', loading: true, label: this.getLabel(filter) });
379
378
  const normalProps = Object.assign(Object.assign({}, baseProps), { label: this.getLabel(filter), link: this.getLink(filter), loading: this.loading, value: value === null || value === void 0 ? void 0 : value.value.trim() });
380
379
  const props = !filter || this.error ? errorProps : normalProps;
381
- return (h("limel-info-tile", Object.assign({ key: '43a5d8a0eb0b877f607c549900593f98e68396ed', class: { error: !filter || this.error } }, props)));
380
+ return (h("limel-info-tile", Object.assign({ key: '9d8d11498cba43ea63f18f6a6a72148d39966d5c', class: { error: !filter || this.error } }, props)));
382
381
  }
383
382
  getFormattedValue() {
384
383
  if (!this.value && this.value !== 0) {
@@ -94,13 +94,13 @@ const FileViewer = /*@__PURE__*/ proxyCustomElement(class FileViewer extends HTM
94
94
  return this.fileTypes
95
95
  .filter(this.isLiveDocsType)
96
96
  .map((type) => file.getUrl(type))
97
- .find((href) => href);
97
+ .find(Boolean);
98
98
  }
99
99
  getFileUrl(file) {
100
100
  return this.fileTypes
101
101
  .filter(negate(this.isLiveDocsType))
102
102
  .map((type) => file.getUrl(type))
103
- .find((href) => href);
103
+ .find(Boolean);
104
104
  }
105
105
  getFile() {
106
106
  const property = this.fileProperty;
@@ -1534,8 +1534,13 @@ var sortBy = baseRest(function(collection, iteratees) {
1534
1534
 
1535
1535
  const sortBy$1 = sortBy;
1536
1536
 
1537
+ /**
1538
+ *
1539
+ * @param languageCode
1540
+ * @param sessionLanguage
1541
+ */
1537
1542
  function getLanguageTitle(languageCode, sessionLanguage) {
1538
- if (!languageCode.length || !sessionLanguage.length) {
1543
+ if (languageCode.length === 0 || sessionLanguage.length === 0) {
1539
1544
  return '';
1540
1545
  }
1541
1546
  languageCode = languageCode === 'en_us' ? 'en-US' : languageCode;
@@ -1548,6 +1553,10 @@ function getLanguageTitle(languageCode, sessionLanguage) {
1548
1553
  languageNameParts[0] = capitalize(languageNameParts[0]);
1549
1554
  return languageNameParts.join(' ');
1550
1555
  }
1556
+ /**
1557
+ *
1558
+ * @param http
1559
+ */
1551
1560
  async function getAllLanguages(http) {
1552
1561
  const languages = await http.get('api/v1/admin/settings/languages');
1553
1562
  const result = [];
@@ -1587,7 +1596,6 @@ const LocalePicker = /*@__PURE__*/ proxyCustomElement(class LocalePicker extends
1587
1596
  }
1588
1597
  catch (error) {
1589
1598
  // Throwing an error here will break the entire page, so we just log it instead
1590
- // eslint-disable-next-line no-console
1591
1599
  console.error(error);
1592
1600
  }
1593
1601
  }
@@ -1602,13 +1610,13 @@ const LocalePicker = /*@__PURE__*/ proxyCustomElement(class LocalePicker extends
1602
1610
  let selectedOptions;
1603
1611
  if (Array.isArray(this.value)) {
1604
1612
  const value = this.value;
1605
- selectedOptions = options.filter((option) => value.some((val) => option.value === val));
1613
+ selectedOptions = options.filter((option) => value.includes(option.value));
1606
1614
  }
1607
1615
  else {
1608
1616
  const value = this.value;
1609
1617
  selectedOptions = options.find((option) => option.value === value);
1610
1618
  }
1611
- return (h("limel-select", { key: '085d3f0a20c6deb08ce52c4dadcc543f20cae275', value: selectedOptions, options: sortBy$1(options, 'text'), helperText: this.helperText, label: this.label, required: this.required, disabled: this.disabled, readonly: this.readonly, onChange: this.handleChange, multiple: this.multipleChoice }));
1619
+ return (h("limel-select", { key: 'cc3a266bdce895eee028a3109e4b1918f805adb7', value: selectedOptions, options: sortBy$1(options, 'text'), helperText: this.helperText, label: this.label, required: this.required, disabled: this.disabled, readonly: this.readonly, onChange: this.handleChange, multiple: this.multipleChoice }));
1612
1620
  }
1613
1621
  }, [1, "limebb-locale-picker", {
1614
1622
  "platform": [16],
@@ -4,10 +4,10 @@ import { c } from './index.esm.js';
4
4
  /**
5
5
  * Find the closest parent element matching the given predicate
6
6
  *
7
- * @param {HTMLElement} element - the element to check if it matches the given
7
+ * @param element - the element to check if it matches the given
8
8
  * predicate
9
- * @param {Function} predicate - predicate function
10
- * @returns {HTMLElement | undefined} the matching element if it is found
9
+ * @param predicate - predicate function
10
+ * @returns the matching element if it is found
11
11
  */
12
12
  function findParentElement(element, predicate) {
13
13
  if (predicate(element)) {
@@ -61,7 +61,6 @@ const Mention = /*@__PURE__*/ proxyCustomElement(class Mention extends HTMLEleme
61
61
  await repository.loadObject(this.limetype, this.objectid);
62
62
  }
63
63
  catch (_a) {
64
- // eslint-disable-next-line no-console
65
64
  console.error('Could not load mentioned object');
66
65
  }
67
66
  this.limeobject = repository.getObject(this.limetype, this.objectid);
@@ -5,11 +5,11 @@ import { d as defineCustomElement$2 } from './notification-item.js';
5
5
  /**
6
6
  * Processes a list of notifications by adding date headers and a "new items" indicator.
7
7
  *
8
- * @param {NotificationItem[]} items - The list of notification items to process. These items must be pre-sorted by their `timestamp` in descending order.
9
- * @param {DateTimeFormatter} dateTimeFormatter - A service used to format dates for the date headers.
10
- * @param {Date | null} lastVisitedTimestamp - The timestamp of the user's last visit. This is used to determine where the "new items" indicator should be placed.
8
+ * @param items - The list of notification items to process. These items must be pre-sorted by their `timestamp` in descending order.
9
+ * @param dateTimeFormatter - A service used to format dates for the date headers.
10
+ * @param lastVisitedTimestamp - The timestamp of the user's last visit. This is used to determine where the "new items" indicator should be placed.
11
11
  *
12
- * @returns {ProcessedItem[]} An array of processed items, including notifications, date headers, and a "new items" indicator if applicable.
12
+ * @returns An array of processed items, including notifications, date headers, and a "new items" indicator if applicable.
13
13
  *
14
14
  * @example
15
15
  * const processedItems = processNotificationItems(
@@ -48,18 +48,27 @@ function processNotificationItems(items, dateTimeFormatter, lastVisitedTimestamp
48
48
  return finalContext.processedItems;
49
49
  }
50
50
  function createPipeline(initialContext, processors) {
51
+ // eslint-disable-next-line unicorn/no-array-reduce
51
52
  return processors.reduce((context, processor) => processor(context), initialContext);
52
53
  }
54
+ /**
55
+ *
56
+ * @param context
57
+ */
53
58
  function insertNotifications(context) {
54
- context.items.forEach((item) => {
59
+ for (const item of context.items) {
55
60
  context.processedItems.push({ type: 'notification', item: item });
56
- });
61
+ }
57
62
  return context;
58
63
  }
64
+ /**
65
+ *
66
+ * @param context
67
+ */
59
68
  function insertNewItemIndicator(context) {
60
69
  const processedWithIndicator = [];
61
70
  let newItemIndicatorInserted = context.newItemIndicatorInserted;
62
- context.processedItems.forEach((item) => {
71
+ for (const item of context.processedItems) {
63
72
  if (item.type === 'notification' &&
64
73
  context.lastVisitedTimestamp &&
65
74
  !newItemIndicatorInserted &&
@@ -71,11 +80,16 @@ function insertNewItemIndicator(context) {
71
80
  }
72
81
  // Push the current item to the new array
73
82
  processedWithIndicator.push(item);
74
- });
83
+ }
75
84
  context.processedItems = processedWithIndicator;
76
85
  context.newItemIndicatorInserted = newItemIndicatorInserted;
77
86
  return context;
78
87
  }
88
+ /**
89
+ *
90
+ * @param context
91
+ */
92
+ // eslint-disable-next-line sonarjs/cognitive-complexity
79
93
  function insertDateGroups(context) {
80
94
  const newProcessedItems = [];
81
95
  let currentGroup = null;
@@ -121,7 +135,7 @@ function insertDateGroups(context) {
121
135
  return Object.assign(Object.assign({}, context), { processedItems: newProcessedItems });
122
136
  }
123
137
 
124
- const notificationListCss = "@charset \"UTF-8\";:host(limebb-notification-list){--limebb-notification-list-background-color:var(\n --notification-list-background-color,\n rgb(var(--contrast-300))\n );display:flex;flex-direction:column;gap:1rem;max-width:45rem;background-color:var(--limebb-notification-list-background-color);padding:0.5rem}limebb-notification-item:focus{outline:none}limebb-notification-item:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}limebb-notification-item:not(.is-read){--limebb-notification-item-unread-badge-color:rgb(\n var(--color-red-default)\n );--limebb-notification-item-unread-badge-scale:1;background-color:rgb(var(--contrast-100)) !important}limebb-notification-item.is-clickable{transition:color var(--limel-clickable-transition-speed, 0.4s) ease, background-color var(--limel-clickable-transition-speed, 0.4s) ease, box-shadow var(--limel-clickable-transform-speed, 0.4s) ease, transform var(--limel-clickable-transform-speed, 0.4s) var(--limel-clickable-transform-timing-function, ease);cursor:pointer;color:var(--mdc-theme-on-surface);background-color:transparent}limebb-notification-item.is-clickable:hover,limebb-notification-item.is-clickable:focus,limebb-notification-item.is-clickable:focus-visible{will-change:color, background-color, box-shadow, transform}limebb-notification-item.is-clickable:hover{transform:translate3d(0, 0.01rem, 0);color:var(--mdc-theme-on-surface);background-color:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-hovered)}limebb-notification-item.is-clickable:active{--limel-clickable-transform-timing-function:cubic-bezier(\n 0.83,\n -0.15,\n 0.49,\n 1.16\n );transform:translate3d(0, 0.05rem, 0);box-shadow:var(--button-shadow-pressed)}limebb-notification-item.is-clickable:hover,limebb-notification-item.is-clickable:active{--limel-clickable-transition-speed:0.2s;--limel-clickable-transform-speed:0.16s}limebb-notification-item.is-clickable:hover{border-color:transparent}limebb-notification-item.is-read{border-color:rgb(var(--contrast-600));background-color:rgb(var(--contrast-500))}limebb-notification-item.is-selected{box-shadow:var(--shadow-focused-state)}limebb-notification-item.is-selected:hover{box-shadow:var(--shadow-focused-state), var(--button-shadow-hovered)}limel-spinner{align-self:center;justify-self:center;margin:auto}.date-group{isolation:isolate;display:flex;flex-direction:column;gap:0.5rem}.date-heading{position:sticky;z-index:1;top:0.25rem;display:flex;border-radius:9rem;padding:0.25rem 0.5rem;margin:0;width:fit-content;font-size:0.75rem;line-height:1;color:rgb(var(--contrast-900));backdrop-filter:blur(0.5rem);-webkit-backdrop-filter:blur(0.5rem);transition:color 0.2s ease, border-color 0.4s ease}.date-heading:hover{color:rgb(var(--contrast-1000));border-color:rgb(var(--contrast-500))}.date-heading:hover:before{opacity:1}.date-heading:before{transition:opacity 0.2s ease;content:\"\";position:absolute;z-index:-1;inset:0;opacity:0.6;border-radius:inherit;background-color:var(--limebb-notification-list-background-color)}.new-items-indicator{position:relative;isolation:isolate;display:flex;align-items:center;justify-content:flex-end;margin:0.25rem 0}.new-items-indicator hr{border:none;position:absolute;width:100%;height:1px;background-color:rgb(var(--color-red-lighter))}.new-items-indicator h3{z-index:1;padding:0 0.5rem;border-radius:1rem;margin:0 1rem;font-size:small;line-height:0.75rem;text-transform:lowercase;color:rgb(var(--color-red-default));background-color:var(--limebb-notification-list-background-color)}";
138
+ const notificationListCss = "@charset \"UTF-8\";:host(limebb-notification-list){--limebb-notification-list-background-color:var(\n --notification-list-background-color,\n rgb(var(--contrast-300))\n );display:flex;flex-direction:column;gap:1rem;max-width:45rem;background-color:var(--limebb-notification-list-background-color);padding:0.5rem}limebb-notification-item:focus{outline:none}limebb-notification-item:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}limebb-notification-item:not(.is-read){--limebb-notification-item-unread-badge-color:rgb(\n var(--color-red-default)\n );--limebb-notification-item-unread-badge-scale:1;background-color:rgb(var(--contrast-100)) !important}limebb-notification-item.is-clickable{transition:color var(--limel-clickable-transition-speed, 0.4s) ease, background-color var(--limel-clickable-transition-speed, 0.4s) ease, box-shadow var(--limel-clickable-transform-speed, 0.4s) ease, transform var(--limel-clickable-transform-speed, 0.4s) var(--limel-clickable-transform-timing-function, ease);cursor:pointer;color:var(--limel-theme-on-surface-color);background-color:transparent}limebb-notification-item.is-clickable:hover,limebb-notification-item.is-clickable:focus,limebb-notification-item.is-clickable:focus-visible{will-change:color, background-color, box-shadow, transform}limebb-notification-item.is-clickable:hover{transform:translate3d(0, 0.01rem, 0);color:var(--limel-theme-on-surface-color);background-color:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-hovered)}limebb-notification-item.is-clickable:active{--limel-clickable-transform-timing-function:cubic-bezier(\n 0.83,\n -0.15,\n 0.49,\n 1.16\n );transform:translate3d(0, 0.05rem, 0);box-shadow:var(--button-shadow-pressed)}limebb-notification-item.is-clickable:hover,limebb-notification-item.is-clickable:active{--limel-clickable-transition-speed:0.2s;--limel-clickable-transform-speed:0.16s}limebb-notification-item.is-clickable:hover{border-color:transparent}limebb-notification-item.is-read{border-color:rgb(var(--contrast-600));background-color:rgb(var(--contrast-500))}limebb-notification-item.is-selected{box-shadow:var(--shadow-focused-state)}limebb-notification-item.is-selected:hover{box-shadow:var(--shadow-focused-state), var(--button-shadow-hovered)}limel-spinner{align-self:center;justify-self:center;margin:auto}.date-group{isolation:isolate;display:flex;flex-direction:column;gap:0.5rem}.date-heading{position:sticky;z-index:1;top:0.25rem;display:flex;border-radius:9rem;padding:0.25rem 0.5rem;margin:0;width:fit-content;font-size:0.75rem;line-height:1;color:rgb(var(--contrast-900));backdrop-filter:blur(0.5rem);-webkit-backdrop-filter:blur(0.5rem);transition:color 0.2s ease, border-color 0.4s ease}.date-heading:hover{color:rgb(var(--contrast-1000));border-color:rgb(var(--contrast-500))}.date-heading:hover:before{opacity:1}.date-heading:before{transition:opacity 0.2s ease;content:\"\";position:absolute;z-index:-1;inset:0;opacity:0.6;border-radius:inherit;background-color:var(--limebb-notification-list-background-color)}.new-items-indicator{position:relative;isolation:isolate;display:flex;align-items:center;justify-content:flex-end;margin:0.25rem 0}.new-items-indicator hr{border:none;position:absolute;width:100%;height:1px;background-color:rgb(var(--color-red-lighter))}.new-items-indicator h3{z-index:1;padding:0 0.5rem;border-radius:1rem;margin:0 1rem;font-size:small;line-height:0.75rem;text-transform:lowercase;color:rgb(var(--color-red-default));background-color:var(--limebb-notification-list-background-color)}";
125
139
  const LimebbNotificationListStyle0 = notificationListCss;
126
140
 
127
141
  const NotificationList = /*@__PURE__*/ proxyCustomElement(class NotificationList extends HTMLElement {
@@ -161,12 +175,15 @@ const NotificationList = /*@__PURE__*/ proxyCustomElement(class NotificationList
161
175
  renderNotificationItems() {
162
176
  return this.processedItems.map((item) => {
163
177
  switch (item.type) {
164
- case 'group':
178
+ case 'group': {
165
179
  return this.renderGroup(item);
166
- case 'newItemIndicator':
180
+ }
181
+ case 'newItemIndicator': {
167
182
  return this.renderIndicator();
168
- default:
183
+ }
184
+ default: {
169
185
  return null;
186
+ }
170
187
  }
171
188
  });
172
189
  }
@@ -70,18 +70,17 @@ const PercentageVisualizer = /*@__PURE__*/ proxyCustomElement(class PercentageVi
70
70
  }
71
71
  triggerRangeWarning() {
72
72
  if (this.rangeMin >= this.rangeMax) {
73
- // eslint-disable-next-line no-console
74
73
  console.warn(`[limebb-percentage-visualizer] Invalid range: rangeMin (${this.rangeMin}) must be less than rangeMax (${this.rangeMax}). Visualization may not appear as expected.`);
75
74
  }
76
75
  }
77
76
  render() {
78
77
  const normalizedValue = this.getNormalizedValue();
79
78
  const zeroPoint = this.getZeroPointPosition();
80
- return (h(Host, { key: 'c279e1a4d25555af3928cccec63f3ff65c34ca61', class: this.getContainerClassList(), style: {
79
+ return (h(Host, { key: '454366891b8fe6860a43efaf8c1b96c9a4689962', class: this.getContainerClassList(), style: {
81
80
  '--limebb-percentage-visualizer-zero-point-position': `${zeroPoint}%`,
82
81
  '--limebb-percentage-visualizer-width': `${Math.abs(normalizedValue)}%`,
83
82
  '--limebb-percentage-visualizer-rotate': `${normalizedValue >= 0 ? '0deg' : '180deg'}`,
84
- } }, h("limel-notched-outline", { key: '3044031cdb7a169cb89957c7ee99609716e0f66d', tabIndex: 0, role: "meter", "aria-valuemin": this.rangeMin, "aria-valuemax": this.rangeMax, "aria-valuenow": this.numValue, "aria-labelledby": this.labelId, "aria-describedby": this.helperTextId, label: this.label, labelId: this.labelId, invalid: this.invalid, required: this.required, hasValue: true, hasFloatingLabel: true, "aria-controls": this.helperTextId }, h("div", { key: 'c139e8add053c9c559cca82f533e92e7769842ad', slot: "content" }, this.renderVisualization())), this.renderHelperLine()));
83
+ } }, h("limel-notched-outline", { key: 'c827cb818ed190f6a7b6fa33e6b1c878b5682e42', tabIndex: 0, role: "meter", "aria-valuemin": this.rangeMin, "aria-valuemax": this.rangeMax, "aria-valuenow": this.numValue, "aria-labelledby": this.labelId, "aria-describedby": this.helperTextId, label: this.label, labelId: this.labelId, invalid: this.invalid, required: this.required, hasValue: true, hasFloatingLabel: true, "aria-controls": this.helperTextId }, h("div", { key: '7c6dcc138c4bca114d4d83af026c93f8611339b5', slot: "content" }, this.renderVisualization())), this.renderHelperLine()));
85
84
  }
86
85
  renderVisualization() {
87
86
  if (this.reducePresence && (this.numValue === 0 || !this.hasValue())) {
@@ -163,15 +162,15 @@ const PercentageVisualizer = /*@__PURE__*/ proxyCustomElement(class PercentageVi
163
162
  }
164
163
  unifyMinusSign(input) {
165
164
  // Replace Unicode minus sign (−) with ASCII hyphen-minus (-)
166
- return input.replace(/−/g, '-');
165
+ return input.replaceAll('−', '-');
167
166
  }
168
167
  convertToUnicodeMinus(input) {
169
168
  // Replace ASCII hyphen-minus (-) with Unicode minus sign (−)
170
- return input.replace(/-/g, '−');
169
+ return input.replaceAll('-', '−');
171
170
  }
172
171
  parseValue(value) {
173
172
  if (typeof value === 'string') {
174
- return parseFloat(this.unifyMinusSign(value));
173
+ return Number.parseFloat(this.unifyMinusSign(value));
175
174
  }
176
175
  return value;
177
176
  }
@@ -1081,6 +1081,11 @@ const getItemIndex = (direction, currentItemIndex, numberOfItems) => {
1081
1081
  const increment = direction === ARROW_DOWN ? 1 : -1;
1082
1082
  return (currentItemIndex + increment + numberOfItems) % numberOfItems;
1083
1083
  };
1084
+ /**
1085
+ *
1086
+ * @param items
1087
+ * @param highlightedItemIndex
1088
+ */
1084
1089
  function getUpdatedItems(items, highlightedItemIndex) {
1085
1090
  return items.map((item, index) => {
1086
1091
  const newItem = cloneDeep(item);
@@ -1088,6 +1093,7 @@ function getUpdatedItems(items, highlightedItemIndex) {
1088
1093
  });
1089
1094
  }
1090
1095
 
1096
+ /* eslint-disable sonarjs/pseudo-random */
1091
1097
  const createRandomString = () => {
1092
1098
  var _a;
1093
1099
  if (!('crypto' in window) ||
@@ -1101,17 +1107,19 @@ function legacyCreateRandomString() {
1101
1107
  const SKIP_LEADING_ZERODOT = 2;
1102
1108
  const ASCII_A = 97;
1103
1109
  const NUMBER_OF_LETTERS = 26;
1104
- return (String.fromCharCode(ASCII_A + Math.floor(Math.random() * NUMBER_OF_LETTERS)) +
1105
- Math.random().toString(USE_HEX).substring(SKIP_LEADING_ZERODOT) +
1106
- Math.random().toString(USE_HEX).substring(SKIP_LEADING_ZERODOT));
1110
+ return (String.fromCodePoint(ASCII_A + Math.floor(Math.random() * NUMBER_OF_LETTERS)) +
1111
+ Math.random()
1112
+ .toString(USE_HEX)
1113
+ .slice(Math.max(0, SKIP_LEADING_ZERODOT)) +
1114
+ Math.random().toString(USE_HEX).slice(Math.max(0, SKIP_LEADING_ZERODOT)));
1107
1115
  }
1108
1116
 
1109
1117
  /**
1110
1118
  * Whether the given object has the given label or not.
1111
1119
  *
1112
- * @param {LimeType|LimeProperty} object the object to check label for
1113
- * @param {string} label the label to check for
1114
- * @returns {boolean} true if the object has the label
1120
+ * @param object the object to check label for
1121
+ * @param label the label to check for
1122
+ * @returns true if the object has the label
1115
1123
  */
1116
1124
  function hasLabel(object, label) {
1117
1125
  return object.label === label;
@@ -1119,8 +1127,8 @@ function hasLabel(object, label) {
1119
1127
  /**
1120
1128
  * Whether the given property is a hasmany relation or not.
1121
1129
  *
1122
- * @param {LimeProperty} property the property to check
1123
- * @returns {boolean} true if the property is a hasmany relation
1130
+ * @param property the property to check
1131
+ * @returns true if the property is a hasmany relation
1124
1132
  */
1125
1133
  function isManyRelation(property) {
1126
1134
  return De(property) && !Me(property);
@@ -1129,9 +1137,9 @@ function isManyRelation(property) {
1129
1137
  * Finds a relation property on the given limetype that is related to a
1130
1138
  * limetype with the given label.
1131
1139
  *
1132
- * @param {LimeType} limetype the limetype to search for the relation property
1133
- * @param {string} label the label of the target limetype to match
1134
- * @returns {LimeProperty|undefined} the relation property or undefined
1140
+ * @param limetype the limetype to search for the relation property
1141
+ * @param label the label of the target limetype to match
1142
+ * @returns the relation property or undefined
1135
1143
  */
1136
1144
  function getRelationProperty(limetype, label) {
1137
1145
  return Object.values(limetype.properties).find((property) => property &&
@@ -1141,21 +1149,20 @@ function getRelationProperty(limetype, label) {
1141
1149
  /**
1142
1150
  * Whether the limetype has a hasmany relation of a limetype with the given label
1143
1151
  *
1144
- * @param {LimeType} limetype the limetype
1145
- * @param {string} relatedLabel the label of the related limetype
1146
- * @returns {boolean} true if the limetype has the hasmany relation
1152
+ * @param limetype the limetype
1153
+ * @param relatedLabel the label of the related limetype
1154
+ * @returns true if the limetype has the hasmany relation
1147
1155
  */
1148
1156
  function hasHasManyRelation(limetype, relatedLabel) {
1149
1157
  const property = getRelationProperty(limetype, relatedLabel);
1150
1158
  return !!property && isManyRelation(property);
1151
1159
  }
1152
1160
 
1153
- /* eslint-disable no-underscore-dangle */
1154
1161
  /**
1155
1162
  * Get the limetypes that should be available for mentions
1156
1163
  *
1157
- * @param {Record<string, LimeType>} limetypes all limetypes
1158
- * @returns {LimeType[]} mention limetypes
1164
+ * @param limetypes all limetypes
1165
+ * @returns mention limetypes
1159
1166
  */
1160
1167
  function getMentionLimetypes(limetypes) {
1161
1168
  return Object.values(limetypes).filter((limetype) => {
@@ -1236,9 +1243,9 @@ class MentionsService {
1236
1243
  .filter((limetype) => !hasLabel(limetype, 'user') &&
1237
1244
  hasHasManyRelation(limetype, 'user'))
1238
1245
  .map((limetype) => this.getGroupCounts(limetype));
1239
- (await Promise.all(groupCountsLoads)).forEach((groupCount) => {
1246
+ for (const groupCount of await Promise.all(groupCountsLoads)) {
1240
1247
  Object.assign(this.groupCounts, groupCount);
1241
- });
1248
+ }
1242
1249
  }
1243
1250
  async getGroupCounts(limetype) {
1244
1251
  var _a;
@@ -1267,17 +1274,16 @@ class MentionsService {
1267
1274
  return { [limetypeName]: groupCount };
1268
1275
  }
1269
1276
  catch (error) {
1270
- // eslint-disable-next-line no-console
1271
1277
  console.error(`Error fetching group count for limetype: ${limetype.name}`, error);
1272
1278
  return { [limetypeName]: {} };
1273
1279
  }
1274
1280
  }
1275
1281
  createGroupCount(objects, coworkerPropertyName) {
1276
1282
  const groupCount = {};
1277
- objects.forEach((object) => {
1283
+ for (const object of objects) {
1278
1284
  const { _id: id, [coworkerPropertyName]: aggregateProperty } = object;
1279
1285
  groupCount[id] = aggregateProperty.count;
1280
- });
1286
+ }
1281
1287
  return groupCount;
1282
1288
  }
1283
1289
  createSearchListItems(searchObjects = []) {
@@ -1325,7 +1331,7 @@ class FileUpload {
1325
1331
  this.http = http;
1326
1332
  this.uploadCancelled = false;
1327
1333
  this.getUrl = (fileid) => {
1328
- return `${CORE_API_PATH}/${FILE_PATH}/${fileid ? fileid : ''}`;
1334
+ return `${CORE_API_PATH}/${FILE_PATH}/${fileid !== null && fileid !== void 0 ? fileid : ''}`;
1329
1335
  };
1330
1336
  }
1331
1337
  async initialize() {
@@ -1360,8 +1366,8 @@ class UploadHandler {
1360
1366
  /**
1361
1367
  * Handles image paste events in the text editor
1362
1368
  *
1363
- * @param {ImageInserter} imageInserter - The image inserter with the file info
1364
- * @returns {Promise<FileWrapper | undefined>} Promise resolving to the uploaded file wrapper or undefined if upload fails
1369
+ * @param imageInserter - The image inserter with the file info
1370
+ * @returns Promise resolving to the uploaded file wrapper or undefined if upload fails
1365
1371
  */
1366
1372
  async handleImagePasted(imageInserter) {
1367
1373
  const fileInfo = imageInserter === null || imageInserter === void 0 ? void 0 : imageInserter.fileInfo;
@@ -1389,8 +1395,8 @@ class UploadHandler {
1389
1395
  * This function parses a URL to find a file ID that appears before
1390
1396
  * '/contents/' at the end of the URL.
1391
1397
  *
1392
- * @param {string} src - The URL string to parse
1393
- * @returns {string | undefined} The extracted file ID or undefined if no match is found
1398
+ * @param src - The URL string to parse
1399
+ * @returns The extracted file ID or undefined if no match is found
1394
1400
  *
1395
1401
  * @example
1396
1402
  * // Returns 123
@@ -1416,8 +1422,8 @@ class UploadHandler {
1416
1422
  /**
1417
1423
  * Validates that the image file size is within limits
1418
1424
  *
1419
- * @param {FileInfo} fileInfo - The file info to validate
1420
- * @returns {boolean} True if file size is valid, false otherwise
1425
+ * @param fileInfo - The file info to validate
1426
+ * @returns True if file size is valid, false otherwise
1421
1427
  */
1422
1428
  validateImageSize(fileInfo) {
1423
1429
  if (!fileInfo.fileContent) {
@@ -1428,8 +1434,8 @@ class UploadHandler {
1428
1434
  /**
1429
1435
  * Creates and uploads a file
1430
1436
  *
1431
- * @param {FileInfo} fileInfo - The file info to upload
1432
- * @returns {Promise<FileWrapper | undefined>} Promise resolving to the uploaded file wrapper or undefined if upload fails
1437
+ * @param fileInfo - The file info to upload
1438
+ * @returns Promise resolving to the uploaded file wrapper or undefined if upload fails
1433
1439
  */
1434
1440
  async createFileUpload(fileInfo) {
1435
1441
  var _a;
@@ -1455,7 +1461,6 @@ class UploadHandler {
1455
1461
  imageUpload.contentType = response.contentType;
1456
1462
  imageUpload.size = response.size;
1457
1463
  imageUpload.state = 'done';
1458
- // eslint-disable-next-line no-underscore-dangle
1459
1464
  imageUpload.href = (_a = response._links) === null || _a === void 0 ? void 0 : _a.contents.href;
1460
1465
  return imageUpload;
1461
1466
  }
@@ -1619,7 +1624,7 @@ const LimeBBTextEditor = /*@__PURE__*/ proxyCustomElement(class LimeBBTextEditor
1619
1624
  };
1620
1625
  this.findNonSeparatorIndex = (direction, currentIndex, depth = 0) => {
1621
1626
  // Safety check to avoid infinite recursion
1622
- if (!this.items.length || depth > this.items.length) {
1627
+ if (this.items.length === 0 || depth > this.items.length) {
1623
1628
  return currentIndex;
1624
1629
  }
1625
1630
  const nextIndex = getItemIndex(direction, currentIndex, this.items.length);
@@ -1704,7 +1709,6 @@ const LimeBBTextEditor = /*@__PURE__*/ proxyCustomElement(class LimeBBTextEditor
1704
1709
  triggerHandler.inserter(this.triggerFunction, selectedItem);
1705
1710
  }
1706
1711
  catch (error) {
1707
- // eslint-disable-next-line no-console
1708
1712
  console.error('Error inserting', error);
1709
1713
  }
1710
1714
  this.resetTriggerAndPicker();
@@ -1729,7 +1733,6 @@ const LimeBBTextEditor = /*@__PURE__*/ proxyCustomElement(class LimeBBTextEditor
1729
1733
  this.items = items;
1730
1734
  }
1731
1735
  catch (error) {
1732
- // eslint-disable-next-line no-console
1733
1736
  console.error('Error searching', error);
1734
1737
  }
1735
1738
  finally {
@@ -1832,7 +1835,7 @@ const LimeBBTextEditor = /*@__PURE__*/ proxyCustomElement(class LimeBBTextEditor
1832
1835
  }
1833
1836
  render() {
1834
1837
  return [
1835
- h("limel-text-editor", { key: '65f1a843efb81de7f5006f49bf4bd912047e73f4', ref: (el) => (this.textEditor = el), tabindex: this.disabled ? -1 : 0, value: this.value, contentType: this.contentType, customElements: this.registeredCustomElements, "aria-disabled": this.disabled, language: this.language, triggers: this.registeredTriggers, onTriggerStart: this.handleTriggerStart, onTriggerStop: this.handleTriggerStop, onTriggerChange: this.handleTriggerChange, onImagePasted: this.handleImagePasted, onMetadataChange: this.handleMetadataChange, ui: this.ui, allowResize: this.allowResize, required: this.required, disabled: this.disabled, readonly: this.readonly, helperText: this.helperText, placeholder: this.placeholder, label: this.label, invalid: this.invalid }),
1838
+ h("limel-text-editor", { key: 'af646ab86b401f895b2df8ce307d2b739d356d4c', ref: (el) => (this.textEditor = el), tabindex: this.disabled ? -1 : 0, value: this.value, contentType: this.contentType, customElements: this.registeredCustomElements, "aria-disabled": this.disabled, language: this.language, triggers: this.registeredTriggers, onTriggerStart: this.handleTriggerStart, onTriggerStop: this.handleTriggerStop, onTriggerChange: this.handleTriggerChange, onImagePasted: this.handleImagePasted, onMetadataChange: this.handleMetadataChange, ui: this.ui, allowResize: this.allowResize, required: this.required, disabled: this.disabled, readonly: this.readonly, helperText: this.helperText, placeholder: this.placeholder, label: this.label, invalid: this.invalid }),
1836
1839
  this.renderPicker(),
1837
1840
  ];
1838
1841
  }
@@ -47,7 +47,7 @@ const TrendIndicator = /*@__PURE__*/ proxyCustomElement(class TrendIndicator ext
47
47
  return h("span", { class: "no-value" }, "\u2013");
48
48
  }
49
49
  return [
50
- h("div", { class: "icon" }, this.getArrowIcon()),
50
+ this.getArrowIcon(),
51
51
  h("span", null, this.renderGrowthPercentage(), this.renderGrowthAmount()),
52
52
  ];
53
53
  }
@@ -111,19 +111,19 @@ const TrendIndicator = /*@__PURE__*/ proxyCustomElement(class TrendIndicator ext
111
111
  const percentage = (((this.numValue - this.formerValue) /
112
112
  Math.abs(this.formerValue)) *
113
113
  PERCENT).toFixed(DECIMALS);
114
- return parseFloat(percentage);
114
+ return Number.parseFloat(percentage);
115
115
  }
116
116
  unifyMinusSign(input) {
117
117
  // Replace Unicode minus sign (−) with ASCII hyphen-minus (-)
118
- return input.replace(/−/g, '-');
118
+ return input.replaceAll('−', '-');
119
119
  }
120
120
  convertToUnicodeMinus(input) {
121
121
  // Replace ASCII hyphen-minus (-) with Unicode minus sign (−)
122
- return input.replace(/-/g, '−');
122
+ return input.replaceAll('-', '−');
123
123
  }
124
124
  parseValue(value) {
125
125
  if (typeof value === 'string') {
126
- return parseFloat(this.unifyMinusSign(value));
126
+ return Number.parseFloat(this.unifyMinusSign(value));
127
127
  }
128
128
  return value;
129
129
  }
@@ -135,7 +135,7 @@ const TrendIndicator = /*@__PURE__*/ proxyCustomElement(class TrendIndicator ext
135
135
  return this.convertToUnicodeMinus(constructedValue);
136
136
  }
137
137
  getArrowIcon() {
138
- return (h("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 32 32" }, h("line", { fill: "none", stroke: "currentColor", "stroke-width": "2", "stroke-miterlimit": "10", x1: "26", y1: "16", x2: "4", y2: "16" }), h("polyline", { fill: "none", stroke: "currentColor", "stroke-width": "2", "stroke-miterlimit": "10", points: "18,7.5 26.5,16 18,24.5 " })));
138
+ return (h("limel-icon", { class: "icon", name: "right", "aria-hidden": "true", role: "presentation" }));
139
139
  }
140
140
  static get watchers() { return {
141
141
  "value": ["valueChanged"]