nestlens 0.5.1 → 0.6.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 (258) hide show
  1. package/dist/api/dashboard.controller.d.ts +7 -0
  2. package/dist/api/dashboard.controller.d.ts.map +1 -1
  3. package/dist/api/dashboard.controller.js +21 -1
  4. package/dist/api/dashboard.controller.js.map +1 -1
  5. package/dist/api/route-path.d.ts +14 -0
  6. package/dist/api/route-path.d.ts.map +1 -0
  7. package/dist/api/route-path.js +29 -0
  8. package/dist/api/route-path.js.map +1 -0
  9. package/dist/dashboard/public/assets/{BatchesPage-Mw30dmK6.js → BatchesPage-49gOGnzu.js} +1 -1
  10. package/dist/dashboard/public/assets/{CachePage-Csd_wBNd.js → CachePage-ov2Ag-N9.js} +1 -1
  11. package/dist/dashboard/public/assets/{ClickableBadge-D2hks1Oq.js → ClickableBadge-DYNLPtLq.js} +1 -1
  12. package/dist/dashboard/public/assets/{CommandsPage-Dea7woCG.js → CommandsPage-mpPr6q9X.js} +1 -1
  13. package/dist/dashboard/public/assets/{DashboardPage-NZfBMveD.js → DashboardPage-DOdstR4a.js} +1 -1
  14. package/dist/dashboard/public/assets/{DumpsPage-DVu-4BfV.js → DumpsPage-CQ_vpUE8.js} +1 -1
  15. package/dist/dashboard/public/assets/{EntryDetailPage-DWvKZcha.js → EntryDetailPage-CxL10HuU.js} +1 -1
  16. package/dist/dashboard/public/assets/{EntrySearchInput-CK8uj0H9.js → EntrySearchInput-DaH1CLjl.js} +1 -1
  17. package/dist/dashboard/public/assets/{EventsPage-GSA39EzN.js → EventsPage-Di57VeHM.js} +1 -1
  18. package/dist/dashboard/public/assets/{ExceptionsPage-CmaaycMZ.js → ExceptionsPage-C9DcC4-2.js} +1 -1
  19. package/dist/dashboard/public/assets/{GatesPage-BMJJxmed.js → GatesPage-DBgWv2nS.js} +1 -1
  20. package/dist/dashboard/public/assets/{GraphQLPage-bpEEWC54.js → GraphQLPage-D8DcycD9.js} +1 -1
  21. package/dist/dashboard/public/assets/{HttpClientPage-CuiSpSP1.js → HttpClientPage-PTrP2EjP.js} +1 -1
  22. package/dist/dashboard/public/assets/{JobsPage-iCMPR5ug.js → JobsPage-CraSw8O9.js} +1 -1
  23. package/dist/dashboard/public/assets/{LogsPage-Qmpj9Mj0.js → LogsPage-7ZGkLuX9.js} +1 -1
  24. package/dist/dashboard/public/assets/{MailPage-Bp-iCc8U.js → MailPage-dQoSJAY3.js} +1 -1
  25. package/dist/dashboard/public/assets/{ModelsPage-DG4Nuhwi.js → ModelsPage-CKkb6PGt.js} +1 -1
  26. package/dist/dashboard/public/assets/{NotificationsPage-qr-hjqWi.js → NotificationsPage-CuTXZ1qY.js} +1 -1
  27. package/dist/dashboard/public/assets/{PageHeader-D5bOCFIP.js → PageHeader-q5aVtQHw.js} +1 -1
  28. package/dist/dashboard/public/assets/{QueriesPage-BGK5GTNL.js → QueriesPage-CM4NansM.js} +1 -1
  29. package/dist/dashboard/public/assets/{RedisPage-dSaJayP0.js → RedisPage-C9y6TuoK.js} +1 -1
  30. package/dist/dashboard/public/assets/{RequestsPage-bUmD379S.js → RequestsPage-Cxnqol-x.js} +1 -1
  31. package/dist/dashboard/public/assets/{SchedulePage-DNmNxHDK.js → SchedulePage-Cp3ecH0l.js} +1 -1
  32. package/dist/dashboard/public/assets/{ViewsPage-BkQuW4hD.js → ViewsPage-BG8omC5C.js} +1 -1
  33. package/dist/dashboard/public/assets/{calendar-Cei8GX4-.js → calendar-CjIUfRxv.js} +1 -1
  34. package/dist/dashboard/public/assets/{circle-check-big-CJgtCXaK.js → circle-check-big-DDApLrDE.js} +1 -1
  35. package/dist/dashboard/public/assets/{eye-CBVB8boI.js → eye-csDSrPe6.js} +1 -1
  36. package/dist/dashboard/public/assets/index-TmiQivGf.js +361 -0
  37. package/dist/dashboard/public/assets/{search-DQ8xACgM.js → search-DS3CEfeI.js} +1 -1
  38. package/dist/dashboard/public/assets/{types-P3vOygE2.js → types-DcORDHhK.js} +3 -3
  39. package/dist/dashboard/public/assets/{zap-C8uvyhpc.js → zap-DEs_rIzA.js} +1 -1
  40. package/dist/dashboard/public/index.html +4 -4
  41. package/dist/nestlens.module.d.ts +12 -0
  42. package/dist/nestlens.module.d.ts.map +1 -1
  43. package/dist/nestlens.module.js +26 -0
  44. package/dist/nestlens.module.js.map +1 -1
  45. package/package.json +3 -3
  46. package/dist/__tests__/api/api.controller.spec.d.ts +0 -2
  47. package/dist/__tests__/api/api.controller.spec.d.ts.map +0 -1
  48. package/dist/__tests__/api/api.controller.spec.js +0 -871
  49. package/dist/__tests__/api/api.controller.spec.js.map +0 -1
  50. package/dist/__tests__/api/api.guard.spec.d.ts +0 -2
  51. package/dist/__tests__/api/api.guard.spec.d.ts.map +0 -1
  52. package/dist/__tests__/api/api.guard.spec.js +0 -545
  53. package/dist/__tests__/api/api.guard.spec.js.map +0 -1
  54. package/dist/__tests__/api/dashboard.controller.spec.d.ts +0 -2
  55. package/dist/__tests__/api/dashboard.controller.spec.d.ts.map +0 -1
  56. package/dist/__tests__/api/dashboard.controller.spec.js +0 -159
  57. package/dist/__tests__/api/dashboard.controller.spec.js.map +0 -1
  58. package/dist/__tests__/api/nestlens-validation.pipe.spec.d.ts +0 -2
  59. package/dist/__tests__/api/nestlens-validation.pipe.spec.d.ts.map +0 -1
  60. package/dist/__tests__/api/nestlens-validation.pipe.spec.js +0 -73
  61. package/dist/__tests__/api/nestlens-validation.pipe.spec.js.map +0 -1
  62. package/dist/__tests__/api/tag.controller.spec.d.ts +0 -2
  63. package/dist/__tests__/api/tag.controller.spec.d.ts.map +0 -1
  64. package/dist/__tests__/api/tag.controller.spec.js +0 -280
  65. package/dist/__tests__/api/tag.controller.spec.js.map +0 -1
  66. package/dist/__tests__/collector.service.spec.d.ts +0 -2
  67. package/dist/__tests__/collector.service.spec.d.ts.map +0 -1
  68. package/dist/__tests__/collector.service.spec.js +0 -240
  69. package/dist/__tests__/collector.service.spec.js.map +0 -1
  70. package/dist/__tests__/core/collector.service.spec.d.ts +0 -2
  71. package/dist/__tests__/core/collector.service.spec.d.ts.map +0 -1
  72. package/dist/__tests__/core/collector.service.spec.js +0 -517
  73. package/dist/__tests__/core/collector.service.spec.js.map +0 -1
  74. package/dist/__tests__/core/family-hash.service.spec.d.ts +0 -2
  75. package/dist/__tests__/core/family-hash.service.spec.d.ts.map +0 -1
  76. package/dist/__tests__/core/family-hash.service.spec.js +0 -1117
  77. package/dist/__tests__/core/family-hash.service.spec.js.map +0 -1
  78. package/dist/__tests__/core/pruning.service.spec.d.ts +0 -2
  79. package/dist/__tests__/core/pruning.service.spec.d.ts.map +0 -1
  80. package/dist/__tests__/core/pruning.service.spec.js +0 -224
  81. package/dist/__tests__/core/pruning.service.spec.js.map +0 -1
  82. package/dist/__tests__/core/storage/memory.storage.spec.d.ts +0 -2
  83. package/dist/__tests__/core/storage/memory.storage.spec.d.ts.map +0 -1
  84. package/dist/__tests__/core/storage/memory.storage.spec.js +0 -450
  85. package/dist/__tests__/core/storage/memory.storage.spec.js.map +0 -1
  86. package/dist/__tests__/core/storage/redis.storage.spec.d.ts +0 -10
  87. package/dist/__tests__/core/storage/redis.storage.spec.d.ts.map +0 -1
  88. package/dist/__tests__/core/storage/redis.storage.spec.js +0 -657
  89. package/dist/__tests__/core/storage/redis.storage.spec.js.map +0 -1
  90. package/dist/__tests__/core/storage/sqlite.storage.spec.d.ts +0 -2
  91. package/dist/__tests__/core/storage/sqlite.storage.spec.d.ts.map +0 -1
  92. package/dist/__tests__/core/storage/sqlite.storage.spec.js +0 -1294
  93. package/dist/__tests__/core/storage/sqlite.storage.spec.js.map +0 -1
  94. package/dist/__tests__/core/storage/storage.factory.spec.d.ts +0 -2
  95. package/dist/__tests__/core/storage/storage.factory.spec.d.ts.map +0 -1
  96. package/dist/__tests__/core/storage/storage.factory.spec.js +0 -151
  97. package/dist/__tests__/core/storage/storage.factory.spec.js.map +0 -1
  98. package/dist/__tests__/core/tag.service.spec.d.ts +0 -2
  99. package/dist/__tests__/core/tag.service.spec.d.ts.map +0 -1
  100. package/dist/__tests__/core/tag.service.spec.js +0 -1126
  101. package/dist/__tests__/core/tag.service.spec.js.map +0 -1
  102. package/dist/__tests__/docs-consistency.spec.d.ts +0 -2
  103. package/dist/__tests__/docs-consistency.spec.d.ts.map +0 -1
  104. package/dist/__tests__/docs-consistency.spec.js +0 -74
  105. package/dist/__tests__/docs-consistency.spec.js.map +0 -1
  106. package/dist/__tests__/family-hash.service.spec.d.ts +0 -2
  107. package/dist/__tests__/family-hash.service.spec.d.ts.map +0 -1
  108. package/dist/__tests__/family-hash.service.spec.js +0 -325
  109. package/dist/__tests__/family-hash.service.spec.js.map +0 -1
  110. package/dist/__tests__/filters/api-filters.spec.d.ts +0 -2
  111. package/dist/__tests__/filters/api-filters.spec.d.ts.map +0 -1
  112. package/dist/__tests__/filters/api-filters.spec.js +0 -188
  113. package/dist/__tests__/filters/api-filters.spec.js.map +0 -1
  114. package/dist/__tests__/filters/badge-filter-e2e.spec.d.ts +0 -2
  115. package/dist/__tests__/filters/badge-filter-e2e.spec.d.ts.map +0 -1
  116. package/dist/__tests__/filters/badge-filter-e2e.spec.js +0 -418
  117. package/dist/__tests__/filters/badge-filter-e2e.spec.js.map +0 -1
  118. package/dist/__tests__/filters/entry-factories.d.ts +0 -20
  119. package/dist/__tests__/filters/entry-factories.d.ts.map +0 -1
  120. package/dist/__tests__/filters/entry-factories.js +0 -288
  121. package/dist/__tests__/filters/entry-factories.js.map +0 -1
  122. package/dist/__tests__/filters/filter-contract.spec.d.ts +0 -2
  123. package/dist/__tests__/filters/filter-contract.spec.d.ts.map +0 -1
  124. package/dist/__tests__/filters/filter-contract.spec.js +0 -319
  125. package/dist/__tests__/filters/filter-contract.spec.js.map +0 -1
  126. package/dist/__tests__/filters/filter-test-data.d.ts +0 -26
  127. package/dist/__tests__/filters/filter-test-data.d.ts.map +0 -1
  128. package/dist/__tests__/filters/filter-test-data.js +0 -374
  129. package/dist/__tests__/filters/filter-test-data.js.map +0 -1
  130. package/dist/__tests__/filters/storage-filters.spec.d.ts +0 -2
  131. package/dist/__tests__/filters/storage-filters.spec.d.ts.map +0 -1
  132. package/dist/__tests__/filters/storage-filters.spec.js +0 -699
  133. package/dist/__tests__/filters/storage-filters.spec.js.map +0 -1
  134. package/dist/__tests__/filters/test-utils.d.ts +0 -23
  135. package/dist/__tests__/filters/test-utils.d.ts.map +0 -1
  136. package/dist/__tests__/filters/test-utils.js +0 -54
  137. package/dist/__tests__/filters/test-utils.js.map +0 -1
  138. package/dist/__tests__/integration/adapter-compat.integration.spec.d.ts +0 -2
  139. package/dist/__tests__/integration/adapter-compat.integration.spec.d.ts.map +0 -1
  140. package/dist/__tests__/integration/adapter-compat.integration.spec.js +0 -139
  141. package/dist/__tests__/integration/adapter-compat.integration.spec.js.map +0 -1
  142. package/dist/__tests__/integration/entries-filter-graphql-tags.integration.spec.d.ts +0 -16
  143. package/dist/__tests__/integration/entries-filter-graphql-tags.integration.spec.d.ts.map +0 -1
  144. package/dist/__tests__/integration/entries-filter-graphql-tags.integration.spec.js +0 -131
  145. package/dist/__tests__/integration/entries-filter-graphql-tags.integration.spec.js.map +0 -1
  146. package/dist/__tests__/integration/schedule-watcher.integration.spec.d.ts +0 -2
  147. package/dist/__tests__/integration/schedule-watcher.integration.spec.d.ts.map +0 -1
  148. package/dist/__tests__/integration/schedule-watcher.integration.spec.js +0 -87
  149. package/dist/__tests__/integration/schedule-watcher.integration.spec.js.map +0 -1
  150. package/dist/__tests__/integration/watcher-coexistence.integration.spec.d.ts +0 -2
  151. package/dist/__tests__/integration/watcher-coexistence.integration.spec.d.ts.map +0 -1
  152. package/dist/__tests__/integration/watcher-coexistence.integration.spec.js +0 -88
  153. package/dist/__tests__/integration/watcher-coexistence.integration.spec.js.map +0 -1
  154. package/dist/__tests__/nestlens.module.spec.d.ts +0 -2
  155. package/dist/__tests__/nestlens.module.spec.d.ts.map +0 -1
  156. package/dist/__tests__/nestlens.module.spec.js +0 -620
  157. package/dist/__tests__/nestlens.module.spec.js.map +0 -1
  158. package/dist/__tests__/package-contract.spec.d.ts +0 -2
  159. package/dist/__tests__/package-contract.spec.d.ts.map +0 -1
  160. package/dist/__tests__/package-contract.spec.js +0 -88
  161. package/dist/__tests__/package-contract.spec.js.map +0 -1
  162. package/dist/__tests__/pruning.service.spec.d.ts +0 -2
  163. package/dist/__tests__/pruning.service.spec.d.ts.map +0 -1
  164. package/dist/__tests__/pruning.service.spec.js +0 -142
  165. package/dist/__tests__/pruning.service.spec.js.map +0 -1
  166. package/dist/__tests__/setup.d.ts +0 -7
  167. package/dist/__tests__/setup.d.ts.map +0 -1
  168. package/dist/__tests__/setup.js +0 -24
  169. package/dist/__tests__/setup.js.map +0 -1
  170. package/dist/__tests__/tag.service.spec.d.ts +0 -2
  171. package/dist/__tests__/tag.service.spec.d.ts.map +0 -1
  172. package/dist/__tests__/tag.service.spec.js +0 -477
  173. package/dist/__tests__/tag.service.spec.js.map +0 -1
  174. package/dist/__tests__/watchers/batch.watcher.spec.d.ts +0 -2
  175. package/dist/__tests__/watchers/batch.watcher.spec.d.ts.map +0 -1
  176. package/dist/__tests__/watchers/batch.watcher.spec.js +0 -515
  177. package/dist/__tests__/watchers/batch.watcher.spec.js.map +0 -1
  178. package/dist/__tests__/watchers/cache.watcher.spec.d.ts +0 -2
  179. package/dist/__tests__/watchers/cache.watcher.spec.d.ts.map +0 -1
  180. package/dist/__tests__/watchers/cache.watcher.spec.js +0 -397
  181. package/dist/__tests__/watchers/cache.watcher.spec.js.map +0 -1
  182. package/dist/__tests__/watchers/command.watcher.spec.d.ts +0 -2
  183. package/dist/__tests__/watchers/command.watcher.spec.d.ts.map +0 -1
  184. package/dist/__tests__/watchers/command.watcher.spec.js +0 -604
  185. package/dist/__tests__/watchers/command.watcher.spec.js.map +0 -1
  186. package/dist/__tests__/watchers/dump.watcher.spec.d.ts +0 -2
  187. package/dist/__tests__/watchers/dump.watcher.spec.d.ts.map +0 -1
  188. package/dist/__tests__/watchers/dump.watcher.spec.js +0 -723
  189. package/dist/__tests__/watchers/dump.watcher.spec.js.map +0 -1
  190. package/dist/__tests__/watchers/event.watcher.spec.d.ts +0 -2
  191. package/dist/__tests__/watchers/event.watcher.spec.d.ts.map +0 -1
  192. package/dist/__tests__/watchers/event.watcher.spec.js +0 -316
  193. package/dist/__tests__/watchers/event.watcher.spec.js.map +0 -1
  194. package/dist/__tests__/watchers/exception.watcher.spec.d.ts +0 -2
  195. package/dist/__tests__/watchers/exception.watcher.spec.d.ts.map +0 -1
  196. package/dist/__tests__/watchers/exception.watcher.spec.js +0 -507
  197. package/dist/__tests__/watchers/exception.watcher.spec.js.map +0 -1
  198. package/dist/__tests__/watchers/gate.watcher.spec.d.ts +0 -2
  199. package/dist/__tests__/watchers/gate.watcher.spec.d.ts.map +0 -1
  200. package/dist/__tests__/watchers/gate.watcher.spec.js +0 -683
  201. package/dist/__tests__/watchers/gate.watcher.spec.js.map +0 -1
  202. package/dist/__tests__/watchers/graphql/header-masking.spec.d.ts +0 -2
  203. package/dist/__tests__/watchers/graphql/header-masking.spec.d.ts.map +0 -1
  204. package/dist/__tests__/watchers/graphql/header-masking.spec.js +0 -95
  205. package/dist/__tests__/watchers/graphql/header-masking.spec.js.map +0 -1
  206. package/dist/__tests__/watchers/http-client.watcher.spec.d.ts +0 -2
  207. package/dist/__tests__/watchers/http-client.watcher.spec.d.ts.map +0 -1
  208. package/dist/__tests__/watchers/http-client.watcher.spec.js +0 -886
  209. package/dist/__tests__/watchers/http-client.watcher.spec.js.map +0 -1
  210. package/dist/__tests__/watchers/job.watcher.spec.d.ts +0 -2
  211. package/dist/__tests__/watchers/job.watcher.spec.d.ts.map +0 -1
  212. package/dist/__tests__/watchers/job.watcher.spec.js +0 -843
  213. package/dist/__tests__/watchers/job.watcher.spec.js.map +0 -1
  214. package/dist/__tests__/watchers/log.watcher.spec.d.ts +0 -2
  215. package/dist/__tests__/watchers/log.watcher.spec.d.ts.map +0 -1
  216. package/dist/__tests__/watchers/log.watcher.spec.js +0 -428
  217. package/dist/__tests__/watchers/log.watcher.spec.js.map +0 -1
  218. package/dist/__tests__/watchers/mail.watcher.spec.d.ts +0 -2
  219. package/dist/__tests__/watchers/mail.watcher.spec.d.ts.map +0 -1
  220. package/dist/__tests__/watchers/mail.watcher.spec.js +0 -426
  221. package/dist/__tests__/watchers/mail.watcher.spec.js.map +0 -1
  222. package/dist/__tests__/watchers/model.watcher.spec.d.ts +0 -2
  223. package/dist/__tests__/watchers/model.watcher.spec.d.ts.map +0 -1
  224. package/dist/__tests__/watchers/model.watcher.spec.js +0 -712
  225. package/dist/__tests__/watchers/model.watcher.spec.js.map +0 -1
  226. package/dist/__tests__/watchers/notification.watcher.spec.d.ts +0 -2
  227. package/dist/__tests__/watchers/notification.watcher.spec.d.ts.map +0 -1
  228. package/dist/__tests__/watchers/notification.watcher.spec.js +0 -595
  229. package/dist/__tests__/watchers/notification.watcher.spec.js.map +0 -1
  230. package/dist/__tests__/watchers/query/typeorm-integration.spec.d.ts +0 -2
  231. package/dist/__tests__/watchers/query/typeorm-integration.spec.d.ts.map +0 -1
  232. package/dist/__tests__/watchers/query/typeorm-integration.spec.js +0 -100
  233. package/dist/__tests__/watchers/query/typeorm-integration.spec.js.map +0 -1
  234. package/dist/__tests__/watchers/query/types.spec.d.ts +0 -2
  235. package/dist/__tests__/watchers/query/types.spec.d.ts.map +0 -1
  236. package/dist/__tests__/watchers/query/types.spec.js +0 -77
  237. package/dist/__tests__/watchers/query/types.spec.js.map +0 -1
  238. package/dist/__tests__/watchers/query.watcher.spec.d.ts +0 -2
  239. package/dist/__tests__/watchers/query.watcher.spec.d.ts.map +0 -1
  240. package/dist/__tests__/watchers/query.watcher.spec.js +0 -252
  241. package/dist/__tests__/watchers/query.watcher.spec.js.map +0 -1
  242. package/dist/__tests__/watchers/redis.watcher.spec.d.ts +0 -2
  243. package/dist/__tests__/watchers/redis.watcher.spec.d.ts.map +0 -1
  244. package/dist/__tests__/watchers/redis.watcher.spec.js +0 -636
  245. package/dist/__tests__/watchers/redis.watcher.spec.js.map +0 -1
  246. package/dist/__tests__/watchers/request.watcher.spec.d.ts +0 -2
  247. package/dist/__tests__/watchers/request.watcher.spec.d.ts.map +0 -1
  248. package/dist/__tests__/watchers/request.watcher.spec.js +0 -1064
  249. package/dist/__tests__/watchers/request.watcher.spec.js.map +0 -1
  250. package/dist/__tests__/watchers/schedule.watcher.spec.d.ts +0 -2
  251. package/dist/__tests__/watchers/schedule.watcher.spec.d.ts.map +0 -1
  252. package/dist/__tests__/watchers/schedule.watcher.spec.js +0 -345
  253. package/dist/__tests__/watchers/schedule.watcher.spec.js.map +0 -1
  254. package/dist/__tests__/watchers/view.watcher.spec.d.ts +0 -2
  255. package/dist/__tests__/watchers/view.watcher.spec.d.ts.map +0 -1
  256. package/dist/__tests__/watchers/view.watcher.spec.js +0 -566
  257. package/dist/__tests__/watchers/view.watcher.spec.js.map +0 -1
  258. package/dist/dashboard/public/assets/index-6-E0lKi6.js +0 -361
