@limetech/lime-crm-building-blocks 1.134.0 → 1.135.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 (283) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/dist/cjs/{filter-group-logic-Bwk6B784.js → filter-group-logic-Dp9o1iOJ.js} +1 -1
  3. package/dist/cjs/{index.esm-DcWSoSRE.js → index.esm-Dgkx-Syd.js} +2 -2
  4. package/dist/cjs/lime-crm-building-blocks.cjs.js +1 -1
  5. package/dist/cjs/{lime-query-operators-Ci-RNshi.js → lime-query-operators-B6PujuTH.js} +1 -1
  6. package/dist/cjs/{lime-query-validation-nql4N6Z8.js → lime-query-validation-BszGOirf.js} +1 -1
  7. package/dist/cjs/limebb-alert-dialog.cjs.entry.js +1 -1
  8. package/dist/cjs/limebb-browser.cjs.entry.js +3 -3
  9. package/dist/cjs/limebb-chat-icon-list_3.cjs.entry.js +5 -5
  10. package/dist/cjs/limebb-chat-list.cjs.entry.js +2 -2
  11. package/dist/cjs/limebb-color-palette-picker.cjs.entry.js +1 -1
  12. package/dist/cjs/limebb-color-palette-swatches.cjs.entry.js +1 -1
  13. package/dist/cjs/limebb-component-config.cjs.entry.js +1 -1
  14. package/dist/cjs/limebb-component-picker.cjs.entry.js +1 -1
  15. package/dist/cjs/limebb-composer-toolbar.cjs.entry.js +3 -3
  16. package/dist/cjs/limebb-currency-picker.cjs.entry.js +2 -2
  17. package/dist/cjs/limebb-dashboard-widget.cjs.entry.js +1 -1
  18. package/dist/cjs/limebb-data-cells.cjs.entry.js +1 -1
  19. package/dist/cjs/limebb-date-picker.cjs.entry.js +2 -2
  20. package/dist/cjs/limebb-date-range.cjs.entry.js +1 -1
  21. package/dist/cjs/limebb-document-chips.cjs.entry.js +1 -1
  22. package/dist/cjs/limebb-document-item.cjs.entry.js +2 -2
  23. package/dist/cjs/limebb-document-picker.cjs.entry.js +1 -1
  24. package/dist/cjs/limebb-feed-item-thumbnail-file-info.cjs.entry.js +1 -1
  25. package/dist/cjs/limebb-feed-timeline-item.cjs.entry.js +2 -2
  26. package/dist/cjs/limebb-feed.cjs.entry.js +2 -2
  27. package/dist/cjs/limebb-icon-picker.cjs.entry.js +1 -1
  28. package/dist/cjs/limebb-info-tile-format.cjs.entry.js +1 -1
  29. package/dist/cjs/limebb-info-tile.cjs.entry.js +44 -9
  30. package/dist/cjs/limebb-kanban-group.cjs.entry.js +2 -2
  31. package/dist/cjs/limebb-kanban-item.cjs.entry.js +2 -2
  32. package/dist/cjs/limebb-lime-query-builder.cjs.entry.js +3 -3
  33. package/dist/cjs/limebb-lime-query-filter-builder.cjs.entry.js +2 -2
  34. package/dist/cjs/limebb-lime-query-filter-comparison-editor_4.cjs.entry.js +7 -7
  35. package/dist/cjs/limebb-lime-query-filter-comparison_2.cjs.entry.js +4 -4
  36. package/dist/cjs/limebb-lime-query-order-by-editor_2.cjs.entry.js +4 -4
  37. package/dist/cjs/limebb-lime-query-order-by-item.cjs.entry.js +2 -2
  38. package/dist/cjs/limebb-lime-query-response-format-builder.cjs.entry.js +3 -3
  39. package/dist/cjs/limebb-lime-query-response-format-editor_2.cjs.entry.js +1 -1
  40. package/dist/cjs/limebb-limeobject-file-viewer.cjs.entry.js +1 -1
  41. package/dist/cjs/limebb-live-docs-info.cjs.entry.js +2 -2
  42. package/dist/cjs/limebb-loader.cjs.entry.js +18 -1
  43. package/dist/cjs/limebb-locale-picker.cjs.entry.js +2 -2
  44. package/dist/cjs/limebb-mention-group-counter.cjs.entry.js +2 -2
  45. package/dist/cjs/limebb-mention.cjs.entry.js +1 -1
  46. package/dist/cjs/limebb-navigation-button_2.cjs.entry.js +2 -2
  47. package/dist/cjs/limebb-notification-item.cjs.entry.js +2 -2
  48. package/dist/cjs/limebb-notification-list.cjs.entry.js +1 -1
  49. package/dist/cjs/limebb-object-chip.cjs.entry.js +2 -2
  50. package/dist/cjs/limebb-percentage-visualizer.cjs.entry.js +3 -3
  51. package/dist/cjs/limebb-property-selector.cjs.entry.js +2 -2
  52. package/dist/cjs/limebb-rule-arg-filter-editor.cjs.entry.js +1 -1
  53. package/dist/cjs/limebb-rule-chip-popover.cjs.entry.js +2 -2
  54. package/dist/cjs/limebb-rule-editor.cjs.entry.js +2 -2
  55. package/dist/cjs/limebb-rule-gate.cjs.entry.js +2 -2
  56. package/dist/cjs/limebb-text-editor.cjs.entry.js +3 -3
  57. package/dist/cjs/limebb-trend-indicator.cjs.entry.js +2 -2
  58. package/dist/cjs/limebb-value-comparison-editor.cjs.entry.js +75 -0
  59. package/dist/cjs/{limetype-CNjUGemK.js → limetype-BayDf-QY.js} +1 -1
  60. package/dist/cjs/loader.cjs.js +1 -1
  61. package/dist/collection/collection-manifest.json +1 -0
  62. package/dist/collection/components/alert-dialog/alert-dialog.js +1 -1
  63. package/dist/collection/components/browser/browser.js +2 -2
  64. package/dist/collection/components/chat-list/chat-icon-list/chat-icon-list.js +1 -1
  65. package/dist/collection/components/chat-list/chat-item/chat-item.js +2 -2
  66. package/dist/collection/components/chat-list/chat-list.js +1 -1
  67. package/dist/collection/components/chat-list/typing-indicator/typing-indicator.js +1 -1
  68. package/dist/collection/components/color-palette-picker/color-palette-picker.js +1 -1
  69. package/dist/collection/components/color-palette-picker/color-palette-swatches/color-palette-swatches.js +1 -1
  70. package/dist/collection/components/composer-toolbar/composer-toolbar.js +2 -2
  71. package/dist/collection/components/currency-picker/currency-picker.js +1 -1
  72. package/dist/collection/components/dashboard-widget/dashboard-widget.js +1 -1
  73. package/dist/collection/components/date-picker/date-picker.js +1 -1
  74. package/dist/collection/components/date-range/date-range.js +1 -1
  75. package/dist/collection/components/document-chips/document-chips.js +1 -1
  76. package/dist/collection/components/document-picker/document-item/document-item.js +2 -2
  77. package/dist/collection/components/document-picker/document-picker.js +1 -1
  78. package/dist/collection/components/feed/feed-item/feed-timeline-item.js +1 -1
  79. package/dist/collection/components/feed/feed-item-thumbnail-file-info/feed-item-thumbnail-file-info.js +1 -1
  80. package/dist/collection/components/feed/feed.js +1 -1
  81. package/dist/collection/components/icon-picker/icon-picker.js +1 -1
  82. package/dist/collection/components/info-tile/format/config/info-tile-format.js +1 -1
  83. package/dist/collection/components/info-tile/info-tile.js +86 -7
  84. package/dist/collection/components/kanban/kanban-group/kanban-group.js +1 -1
  85. package/dist/collection/components/kanban/kanban-item/kanban-item.js +1 -1
  86. package/dist/collection/components/lime-query-builder/expressions/lime-query-filter-comparison-editor.js +1 -1
  87. package/dist/collection/components/lime-query-builder/expressions/lime-query-filter-comparison.js +1 -1
  88. package/dist/collection/components/lime-query-builder/expressions/lime-query-filter-group.js +2 -2
  89. package/dist/collection/components/lime-query-builder/expressions/lime-query-filter-not.js +1 -1
  90. package/dist/collection/components/lime-query-builder/lime-query-builder.js +1 -1
  91. package/dist/collection/components/lime-query-builder/lime-query-response-format-builder.js +1 -1
  92. package/dist/collection/components/lime-query-builder/limetype-field/limetype-field.js +1 -1
  93. package/dist/collection/components/lime-query-builder/order-by/order-by-editor.js +1 -1
  94. package/dist/collection/components/lime-query-builder/order-by/order-by-item.js +2 -2
  95. package/dist/collection/components/lime-query-builder/response-format/response-format-item.js +1 -1
  96. package/dist/collection/components/limeobject/file-viewer/live-docs-info.js +2 -2
  97. package/dist/collection/components/loader/loader.js +2 -0
  98. package/dist/collection/components/locale-picker/locale-picker.js +1 -1
  99. package/dist/collection/components/notification-list/notification-item/notification-item.js +1 -1
  100. package/dist/collection/components/percentage-visualizer/percentage-visualizer.js +2 -2
  101. package/dist/collection/components/rule-editor/rule-chip-popover/rule-chip-popover.js +1 -1
  102. package/dist/collection/components/rule-editor/rule-editor.js +1 -1
  103. package/dist/collection/components/rule-editor/value-comparison-editor/value-comparison-editor-metadata.js +15 -0
  104. package/dist/collection/components/rule-editor/value-comparison-editor/value-comparison-editor.css +9 -0
  105. package/dist/collection/components/rule-editor/value-comparison-editor/value-comparison-editor.js +149 -0
  106. package/dist/collection/components/rule-gate/rule-gate.js +1 -1
  107. package/dist/collection/components/summary-popover/summary-popover.js +2 -2
  108. package/dist/collection/components/text-editor/mention-group-counter.js +2 -2
  109. package/dist/collection/components/text-editor/text-editor.js +1 -1
  110. package/dist/collection/components/trend-indicator/trend-indicator.js +1 -1
  111. package/dist/components/chat-icon-list.js +1 -1
  112. package/dist/components/chat-item.js +1 -1
  113. package/dist/components/currency-picker.js +1 -1
  114. package/dist/components/date-picker.js +1 -1
  115. package/dist/components/document-item.js +1 -1
  116. package/dist/components/feed-item-thumbnail-file-info.js +1 -1
  117. package/dist/components/feed-timeline-item.js +1 -1
  118. package/dist/components/kanban-group.js +1 -1
  119. package/dist/components/kanban-item.js +1 -1
  120. package/dist/components/lime-query-filter-comparison-editor.js +1 -1
  121. package/dist/components/lime-query-filter-comparison.js +1 -1
  122. package/dist/components/lime-query-filter-expression.js +1 -1
  123. package/dist/components/limebb-alert-dialog.js +1 -1
  124. package/dist/components/limebb-browser.js +1 -1
  125. package/dist/components/limebb-chat-list.js +1 -1
  126. package/dist/components/limebb-color-palette-picker.js +1 -1
  127. package/dist/components/limebb-color-palette-swatches.js +1 -1
  128. package/dist/components/limebb-composer-toolbar.js +1 -1
  129. package/dist/components/limebb-dashboard-widget.js +1 -1
  130. package/dist/components/limebb-date-range.js +1 -1
  131. package/dist/components/limebb-document-chips.js +1 -1
  132. package/dist/components/limebb-document-picker.js +1 -1
  133. package/dist/components/limebb-feed.js +1 -1
  134. package/dist/components/limebb-icon-picker.js +1 -1
  135. package/dist/components/limebb-info-tile-format.js +1 -1
  136. package/dist/components/limebb-info-tile.js +1 -1
  137. package/dist/components/limebb-lime-query-builder.js +1 -1
  138. package/dist/components/limebb-lime-query-response-format-builder.js +1 -1
  139. package/dist/components/limebb-loader.js +1 -1
  140. package/dist/components/limebb-locale-picker.js +1 -1
  141. package/dist/components/limebb-mention-group-counter.js +1 -1
  142. package/dist/components/limebb-rule-editor.js +1 -1
  143. package/dist/components/limebb-rule-gate.js +1 -1
  144. package/dist/components/limebb-text-editor.js +1 -1
  145. package/dist/components/limebb-trend-indicator.js +1 -1
  146. package/dist/components/limebb-value-comparison-editor.d.ts +11 -0
  147. package/dist/components/limebb-value-comparison-editor.js +1 -0
  148. package/dist/components/limetype-field.js +1 -1
  149. package/dist/components/live-docs-info.js +1 -1
  150. package/dist/components/notification-item.js +1 -1
  151. package/dist/components/order-by-editor.js +1 -1
  152. package/dist/components/order-by-item.js +1 -1
  153. package/dist/components/percentage-visualizer.js +1 -1
  154. package/dist/components/response-format-item.js +1 -1
  155. package/dist/components/rule-chip-popover.js +1 -1
  156. package/dist/components/summary-popover.js +1 -1
  157. package/dist/components/typing-indicator.js +1 -1
  158. package/dist/esm/{filter-group-logic-RXn-GGk1.js → filter-group-logic-1aucZQgy.js} +1 -1
  159. package/dist/esm/{index.esm-DAe4_MLR.js → index.esm-B1KM7sH7.js} +1 -1
  160. package/dist/esm/lime-crm-building-blocks.js +1 -1
  161. package/dist/esm/{lime-query-operators-DYlN1dAt.js → lime-query-operators-DvI2OyJI.js} +1 -1
  162. package/dist/esm/{lime-query-validation-DXxPZ2CH.js → lime-query-validation-CiIEITCJ.js} +1 -1
  163. package/dist/esm/limebb-alert-dialog.entry.js +1 -1
  164. package/dist/esm/limebb-browser.entry.js +3 -3
  165. package/dist/esm/limebb-chat-icon-list_3.entry.js +5 -5
  166. package/dist/esm/limebb-chat-list.entry.js +2 -2
  167. package/dist/esm/limebb-color-palette-picker.entry.js +1 -1
  168. package/dist/esm/limebb-color-palette-swatches.entry.js +1 -1
  169. package/dist/esm/limebb-component-config.entry.js +1 -1
  170. package/dist/esm/limebb-component-picker.entry.js +1 -1
  171. package/dist/esm/limebb-composer-toolbar.entry.js +3 -3
  172. package/dist/esm/limebb-currency-picker.entry.js +2 -2
  173. package/dist/esm/limebb-dashboard-widget.entry.js +1 -1
  174. package/dist/esm/limebb-data-cells.entry.js +1 -1
  175. package/dist/esm/limebb-date-picker.entry.js +2 -2
  176. package/dist/esm/limebb-date-range.entry.js +1 -1
  177. package/dist/esm/limebb-document-chips.entry.js +1 -1
  178. package/dist/esm/limebb-document-item.entry.js +2 -2
  179. package/dist/esm/limebb-document-picker.entry.js +1 -1
  180. package/dist/esm/limebb-feed-item-thumbnail-file-info.entry.js +1 -1
  181. package/dist/esm/limebb-feed-timeline-item.entry.js +2 -2
  182. package/dist/esm/limebb-feed.entry.js +2 -2
  183. package/dist/esm/limebb-icon-picker.entry.js +1 -1
  184. package/dist/esm/limebb-info-tile-format.entry.js +1 -1
  185. package/dist/esm/limebb-info-tile.entry.js +44 -9
  186. package/dist/esm/limebb-kanban-group.entry.js +2 -2
  187. package/dist/esm/limebb-kanban-item.entry.js +2 -2
  188. package/dist/esm/limebb-lime-query-builder.entry.js +3 -3
  189. package/dist/esm/limebb-lime-query-filter-builder.entry.js +2 -2
  190. package/dist/esm/limebb-lime-query-filter-comparison-editor_4.entry.js +7 -7
  191. package/dist/esm/limebb-lime-query-filter-comparison_2.entry.js +4 -4
  192. package/dist/esm/limebb-lime-query-order-by-editor_2.entry.js +4 -4
  193. package/dist/esm/limebb-lime-query-order-by-item.entry.js +2 -2
  194. package/dist/esm/limebb-lime-query-response-format-builder.entry.js +3 -3
  195. package/dist/esm/limebb-lime-query-response-format-editor_2.entry.js +1 -1
  196. package/dist/esm/limebb-limeobject-file-viewer.entry.js +1 -1
  197. package/dist/esm/limebb-live-docs-info.entry.js +2 -2
  198. package/dist/esm/limebb-loader.entry.js +18 -1
  199. package/dist/esm/limebb-locale-picker.entry.js +2 -2
  200. package/dist/esm/limebb-mention-group-counter.entry.js +2 -2
  201. package/dist/esm/limebb-mention.entry.js +1 -1
  202. package/dist/esm/limebb-navigation-button_2.entry.js +2 -2
  203. package/dist/esm/limebb-notification-item.entry.js +2 -2
  204. package/dist/esm/limebb-notification-list.entry.js +1 -1
  205. package/dist/esm/limebb-object-chip.entry.js +2 -2
  206. package/dist/esm/limebb-percentage-visualizer.entry.js +3 -3
  207. package/dist/esm/limebb-property-selector.entry.js +2 -2
  208. package/dist/esm/limebb-rule-arg-filter-editor.entry.js +1 -1
  209. package/dist/esm/limebb-rule-chip-popover.entry.js +2 -2
  210. package/dist/esm/limebb-rule-editor.entry.js +2 -2
  211. package/dist/esm/limebb-rule-gate.entry.js +2 -2
  212. package/dist/esm/limebb-text-editor.entry.js +3 -3
  213. package/dist/esm/limebb-trend-indicator.entry.js +2 -2
  214. package/dist/esm/limebb-value-comparison-editor.entry.js +73 -0
  215. package/dist/esm/{limetype-C1wEJnPI.js → limetype-CIkoDD1B.js} +1 -1
  216. package/dist/esm/loader.js +1 -1
  217. package/dist/lime-crm-building-blocks/lime-crm-building-blocks.esm.js +1 -1
  218. package/dist/lime-crm-building-blocks/{p-692084d2.entry.js → p-041f1094.entry.js} +1 -1
  219. package/dist/lime-crm-building-blocks/{p-3c437049.entry.js → p-096ea04d.entry.js} +1 -1
  220. package/dist/lime-crm-building-blocks/{p-7f5c97fe.entry.js → p-0d6d8b72.entry.js} +1 -1
  221. package/dist/lime-crm-building-blocks/{p-dc1d543d.entry.js → p-16fad0a8.entry.js} +1 -1
  222. package/dist/lime-crm-building-blocks/{p-56bb13b2.entry.js → p-191e4dcd.entry.js} +1 -1
  223. package/dist/lime-crm-building-blocks/{p-8ed7b025.entry.js → p-1a076d37.entry.js} +1 -1
  224. package/dist/lime-crm-building-blocks/{p-efab4f7e.entry.js → p-1b5f48c2.entry.js} +1 -1
  225. package/dist/lime-crm-building-blocks/{p-81655182.entry.js → p-201498a9.entry.js} +1 -1
  226. package/dist/lime-crm-building-blocks/{p-c7c5991f.entry.js → p-26e25dbd.entry.js} +1 -1
  227. package/dist/lime-crm-building-blocks/{p-24337de2.entry.js → p-29dd2424.entry.js} +1 -1
  228. package/dist/lime-crm-building-blocks/{p-563d69ff.entry.js → p-30f6d7ea.entry.js} +1 -1
  229. package/dist/lime-crm-building-blocks/{p-99464fa7.entry.js → p-340250da.entry.js} +1 -1
  230. package/dist/lime-crm-building-blocks/{p-18ce3ce5.entry.js → p-3f2f1826.entry.js} +1 -1
  231. package/dist/lime-crm-building-blocks/{p-4c10bea0.entry.js → p-46225433.entry.js} +1 -1
  232. package/dist/lime-crm-building-blocks/{p-68a951f5.entry.js → p-4cd99453.entry.js} +1 -1
  233. package/dist/lime-crm-building-blocks/{p-464b02c2.entry.js → p-52d8f7c2.entry.js} +1 -1
  234. package/dist/lime-crm-building-blocks/p-555da984.entry.js +1 -0
  235. package/dist/lime-crm-building-blocks/{p-efb70fbb.entry.js → p-6299c46b.entry.js} +1 -1
  236. package/dist/lime-crm-building-blocks/{p-b16bbda2.entry.js → p-69cf07ba.entry.js} +1 -1
  237. package/dist/lime-crm-building-blocks/{p-47a7b3fd.entry.js → p-6c4521a0.entry.js} +1 -1
  238. package/dist/lime-crm-building-blocks/{p-8d5311e4.entry.js → p-6f0a5401.entry.js} +1 -1
  239. package/dist/lime-crm-building-blocks/{p-7d969bbe.entry.js → p-71e1c5f0.entry.js} +1 -1
  240. package/dist/lime-crm-building-blocks/p-759d0fc2.entry.js +1 -0
  241. package/dist/lime-crm-building-blocks/{p-5eef1781.entry.js → p-7aaf805d.entry.js} +1 -1
  242. package/dist/lime-crm-building-blocks/{p-8d14a58a.entry.js → p-8c3970ed.entry.js} +1 -1
  243. package/dist/lime-crm-building-blocks/{p-a5850f04.entry.js → p-9909b0bf.entry.js} +1 -1
  244. package/dist/lime-crm-building-blocks/{p-6cf0a1cd.entry.js → p-991783f8.entry.js} +1 -1
  245. package/dist/lime-crm-building-blocks/{p-DzXJyKRS.js → p-B5QzrGTX.js} +1 -1
  246. package/dist/lime-crm-building-blocks/{p-D3UYWGdn.js → p-BneXZK-Q.js} +1 -1
  247. package/dist/lime-crm-building-blocks/{p-BbFGcMnU.js → p-DK4A47Sj.js} +1 -1
  248. package/dist/lime-crm-building-blocks/{p-y_s8hZmV.js → p-DjwVpKf5.js} +1 -1
  249. package/dist/lime-crm-building-blocks/{p-5a718d20.entry.js → p-a21d6f7e.entry.js} +1 -1
  250. package/dist/lime-crm-building-blocks/{p-43af24b5.entry.js → p-a2c8e1af.entry.js} +1 -1
  251. package/dist/lime-crm-building-blocks/p-a8684418.entry.js +1 -0
  252. package/dist/lime-crm-building-blocks/{p-0ba1294a.entry.js → p-b264b37d.entry.js} +1 -1
  253. package/dist/lime-crm-building-blocks/{p-ecd0280d.entry.js → p-b431df3c.entry.js} +1 -1
  254. package/dist/lime-crm-building-blocks/{p-22296e19.entry.js → p-b4b103c1.entry.js} +1 -1
  255. package/dist/lime-crm-building-blocks/{p-0fac2307.entry.js → p-b7d917ed.entry.js} +1 -1
  256. package/dist/lime-crm-building-blocks/p-c0d39ae4.entry.js +1 -0
  257. package/dist/lime-crm-building-blocks/{p-8238723b.entry.js → p-c4c3f054.entry.js} +1 -1
  258. package/dist/lime-crm-building-blocks/{p-072756ea.entry.js → p-c6cc1438.entry.js} +1 -1
  259. package/dist/lime-crm-building-blocks/{p-bd264cfa.entry.js → p-c72d3231.entry.js} +1 -1
  260. package/dist/lime-crm-building-blocks/{p-a6103d04.entry.js → p-c7dbd961.entry.js} +1 -1
  261. package/dist/lime-crm-building-blocks/{p-b01f2045.entry.js → p-c8cf6e4d.entry.js} +1 -1
  262. package/dist/lime-crm-building-blocks/{p-1dfdf045.entry.js → p-cea4fe16.entry.js} +1 -1
  263. package/dist/lime-crm-building-blocks/p-d6ac6cd3.entry.js +1 -0
  264. package/dist/lime-crm-building-blocks/{p-7a4704dc.entry.js → p-d8835b8c.entry.js} +1 -1
  265. package/dist/lime-crm-building-blocks/{p-603ab702.entry.js → p-e1223704.entry.js} +1 -1
  266. package/dist/lime-crm-building-blocks/{p-49bc396e.entry.js → p-e174dccd.entry.js} +1 -1
  267. package/dist/lime-crm-building-blocks/{p-725e6748.entry.js → p-ec22438d.entry.js} +1 -1
  268. package/dist/lime-crm-building-blocks/{p-dc3a86f3.entry.js → p-efd62913.entry.js} +1 -1
  269. package/dist/lime-crm-building-blocks/{p-9639c6ee.entry.js → p-f22e2539.entry.js} +1 -1
  270. package/dist/lime-crm-building-blocks/{p-3996a598.entry.js → p-f58d25e5.entry.js} +1 -1
  271. package/dist/lime-crm-building-blocks/{p-16fa6f3e.entry.js → p-fac7ff61.entry.js} +1 -1
  272. package/dist/lime-crm-building-blocks/{p-5006c5ea.entry.js → p-fb23df8e.entry.js} +1 -1
  273. package/dist/lime-crm-building-blocks/{p-7b9359cc.entry.js → p-ff686a4e.entry.js} +1 -1
  274. package/dist/types/components/info-tile/info-tile.d.ts +50 -1
  275. package/dist/types/components/rule-editor/value-comparison-editor/value-comparison-editor-metadata.d.ts +12 -0
  276. package/dist/types/components/rule-editor/value-comparison-editor/value-comparison-editor.d.ts +45 -0
  277. package/dist/types/components.d.ts +116 -0
  278. package/package.json +4 -4
  279. package/dist/lime-crm-building-blocks/p-07ef2fd0.entry.js +0 -1
  280. package/dist/lime-crm-building-blocks/p-6fc4e731.entry.js +0 -1
  281. package/dist/lime-crm-building-blocks/p-898b097e.entry.js +0 -1
  282. package/dist/lime-crm-building-blocks/p-ec335be5.entry.js +0 -1
  283. /package/dist/lime-crm-building-blocks/{p-CqRNpSRV.js → p-BVxuJgRM.js} +0 -0
@@ -1 +1 @@
1
- import{r,h as a}from"./p-DYpn0EkA.js";const o=class{constructor(o){r(this,o),this.renderHeader=()=>{if(this.heading||this.subheading||this.supportingText||this.icon)return a("limel-header",{heading:this.heading,subheading:this.subheading,supportingText:this.supportingText,icon:this.icon},a("slot",{name:"header-actions"}))}}render(){return[this.renderHeader(),a("slot",{key:"f4f4a4e0442f5cfc06ef8f277840810eda9a589c",name:"content"})]}};o.style=":host(limebb-dashboard-widget){--dashboard-widget-background-color:var( --start-page-grid-widget-background-color, rgb(var(--contrast-100)) );--header-icon-color:var(--dashboard-widget-icon-color);--header-background-color:var( --dashboard-widget-header-background-color, var(--start-page-grid-widget-header-color) );--dashboard-widget-border-radius:var( --start-page-grid-widget-border-radius, 1rem );--header-top-right-left-border-radius:0;display:flex;flex-direction:column;border-radius:var(--dashboard-widget-border-radius);background-color:var(--dashboard-widget-background-color);height:100%;width:100%;overflow:hidden}::slotted(limebb-navigation-button[slot=header-actions]){--navigation-button-background-color:var( --dashboard-widget-header-background-color, var(--start-page-grid-widget-header-color, rgb(var(--contrast-300))) )}";export{o as limebb_dashboard_widget}
1
+ import{r,h as a}from"./p-DYpn0EkA.js";const d=class{constructor(d){r(this,d),this.renderHeader=()=>{if(this.heading||this.subheading||this.supportingText||this.icon)return a("limel-header",{heading:this.heading,subheading:this.subheading,supportingText:this.supportingText,icon:this.icon},a("slot",{name:"header-actions"}))}}render(){return[this.renderHeader(),a("slot",{key:"6b710aba0ec66494e7a65e9ded69782bd8c09894",name:"content"})]}};d.style=":host(limebb-dashboard-widget){--dashboard-widget-background-color:var( --start-page-grid-widget-background-color, rgb(var(--contrast-100)) );--header-icon-color:var(--dashboard-widget-icon-color);--header-background-color:var( --dashboard-widget-header-background-color, var(--start-page-grid-widget-header-color) );--dashboard-widget-border-radius:var( --start-page-grid-widget-border-radius, 1rem );--header-top-right-left-border-radius:0;display:flex;flex-direction:column;border-radius:var(--dashboard-widget-border-radius);background-color:var(--dashboard-widget-background-color);height:100%;width:100%;overflow:hidden}::slotted(limebb-navigation-button[slot=header-actions]){--navigation-button-background-color:var( --dashboard-widget-header-background-color, var(--start-page-grid-widget-header-color, rgb(var(--contrast-300))) )}";export{d as limebb_dashboard_widget}
@@ -1 +1 @@
1
- import{r as t,c as e,h as i}from"./p-DYpn0EkA.js";function o(t,e,i){if(null===i)return void t.push({path:e});const o=i,s="_alias"in o,n="#description"in o,a=Object.keys(o).filter((t=>"_alias"!==t&&"#description"!==t));if(0!==a.length)if(s||n){const i={};for(const t of a)i[t]=o[t];t.push(...r(i,e))}else t.push(...r(i,e));else{const i=o._alias,r=o["#description"];t.push(i||r?{path:e,alias:i,description:r}:{path:e})}}function r(t,e=""){if(!t)return[];const i=[];for(const[r,s]of Object.entries(t))"object"==typeof s&&o(i,e?`${e}.${r}`:r,s);return i}function s(t,e,i){const o=t[e];if(o&&"object"==typeof o&&!("_alias"in o)&&!("#description"in o))return;const r={};i.alias&&""!==i.alias.trim()&&(r._alias=i.alias),i.description&&""!==i.description.trim()&&(r["#description"]=i.description),t[e]=Object.keys(r).length>0?r:null}function n(t,e){const i=t[e];if(!i)return t[e]={},t[e];if("object"==typeof i){const t=i;return Object.keys(t).filter((t=>"_alias"!==t&&"#description"!==t)),t}return t[e]={},t[e]}const a=class{constructor(i){t(this,i),this.change=e(this,"change"),this.label="Properties",this.items=[],this.handleItemChange=t=>e=>{e.stopPropagation();const i=[...this.items];null===e.detail?i.splice(t,1):i[t]=e.detail,this.items=i,this.emitChange()},this.handleAddProperty=()=>{this.items=[...this.items,{path:""}],this.emitChange()}}componentWillLoad(){this.items=this.value?this.isEmptyResponseFormat(this.value)?[]:this.value.object?r(this.value.object):[]:[{path:"_id"}]}componentWillUpdate(){if(this.value)if(this.value.object&&!this.isEmptyResponseFormat(this.value)){const t=r(this.value.object);(t.length!==this.items.length||!t.every(((t,e)=>{const i=this.items[e];return i&&t.path===i.path&&t.alias===i.alias&&t.description===i.description})))&&(this.items=t)}else this.items.length>0&&(this.items=[])}render(){return this.limetype?0===this.items.length?i("div",{class:"response-format-editor"},i("h4",{class:"header"},this.label),i("div",{class:"empty-state"},i("p",{class:"empty-state-message"},"No properties selected. The response will return empty objects."),i("limel-button",{label:"Add Property",icon:"plus_math",onClick:this.handleAddProperty}))):i("div",{class:"response-format-editor"},i("limel-header",{subheading:this.label},this.renderPropertyCount()),i("div",{class:"property-list"},this.items.map(((t,e)=>this.renderItem(t,e))),i("limel-button",{label:"Property",disabled:this.items.some((t=>!t.path||""===t.path.trim())),icon:{name:"plus_math",title:"Add"},onClick:this.handleAddProperty}))):i("div",{class:"empty-state"},i("p",null,"Select a limetype to choose properties"))}renderPropertyCount(){return[i("limel-badge",{slot:"actions",id:"counter-badge",label:this.items.length.toString()}),i("limel-tooltip",{elementId:"counter-badge",slot:"actions",label:"Number of selected properties"})]}renderItem(t,e){return i("limebb-lime-query-response-format-item",{key:`${t.path}-${e}`,class:"property-item",platform:this.platform,context:this.context,limetype:this.limetype,item:t,onItemChange:this.handleItemChange(e)})}emitChange(){const t=function(t){const e={};for(const i of t){const t=i.path.split(".");let o=e;for(let e=0;e<t.length;e++){const r=t[e];e===t.length-1?s(o,r,i):o=n(o,r)}}return e}(this.items);this.change.emit({object:t})}isEmptyResponseFormat(t){return!(!t||0!==Object.keys(t).length&&(!t.object||0!==Object.keys(t.object).length||t.aggregates))}};a.style=":host(limebb-lime-query-response-format-editor){display:block;width:100%}.response-format-editor{display:flex;flex-direction:column;padding:1rem 0}limel-badge[slot=actions]{--badge-background-color:rgb(var(--contrast-200));margin-right:0.25rem}.property-list{display:flex;flex-direction:column;border-radius:0 0 0.75rem 0.75rem;padding:0.25rem;background-color:rgb(var(--contrast-300))}.empty-state{padding:2rem;text-align:center;color:rgb(var(--contrast-700));font-style:italic}.empty-state p{margin:0}.empty-state .empty-state-message{margin-bottom:1rem;font-size:0.875rem}.empty-state limel-button{margin:0 auto;max-width:200px}";const l=class{constructor(i){t(this,i),this.itemChange=e(this,"itemChange"),this.showAliasInput=!1,this.showDescriptionInput=!1,this.handlePathChange=t=>{t.stopPropagation(),this.itemChange.emit(Object.assign(Object.assign({},this.item),{path:t.detail}))},this.toggleAliasInput=()=>{this.showAliasInput=!this.showAliasInput},this.toggleDescriptionInput=()=>{this.showDescriptionInput=!this.showDescriptionInput},this.handleAliasChange=t=>{t.stopPropagation();const e=t.detail;this.itemChange.emit(Object.assign(Object.assign({},this.item),{alias:e||void 0}))},this.handleDescriptionChange=t=>{t.stopPropagation();const e=t.detail;this.itemChange.emit(Object.assign(Object.assign({},this.item),{description:e||void 0}))},this.handleAliasBlur=()=>{if(this.item.alias){const t=this.item.alias.trim();t!==this.item.alias&&this.itemChange.emit(Object.assign(Object.assign({},this.item),{alias:t||void 0}))}},this.handleDescriptionBlur=()=>{if(this.item.description){const t=this.item.description.trim();t!==this.item.description&&this.itemChange.emit(Object.assign(Object.assign({},this.item),{description:t||void 0}))}},this.handleRemove=()=>{this.itemChange.emit(null)}}componentWillLoad(){this.showAliasInput=!!this.item.alias,this.showDescriptionInput=!!this.item.description}componentWillUpdate(){this.item.alias&&!this.showAliasInput&&(this.showAliasInput=!0),this.item.description&&!this.showDescriptionInput&&(this.showDescriptionInput=!0)}render(){return[i("div",{key:"98518fb21bacceef31e398faf0e7d66d92152a9f",class:"property-controls"},i("div",{key:"1d636436ce63b930abdfb40600106d0d8f643663",class:"property-path"},i("limebb-property-selector",{key:"3e0fa6a5c5c414c70e38b52f7157a806be8358df",platform:this.platform,context:this.context,limetype:this.limetype,label:"Property",value:this.item.path,required:!0,onChange:this.handlePathChange}),i("div",{key:"03bc814455e46812ad7365ddf893431e97b255df",class:"input-grid"},this.renderAliasInput()),i("div",{key:"8d6b47ff44a01288e9875494b1fea5a57649205f",class:"input-grid"},this.renderDescriptionInput()),i("div",{key:"e2e4741bc80c0fef0741f153c7183b8a12da7aa9",class:"button-group"},this.renderAliasButton(),this.renderDescriptionButton())),i("limel-icon-button",{key:"7f204e6331dbcd0e8e62a5e9a61676f62b14a045",icon:"trash",label:"Remove property",onClick:this.handleRemove}))]}renderAliasButton(){if(!this.showAliasInput)return i("button",{type:"button",class:"alias",onClick:this.toggleAliasInput},"+ Alias")}renderDescriptionButton(){if(!this.showDescriptionInput)return i("button",{type:"button",class:"description",onClick:this.toggleDescriptionInput},"+ Description")}renderAliasInput(){if(this.showAliasInput)return i("div",{class:"input-group"},i("limel-input-field",{label:"Alias",value:this.item.alias||"",placeholder:"Custom property name...",onChange:this.handleAliasChange,onBlur:this.handleAliasBlur,leadingIcon:"add_tag"}),i("limel-icon-button",{class:"remove-alias",icon:"multiply",onClick:this.toggleAliasInput,label:"Remove alias",disabled:!!this.item.alias}))}renderDescriptionInput(){if(this.showDescriptionInput)return i("div",{class:"input-group"},i("limel-input-field",{label:"Description",value:this.item.description||"",placeholder:"Describe this property for AI...",onChange:this.handleDescriptionChange,onBlur:this.handleDescriptionBlur,leadingIcon:"comments"}),i("limel-icon-button",{class:"remove-description",icon:"multiply",onClick:this.toggleDescriptionInput,label:"Remove description",disabled:!!this.item.description}))}};l.style='@charset "UTF-8";*{box-sizing:border-box;min-width:0}:host(limebb-lime-query-response-format-item){display:flex;flex-direction:column;gap:0.5rem}.property-controls{transition:box-shadow 0.4s ease, background-color 0.6s ease;display:flex;align-items:flex-start;gap:0.5rem;width:100%;padding:0.75rem 0.75rem 0 0.75rem;border-radius:0.75rem}.property-controls:hover,.property-controls:focus,.property-controls:focus-within{transition-duration:0.2s;background-color:rgb(var(--contrast-100));box-shadow:var(--shadow-inflated-16)}.property-controls limel-icon-button{margin-top:0.125rem}.property-path{flex-grow:1;display:flex;flex-direction:column;padding-bottom:0.25rem}.button-group,.input-group{padding-left:1rem}.button-group:not(:empty),.input-group:not(:empty){padding-top:0.25rem;padding-bottom:0.25rem}.button-group{display:flex;gap:0.5rem;align-items:center}.button-group button{appearance:none;background:none;border:none;padding:0;margin:0;font:inherit;color:inherit;text-align:inherit;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;font-size:0.625rem;padding:0 0.5rem 0 0.25rem;display:flex;align-items:center;gap:0.25rem;border-radius:0.25rem}.button-group button:hover,.button-group button:focus,.button-group button:focus-visible{will-change:color, background-color, box-shadow, transform}.button-group button:hover,.button-group button:focus-visible{transform:translate3d(0, 0.01rem, 0);color:var(--limel-theme-on-surface-color);background-color:var(--lime-elevated-surface-background-color)}.button-group button:hover{box-shadow:var(--button-shadow-hovered)}.button-group button:active{--limel-clickable-transform-timing-function:cubic-bezier( 0.83, -0.15, 0.49, 1.16 );transform:translate3d(0, 0.05rem, 0);box-shadow:var(--button-shadow-pressed)}.button-group button:hover,.button-group button:active{--limel-clickable-transition-speed:0.2s;--limel-clickable-transform-speed:0.16s}.button-group button:focus{outline:none}.button-group button:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}.button-group button:hover{transform:scale(1.2)}.button-group limel-icon{width:1rem}.input-group{display:flex;align-items:center}.input-group limel-input-field{flex-grow:1}.input-group limel-icon-button{transform:scale(0.85)}.metadata{flex-grow:1;padding-left:1rem}@media (max-width: 768px){.property-controls{flex-direction:column;gap:0.5rem}}.input-grid{--limebb-l-q-r-f-i--opacity-transition-speed:0.1s;--limebb-l-q-r-f-i--opacity-transition-delay:0s;--limebb-l-q-r-f-i--grid-template-rows-transition-speed:0.3s;transition:grid-template-rows var(--limebb-l-q-r-f-i--grid-template-rows-transition-speed) ease;display:grid;grid-template-rows:0fr}.input-grid .input-group{transition:opacity var(--limebb-l-q-r-f-i--opacity-transition-speed) ease var(--limebb-l-q-r-f-i--opacity-transition-delay), padding var(--limebb-l-q-r-f-i--opacity-transition-speed) ease var(--limebb-l-q-r-f-i--opacity-transition-delay);overflow:hidden;opacity:0}.input-grid:not(:empty){--limebb-l-q-r-f-i--opacity-transition-speed:0.2s;--limebb-l-q-r-f-i--opacity-transition-delay:0.1s;--limebb-l-q-r-f-i--grid-template-rows-transition-speed:0.2s;grid-template-rows:1fr}.input-grid:not(:empty) .input-group{opacity:1}.button-group:hover .input-grid{will-change:grid-template-rows}.button-group:hover .input-group{will-change:opacity, padding}';export{a as limebb_lime_query_response_format_editor,l as limebb_lime_query_response_format_item}
1
+ import{r as t,c as e,h as i}from"./p-DYpn0EkA.js";function o(t,e,i){if(null===i)return void t.push({path:e});const o=i,s="_alias"in o,n="#description"in o,a=Object.keys(o).filter((t=>"_alias"!==t&&"#description"!==t));if(0!==a.length)if(s||n){const i={};for(const t of a)i[t]=o[t];t.push(...r(i,e))}else t.push(...r(i,e));else{const i=o._alias,r=o["#description"];t.push(i||r?{path:e,alias:i,description:r}:{path:e})}}function r(t,e=""){if(!t)return[];const i=[];for(const[r,s]of Object.entries(t))"object"==typeof s&&o(i,e?`${e}.${r}`:r,s);return i}function s(t,e,i){const o=t[e];if(o&&"object"==typeof o&&!("_alias"in o)&&!("#description"in o))return;const r={};i.alias&&""!==i.alias.trim()&&(r._alias=i.alias),i.description&&""!==i.description.trim()&&(r["#description"]=i.description),t[e]=Object.keys(r).length>0?r:null}function n(t,e){const i=t[e];if(!i)return t[e]={},t[e];if("object"==typeof i){const t=i;return Object.keys(t).filter((t=>"_alias"!==t&&"#description"!==t)),t}return t[e]={},t[e]}const a=class{constructor(i){t(this,i),this.change=e(this,"change"),this.label="Properties",this.items=[],this.handleItemChange=t=>e=>{e.stopPropagation();const i=[...this.items];null===e.detail?i.splice(t,1):i[t]=e.detail,this.items=i,this.emitChange()},this.handleAddProperty=()=>{this.items=[...this.items,{path:""}],this.emitChange()}}componentWillLoad(){this.items=this.value?this.isEmptyResponseFormat(this.value)?[]:this.value.object?r(this.value.object):[]:[{path:"_id"}]}componentWillUpdate(){if(this.value)if(this.value.object&&!this.isEmptyResponseFormat(this.value)){const t=r(this.value.object);(t.length!==this.items.length||!t.every(((t,e)=>{const i=this.items[e];return i&&t.path===i.path&&t.alias===i.alias&&t.description===i.description})))&&(this.items=t)}else this.items.length>0&&(this.items=[])}render(){return this.limetype?0===this.items.length?i("div",{class:"response-format-editor"},i("h4",{class:"header"},this.label),i("div",{class:"empty-state"},i("p",{class:"empty-state-message"},"No properties selected. The response will return empty objects."),i("limel-button",{label:"Add Property",icon:"plus_math",onClick:this.handleAddProperty}))):i("div",{class:"response-format-editor"},i("limel-header",{subheading:this.label},this.renderPropertyCount()),i("div",{class:"property-list"},this.items.map(((t,e)=>this.renderItem(t,e))),i("limel-button",{label:"Property",disabled:this.items.some((t=>!t.path||""===t.path.trim())),icon:{name:"plus_math",title:"Add"},onClick:this.handleAddProperty}))):i("div",{class:"empty-state"},i("p",null,"Select a limetype to choose properties"))}renderPropertyCount(){return[i("limel-badge",{slot:"actions",id:"counter-badge",label:this.items.length.toString()}),i("limel-tooltip",{elementId:"counter-badge",slot:"actions",label:"Number of selected properties"})]}renderItem(t,e){return i("limebb-lime-query-response-format-item",{key:`${t.path}-${e}`,class:"property-item",platform:this.platform,context:this.context,limetype:this.limetype,item:t,onItemChange:this.handleItemChange(e)})}emitChange(){const t=function(t){const e={};for(const i of t){const t=i.path.split(".");let o=e;for(let e=0;e<t.length;e++){const r=t[e];e===t.length-1?s(o,r,i):o=n(o,r)}}return e}(this.items);this.change.emit({object:t})}isEmptyResponseFormat(t){return!(!t||0!==Object.keys(t).length&&(!t.object||0!==Object.keys(t.object).length||t.aggregates))}};a.style=":host(limebb-lime-query-response-format-editor){display:block;width:100%}.response-format-editor{display:flex;flex-direction:column;padding:1rem 0}limel-badge[slot=actions]{--badge-background-color:rgb(var(--contrast-200));margin-right:0.25rem}.property-list{display:flex;flex-direction:column;border-radius:0 0 0.75rem 0.75rem;padding:0.25rem;background-color:rgb(var(--contrast-300))}.empty-state{padding:2rem;text-align:center;color:rgb(var(--contrast-700));font-style:italic}.empty-state p{margin:0}.empty-state .empty-state-message{margin-bottom:1rem;font-size:0.875rem}.empty-state limel-button{margin:0 auto;max-width:200px}";const l=class{constructor(i){t(this,i),this.itemChange=e(this,"itemChange"),this.showAliasInput=!1,this.showDescriptionInput=!1,this.handlePathChange=t=>{t.stopPropagation(),this.itemChange.emit(Object.assign(Object.assign({},this.item),{path:t.detail}))},this.toggleAliasInput=()=>{this.showAliasInput=!this.showAliasInput},this.toggleDescriptionInput=()=>{this.showDescriptionInput=!this.showDescriptionInput},this.handleAliasChange=t=>{t.stopPropagation();const e=t.detail;this.itemChange.emit(Object.assign(Object.assign({},this.item),{alias:e||void 0}))},this.handleDescriptionChange=t=>{t.stopPropagation();const e=t.detail;this.itemChange.emit(Object.assign(Object.assign({},this.item),{description:e||void 0}))},this.handleAliasBlur=()=>{if(this.item.alias){const t=this.item.alias.trim();t!==this.item.alias&&this.itemChange.emit(Object.assign(Object.assign({},this.item),{alias:t||void 0}))}},this.handleDescriptionBlur=()=>{if(this.item.description){const t=this.item.description.trim();t!==this.item.description&&this.itemChange.emit(Object.assign(Object.assign({},this.item),{description:t||void 0}))}},this.handleRemove=()=>{this.itemChange.emit(null)}}componentWillLoad(){this.showAliasInput=!!this.item.alias,this.showDescriptionInput=!!this.item.description}componentWillUpdate(){this.item.alias&&!this.showAliasInput&&(this.showAliasInput=!0),this.item.description&&!this.showDescriptionInput&&(this.showDescriptionInput=!0)}render(){return[i("div",{key:"d64c80f48ebdb1a716ba8a9bcb57f168929c3f63",class:"property-controls"},i("div",{key:"c562b74c745e958337850d1c12bd9ee01f681c6c",class:"property-path"},i("limebb-property-selector",{key:"ae80e4606cbe91e30ca5b3c55495a9a895df40b0",platform:this.platform,context:this.context,limetype:this.limetype,label:"Property",value:this.item.path,required:!0,onChange:this.handlePathChange}),i("div",{key:"775da8d9633e517441dafed44bdc78396bbeade9",class:"input-grid"},this.renderAliasInput()),i("div",{key:"a734205bddb9132aae4a27b1bf16376caeb19fdf",class:"input-grid"},this.renderDescriptionInput()),i("div",{key:"d93229a166f757e5eb3d436fccf34a6c57b12627",class:"button-group"},this.renderAliasButton(),this.renderDescriptionButton())),i("limel-icon-button",{key:"33b9209166ce2a2186d06806f52faad115e264cf",icon:"trash",label:"Remove property",onClick:this.handleRemove}))]}renderAliasButton(){if(!this.showAliasInput)return i("button",{type:"button",class:"alias",onClick:this.toggleAliasInput},"+ Alias")}renderDescriptionButton(){if(!this.showDescriptionInput)return i("button",{type:"button",class:"description",onClick:this.toggleDescriptionInput},"+ Description")}renderAliasInput(){if(this.showAliasInput)return i("div",{class:"input-group"},i("limel-input-field",{label:"Alias",value:this.item.alias||"",placeholder:"Custom property name...",onChange:this.handleAliasChange,onBlur:this.handleAliasBlur,leadingIcon:"add_tag"}),i("limel-icon-button",{class:"remove-alias",icon:"multiply",onClick:this.toggleAliasInput,label:"Remove alias",disabled:!!this.item.alias}))}renderDescriptionInput(){if(this.showDescriptionInput)return i("div",{class:"input-group"},i("limel-input-field",{label:"Description",value:this.item.description||"",placeholder:"Describe this property for AI...",onChange:this.handleDescriptionChange,onBlur:this.handleDescriptionBlur,leadingIcon:"comments"}),i("limel-icon-button",{class:"remove-description",icon:"multiply",onClick:this.toggleDescriptionInput,label:"Remove description",disabled:!!this.item.description}))}};l.style='@charset "UTF-8";*{box-sizing:border-box;min-width:0}:host(limebb-lime-query-response-format-item){display:flex;flex-direction:column;gap:0.5rem}.property-controls{transition:box-shadow 0.4s ease, background-color 0.6s ease;display:flex;align-items:flex-start;gap:0.5rem;width:100%;padding:0.75rem 0.75rem 0 0.75rem;border-radius:0.75rem}.property-controls:hover,.property-controls:focus,.property-controls:focus-within{transition-duration:0.2s;background-color:rgb(var(--contrast-100));box-shadow:var(--shadow-inflated-16)}.property-controls limel-icon-button{margin-top:0.125rem}.property-path{flex-grow:1;display:flex;flex-direction:column;padding-bottom:0.25rem}.button-group,.input-group{padding-left:1rem}.button-group:not(:empty),.input-group:not(:empty){padding-top:0.25rem;padding-bottom:0.25rem}.button-group{display:flex;gap:0.5rem;align-items:center}.button-group button{appearance:none;background:none;border:none;padding:0;margin:0;font:inherit;color:inherit;text-align:inherit;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;font-size:0.625rem;padding:0 0.5rem 0 0.25rem;display:flex;align-items:center;gap:0.25rem;border-radius:0.25rem}.button-group button:hover,.button-group button:focus,.button-group button:focus-visible{will-change:color, background-color, box-shadow, transform}.button-group button:hover,.button-group button:focus-visible{transform:translate3d(0, 0.01rem, 0);color:var(--limel-theme-on-surface-color);background-color:var(--lime-elevated-surface-background-color)}.button-group button:hover{box-shadow:var(--button-shadow-hovered)}.button-group button:active{--limel-clickable-transform-timing-function:cubic-bezier( 0.83, -0.15, 0.49, 1.16 );transform:translate3d(0, 0.05rem, 0);box-shadow:var(--button-shadow-pressed)}.button-group button:hover,.button-group button:active{--limel-clickable-transition-speed:0.2s;--limel-clickable-transform-speed:0.16s}.button-group button:focus{outline:none}.button-group button:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}.button-group button:hover{transform:scale(1.2)}.button-group limel-icon{width:1rem}.input-group{display:flex;align-items:center}.input-group limel-input-field{flex-grow:1}.input-group limel-icon-button{transform:scale(0.85)}.metadata{flex-grow:1;padding-left:1rem}@media (max-width: 768px){.property-controls{flex-direction:column;gap:0.5rem}}.input-grid{--limebb-l-q-r-f-i--opacity-transition-speed:0.1s;--limebb-l-q-r-f-i--opacity-transition-delay:0s;--limebb-l-q-r-f-i--grid-template-rows-transition-speed:0.3s;transition:grid-template-rows var(--limebb-l-q-r-f-i--grid-template-rows-transition-speed) ease;display:grid;grid-template-rows:0fr}.input-grid .input-group{transition:opacity var(--limebb-l-q-r-f-i--opacity-transition-speed) ease var(--limebb-l-q-r-f-i--opacity-transition-delay), padding var(--limebb-l-q-r-f-i--opacity-transition-speed) ease var(--limebb-l-q-r-f-i--opacity-transition-delay);overflow:hidden;opacity:0}.input-grid:not(:empty){--limebb-l-q-r-f-i--opacity-transition-speed:0.2s;--limebb-l-q-r-f-i--opacity-transition-delay:0.1s;--limebb-l-q-r-f-i--grid-template-rows-transition-speed:0.2s;grid-template-rows:1fr}.input-grid:not(:empty) .input-group{opacity:1}.button-group:hover .input-grid{will-change:grid-template-rows}.button-group:hover .input-group{will-change:opacity, padding}';export{a as limebb_lime_query_response_format_editor,l as limebb_lime_query_response_format_item}
@@ -0,0 +1 @@
1
+ import{r as t,c as e,h as i}from"./p-DYpn0EkA.js";import{b as s}from"./p-BVxuJgRM.js";const h=class{constructor(i){t(this,i),this.change=e(this,"change"),this.disabled=!1,this.readonly=!1,this.invalid=!1,this.required=!1,this.type="datetime",this.shouldEmitValueAsString=!0,this.handleChange=t=>{if(!t.detail)return;t.stopPropagation();const e=(i=t.detail,"datetime"===(s=this.type)||"time"===s?i:new Date(Date.UTC(i.getFullYear(),i.getMonth(),i.getDate())));var i,s;this.change.emit(this.shouldEmitValueAsString?e.toISOString():e)},this.formatter=t=>this.dateTimeFormatter.format(t,a[this.type]||this.type)}render(){return this.language||(this.language=this.getAppLanguage()),this.value&&(this.shouldEmitValueAsString="string"==typeof this.value),i("limel-date-picker",{key:"a4b3c97cf7d9261e6d9e97faeec5be9eae4cacf0",disabled:this.disabled,readonly:this.readonly,invalid:this.invalid,label:this.label,placeholder:this.placeholder,helperText:this.helperText,required:this.required,value:this.parseDateValue(),type:this.type,language:this.language,formatter:this.formatter,onChange:this.handleChange})}parseDateValue(){const t=this.value;if(t)return this.dateTimeFormatter.parse(t,a[this.type]||this.type)}get dateTimeFormatter(){return this.platform.get(s.DateTimeFormatter)}getAppLanguage(){const t=this.platform.get(s.Translate),e=this.platform.get(s.Application);let i;var h;return i="function"==typeof(null==(h=t)?void 0:h.getLanguage)?t.getLanguage():e.getLanguage(),n(i)?i:"en"}},a={datetime:"time",time:"timeofday"},r=new Set(["da","de","en","fi","fr","nb","no","nl","sv"]),n=t=>r.has(t);export{h as limebb_date_picker}
@@ -1 +1 @@
1
- import{r as e,c as t,h as r,H as i}from"./p-DYpn0EkA.js";import{b as o,n as s,L as l}from"./p-CqRNpSRV.js";import{L as a}from"./p-D3UYWGdn.js";import{g as n,s as c,b as h,u as d,c as u,d as p,e as m}from"./p-y_s8hZmV.js";import{g as b}from"./p-CQUZjrU4.js";const f=class{constructor(r){e(this,r),this.expressionChange=t(this,"expressionChange"),this.handlePropertyChange=e=>{e.stopPropagation(),this.expressionChange.emit(Object.assign(Object.assign({},this.expression),{key:e.detail}))},this.handleOperatorChange=e=>{e.stopPropagation();const t=e.detail.value,r=this.expression.op;let i=this.expression.exp;t!==s.IN||Array.isArray(i)?r===s.IN&&t!==s.IN&&Array.isArray(i)&&(i=i.length>0?i[0]:""):i=void 0!==i&&""!==i?[i]:[],this.expressionChange.emit({key:this.expression.key,op:t,exp:i})},this.handleValueChange=e=>{e.stopPropagation(),this.expressionChange.emit(Object.assign(Object.assign({},this.expression),{exp:e.detail}))}}componentDidLoad(){var e;null===(e=this.propertySelectorEl)||void 0===e||e.focus()}render(){return r(i,{key:"8b70eaef1906fd9eaa69c9e4d6c42937406d2fcc"},this.renderPropertySelector(),this.renderOperator(),this.renderValueInput())}renderPropertySelector(){return r("limebb-property-selector",{ref:e=>this.propertySelectorEl=e,class:"property",label:"Property",platform:this.platform,context:this.context,limetype:this.limetype,value:this.expression.key,required:!0,onChange:this.handlePropertyChange})}renderOperator(){const e=!!this.expression.op,t=a.map((e=>{var t,r;return{text:null!==(r=null===(t=this.translator)||void 0===t?void 0:t.get(e.label))&&void 0!==r?r:e.label,value:e.value,icon:e.icon?{name:e.icon}:void 0}})),i=t.find((e=>e.value===this.expression.op));return r("limel-select",{class:"operator",label:"Operator",value:i,options:t,disabled:!e&&!this.expression.key,onChange:this.handleOperatorChange})}renderValueInput(){return this.expression.op?r("limebb-lime-query-value-input",{class:"value",label:"Value",platform:this.platform,context:this.context,limetype:this.limetype,activeLimetype:this.activeLimetype,propertyPath:this.expression.key,operator:this.expression.op,value:this.expression.exp,onChange:this.handleValueChange}):null}get translator(){var e;return null===(e=this.platform)||void 0===e?void 0:e.get(o.Translate)}static get delegatesFocus(){return!0}};f.style=":host{display:grid;grid-template-columns:3fr 1fr;gap:0.5rem;padding:0.75rem;min-width:30rem;align-items:center}.value{grid-column:1/-1}";const g={AND:{color:"rgb(var(--contrast-900))",iconName:"dot_circle",text:"All of",secondaryText:"True when every condition is true"},OR:{color:"rgb(var(--color-sky-default))",iconName:"centre_point",text:"Any of",secondaryText:"True when at least one condition is true"},NOT_AND:{color:"rgb(var(--color-orange-default))",iconName:"dot_circle",text:"Not all of",secondaryText:"True when at least one condition is false"},NOT_OR:{color:"rgb(var(--color-red-default))",iconName:"centre_point",text:"None of",secondaryText:"True when every condition is false"}},v=["AND","OR","NOT_AND","NOT_OR"].map((e=>({text:g[e].text,secondaryText:g[e].secondaryText,value:e,icon:{name:g[e].iconName,color:g[e].color}}))),y=class{constructor(i){e(this,i),this.expressionChange=t(this,"expressionChange"),this.renderChildExpression=(e,t)=>r("li",{class:"row"},r("limebb-lime-query-filter-expression",{platform:this.platform,context:this.context,limetype:this.limetype,activeLimetype:this.activeLimetype,expression:e,onExpressionChange:this.handleChildExpressionChange(t)})),this.handleCombinatorChange=e=>{e.stopPropagation();const t=e.detail.value;t&&t!==n(this.expression)&&this.expressionChange.emit(c(this.expression,t))},this.handleDeleteGroup=()=>{this.expressionChange.emit()},this.handleAddChildExpression=()=>{const e=u(this.expression),t=h(e,m());this.expressionChange.emit(this.wrap(t))},this.handleAddChildGroup=()=>{const e=u(this.expression),t=p(e.op),r=h(e,t);this.expressionChange.emit(this.wrap(r))},this.handleChildExpressionChange=e=>t=>{t.stopPropagation();const r=u(this.expression),i=d(r,e,t.detail);this.expressionChange.emit("removed"!==i.type?this.isNegated?{op:s.NOT,exp:i.expression}:i.expression:void 0)}}render(){const e=n(this.expression),t=u(this.expression),o=v.find((t=>t.value===e));return r(i,{key:"c9ca20c6b893416088807266fede19e5a24e360d","data-op":e,style:{"--limebb-query-filter-group-color-code":g[e].color}},r("div",{key:"8efe9e6e4d1ba552b8a761ec23b18668a1aef7f3",class:"group"},r("div",{key:"e99bb85a9532431a63ce0916dc4882a2f73d2307",class:"group-header"},r("limel-select",{key:"981fd5c1d4755ef937451144245640228ed515a9",class:"combinator",label:"Match",value:o,options:v,onChange:this.handleCombinatorChange}),r("limel-icon-button",{key:"caa427e897501a12a98a370c4d2364564904c042",class:"delete-group",icon:"trash",label:"Delete this group",onClick:this.handleDeleteGroup})),r("ul",{key:"8a21efdd1d783b11bb00f39c3579eec7277a505e",class:"rows"},t.exp.map(this.renderChildExpression),r("limel-chip",{key:"b4612f1899060f2f553283cc7afac53777b0c1ef",role:"listitem",class:"add-condition",text:"Condition",icon:{name:"plus_math",title:"Add"},onClick:this.handleAddChildExpression})),r("limel-chip",{key:"7046abfe1929fa13f4de3e90285610280467fd76",class:"add-group",size:"small",text:"Group",icon:{name:"plus_math",title:"Add",color:"var(--group-rail-color)"},onClick:this.handleAddChildGroup})))}get isNegated(){return this.expression.op===s.NOT}wrap(e){return this.isNegated?{op:s.NOT,exp:e}:e}};y.style='*,*:before,*::after{box-sizing:border-box}:host(limebb-lime-query-filter-group){--group-rail-color:var(--limebb-query-filter-group-color-code);display:flex;flex-direction:column;gap:1.5rem}:host([data-op=AND]){--combinator-symbol:"&"}:host([data-op=NOT_AND]){--combinator-symbol:"- &"}:host([data-op=OR]){--combinator-symbol:"or"}:host([data-op=NOT_OR]){--combinator-symbol:"- or"}.group{position:relative;display:flex;flex-direction:column;gap:1rem;padding:0.5rem;border-radius:0.75rem;background-color:rgb(var(--contrast-800), 0.15);transition:box-shadow 120ms ease}.group:before{content:"";position:absolute;top:1rem;bottom:calc(1rem + 1.75rem);left:0;width:0.125rem;transform:translateX(-50%);border-radius:1rem;background-color:var(--group-rail-color)}.group:has(limel-icon-button.delete-group:hover),.group:has(limel-icon-button.delete-group:focus-within){box-shadow:var(--shadow-error-state)}.group-header{display:flex;align-items:center;gap:0.5rem}limel-select.combinator{min-width:9rem}limel-icon-button.delete-group{margin-left:auto;opacity:0;transition:opacity 120ms ease}limel-chip.add-group{--lime-elevated-surface-background-color:transparent;--button-shadow-normal:none;isolation:isolate;position:relative;margin-right:auto}limel-chip.add-group:after{content:"";position:absolute;width:0.5rem;height:1.75rem;top:0;left:calc(0.5rem * -1 - 0.125rem / 2);border-width:0 0 0.125rem 0.125rem;border-color:var(--group-rail-color);border-style:solid;border-radius:0 0 0 0.5rem;transform:translateY(calc(-50% - 0.125rem / 2))}.group:hover>.group-header>limel-icon-button.delete-group,limel-icon-button.delete-group:focus-within{opacity:1}ul.rows{list-style:none;margin:0;display:flex;flex-direction:row;flex-wrap:wrap;align-items:center;column-gap:0.5rem;row-gap:0.5rem;padding:0 0.5rem 0.5rem 0.5rem}li.row{list-style:none;position:relative}li.row:has(>limebb-lime-query-filter-expression>limebb-lime-query-filter-group){flex-basis:100%;align-self:stretch}li.row+li.row:before{content:var(--combinator-symbol);color:var(--limebb-query-filter-group-color-code);font-size:0.75rem;font-weight:600}li.row+li.row:has(>limebb-lime-query-filter-expression>limebb-lime-query-filter-group):before{position:absolute;left:0;top:0;transform:translate(-50%, -50%)}li.row+li.row:not(:has(>limebb-lime-query-filter-expression>limebb-lime-query-filter-group)):before{margin-right:0.5rem}';const x=class{constructor(r){e(this,r),this.expressionChange=t(this,"expressionChange"),this.handleExpressionChange=e=>{var t;e.stopPropagation();const r=null!==(t=e.detail)&&void 0!==t?t:void 0;this.expressionChange.emit(void 0!==r?{op:s.NOT,exp:r}:void 0)}}render(){return r("div",{key:"30b9f2fbe27c8277633ef02fbebbafb227387ed8",class:"expression"},this.label&&r("limel-header",{key:"05b193ac0ec191b1f9394ed48691c24e534ba66c",heading:this.label}),r("limebb-lime-query-filter-expression",{key:"83b6a42631b886735502a8ec6454f5e9c868cc4c",platform:this.platform,context:this.context,label:"Not",limetype:this.limetype,activeLimetype:this.activeLimetype,expression:this.expression.exp,onExpressionChange:this.handleExpressionChange}))}};x.style='@charset "UTF-8";.expression{display:flex;flex-direction:column;margin-bottom:1rem;gap:1rem;padding:1rem;border-left:0.25rem solid rgb(var(--contrast-400));background-color:rgb(var(--contrast-100))}';const w={timestamp:"time",createdtime:"time",updatedtime:"time",id:"integer",createduser:"integer",updateduser:"integer",descriptive:"string"},k={date:"date",time:"datetime",timeofday:"time",month:"month",quarter:"quarter",year:"year"};const _=class{constructor(r){e(this,r),this.change=t(this,"change"),this.label="Value",this.inputMode="value",this.handleTextChange=e=>{e.stopPropagation();const t=e.detail,r=Number(t);Number.isNaN(r)||""===t?this.change.emit(t):this.change.emit(r)},this.handleSelectChange=e=>{e.stopPropagation();const t=e.detail;Array.isArray(t)?this.change.emit(t.map((e=>e.value))):this.change.emit(null==t?void 0:t.value)},this.handleBooleanChange=e=>{e.stopPropagation();const t=e.detail;Array.isArray(t)||this.change.emit("true"===(null==t?void 0:t.value))},this.handleDateChange=e=>{e.stopPropagation();const t=e.detail;this.change.emit(t?t.toISOString():null)},this.handleMultiValueChange=e=>{e.stopPropagation();const t=e.detail.split(",").map((e=>e.trim())).filter((e=>e.length>0));this.change.emit(t)},this.handleModeToggle=()=>{"value"===this.inputMode?(this.inputMode="placeholder",this.change.emit("%activeObject%")):(this.inputMode="value",this.change.emit(""))},this.handlePlaceholderPropertyChange=e=>{e.stopPropagation();const t=this.buildPlaceholderValue(e.detail);this.change.emit(t)}}componentWillLoad(){this.isPlaceholder(this.value)&&(this.inputMode="placeholder")}componentWillUpdate(){this.isPlaceholder(this.value)&&"placeholder"!==this.inputMode?this.inputMode="placeholder":this.isPlaceholder(this.value)||"placeholder"!==this.inputMode||(this.inputMode="value")}isPlaceholder(e){return"string"==typeof e&&e.startsWith("%activeObject%")}parsePlaceholderPath(e){return this.isPlaceholder(e)?e.replace(/^%activeObject%\.?/,""):""}buildPlaceholderValue(e){return e?`%activeObject%.${e}`:"%activeObject%"}render(){return this.operator?r(i,null,this.renderModeToggle(),this.renderInputByMode()):null}renderInputByMode(){return"placeholder"===this.inputMode?this.renderPlaceholderInput():this.renderValueInputByType()}renderModeToggle(){if(!this.activeLimetype)return null;const e="placeholder"===this.inputMode;return r("limel-icon-button",{class:"mode-toggle",icon:e?"text":"link",label:e?"Use Value":"Use Placeholder",onClick:this.handleModeToggle})}renderPlaceholderInput(){const e=this.parsePlaceholderPath(this.value);return r("div",{class:"placeholder-input"},r("limebb-property-selector",{platform:this.platform,context:this.context,limetype:this.activeLimetype,label:"Active Object Property",value:e,required:!1,helperText:"Select property from the active object",onChange:this.handlePlaceholderPropertyChange}),this.renderPlaceholderPreview())}renderPlaceholderPreview(){if(this.isPlaceholder(this.value))return r("div",{class:"placeholder-preview"},r("limel-icon",{name:"info",size:"small"}),r("span",null,"Placeholder: ",this.value))}renderValueInputByType(){if(this.operator===s.IN)return this.renderMultiValueInput();const e=this.getProperty();if(!e)return this.renderTextInput();const t=function(e){return"system"===e.type?function(e){const t=e.replace(/^_/,"");return w[t]||"string"}(e.name):e.type}(e);switch(t){case"integer":case"decimal":return this.renderNumberInput(t);case"yesno":return this.renderBooleanInput();case"option":return this.renderOptionInput(e);case"date":case"time":case"timeofday":case"year":case"month":case"quarter":return this.renderDateTimeInput(t);default:return this.renderTextInput()}}renderTextInput(){var e;return r("limel-input-field",{label:this.label,value:(null===(e=this.value)||void 0===e?void 0:e.toString())||"",placeholder:"Enter value",onChange:this.handleTextChange})}renderNumberInput(e){var t;const i="integer"===e?1:.01;return r("limel-input-field",{label:this.label,type:"number",value:(null===(t=this.value)||void 0===t?void 0:t.toString())||"",step:i,onChange:this.handleTextChange})}renderBooleanInput(){const e=[{text:"True",value:"true"},{text:"False",value:"false"}],t=!0===this.value||"true"===this.value?"true":"false",i=e.find((e=>e.value===t));return r("limel-select",{label:this.label,options:e,value:i,onChange:this.handleBooleanChange})}renderOptionInput(e){if(!e.options||0===e.options.length)return this.renderTextInput();const t=e.options.map((e=>({text:e.text||e.key,value:e.key}))),i=t.find((e=>e.value===this.value));return r("limel-select",{label:this.label,options:t,value:i,onChange:this.handleSelectChange})}renderDateTimeInput(e){const t="string"==typeof this.value?new Date(this.value):this.value;return r("limel-date-picker",{label:this.label,value:t,type:k[e]||"date",onChange:this.handleDateChange})}renderMultiValueInput(){const e=Array.isArray(this.value)?this.value.join(", "):this.value||"";return r("limel-input-field",{label:this.label+" (comma-separated)",value:e,placeholder:"e.g., won, lost, tender",onChange:this.handleMultiValueChange})}getProperty(){if(this.limetypes&&this.limetype&&this.propertyPath)return b(this.limetypes,this.limetype,this.propertyPath)}};(function(e,t,r,i){var o,s=arguments.length,l=s<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,r):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)l=Reflect.decorate(e,t,r,i);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(l=(s<3?o(l):s>3?o(t,r,l):o(t,r))||l);s>3&&l&&Object.defineProperty(t,r,l)})([l()],_.prototype,"limetypes",void 0),_.style=":host{display:flex;gap:0.5rem}:host>*{flex-grow:1}*{box-sizing:border-box}.value-input-container{display:flex;flex-direction:row;align-items:flex-start;gap:0.5rem;width:100%}.mode-toggle{flex-shrink:0;flex-grow:0}.placeholder-input{flex-grow:1;display:flex;flex-direction:column;gap:0.5rem}.placeholder-preview{display:flex;align-items:center;gap:0.5rem;padding:0.5rem;background-color:rgba(var(--color-blue-light), 0.1);border-radius:var(--border-radius-small);font-size:0.875rem;color:rgb(var(--color-blue-default));border-left:3px solid rgb(var(--color-blue-default))}.placeholder-preview limel-icon{flex-shrink:0;color:rgb(var(--color-blue-default))}.placeholder-preview span{font-family:var(--font-monospace);word-break:break-all}";export{f as limebb_lime_query_filter_comparison_editor,y as limebb_lime_query_filter_group,x as limebb_lime_query_filter_not,_ as limebb_lime_query_value_input}
1
+ import{r as e,c as t,h as r,H as i}from"./p-DYpn0EkA.js";import{b as o,n as s,L as l}from"./p-BVxuJgRM.js";import{L as a}from"./p-BneXZK-Q.js";import{g as n,s as c,b as h,u as d,c as u,d as p,e as m}from"./p-DjwVpKf5.js";import{g as b}from"./p-CQUZjrU4.js";const f=class{constructor(r){e(this,r),this.expressionChange=t(this,"expressionChange"),this.handlePropertyChange=e=>{e.stopPropagation(),this.expressionChange.emit(Object.assign(Object.assign({},this.expression),{key:e.detail}))},this.handleOperatorChange=e=>{e.stopPropagation();const t=e.detail.value,r=this.expression.op;let i=this.expression.exp;t!==s.IN||Array.isArray(i)?r===s.IN&&t!==s.IN&&Array.isArray(i)&&(i=i.length>0?i[0]:""):i=void 0!==i&&""!==i?[i]:[],this.expressionChange.emit({key:this.expression.key,op:t,exp:i})},this.handleValueChange=e=>{e.stopPropagation(),this.expressionChange.emit(Object.assign(Object.assign({},this.expression),{exp:e.detail}))}}componentDidLoad(){var e;null===(e=this.propertySelectorEl)||void 0===e||e.focus()}render(){return r(i,{key:"06e1cb22b9e472cbe185e06b21666adb0a11344b"},this.renderPropertySelector(),this.renderOperator(),this.renderValueInput())}renderPropertySelector(){return r("limebb-property-selector",{ref:e=>this.propertySelectorEl=e,class:"property",label:"Property",platform:this.platform,context:this.context,limetype:this.limetype,value:this.expression.key,required:!0,onChange:this.handlePropertyChange})}renderOperator(){const e=!!this.expression.op,t=a.map((e=>{var t,r;return{text:null!==(r=null===(t=this.translator)||void 0===t?void 0:t.get(e.label))&&void 0!==r?r:e.label,value:e.value,icon:e.icon?{name:e.icon}:void 0}})),i=t.find((e=>e.value===this.expression.op));return r("limel-select",{class:"operator",label:"Operator",value:i,options:t,disabled:!e&&!this.expression.key,onChange:this.handleOperatorChange})}renderValueInput(){return this.expression.op?r("limebb-lime-query-value-input",{class:"value",label:"Value",platform:this.platform,context:this.context,limetype:this.limetype,activeLimetype:this.activeLimetype,propertyPath:this.expression.key,operator:this.expression.op,value:this.expression.exp,onChange:this.handleValueChange}):null}get translator(){var e;return null===(e=this.platform)||void 0===e?void 0:e.get(o.Translate)}static get delegatesFocus(){return!0}};f.style=":host{display:grid;grid-template-columns:3fr 1fr;gap:0.5rem;padding:0.75rem;min-width:30rem;align-items:center}.value{grid-column:1/-1}";const g={AND:{color:"rgb(var(--contrast-900))",iconName:"dot_circle",text:"All of",secondaryText:"True when every condition is true"},OR:{color:"rgb(var(--color-sky-default))",iconName:"centre_point",text:"Any of",secondaryText:"True when at least one condition is true"},NOT_AND:{color:"rgb(var(--color-orange-default))",iconName:"dot_circle",text:"Not all of",secondaryText:"True when at least one condition is false"},NOT_OR:{color:"rgb(var(--color-red-default))",iconName:"centre_point",text:"None of",secondaryText:"True when every condition is false"}},v=["AND","OR","NOT_AND","NOT_OR"].map((e=>({text:g[e].text,secondaryText:g[e].secondaryText,value:e,icon:{name:g[e].iconName,color:g[e].color}}))),y=class{constructor(i){e(this,i),this.expressionChange=t(this,"expressionChange"),this.renderChildExpression=(e,t)=>r("li",{class:"row"},r("limebb-lime-query-filter-expression",{platform:this.platform,context:this.context,limetype:this.limetype,activeLimetype:this.activeLimetype,expression:e,onExpressionChange:this.handleChildExpressionChange(t)})),this.handleCombinatorChange=e=>{e.stopPropagation();const t=e.detail.value;t&&t!==n(this.expression)&&this.expressionChange.emit(c(this.expression,t))},this.handleDeleteGroup=()=>{this.expressionChange.emit()},this.handleAddChildExpression=()=>{const e=u(this.expression),t=h(e,m());this.expressionChange.emit(this.wrap(t))},this.handleAddChildGroup=()=>{const e=u(this.expression),t=p(e.op),r=h(e,t);this.expressionChange.emit(this.wrap(r))},this.handleChildExpressionChange=e=>t=>{t.stopPropagation();const r=u(this.expression),i=d(r,e,t.detail);this.expressionChange.emit("removed"!==i.type?this.isNegated?{op:s.NOT,exp:i.expression}:i.expression:void 0)}}render(){const e=n(this.expression),t=u(this.expression),o=v.find((t=>t.value===e));return r(i,{key:"66a01a54f224e00445831f10966cc0c90ff10061","data-op":e,style:{"--limebb-query-filter-group-color-code":g[e].color}},r("div",{key:"24fe86628ceb5b67ed1b3946483030c758145041",class:"group"},r("div",{key:"6c0fc9ea1a2acc6db6a5b91de10ddf4e279d646b",class:"group-header"},r("limel-select",{key:"443a8f9eb2d41371563a0305aebee4b0e2266795",class:"combinator",label:"Match",value:o,options:v,onChange:this.handleCombinatorChange}),r("limel-icon-button",{key:"50bc34b2b3328d6ad6056315700b098be4307d90",class:"delete-group",icon:"trash",label:"Delete this group",onClick:this.handleDeleteGroup})),r("ul",{key:"b535dc3de80947d1d9a88f38f0df7c87b53ba4f6",class:"rows"},t.exp.map(this.renderChildExpression),r("limel-chip",{key:"e30331e86df3af825828cce2a743ea54540cdc8c",role:"listitem",class:"add-condition",text:"Condition",icon:{name:"plus_math",title:"Add"},onClick:this.handleAddChildExpression})),r("limel-chip",{key:"f669006fa958fd141db149b1ff6e5d9f2655d853",class:"add-group",size:"small",text:"Group",icon:{name:"plus_math",title:"Add",color:"var(--group-rail-color)"},onClick:this.handleAddChildGroup})))}get isNegated(){return this.expression.op===s.NOT}wrap(e){return this.isNegated?{op:s.NOT,exp:e}:e}};y.style='*,*:before,*::after{box-sizing:border-box}:host(limebb-lime-query-filter-group){--group-rail-color:var(--limebb-query-filter-group-color-code);display:flex;flex-direction:column;gap:1.5rem}:host([data-op=AND]){--combinator-symbol:"&"}:host([data-op=NOT_AND]){--combinator-symbol:"- &"}:host([data-op=OR]){--combinator-symbol:"or"}:host([data-op=NOT_OR]){--combinator-symbol:"- or"}.group{position:relative;display:flex;flex-direction:column;gap:1rem;padding:0.5rem;border-radius:0.75rem;background-color:rgb(var(--contrast-800), 0.15);transition:box-shadow 120ms ease}.group:before{content:"";position:absolute;top:1rem;bottom:calc(1rem + 1.75rem);left:0;width:0.125rem;transform:translateX(-50%);border-radius:1rem;background-color:var(--group-rail-color)}.group:has(limel-icon-button.delete-group:hover),.group:has(limel-icon-button.delete-group:focus-within){box-shadow:var(--shadow-error-state)}.group-header{display:flex;align-items:center;gap:0.5rem}limel-select.combinator{min-width:9rem}limel-icon-button.delete-group{margin-left:auto;opacity:0;transition:opacity 120ms ease}limel-chip.add-group{--lime-elevated-surface-background-color:transparent;--button-shadow-normal:none;isolation:isolate;position:relative;margin-right:auto}limel-chip.add-group:after{content:"";position:absolute;width:0.5rem;height:1.75rem;top:0;left:calc(0.5rem * -1 - 0.125rem / 2);border-width:0 0 0.125rem 0.125rem;border-color:var(--group-rail-color);border-style:solid;border-radius:0 0 0 0.5rem;transform:translateY(calc(-50% - 0.125rem / 2))}.group:hover>.group-header>limel-icon-button.delete-group,limel-icon-button.delete-group:focus-within{opacity:1}ul.rows{list-style:none;margin:0;display:flex;flex-direction:row;flex-wrap:wrap;align-items:center;column-gap:0.5rem;row-gap:0.5rem;padding:0 0.5rem 0.5rem 0.5rem}li.row{list-style:none;position:relative}li.row:has(>limebb-lime-query-filter-expression>limebb-lime-query-filter-group){flex-basis:100%;align-self:stretch}li.row+li.row:before{content:var(--combinator-symbol);color:var(--limebb-query-filter-group-color-code);font-size:0.75rem;font-weight:600}li.row+li.row:has(>limebb-lime-query-filter-expression>limebb-lime-query-filter-group):before{position:absolute;left:0;top:0;transform:translate(-50%, -50%)}li.row+li.row:not(:has(>limebb-lime-query-filter-expression>limebb-lime-query-filter-group)):before{margin-right:0.5rem}';const x=class{constructor(r){e(this,r),this.expressionChange=t(this,"expressionChange"),this.handleExpressionChange=e=>{var t;e.stopPropagation();const r=null!==(t=e.detail)&&void 0!==t?t:void 0;this.expressionChange.emit(void 0!==r?{op:s.NOT,exp:r}:void 0)}}render(){return r("div",{key:"0058f05ff88585bbdc15b2781316e17fcebe49af",class:"expression"},this.label&&r("limel-header",{key:"02abf5fa55add75c1341f1a4b0699f1c5a8658ad",heading:this.label}),r("limebb-lime-query-filter-expression",{key:"1ef393bb9c3a5dc20f3775c8796b0e898efbd7f2",platform:this.platform,context:this.context,label:"Not",limetype:this.limetype,activeLimetype:this.activeLimetype,expression:this.expression.exp,onExpressionChange:this.handleExpressionChange}))}};x.style='@charset "UTF-8";.expression{display:flex;flex-direction:column;margin-bottom:1rem;gap:1rem;padding:1rem;border-left:0.25rem solid rgb(var(--contrast-400));background-color:rgb(var(--contrast-100))}';const w={timestamp:"time",createdtime:"time",updatedtime:"time",id:"integer",createduser:"integer",updateduser:"integer",descriptive:"string"},k={date:"date",time:"datetime",timeofday:"time",month:"month",quarter:"quarter",year:"year"};const _=class{constructor(r){e(this,r),this.change=t(this,"change"),this.label="Value",this.inputMode="value",this.handleTextChange=e=>{e.stopPropagation();const t=e.detail,r=Number(t);Number.isNaN(r)||""===t?this.change.emit(t):this.change.emit(r)},this.handleSelectChange=e=>{e.stopPropagation();const t=e.detail;Array.isArray(t)?this.change.emit(t.map((e=>e.value))):this.change.emit(null==t?void 0:t.value)},this.handleBooleanChange=e=>{e.stopPropagation();const t=e.detail;Array.isArray(t)||this.change.emit("true"===(null==t?void 0:t.value))},this.handleDateChange=e=>{e.stopPropagation();const t=e.detail;this.change.emit(t?t.toISOString():null)},this.handleMultiValueChange=e=>{e.stopPropagation();const t=e.detail.split(",").map((e=>e.trim())).filter((e=>e.length>0));this.change.emit(t)},this.handleModeToggle=()=>{"value"===this.inputMode?(this.inputMode="placeholder",this.change.emit("%activeObject%")):(this.inputMode="value",this.change.emit(""))},this.handlePlaceholderPropertyChange=e=>{e.stopPropagation();const t=this.buildPlaceholderValue(e.detail);this.change.emit(t)}}componentWillLoad(){this.isPlaceholder(this.value)&&(this.inputMode="placeholder")}componentWillUpdate(){this.isPlaceholder(this.value)&&"placeholder"!==this.inputMode?this.inputMode="placeholder":this.isPlaceholder(this.value)||"placeholder"!==this.inputMode||(this.inputMode="value")}isPlaceholder(e){return"string"==typeof e&&e.startsWith("%activeObject%")}parsePlaceholderPath(e){return this.isPlaceholder(e)?e.replace(/^%activeObject%\.?/,""):""}buildPlaceholderValue(e){return e?`%activeObject%.${e}`:"%activeObject%"}render(){return this.operator?r(i,null,this.renderModeToggle(),this.renderInputByMode()):null}renderInputByMode(){return"placeholder"===this.inputMode?this.renderPlaceholderInput():this.renderValueInputByType()}renderModeToggle(){if(!this.activeLimetype)return null;const e="placeholder"===this.inputMode;return r("limel-icon-button",{class:"mode-toggle",icon:e?"text":"link",label:e?"Use Value":"Use Placeholder",onClick:this.handleModeToggle})}renderPlaceholderInput(){const e=this.parsePlaceholderPath(this.value);return r("div",{class:"placeholder-input"},r("limebb-property-selector",{platform:this.platform,context:this.context,limetype:this.activeLimetype,label:"Active Object Property",value:e,required:!1,helperText:"Select property from the active object",onChange:this.handlePlaceholderPropertyChange}),this.renderPlaceholderPreview())}renderPlaceholderPreview(){if(this.isPlaceholder(this.value))return r("div",{class:"placeholder-preview"},r("limel-icon",{name:"info",size:"small"}),r("span",null,"Placeholder: ",this.value))}renderValueInputByType(){if(this.operator===s.IN)return this.renderMultiValueInput();const e=this.getProperty();if(!e)return this.renderTextInput();const t=function(e){return"system"===e.type?function(e){const t=e.replace(/^_/,"");return w[t]||"string"}(e.name):e.type}(e);switch(t){case"integer":case"decimal":return this.renderNumberInput(t);case"yesno":return this.renderBooleanInput();case"option":return this.renderOptionInput(e);case"date":case"time":case"timeofday":case"year":case"month":case"quarter":return this.renderDateTimeInput(t);default:return this.renderTextInput()}}renderTextInput(){var e;return r("limel-input-field",{label:this.label,value:(null===(e=this.value)||void 0===e?void 0:e.toString())||"",placeholder:"Enter value",onChange:this.handleTextChange})}renderNumberInput(e){var t;const i="integer"===e?1:.01;return r("limel-input-field",{label:this.label,type:"number",value:(null===(t=this.value)||void 0===t?void 0:t.toString())||"",step:i,onChange:this.handleTextChange})}renderBooleanInput(){const e=[{text:"True",value:"true"},{text:"False",value:"false"}],t=!0===this.value||"true"===this.value?"true":"false",i=e.find((e=>e.value===t));return r("limel-select",{label:this.label,options:e,value:i,onChange:this.handleBooleanChange})}renderOptionInput(e){if(!e.options||0===e.options.length)return this.renderTextInput();const t=e.options.map((e=>({text:e.text||e.key,value:e.key}))),i=t.find((e=>e.value===this.value));return r("limel-select",{label:this.label,options:t,value:i,onChange:this.handleSelectChange})}renderDateTimeInput(e){const t="string"==typeof this.value?new Date(this.value):this.value;return r("limel-date-picker",{label:this.label,value:t,type:k[e]||"date",onChange:this.handleDateChange})}renderMultiValueInput(){const e=Array.isArray(this.value)?this.value.join(", "):this.value||"";return r("limel-input-field",{label:this.label+" (comma-separated)",value:e,placeholder:"e.g., won, lost, tender",onChange:this.handleMultiValueChange})}getProperty(){if(this.limetypes&&this.limetype&&this.propertyPath)return b(this.limetypes,this.limetype,this.propertyPath)}};(function(e,t,r,i){var o,s=arguments.length,l=s<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,r):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)l=Reflect.decorate(e,t,r,i);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(l=(s<3?o(l):s>3?o(t,r,l):o(t,r))||l);s>3&&l&&Object.defineProperty(t,r,l)})([l()],_.prototype,"limetypes",void 0),_.style=":host{display:flex;gap:0.5rem}:host>*{flex-grow:1}*{box-sizing:border-box}.value-input-container{display:flex;flex-direction:row;align-items:flex-start;gap:0.5rem;width:100%}.mode-toggle{flex-shrink:0;flex-grow:0}.placeholder-input{flex-grow:1;display:flex;flex-direction:column;gap:0.5rem}.placeholder-preview{display:flex;align-items:center;gap:0.5rem;padding:0.5rem;background-color:rgba(var(--color-blue-light), 0.1);border-radius:var(--border-radius-small);font-size:0.875rem;color:rgb(var(--color-blue-default));border-left:3px solid rgb(var(--color-blue-default))}.placeholder-preview limel-icon{flex-shrink:0;color:rgb(var(--color-blue-default))}.placeholder-preview span{font-family:var(--font-monospace);word-break:break-all}";export{f as limebb_lime_query_filter_comparison_editor,y as limebb_lime_query_filter_group,x as limebb_lime_query_filter_not,_ as limebb_lime_query_value_input}
@@ -1 +1 @@
1
- import{r,c as o,h as e,H as a}from"./p-DYpn0EkA.js";import{g as l}from"./p-Bcm94u_z.js";import{g as t}from"./p-DtnPTzDv.js";const i="tear_off_calendar",s="email",g="internet",p="text_box",c="ms_excel_copyrighted",d="ms_word_copyrighted",m="ms_powerpoint_copyrighted",b="picture",n="camera",v="vector",h="presentation_filled",x="overview_pages_2",f="data_sheet",k="audio_wave",u="video_file",y="condom_package",w="database",_={msg:"ms_outlook_copyrighted",ics:i,ical:i,icalendar:i,ifb:i,email:s,eml:s,oft:s,ost:s,emlx:s,html:g,xml:g,txt:p,rtf:p,dot:d,doc:d,docx:d,dotx:d,docm:d,dotm:d,odt:x,pages:x,pdf:"PDF_2",ppt:m,pot:m,pps:m,pptx:m,pptm:m,potx:m,potm:m,ppam:m,ppsx:m,ppsm:m,sldx:m,sldm:m,odp:h,key:h,xls:c,xlsx:c,csv:f,numbers:f,jpg:n,jpeg:n,heic:n,bmp:b,png:b,gif:b,psd:"adobe_photoshop_copyrighted",ai:"adobe_illustrator_copyrighted",svg:v,svgz:v,ep:v,eps:v,sketch:v,mp3:k,wav:k,wma:k,ogg:k,avi:u,flv:u,h264:u,mov:u,mp4:u,mwv:u,zip:y,"7z":y,rar:y,json:"json",yaml:w,sql:w,db:w,dbf:w},j="rgb(var(--color-gray-dark))",z="rgb(var(--color-cyan-dark))",U="rgb(var(--color-gray-dark))",D="rgb(var(--color-blue-dark))",F="rgb(var(--color-yellow-darker))",C="rgb(var(--color-green-dark))",R="rgb(var(--color-coral-dark))",q="rgb(var(--color-sky-dark))",B="rgb(var(--color-lime-dark))",L="rgb(var(--color-magenta-dark))",M="rgb(var(--color-blue-dark))",P="rgb(var(--color-orange-dark))",A="rgb(var(--color-indigo-dark))",H="rgb(var(--color-red-dark))",O="rgb(var(--color-brown-default))",E="rgb(var(--color-glaucous-dark))",I=j,S={msg:"rgb(var(--color-yellow-dark))",ics:z,ical:z,icalendar:z,ifb:z,email:U,eml:U,oft:U,ost:U,emlx:U,html:D,xml:D,txt:F,rtf:F,dot:q,doc:q,docx:q,dotx:q,docm:q,dotm:q,odt:P,pages:P,pdf:"rgb(var(--color-red-dark))",ppt:R,pot:R,pps:R,pptx:R,pptm:R,potx:R,potm:R,ppam:R,ppsx:R,ppsm:R,sldx:R,sldm:R,odp:M,key:M,xls:C,xlsx:C,csv:j,numbers:"rgb(var(--color-green-dark))",bmp:B,jpg:B,jpeg:B,heic:B,png:B,gif:B,psd:M,ai:P,svg:L,svgz:L,ep:L,eps:L,sketch:L,mp3:A,wav:A,wma:A,ogg:A,flv:H,h264:H,mov:H,mp4:H,mwv:H,zip:O,"7z":O,rar:O,json:E,yaml:E,sql:E,db:E,dbf:E},T="rgba(var(--color-gray-lighter), 0.4)",W="rgba(var(--color-cyan-lighter), 0.4)",Y="rgba(var(--color-gray-lighter), 0.4)",G="rgba(var(--color-blue-lighter), 0.4)",J="rgba(var(--color-yellow-lighter), 0.4)",K="rgba(var(--color-green-lighter), 0.4)",N="rgba(var(--color-coral-lighter), 0.4)",Q="rgba(var(--color-sky-lighter), 0.4)",V="rgba(var(--color-lime-lighter), 0.4)",X="rgba(var(--color-magenta-lighter), 0.4)",Z="rgba(var(--color-blue-lighter), 0.4)",$="rgba(var(--color-orange-lighter), 0.4)",rr="rgba(var(--color-indigo-lighter), 0.4)",or="rgba(var(--color-red-lighter), 0.4)",er="rgba(var(--color-orange-lighter), 0.4)",ar="rgba(var(--color-glaucous-lighter), 0.4)",lr=T,tr={msg:"rgba(var(--color-yellow-lighter), 0.4)",ics:W,ical:W,icalendar:W,ifb:W,email:Y,eml:Y,oft:Y,ost:Y,emlx:Y,html:G,xml:G,txt:J,rtf:J,dot:Q,doc:Q,docx:Q,dotx:Q,docm:Q,dotm:Q,odt:$,pages:$,pdf:"rgba(var(--color-red-lighter), 0.4)",ppt:N,pot:N,pps:N,pptx:N,pptm:N,potx:N,potm:N,ppam:N,ppsx:N,ppsm:N,sldx:N,sldm:N,odp:Z,key:Z,xls:K,xlsx:K,csv:T,numbers:"rgba(var(--color-green-lighter), 0.4)",bmp:V,jpg:V,jpeg:V,heic:V,png:V,gif:V,psd:Z,ai:$,svg:X,svgz:X,ep:X,eps:X,sketch:X,mp3:rr,wav:rr,wma:rr,ogg:rr,flv:or,h264:or,mov:or,mp4:or,mwv:or,zip:er,"7z":er,rar:er,json:ar,yaml:ar,sql:ar,db:ar,dbf:ar},ir=class{constructor(e){r(this,e),this.removeFile=o(this,"removeFile"),this.files=[],this.blobUrls=new Map,this.handleRemove=r=>{r.stopPropagation();const o=r.detail;this.revokeBlobUrl(o),this.removeFile.emit(o)}}onFilesChanged(r,o){const e=new Set(r.map((r=>r.id)));for(const r of o)e.has(r.id)||this.revokeBlobUrl(r.id)}disconnectedCallback(){this.revokeAllBlobUrls()}render(){return e(a,{key:"a4cf5bdcef2b8dc9b206b333baa4ad13e5c11b3e",role:"list","aria-label":this.accessibleLabel},this.files.map((r=>this.renderFile(r))))}renderFile(r){const o=!r.uploadState||"done"===r.uploadState,a=this.getIcon(r),l=e("limel-chip",{role:o?void 0:"listitem",slot:o?"trigger":void 0,removable:!0,identifier:r.id,text:r.filename,icon:a,invalid:"failed"===r.uploadState,progress:"uploading"===r.uploadState?r.uploadProgress:void 0,loading:"added"===r.uploadState||"finalizing"===r.uploadState,onRemove:this.handleRemove});return o?e("limebb-summary-popover",{role:"listitem",file:Object.assign(Object.assign({},r),{href:this.getPreviewUrl(r)}),popoverMaxWidth:"32rem",popoverMaxHeight:"32rem",triggerDelay:1e3},l):l}getIcon(r){return r.icon?r.icon:function(r){const o=t(r);return{name:_[o]||"file",color:S[o]||I,backgroundColor:tr[o]||lr}}(r.filename)}getPreviewUrl(r){const o=t(r.filename);if("sharepoint"!==l(o))return r.href?r.href:r.fileContent?(this.blobUrls.has(r.id)||this.blobUrls.set(r.id,URL.createObjectURL(r.fileContent)),this.blobUrls.get(r.id)):void 0}revokeBlobUrl(r){const o=this.blobUrls.get(r);o&&(URL.revokeObjectURL(o),this.blobUrls.delete(r))}revokeAllBlobUrls(){for(const r of this.blobUrls.values())URL.revokeObjectURL(r);this.blobUrls.clear()}static get watchers(){return{files:[{onFilesChanged:0}]}}};ir.style=":host(limebb-document-chips){box-sizing:border-box;display:flex;flex-wrap:wrap;gap:0.25rem;width:100%}*{box-sizing:border-box;min-width:0}limebb-summary-popover{max-width:100%}limel-chip{max-width:18rem}";export{ir as limebb_document_chips}
1
+ import{r,c as o,h as e,H as a}from"./p-DYpn0EkA.js";import{g as l}from"./p-Bcm94u_z.js";import{g as t}from"./p-DtnPTzDv.js";const i="tear_off_calendar",s="email",g="internet",p="text_box",c="ms_excel_copyrighted",d="ms_word_copyrighted",m="ms_powerpoint_copyrighted",b="picture",n="camera",v="vector",h="presentation_filled",x="overview_pages_2",f="data_sheet",k="audio_wave",u="video_file",y="condom_package",w="database",_={msg:"ms_outlook_copyrighted",ics:i,ical:i,icalendar:i,ifb:i,email:s,eml:s,oft:s,ost:s,emlx:s,html:g,xml:g,txt:p,rtf:p,dot:d,doc:d,docx:d,dotx:d,docm:d,dotm:d,odt:x,pages:x,pdf:"PDF_2",ppt:m,pot:m,pps:m,pptx:m,pptm:m,potx:m,potm:m,ppam:m,ppsx:m,ppsm:m,sldx:m,sldm:m,odp:h,key:h,xls:c,xlsx:c,csv:f,numbers:f,jpg:n,jpeg:n,heic:n,bmp:b,png:b,gif:b,psd:"adobe_photoshop_copyrighted",ai:"adobe_illustrator_copyrighted",svg:v,svgz:v,ep:v,eps:v,sketch:v,mp3:k,wav:k,wma:k,ogg:k,avi:u,flv:u,h264:u,mov:u,mp4:u,mwv:u,zip:y,"7z":y,rar:y,json:"json",yaml:w,sql:w,db:w,dbf:w},j="rgb(var(--color-gray-dark))",z="rgb(var(--color-cyan-dark))",U="rgb(var(--color-gray-dark))",D="rgb(var(--color-blue-dark))",F="rgb(var(--color-yellow-darker))",C="rgb(var(--color-green-dark))",R="rgb(var(--color-coral-dark))",q="rgb(var(--color-sky-dark))",B="rgb(var(--color-lime-dark))",L="rgb(var(--color-magenta-dark))",M="rgb(var(--color-blue-dark))",P="rgb(var(--color-orange-dark))",A="rgb(var(--color-indigo-dark))",H="rgb(var(--color-red-dark))",O="rgb(var(--color-brown-default))",E="rgb(var(--color-glaucous-dark))",I=j,S={msg:"rgb(var(--color-yellow-dark))",ics:z,ical:z,icalendar:z,ifb:z,email:U,eml:U,oft:U,ost:U,emlx:U,html:D,xml:D,txt:F,rtf:F,dot:q,doc:q,docx:q,dotx:q,docm:q,dotm:q,odt:P,pages:P,pdf:"rgb(var(--color-red-dark))",ppt:R,pot:R,pps:R,pptx:R,pptm:R,potx:R,potm:R,ppam:R,ppsx:R,ppsm:R,sldx:R,sldm:R,odp:M,key:M,xls:C,xlsx:C,csv:j,numbers:"rgb(var(--color-green-dark))",bmp:B,jpg:B,jpeg:B,heic:B,png:B,gif:B,psd:M,ai:P,svg:L,svgz:L,ep:L,eps:L,sketch:L,mp3:A,wav:A,wma:A,ogg:A,flv:H,h264:H,mov:H,mp4:H,mwv:H,zip:O,"7z":O,rar:O,json:E,yaml:E,sql:E,db:E,dbf:E},T="rgba(var(--color-gray-lighter), 0.4)",W="rgba(var(--color-cyan-lighter), 0.4)",Y="rgba(var(--color-gray-lighter), 0.4)",G="rgba(var(--color-blue-lighter), 0.4)",J="rgba(var(--color-yellow-lighter), 0.4)",K="rgba(var(--color-green-lighter), 0.4)",N="rgba(var(--color-coral-lighter), 0.4)",Q="rgba(var(--color-sky-lighter), 0.4)",V="rgba(var(--color-lime-lighter), 0.4)",X="rgba(var(--color-magenta-lighter), 0.4)",Z="rgba(var(--color-blue-lighter), 0.4)",$="rgba(var(--color-orange-lighter), 0.4)",rr="rgba(var(--color-indigo-lighter), 0.4)",or="rgba(var(--color-red-lighter), 0.4)",er="rgba(var(--color-orange-lighter), 0.4)",ar="rgba(var(--color-glaucous-lighter), 0.4)",lr=T,tr={msg:"rgba(var(--color-yellow-lighter), 0.4)",ics:W,ical:W,icalendar:W,ifb:W,email:Y,eml:Y,oft:Y,ost:Y,emlx:Y,html:G,xml:G,txt:J,rtf:J,dot:Q,doc:Q,docx:Q,dotx:Q,docm:Q,dotm:Q,odt:$,pages:$,pdf:"rgba(var(--color-red-lighter), 0.4)",ppt:N,pot:N,pps:N,pptx:N,pptm:N,potx:N,potm:N,ppam:N,ppsx:N,ppsm:N,sldx:N,sldm:N,odp:Z,key:Z,xls:K,xlsx:K,csv:T,numbers:"rgba(var(--color-green-lighter), 0.4)",bmp:V,jpg:V,jpeg:V,heic:V,png:V,gif:V,psd:Z,ai:$,svg:X,svgz:X,ep:X,eps:X,sketch:X,mp3:rr,wav:rr,wma:rr,ogg:rr,flv:or,h264:or,mov:or,mp4:or,mwv:or,zip:er,"7z":er,rar:er,json:ar,yaml:ar,sql:ar,db:ar,dbf:ar},ir=class{constructor(e){r(this,e),this.removeFile=o(this,"removeFile"),this.files=[],this.blobUrls=new Map,this.handleRemove=r=>{r.stopPropagation();const o=r.detail;this.revokeBlobUrl(o),this.removeFile.emit(o)}}onFilesChanged(r,o){const e=new Set(r.map((r=>r.id)));for(const r of o)e.has(r.id)||this.revokeBlobUrl(r.id)}disconnectedCallback(){this.revokeAllBlobUrls()}render(){return e(a,{key:"3ed9e562b60216e670aff7f4553b5ac2c1728f37",role:"list","aria-label":this.accessibleLabel},this.files.map((r=>this.renderFile(r))))}renderFile(r){const o=!r.uploadState||"done"===r.uploadState,a=this.getIcon(r),l=e("limel-chip",{role:o?void 0:"listitem",slot:o?"trigger":void 0,removable:!0,identifier:r.id,text:r.filename,icon:a,invalid:"failed"===r.uploadState,progress:"uploading"===r.uploadState?r.uploadProgress:void 0,loading:"added"===r.uploadState||"finalizing"===r.uploadState,onRemove:this.handleRemove});return o?e("limebb-summary-popover",{role:"listitem",file:Object.assign(Object.assign({},r),{href:this.getPreviewUrl(r)}),popoverMaxWidth:"32rem",popoverMaxHeight:"32rem",triggerDelay:1e3},l):l}getIcon(r){return r.icon?r.icon:function(r){const o=t(r);return{name:_[o]||"file",color:S[o]||I,backgroundColor:tr[o]||lr}}(r.filename)}getPreviewUrl(r){const o=t(r.filename);if("sharepoint"!==l(o))return r.href?r.href:r.fileContent?(this.blobUrls.has(r.id)||this.blobUrls.set(r.id,URL.createObjectURL(r.fileContent)),this.blobUrls.get(r.id)):void 0}revokeBlobUrl(r){const o=this.blobUrls.get(r);o&&(URL.revokeObjectURL(o),this.blobUrls.delete(r))}revokeAllBlobUrls(){for(const r of this.blobUrls.values())URL.revokeObjectURL(r);this.blobUrls.clear()}static get watchers(){return{files:[{onFilesChanged:0}]}}};ir.style=":host(limebb-document-chips){box-sizing:border-box;display:flex;flex-wrap:wrap;gap:0.25rem;width:100%}*{box-sizing:border-box;min-width:0}limebb-summary-popover{max-width:100%}limel-chip{max-width:18rem}";export{ir as limebb_document_chips}
@@ -1 +1 @@
1
- import{r as e,h as t,H as i,g as o}from"./p-DYpn0EkA.js";import{b as r}from"./p-CqRNpSRV.js";const a=class{constructor(i){e(this,i),this.ui="standard",this.hasError=!1,this.isBundled=!1,this.headingCanExpand=!1,this.isHeadingExpanded=!1,this.showMore=!1,this.isTall=!1,this.collapsibleButtonId="a"+crypto.randomUUID(),this.setHeaderCollapsible=()=>{this.headingParagraphElement&&(this.headingCanExpand=this.isTextTruncated(this.headingParagraphElement))},this.bodyTextTall=e=>{if(!this.bodyTextElement||!(null==e?void 0:e.length))return;const t=e[0].contentRect.width;if(t===this.lastMeasuredWidth)return;this.lastMeasuredWidth=t,this.bodyTextElement.style.minHeight="0";const i=this.bodyTextElement.scrollHeight;this.bodyTextElement.style.removeProperty("min-height"),this.isTall=i>(this.isThreadMessage?48:160),void 0===this.bodyTextHeight&&(this.bodyTextHeight=i)},this.renderHeader=()=>{if((!this.isBundled||this.item.heading)&&(this.item.author||this.item.heading))return t("div",{class:"header"},this.renderAuthor(),this.renderHeading(),this.renderExpandCollapseHeadingButton())},this.renderRelations=()=>{var e,i,o;if(null===(i=null===(e=this.item)||void 0===e?void 0:e.relations)||void 0===i?void 0:i.length)return t("limel-chip-set",{value:null===(o=this.item)||void 0===o?void 0:o.relations})},this.renderExpandCollapseHeadingButton=()=>{var e,i;if(this.item.heading)return this.headingCanExpand&&!this.isHeadingExpanded?[t("button",{onClick:this.toggleHeadingExpansion,class:"expand-heading"},null===(e=this.translator)||void 0===e?void 0:e.get("webclient.more"))]:this.isHeadingExpanded?[t("button",{onClick:this.toggleHeadingExpansion,id:this.collapsibleButtonId,class:"collapse-heading"},t("limel-icon",{name:"angle_up"})),t("limel-tooltip",{elementId:this.collapsibleButtonId,label:null===(i=this.translator)||void 0===i?void 0:i.get("webclient.show-less"),openDirection:"top-end"})]:void 0},this.renderThumbnailCard=e=>{const{href:i,image:o,filename:r}=e;if(!o&&!r)return;const a="thumb-"+crypto.randomUUID();return[t("a",{class:"thumbnail-card-link",id:a,key:a,href:i||void 0},t("limel-card",{image:o,clickable:!!i},t("limebb-feed-item-thumbnail-file-info",{slot:"component",description:r})),this.showThumbnailTooltip(e,a))]},this.setBodyTextElement=e=>{this.bodyTextElement=e},this.toggleShowMore=()=>{this.showMore=!this.showMore,this.showMore||this.el.offsetHeight>=window.innerHeight&&this.el.scrollIntoView({behavior:"auto"})},this.toggleHeadingExpansion=()=>{this.isHeadingExpanded=!this.isHeadingExpanded},this.createMenuItem=e=>{var t,i;return"separator"in e?e:{value:e,text:null!==(t=e.label)&&void 0!==t?t:"",secondaryText:e.description,disabled:e.disabled,icon:null!==(i=e.icon)&&void 0!==i?i:""}},this.createActionBarItem=e=>{var t,i;if("separator"in e)return e;let o={value:e,text:null!==(t=e.label)&&void 0!==t?t:"",secondaryText:e.description,disabled:e.disabled};return!e.label&&e.icon?o=Object.assign(Object.assign({},o),{icon:e.icon,text:null!==(i=e.description)&&void 0!==i?i:o.text,iconOnly:!0}):e.icon&&(o=Object.assign(Object.assign({},o),{icon:e.icon})),o},this.handleMenuItemSelect=e=>{var t;e.stopPropagation();const i=null===(t=e.detail.value)||void 0===t?void 0:t.command;i&&this.commandbus.handle(i)},this.handleActionBarItemSelect=e=>{var t;e.stopPropagation();const i=null===(t=e.detail.value)||void 0===t?void 0:t.command;i&&this.commandbus.handle(i)}}componentDidLoad(){var e,t;const i=null===(e=this.el.shadowRoot)||void 0===e?void 0:e.querySelector(".heading");this.headingParagraphElement=null===(t=null==i?void 0:i.shadowRoot)||void 0===t?void 0:t.querySelector("p"),this.headingParagraphElement&&(this.headingResizeObserver=new ResizeObserver(this.setHeaderCollapsible),this.headingResizeObserver.observe(this.headingParagraphElement)),this.bodyTextElement&&(this.bodyResizeObserver=new ResizeObserver(this.bodyTextTall),this.bodyResizeObserver.observe(this.bodyTextElement))}disconnectedCallback(){var e;null===(e=this.bodyResizeObserver)||void 0===e||e.disconnect()}render(){var e,o;const r=`helper-text-${this.item.id}`;return t(i,{key:"2ad365b907d0da77fcd0ac20c268f1660390a078",id:this.item.id,class:{"has-unpromoted-actions":!!(null===(e=this.item.unpromotedActions)||void 0===e?void 0:e.length),"has-author-picture":!!(null===(o=this.item.author)||void 0===o?void 0:o.picture),"shows-less":!this.showMore,"expanded-heading":this.isHeadingExpanded,"shows-more":this.showMore,"is-tall":this.isTall},style:{"--body-text-height":`${this.bodyTextHeight}`,"--color-code":`${this.item.color}`},"aria-describedby":this.helperText?r:void 0,tabindex:"-1"},this.renderBadgeAndTimestamp(),this.renderContent(r))}renderBadgeAndTimestamp(){return t("div",{class:"left"},t("div",{class:"info"},this.renderAuthorPicture(),this.renderIcon(),t("span",{class:"timestamp"},this.renderTimestamp())))}renderIcon(){var e,i,o;if(!this.isBundled&&(this.item.icon||!(null===(e=this.item.author)||void 0===e?void 0:e.picture)))return t("limel-icon",{class:"icon",badge:!0,name:this.getIconName(),style:{color:`${null===(i=this.item.icon)||void 0===i?void 0:i.color}`,"background-color":`${null===(o=this.item.icon)||void 0===o?void 0:o.backgroundColor}`}})}getIconName(){const{ui:e,icon:t}=this.item;return"error-message"===e?"error":(null==t?void 0:t.name)||"dot_circle"}renderContent(e){return t("div",{class:"right"},t("div",{class:"content"},this.renderThreadEffects(),this.renderHeader(),this.renderUnpromotedActionsMenu(),this.renderValue(),this.renderThumbnails(),this.renderRelations(),this.renderHelperText(e)),this.renderPromotedActions())}renderThreadEffects(){if(this.isThreadMessage)return t("div",{class:"thread-effects",role:"presentation"})}renderHelperText(e){if(this.helperText)return t("span",{class:"helper-text",id:e},this.helperText)}renderAuthor(){if(this.item.author&&(!this.isBundled||this.item.heading)){if("string"==typeof this.item.author.name)return t("span",{class:"author"},this.item.author.name);if("object"==typeof this.item.author.name){const{href:e,title:i,text:o}=this.item.author.name;return t("a",{class:"author",href:e,title:i},o)}}}renderAuthorPicture(){var e;if(!(null===(e=this.item.author)||void 0===e?void 0:e.picture))return;if(this.isBundled)return;const{author:i}=this.item,o=this.getAuthorName(i),r=this.createLinkToAuthor(i);return t("limebb-summary-popover",{image:{src:this.item.author.picture,alt:`${o}`},heading:o,value:r},t("img",{slot:"trigger",loading:"lazy",src:this.item.author.picture}))}renderHeading(){if(this.item.heading)return[t("limel-markdown",{class:{heading:!0,"expanded-heading":this.isHeadingExpanded,"truncate-paragraphs":!this.isHeadingExpanded},value:this.item.heading,adaptColorContrast:!0})]}renderValue(){var e;if(this.item.value)return[t("div",{class:"markdown-container"},t("limel-markdown",{class:{"body-text":!0,opened:this.showMore,"no-table-styles":!(null===(e=this.item)||void 0===e?void 0:e.hasDefaultTableStyles),"reset-img-height":!0},value:this.item.value,lazyLoadImages:!0,ref:this.setBodyTextElement,adaptColorContrast:!0,whitelist:[{tagName:"limebb-mention",attributes:["limetype","objectid"]}]}),this.renderShowMoreButton())]}renderThumbnails(){var e;const i=null===(e=this.item)||void 0===e?void 0:e.thumbnails;if(null==i?void 0:i.length)return t("limel-masonry-layout",{role:"group"},i.map(this.renderThumbnailCard))}showThumbnailTooltip(e,i){var o;const{href:r,filename:a}=e;if(r)return t("limel-tooltip",{elementId:i,label:(null===(o=this.translator)||void 0===o?void 0:o.get("webclient.go-to-context-label",{context:a}))||a})}getAuthorName(e){return"string"==typeof e.name?e.name:e.name.text}createLinkToAuthor(e){if("object"!=typeof e.name)return;const{href:t,title:i,text:o}=e.name;return`<a class="author" href="${t}" title="${i}">${this.translator.get("webclient.actions.goto-object",{limetype:": <br><b>"+o+"</b>"})}</a>`}isTextTruncated(e){return e.offsetWidth<e.scrollWidth}renderShowMoreButton(){if(this.isTall)return[t("button",{id:"show-more-button",type:"button",onClick:this.toggleShowMore},t("limel-icon",{name:"angle_down"})),t("limel-tooltip",{label:this.toggleShowMoreLabel(),elementId:"show-more-button",openDirection:"top"})]}toggleShowMoreLabel(){var e,t;return this.showMore?null===(e=this.translator)||void 0===e?void 0:e.get("webclient.show-less"):null===(t=this.translator)||void 0===t?void 0:t.get("webclient.show-more")}renderUnpromotedActionsMenu(){var e,i;if(!(null===(e=this.item.unpromotedActions)||void 0===e?void 0:e.length))return;const o=this.item.unpromotedActions.map(this.createMenuItem);return t("limel-menu",{class:"unpromoted-actions-menu",items:o,openDirection:"bottom-end",onSelect:this.handleMenuItemSelect},t("limel-icon-button",{icon:"menu_2",slot:"trigger",label:null===(i=this.translator)||void 0===i?void 0:i.get("webclient.more-actions")}))}renderPromotedActions(){var e;if(!(null===(e=this.item.promotedActions)||void 0===e?void 0:e.length))return;const i=this.item.promotedActions.map(this.createActionBarItem);return t("div",{class:"action-bar"},t("div",{class:"action-bar-hider"},t("limel-action-bar",{accessibleLabel:"Action bar",actions:i,layout:"fullWidth",onItemSelected:this.handleActionBarItemSelect})))}renderTimestamp(){const e=this.item.timestamp;if(e)return this.dateTimeFormatter.format(e,"timeofday")}get dateTimeFormatter(){return this.platform.get(r.DateTimeFormatter)}get translator(){var e;return null===(e=this.platform)||void 0===e?void 0:e.get(r.Translate)}get commandbus(){var e;return null===(e=this.platform)||void 0===e?void 0:e.get(r.CommandBus)}get isThreadMessage(){return"thread-message"===this.ui}get el(){return o(this)}};a.style='@charset "UTF-8";limel-action-bar{--action-bar-item-height:1.75rem;transition:opacity 0.2s ease;justify-content:flex-start;opacity:0.8}.action-bar{display:grid;transition:grid-template-rows var(--limebb-promoted-action-bar-grid-template-rows-transition-speed, 0.2s) cubic-bezier(1, 0.09, 0, 0.89) var(--limebb-promoted-action-bar-grid-template-rows-transition-delay, 0s);grid-template-rows:var(--limebb-promoted-action-bar-grid-template-rows, 1fr)}.action-bar-hider{overflow:hidden}limel-action-bar{transition:padding var(--limebb-promoted-action-bar-grid-template-rows-transition-speed) cubic-bezier(1, 0.09, 0, 0.89) var(--limebb-promoted-action-bar-grid-template-rows-transition-delay);padding-top:0;padding-bottom:0.75rem}:host(limebb-feed-timeline-item:hover) .action-bar,:host(limebb-feed-timeline-item:focus-within) .action-bar,:host(limebb-feed-timeline-item:focus-visible) .action-bar{--limebb-promoted-action-bar-grid-template-rows:1fr;will-change:grid-template-rows}:host(limebb-feed-timeline-item:hover) limel-action-bar,:host(limebb-feed-timeline-item:focus-within) limel-action-bar,:host(limebb-feed-timeline-item:focus-visible) limel-action-bar{will-change:opacity;opacity:1}:host(limebb-feed-timeline-item:hover),:host(limebb-feed-timeline-item:focus-within){--limebb-promoted-action-bar-grid-template-rows-transition-speed:0.46s;--limebb-promoted-action-bar-grid-template-rows-transition-delay:0.7s}:host(limebb-feed-timeline-item.is-tall) .markdown-container{margin-bottom:0.5rem}:host(limebb-feed-timeline-item.is-tall) .body-text{--body-text-min-height-set-by-code:10rem;min-height:calc(var(--body-text-min-height-set-by-code) + 0.25rem)}:host(limebb-feed-timeline-item.is-tall) .body-text:after{transition:opacity 0.6s ease;content:"";opacity:0.26;pointer-events:none;position:absolute;bottom:-0.125rem;right:-0.125rem;left:-0.125rem;height:2.5rem;background:radial-gradient(farthest-side at 50% 100%, rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0)) 0 100%, linear-gradient(to bottom, rgb(var(--limebb-feed-item-background-color), 0) 0%, rgb(var(--limebb-feed-item-background-color), 90%) 100%);background-repeat:no-repeat;background-size:100% 0.5rem, 100% 100%}:host(limebb-feed-timeline-item.is-tall.shows-less) .markdown-container{grid-template-rows:0fr}:host(limebb-feed-timeline-item.is-tall.shows-less) .body-text:after{opacity:1}:host(limebb-feed-timeline-item.is-tall.shows-more) .markdown-container{grid-template-rows:1fr}:host(limebb-feed-timeline-item.is-tall.shows-more) #show-more-button limel-icon{rotate:180deg}.markdown-container{position:relative;display:grid}.markdown-container:not(.opened){transition:grid-template-rows min(var(--body-text-height) * 1.2ms, 500ms) cubic-bezier(1, 0.09, 0, 0.89)}.body-text{display:block;overflow:hidden}button#show-more-button{appearance:none;background:none;border:none;padding:0;margin:0;font:inherit;color:inherit;text-align:inherit;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:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-normal);z-index:1;position:absolute;right:0;bottom:-0.6rem;left:0;margin:0 auto;display:flex;align-items:center;justify-content:center;border-radius:3rem;width:2rem;height:1rem}button#show-more-button:hover,button#show-more-button:focus,button#show-more-button:focus-visible{will-change:color, background-color, box-shadow, transform}button#show-more-button:hover,button#show-more-button:focus-visible{transform:translate3d(0, -0.04rem, 0);color:var(--limel-theme-on-surface-color);background-color:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-hovered)}button#show-more-button:active{--limel-clickable-transform-timing-function:cubic-bezier( 0.83, -0.15, 0.49, 1.16 );transform:translate3d(0, 0.05rem, 0);box-shadow:var(--button-shadow-pressed)}button#show-more-button:hover,button#show-more-button:active{--limel-clickable-transition-speed:0.2s;--limel-clickable-transform-speed:0.16s}button#show-more-button:focus{outline:none}button#show-more-button:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}button#show-more-button limel-icon{transition:rotate 0.2s ease 0.5s;color:var(--mdc-theme-primary);width:0.75rem}:host(limebb-feed-timeline-item[ui=standard]) .content{background-color:rgb(var(--limebb-feed-item-background-color))}:host(limebb-feed-timeline-item[ui=emphasized]) .content{border:1px dashed rgb(var(--contrast-800))}:host(limebb-feed-timeline-item[ui=minimal]) limel-markdown{--markdown-hyperlink-color:rgb(var(--contrast-900))}:host(limebb-feed-timeline-item[ui=minimal]) limel-markdown:hover{--markdown-hyperlink-color:rgb(var(--color-blue-default))}:host(limebb-feed-timeline-item[ui=minimal]) a.author{color:rgb(var(--contrast-900))}:host(limebb-feed-timeline-item[ui=minimal]) .header:hover a.author{color:rgb(var(--color-blue-default))}:host(limebb-feed-timeline-item[ui=minimal]) .icon{color:rgb(var(--contrast-900)) !important}:host(limebb-feed-timeline-item[ui=minimal]) .body-text{color:rgb(var(--contrast-900))}:host(limebb-feed-timeline-item[ui=minimal]) .body-text:hover{color:rgb(var(--contrast-1100))}:host(limebb-feed-timeline-item[ui=thread-message]){padding:0.25rem 0}:host(limebb-feed-timeline-item[ui=thread-message]) .content{border-radius:0;box-shadow:var(--button-shadow-normal);margin-bottom:0.25rem;background-color:var(--lime-elevated-surface-background-color)}:host(limebb-feed-timeline-item[ui=thread-message]) .header{padding-bottom:0.75rem;margin-bottom:0.25rem}:host(limebb-feed-timeline-item[ui=thread-message]) .header:before{content:"";position:absolute;top:calc(var(--limebb-feed-item-paddings) * -1 + 0.25rem);left:calc(var(--limebb-feed-item-paddings) * -1);right:calc(var(--limebb-feed-item-paddings) * -1);bottom:0;pointer-events:none;border-bottom:1px dashed rgb(var(--contrast-600))}:host(limebb-feed-timeline-item[ui=thread-message]) .thread-effects{transition:transform 0.2s ease;pointer-events:none;content:"";position:absolute;z-index:-1;top:0;right:0;bottom:0;left:0;box-shadow:var(--button-shadow-normal);transform:translate3d(-0.225rem, -0.125rem, 0) rotate(0.5deg);background-color:rgb(var(--contrast-300))}:host(limebb-feed-timeline-item.is-tall[ui=thread-message]) .body-text{--body-text-min-height-set-by-code:3rem;min-height:calc(var(--body-text-min-height-set-by-code) + 0.25rem);max-height:35rem}:host(limebb-feed-timeline-item.is-tall[ui=thread-message].shows-more) .body-text{overflow-y:auto}:host(limebb-feed-timeline-item[ui=error-message]) .icon{color:rgb(var(--color-red-default))}:host(limebb-feed-timeline-item[ui=error-message]) .content{border:1px dashed rgb(var(--color-red-light));background-color:rgb(var(--color-red-lighter), 0.2)}.content{position:relative}.content:before,.content:after{content:"";position:absolute;top:1rem;bottom:1rem;left:-0.125rem;width:0.25rem;border-radius:0.25rem}.content:before{background-color:var(--color-code)}:host(limebb-feed-timeline-item[ui=emphasized]) .content:before,:host(limebb-feed-timeline-item[ui=emphasized]) .content:after{left:calc(-0.125rem - 0.5px)}:host(limebb-feed-timeline-item[ui=minimal]) .content:before{opacity:0.25}:host(limebb-feed-timeline-item[ui=minimal]) .content:after{opacity:0.5;background:repeating-linear-gradient(45deg, var(--color-code), var(--color-code) 0.5rem, transparent 0.5rem, transparent 1rem);background-size:0.25rem 100%;background-repeat:repeat-y;background-position:left;rotate:180deg}:host(limebb-feed-timeline-item[ui=thread-message]) .content:before{top:0.25rem;bottom:unset;height:1.75rem}*{box-sizing:border-box}:host(limebb-feed-timeline-item){--limebb-feed-item-paddings:0.75rem;display:flex;gap:0.75rem;position:relative;isolation:isolate;border-radius:0.5rem}:host(limebb-feed-timeline-item[is-bundled]:hover){--limebb-feed-item-timestamp-opacity-delay:0.5s}:host(limebb-feed-timeline-item[is-bundled]:hover) .timestamp{opacity:1}:host(limebb-feed-timeline-item[is-bundled]) .timestamp{opacity:0}:host(limebb-feed-timeline-item:hover),:host(limebb-feed-timeline-item:focus),:host(limebb-feed-timeline-item:focus-within){--limebb-feed-item-timeline-color:var(--mdc-theme-primary);--limebb-feed-item-timestamp-color:var(--mdc-theme-primary)}.left:before{transition:background-color 0.2s ease;content:"";position:absolute;z-index:-1;top:-0.25rem;bottom:-0.25rem;left:1rem;width:1px;border-radius:1rem;background-color:var(--limebb-feed-item-timeline-color, rgb(var(--contrast-600)))}.info{position:sticky;top:0.5rem;display:flex;flex-direction:column;align-items:center;gap:0.25rem}.right,.content{display:flex;flex-direction:column;flex-grow:1;min-width:0}.content{border-radius:1rem;gap:0.25rem;padding:var(--limebb-feed-item-paddings)}.header{position:relative;display:flex;gap:0.25rem;padding-bottom:0.25rem;margin-top:-0.25rem;color:rgb(var(--contrast-900));font-size:0.875rem}:host(.has-unpromoted-actions) .header{padding-right:2rem}.header limel-markdown{--markdown-hyperlink-color:var(--mdc-theme-primary);--markdown-hyperlink-color--hovered:rgb(var(--color-teal-light))}.heading{flex-grow:1;overflow:hidden;white-space:nowrap}.heading.expanded-heading{white-space:normal}button.expand-heading{appearance:none;background:none;border:none;padding:0;margin:0;font:inherit;color:inherit;text-align:inherit;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:rgb(var(--color-blue-default));background-color:transparent;border-radius:1rem;padding:0 0.25rem 0.25rem 0.25rem;height:1rem;white-space:nowrap}button.expand-heading:hover,button.expand-heading:focus,button.expand-heading:focus-visible{will-change:color, background-color, box-shadow, transform}button.expand-heading:hover,button.expand-heading:focus-visible{transform:translate3d(0, 0.01rem, 0);color:rgb(var(--color-blue-default));background-color:var(--lime-elevated-surface-background-color)}button.expand-heading:hover{box-shadow:var(--button-shadow-hovered)}button.expand-heading:active{--limel-clickable-transform-timing-function:cubic-bezier( 0.83, -0.15, 0.49, 1.16 );transform:translate3d(0, 0.05rem, 0);box-shadow:var(--button-shadow-pressed)}button.expand-heading:hover,button.expand-heading:active{--limel-clickable-transition-speed:0.2s;--limel-clickable-transform-speed:0.16s}button.collapse-heading{appearance:none;background:none;border:none;padding:0;margin:0;font:inherit;color:inherit;text-align:inherit;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:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-normal);flex-shrink:0;display:flex;align-items:center;justify-content:center;border-radius:1.5rem;width:1rem}button.collapse-heading:hover,button.collapse-heading:focus,button.collapse-heading:focus-visible{will-change:color, background-color, box-shadow, transform}button.collapse-heading:hover,button.collapse-heading:focus-visible{transform:translate3d(0, -0.04rem, 0);color:var(--limel-theme-on-surface-color);background-color:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-hovered)}button.collapse-heading:active{--limel-clickable-transform-timing-function:cubic-bezier( 0.83, -0.15, 0.49, 1.16 );transform:translate3d(0, 0.05rem, 0);box-shadow:var(--button-shadow-pressed)}button.collapse-heading:hover,button.collapse-heading:active{--limel-clickable-transition-speed:0.2s;--limel-clickable-transform-speed:0.16s}button.collapse-heading:focus{outline:none}button.collapse-heading:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}button.collapse-heading limel-icon{width:0.75rem}.unpromoted-actions-menu{position:absolute;top:0;right:0;z-index:1}.timestamp{transition:color 0.4s ease, opacity 0.2s ease;transition-delay:var(--limebb-feed-item-timestamp-opacity-delay, 0s);display:flex;flex-direction:column;align-items:center;gap:0.25rem;font-size:0.75rem;text-align:center;color:var(--limebb-feed-item-timestamp-color, rgb(var(--contrast-800)));background-color:var(--limebb-feed-background-color);padding:0.125rem 0;width:2rem;border-radius:1rem}.timestamp:after{width:0.5rem;height:0.5rem;border-radius:50%;background-color:rgb(var(--color-red-default))}:host(.is-new) .timestamp:after{content:""}.icon{--icon-background-color:var(--limebb-feed-background-color);width:2rem;padding:0.125rem}:host(.has-author-picture) .icon{width:1.5rem}img{cursor:help;border-radius:50%;width:2rem;height:2rem;object-fit:cover;background-color:var(--limebb-feed-background-color);box-shadow:0 0 0 1px rgb(var(--contrast-600))}.author{font-weight:bold;text-decoration:none;white-space:nowrap}a.author{position:relative;cursor:pointer;transition:color 0.2s ease;color:var(--mdc-theme-primary)}a.author:before{transition:opacity 0.2s ease, transform 0.3s ease-out;content:"";position:absolute;inset:auto 0 0 0;width:calc(100% - 0.5rem);margin:auto;height:0.125rem;border-radius:1rem;background-color:currentColor;opacity:0;transform:scale(0.6)}a.author:hover{color:rgb(var(--color-teal-light))}a.author:hover:before{opacity:0.3;transform:scale(1)}limel-chip-set{--limel-chip-size:1.5rem;--button-shadow-normal:none;margin-left:-1rem;margin-bottom:-0.5rem}.helper-text{transition:opacity 0.2s ease;opacity:0.6;font-size:x-small;margin-top:0.5rem;margin-bottom:-0.25rem}:host(limebb-feed-timeline-item:hover) .helper-text,:host(limebb-feed-timeline-item:focus-within) .helper-text{opacity:1}.thumbnail-card-link{--card-border-radius:0.5rem;border-radius:var(--card-border-radius);text-decoration:none;display:inline-block}.thumbnail-card-link:focus{outline:none}.thumbnail-card-link:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}limel-masonry-layout{--masonry-layout-min-column-width:10rem;--masonry-layout-gap:0.5rem;margin:0.25rem 0}:host(limebb-feed-timeline-item[has-error]:not([has-error=false])) .left:before{background-color:rgb(var(--color-red-default));box-shadow:0 0 0 1px rgb(var(--color-red-default))}:host(limebb-feed-timeline-item[has-error]:not([has-error=false])) img,:host(limebb-feed-timeline-item[has-error]:not([has-error=false])) .icon{box-shadow:var(--shadow-error-state)}:host(limebb-feed-timeline-item[has-error]:not([has-error=false])) .helper-text{opacity:1;color:rgb(var(--color-red-default))}';export{a as limebb_feed_timeline_item}
1
+ import{r as e,h as t,H as i,g as o}from"./p-DYpn0EkA.js";import{b as r}from"./p-BVxuJgRM.js";const a=class{constructor(i){e(this,i),this.ui="standard",this.hasError=!1,this.isBundled=!1,this.headingCanExpand=!1,this.isHeadingExpanded=!1,this.showMore=!1,this.isTall=!1,this.collapsibleButtonId="a"+crypto.randomUUID(),this.setHeaderCollapsible=()=>{this.headingParagraphElement&&(this.headingCanExpand=this.isTextTruncated(this.headingParagraphElement))},this.bodyTextTall=e=>{if(!this.bodyTextElement||!(null==e?void 0:e.length))return;const t=e[0].contentRect.width;if(t===this.lastMeasuredWidth)return;this.lastMeasuredWidth=t,this.bodyTextElement.style.minHeight="0";const i=this.bodyTextElement.scrollHeight;this.bodyTextElement.style.removeProperty("min-height"),this.isTall=i>(this.isThreadMessage?48:160),void 0===this.bodyTextHeight&&(this.bodyTextHeight=i)},this.renderHeader=()=>{if((!this.isBundled||this.item.heading)&&(this.item.author||this.item.heading))return t("div",{class:"header"},this.renderAuthor(),this.renderHeading(),this.renderExpandCollapseHeadingButton())},this.renderRelations=()=>{var e,i,o;if(null===(i=null===(e=this.item)||void 0===e?void 0:e.relations)||void 0===i?void 0:i.length)return t("limel-chip-set",{value:null===(o=this.item)||void 0===o?void 0:o.relations})},this.renderExpandCollapseHeadingButton=()=>{var e,i;if(this.item.heading)return this.headingCanExpand&&!this.isHeadingExpanded?[t("button",{onClick:this.toggleHeadingExpansion,class:"expand-heading"},null===(e=this.translator)||void 0===e?void 0:e.get("webclient.more"))]:this.isHeadingExpanded?[t("button",{onClick:this.toggleHeadingExpansion,id:this.collapsibleButtonId,class:"collapse-heading"},t("limel-icon",{name:"angle_up"})),t("limel-tooltip",{elementId:this.collapsibleButtonId,label:null===(i=this.translator)||void 0===i?void 0:i.get("webclient.show-less"),openDirection:"top-end"})]:void 0},this.renderThumbnailCard=e=>{const{href:i,image:o,filename:r}=e;if(!o&&!r)return;const a="thumb-"+crypto.randomUUID();return[t("a",{class:"thumbnail-card-link",id:a,key:a,href:i||void 0},t("limel-card",{image:o,clickable:!!i},t("limebb-feed-item-thumbnail-file-info",{slot:"component",description:r})),this.showThumbnailTooltip(e,a))]},this.setBodyTextElement=e=>{this.bodyTextElement=e},this.toggleShowMore=()=>{this.showMore=!this.showMore,this.showMore||this.el.offsetHeight>=window.innerHeight&&this.el.scrollIntoView({behavior:"auto"})},this.toggleHeadingExpansion=()=>{this.isHeadingExpanded=!this.isHeadingExpanded},this.createMenuItem=e=>{var t,i;return"separator"in e?e:{value:e,text:null!==(t=e.label)&&void 0!==t?t:"",secondaryText:e.description,disabled:e.disabled,icon:null!==(i=e.icon)&&void 0!==i?i:""}},this.createActionBarItem=e=>{var t,i;if("separator"in e)return e;let o={value:e,text:null!==(t=e.label)&&void 0!==t?t:"",secondaryText:e.description,disabled:e.disabled};return!e.label&&e.icon?o=Object.assign(Object.assign({},o),{icon:e.icon,text:null!==(i=e.description)&&void 0!==i?i:o.text,iconOnly:!0}):e.icon&&(o=Object.assign(Object.assign({},o),{icon:e.icon})),o},this.handleMenuItemSelect=e=>{var t;e.stopPropagation();const i=null===(t=e.detail.value)||void 0===t?void 0:t.command;i&&this.commandbus.handle(i)},this.handleActionBarItemSelect=e=>{var t;e.stopPropagation();const i=null===(t=e.detail.value)||void 0===t?void 0:t.command;i&&this.commandbus.handle(i)}}componentDidLoad(){var e,t;const i=null===(e=this.el.shadowRoot)||void 0===e?void 0:e.querySelector(".heading");this.headingParagraphElement=null===(t=null==i?void 0:i.shadowRoot)||void 0===t?void 0:t.querySelector("p"),this.headingParagraphElement&&(this.headingResizeObserver=new ResizeObserver(this.setHeaderCollapsible),this.headingResizeObserver.observe(this.headingParagraphElement)),this.bodyTextElement&&(this.bodyResizeObserver=new ResizeObserver(this.bodyTextTall),this.bodyResizeObserver.observe(this.bodyTextElement))}disconnectedCallback(){var e;null===(e=this.bodyResizeObserver)||void 0===e||e.disconnect()}render(){var e,o;const r=`helper-text-${this.item.id}`;return t(i,{key:"6e0269001c0a99c5792edb611cb62ccc3e58ecfd",id:this.item.id,class:{"has-unpromoted-actions":!!(null===(e=this.item.unpromotedActions)||void 0===e?void 0:e.length),"has-author-picture":!!(null===(o=this.item.author)||void 0===o?void 0:o.picture),"shows-less":!this.showMore,"expanded-heading":this.isHeadingExpanded,"shows-more":this.showMore,"is-tall":this.isTall},style:{"--body-text-height":`${this.bodyTextHeight}`,"--color-code":`${this.item.color}`},"aria-describedby":this.helperText?r:void 0,tabindex:"-1"},this.renderBadgeAndTimestamp(),this.renderContent(r))}renderBadgeAndTimestamp(){return t("div",{class:"left"},t("div",{class:"info"},this.renderAuthorPicture(),this.renderIcon(),t("span",{class:"timestamp"},this.renderTimestamp())))}renderIcon(){var e,i,o;if(!this.isBundled&&(this.item.icon||!(null===(e=this.item.author)||void 0===e?void 0:e.picture)))return t("limel-icon",{class:"icon",badge:!0,name:this.getIconName(),style:{color:`${null===(i=this.item.icon)||void 0===i?void 0:i.color}`,"background-color":`${null===(o=this.item.icon)||void 0===o?void 0:o.backgroundColor}`}})}getIconName(){const{ui:e,icon:t}=this.item;return"error-message"===e?"error":(null==t?void 0:t.name)||"dot_circle"}renderContent(e){return t("div",{class:"right"},t("div",{class:"content"},this.renderThreadEffects(),this.renderHeader(),this.renderUnpromotedActionsMenu(),this.renderValue(),this.renderThumbnails(),this.renderRelations(),this.renderHelperText(e)),this.renderPromotedActions())}renderThreadEffects(){if(this.isThreadMessage)return t("div",{class:"thread-effects",role:"presentation"})}renderHelperText(e){if(this.helperText)return t("span",{class:"helper-text",id:e},this.helperText)}renderAuthor(){if(this.item.author&&(!this.isBundled||this.item.heading)){if("string"==typeof this.item.author.name)return t("span",{class:"author"},this.item.author.name);if("object"==typeof this.item.author.name){const{href:e,title:i,text:o}=this.item.author.name;return t("a",{class:"author",href:e,title:i},o)}}}renderAuthorPicture(){var e;if(!(null===(e=this.item.author)||void 0===e?void 0:e.picture))return;if(this.isBundled)return;const{author:i}=this.item,o=this.getAuthorName(i),r=this.createLinkToAuthor(i);return t("limebb-summary-popover",{image:{src:this.item.author.picture,alt:`${o}`},heading:o,value:r},t("img",{slot:"trigger",loading:"lazy",src:this.item.author.picture}))}renderHeading(){if(this.item.heading)return[t("limel-markdown",{class:{heading:!0,"expanded-heading":this.isHeadingExpanded,"truncate-paragraphs":!this.isHeadingExpanded},value:this.item.heading,adaptColorContrast:!0})]}renderValue(){var e;if(this.item.value)return[t("div",{class:"markdown-container"},t("limel-markdown",{class:{"body-text":!0,opened:this.showMore,"no-table-styles":!(null===(e=this.item)||void 0===e?void 0:e.hasDefaultTableStyles),"reset-img-height":!0},value:this.item.value,lazyLoadImages:!0,ref:this.setBodyTextElement,adaptColorContrast:!0,whitelist:[{tagName:"limebb-mention",attributes:["limetype","objectid"]}]}),this.renderShowMoreButton())]}renderThumbnails(){var e;const i=null===(e=this.item)||void 0===e?void 0:e.thumbnails;if(null==i?void 0:i.length)return t("limel-masonry-layout",{role:"group"},i.map(this.renderThumbnailCard))}showThumbnailTooltip(e,i){var o;const{href:r,filename:a}=e;if(r)return t("limel-tooltip",{elementId:i,label:(null===(o=this.translator)||void 0===o?void 0:o.get("webclient.go-to-context-label",{context:a}))||a})}getAuthorName(e){return"string"==typeof e.name?e.name:e.name.text}createLinkToAuthor(e){if("object"!=typeof e.name)return;const{href:t,title:i,text:o}=e.name;return`<a class="author" href="${t}" title="${i}">${this.translator.get("webclient.actions.goto-object",{limetype:": <br><b>"+o+"</b>"})}</a>`}isTextTruncated(e){return e.offsetWidth<e.scrollWidth}renderShowMoreButton(){if(this.isTall)return[t("button",{id:"show-more-button",type:"button",onClick:this.toggleShowMore},t("limel-icon",{name:"angle_down"})),t("limel-tooltip",{label:this.toggleShowMoreLabel(),elementId:"show-more-button",openDirection:"top"})]}toggleShowMoreLabel(){var e,t;return this.showMore?null===(e=this.translator)||void 0===e?void 0:e.get("webclient.show-less"):null===(t=this.translator)||void 0===t?void 0:t.get("webclient.show-more")}renderUnpromotedActionsMenu(){var e,i;if(!(null===(e=this.item.unpromotedActions)||void 0===e?void 0:e.length))return;const o=this.item.unpromotedActions.map(this.createMenuItem);return t("limel-menu",{class:"unpromoted-actions-menu",items:o,openDirection:"bottom-end",onSelect:this.handleMenuItemSelect},t("limel-icon-button",{icon:"menu_2",slot:"trigger",label:null===(i=this.translator)||void 0===i?void 0:i.get("webclient.more-actions")}))}renderPromotedActions(){var e;if(!(null===(e=this.item.promotedActions)||void 0===e?void 0:e.length))return;const i=this.item.promotedActions.map(this.createActionBarItem);return t("div",{class:"action-bar"},t("div",{class:"action-bar-hider"},t("limel-action-bar",{accessibleLabel:"Action bar",actions:i,layout:"fullWidth",onItemSelected:this.handleActionBarItemSelect})))}renderTimestamp(){const e=this.item.timestamp;if(e)return this.dateTimeFormatter.format(e,"timeofday")}get dateTimeFormatter(){return this.platform.get(r.DateTimeFormatter)}get translator(){var e;return null===(e=this.platform)||void 0===e?void 0:e.get(r.Translate)}get commandbus(){var e;return null===(e=this.platform)||void 0===e?void 0:e.get(r.CommandBus)}get isThreadMessage(){return"thread-message"===this.ui}get el(){return o(this)}};a.style='@charset "UTF-8";limel-action-bar{--action-bar-item-height:1.75rem;transition:opacity 0.2s ease;justify-content:flex-start;opacity:0.8}.action-bar{display:grid;transition:grid-template-rows var(--limebb-promoted-action-bar-grid-template-rows-transition-speed, 0.2s) cubic-bezier(1, 0.09, 0, 0.89) var(--limebb-promoted-action-bar-grid-template-rows-transition-delay, 0s);grid-template-rows:var(--limebb-promoted-action-bar-grid-template-rows, 1fr)}.action-bar-hider{overflow:hidden}limel-action-bar{transition:padding var(--limebb-promoted-action-bar-grid-template-rows-transition-speed) cubic-bezier(1, 0.09, 0, 0.89) var(--limebb-promoted-action-bar-grid-template-rows-transition-delay);padding-top:0;padding-bottom:0.75rem}:host(limebb-feed-timeline-item:hover) .action-bar,:host(limebb-feed-timeline-item:focus-within) .action-bar,:host(limebb-feed-timeline-item:focus-visible) .action-bar{--limebb-promoted-action-bar-grid-template-rows:1fr;will-change:grid-template-rows}:host(limebb-feed-timeline-item:hover) limel-action-bar,:host(limebb-feed-timeline-item:focus-within) limel-action-bar,:host(limebb-feed-timeline-item:focus-visible) limel-action-bar{will-change:opacity;opacity:1}:host(limebb-feed-timeline-item:hover),:host(limebb-feed-timeline-item:focus-within){--limebb-promoted-action-bar-grid-template-rows-transition-speed:0.46s;--limebb-promoted-action-bar-grid-template-rows-transition-delay:0.7s}:host(limebb-feed-timeline-item.is-tall) .markdown-container{margin-bottom:0.5rem}:host(limebb-feed-timeline-item.is-tall) .body-text{--body-text-min-height-set-by-code:10rem;min-height:calc(var(--body-text-min-height-set-by-code) + 0.25rem)}:host(limebb-feed-timeline-item.is-tall) .body-text:after{transition:opacity 0.6s ease;content:"";opacity:0.26;pointer-events:none;position:absolute;bottom:-0.125rem;right:-0.125rem;left:-0.125rem;height:2.5rem;background:radial-gradient(farthest-side at 50% 100%, rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0)) 0 100%, linear-gradient(to bottom, rgb(var(--limebb-feed-item-background-color), 0) 0%, rgb(var(--limebb-feed-item-background-color), 90%) 100%);background-repeat:no-repeat;background-size:100% 0.5rem, 100% 100%}:host(limebb-feed-timeline-item.is-tall.shows-less) .markdown-container{grid-template-rows:0fr}:host(limebb-feed-timeline-item.is-tall.shows-less) .body-text:after{opacity:1}:host(limebb-feed-timeline-item.is-tall.shows-more) .markdown-container{grid-template-rows:1fr}:host(limebb-feed-timeline-item.is-tall.shows-more) #show-more-button limel-icon{rotate:180deg}.markdown-container{position:relative;display:grid}.markdown-container:not(.opened){transition:grid-template-rows min(var(--body-text-height) * 1.2ms, 500ms) cubic-bezier(1, 0.09, 0, 0.89)}.body-text{display:block;overflow:hidden}button#show-more-button{appearance:none;background:none;border:none;padding:0;margin:0;font:inherit;color:inherit;text-align:inherit;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:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-normal);z-index:1;position:absolute;right:0;bottom:-0.6rem;left:0;margin:0 auto;display:flex;align-items:center;justify-content:center;border-radius:3rem;width:2rem;height:1rem}button#show-more-button:hover,button#show-more-button:focus,button#show-more-button:focus-visible{will-change:color, background-color, box-shadow, transform}button#show-more-button:hover,button#show-more-button:focus-visible{transform:translate3d(0, -0.04rem, 0);color:var(--limel-theme-on-surface-color);background-color:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-hovered)}button#show-more-button:active{--limel-clickable-transform-timing-function:cubic-bezier( 0.83, -0.15, 0.49, 1.16 );transform:translate3d(0, 0.05rem, 0);box-shadow:var(--button-shadow-pressed)}button#show-more-button:hover,button#show-more-button:active{--limel-clickable-transition-speed:0.2s;--limel-clickable-transform-speed:0.16s}button#show-more-button:focus{outline:none}button#show-more-button:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}button#show-more-button limel-icon{transition:rotate 0.2s ease 0.5s;color:var(--mdc-theme-primary);width:0.75rem}:host(limebb-feed-timeline-item[ui=standard]) .content{background-color:rgb(var(--limebb-feed-item-background-color))}:host(limebb-feed-timeline-item[ui=emphasized]) .content{border:1px dashed rgb(var(--contrast-800))}:host(limebb-feed-timeline-item[ui=minimal]) limel-markdown{--markdown-hyperlink-color:rgb(var(--contrast-900))}:host(limebb-feed-timeline-item[ui=minimal]) limel-markdown:hover{--markdown-hyperlink-color:rgb(var(--color-blue-default))}:host(limebb-feed-timeline-item[ui=minimal]) a.author{color:rgb(var(--contrast-900))}:host(limebb-feed-timeline-item[ui=minimal]) .header:hover a.author{color:rgb(var(--color-blue-default))}:host(limebb-feed-timeline-item[ui=minimal]) .icon{color:rgb(var(--contrast-900)) !important}:host(limebb-feed-timeline-item[ui=minimal]) .body-text{color:rgb(var(--contrast-900))}:host(limebb-feed-timeline-item[ui=minimal]) .body-text:hover{color:rgb(var(--contrast-1100))}:host(limebb-feed-timeline-item[ui=thread-message]){padding:0.25rem 0}:host(limebb-feed-timeline-item[ui=thread-message]) .content{border-radius:0;box-shadow:var(--button-shadow-normal);margin-bottom:0.25rem;background-color:var(--lime-elevated-surface-background-color)}:host(limebb-feed-timeline-item[ui=thread-message]) .header{padding-bottom:0.75rem;margin-bottom:0.25rem}:host(limebb-feed-timeline-item[ui=thread-message]) .header:before{content:"";position:absolute;top:calc(var(--limebb-feed-item-paddings) * -1 + 0.25rem);left:calc(var(--limebb-feed-item-paddings) * -1);right:calc(var(--limebb-feed-item-paddings) * -1);bottom:0;pointer-events:none;border-bottom:1px dashed rgb(var(--contrast-600))}:host(limebb-feed-timeline-item[ui=thread-message]) .thread-effects{transition:transform 0.2s ease;pointer-events:none;content:"";position:absolute;z-index:-1;top:0;right:0;bottom:0;left:0;box-shadow:var(--button-shadow-normal);transform:translate3d(-0.225rem, -0.125rem, 0) rotate(0.5deg);background-color:rgb(var(--contrast-300))}:host(limebb-feed-timeline-item.is-tall[ui=thread-message]) .body-text{--body-text-min-height-set-by-code:3rem;min-height:calc(var(--body-text-min-height-set-by-code) + 0.25rem);max-height:35rem}:host(limebb-feed-timeline-item.is-tall[ui=thread-message].shows-more) .body-text{overflow-y:auto}:host(limebb-feed-timeline-item[ui=error-message]) .icon{color:rgb(var(--color-red-default))}:host(limebb-feed-timeline-item[ui=error-message]) .content{border:1px dashed rgb(var(--color-red-light));background-color:rgb(var(--color-red-lighter), 0.2)}.content{position:relative}.content:before,.content:after{content:"";position:absolute;top:1rem;bottom:1rem;left:-0.125rem;width:0.25rem;border-radius:0.25rem}.content:before{background-color:var(--color-code)}:host(limebb-feed-timeline-item[ui=emphasized]) .content:before,:host(limebb-feed-timeline-item[ui=emphasized]) .content:after{left:calc(-0.125rem - 0.5px)}:host(limebb-feed-timeline-item[ui=minimal]) .content:before{opacity:0.25}:host(limebb-feed-timeline-item[ui=minimal]) .content:after{opacity:0.5;background:repeating-linear-gradient(45deg, var(--color-code), var(--color-code) 0.5rem, transparent 0.5rem, transparent 1rem);background-size:0.25rem 100%;background-repeat:repeat-y;background-position:left;rotate:180deg}:host(limebb-feed-timeline-item[ui=thread-message]) .content:before{top:0.25rem;bottom:unset;height:1.75rem}*{box-sizing:border-box}:host(limebb-feed-timeline-item){--limebb-feed-item-paddings:0.75rem;display:flex;gap:0.75rem;position:relative;isolation:isolate;border-radius:0.5rem}:host(limebb-feed-timeline-item[is-bundled]:hover){--limebb-feed-item-timestamp-opacity-delay:0.5s}:host(limebb-feed-timeline-item[is-bundled]:hover) .timestamp{opacity:1}:host(limebb-feed-timeline-item[is-bundled]) .timestamp{opacity:0}:host(limebb-feed-timeline-item:hover),:host(limebb-feed-timeline-item:focus),:host(limebb-feed-timeline-item:focus-within){--limebb-feed-item-timeline-color:var(--mdc-theme-primary);--limebb-feed-item-timestamp-color:var(--mdc-theme-primary)}.left:before{transition:background-color 0.2s ease;content:"";position:absolute;z-index:-1;top:-0.25rem;bottom:-0.25rem;left:1rem;width:1px;border-radius:1rem;background-color:var(--limebb-feed-item-timeline-color, rgb(var(--contrast-600)))}.info{position:sticky;top:0.5rem;display:flex;flex-direction:column;align-items:center;gap:0.25rem}.right,.content{display:flex;flex-direction:column;flex-grow:1;min-width:0}.content{border-radius:1rem;gap:0.25rem;padding:var(--limebb-feed-item-paddings)}.header{position:relative;display:flex;gap:0.25rem;padding-bottom:0.25rem;margin-top:-0.25rem;color:rgb(var(--contrast-900));font-size:0.875rem}:host(.has-unpromoted-actions) .header{padding-right:2rem}.header limel-markdown{--markdown-hyperlink-color:var(--mdc-theme-primary);--markdown-hyperlink-color--hovered:rgb(var(--color-teal-light))}.heading{flex-grow:1;overflow:hidden;white-space:nowrap}.heading.expanded-heading{white-space:normal}button.expand-heading{appearance:none;background:none;border:none;padding:0;margin:0;font:inherit;color:inherit;text-align:inherit;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:rgb(var(--color-blue-default));background-color:transparent;border-radius:1rem;padding:0 0.25rem 0.25rem 0.25rem;height:1rem;white-space:nowrap}button.expand-heading:hover,button.expand-heading:focus,button.expand-heading:focus-visible{will-change:color, background-color, box-shadow, transform}button.expand-heading:hover,button.expand-heading:focus-visible{transform:translate3d(0, 0.01rem, 0);color:rgb(var(--color-blue-default));background-color:var(--lime-elevated-surface-background-color)}button.expand-heading:hover{box-shadow:var(--button-shadow-hovered)}button.expand-heading:active{--limel-clickable-transform-timing-function:cubic-bezier( 0.83, -0.15, 0.49, 1.16 );transform:translate3d(0, 0.05rem, 0);box-shadow:var(--button-shadow-pressed)}button.expand-heading:hover,button.expand-heading:active{--limel-clickable-transition-speed:0.2s;--limel-clickable-transform-speed:0.16s}button.collapse-heading{appearance:none;background:none;border:none;padding:0;margin:0;font:inherit;color:inherit;text-align:inherit;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:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-normal);flex-shrink:0;display:flex;align-items:center;justify-content:center;border-radius:1.5rem;width:1rem}button.collapse-heading:hover,button.collapse-heading:focus,button.collapse-heading:focus-visible{will-change:color, background-color, box-shadow, transform}button.collapse-heading:hover,button.collapse-heading:focus-visible{transform:translate3d(0, -0.04rem, 0);color:var(--limel-theme-on-surface-color);background-color:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-hovered)}button.collapse-heading:active{--limel-clickable-transform-timing-function:cubic-bezier( 0.83, -0.15, 0.49, 1.16 );transform:translate3d(0, 0.05rem, 0);box-shadow:var(--button-shadow-pressed)}button.collapse-heading:hover,button.collapse-heading:active{--limel-clickable-transition-speed:0.2s;--limel-clickable-transform-speed:0.16s}button.collapse-heading:focus{outline:none}button.collapse-heading:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}button.collapse-heading limel-icon{width:0.75rem}.unpromoted-actions-menu{position:absolute;top:0;right:0;z-index:1}.timestamp{transition:color 0.4s ease, opacity 0.2s ease;transition-delay:var(--limebb-feed-item-timestamp-opacity-delay, 0s);display:flex;flex-direction:column;align-items:center;gap:0.25rem;font-size:0.75rem;text-align:center;color:var(--limebb-feed-item-timestamp-color, rgb(var(--contrast-800)));background-color:var(--limebb-feed-background-color);padding:0.125rem 0;width:2rem;border-radius:1rem}.timestamp:after{width:0.5rem;height:0.5rem;border-radius:50%;background-color:rgb(var(--color-red-default))}:host(.is-new) .timestamp:after{content:""}.icon{--icon-background-color:var(--limebb-feed-background-color);width:2rem;padding:0.125rem}:host(.has-author-picture) .icon{width:1.5rem}img{cursor:help;border-radius:50%;width:2rem;height:2rem;object-fit:cover;background-color:var(--limebb-feed-background-color);box-shadow:0 0 0 1px rgb(var(--contrast-600))}.author{font-weight:bold;text-decoration:none;white-space:nowrap}a.author{position:relative;cursor:pointer;transition:color 0.2s ease;color:var(--mdc-theme-primary)}a.author:before{transition:opacity 0.2s ease, transform 0.3s ease-out;content:"";position:absolute;inset:auto 0 0 0;width:calc(100% - 0.5rem);margin:auto;height:0.125rem;border-radius:1rem;background-color:currentColor;opacity:0;transform:scale(0.6)}a.author:hover{color:rgb(var(--color-teal-light))}a.author:hover:before{opacity:0.3;transform:scale(1)}limel-chip-set{--limel-chip-size:1.5rem;--button-shadow-normal:none;margin-left:-1rem;margin-bottom:-0.5rem}.helper-text{transition:opacity 0.2s ease;opacity:0.6;font-size:x-small;margin-top:0.5rem;margin-bottom:-0.25rem}:host(limebb-feed-timeline-item:hover) .helper-text,:host(limebb-feed-timeline-item:focus-within) .helper-text{opacity:1}.thumbnail-card-link{--card-border-radius:0.5rem;border-radius:var(--card-border-radius);text-decoration:none;display:inline-block}.thumbnail-card-link:focus{outline:none}.thumbnail-card-link:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}limel-masonry-layout{--masonry-layout-min-column-width:10rem;--masonry-layout-gap:0.5rem;margin:0.25rem 0}:host(limebb-feed-timeline-item[has-error]:not([has-error=false])) .left:before{background-color:rgb(var(--color-red-default));box-shadow:0 0 0 1px rgb(var(--color-red-default))}:host(limebb-feed-timeline-item[has-error]:not([has-error=false])) img,:host(limebb-feed-timeline-item[has-error]:not([has-error=false])) .icon{box-shadow:var(--shadow-error-state)}:host(limebb-feed-timeline-item[has-error]:not([has-error=false])) .helper-text{opacity:1;color:rgb(var(--color-red-default))}';export{a as limebb_feed_timeline_item}
@@ -1 +1 @@
1
- import{r as t,c as e,h as r}from"./p-DYpn0EkA.js";const o=class{constructor(r){t(this,r),this.dismiss=e(this,"dismiss"),this.type="note",this.open=!1,this.handleClose=()=>{this.dismiss.emit()}}render(){return r("limel-dialog",{key:"0b4041923a74d2e0b43788a09422a314debc8ae0",open:this.open,onClose:this.handleClose},r("div",{key:"b8bcf117221f66ae918d8787ea8f9bb78b2dd55a",class:"dialog-content"},r("div",{key:"6ea1963f9760ca4d62a01b51f3adae3094970c7a",class:"icon-slot"},r("limel-icon",{key:"d95479863a615d2d074a360942fa02d70e7c2f41",name:this.getIconName(),"aria-hidden":"true"})),r("h1",{key:"6e1fa0d6511ba3dc5e4799f32f51ccd5514486ad",id:"alert-dialog-title"},this.heading),this.renderSubheading()),r("div",{key:"d5a5e895dfb911fdf04ca644a540799546d10083",slot:"button"},r("slot",{key:"6211763f55159bb546082483e05006f5c037ca6e",name:"button"})))}renderSubheading(){return this.subheading?r("h2",{id:"alert-dialog-content"},this.subheading):null}getIconName(){return this.icon?this.icon:{note:"information",success:"check_mark",caution:"error_(14)",warning:"multiply"}[this.type]}};o.style='@charset "UTF-8";:host(limebb-alert-dialog){--dialog-width:20rem;overflow:hidden}:host([type=note]){--alert-type-background:var(--color-sky-lighter);--alert-type-color:var(--color-sky-dark)}:host([type=success]){--alert-type-background:var(--color-lime-lighter);--alert-type-color:var(--color-lime-dark)}:host([type=caution]){--alert-type-background:var(--color-orange-lighter);--alert-type-color:var(--color-orange-dark)}:host([type=warning]){--alert-type-background:var(--color-coral-lighter);--alert-type-color:var(--color-coral-dark)}.dialog-content{display:flex;flex-direction:column;align-items:center}.icon-slot{display:flex;justify-content:center;align-items:center;height:7rem;width:7rem;border-radius:50%;margin:1.5rem 0;background:rgb(var(--alert-type-background))}limel-icon{height:3.5rem;width:3.5rem;color:rgb(var(--alert-type-color))}h1{color:rgb(var(--contrast-1500));font-size:1.5rem}h2{text-align:center;color:rgb(var(--contrast-1200));margin:0 0 0.25rem 0;font-size:0.9rem;font-weight:500;line-height:1.2rem}div[slot=button]{display:flex;flex-direction:column;align-items:center;gap:0.5rem;width:100%}::slotted(limel-button){display:block;width:100%}::slotted(limel-button[primary]){color:rgb(var(--contrast-100));--lime-primary-color:rgb(var(--alert-type-color))}::slotted(limel-button:not([primary])){--lime-primary-color:rgb(var(--contrast-1000))}::slotted(button){appearance:none;background:none;border:none;padding:0;margin:0;font:inherit;color:inherit;text-align:inherit}::slotted(a){all:unset}::slotted(button),::slotted(a){color:rgb(var(--contrast-1000));border-bottom:1px solid rgb(var(--contrast-800));text-align:center;width:fit-content;cursor:pointer}::slotted(button:focus-visible),::slotted(a:focus-visible){outline:none;box-shadow:var(--shadow-depth-8-focused)}';export{o as limebb_alert_dialog}
1
+ import{r as t,c as e,h as r}from"./p-DYpn0EkA.js";const o=class{constructor(r){t(this,r),this.dismiss=e(this,"dismiss"),this.type="note",this.open=!1,this.handleClose=()=>{this.dismiss.emit()}}render(){return r("limel-dialog",{key:"9912ff54e5a06d0b535a590e0088fad30bb8ed02",open:this.open,onClose:this.handleClose},r("div",{key:"553dcbc83dd5017bae91ed2801a54fa5d107e6a7",class:"dialog-content"},r("div",{key:"b81159c55780a4e4e4d6509866cd60accadce88f",class:"icon-slot"},r("limel-icon",{key:"aa61f4a0371e9a41359403ea3431b21404757017",name:this.getIconName(),"aria-hidden":"true"})),r("h1",{key:"7aeef07ad8fa5478099b48b123d672f6ae691a40",id:"alert-dialog-title"},this.heading),this.renderSubheading()),r("div",{key:"c2bff37973635292366a7131c7c165d639ac08a8",slot:"button"},r("slot",{key:"6094bd1c292867e6f0dddb0667fafb03efaaa9ee",name:"button"})))}renderSubheading(){return this.subheading?r("h2",{id:"alert-dialog-content"},this.subheading):null}getIconName(){return this.icon?this.icon:{note:"information",success:"check_mark",caution:"error_(14)",warning:"multiply"}[this.type]}};o.style='@charset "UTF-8";:host(limebb-alert-dialog){--dialog-width:20rem;overflow:hidden}:host([type=note]){--alert-type-background:var(--color-sky-lighter);--alert-type-color:var(--color-sky-dark)}:host([type=success]){--alert-type-background:var(--color-lime-lighter);--alert-type-color:var(--color-lime-dark)}:host([type=caution]){--alert-type-background:var(--color-orange-lighter);--alert-type-color:var(--color-orange-dark)}:host([type=warning]){--alert-type-background:var(--color-coral-lighter);--alert-type-color:var(--color-coral-dark)}.dialog-content{display:flex;flex-direction:column;align-items:center}.icon-slot{display:flex;justify-content:center;align-items:center;height:7rem;width:7rem;border-radius:50%;margin:1.5rem 0;background:rgb(var(--alert-type-background))}limel-icon{height:3.5rem;width:3.5rem;color:rgb(var(--alert-type-color))}h1{color:rgb(var(--contrast-1500));font-size:1.5rem}h2{text-align:center;color:rgb(var(--contrast-1200));margin:0 0 0.25rem 0;font-size:0.9rem;font-weight:500;line-height:1.2rem}div[slot=button]{display:flex;flex-direction:column;align-items:center;gap:0.5rem;width:100%}::slotted(limel-button){display:block;width:100%}::slotted(limel-button[primary]){color:rgb(var(--contrast-100));--lime-primary-color:rgb(var(--alert-type-color))}::slotted(limel-button:not([primary])){--lime-primary-color:rgb(var(--contrast-1000))}::slotted(button){appearance:none;background:none;border:none;padding:0;margin:0;font:inherit;color:inherit;text-align:inherit}::slotted(a){all:unset}::slotted(button),::slotted(a){color:rgb(var(--contrast-1000));border-bottom:1px solid rgb(var(--contrast-800));text-align:center;width:fit-content;cursor:pointer}::slotted(button:focus-visible),::slotted(a:focus-visible){outline:none;box-shadow:var(--shadow-depth-8-focused)}';export{o as limebb_alert_dialog}
@@ -1 +1 @@
1
- import{r as t,c as e,h as i,H as r}from"./p-DYpn0EkA.js";import{b as o}from"./p-CqRNpSRV.js";const a=class{constructor(r){t(this,r),this.interact=e(this,"interact"),this.handleClick=()=>{this.isItemClickable()&&this.handleNotificationListItemClick()},this.handleKeyDown=t=>{this.isItemClickable()&&"Enter"===t.key&&this.handleNotificationListItemClick()},this.renderHeading=()=>{if(!this.item.heading)return;if(!this.item.author)return i("limel-markdown",{value:this.translator.get(this.item.heading)});const t=this.getAuthorLink(),e=this.translator.get(this.item.heading,{author:t});return i("limel-markdown",{class:"heading",value:e})},this.createMenuItem=t=>{var e,i;return"separator"in t?t:{value:t,text:null!==(e=t.label)&&void 0!==e?e:"",secondaryText:t.description,disabled:t.disabled,icon:null!==(i=t.icon)&&void 0!==i?i:""}},this.handleMenuItemSelect=t=>{var e;t.stopPropagation();const i=null===(e=t.detail.value)||void 0===e?void 0:e.command;i&&this.commandbus.handle(i)},this.handleNotificationListItemClick=()=>{this.interact.emit(this.item)}}render(){var t,e;return i(r,{key:"dff09ced1e8ae05c746912e249f2557de6fce96e",id:this.item.id,class:{"is-clickable":this.isItemClickable(),"is-read":!!(null===(t=this.item)||void 0===t?void 0:t.read),"is-selected":!!(null===(e=this.item)||void 0===e?void 0:e.selected)},onClick:this.handleClick,onKeyDown:this.handleKeyDown,tabindex:0},this.renderSource(),this.renderContent())}isItemClickable(){var t;return!!(null===(t=this.item)||void 0===t?void 0:t.clickable)}renderSource(){return i("div",{class:"header"},this.renderIcon(),this.renderCaption(),this.renderTimestamp(),this.renderUnpromotedActionsMenu())}renderIcon(){var t,e,r,o;if(this.item.icon)return i("limel-icon",{class:"icon",badge:!0,name:null!==(e=null===(t=this.item.icon)||void 0===t?void 0:t.name)&&void 0!==e?e:"dot_circle",style:{color:`${null===(r=this.item.icon)||void 0===r?void 0:r.color}`,"background-color":`${null===(o=this.item.icon)||void 0===o?void 0:o.backgroundColor}`}})}renderContent(){return i("div",{class:"content"},i("div",{class:"body"},this.renderHeadline(),this.renderValue()),this.renderAuthorPicture())}renderHeadline(){if(this.item.heading)return i("div",{class:"headline"},this.renderHeading())}getAuthorLink(){if(!this.item.author)return;if("string"==typeof this.item.author.name)return this.item.author.name;const{href:t,text:e}=this.item.author.name;return`[${e}](${t})`}renderAuthorPicture(){var t;if(null===(t=this.item.author)||void 0===t?void 0:t.picture)return i("img",{class:"author-avatar",loading:"lazy",src:this.item.author.picture})}renderCaption(){if(this.item.caption)return i("h2",{class:"caption"},this.item.caption)}renderValue(){if(this.item.value)return i("limel-markdown",{class:"body-text",value:this.item.value})}renderUnpromotedActionsMenu(){var t,e;if(!(null===(t=this.item.unpromotedActions)||void 0===t?void 0:t.length))return;const r=this.item.unpromotedActions.map(this.createMenuItem);return i("limel-menu",{class:"unpromoted-actions-menu",items:r,openDirection:"bottom-end",onSelect:this.handleMenuItemSelect},i("limel-icon-button",{icon:"menu_2",slot:"trigger",label:null===(e=this.translator)||void 0===e?void 0:e.get("webclient.more-actions")}))}renderTimestamp(){const t=this.item.timestamp;if(t)return i("span",{class:"timestamp"},this.dateTimeFormatter.format(t,"timeofday"))}get dateTimeFormatter(){return this.platform.get(o.DateTimeFormatter)}get translator(){var t;return null===(t=this.platform)||void 0===t?void 0:t.get(o.Translate)}get commandbus(){var t;return null===(t=this.platform)||void 0===t?void 0:t.get(o.CommandBus)}};a.style='@charset "UTF-8";*{box-sizing:border-box}:host(limebb-notification-item){isolation:isolate;position:relative;box-sizing:border-box;display:flex;flex-direction:column;gap:0.25rem;margin-left:0.5rem;border-radius:0.75rem;border:1px solid rgb(var(--contrast-500))}:host(limebb-notification-item):before{content:"";display:block;position:absolute;left:-1rem;top:0.85rem;border-radius:50%;height:0.5rem;width:0.5rem;transition:background-color 0.2s ease, scale 0.2s cubic-bezier(0.82, 0.3, 0.14, 1.36);scale:var(--limebb-notification-item-unread-badge-scale, 0.6);background-color:var(--limebb-notification-item-unread-badge-color, transparent)}:host(limebb-notification-item:hover) .timestamp{color:rgb(var(--contrast-1100))}:host(limebb-notification-item:hover) .body-text{opacity:1}.header{display:flex;align-items:center;gap:0.25rem;min-height:2rem;padding:0 0 0 0.25rem;margin-bottom:0.25rem}.header:not(:has(.icon)){padding-left:0.75rem}.header:not(:has(.unpromoted-actions-menu)){padding-right:0.5rem}.caption,.timestamp{font-size:0.75rem}.caption{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;margin:0;flex-grow:1;font-weight:600;color:rgb(var(--contrast-900))}.timestamp{flex-shrink:0;margin-left:auto;transition:color 0.4s ease, opacity 0.2s ease;color:rgb(var(--contrast-900))}.headline{display:flex;gap:0.25rem;align-items:center}.content{display:flex;min-width:0;gap:0.5rem;padding:0 0.75rem 0.5rem 0.75rem}.heading{display:-webkit-box;overflow:hidden;white-space:normal;-webkit-box-orient:vertical;-webkit-line-clamp:2;max-height:2.5rem;font-size:0.875rem;--markdown-hyperlink-color:var(--mdc-theme-primary);--markdown-hyperlink-color--hovered:rgb(var(--color-teal-light))}.body{display:flex;flex-direction:column;gap:0.5rem}.body-text{display:-webkit-box;overflow:hidden;white-space:normal;-webkit-box-orient:vertical;-webkit-line-clamp:3;max-height:4.25rem;transition:opacity 0.2s ease;opacity:0.7}.icon{--icon-background-color:var(--limebb-feed-background-color);flex-shrink:0;width:1.5rem;padding:0.125rem}.author-avatar{border-radius:50%;width:2rem;height:2rem;object-fit:cover;margin-top:auto;margin-right:-0.25rem;margin-left:auto;box-shadow:0 0 0 1px rgb(var(--contrast-600))}.author{font-weight:bold;text-decoration:none;white-space:nowrap}a.author{position:relative;cursor:pointer;transition:color 0.2s ease;color:var(--mdc-theme-primary)}a.author:before{transition:opacity 0.2s ease, transform 0.3s ease-out;content:"";position:absolute;inset:auto 0 0 0;width:calc(100% - 0.5rem);margin:auto;height:0.125rem;border-radius:1rem;background-color:currentColor;opacity:0;transform:scale(0.6)}a.author:hover{color:rgb(var(--color-teal-light))}a.author:hover:before{opacity:0.3;transform:scale(1)}limel-chip-set{--button-shadow-normal:none;margin-left:-1rem;margin-bottom:-0.5rem}';export{a as limebb_notification_item}
1
+ import{r as t,c as i,h as e,H as r}from"./p-DYpn0EkA.js";import{b as o}from"./p-BVxuJgRM.js";const a=class{constructor(r){t(this,r),this.interact=i(this,"interact"),this.handleClick=()=>{this.isItemClickable()&&this.handleNotificationListItemClick()},this.handleKeyDown=t=>{this.isItemClickable()&&"Enter"===t.key&&this.handleNotificationListItemClick()},this.renderHeading=()=>{if(!this.item.heading)return;if(!this.item.author)return e("limel-markdown",{value:this.translator.get(this.item.heading)});const t=this.getAuthorLink(),i=this.translator.get(this.item.heading,{author:t});return e("limel-markdown",{class:"heading",value:i})},this.createMenuItem=t=>{var i,e;return"separator"in t?t:{value:t,text:null!==(i=t.label)&&void 0!==i?i:"",secondaryText:t.description,disabled:t.disabled,icon:null!==(e=t.icon)&&void 0!==e?e:""}},this.handleMenuItemSelect=t=>{var i;t.stopPropagation();const e=null===(i=t.detail.value)||void 0===i?void 0:i.command;e&&this.commandbus.handle(e)},this.handleNotificationListItemClick=()=>{this.interact.emit(this.item)}}render(){var t,i;return e(r,{key:"db1045deee7826d3e3bd235f290bc5f42b1d8462",id:this.item.id,class:{"is-clickable":this.isItemClickable(),"is-read":!!(null===(t=this.item)||void 0===t?void 0:t.read),"is-selected":!!(null===(i=this.item)||void 0===i?void 0:i.selected)},onClick:this.handleClick,onKeyDown:this.handleKeyDown,tabindex:0},this.renderSource(),this.renderContent())}isItemClickable(){var t;return!!(null===(t=this.item)||void 0===t?void 0:t.clickable)}renderSource(){return e("div",{class:"header"},this.renderIcon(),this.renderCaption(),this.renderTimestamp(),this.renderUnpromotedActionsMenu())}renderIcon(){var t,i,r,o;if(this.item.icon)return e("limel-icon",{class:"icon",badge:!0,name:null!==(i=null===(t=this.item.icon)||void 0===t?void 0:t.name)&&void 0!==i?i:"dot_circle",style:{color:`${null===(r=this.item.icon)||void 0===r?void 0:r.color}`,"background-color":`${null===(o=this.item.icon)||void 0===o?void 0:o.backgroundColor}`}})}renderContent(){return e("div",{class:"content"},e("div",{class:"body"},this.renderHeadline(),this.renderValue()),this.renderAuthorPicture())}renderHeadline(){if(this.item.heading)return e("div",{class:"headline"},this.renderHeading())}getAuthorLink(){if(!this.item.author)return;if("string"==typeof this.item.author.name)return this.item.author.name;const{href:t,text:i}=this.item.author.name;return`[${i}](${t})`}renderAuthorPicture(){var t;if(null===(t=this.item.author)||void 0===t?void 0:t.picture)return e("img",{class:"author-avatar",loading:"lazy",src:this.item.author.picture})}renderCaption(){if(this.item.caption)return e("h2",{class:"caption"},this.item.caption)}renderValue(){if(this.item.value)return e("limel-markdown",{class:"body-text",value:this.item.value})}renderUnpromotedActionsMenu(){var t,i;if(!(null===(t=this.item.unpromotedActions)||void 0===t?void 0:t.length))return;const r=this.item.unpromotedActions.map(this.createMenuItem);return e("limel-menu",{class:"unpromoted-actions-menu",items:r,openDirection:"bottom-end",onSelect:this.handleMenuItemSelect},e("limel-icon-button",{icon:"menu_2",slot:"trigger",label:null===(i=this.translator)||void 0===i?void 0:i.get("webclient.more-actions")}))}renderTimestamp(){const t=this.item.timestamp;if(t)return e("span",{class:"timestamp"},this.dateTimeFormatter.format(t,"timeofday"))}get dateTimeFormatter(){return this.platform.get(o.DateTimeFormatter)}get translator(){var t;return null===(t=this.platform)||void 0===t?void 0:t.get(o.Translate)}get commandbus(){var t;return null===(t=this.platform)||void 0===t?void 0:t.get(o.CommandBus)}};a.style='@charset "UTF-8";*{box-sizing:border-box}:host(limebb-notification-item){isolation:isolate;position:relative;box-sizing:border-box;display:flex;flex-direction:column;gap:0.25rem;margin-left:0.5rem;border-radius:0.75rem;border:1px solid rgb(var(--contrast-500))}:host(limebb-notification-item):before{content:"";display:block;position:absolute;left:-1rem;top:0.85rem;border-radius:50%;height:0.5rem;width:0.5rem;transition:background-color 0.2s ease, scale 0.2s cubic-bezier(0.82, 0.3, 0.14, 1.36);scale:var(--limebb-notification-item-unread-badge-scale, 0.6);background-color:var(--limebb-notification-item-unread-badge-color, transparent)}:host(limebb-notification-item:hover) .timestamp{color:rgb(var(--contrast-1100))}:host(limebb-notification-item:hover) .body-text{opacity:1}.header{display:flex;align-items:center;gap:0.25rem;min-height:2rem;padding:0 0 0 0.25rem;margin-bottom:0.25rem}.header:not(:has(.icon)){padding-left:0.75rem}.header:not(:has(.unpromoted-actions-menu)){padding-right:0.5rem}.caption,.timestamp{font-size:0.75rem}.caption{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;margin:0;flex-grow:1;font-weight:600;color:rgb(var(--contrast-900))}.timestamp{flex-shrink:0;margin-left:auto;transition:color 0.4s ease, opacity 0.2s ease;color:rgb(var(--contrast-900))}.headline{display:flex;gap:0.25rem;align-items:center}.content{display:flex;min-width:0;gap:0.5rem;padding:0 0.75rem 0.5rem 0.75rem}.heading{display:-webkit-box;overflow:hidden;white-space:normal;-webkit-box-orient:vertical;-webkit-line-clamp:2;max-height:2.5rem;font-size:0.875rem;--markdown-hyperlink-color:var(--mdc-theme-primary);--markdown-hyperlink-color--hovered:rgb(var(--color-teal-light))}.body{display:flex;flex-direction:column;gap:0.5rem}.body-text{display:-webkit-box;overflow:hidden;white-space:normal;-webkit-box-orient:vertical;-webkit-line-clamp:3;max-height:4.25rem;transition:opacity 0.2s ease;opacity:0.7}.icon{--icon-background-color:var(--limebb-feed-background-color);flex-shrink:0;width:1.5rem;padding:0.125rem}.author-avatar{border-radius:50%;width:2rem;height:2rem;object-fit:cover;margin-top:auto;margin-right:-0.25rem;margin-left:auto;box-shadow:0 0 0 1px rgb(var(--contrast-600))}.author{font-weight:bold;text-decoration:none;white-space:nowrap}a.author{position:relative;cursor:pointer;transition:color 0.2s ease;color:var(--mdc-theme-primary)}a.author:before{transition:opacity 0.2s ease, transform 0.3s ease-out;content:"";position:absolute;inset:auto 0 0 0;width:calc(100% - 0.5rem);margin:auto;height:0.125rem;border-radius:1rem;background-color:currentColor;opacity:0;transform:scale(0.6)}a.author:hover{color:rgb(var(--color-teal-light))}a.author:hover:before{opacity:0.3;transform:scale(1)}limel-chip-set{--button-shadow-normal:none;margin-left:-1rem;margin-bottom:-0.5rem}';export{a as limebb_notification_item}
@@ -1 +1 @@
1
- import{r as i,c as t,h as e,H as s}from"./p-DYpn0EkA.js";import{b as r,n as o}from"./p-CqRNpSRV.js";import{L as n}from"./p-D3UYWGdn.js";import{a as h}from"./p-CQUZjrU4.js";import{a as l}from"./p-y_s8hZmV.js";const a=class{constructor(e){i(this,e),this.expressionChange=t(this,"expressionChange"),this.isOpen=!1,this.handleOpen=()=>{this.isOpen=!0},this.handleClose=()=>{this.isOpen=!1},this.handleEditorChange=i=>{i.stopPropagation(),this.expressionChange.emit(i.detail)},this.removeExpression=()=>{this.expressionChange.emit(void 0)}}componentWillLoad(){var i;(null===(i=this.expression)||void 0===i?void 0:i.key)||(this.isOpen=!0)}render(){return e(s,{key:"f85d1669dccffd7a0905ac5549eeea2f4c350782"},this.renderHeader(),e("limel-popover",{key:"793a3ea0377182b86511165e39ff30212736d030",open:this.isOpen,openDirection:"bottom-start",onClose:this.handleClose},e("limel-chip",{key:"0d4c7c565268c096d390994a862920c8066e1f11",slot:"trigger",text:this.summaryText(),icon:this.summaryIcon(),removable:!0,onClick:this.handleOpen,onRemove:this.removeExpression}),e("limebb-lime-query-filter-comparison-editor",{key:"a4ddad5edc49c4de265e9b3e237fb31455ae48e0",platform:this.platform,context:this.context,limetype:this.limetype,activeLimetype:this.activeLimetype,expression:this.expression,onExpressionChange:this.handleEditorChange})))}summaryText(){var i;const t=null===(i=this.expression)||void 0===i?void 0:i.key;return t?`${this.getPropertyLabel(t)} ${this.getOperatorLabel(this.expression.op)} ${this.formatValue(this.expression.exp)}`.trim():"New condition"}getPropertyLabel(i){var t,e;const s=null===(t=this.platform)||void 0===t?void 0:t.get(r.LimeTypeRepository);if(!s||!this.limetype)return i;const o=i.split("."),n=[];let l=s.getLimeType(this.limetype);for(const i of o){if(!l){n.push(i);continue}const t=h(l)[i];n.push((null==t?void 0:t.localname)||i),l=null===(e=null==t?void 0:t.relation)||void 0===e?void 0:e.getLimetype()}return n.join(" › ")}summaryIcon(){var i;if(!(null===(i=this.expression)||void 0===i?void 0:i.op))return;const t=n.find((i=>i.value===this.expression.op));return null==t?void 0:t.icon}getOperatorLabel(i){var t,e;if(!i)return"";const s=n.find((t=>t.value===i));return s?null!==(e=null===(t=this.translator)||void 0===t?void 0:t.get(s.label))&&void 0!==e?e:s.label:""}formatValue(i){return null==i||""===i?"…":Array.isArray(i)?i.map((i=>this.formatValue(i))).join(", "):"string"==typeof i?`"${i}"`:String(i)}renderHeader(){if(this.label)return e("limel-header",{subheading:this.label})}get translator(){var i;return null===(i=this.platform)||void 0===i?void 0:i.get(r.Translate)}};a.style=":host(limebb-lime-query-filter-comparison){display:inline-block;max-width:25rem}";const m=class{constructor(e){i(this,e),this.expressionChange=t(this,"expressionChange"),this.handleExpressionChange=i=>{i.stopPropagation(),this.expressionChange.emit(i.detail)}}render(){if(!this.expression)return;const i={platform:this.platform,context:this.context,label:this.label,limetype:this.limetype,activeLimetype:this.activeLimetype};if("key"in this.expression)return e("limebb-lime-query-filter-comparison",Object.assign({},i,{expression:this.expression,onExpressionChange:this.handleExpressionChange}));const t=l(this.expression);return t?e("limebb-lime-query-filter-group",Object.assign({},i,{expression:t,onExpressionChange:this.handleExpressionChange})):this.expression.op===o.NOT?e("limebb-lime-query-filter-not",Object.assign({},i,{expression:this.expression,onExpressionChange:this.handleExpressionChange})):void 0}};export{a as limebb_lime_query_filter_comparison,m as limebb_lime_query_filter_expression}
1
+ import{r as i,c as t,h as e,H as s}from"./p-DYpn0EkA.js";import{b as r,n as o}from"./p-BVxuJgRM.js";import{L as n}from"./p-BneXZK-Q.js";import{a as h}from"./p-CQUZjrU4.js";import{a as l}from"./p-DjwVpKf5.js";const a=class{constructor(e){i(this,e),this.expressionChange=t(this,"expressionChange"),this.isOpen=!1,this.handleOpen=()=>{this.isOpen=!0},this.handleClose=()=>{this.isOpen=!1},this.handleEditorChange=i=>{i.stopPropagation(),this.expressionChange.emit(i.detail)},this.removeExpression=()=>{this.expressionChange.emit(void 0)}}componentWillLoad(){var i;(null===(i=this.expression)||void 0===i?void 0:i.key)||(this.isOpen=!0)}render(){return e(s,{key:"2eb5d1fd3602162e9b5efe49e9ebdd1ad006a611"},this.renderHeader(),e("limel-popover",{key:"8ff6dba3737f58f204cc25b2c7d37827c1e7ecee",open:this.isOpen,openDirection:"bottom-start",onClose:this.handleClose},e("limel-chip",{key:"886ff840786fbdf0fdf1d7ef6a8cf3d8cca54c72",slot:"trigger",text:this.summaryText(),icon:this.summaryIcon(),removable:!0,onClick:this.handleOpen,onRemove:this.removeExpression}),e("limebb-lime-query-filter-comparison-editor",{key:"b0dfd57ffda004f63c3f7d71db46aa0950e2f13c",platform:this.platform,context:this.context,limetype:this.limetype,activeLimetype:this.activeLimetype,expression:this.expression,onExpressionChange:this.handleEditorChange})))}summaryText(){var i;const t=null===(i=this.expression)||void 0===i?void 0:i.key;return t?`${this.getPropertyLabel(t)} ${this.getOperatorLabel(this.expression.op)} ${this.formatValue(this.expression.exp)}`.trim():"New condition"}getPropertyLabel(i){var t,e;const s=null===(t=this.platform)||void 0===t?void 0:t.get(r.LimeTypeRepository);if(!s||!this.limetype)return i;const o=i.split("."),n=[];let l=s.getLimeType(this.limetype);for(const i of o){if(!l){n.push(i);continue}const t=h(l)[i];n.push((null==t?void 0:t.localname)||i),l=null===(e=null==t?void 0:t.relation)||void 0===e?void 0:e.getLimetype()}return n.join(" › ")}summaryIcon(){var i;if(!(null===(i=this.expression)||void 0===i?void 0:i.op))return;const t=n.find((i=>i.value===this.expression.op));return null==t?void 0:t.icon}getOperatorLabel(i){var t,e;if(!i)return"";const s=n.find((t=>t.value===i));return s?null!==(e=null===(t=this.translator)||void 0===t?void 0:t.get(s.label))&&void 0!==e?e:s.label:""}formatValue(i){return null==i||""===i?"…":Array.isArray(i)?i.map((i=>this.formatValue(i))).join(", "):"string"==typeof i?`"${i}"`:String(i)}renderHeader(){if(this.label)return e("limel-header",{subheading:this.label})}get translator(){var i;return null===(i=this.platform)||void 0===i?void 0:i.get(r.Translate)}};a.style=":host(limebb-lime-query-filter-comparison){display:inline-block;max-width:25rem}";const c=class{constructor(e){i(this,e),this.expressionChange=t(this,"expressionChange"),this.handleExpressionChange=i=>{i.stopPropagation(),this.expressionChange.emit(i.detail)}}render(){if(!this.expression)return;const i={platform:this.platform,context:this.context,label:this.label,limetype:this.limetype,activeLimetype:this.activeLimetype};if("key"in this.expression)return e("limebb-lime-query-filter-comparison",Object.assign({},i,{expression:this.expression,onExpressionChange:this.handleExpressionChange}));const t=l(this.expression);return t?e("limebb-lime-query-filter-group",Object.assign({},i,{expression:t,onExpressionChange:this.handleExpressionChange})):this.expression.op===o.NOT?e("limebb-lime-query-filter-not",Object.assign({},i,{expression:this.expression,onExpressionChange:this.handleExpressionChange})):void 0}};export{a as limebb_lime_query_filter_comparison,c as limebb_lime_query_filter_expression}
@@ -0,0 +1 @@
1
+ import{r as e,h as t,H as s,g as i}from"./p-DYpn0EkA.js";import{b as o}from"./p-BVxuJgRM.js";const h=class{constructor(t){e(this,t),this.shouldRender=!1}componentWillLoad(){this.compileAndEvaluate()}onRuleChange(){this.compileAndEvaluate()}onScopeChange(){this.compileAndEvaluate()}render(){return t(s,{key:"bb6a8a31d0694bfae30bfeb1644f5c21e69d53b5",hidden:!this.shouldRender},t("slot",{key:"492e995687b48971ad8c539749044677d79756ae"}))}get ruleRegistry(){return this.platform.get(o.RuleRegistry)}compileAndEvaluate(){var e;if(this.rule)try{const t=this.ruleRegistry.compile(this.rule),s=null!==(e=this.scope)&&void 0!==e?e:this.ruleRegistry.scope({host:this.host});this.shouldRender=t(s)}catch(e){console.warn("rule-gate failed to compile rule; hiding slot",{rule:this.rule,error:e}),this.shouldRender=!1}else this.shouldRender=!0}get host(){return i(this)}static get watchers(){return{rule:[{onRuleChange:0}],scope:[{onScopeChange:0}]}}};h.style=":host{display:block}:host([hidden]){display:none}";export{h as limebb_rule_gate}
@@ -1 +1 @@
1
- import{r as e,c as i,h as t}from"./p-DYpn0EkA.js";import{b as o}from"./p-CqRNpSRV.js";function r(e){for(const i of e.items)e.processedItems.push({type:"notification",item:i});return e}function n(e){const i=[];let t=e.newItemIndicatorInserted;for(const o of e.processedItems)"notification"===o.type&&e.lastVisitedTimestamp&&!t&&new Date(o.item.timestamp)<=e.lastVisitedTimestamp&&e.hasUnseenNotifications&&(i.push({type:"newItemIndicator"}),t=!0),i.push(o);return e.processedItems=i,e.newItemIndicatorInserted=t,e}function a(e){const i=[];let t=null,o=null;for(const r of e.processedItems)if("notification"===r.type){const n=new Date(r.item.timestamp),a=e.dateTimeFormatter.format(n,"date");a!==o&&(t&&i.push(t),t={type:"group",groupType:"dateGroup",heading:a,items:[]},o=a),t&&t.items.push(r)}else"newItemIndicator"===r.type&&(t?t.items.push(r):i.push(r));return t&&i.push(t),Object.assign(Object.assign({},e),{processedItems:i})}const s=class{constructor(t){e(this,t),this.itemClick=i(this,"itemClick"),this.items=[],this.processedItems=[],this.handleItemClick=e=>{this.itemClick.emit(e.detail)}}handleItemsChange(){let e=null;var i,t,o,s;this.lastVisitedTimestamp&&(e="string"==typeof(s=this.lastVisitedTimestamp)?new Date(Date.parse(s)):new Date(s)),this.processedItems=(o={items:i=this.items,processedItems:[],lastVisitedTimestamp:t=e,dateTimeFormatter:this.dateTimeFormatter,newItemIndicatorInserted:!1,lastProcessedDate:null,hasUnseenNotifications:i.some((e=>t&&new Date(e.timestamp)>t))},[r,n,a].reduce(((e,i)=>i(e)),o)).processedItems}componentWillLoad(){this.handleItemsChange()}render(){return[this.renderSpinner(),this.renderNotificationItems()]}renderSpinner(){if(this.loading)return t("limel-spinner",{size:"small"})}renderNotificationItems(){return this.processedItems.map((e=>{switch(e.type){case"group":return this.renderGroup(e);case"newItemIndicator":return this.renderIndicator();default:return null}}))}renderGroup(e){return t("section",{class:"date-group"},t("a",{class:"date-heading"},e.heading),e.items.map((e=>"notification"===e.type?this.renderNotificationItem(e.item):"newItemIndicator"===e.type?this.renderIndicator():void 0)))}renderNotificationItem(e){return t("limebb-notification-item",{platform:this.platform,context:this.context,item:e,key:e.id,onInteract:this.handleItemClick})}renderIndicator(){return t("div",{class:"new-items-indicator"},t("hr",null),t("h3",null,this.translator.get("webclient.new")))}get dateTimeFormatter(){return this.platform.get(o.DateTimeFormatter)}get translator(){return this.platform.get(o.Translate)}static get watchers(){return{items:[{handleItemsChange:0}]}}};s.style='@charset "UTF-8";:host(limebb-notification-list){--limebb-notification-list-background-color:var( --notification-list-background-color, rgb(var(--contrast-300)) );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( var(--color-red-default) );--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,limebb-notification-item.is-clickable:focus-visible{transform:translate3d(0, 0.01rem, 0);color:var(--limel-theme-on-surface-color);background-color:var(--lime-elevated-surface-background-color)}limebb-notification-item.is-clickable:hover{box-shadow:var(--button-shadow-hovered)}limebb-notification-item.is-clickable:active{--limel-clickable-transform-timing-function:cubic-bezier( 0.83, -0.15, 0.49, 1.16 );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)}';export{s as limebb_notification_list}
1
+ import{r as e,c as i,h as t}from"./p-DYpn0EkA.js";import{b as o}from"./p-BVxuJgRM.js";function r(e){for(const i of e.items)e.processedItems.push({type:"notification",item:i});return e}function n(e){const i=[];let t=e.newItemIndicatorInserted;for(const o of e.processedItems)"notification"===o.type&&e.lastVisitedTimestamp&&!t&&new Date(o.item.timestamp)<=e.lastVisitedTimestamp&&e.hasUnseenNotifications&&(i.push({type:"newItemIndicator"}),t=!0),i.push(o);return e.processedItems=i,e.newItemIndicatorInserted=t,e}function a(e){const i=[];let t=null,o=null;for(const r of e.processedItems)if("notification"===r.type){const n=new Date(r.item.timestamp),a=e.dateTimeFormatter.format(n,"date");a!==o&&(t&&i.push(t),t={type:"group",groupType:"dateGroup",heading:a,items:[]},o=a),t&&t.items.push(r)}else"newItemIndicator"===r.type&&(t?t.items.push(r):i.push(r));return t&&i.push(t),Object.assign(Object.assign({},e),{processedItems:i})}const s=class{constructor(t){e(this,t),this.itemClick=i(this,"itemClick"),this.items=[],this.processedItems=[],this.handleItemClick=e=>{this.itemClick.emit(e.detail)}}handleItemsChange(){let e=null;var i,t,o,s;this.lastVisitedTimestamp&&(e="string"==typeof(s=this.lastVisitedTimestamp)?new Date(Date.parse(s)):new Date(s)),this.processedItems=(o={items:i=this.items,processedItems:[],lastVisitedTimestamp:t=e,dateTimeFormatter:this.dateTimeFormatter,newItemIndicatorInserted:!1,lastProcessedDate:null,hasUnseenNotifications:i.some((e=>t&&new Date(e.timestamp)>t))},[r,n,a].reduce(((e,i)=>i(e)),o)).processedItems}componentWillLoad(){this.handleItemsChange()}render(){return[this.renderSpinner(),this.renderNotificationItems()]}renderSpinner(){if(this.loading)return t("limel-spinner",{size:"small"})}renderNotificationItems(){return this.processedItems.map((e=>{switch(e.type){case"group":return this.renderGroup(e);case"newItemIndicator":return this.renderIndicator();default:return null}}))}renderGroup(e){return t("section",{class:"date-group"},t("a",{class:"date-heading"},e.heading),e.items.map((e=>"notification"===e.type?this.renderNotificationItem(e.item):"newItemIndicator"===e.type?this.renderIndicator():void 0)))}renderNotificationItem(e){return t("limebb-notification-item",{platform:this.platform,context:this.context,item:e,key:e.id,onInteract:this.handleItemClick})}renderIndicator(){return t("div",{class:"new-items-indicator"},t("hr",null),t("h3",null,this.translator.get("webclient.new")))}get dateTimeFormatter(){return this.platform.get(o.DateTimeFormatter)}get translator(){return this.platform.get(o.Translate)}static get watchers(){return{items:[{handleItemsChange:0}]}}};s.style='@charset "UTF-8";:host(limebb-notification-list){--limebb-notification-list-background-color:var( --notification-list-background-color, rgb(var(--contrast-300)) );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( var(--color-red-default) );--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,limebb-notification-item.is-clickable:focus-visible{transform:translate3d(0, 0.01rem, 0);color:var(--limel-theme-on-surface-color);background-color:var(--lime-elevated-surface-background-color)}limebb-notification-item.is-clickable:hover{box-shadow:var(--button-shadow-hovered)}limebb-notification-item.is-clickable:active{--limel-clickable-transform-timing-function:cubic-bezier( 0.83, -0.15, 0.49, 1.16 );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)}';export{s as limebb_notification_list}
@@ -1 +1 @@
1
- import{r as e,h as r,H as t}from"./p-DYpn0EkA.js";const a=class{constructor(r){e(this,r),this.colors=[]}render(){return r(t,{key:"ae4e71ec4e2e6d45f5c112ba6b28e1a3a9e35d8b","aria-hidden":"true"},r("ol",{key:"e09bd29e6d5ab4ba2f20847e23108637d3e30f21"},this.colors.map(((e,t)=>r("li",{key:t,style:{backgroundColor:e}})))))}};a.style=":host(limebb-color-palette-swatches){pointer-events:none;transform:var(--color-palette-swatches-transform, unset);box-sizing:border-box;display:block;width:100%}*{box-sizing:border-box;min-width:0;min-height:0}ol{list-style:none;display:grid;grid-template-columns:repeat(auto-fit, minmax(0.75rem, 1fr));gap:var(--color-palette-swatches-gap, 0.25rem);margin:0;padding:var(--color-palette-swatches-gap, 0.25rem);border-radius:0.5rem}li{aspect-ratio:1;border-radius:0.25rem}";export{a as limebb_color_palette_swatches}
1
+ import{r as e,h as r,H as t}from"./p-DYpn0EkA.js";const a=class{constructor(r){e(this,r),this.colors=[]}render(){return r(t,{key:"1d22ab71b6c9ced22f667dc01bed168f43e7c0dc","aria-hidden":"true"},r("ol",{key:"91e83665cc5dda84a0c7ab385dd33347a5fd4262"},this.colors.map(((e,t)=>r("li",{key:t,style:{backgroundColor:e}})))))}};a.style=":host(limebb-color-palette-swatches){pointer-events:none;transform:var(--color-palette-swatches-transform, unset);box-sizing:border-box;display:block;width:100%}*{box-sizing:border-box;min-width:0;min-height:0}ol{list-style:none;display:grid;grid-template-columns:repeat(auto-fit, minmax(0.75rem, 1fr));gap:var(--color-palette-swatches-gap, 0.25rem);margin:0;padding:var(--color-palette-swatches-gap, 0.25rem);border-radius:0.5rem}li{aspect-ratio:1;border-radius:0.25rem}";export{a as limebb_color_palette_swatches}
@@ -1 +1 @@
1
- import{r as e,c as t,h as o}from"./p-DYpn0EkA.js";import{T as r,b as i}from"./p-CqRNpSRV.js";import{L as s}from"./p-BKtEmDNs.js";const a=class{constructor(o){e(this,o),this.negate=t(this,"negate"),this.updateArgs=t(this,"updateArgs"),this.deleteChip=t(this,"deleteChip"),this.isNegated=!1,this.readonly=!1,this.disabled=!1,this.isMutable=!0,this.focusOnOpen=!1,this.handleNegateChange=e=>{e.stopPropagation(),this.negate.emit(e.detail)},this.handleArgsChange=e=>{e.stopPropagation(),this.updateArgs.emit(e.detail)},this.handleDelete=()=>{this.deleteChip.emit()}}render(){return o("div",{key:"a395bf65b1868b0a440881f2c885c7bd9dc741d4",class:"popover"},this.renderHeader(),this.renderBody())}renderHeader(){var e,t,r,i;const s=(null===(e=this.metadata)||void 0===e?void 0:e.title)?this.translator.get(this.metadata.title):null!==(r=null===(t=this.refNode)||void 0===t?void 0:t.id)&&void 0!==r?r:"";return o("limel-header",{class:"popover__header is-narrow",heading:s,icon:null===(i=this.metadata)||void 0===i?void 0:i.icon},this.renderHeaderActions())}renderHeaderActions(){return this.isMutable?o("div",{slot:"actions",class:"popover__header-actions"},o("limel-switch",{class:"popover__negate-switch",label:this.translator.get("webclient.rule-editor.negate"),value:this.isNegated,onChange:this.handleNegateChange}),o("limel-icon-button",{class:"popover__delete-button",icon:"trash",label:this.translator.get("webclient.rule-editor.delete"),onClick:this.handleDelete})):null}get translator(){return this.platform.get(i.Translate)}renderBody(){var e,t;const r=null===(e=this.metadata)||void 0===e?void 0:e.configComponent;return r?o("div",{class:"popover__body"},o(s,{platform:this.platform,context:this.context,name:r.name,props:Object.assign(Object.assign({},r.props),{value:null===(t=this.refNode)||void 0===t?void 0:t.args,readonly:this.readonly,disabled:this.disabled,focusOnOpen:this.focusOnOpen,onChange:this.handleArgsChange})})):null}};(function(e,t,o,r){var i,s=arguments.length,a=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,o):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,o,r);else for(var n=e.length-1;n>=0;n--)(i=e[n])&&(a=(s<3?i(a):s>3?i(t,o,a):i(t,o))||a);s>3&&a&&Object.defineProperty(t,o,a)})([r("context")],a.prototype,"context",void 0),a.style=":host{display:block}.popover{display:flex;flex-direction:column;min-width:24rem;background-color:rgb(var(--contrast-100));border:1px solid rgb(var(--contrast-700));border-radius:0.5rem;box-shadow:0 0.25rem 0.75rem rgba(0, 0, 0, 0.15);overflow:hidden}.popover__header{--header-background-color:rgba(var(--contrast-300));padding-right:0.5rem;gap:1rem}.popover__header-actions{display:grid;grid-auto-flow:column;grid-gap:0.75rem;padding:0.25rem;align-items:center}.popover__delete-button{color:rgb(var(--contrast-1100))}.popover__body{padding:1rem}";export{a as limebb_rule_chip_popover}
1
+ import{r as e,c as t,h as o}from"./p-DYpn0EkA.js";import{T as r,b as i}from"./p-BVxuJgRM.js";import{L as s}from"./p-BKtEmDNs.js";const a=class{constructor(o){e(this,o),this.negate=t(this,"negate"),this.updateArgs=t(this,"updateArgs"),this.deleteChip=t(this,"deleteChip"),this.isNegated=!1,this.readonly=!1,this.disabled=!1,this.isMutable=!0,this.focusOnOpen=!1,this.handleNegateChange=e=>{e.stopPropagation(),this.negate.emit(e.detail)},this.handleArgsChange=e=>{e.stopPropagation(),this.updateArgs.emit(e.detail)},this.handleDelete=()=>{this.deleteChip.emit()}}render(){return o("div",{key:"1128e5c6da6e5ce3a3fd36eb9846eccd4b70e869",class:"popover"},this.renderHeader(),this.renderBody())}renderHeader(){var e,t,r,i;const s=(null===(e=this.metadata)||void 0===e?void 0:e.title)?this.translator.get(this.metadata.title):null!==(r=null===(t=this.refNode)||void 0===t?void 0:t.id)&&void 0!==r?r:"";return o("limel-header",{class:"popover__header is-narrow",heading:s,icon:null===(i=this.metadata)||void 0===i?void 0:i.icon},this.renderHeaderActions())}renderHeaderActions(){return this.isMutable?o("div",{slot:"actions",class:"popover__header-actions"},o("limel-switch",{class:"popover__negate-switch",label:this.translator.get("webclient.rule-editor.negate"),value:this.isNegated,onChange:this.handleNegateChange}),o("limel-icon-button",{class:"popover__delete-button",icon:"trash",label:this.translator.get("webclient.rule-editor.delete"),onClick:this.handleDelete})):null}get translator(){return this.platform.get(i.Translate)}renderBody(){var e,t;const r=null===(e=this.metadata)||void 0===e?void 0:e.configComponent;return r?o("div",{class:"popover__body"},o(s,{platform:this.platform,context:this.context,name:r.name,props:Object.assign(Object.assign({},r.props),{value:null===(t=this.refNode)||void 0===t?void 0:t.args,readonly:this.readonly,disabled:this.disabled,focusOnOpen:this.focusOnOpen,onChange:this.handleArgsChange})})):null}};(function(e,t,o,r){var i,s=arguments.length,a=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,o):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,o,r);else for(var n=e.length-1;n>=0;n--)(i=e[n])&&(a=(s<3?i(a):s>3?i(t,o,a):i(t,o))||a);s>3&&a&&Object.defineProperty(t,o,a)})([r("context")],a.prototype,"context",void 0),a.style=":host{display:block}.popover{display:flex;flex-direction:column;min-width:24rem;background-color:rgb(var(--contrast-100));border:1px solid rgb(var(--contrast-700));border-radius:0.5rem;box-shadow:0 0.25rem 0.75rem rgba(0, 0, 0, 0.15);overflow:hidden}.popover__header{--header-background-color:rgba(var(--contrast-300));padding-right:0.5rem;gap:1rem}.popover__header-actions{display:grid;grid-auto-flow:column;grid-gap:0.75rem;padding:0.25rem;align-items:center}.popover__delete-button{color:rgb(var(--contrast-1100))}.popover__body{padding:1rem}";export{a as limebb_rule_chip_popover}
@@ -1 +1 @@
1
- import{r as o,h as r,H as t}from"./p-DYpn0EkA.js";import{b as e}from"./p-CqRNpSRV.js";import{g as a,n as i}from"./p-Cg1DC15C.js";const s=class{constructor(t){o(this,t),this.suffix="%",this.reducePresence=!0,this.locale="en",this.labelId="a"+crypto.randomUUID(),this.tooltipId="a"+crypto.randomUUID(),this.helperTextId="a"+crypto.randomUUID(),this.renderHelperLine=()=>{if(this.hasHelperText())return r("limel-helper-line",{helperTextId:this.helperTextId,helperText:this.helperText,invalid:this.invalid})},this.hasHelperText=()=>null!=this.helperText}valueChanged(o){this.numValue=this.parseValue(o)}componentWillLoad(){try{this.locale=this.platform.get(e.UserPreferencesRepository).get("locale"),this.numberFormat=new Intl.NumberFormat(this.locale)}catch(o){console.warn(`Could not get user's locale (${this.locale}), falling back to 'en'.`),this.locale="en",this.numberFormat=new Intl.NumberFormat("en")}this.numValue=this.parseValue(this.value)}render(){return r(t,{key:"ea5709dccccd0ca07684bd221e7f5fe79b76dae4",class:this.getContainerClassList()},r("limel-notched-outline",{key:"952a07d4e934d589460a8848a52bad130f351cdf",id:this.tooltipId,label:this.label,labelId:this.labelId,invalid:this.invalid,required:this.required,hasValue:!0,hasFloatingLabel:!0,"aria-labelledby":this.labelId,"aria-describedby":this.helperTextId,"aria-controls":this.helperTextId},r("div",{key:"a620318b3edea23636d656654da65c9532b4a5f0",slot:"content",tabIndex:0},this.renderVisualization())),this.renderHelperLine(),this.renderTooltip())}renderVisualization(){if(!this.reducePresence||0!==this.numValue&&this.hasValue())return this.hasValue()?[this.getArrowIcon(),r("span",null,this.renderGrowthPercentage(),this.renderGrowthAmount())]:r("span",{class:"no-value"},"–")}renderTooltip(){if(void 0===this.formerValue)return;const o=`${this.value} - ${this.formerValue>0?this.formerValue:"("+this.formerValue+")"} = ${this.calculateGrowth()} ${this.suffix} `,t=this.calculatePercentage();return r("limel-tooltip",{openDirection:"top-start",elementId:this.tooltipId,label:t+"%",helperLabel:o})}renderGrowthPercentage(){if(void 0===this.formerValue)return this.formatValue(this.numValue,this.suffix);const o=this.calculatePercentage();return null!==o?this.formatValue(o,"%"):void 0}renderGrowthAmount(){if(void 0===this.formerValue)return;const o=this.calculateGrowth();return r("span",{class:"growth-unit"},"( ",this.formatValue(o,this.suffix)," )")}hasValue(){return null!=this.value&&""!==this.value}getContainerClassList(){if(!this.hasValue())return;const o=this.getPercentage(),r=a(o);return Object.assign({},r&&{[r]:!0})}getPercentage(){return void 0===this.formerValue?this.numValue:this.calculatePercentage()}calculateGrowth(){return this.numValue-this.formerValue}calculatePercentage(){if(0===this.formerValue)return null;const o=((this.numValue-this.formerValue)/Math.abs(this.formerValue)*100).toFixed(2);return Number.parseFloat(o)}unifyMinusSign(o){return o.replaceAll("−","-")}convertToUnicodeMinus(o){return o.replaceAll("-","−")}parseValue(o){return"string"==typeof o?Number.parseFloat(i(this.unifyMinusSign(o),this.locale)):o}formatValue(o,r){const t=`${this.numberFormat.format(o)} ${r}`;return o>0?"+"+t:this.convertToUnicodeMinus(t)}getArrowIcon(){return r("limel-icon",{class:"icon",name:"right","aria-hidden":"true",role:"presentation"})}static get watchers(){return{value:[{valueChanged:0}]}}};s.style='@charset "UTF-8";*{box-sizing:border-box}:host(limebb-trend-indicator){position:relative;display:block;height:100%;width:100%}limel-notched-outline:not([invalid]:not([invalid=false])) .limel-notched-outline--outlines{--limel-notched-outline-border-color:transparent}div[slot=content]{display:flex;align-items:center;gap:0.5rem;border-radius:inherit;background-color:transparent !important}div[slot=content]:focus{outline:none}div[slot=content]:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}:host(limebb-trend-indicator):has(label) div[slot=content]{min-height:2.5rem;padding:0 0.375rem 0 1rem}:host(limebb-trend-indicator[former-value]) div[slot=content]{cursor:help}div[slot=content] span{flex-shrink:0}.icon{flex-shrink:0;display:flex;transition-property:color, background-color, transform;transition-duration:0.4s;transition-timing-function:ease;width:1.25rem;height:1.25rem;border-radius:50%;padding:0.12rem;color:rgb(var(--color-white));background-color:rgb(var(--color-gray-default), 0.5)}:host(.has-value-40to30-negative) .icon{color:rgb(var(--color-gray-darker))}:host(.has-value-30to20-negative) .icon{color:rgb(var(--color-gray-darker))}:host(.has-value-20to10-negative) .icon{color:rgb(var(--color-gray-darker))}:host(.has-value-10to0-negative) .icon{color:rgb(var(--color-gray-darker))}:host(.has-value-0to10-positive) .icon{color:rgb(var(--color-gray-dark))}:host(.has-value-10to20-positive) .icon{color:rgb(var(--color-gray-dark))}:host(.has-value-20to30-positive) .icon{color:rgb(var(--color-gray-dark))}:host(.has-value-30to40-positive) .icon{color:rgb(var(--color-gray-dark))}:host(.has-value-200or-larger-negative) .icon{background-color:rgb(var(--color-red-darker));transform:rotate(90deg)}:host(.has-value-200to100-negative) .icon{background-color:rgb(var(--color-red-dark));transform:rotate(90deg)}:host(.has-value-100to90-negative) .icon{background-color:rgb(var(--color-red-dark));transform:rotate(90deg)}:host(.has-value-90to80-negative) .icon{background-color:rgb(var(--color-red-dark));transform:rotate(81deg)}:host(.has-value-80to70-negative) .icon{background-color:rgb(var(--color-red-default));transform:rotate(72deg)}:host(.has-value-70to60-negative) .icon{background-color:rgb(var(--color-red-default));transform:rotate(63deg)}:host(.has-value-60to50-negative) .icon{background-color:rgb(var(--color-coral-default));transform:rotate(54deg)}:host(.has-value-50to40-negative) .icon{background-color:rgb(var(--color-coral-default));transform:rotate(45deg)}:host(.has-value-40to30-negative) .icon{background-color:rgb(var(--color-orange-default));transform:rotate(36deg)}:host(.has-value-30to20-negative) .icon{background-color:rgb(var(--color-orange-default));transform:rotate(27deg)}:host(.has-value-20to10-negative) .icon{background-color:rgb(var(--color-amber-default));transform:rotate(18deg)}:host(.has-value-10to0-negative) .icon{background-color:rgb(var(--color-amber-default));transform:rotate(9deg)}:host(.has-value-0) .icon{background-color:rgb(var(--color-gray-default));transform:rotate(0deg)}:host(.has-value-0to10-positive) .icon{background-color:rgb(var(--color-yellow-default));transform:rotate(-9deg)}:host(.has-value-10to20-positive) .icon{background-color:rgb(var(--color-yellow-default));transform:rotate(-18deg)}:host(.has-value-20to30-positive) .icon{background-color:rgb(var(--color-grass-default));transform:rotate(-27deg)}:host(.has-value-30to40-positive) .icon{background-color:rgb(var(--color-grass-default));transform:rotate(-36deg)}:host(.has-value-40to50-positive) .icon{background-color:rgb(var(--color-lime-default));transform:rotate(-45deg)}:host(.has-value-50to60-positive) .icon{background-color:rgb(var(--color-lime-default));transform:rotate(-54deg)}:host(.has-value-60to70-positive) .icon{background-color:rgb(var(--color-teal-default));transform:rotate(-63deg)}:host(.has-value-70to80-positive) .icon{background-color:rgb(var(--color-teal-default));transform:rotate(-72deg)}:host(.has-value-80to90-positive) .icon{background-color:rgb(var(--color-teal-dark));transform:rotate(-81deg)}:host(.has-value-90to100-positive) .icon{background-color:rgb(var(--color-teal-dark));transform:rotate(-90deg)}:host(.has-value-100to200-positive) .icon{background-color:rgb(var(--color-teal-dark));transform:rotate(-90deg)}:host(.has-value-200or-larger-positive) .icon{background-color:rgb(var(--color-teal-darker));transform:rotate(-90deg)}:host(.has-value-0) .icon{background-color:rgb(var(--color-gray-default), 0.5);transform:rotate(0deg)}:host(.has-value-0) .icon polyline{color:transparent}:host(.has-value-200or-larger-negative) .icon:after,:host(.has-value-200or-larger-negative) .icon:before,:host(.has-value-200to100-negative) .icon:after,:host(.has-value-200to100-negative) .icon:before,:host(.has-value-100to200-positive) .icon:after,:host(.has-value-100to200-positive) .icon:before,:host(.has-value-200or-larger-positive) .icon:after,:host(.has-value-200or-larger-positive) .icon:before{transition:border-color 0.6s ease;content:"";position:absolute;inset:0;margin:auto;border:1px solid transparent;border-radius:50%}:host(.has-value-200or-larger-negative) .icon:before,:host(.has-value-200to100-negative) .icon:before,:host(.has-value-100to200-positive) .icon:before,:host(.has-value-200or-larger-positive) .icon:before{transform:scale(1.2)}:host(.has-value-200or-larger-negative) .icon:after,:host(.has-value-200to100-negative) .icon:after,:host(.has-value-100to200-positive) .icon:after,:host(.has-value-200or-larger-positive) .icon:after{transform:scale(1.4);opacity:0.4}:host(.has-value-200to100-negative) .icon:before,:host(.has-value-200or-larger-negative) .icon:before{border-color:rgb(var(--color-red-dark))}:host(.has-value-200or-larger-negative) .icon:after{border-color:rgb(var(--color-red-darker))}:host(.has-value-100to200-positive) .icon:before,:host(.has-value-200or-larger-positive) .icon:before{border-color:rgb(var(--color-teal-dark))}:host(.has-value-200or-larger-positive) .icon:after{border-color:rgb(var(--color-teal-darker))}.no-value{transform:translateY(0.5rem)}.growth-unit{padding-left:0.5rem;opacity:0.5}:host(limebb-trend-indicator:focus),:host(limebb-trend-indicator:focus-visible),:host(limebb-trend-indicator:focus-within){--limel-h-l-grid-template-rows-transition-speed:0.46s;--limel-h-l-grid-template-rows:1fr}:host(limebb-trend-indicator){--limel-h-l-grid-template-rows-transition-speed:0.3s;--limel-h-l-grid-template-rows:0fr}:host(limebb-trend-indicator:focus) limel-helper-line,:host(limebb-trend-indicator:focus-visible) limel-helper-line,:host(limebb-trend-indicator:focus-within) limel-helper-line,:host(limebb-trend-indicator:hover) limel-helper-line{will-change:grid-template-rows}';export{s as limebb_trend_indicator}
1
+ import{r as o,h as r,H as t}from"./p-DYpn0EkA.js";import{b as e}from"./p-BVxuJgRM.js";import{g as a,n as i}from"./p-Cg1DC15C.js";const s=class{constructor(t){o(this,t),this.suffix="%",this.reducePresence=!0,this.locale="en",this.labelId="a"+crypto.randomUUID(),this.tooltipId="a"+crypto.randomUUID(),this.helperTextId="a"+crypto.randomUUID(),this.renderHelperLine=()=>{if(this.hasHelperText())return r("limel-helper-line",{helperTextId:this.helperTextId,helperText:this.helperText,invalid:this.invalid})},this.hasHelperText=()=>null!=this.helperText}valueChanged(o){this.numValue=this.parseValue(o)}componentWillLoad(){try{this.locale=this.platform.get(e.UserPreferencesRepository).get("locale"),this.numberFormat=new Intl.NumberFormat(this.locale)}catch(o){console.warn(`Could not get user's locale (${this.locale}), falling back to 'en'.`),this.locale="en",this.numberFormat=new Intl.NumberFormat("en")}this.numValue=this.parseValue(this.value)}render(){return r(t,{key:"156ed22ec35266d2c298ba60bec7edeaecaae4c4",class:this.getContainerClassList()},r("limel-notched-outline",{key:"dff7957aa5e286373ab29a9cda30cab982fecebc",id:this.tooltipId,label:this.label,labelId:this.labelId,invalid:this.invalid,required:this.required,hasValue:!0,hasFloatingLabel:!0,"aria-labelledby":this.labelId,"aria-describedby":this.helperTextId,"aria-controls":this.helperTextId},r("div",{key:"86b950603fd262cffc074a1020a7231e04979470",slot:"content",tabIndex:0},this.renderVisualization())),this.renderHelperLine(),this.renderTooltip())}renderVisualization(){if(!this.reducePresence||0!==this.numValue&&this.hasValue())return this.hasValue()?[this.getArrowIcon(),r("span",null,this.renderGrowthPercentage(),this.renderGrowthAmount())]:r("span",{class:"no-value"},"–")}renderTooltip(){if(void 0===this.formerValue)return;const o=`${this.value} - ${this.formerValue>0?this.formerValue:"("+this.formerValue+")"} = ${this.calculateGrowth()} ${this.suffix} `,t=this.calculatePercentage();return r("limel-tooltip",{openDirection:"top-start",elementId:this.tooltipId,label:t+"%",helperLabel:o})}renderGrowthPercentage(){if(void 0===this.formerValue)return this.formatValue(this.numValue,this.suffix);const o=this.calculatePercentage();return null!==o?this.formatValue(o,"%"):void 0}renderGrowthAmount(){if(void 0===this.formerValue)return;const o=this.calculateGrowth();return r("span",{class:"growth-unit"},"( ",this.formatValue(o,this.suffix)," )")}hasValue(){return null!=this.value&&""!==this.value}getContainerClassList(){if(!this.hasValue())return;const o=this.getPercentage(),r=a(o);return Object.assign({},r&&{[r]:!0})}getPercentage(){return void 0===this.formerValue?this.numValue:this.calculatePercentage()}calculateGrowth(){return this.numValue-this.formerValue}calculatePercentage(){if(0===this.formerValue)return null;const o=((this.numValue-this.formerValue)/Math.abs(this.formerValue)*100).toFixed(2);return Number.parseFloat(o)}unifyMinusSign(o){return o.replaceAll("−","-")}convertToUnicodeMinus(o){return o.replaceAll("-","−")}parseValue(o){return"string"==typeof o?Number.parseFloat(i(this.unifyMinusSign(o),this.locale)):o}formatValue(o,r){const t=`${this.numberFormat.format(o)} ${r}`;return o>0?"+"+t:this.convertToUnicodeMinus(t)}getArrowIcon(){return r("limel-icon",{class:"icon",name:"right","aria-hidden":"true",role:"presentation"})}static get watchers(){return{value:[{valueChanged:0}]}}};s.style='@charset "UTF-8";*{box-sizing:border-box}:host(limebb-trend-indicator){position:relative;display:block;height:100%;width:100%}limel-notched-outline:not([invalid]:not([invalid=false])) .limel-notched-outline--outlines{--limel-notched-outline-border-color:transparent}div[slot=content]{display:flex;align-items:center;gap:0.5rem;border-radius:inherit;background-color:transparent !important}div[slot=content]:focus{outline:none}div[slot=content]:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}:host(limebb-trend-indicator):has(label) div[slot=content]{min-height:2.5rem;padding:0 0.375rem 0 1rem}:host(limebb-trend-indicator[former-value]) div[slot=content]{cursor:help}div[slot=content] span{flex-shrink:0}.icon{flex-shrink:0;display:flex;transition-property:color, background-color, transform;transition-duration:0.4s;transition-timing-function:ease;width:1.25rem;height:1.25rem;border-radius:50%;padding:0.12rem;color:rgb(var(--color-white));background-color:rgb(var(--color-gray-default), 0.5)}:host(.has-value-40to30-negative) .icon{color:rgb(var(--color-gray-darker))}:host(.has-value-30to20-negative) .icon{color:rgb(var(--color-gray-darker))}:host(.has-value-20to10-negative) .icon{color:rgb(var(--color-gray-darker))}:host(.has-value-10to0-negative) .icon{color:rgb(var(--color-gray-darker))}:host(.has-value-0to10-positive) .icon{color:rgb(var(--color-gray-dark))}:host(.has-value-10to20-positive) .icon{color:rgb(var(--color-gray-dark))}:host(.has-value-20to30-positive) .icon{color:rgb(var(--color-gray-dark))}:host(.has-value-30to40-positive) .icon{color:rgb(var(--color-gray-dark))}:host(.has-value-200or-larger-negative) .icon{background-color:rgb(var(--color-red-darker));transform:rotate(90deg)}:host(.has-value-200to100-negative) .icon{background-color:rgb(var(--color-red-dark));transform:rotate(90deg)}:host(.has-value-100to90-negative) .icon{background-color:rgb(var(--color-red-dark));transform:rotate(90deg)}:host(.has-value-90to80-negative) .icon{background-color:rgb(var(--color-red-dark));transform:rotate(81deg)}:host(.has-value-80to70-negative) .icon{background-color:rgb(var(--color-red-default));transform:rotate(72deg)}:host(.has-value-70to60-negative) .icon{background-color:rgb(var(--color-red-default));transform:rotate(63deg)}:host(.has-value-60to50-negative) .icon{background-color:rgb(var(--color-coral-default));transform:rotate(54deg)}:host(.has-value-50to40-negative) .icon{background-color:rgb(var(--color-coral-default));transform:rotate(45deg)}:host(.has-value-40to30-negative) .icon{background-color:rgb(var(--color-orange-default));transform:rotate(36deg)}:host(.has-value-30to20-negative) .icon{background-color:rgb(var(--color-orange-default));transform:rotate(27deg)}:host(.has-value-20to10-negative) .icon{background-color:rgb(var(--color-amber-default));transform:rotate(18deg)}:host(.has-value-10to0-negative) .icon{background-color:rgb(var(--color-amber-default));transform:rotate(9deg)}:host(.has-value-0) .icon{background-color:rgb(var(--color-gray-default));transform:rotate(0deg)}:host(.has-value-0to10-positive) .icon{background-color:rgb(var(--color-yellow-default));transform:rotate(-9deg)}:host(.has-value-10to20-positive) .icon{background-color:rgb(var(--color-yellow-default));transform:rotate(-18deg)}:host(.has-value-20to30-positive) .icon{background-color:rgb(var(--color-grass-default));transform:rotate(-27deg)}:host(.has-value-30to40-positive) .icon{background-color:rgb(var(--color-grass-default));transform:rotate(-36deg)}:host(.has-value-40to50-positive) .icon{background-color:rgb(var(--color-lime-default));transform:rotate(-45deg)}:host(.has-value-50to60-positive) .icon{background-color:rgb(var(--color-lime-default));transform:rotate(-54deg)}:host(.has-value-60to70-positive) .icon{background-color:rgb(var(--color-teal-default));transform:rotate(-63deg)}:host(.has-value-70to80-positive) .icon{background-color:rgb(var(--color-teal-default));transform:rotate(-72deg)}:host(.has-value-80to90-positive) .icon{background-color:rgb(var(--color-teal-dark));transform:rotate(-81deg)}:host(.has-value-90to100-positive) .icon{background-color:rgb(var(--color-teal-dark));transform:rotate(-90deg)}:host(.has-value-100to200-positive) .icon{background-color:rgb(var(--color-teal-dark));transform:rotate(-90deg)}:host(.has-value-200or-larger-positive) .icon{background-color:rgb(var(--color-teal-darker));transform:rotate(-90deg)}:host(.has-value-0) .icon{background-color:rgb(var(--color-gray-default), 0.5);transform:rotate(0deg)}:host(.has-value-0) .icon polyline{color:transparent}:host(.has-value-200or-larger-negative) .icon:after,:host(.has-value-200or-larger-negative) .icon:before,:host(.has-value-200to100-negative) .icon:after,:host(.has-value-200to100-negative) .icon:before,:host(.has-value-100to200-positive) .icon:after,:host(.has-value-100to200-positive) .icon:before,:host(.has-value-200or-larger-positive) .icon:after,:host(.has-value-200or-larger-positive) .icon:before{transition:border-color 0.6s ease;content:"";position:absolute;inset:0;margin:auto;border:1px solid transparent;border-radius:50%}:host(.has-value-200or-larger-negative) .icon:before,:host(.has-value-200to100-negative) .icon:before,:host(.has-value-100to200-positive) .icon:before,:host(.has-value-200or-larger-positive) .icon:before{transform:scale(1.2)}:host(.has-value-200or-larger-negative) .icon:after,:host(.has-value-200to100-negative) .icon:after,:host(.has-value-100to200-positive) .icon:after,:host(.has-value-200or-larger-positive) .icon:after{transform:scale(1.4);opacity:0.4}:host(.has-value-200to100-negative) .icon:before,:host(.has-value-200or-larger-negative) .icon:before{border-color:rgb(var(--color-red-dark))}:host(.has-value-200or-larger-negative) .icon:after{border-color:rgb(var(--color-red-darker))}:host(.has-value-100to200-positive) .icon:before,:host(.has-value-200or-larger-positive) .icon:before{border-color:rgb(var(--color-teal-dark))}:host(.has-value-200or-larger-positive) .icon:after{border-color:rgb(var(--color-teal-darker))}.no-value{transform:translateY(0.5rem)}.growth-unit{padding-left:0.5rem;opacity:0.5}:host(limebb-trend-indicator:focus),:host(limebb-trend-indicator:focus-visible),:host(limebb-trend-indicator:focus-within){--limel-h-l-grid-template-rows-transition-speed:0.46s;--limel-h-l-grid-template-rows:1fr}:host(limebb-trend-indicator){--limel-h-l-grid-template-rows-transition-speed:0.3s;--limel-h-l-grid-template-rows:0fr}:host(limebb-trend-indicator:focus) limel-helper-line,:host(limebb-trend-indicator:focus-visible) limel-helper-line,:host(limebb-trend-indicator:focus-within) limel-helper-line,:host(limebb-trend-indicator:hover) limel-helper-line{will-change:grid-template-rows}';export{s as limebb_trend_indicator}
@@ -1 +1 @@
1
- import{r as e,h as i}from"./p-DYpn0EkA.js";import{G as t,R as r,b as l}from"./p-CqRNpSRV.js";import{g as o}from"./p-Bcm94u_z.js";import{n as s}from"./p-ooVD-6_a.js";const n=["pdf","edit","view"];var c=function(e,i,t,r){var l,o=arguments.length,s=o<3?i:null===r?r=Object.getOwnPropertyDescriptor(i,t):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,i,t,r);else for(var n=e.length-1;n>=0;n--)(l=e[n])&&(s=(o<3?l(s):o>3?l(i,t,s):l(i,t))||s);return o>3&&s&&Object.defineProperty(i,t,s),s};const a=class{constructor(t){e(this,t),this.fileTypes=["view","contents","download"],this.renderLiveDocs=e=>{if(!this.isLiveDocsAvailable(e))return i("limebb-live-docs-info",null);if(!this.platform.isFeatureEnabled("useOfficeFilePreview"))return i("limebb-empty-state",{value:"Preview of this file type will be available soon",icon:{name:"attention",color:"rgb(var(--color-blue-light))"}});const t=this.getLiveDocsUrl(e);return i("iframe",{src:t,frameBorder:0,marginHeight:0,marginWidth:0})},this.renderFileViewer=e=>{const t=e.filename,r=this.getFileUrl(e);return r?i("limel-file-viewer",{filename:t,url:r,allowFullscreen:!0,allowOpenInNewTab:!0}):this.renderNotFound()},this.renderUnsupported=e=>i("limel-file-viewer",{filename:e.filename,url:void 0,allowFullscreen:!0,allowOpenInNewTab:!0}),this.renderNotFound=()=>[i("section",{class:"not-found"},i("limel-icon",{name:"error",size:"large"}),i("h2",null,this.translator.get("webclient.not-found")),i("p",null,this.translator.get("webclient.no-files-attached",{object:this.getDescriptive(this.limeobject)})))]}render(){const e=this.getFile();if(!e)return this.renderNotFound();const i=o(e.extension);return(0,{fileViewer:this.renderFileViewer,browser:this.renderFileViewer,sharepoint:this.renderLiveDocs,unsupported:this.renderUnsupported}[i])(e)}getLiveDocsUrl(e){let i=[...this.fileTypes];return this.platform.isFeatureEnabled("useOfficeFilePreview")&&(i=["pdf",...i]),i.filter(this.isLiveDocsType).map((i=>e.getUrl(i))).find(Boolean)}getFileUrl(e){return this.fileTypes.filter(s(this.isLiveDocsType)).map((i=>e.getUrl(i))).find(Boolean)}getFile(){const e=this.fileProperty;if(e)return this.limeobject.getFile(e.name)}isLiveDocsAvailable(e){return n.some((i=>e.getUrl(i)))}isLiveDocsType(e){return n.includes(e)}getDescriptive(e){var i;return(null==e?void 0:e.descriptive)||(null===(i=this.limetype)||void 0===i?void 0:i.localname.singular)||this.translator.get("object")}get fileProperty(){if(this.limeobject){if(this.property){const e=this.limeobject.getLimetype().getProperty(this.property);if("file"===e.type)return e}return Object.values(this.limeobject.getLimetype().properties).find((e=>"file"===e.type))}}get translator(){return this.platform.get(l.Translate)}};c([t()],a.prototype,"limeobject",void 0),c([r()],a.prototype,"limetype",void 0),a.style=".not-found{display:flex;flex-direction:column;height:100%;align-items:center;justify-content:center;line-height:1rem;color:rgb(var(--contrast-1100))}.not-found limel-icon{color:rgb(var(--color-red-default))}iframe{height:100%;width:100%}";export{a as limebb_limeobject_file_viewer}
1
+ import{r as e,h as i}from"./p-DYpn0EkA.js";import{G as t,R as r,b as l}from"./p-BVxuJgRM.js";import{g as o}from"./p-Bcm94u_z.js";import{n as s}from"./p-ooVD-6_a.js";const n=["pdf","edit","view"];var c=function(e,i,t,r){var l,o=arguments.length,s=o<3?i:null===r?r=Object.getOwnPropertyDescriptor(i,t):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,i,t,r);else for(var n=e.length-1;n>=0;n--)(l=e[n])&&(s=(o<3?l(s):o>3?l(i,t,s):l(i,t))||s);return o>3&&s&&Object.defineProperty(i,t,s),s};const a=class{constructor(t){e(this,t),this.fileTypes=["view","contents","download"],this.renderLiveDocs=e=>{if(!this.isLiveDocsAvailable(e))return i("limebb-live-docs-info",null);if(!this.platform.isFeatureEnabled("useOfficeFilePreview"))return i("limebb-empty-state",{value:"Preview of this file type will be available soon",icon:{name:"attention",color:"rgb(var(--color-blue-light))"}});const t=this.getLiveDocsUrl(e);return i("iframe",{src:t,frameBorder:0,marginHeight:0,marginWidth:0})},this.renderFileViewer=e=>{const t=e.filename,r=this.getFileUrl(e);return r?i("limel-file-viewer",{filename:t,url:r,allowFullscreen:!0,allowOpenInNewTab:!0}):this.renderNotFound()},this.renderUnsupported=e=>i("limel-file-viewer",{filename:e.filename,url:void 0,allowFullscreen:!0,allowOpenInNewTab:!0}),this.renderNotFound=()=>[i("section",{class:"not-found"},i("limel-icon",{name:"error",size:"large"}),i("h2",null,this.translator.get("webclient.not-found")),i("p",null,this.translator.get("webclient.no-files-attached",{object:this.getDescriptive(this.limeobject)})))]}render(){const e=this.getFile();if(!e)return this.renderNotFound();const i=o(e.extension);return(0,{fileViewer:this.renderFileViewer,browser:this.renderFileViewer,sharepoint:this.renderLiveDocs,unsupported:this.renderUnsupported}[i])(e)}getLiveDocsUrl(e){let i=[...this.fileTypes];return this.platform.isFeatureEnabled("useOfficeFilePreview")&&(i=["pdf",...i]),i.filter(this.isLiveDocsType).map((i=>e.getUrl(i))).find(Boolean)}getFileUrl(e){return this.fileTypes.filter(s(this.isLiveDocsType)).map((i=>e.getUrl(i))).find(Boolean)}getFile(){const e=this.fileProperty;if(e)return this.limeobject.getFile(e.name)}isLiveDocsAvailable(e){return n.some((i=>e.getUrl(i)))}isLiveDocsType(e){return n.includes(e)}getDescriptive(e){var i;return(null==e?void 0:e.descriptive)||(null===(i=this.limetype)||void 0===i?void 0:i.localname.singular)||this.translator.get("object")}get fileProperty(){if(this.limeobject){if(this.property){const e=this.limeobject.getLimetype().getProperty(this.property);if("file"===e.type)return e}return Object.values(this.limeobject.getLimetype().properties).find((e=>"file"===e.type))}}get translator(){return this.platform.get(l.Translate)}};c([t()],a.prototype,"limeobject",void 0),c([r()],a.prototype,"limetype",void 0),a.style=".not-found{display:flex;flex-direction:column;height:100%;align-items:center;justify-content:center;line-height:1rem;color:rgb(var(--contrast-1100))}.not-found limel-icon{color:rgb(var(--color-red-default))}iframe{height:100%;width:100%}";export{a as limebb_limeobject_file_viewer}