@@ -1 +1 @@
1
- import{j as t,e as l}from"./index-6-E0lKi6.js";import{e as T,b as v}from"./vendor-B2nVRih0.js";import{u as P,C as d,f as D,p as F}from"./ClickableBadge-D2hks1Oq.js";import{u as R,P as A,N as M,L as B}from"./PageHeader-D5bOCFIP.js";import{o as W,T as a,D as L,b as H}from"./types-P3vOygE2.js";function z(){const c=T(),{addFilter:i,clearAll:p,serverFilters:u,headerFilters:h,hasFilters:x}=P("notifications"),{entries:m,loading:g,refreshing:r,newEntriesCount:y,hasMore:f,loadMore:j,loadNew:C,autoRefreshEnabled:k,setAutoRefresh:N,meta:s,isHighlighted:w}=R({type:"notification",limit:50,filters:u}),o=m.filter(e=>W(e)),b=v.useMemo(()=>[{key:"type",header:"Type",width:"150px",render:e=>t.jsx(d,{onClick:n=>{n.stopPropagation(),i("types",e.payload.type)},children:e.payload.type})},{key:"recipient",header:"Recipient",minWidth:"200px",render:e=>t.jsx(a,{mono:!0,truncate:!0,maxWidth:"250px",children:e.payload.recipient})},{key:"title",header:"Title",minWidth:"200px",render:e=>e.payload.title?t.jsx(a,{truncate:!0,maxWidth:"300px",children:e.payload.title}):t.jsx(a,{secondary:!0,children:"-"})},{key:"status",header:"Status",width:"100px",render:e=>t.jsx(d,{onClick:n=>{n.stopPropagation(),i("statuses",e.payload.status)},children:e.payload.status.toUpperCase()})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>t.jsx(L,{ms:e.payload.duration||0})},{key:"time",header:"Time",width:"170px",align:"right",render:e=>t.jsx(a,{secondary:!0,className:"text-xs",children:D(F(e.createdAt),{addSuffix:!0})})}],[i]);if(g&&o.length===0)return t.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:t.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const E=x?"pt-28":"pt-16";return t.jsxs("div",{children:[t.jsx(A,{title:"Notifications",icon:l,iconColor:"text-indigo-600 dark:text-indigo-400",count:o.length,totalCount:s==null?void 0:s.total,refreshing:r,autoRefreshEnabled:k,onAutoRefreshToggle:N,filters:h,onClearAllFilters:p}),t.jsxs("div",{className:`${E} space-y-4 transition-all duration-200`,children:[t.jsx(M,{count:y,onClick:C,loading:r}),t.jsx(H,{columns:b,data:o,keyExtractor:e=>e.id,onRowClick:e=>c(`/notifications/${e.id}`),rowClassName:e=>w(e.id)?"highlight-new":"",emptyMessage:"No notifications recorded yet",emptyIcon:t.jsx(l,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),t.jsx(B,{hasMore:f,onClick:j,loading:r})]})]})}export{z as default};
1
+ import{j as t,e as l}from"./index-TmiQivGf.js";import{e as T,b as v}from"./vendor-B2nVRih0.js";import{u as P,C as d,f as D,p as F}from"./ClickableBadge-DYNLPtLq.js";import{u as R,P as A,N as M,L as B}from"./PageHeader-q5aVtQHw.js";import{o as W,T as a,D as L,b as H}from"./types-DcORDHhK.js";function z(){const c=T(),{addFilter:i,clearAll:p,serverFilters:u,headerFilters:h,hasFilters:x}=P("notifications"),{entries:m,loading:g,refreshing:r,newEntriesCount:y,hasMore:f,loadMore:j,loadNew:C,autoRefreshEnabled:k,setAutoRefresh:N,meta:s,isHighlighted:w}=R({type:"notification",limit:50,filters:u}),o=m.filter(e=>W(e)),b=v.useMemo(()=>[{key:"type",header:"Type",width:"150px",render:e=>t.jsx(d,{onClick:n=>{n.stopPropagation(),i("types",e.payload.type)},children:e.payload.type})},{key:"recipient",header:"Recipient",minWidth:"200px",render:e=>t.jsx(a,{mono:!0,truncate:!0,maxWidth:"250px",children:e.payload.recipient})},{key:"title",header:"Title",minWidth:"200px",render:e=>e.payload.title?t.jsx(a,{truncate:!0,maxWidth:"300px",children:e.payload.title}):t.jsx(a,{secondary:!0,children:"-"})},{key:"status",header:"Status",width:"100px",render:e=>t.jsx(d,{onClick:n=>{n.stopPropagation(),i("statuses",e.payload.status)},children:e.payload.status.toUpperCase()})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>t.jsx(L,{ms:e.payload.duration||0})},{key:"time",header:"Time",width:"170px",align:"right",render:e=>t.jsx(a,{secondary:!0,className:"text-xs",children:D(F(e.createdAt),{addSuffix:!0})})}],[i]);if(g&&o.length===0)return t.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:t.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const E=x?"pt-28":"pt-16";return t.jsxs("div",{children:[t.jsx(A,{title:"Notifications",icon:l,iconColor:"text-indigo-600 dark:text-indigo-400",count:o.length,totalCount:s==null?void 0:s.total,refreshing:r,autoRefreshEnabled:k,onAutoRefreshToggle:N,filters:h,onClearAllFilters:p}),t.jsxs("div",{className:`${E} space-y-4 transition-all duration-200`,children:[t.jsx(M,{count:y,onClick:C,loading:r}),t.jsx(H,{columns:b,data:o,keyExtractor:e=>e.id,onRowClick:e=>c(`/notifications/${e.id}`),rowClassName:e=>w(e.id)?"highlight-new":"",emptyMessage:"No notifications recorded yet",emptyIcon:t.jsx(l,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),t.jsx(B,{hasMore:f,onClick:j,loading:r})]})]})}export{z as default};
@@ -1 +1 @@
1
- import{b as s}from"./vendor-B2nVRih0.js";import{m as F,z as q,p as J,q as _,j as r,i as A,e as Q,s as V,X as Z}from"./index-6-E0lKi6.js";function $(t){return t==null?"":typeof t!="object"?String(t):Array.isArray(t)?"["+t.map($).join(",")+"]":"{"+Object.keys(t).sort().map(n=>`"${n}":${$(t[n])}`).join(",")+"}"}const z="nestlens-auto-refresh";function ee(){try{const t=localStorage.getItem(z);return t===null?!0:t==="true"}catch{return!0}}function re(t){try{localStorage.setItem(z,String(t))}catch{}}function se(t={}){const{type:a,limit:n=50,autoRefresh:c,autoRefreshInterval:f=5e3,filters:y}=t,m=$(y),[v,h]=s.useState([]),[j,N]=s.useState(!0),[S,g]=s.useState(!1),[I,b]=s.useState(null),[d,k]=s.useState(null),[R,o]=s.useState(0),[x,w]=s.useState(c??ee()),l=s.useRef(null),E=s.useRef(null),L=s.useRef(!0),B=s.useRef(m),C=s.useRef(new Map),[,G]=s.useState(0),H=1e4,O=s.useCallback(async()=>{L.current?N(!0):g(!0);try{b(null);const e=await F({type:a,limit:n,filters:y});h(e.data),k(e.meta),l.current=e.meta.newestSequence,o(0),L.current=!1,B.current=m}catch(e){const i=e instanceof Error?e:new Error("Failed to fetch entries");b(i),console.error("Failed to fetch entries:",e),q.error("Failed to load entries")}finally{N(!1),g(!1)}},[a,n,m]),K=s.useCallback(async()=>{if(!(!(d!=null&&d.oldestSequence)||!d.hasMore)){g(!0);try{const e=await F({type:a,limit:n,beforeSequence:d.oldestSequence,filters:y});h(i=>[...i,...e.data]),k(e.meta)}catch(e){console.error("Failed to load more entries:",e),q.error("Failed to load more entries")}finally{g(!1)}}},[a,n,d,m]),P=s.useCallback(async()=>{if(l.current){g(!0);try{const e=await F({type:a,limit:R||n,afterSequence:l.current,filters:y});if(e.data.length>0){const i=Date.now();e.data.forEach(u=>{C.current.set(u.id,i)}),h(u=>[...e.data,...u]),l.current=e.meta.newestSequence,o(0)}}catch(e){console.error("Failed to load new entries:",e),q.error("Failed to load new entries")}finally{g(!1)}}},[a,n,R,m]),U=s.useCallback(async()=>{g(!0);try{b(null);const e=await F({type:a,limit:n,filters:y});h(e.data),k(e.meta),l.current=e.meta.newestSequence,o(0)}catch(e){const i=e instanceof Error?e:new Error("Failed to refresh entries");b(i),console.error("Failed to refresh entries:",e),q.error("Failed to refresh entries")}finally{g(!1)}},[a,n,m]),D=s.useCallback(async()=>{if(!l.current){try{(await J(a)).data&&o(1)}catch{}return}try{const e=await _(l.current,a);o(e.data.count)}catch{}},[a]),W=s.useCallback(e=>{w(e),re(e)},[]),X=s.useCallback(e=>{h(i=>i.map(u=>u.id===e.id?e:u))},[]);s.useEffect(()=>{O()},[O]);const Y=s.useCallback(e=>{const i=C.current.get(e);return i?Date.now()-i<H:!1},[]),M=s.useCallback(()=>{const e=Date.now();let i=!1;C.current.forEach((u,p)=>{e-u>=H&&(C.current.delete(p),i=!0)}),i&&G(u=>u+1)},[]),T=s.useCallback(async()=>{if(l.current)try{const e=await _(l.current,a);if(e.data.count>0){const i=await F({type:a,limit:e.data.count,afterSequence:l.current,filters:y});if(i.data.length>0){const u=Date.now();i.data.forEach(p=>{C.current.set(p.id,u)}),h(p=>[...i.data,...p]),l.current=i.meta.newestSequence,k(p=>p?{...p,total:p.total+i.data.length,newestSequence:i.meta.newestSequence}:i.meta)}}}catch{}},[a,m]);return s.useEffect(()=>(x?E.current=setInterval(T,f):E.current=setInterval(D,f),()=>{E.current&&(clearInterval(E.current),E.current=null)}),[x,f,T,D]),s.useEffect(()=>{const e=setInterval(M,1e3);return()=>clearInterval(e)},[M]),{entries:v,loading:j,refreshing:S,error:I,meta:d,newEntriesCount:R,hasMore:(d==null?void 0:d.hasMore)??!1,loadMore:K,loadNew:P,refresh:U,setAutoRefresh:W,autoRefreshEnabled:x,updateEntry:X,isHighlighted:Y}}function ne({count:t,onClick:a,loading:n}){return t===0?null:r.jsxs("button",{onClick:a,disabled:n,className:"w-full py-3 px-4 bg-primary-50 dark:bg-primary-900/20 text-primary-600 dark:text-primary-400 font-medium rounded-lg hover:bg-primary-100 dark:hover:bg-primary-900/30 transition-colors flex items-center justify-center space-x-2 disabled:opacity-50",children:[n?r.jsx(A,{className:"h-4 w-4 animate-spin"}):r.jsx(Q,{className:"h-4 w-4"}),r.jsxs("span",{children:["Load ",t," new ",t===1?"entry":"entries"]})]})}function ie({hasMore:t,onClick:a,loading:n}){return t?r.jsxs("button",{onClick:a,disabled:n,className:"w-full py-3 px-4 bg-gray-100 dark:bg-gray-800 text-gray-700 dark:text-gray-300 font-medium rounded-lg hover:bg-gray-200 dark:hover:bg-gray-700 transition-colors flex items-center justify-center space-x-2 disabled:opacity-50",children:[n?r.jsx(A,{className:"h-4 w-4 animate-spin"}):r.jsx(V,{className:"h-4 w-4"}),r.jsx("span",{children:"Load older entries"})]}):null}function ce({title:t,icon:a,iconColor:n="text-primary-600 dark:text-primary-400",count:c,totalCount:f,subtitle:y,loading:m,refreshing:v,onRefresh:h,autoRefreshEnabled:j,onAutoRefreshToggle:N,filters:S=[],onClearAllFilters:g,actions:I,filterControls:b}){const d=S.length>0,k=c??f,R=S.reduce((o,x)=>(o[x.category]||(o[x.category]=[]),o[x.category].push(x),o),{});return r.jsxs("div",{className:"fixed top-0 left-0 right-0 lg:left-64 z-30 bg-gray-50 dark:bg-gray-900 border-b border-gray-200 dark:border-gray-700",children:[r.jsxs("div",{className:"h-16 px-4 lg:px-6 flex items-center justify-between",children:[r.jsxs("div",{className:"flex items-center space-x-3",children:[r.jsx("div",{className:"hidden sm:flex p-2 rounded-lg bg-gray-100 dark:bg-gray-800",children:r.jsx(a,{className:`h-5 w-5 ${n}`})}),r.jsxs("div",{className:"flex items-center space-x-3",children:[r.jsx("h1",{className:"text-xl font-bold text-gray-900 dark:text-white",children:t}),k!==void 0&&r.jsxs("span",{role:"status","aria-live":"polite",className:"inline-flex items-center px-2.5 py-0.5 rounded-full text-xs font-medium bg-gray-100 dark:bg-gray-800 text-gray-600 dark:text-gray-300",children:[k.toLocaleString(),f!==void 0&&c!==void 0&&c!==f&&r.jsxs("span",{className:"text-gray-400 dark:text-gray-500 ml-1",children:["/ ",f.toLocaleString()]})]}),y&&r.jsx("span",{className:"hidden md:inline text-sm text-gray-500 dark:text-gray-400",children:y})]})]}),r.jsxs("div",{className:"flex items-center space-x-2",children:[I,N&&r.jsxs("button",{onClick:()=>N(!j),className:`hidden sm:flex items-center space-x-1.5 px-3 py-1.5 rounded-lg text-sm font-medium transition-colors whitespace-nowrap ${j?"bg-green-100 text-green-700 dark:bg-green-900/30 dark:text-green-400":"bg-gray-100 text-gray-600 dark:bg-gray-800 dark:text-gray-400 hover:bg-gray-200 dark:hover:bg-gray-700"}`,title:j?"Auto-refresh enabled":"Auto-refresh disabled",children:[r.jsx("span",{className:`w-2 h-2 rounded-full flex-shrink-0 ${j?"bg-green-500 animate-pulse":"bg-gray-400"}`}),r.jsx("span",{children:"Auto Refresh"})]}),h&&r.jsx("button",{onClick:h,disabled:m||v,"aria-busy":v,"aria-label":v?"Refreshing...":"Refresh",className:"p-2 rounded-lg text-gray-500 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 hover:text-gray-700 dark:hover:text-gray-200 transition-colors disabled:opacity-50 disabled:cursor-not-allowed",title:"Refresh",children:r.jsx(A,{className:`h-4 w-4 ${v?"animate-spin":""}`})})]})]}),b&&r.jsx("div",{className:"px-4 lg:px-6 py-2 border-t border-gray-100 dark:border-gray-800 bg-gray-50/50 dark:bg-gray-900/50",children:b}),d&&r.jsx("div",{className:"px-4 lg:px-6 py-2 border-t border-gray-100 dark:border-gray-800 bg-gray-50/50 dark:bg-gray-900/50",children:r.jsxs("div",{className:"flex items-center flex-wrap gap-2",children:[r.jsx("span",{className:"text-xs font-medium text-gray-500 dark:text-gray-400 uppercase tracking-wider mr-1",children:"Filters:"}),Object.entries(R).map(([o,x])=>r.jsxs("div",{className:"flex items-center space-x-1",children:[r.jsxs("span",{className:"text-xs text-gray-400 dark:text-gray-500",children:[o,":"]}),x.map((w,l)=>r.jsxs("button",{onClick:w.onRemove,"aria-label":`Remove ${o} filter: ${w.value}`,className:"inline-flex items-center space-x-1 px-2 py-0.5 rounded-md text-xs font-medium bg-primary-100 dark:bg-primary-900/30 text-primary-700 dark:text-primary-300 hover:bg-primary-200 dark:hover:bg-primary-900/50 transition-colors group uppercase",children:[r.jsx("span",{children:w.value}),r.jsx(Z,{className:"h-3 w-3 opacity-60 group-hover:opacity-100"})]},`${w.category}-${w.value}-${l}`))]},o)),g&&S.length>1&&r.jsx("button",{onClick:g,className:"ml-2 text-xs text-gray-500 dark:text-gray-400 hover:text-red-600 dark:hover:text-red-400 transition-colors",children:"Clear all"})]})})]})}function oe({tabs:t,activeTab:a,onChange:n}){return r.jsx("div",{className:"flex items-center space-x-1",children:t.map(c=>r.jsxs("button",{onClick:()=>n(c.id),className:`px-3 py-1.5 rounded-lg text-sm font-medium transition-colors ${a===c.id?"bg-primary-100 text-primary-700 dark:bg-primary-900/50 dark:text-primary-300":"text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800"}`,children:[c.label,c.count!==void 0&&r.jsx("span",{className:`ml-1.5 text-xs ${a===c.id?"text-primary-600 dark:text-primary-400":"text-gray-400 dark:text-gray-500"}`,children:c.count})]},c.id))})}function le({label:t,enabled:a,onChange:n,icon:c}){return r.jsxs("button",{onClick:()=>n(!a),className:`flex items-center space-x-2 px-3 py-1.5 rounded-lg text-sm font-medium transition-colors ${a?"bg-primary-100 text-primary-700 dark:bg-primary-900/30 dark:text-primary-300":"bg-gray-100 text-gray-600 dark:bg-gray-800 dark:text-gray-400 hover:bg-gray-200 dark:hover:bg-gray-700"}`,children:[c&&r.jsx(c,{className:"h-4 w-4"}),r.jsx("span",{children:t})]})}export{oe as F,ie as L,ne as N,ce as P,le as T,se as u};
1
+ import{b as s}from"./vendor-B2nVRih0.js";import{m as F,z as q,p as J,q as _,j as r,i as A,e as Q,s as V,X as Z}from"./index-TmiQivGf.js";function $(t){return t==null?"":typeof t!="object"?String(t):Array.isArray(t)?"["+t.map($).join(",")+"]":"{"+Object.keys(t).sort().map(n=>`"${n}":${$(t[n])}`).join(",")+"}"}const z="nestlens-auto-refresh";function ee(){try{const t=localStorage.getItem(z);return t===null?!0:t==="true"}catch{return!0}}function re(t){try{localStorage.setItem(z,String(t))}catch{}}function se(t={}){const{type:a,limit:n=50,autoRefresh:c,autoRefreshInterval:f=5e3,filters:y}=t,m=$(y),[v,h]=s.useState([]),[j,N]=s.useState(!0),[S,g]=s.useState(!1),[I,b]=s.useState(null),[d,k]=s.useState(null),[R,o]=s.useState(0),[x,w]=s.useState(c??ee()),l=s.useRef(null),E=s.useRef(null),L=s.useRef(!0),B=s.useRef(m),C=s.useRef(new Map),[,G]=s.useState(0),H=1e4,O=s.useCallback(async()=>{L.current?N(!0):g(!0);try{b(null);const e=await F({type:a,limit:n,filters:y});h(e.data),k(e.meta),l.current=e.meta.newestSequence,o(0),L.current=!1,B.current=m}catch(e){const i=e instanceof Error?e:new Error("Failed to fetch entries");b(i),console.error("Failed to fetch entries:",e),q.error("Failed to load entries")}finally{N(!1),g(!1)}},[a,n,m]),K=s.useCallback(async()=>{if(!(!(d!=null&&d.oldestSequence)||!d.hasMore)){g(!0);try{const e=await F({type:a,limit:n,beforeSequence:d.oldestSequence,filters:y});h(i=>[...i,...e.data]),k(e.meta)}catch(e){console.error("Failed to load more entries:",e),q.error("Failed to load more entries")}finally{g(!1)}}},[a,n,d,m]),P=s.useCallback(async()=>{if(l.current){g(!0);try{const e=await F({type:a,limit:R||n,afterSequence:l.current,filters:y});if(e.data.length>0){const i=Date.now();e.data.forEach(u=>{C.current.set(u.id,i)}),h(u=>[...e.data,...u]),l.current=e.meta.newestSequence,o(0)}}catch(e){console.error("Failed to load new entries:",e),q.error("Failed to load new entries")}finally{g(!1)}}},[a,n,R,m]),U=s.useCallback(async()=>{g(!0);try{b(null);const e=await F({type:a,limit:n,filters:y});h(e.data),k(e.meta),l.current=e.meta.newestSequence,o(0)}catch(e){const i=e instanceof Error?e:new Error("Failed to refresh entries");b(i),console.error("Failed to refresh entries:",e),q.error("Failed to refresh entries")}finally{g(!1)}},[a,n,m]),D=s.useCallback(async()=>{if(!l.current){try{(await J(a)).data&&o(1)}catch{}return}try{const e=await _(l.current,a);o(e.data.count)}catch{}},[a]),W=s.useCallback(e=>{w(e),re(e)},[]),X=s.useCallback(e=>{h(i=>i.map(u=>u.id===e.id?e:u))},[]);s.useEffect(()=>{O()},[O]);const Y=s.useCallback(e=>{const i=C.current.get(e);return i?Date.now()-i<H:!1},[]),M=s.useCallback(()=>{const e=Date.now();let i=!1;C.current.forEach((u,p)=>{e-u>=H&&(C.current.delete(p),i=!0)}),i&&G(u=>u+1)},[]),T=s.useCallback(async()=>{if(l.current)try{const e=await _(l.current,a);if(e.data.count>0){const i=await F({type:a,limit:e.data.count,afterSequence:l.current,filters:y});if(i.data.length>0){const u=Date.now();i.data.forEach(p=>{C.current.set(p.id,u)}),h(p=>[...i.data,...p]),l.current=i.meta.newestSequence,k(p=>p?{...p,total:p.total+i.data.length,newestSequence:i.meta.newestSequence}:i.meta)}}}catch{}},[a,m]);return s.useEffect(()=>(x?E.current=setInterval(T,f):E.current=setInterval(D,f),()=>{E.current&&(clearInterval(E.current),E.current=null)}),[x,f,T,D]),s.useEffect(()=>{const e=setInterval(M,1e3);return()=>clearInterval(e)},[M]),{entries:v,loading:j,refreshing:S,error:I,meta:d,newEntriesCount:R,hasMore:(d==null?void 0:d.hasMore)??!1,loadMore:K,loadNew:P,refresh:U,setAutoRefresh:W,autoRefreshEnabled:x,updateEntry:X,isHighlighted:Y}}function ne({count:t,onClick:a,loading:n}){return t===0?null:r.jsxs("button",{onClick:a,disabled:n,className:"w-full py-3 px-4 bg-primary-50 dark:bg-primary-900/20 text-primary-600 dark:text-primary-400 font-medium rounded-lg hover:bg-primary-100 dark:hover:bg-primary-900/30 transition-colors flex items-center justify-center space-x-2 disabled:opacity-50",children:[n?r.jsx(A,{className:"h-4 w-4 animate-spin"}):r.jsx(Q,{className:"h-4 w-4"}),r.jsxs("span",{children:["Load ",t," new ",t===1?"entry":"entries"]})]})}function ie({hasMore:t,onClick:a,loading:n}){return t?r.jsxs("button",{onClick:a,disabled:n,className:"w-full py-3 px-4 bg-gray-100 dark:bg-gray-800 text-gray-700 dark:text-gray-300 font-medium rounded-lg hover:bg-gray-200 dark:hover:bg-gray-700 transition-colors flex items-center justify-center space-x-2 disabled:opacity-50",children:[n?r.jsx(A,{className:"h-4 w-4 animate-spin"}):r.jsx(V,{className:"h-4 w-4"}),r.jsx("span",{children:"Load older entries"})]}):null}function ce({title:t,icon:a,iconColor:n="text-primary-600 dark:text-primary-400",count:c,totalCount:f,subtitle:y,loading:m,refreshing:v,onRefresh:h,autoRefreshEnabled:j,onAutoRefreshToggle:N,filters:S=[],onClearAllFilters:g,actions:I,filterControls:b}){const d=S.length>0,k=c??f,R=S.reduce((o,x)=>(o[x.category]||(o[x.category]=[]),o[x.category].push(x),o),{});return r.jsxs("div",{className:"fixed top-0 left-0 right-0 lg:left-64 z-30 bg-gray-50 dark:bg-gray-900 border-b border-gray-200 dark:border-gray-700",children:[r.jsxs("div",{className:"h-16 px-4 lg:px-6 flex items-center justify-between",children:[r.jsxs("div",{className:"flex items-center space-x-3",children:[r.jsx("div",{className:"hidden sm:flex p-2 rounded-lg bg-gray-100 dark:bg-gray-800",children:r.jsx(a,{className:`h-5 w-5 ${n}`})}),r.jsxs("div",{className:"flex items-center space-x-3",children:[r.jsx("h1",{className:"text-xl font-bold text-gray-900 dark:text-white",children:t}),k!==void 0&&r.jsxs("span",{role:"status","aria-live":"polite",className:"inline-flex items-center px-2.5 py-0.5 rounded-full text-xs font-medium bg-gray-100 dark:bg-gray-800 text-gray-600 dark:text-gray-300",children:[k.toLocaleString(),f!==void 0&&c!==void 0&&c!==f&&r.jsxs("span",{className:"text-gray-400 dark:text-gray-500 ml-1",children:["/ ",f.toLocaleString()]})]}),y&&r.jsx("span",{className:"hidden md:inline text-sm text-gray-500 dark:text-gray-400",children:y})]})]}),r.jsxs("div",{className:"flex items-center space-x-2",children:[I,N&&r.jsxs("button",{onClick:()=>N(!j),className:`hidden sm:flex items-center space-x-1.5 px-3 py-1.5 rounded-lg text-sm font-medium transition-colors whitespace-nowrap ${j?"bg-green-100 text-green-700 dark:bg-green-900/30 dark:text-green-400":"bg-gray-100 text-gray-600 dark:bg-gray-800 dark:text-gray-400 hover:bg-gray-200 dark:hover:bg-gray-700"}`,title:j?"Auto-refresh enabled":"Auto-refresh disabled",children:[r.jsx("span",{className:`w-2 h-2 rounded-full flex-shrink-0 ${j?"bg-green-500 animate-pulse":"bg-gray-400"}`}),r.jsx("span",{children:"Auto Refresh"})]}),h&&r.jsx("button",{onClick:h,disabled:m||v,"aria-busy":v,"aria-label":v?"Refreshing...":"Refresh",className:"p-2 rounded-lg text-gray-500 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 hover:text-gray-700 dark:hover:text-gray-200 transition-colors disabled:opacity-50 disabled:cursor-not-allowed",title:"Refresh",children:r.jsx(A,{className:`h-4 w-4 ${v?"animate-spin":""}`})})]})]}),b&&r.jsx("div",{className:"px-4 lg:px-6 py-2 border-t border-gray-100 dark:border-gray-800 bg-gray-50/50 dark:bg-gray-900/50",children:b}),d&&r.jsx("div",{className:"px-4 lg:px-6 py-2 border-t border-gray-100 dark:border-gray-800 bg-gray-50/50 dark:bg-gray-900/50",children:r.jsxs("div",{className:"flex items-center flex-wrap gap-2",children:[r.jsx("span",{className:"text-xs font-medium text-gray-500 dark:text-gray-400 uppercase tracking-wider mr-1",children:"Filters:"}),Object.entries(R).map(([o,x])=>r.jsxs("div",{className:"flex items-center space-x-1",children:[r.jsxs("span",{className:"text-xs text-gray-400 dark:text-gray-500",children:[o,":"]}),x.map((w,l)=>r.jsxs("button",{onClick:w.onRemove,"aria-label":`Remove ${o} filter: ${w.value}`,className:"inline-flex items-center space-x-1 px-2 py-0.5 rounded-md text-xs font-medium bg-primary-100 dark:bg-primary-900/30 text-primary-700 dark:text-primary-300 hover:bg-primary-200 dark:hover:bg-primary-900/50 transition-colors group uppercase",children:[r.jsx("span",{children:w.value}),r.jsx(Z,{className:"h-3 w-3 opacity-60 group-hover:opacity-100"})]},`${w.category}-${w.value}-${l}`))]},o)),g&&S.length>1&&r.jsx("button",{onClick:g,className:"ml-2 text-xs text-gray-500 dark:text-gray-400 hover:text-red-600 dark:hover:text-red-400 transition-colors",children:"Clear all"})]})})]})}function oe({tabs:t,activeTab:a,onChange:n}){return r.jsx("div",{className:"flex items-center space-x-1",children:t.map(c=>r.jsxs("button",{onClick:()=>n(c.id),className:`px-3 py-1.5 rounded-lg text-sm font-medium transition-colors ${a===c.id?"bg-primary-100 text-primary-700 dark:bg-primary-900/50 dark:text-primary-300":"text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800"}`,children:[c.label,c.count!==void 0&&r.jsx("span",{className:`ml-1.5 text-xs ${a===c.id?"text-primary-600 dark:text-primary-400":"text-gray-400 dark:text-gray-500"}`,children:c.count})]},c.id))})}function le({label:t,enabled:a,onChange:n,icon:c}){return r.jsxs("button",{onClick:()=>n(!a),className:`flex items-center space-x-2 px-3 py-1.5 rounded-lg text-sm font-medium transition-colors ${a?"bg-primary-100 text-primary-700 dark:bg-primary-900/30 dark:text-primary-300":"bg-gray-100 text-gray-600 dark:bg-gray-800 dark:text-gray-400 hover:bg-gray-200 dark:hover:bg-gray-700"}`,children:[c&&r.jsx(c,{className:"h-4 w-4"}),r.jsx("span",{children:t})]})}export{oe as F,ie as L,ne as N,ce as P,le as T,se as u};
@@ -1 +1 @@
1
- import{j as a,D as n}from"./index-6-E0lKi6.js";import{e as P,b as d}from"./vendor-B2nVRih0.js";import{u as A,C as M,f as Q,p as R}from"./ClickableBadge-D2hks1Oq.js";import{u as B,P as O,T as W,N as H,L as I}from"./PageHeader-D5bOCFIP.js";import{E as Z}from"./EntrySearchInput-CK8uj0H9.js";import{c as $,T as u,D as z,a as G,b as J}from"./types-P3vOygE2.js";import{Z as c}from"./zap-C8uvyhpc.js";import"./search-DQ8xACgM.js";function se(){const h=P(),[i,p]=d.useState(!1),{addFilter:l,clearAll:x,serverFilters:m,headerFilters:g,hasFilters:y}=A("queries"),f={...m,slow:i?!0:void 0},{entries:w,loading:j,refreshing:s,newEntriesCount:b,hasMore:C,loadMore:k,loadNew:T,autoRefreshEnabled:N,setAutoRefresh:E,meta:t,isHighlighted:S}=B({type:"query",limit:50,filters:f}),r=w.filter(e=>$(e)),v=d.useMemo(()=>[{key:"source",header:"Source",width:"120px",render:e=>a.jsx(M,{listType:"queries",filterType:"sources",children:e.payload.source||"unknown"})},{key:"query",header:"Query",minWidth:"300px",render:e=>a.jsxs("div",{className:"flex items-start space-x-2",children:[e.payload.slow&&a.jsx(c,{className:"h-4 w-4 text-yellow-500 flex-shrink-0 mt-0.5"}),a.jsx(u,{mono:!0,truncate:!0,maxWidth:"400px",children:e.payload.query.length>100?e.payload.query.substring(0,100)+"...":e.payload.query})]})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>a.jsx(z,{ms:e.payload.duration||0,slowThreshold:e.payload.slow?0:1e3})},{key:"tags",header:"Tags",minWidth:"150px",render:e=>{const D=(e.payload.source||"unknown").toLowerCase(),F=(e.tags||[]).filter(o=>o.toLowerCase()!==D);return a.jsx(G,{tags:F,max:3,onTagClick:(o,L)=>{L.stopPropagation(),l("tags",o)}})}},{key:"time",header:"Time",width:"170px",align:"right",render:e=>a.jsx(u,{secondary:!0,className:"text-xs",children:Q(R(e.createdAt),{addSuffix:!0})})}],[l]);if(j&&r.length===0)return a.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:a.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const q=y?"pt-28":"pt-16";return a.jsxs("div",{children:[a.jsx(O,{title:"Queries",icon:n,iconColor:"text-purple-600 dark:text-purple-400",count:r.length,totalCount:t==null?void 0:t.total,refreshing:s,autoRefreshEnabled:N,onAutoRefreshToggle:E,filters:g,onClearAllFilters:x,actions:a.jsx(W,{label:"Slow Only",enabled:i,onChange:p,icon:c})}),a.jsxs("div",{className:`${q} space-y-4 transition-all duration-200`,children:[a.jsx(Z,{placeholder:"Search by SQL, table, source, tag, or content..."}),a.jsx(H,{count:b,onClick:T,loading:s}),a.jsx(J,{columns:v,data:r,keyExtractor:e=>e.id,onRowClick:e=>h(`/queries/${e.id}`),rowClassName:e=>S(e.id)?"highlight-new":"",emptyMessage:"No queries recorded yet",emptyIcon:a.jsx(n,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),a.jsx(I,{hasMore:C,onClick:k,loading:s})]})]})}export{se as default};
1
+ import{j as a,D as n}from"./index-TmiQivGf.js";import{e as P,b as d}from"./vendor-B2nVRih0.js";import{u as A,C as M,f as Q,p as R}from"./ClickableBadge-DYNLPtLq.js";import{u as B,P as O,T as W,N as H,L as I}from"./PageHeader-q5aVtQHw.js";import{E as Z}from"./EntrySearchInput-DaH1CLjl.js";import{c as $,T as u,D as z,a as G,b as J}from"./types-DcORDHhK.js";import{Z as c}from"./zap-DEs_rIzA.js";import"./search-DS3CEfeI.js";function se(){const h=P(),[i,p]=d.useState(!1),{addFilter:l,clearAll:x,serverFilters:m,headerFilters:g,hasFilters:y}=A("queries"),f={...m,slow:i?!0:void 0},{entries:w,loading:j,refreshing:s,newEntriesCount:b,hasMore:C,loadMore:k,loadNew:T,autoRefreshEnabled:N,setAutoRefresh:E,meta:t,isHighlighted:S}=B({type:"query",limit:50,filters:f}),r=w.filter(e=>$(e)),v=d.useMemo(()=>[{key:"source",header:"Source",width:"120px",render:e=>a.jsx(M,{listType:"queries",filterType:"sources",children:e.payload.source||"unknown"})},{key:"query",header:"Query",minWidth:"300px",render:e=>a.jsxs("div",{className:"flex items-start space-x-2",children:[e.payload.slow&&a.jsx(c,{className:"h-4 w-4 text-yellow-500 flex-shrink-0 mt-0.5"}),a.jsx(u,{mono:!0,truncate:!0,maxWidth:"400px",children:e.payload.query.length>100?e.payload.query.substring(0,100)+"...":e.payload.query})]})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>a.jsx(z,{ms:e.payload.duration||0,slowThreshold:e.payload.slow?0:1e3})},{key:"tags",header:"Tags",minWidth:"150px",render:e=>{const D=(e.payload.source||"unknown").toLowerCase(),F=(e.tags||[]).filter(o=>o.toLowerCase()!==D);return a.jsx(G,{tags:F,max:3,onTagClick:(o,L)=>{L.stopPropagation(),l("tags",o)}})}},{key:"time",header:"Time",width:"170px",align:"right",render:e=>a.jsx(u,{secondary:!0,className:"text-xs",children:Q(R(e.createdAt),{addSuffix:!0})})}],[l]);if(j&&r.length===0)return a.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:a.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const q=y?"pt-28":"pt-16";return a.jsxs("div",{children:[a.jsx(O,{title:"Queries",icon:n,iconColor:"text-purple-600 dark:text-purple-400",count:r.length,totalCount:t==null?void 0:t.total,refreshing:s,autoRefreshEnabled:N,onAutoRefreshToggle:E,filters:g,onClearAllFilters:x,actions:a.jsx(W,{label:"Slow Only",enabled:i,onChange:p,icon:c})}),a.jsxs("div",{className:`${q} space-y-4 transition-all duration-200`,children:[a.jsx(Z,{placeholder:"Search by SQL, table, source, tag, or content..."}),a.jsx(H,{count:b,onClick:T,loading:s}),a.jsx(J,{columns:v,data:r,keyExtractor:e=>e.id,onRowClick:e=>h(`/queries/${e.id}`),rowClassName:e=>S(e.id)?"highlight-new":"",emptyMessage:"No queries recorded yet",emptyIcon:a.jsx(n,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),a.jsx(I,{hasMore:C,onClick:k,loading:s})]})]})}export{se as default};
@@ -1 +1 @@
1
- import{j as a,D as d}from"./index-6-E0lKi6.js";import{e as E,b as R}from"./vendor-B2nVRih0.js";import{u as D,C as l,f as v,p as F}from"./ClickableBadge-D2hks1Oq.js";import{u as T,P as A,N as M,L as B}from"./PageHeader-D5bOCFIP.js";import{m as L,T as n,D as H,b as S}from"./types-P3vOygE2.js";function q(){const c=E(),{addFilter:t,clearAll:m,serverFilters:u,headerFilters:h,hasFilters:p}=D("redis"),{entries:x,loading:g,refreshing:s,newEntriesCount:y,hasMore:f,loadMore:j,loadNew:k,autoRefreshEnabled:C,setAutoRefresh:w,meta:r,isHighlighted:N}=T({type:"redis",limit:50,filters:u}),o=x.filter(e=>L(e)),b=R.useMemo(()=>[{key:"command",header:"Command",width:"120px",render:e=>a.jsx(l,{onClick:i=>{i.stopPropagation(),t("commands",e.payload.command)},className:"font-mono",children:e.payload.command})},{key:"keyPattern",header:"Key Pattern",minWidth:"200px",render:e=>e.payload.keyPattern?a.jsx(n,{mono:!0,truncate:!0,maxWidth:"300px",children:e.payload.keyPattern}):a.jsx(n,{secondary:!0,children:"-"})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>a.jsx(H,{ms:e.payload.duration||0})},{key:"status",header:"Status",width:"100px",render:e=>a.jsx(l,{onClick:i=>{i.stopPropagation(),t("statuses",e.payload.status)},children:e.payload.status.toUpperCase()})},{key:"time",header:"Time",width:"170px",align:"right",render:e=>a.jsx(n,{secondary:!0,className:"text-xs",children:v(F(e.createdAt),{addSuffix:!0})})}],[t]);if(g&&o.length===0)return a.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:a.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const P=p?"pt-28":"pt-16";return a.jsxs("div",{children:[a.jsx(A,{title:"Redis",icon:d,iconColor:"text-red-600 dark:text-red-400",count:o.length,totalCount:r==null?void 0:r.total,refreshing:s,autoRefreshEnabled:C,onAutoRefreshToggle:w,filters:h,onClearAllFilters:m}),a.jsxs("div",{className:`${P} space-y-4 transition-all duration-200`,children:[a.jsx(M,{count:y,onClick:k,loading:s}),a.jsx(S,{columns:b,data:o,keyExtractor:e=>e.id,onRowClick:e=>c(`/redis/${e.id}`),rowClassName:e=>N(e.id)?"highlight-new":"",emptyMessage:"No Redis commands recorded yet",emptyIcon:a.jsx(d,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),a.jsx(B,{hasMore:f,onClick:j,loading:s})]})]})}export{q as default};
1
+ import{j as a,D as d}from"./index-TmiQivGf.js";import{e as E,b as R}from"./vendor-B2nVRih0.js";import{u as D,C as l,f as v,p as F}from"./ClickableBadge-DYNLPtLq.js";import{u as T,P as A,N as M,L as B}from"./PageHeader-q5aVtQHw.js";import{m as L,T as n,D as H,b as S}from"./types-DcORDHhK.js";function q(){const c=E(),{addFilter:t,clearAll:m,serverFilters:u,headerFilters:h,hasFilters:p}=D("redis"),{entries:x,loading:g,refreshing:s,newEntriesCount:y,hasMore:f,loadMore:j,loadNew:k,autoRefreshEnabled:C,setAutoRefresh:w,meta:r,isHighlighted:N}=T({type:"redis",limit:50,filters:u}),o=x.filter(e=>L(e)),b=R.useMemo(()=>[{key:"command",header:"Command",width:"120px",render:e=>a.jsx(l,{onClick:i=>{i.stopPropagation(),t("commands",e.payload.command)},className:"font-mono",children:e.payload.command})},{key:"keyPattern",header:"Key Pattern",minWidth:"200px",render:e=>e.payload.keyPattern?a.jsx(n,{mono:!0,truncate:!0,maxWidth:"300px",children:e.payload.keyPattern}):a.jsx(n,{secondary:!0,children:"-"})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>a.jsx(H,{ms:e.payload.duration||0})},{key:"status",header:"Status",width:"100px",render:e=>a.jsx(l,{onClick:i=>{i.stopPropagation(),t("statuses",e.payload.status)},children:e.payload.status.toUpperCase()})},{key:"time",header:"Time",width:"170px",align:"right",render:e=>a.jsx(n,{secondary:!0,className:"text-xs",children:v(F(e.createdAt),{addSuffix:!0})})}],[t]);if(g&&o.length===0)return a.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:a.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const P=p?"pt-28":"pt-16";return a.jsxs("div",{children:[a.jsx(A,{title:"Redis",icon:d,iconColor:"text-red-600 dark:text-red-400",count:o.length,totalCount:r==null?void 0:r.total,refreshing:s,autoRefreshEnabled:C,onAutoRefreshToggle:w,filters:h,onClearAllFilters:m}),a.jsxs("div",{className:`${P} space-y-4 transition-all duration-200`,children:[a.jsx(M,{count:y,onClick:k,loading:s}),a.jsx(S,{columns:b,data:o,keyExtractor:e=>e.id,onRowClick:e=>c(`/redis/${e.id}`),rowClassName:e=>N(e.id)?"highlight-new":"",emptyMessage:"No Redis commands recorded yet",emptyIcon:a.jsx(d,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),a.jsx(B,{hasMore:f,onClick:j,loading:s})]})]})}export{q as default};
@@ -1 +1 @@
1
- import{j as t,A as N,d as P}from"./index-6-E0lKi6.js";import{e as A,b as q}from"./vendor-B2nVRih0.js";import{u as R,C as l,f as D,p as v}from"./ClickableBadge-D2hks1Oq.js";import{u as L,P as M,N as F,L as H}from"./PageHeader-D5bOCFIP.js";import{E as S}from"./EntrySearchInput-CK8uj0H9.js";import{i as G,T as d,D as B,a as I,b as O}from"./types-P3vOygE2.js";import"./search-DQ8xACgM.js";const U=["GET","POST","PUT","PATCH","DELETE","HEAD","OPTIONS","GRAPHQL"],W=s=>{var a;return(a=s.payload.path)!=null&&a.toLowerCase().includes("/graphql")?"GRAPHQL":s.payload.method.toUpperCase()};function Y(){const s=A(),{addFilter:a,clearAll:u,serverFilters:h,headerFilters:c,hasFilters:p}=R("requests"),{entries:m,loading:g,refreshing:r,newEntriesCount:x,hasMore:y,loadMore:f,loadNew:j,autoRefreshEnabled:C,setAutoRefresh:T,meta:i,isHighlighted:E}=L({type:"request",limit:50,filters:h}),o=m.filter(e=>G(e)),b=q.useMemo(()=>[{key:"method",header:"Method",width:"100px",render:e=>t.jsx(l,{listType:"requests",filterType:"methods",children:W(e)})},{key:"path",header:"Path",minWidth:"200px",render:e=>t.jsx(d,{mono:!0,truncate:!0,maxWidth:"400px",children:e.payload.path})},{key:"status",header:"Status",width:"80px",align:"center",render:e=>t.jsx(l,{listType:"requests",filterType:"statuses",children:e.payload.statusCode||0})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>t.jsx(B,{ms:e.payload.duration||0})},{key:"tags",header:"Tags",minWidth:"150px",render:e=>t.jsx(I,{tags:(e.tags||[]).filter(n=>!U.includes(n.toUpperCase())),max:3,onTagClick:(n,w)=>{w.stopPropagation(),a("tags",n)}})},{key:"time",header:"Time",width:"170px",align:"right",render:e=>t.jsx(d,{secondary:!0,className:"text-xs",children:D(v(e.createdAt),{addSuffix:!0})})}],[a]);if(g&&o.length===0)return t.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:t.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const k=p?"pt-28":"pt-16";return t.jsxs("div",{children:[t.jsx(M,{title:"Requests",icon:N,iconColor:"text-blue-600 dark:text-blue-400",count:o.length,totalCount:i==null?void 0:i.total,refreshing:r,autoRefreshEnabled:C,onAutoRefreshToggle:T,filters:c,onClearAllFilters:u}),t.jsxs("div",{className:`${k} space-y-4 transition-all duration-200`,children:[t.jsx(S,{placeholder:"Search by path, method, status, tag, or content..."}),t.jsx(F,{count:x,onClick:j,loading:r}),t.jsx(O,{columns:b,data:o,keyExtractor:e=>e.id,onRowClick:e=>s(`/requests/${e.id}`),emptyMessage:"No requests recorded yet",emptyIcon:t.jsx(P,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"}),rowClassName:e=>E(e.id)?"highlight-new":""}),t.jsx(H,{hasMore:y,onClick:f,loading:r})]})]})}export{Y as default};
1
+ import{j as t,A as N,d as P}from"./index-TmiQivGf.js";import{e as A,b as q}from"./vendor-B2nVRih0.js";import{u as R,C as l,f as D,p as v}from"./ClickableBadge-DYNLPtLq.js";import{u as L,P as M,N as F,L as H}from"./PageHeader-q5aVtQHw.js";import{E as S}from"./EntrySearchInput-DaH1CLjl.js";import{i as G,T as d,D as B,a as I,b as O}from"./types-DcORDHhK.js";import"./search-DS3CEfeI.js";const U=["GET","POST","PUT","PATCH","DELETE","HEAD","OPTIONS","GRAPHQL"],W=s=>{var a;return(a=s.payload.path)!=null&&a.toLowerCase().includes("/graphql")?"GRAPHQL":s.payload.method.toUpperCase()};function Y(){const s=A(),{addFilter:a,clearAll:u,serverFilters:h,headerFilters:c,hasFilters:p}=R("requests"),{entries:m,loading:g,refreshing:r,newEntriesCount:x,hasMore:y,loadMore:f,loadNew:j,autoRefreshEnabled:C,setAutoRefresh:T,meta:i,isHighlighted:E}=L({type:"request",limit:50,filters:h}),o=m.filter(e=>G(e)),b=q.useMemo(()=>[{key:"method",header:"Method",width:"100px",render:e=>t.jsx(l,{listType:"requests",filterType:"methods",children:W(e)})},{key:"path",header:"Path",minWidth:"200px",render:e=>t.jsx(d,{mono:!0,truncate:!0,maxWidth:"400px",children:e.payload.path})},{key:"status",header:"Status",width:"80px",align:"center",render:e=>t.jsx(l,{listType:"requests",filterType:"statuses",children:e.payload.statusCode||0})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>t.jsx(B,{ms:e.payload.duration||0})},{key:"tags",header:"Tags",minWidth:"150px",render:e=>t.jsx(I,{tags:(e.tags||[]).filter(n=>!U.includes(n.toUpperCase())),max:3,onTagClick:(n,w)=>{w.stopPropagation(),a("tags",n)}})},{key:"time",header:"Time",width:"170px",align:"right",render:e=>t.jsx(d,{secondary:!0,className:"text-xs",children:D(v(e.createdAt),{addSuffix:!0})})}],[a]);if(g&&o.length===0)return t.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:t.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const k=p?"pt-28":"pt-16";return t.jsxs("div",{children:[t.jsx(M,{title:"Requests",icon:N,iconColor:"text-blue-600 dark:text-blue-400",count:o.length,totalCount:i==null?void 0:i.total,refreshing:r,autoRefreshEnabled:C,onAutoRefreshToggle:T,filters:c,onClearAllFilters:u}),t.jsxs("div",{className:`${k} space-y-4 transition-all duration-200`,children:[t.jsx(S,{placeholder:"Search by path, method, status, tag, or content..."}),t.jsx(F,{count:x,onClick:j,loading:r}),t.jsx(O,{columns:b,data:o,keyExtractor:e=>e.id,onRowClick:e=>s(`/requests/${e.id}`),emptyMessage:"No requests recorded yet",emptyIcon:t.jsx(P,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"}),rowClassName:e=>E(e.id)?"highlight-new":""}),t.jsx(H,{hasMore:y,onClick:f,loading:r})]})]})}export{Y as default};
@@ -1 +1 @@
1
- import{j as a,C as c}from"./index-6-E0lKi6.js";import{e as M,b as P}from"./vendor-B2nVRih0.js";import{f as u,c as A}from"./format-BFldcnCk.js";import{u as L,C as h,f as R,p as H}from"./ClickableBadge-D2hks1Oq.js";import{u as B,P as W,N as $,L as I}from"./PageHeader-D5bOCFIP.js";import{k as q,T as i,D as z,a as G,b as J}from"./types-P3vOygE2.js";const K=["started","completed","failed"];function m(t){try{return A.toString(t)}catch{return null}}function Z(){const t=M(),{addFilter:n,clearAll:p,serverFilters:x,headerFilters:g,hasFilters:f}=L("schedule"),{entries:y,loading:k,refreshing:s,newEntriesCount:j,hasMore:C,loadMore:N,loadNew:T,autoRefreshEnabled:v,setAutoRefresh:w,meta:r,isHighlighted:b}=B({type:"schedule",limit:50,filters:x}),l=y.filter(e=>q(e)),d=e=>e.payload.cron?e.payload.cron:e.payload.interval?`${e.payload.interval}ms`:"-",E=P.useMemo(()=>[{key:"task",header:"Task",minWidth:"200px",render:e=>a.jsx(h,{listType:"schedule",filterType:"names",className:"font-mono",children:e.payload.name})},{key:"schedule",header:"Schedule",minWidth:"150px",render:e=>a.jsxs("div",{children:[a.jsx(i,{mono:!0,children:d(e)}),e.payload.cron&&m(e.payload.cron)&&a.jsx("span",{className:"text-xs text-gray-500 dark:text-gray-400 block mt-0.5",children:m(e.payload.cron)}),e.payload.interval&&u(e.payload.interval)&&a.jsx("span",{className:"text-xs text-gray-500 dark:text-gray-400 block mt-0.5",children:u(e.payload.interval)})]})},{key:"status",header:"Status",width:"100px",render:e=>a.jsx(h,{listType:"schedule",filterType:"statuses",children:e.payload.status})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>e.payload.duration?a.jsx(z,{ms:e.payload.duration}):a.jsx(i,{secondary:!0,children:"—"})},{key:"tags",header:"Tags",minWidth:"150px",render:e=>{const D=(e.tags||[]).filter(o=>!K.includes(o.toLowerCase()));return a.jsx(G,{tags:D,max:3,onTagClick:(o,F)=>{F.stopPropagation(),n("tags",o)}})}},{key:"time",header:"Time",width:"170px",align:"right",render:e=>a.jsx(i,{secondary:!0,className:"text-xs",children:R(H(e.createdAt),{addSuffix:!0})})}],[n,d]);if(k&&l.length===0)return a.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:a.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const S=f?"pt-28":"pt-16";return a.jsxs("div",{children:[a.jsx(W,{title:"Schedule",icon:c,iconColor:"text-gray-600 dark:text-gray-400",count:l.length,totalCount:r==null?void 0:r.total,refreshing:s,autoRefreshEnabled:v,onAutoRefreshToggle:w,filters:g,onClearAllFilters:p}),a.jsxs("div",{className:`${S} space-y-4 transition-all duration-200`,children:[a.jsx($,{count:j,onClick:T,loading:s}),a.jsx(J,{columns:E,data:l,keyExtractor:e=>e.id,onRowClick:e=>t(`/schedule/${e.id}`),rowClassName:e=>b(e.id)?"highlight-new":"",emptyMessage:"No scheduled tasks recorded yet",emptyIcon:a.jsx(c,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),a.jsx(I,{hasMore:C,onClick:N,loading:s})]})]})}export{Z as default};
1
+ import{j as a,C as c}from"./index-TmiQivGf.js";import{e as M,b as P}from"./vendor-B2nVRih0.js";import{f as u,c as A}from"./format-BFldcnCk.js";import{u as L,C as h,f as R,p as H}from"./ClickableBadge-DYNLPtLq.js";import{u as B,P as W,N as $,L as I}from"./PageHeader-q5aVtQHw.js";import{k as q,T as i,D as z,a as G,b as J}from"./types-DcORDHhK.js";const K=["started","completed","failed"];function m(t){try{return A.toString(t)}catch{return null}}function Z(){const t=M(),{addFilter:n,clearAll:p,serverFilters:x,headerFilters:g,hasFilters:f}=L("schedule"),{entries:y,loading:k,refreshing:s,newEntriesCount:j,hasMore:C,loadMore:N,loadNew:T,autoRefreshEnabled:v,setAutoRefresh:w,meta:r,isHighlighted:b}=B({type:"schedule",limit:50,filters:x}),l=y.filter(e=>q(e)),d=e=>e.payload.cron?e.payload.cron:e.payload.interval?`${e.payload.interval}ms`:"-",E=P.useMemo(()=>[{key:"task",header:"Task",minWidth:"200px",render:e=>a.jsx(h,{listType:"schedule",filterType:"names",className:"font-mono",children:e.payload.name})},{key:"schedule",header:"Schedule",minWidth:"150px",render:e=>a.jsxs("div",{children:[a.jsx(i,{mono:!0,children:d(e)}),e.payload.cron&&m(e.payload.cron)&&a.jsx("span",{className:"text-xs text-gray-500 dark:text-gray-400 block mt-0.5",children:m(e.payload.cron)}),e.payload.interval&&u(e.payload.interval)&&a.jsx("span",{className:"text-xs text-gray-500 dark:text-gray-400 block mt-0.5",children:u(e.payload.interval)})]})},{key:"status",header:"Status",width:"100px",render:e=>a.jsx(h,{listType:"schedule",filterType:"statuses",children:e.payload.status})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>e.payload.duration?a.jsx(z,{ms:e.payload.duration}):a.jsx(i,{secondary:!0,children:"—"})},{key:"tags",header:"Tags",minWidth:"150px",render:e=>{const D=(e.tags||[]).filter(o=>!K.includes(o.toLowerCase()));return a.jsx(G,{tags:D,max:3,onTagClick:(o,F)=>{F.stopPropagation(),n("tags",o)}})}},{key:"time",header:"Time",width:"170px",align:"right",render:e=>a.jsx(i,{secondary:!0,className:"text-xs",children:R(H(e.createdAt),{addSuffix:!0})})}],[n,d]);if(k&&l.length===0)return a.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:a.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const S=f?"pt-28":"pt-16";return a.jsxs("div",{children:[a.jsx(W,{title:"Schedule",icon:c,iconColor:"text-gray-600 dark:text-gray-400",count:l.length,totalCount:r==null?void 0:r.total,refreshing:s,autoRefreshEnabled:v,onAutoRefreshToggle:w,filters:g,onClearAllFilters:p}),a.jsxs("div",{className:`${S} space-y-4 transition-all duration-200`,children:[a.jsx($,{count:j,onClick:T,loading:s}),a.jsx(J,{columns:E,data:l,keyExtractor:e=>e.id,onRowClick:e=>t(`/schedule/${e.id}`),rowClassName:e=>b(e.id)?"highlight-new":"",emptyMessage:"No scheduled tasks recorded yet",emptyIcon:a.jsx(c,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),a.jsx(I,{hasMore:C,onClick:N,loading:s})]})]})}export{Z as default};
@@ -1 +1 @@
1
- import{j as a}from"./index-6-E0lKi6.js";import{e as b,b as F}from"./vendor-B2nVRih0.js";import{u as P,C as n,f as T,p as D}from"./ClickableBadge-D2hks1Oq.js";import{u as A,P as M,N as R,L as H}from"./PageHeader-D5bOCFIP.js";import{p as B,T as t,D as L,b as V}from"./types-P3vOygE2.js";import{E as d}from"./eye-CBVB8boI.js";function q(){const c=b(),{addFilter:r,clearAll:h,serverFilters:m,headerFilters:p,hasFilters:u}=P("views"),{entries:x,loading:g,refreshing:s,newEntriesCount:f,hasMore:y,loadMore:w,loadNew:j,autoRefreshEnabled:C,setAutoRefresh:k,meta:i,isHighlighted:N}=A({type:"view",limit:50,filters:m}),o=x.filter(e=>B(e)),v=F.useMemo(()=>[{key:"template",header:"Template",minWidth:"250px",render:e=>a.jsx(t,{mono:!0,truncate:!0,maxWidth:"350px",children:e.payload.template})},{key:"format",header:"Format",width:"100px",render:e=>e.payload.format?a.jsx(n,{onClick:l=>{l.stopPropagation(),r("formats",e.payload.format)},className:"font-mono",children:e.payload.format}):a.jsx(t,{secondary:!0,children:"-"})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>a.jsx(L,{ms:e.payload.duration||0})},{key:"status",header:"Status",width:"100px",render:e=>a.jsx(n,{onClick:l=>{l.stopPropagation(),r("statuses",e.payload.status)},children:e.payload.status.toUpperCase()})},{key:"cache",header:"Cache",width:"80px",align:"center",render:e=>e.payload.cacheHit!==void 0?a.jsx(t,{children:e.payload.cacheHit?"Yes":"No"}):a.jsx(t,{secondary:!0,children:"-"})},{key:"time",header:"Time",width:"170px",align:"right",render:e=>a.jsx(t,{secondary:!0,className:"text-xs",children:T(D(e.createdAt),{addSuffix:!0})})}],[r]);if(g&&o.length===0)return a.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:a.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const E=u?"pt-28":"pt-16";return a.jsxs("div",{children:[a.jsx(M,{title:"Views",icon:d,iconColor:"text-teal-600 dark:text-teal-400",count:o.length,totalCount:i==null?void 0:i.total,refreshing:s,autoRefreshEnabled:C,onAutoRefreshToggle:k,filters:p,onClearAllFilters:h}),a.jsxs("div",{className:`${E} space-y-4 transition-all duration-200`,children:[a.jsx(R,{count:f,onClick:j,loading:s}),a.jsx(V,{columns:v,data:o,keyExtractor:e=>e.id,onRowClick:e=>c(`/views/${e.id}`),rowClassName:e=>N(e.id)?"highlight-new":"",emptyMessage:"No view renders recorded yet",emptyIcon:a.jsx(d,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),a.jsx(H,{hasMore:y,onClick:w,loading:s})]})]})}export{q as default};
1
+ import{j as a}from"./index-TmiQivGf.js";import{e as b,b as F}from"./vendor-B2nVRih0.js";import{u as P,C as n,f as T,p as D}from"./ClickableBadge-DYNLPtLq.js";import{u as A,P as M,N as R,L as H}from"./PageHeader-q5aVtQHw.js";import{p as B,T as t,D as L,b as V}from"./types-DcORDHhK.js";import{E as d}from"./eye-csDSrPe6.js";function q(){const c=b(),{addFilter:r,clearAll:h,serverFilters:m,headerFilters:p,hasFilters:u}=P("views"),{entries:x,loading:g,refreshing:s,newEntriesCount:f,hasMore:y,loadMore:w,loadNew:j,autoRefreshEnabled:C,setAutoRefresh:k,meta:i,isHighlighted:N}=A({type:"view",limit:50,filters:m}),o=x.filter(e=>B(e)),v=F.useMemo(()=>[{key:"template",header:"Template",minWidth:"250px",render:e=>a.jsx(t,{mono:!0,truncate:!0,maxWidth:"350px",children:e.payload.template})},{key:"format",header:"Format",width:"100px",render:e=>e.payload.format?a.jsx(n,{onClick:l=>{l.stopPropagation(),r("formats",e.payload.format)},className:"font-mono",children:e.payload.format}):a.jsx(t,{secondary:!0,children:"-"})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>a.jsx(L,{ms:e.payload.duration||0})},{key:"status",header:"Status",width:"100px",render:e=>a.jsx(n,{onClick:l=>{l.stopPropagation(),r("statuses",e.payload.status)},children:e.payload.status.toUpperCase()})},{key:"cache",header:"Cache",width:"80px",align:"center",render:e=>e.payload.cacheHit!==void 0?a.jsx(t,{children:e.payload.cacheHit?"Yes":"No"}):a.jsx(t,{secondary:!0,children:"-"})},{key:"time",header:"Time",width:"170px",align:"right",render:e=>a.jsx(t,{secondary:!0,className:"text-xs",children:T(D(e.createdAt),{addSuffix:!0})})}],[r]);if(g&&o.length===0)return a.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:a.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const E=u?"pt-28":"pt-16";return a.jsxs("div",{children:[a.jsx(M,{title:"Views",icon:d,iconColor:"text-teal-600 dark:text-teal-400",count:o.length,totalCount:i==null?void 0:i.total,refreshing:s,autoRefreshEnabled:C,onAutoRefreshToggle:k,filters:p,onClearAllFilters:h}),a.jsxs("div",{className:`${E} space-y-4 transition-all duration-200`,children:[a.jsx(R,{count:f,onClick:j,loading:s}),a.jsx(V,{columns:v,data:o,keyExtractor:e=>e.id,onRowClick:e=>c(`/views/${e.id}`),rowClassName:e=>N(e.id)?"highlight-new":"",emptyMessage:"No view renders recorded yet",emptyIcon:a.jsx(d,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),a.jsx(H,{hasMore:y,onClick:w,loading:s})]})]})}export{q as default};
@@ -1,4 +1,4 @@
1
- import{c as e}from"./index-6-E0lKi6.js";/**
1
+ import{c as e}from"./index-TmiQivGf.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,4 +1,4 @@
1
- import{c}from"./index-6-E0lKi6.js";/**
1
+ import{c}from"./index-TmiQivGf.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,4 +1,4 @@
1
- import{c}from"./index-6-E0lKi6.js";/**
1
+ import{c}from"./index-TmiQivGf.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.