@geekmidas/constructs 10.0.0-alpha.14 → 10.0.0-alpha.141

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 (454) hide show
  1. package/README.md +222 -158
  2. package/dist/Construct-127M7yrl.d.cts +231 -0
  3. package/dist/Construct-127M7yrl.d.cts.map +1 -0
  4. package/dist/{Construct-BeYVu_QF.mjs → Construct-CGuc_Ijk.mjs} +8 -9
  5. package/dist/Construct-CGuc_Ijk.mjs.map +1 -0
  6. package/dist/{Construct-DqdlARxq.cjs → Construct-DorKS0Ua.cjs} +8 -9
  7. package/dist/Construct-DorKS0Ua.cjs.map +1 -0
  8. package/dist/Construct-DySlwh8o.d.mts +231 -0
  9. package/dist/Construct-DySlwh8o.d.mts.map +1 -0
  10. package/dist/{Cron-DKqnnTdH.d.cts → Cron-CFkpEys6.d.cts} +14 -7
  11. package/dist/Cron-CFkpEys6.d.cts.map +1 -0
  12. package/dist/{Cron-SyqS5oWJ.d.mts → Cron-CQoDSu-n.d.mts} +14 -7
  13. package/dist/Cron-CQoDSu-n.d.mts.map +1 -0
  14. package/dist/CronBuilder-1W-G_i15.d.mts +47 -0
  15. package/dist/CronBuilder-1W-G_i15.d.mts.map +1 -0
  16. package/dist/{CronBuilder-D_0HNBTr.mjs → CronBuilder-BJ5LoadF.mjs} +28 -11
  17. package/dist/CronBuilder-BJ5LoadF.mjs.map +1 -0
  18. package/dist/{CronBuilder-BdnI6lxF.cjs → CronBuilder-B_NSP-Y5.cjs} +27 -10
  19. package/dist/CronBuilder-B_NSP-Y5.cjs.map +1 -0
  20. package/dist/CronBuilder-OaCRRFVk.d.cts +47 -0
  21. package/dist/CronBuilder-OaCRRFVk.d.cts.map +1 -0
  22. package/dist/{Endpoint-C6yyHpRS.d.cts → Endpoint-BEh-jW-f.d.cts} +122 -41
  23. package/dist/Endpoint-BEh-jW-f.d.cts.map +1 -0
  24. package/dist/Endpoint-BcUorcBa.cjs +576 -0
  25. package/dist/Endpoint-BcUorcBa.cjs.map +1 -0
  26. package/dist/Endpoint-BgvG36NO.mjs +547 -0
  27. package/dist/Endpoint-BgvG36NO.mjs.map +1 -0
  28. package/dist/{Endpoint-DuT4TEEq.d.mts → Endpoint-DTXDggNl.d.mts} +124 -43
  29. package/dist/Endpoint-DTXDggNl.d.mts.map +1 -0
  30. package/dist/{index-BPSZ_Lp_.d.cts → EndpointFactory-B2dCS9dy.d.cts} +187 -104
  31. package/dist/EndpointFactory-B2dCS9dy.d.cts.map +1 -0
  32. package/dist/{EndpointFactory-Bm3aKRdV.mjs → EndpointFactory-C1NlpCAS.mjs} +269 -53
  33. package/dist/EndpointFactory-C1NlpCAS.mjs.map +1 -0
  34. package/dist/{index-BoZ-iisU.d.mts → EndpointFactory-D2HXcUrJ.d.mts} +188 -105
  35. package/dist/EndpointFactory-D2HXcUrJ.d.mts.map +1 -0
  36. package/dist/{EndpointFactory-CLvWuHyt.cjs → EndpointFactory-gqmIRVWg.cjs} +309 -51
  37. package/dist/EndpointFactory-gqmIRVWg.cjs.map +1 -0
  38. package/dist/Function-BIEsY0Hm.d.cts +76 -0
  39. package/dist/Function-BIEsY0Hm.d.cts.map +1 -0
  40. package/dist/Function-DfMzTGS4.d.mts +76 -0
  41. package/dist/Function-DfMzTGS4.d.mts.map +1 -0
  42. package/dist/{HonoEndpointAdaptor-92zavCsV.cjs → HonoEndpointAdaptor-BJlj20fQ.cjs} +79 -31
  43. package/dist/HonoEndpointAdaptor-BJlj20fQ.cjs.map +1 -0
  44. package/dist/{HonoEndpointAdaptor-yYaU7jVJ.mjs → HonoEndpointAdaptor-BlbkUDNo.mjs} +76 -28
  45. package/dist/HonoEndpointAdaptor-BlbkUDNo.mjs.map +1 -0
  46. package/dist/ObjectSubscriberBuilder-BuuaYcrm.d.cts +129 -0
  47. package/dist/ObjectSubscriberBuilder-BuuaYcrm.d.cts.map +1 -0
  48. package/dist/ObjectSubscriberBuilder-CzgYmOUH.d.mts +129 -0
  49. package/dist/ObjectSubscriberBuilder-CzgYmOUH.d.mts.map +1 -0
  50. package/dist/ProcessorBuilder-B2_stA8f.d.mts +216 -0
  51. package/dist/ProcessorBuilder-B2_stA8f.d.mts.map +1 -0
  52. package/dist/ProcessorBuilder-C62bIOwj.d.cts +216 -0
  53. package/dist/ProcessorBuilder-C62bIOwj.d.cts.map +1 -0
  54. package/dist/{Queue-D9X6OoON.d.mts → Queue-BnK3UH8r.d.mts} +42 -41
  55. package/dist/Queue-BnK3UH8r.d.mts.map +1 -0
  56. package/dist/{Queue-DYPB2KWL.d.cts → Queue-C4rijiM7.d.cts} +43 -42
  57. package/dist/Queue-C4rijiM7.d.cts.map +1 -0
  58. package/dist/Queue-D4Iaidrs.cjs +109 -0
  59. package/dist/Queue-D4Iaidrs.cjs.map +1 -0
  60. package/dist/Queue-u8w8_HpE.mjs +104 -0
  61. package/dist/Queue-u8w8_HpE.mjs.map +1 -0
  62. package/dist/QueueBuilder-2wP5lEC8.mjs +118 -0
  63. package/dist/QueueBuilder-2wP5lEC8.mjs.map +1 -0
  64. package/dist/QueueBuilder-B3vL1ED2.d.mts +75 -0
  65. package/dist/QueueBuilder-B3vL1ED2.d.mts.map +1 -0
  66. package/dist/QueueBuilder-BcPBQSSX.d.cts +75 -0
  67. package/dist/QueueBuilder-BcPBQSSX.d.cts.map +1 -0
  68. package/dist/QueueBuilder-BxsZ9o5z.cjs +135 -0
  69. package/dist/QueueBuilder-BxsZ9o5z.cjs.map +1 -0
  70. package/dist/Subscriber-5rCX1Nph.d.cts +83 -0
  71. package/dist/Subscriber-5rCX1Nph.d.cts.map +1 -0
  72. package/dist/Subscriber-CW_Dl-YR.d.mts +83 -0
  73. package/dist/Subscriber-CW_Dl-YR.d.mts.map +1 -0
  74. package/dist/SubscriberBuilder-BL_GTcwh.mjs +237 -0
  75. package/dist/SubscriberBuilder-BL_GTcwh.mjs.map +1 -0
  76. package/dist/SubscriberBuilder-CWzKwX1p.cjs +260 -0
  77. package/dist/SubscriberBuilder-CWzKwX1p.cjs.map +1 -0
  78. package/dist/Topic-DN2gYJ-p.mjs +99 -0
  79. package/dist/Topic-DN2gYJ-p.mjs.map +1 -0
  80. package/dist/Topic-Dp9Q7Lj2.cjs +104 -0
  81. package/dist/Topic-Dp9Q7Lj2.cjs.map +1 -0
  82. package/dist/adaptors/aws.cjs +134 -160
  83. package/dist/adaptors/aws.cjs.map +1 -1
  84. package/dist/adaptors/aws.d.cts +57 -48
  85. package/dist/adaptors/aws.d.cts.map +1 -1
  86. package/dist/adaptors/aws.d.mts +58 -49
  87. package/dist/adaptors/aws.d.mts.map +1 -1
  88. package/dist/adaptors/aws.mjs +130 -157
  89. package/dist/adaptors/aws.mjs.map +1 -1
  90. package/dist/adaptors/hono.cjs +1 -1
  91. package/dist/adaptors/hono.d.cts +5 -6
  92. package/dist/adaptors/hono.d.cts.map +1 -1
  93. package/dist/adaptors/hono.d.mts +6 -7
  94. package/dist/adaptors/hono.d.mts.map +1 -1
  95. package/dist/adaptors/hono.mjs +1 -1
  96. package/dist/adaptors/testing.cjs +955 -38
  97. package/dist/adaptors/testing.cjs.map +1 -1
  98. package/dist/adaptors/testing.d.cts +437 -39
  99. package/dist/adaptors/testing.d.cts.map +1 -1
  100. package/dist/adaptors/testing.d.mts +436 -38
  101. package/dist/adaptors/testing.d.mts.map +1 -1
  102. package/dist/adaptors/testing.mjs +929 -34
  103. package/dist/adaptors/testing.mjs.map +1 -1
  104. package/dist/auth-BMCJN30Y.d.cts +268 -0
  105. package/dist/auth-BMCJN30Y.d.cts.map +1 -0
  106. package/dist/auth-D_0788uW.d.mts +268 -0
  107. package/dist/auth-D_0788uW.d.mts.map +1 -0
  108. package/dist/auth.cjs +290 -46
  109. package/dist/auth.cjs.map +1 -1
  110. package/dist/auth.d.cts +2 -104
  111. package/dist/auth.d.mts +2 -104
  112. package/dist/auth.mjs +286 -48
  113. package/dist/auth.mjs.map +1 -1
  114. package/dist/cache-5QZzh5Er.d.mts +44 -0
  115. package/dist/cache-5QZzh5Er.d.mts.map +1 -0
  116. package/dist/cache-DnGDGly3.d.cts +44 -0
  117. package/dist/cache-DnGDGly3.d.cts.map +1 -0
  118. package/dist/cache.d.cts +2 -43
  119. package/dist/cache.d.mts +2 -43
  120. package/dist/cipher-C1lEFX63.mjs +225 -0
  121. package/dist/cipher-C1lEFX63.mjs.map +1 -0
  122. package/dist/cipher-CVxfwLjk.cjs +332 -0
  123. package/dist/cipher-CVxfwLjk.cjs.map +1 -0
  124. package/dist/cipher-DSDxPRIp.d.cts +106 -0
  125. package/dist/cipher-DSDxPRIp.d.cts.map +1 -0
  126. package/dist/cipher-DSDxPRIp.d.mts +106 -0
  127. package/dist/cipher-DSDxPRIp.d.mts.map +1 -0
  128. package/dist/{construct-interface-DPlxfpoS.d.mts → construct-interface-B1AfqRl4.d.cts} +42 -8
  129. package/dist/construct-interface-B1AfqRl4.d.cts.map +1 -0
  130. package/dist/{construct-interface-DgXTJcOD.d.cts → construct-interface-ZvYQbivO.d.mts} +42 -8
  131. package/dist/construct-interface-ZvYQbivO.d.mts.map +1 -0
  132. package/dist/construct-interface.cjs +30 -4
  133. package/dist/construct-interface.cjs.map +1 -1
  134. package/dist/construct-interface.d.cts +2 -2
  135. package/dist/construct-interface.d.mts +2 -2
  136. package/dist/construct-interface.mjs +30 -5
  137. package/dist/construct-interface.mjs.map +1 -1
  138. package/dist/credential-DYymbp_7.cjs +257 -0
  139. package/dist/credential-DYymbp_7.cjs.map +1 -0
  140. package/dist/credential-DfSAOOdY.mjs +222 -0
  141. package/dist/credential-DfSAOOdY.mjs.map +1 -0
  142. package/dist/credential.cjs +7 -129
  143. package/dist/credential.d.cts +2 -58
  144. package/dist/credential.d.mts +2 -58
  145. package/dist/credential.mjs +2 -128
  146. package/dist/crons/index.cjs +126 -1
  147. package/dist/crons/index.cjs.map +1 -1
  148. package/dist/crons/index.d.cts +43 -3
  149. package/dist/crons/index.d.cts.map +1 -1
  150. package/dist/crons/index.d.mts +43 -3
  151. package/dist/crons/index.d.mts.map +1 -1
  152. package/dist/crons/index.mjs +125 -2
  153. package/dist/crons/index.mjs.map +1 -1
  154. package/dist/database/kysely.cjs +3 -194
  155. package/dist/database/kysely.d.cts +2 -149
  156. package/dist/database/kysely.d.mts +2 -149
  157. package/dist/database/kysely.mjs +2 -192
  158. package/dist/email.d.cts +1 -1
  159. package/dist/email.d.cts.map +1 -1
  160. package/dist/email.d.mts +2 -2
  161. package/dist/email.d.mts.map +1 -1
  162. package/dist/encryption/kms.cjs +95 -0
  163. package/dist/encryption/kms.cjs.map +1 -0
  164. package/dist/encryption/kms.d.cts +7 -0
  165. package/dist/encryption/kms.d.cts.map +1 -0
  166. package/dist/encryption/kms.d.mts +7 -0
  167. package/dist/encryption/kms.d.mts.map +1 -0
  168. package/dist/encryption/kms.mjs +93 -0
  169. package/dist/encryption/kms.mjs.map +1 -0
  170. package/dist/encryption.cjs +116 -0
  171. package/dist/encryption.cjs.map +1 -0
  172. package/dist/encryption.d.cts +37 -0
  173. package/dist/encryption.d.cts.map +1 -0
  174. package/dist/encryption.d.mts +37 -0
  175. package/dist/encryption.d.mts.map +1 -0
  176. package/dist/encryption.mjs +101 -0
  177. package/dist/encryption.mjs.map +1 -0
  178. package/dist/endpoints/index.cjs +32 -10
  179. package/dist/endpoints/index.d.cts +106 -3
  180. package/dist/endpoints/index.d.cts.map +1 -0
  181. package/dist/endpoints/index.d.mts +106 -3
  182. package/dist/endpoints/index.d.mts.map +1 -0
  183. package/dist/endpoints/index.mjs +6 -4
  184. package/dist/expire-C586zznE.d.cts +38 -0
  185. package/dist/expire-C586zznE.d.cts.map +1 -0
  186. package/dist/expire-C586zznE.d.mts +38 -0
  187. package/dist/expire-C586zznE.d.mts.map +1 -0
  188. package/dist/expire-CieftS01.cjs +67 -0
  189. package/dist/expire-CieftS01.cjs.map +1 -0
  190. package/dist/expire-CpzUAfr9.mjs +50 -0
  191. package/dist/expire-CpzUAfr9.mjs.map +1 -0
  192. package/dist/external-api.cjs +106 -0
  193. package/dist/external-api.cjs.map +1 -0
  194. package/dist/external-api.d.cts +2 -0
  195. package/dist/external-api.d.mts +2 -0
  196. package/dist/external-api.mjs +103 -0
  197. package/dist/external-api.mjs.map +1 -0
  198. package/dist/fake-BUgcX2Dk.d.cts +201 -0
  199. package/dist/fake-BUgcX2Dk.d.cts.map +1 -0
  200. package/dist/fake-D472nkKb.d.mts +201 -0
  201. package/dist/fake-D472nkKb.d.mts.map +1 -0
  202. package/dist/file-server.cjs +123 -30
  203. package/dist/file-server.cjs.map +1 -1
  204. package/dist/file-server.d.cts +115 -1
  205. package/dist/file-server.d.cts.map +1 -1
  206. package/dist/file-server.d.mts +115 -1
  207. package/dist/file-server.d.mts.map +1 -1
  208. package/dist/file-server.mjs +122 -32
  209. package/dist/file-server.mjs.map +1 -1
  210. package/dist/functions/index.cjs +1 -1
  211. package/dist/functions/index.d.cts +2 -1
  212. package/dist/functions/index.d.mts +2 -1
  213. package/dist/functions/index.mjs +1 -1
  214. package/dist/{functions-C53GW2eQ.mjs → functions-BvIDQKAA.mjs} +117 -22
  215. package/dist/functions-BvIDQKAA.mjs.map +1 -0
  216. package/dist/{functions-B6qCvfmy.cjs → functions-DLF6-IK8.cjs} +122 -18
  217. package/dist/functions-DLF6-IK8.cjs.map +1 -0
  218. package/dist/inbox-DZdICa8F.d.mts +195 -0
  219. package/dist/inbox-DZdICa8F.d.mts.map +1 -0
  220. package/dist/inbox-DqaxrpEk.d.cts +195 -0
  221. package/dist/inbox-DqaxrpEk.d.cts.map +1 -0
  222. package/dist/inbox.cjs +291 -0
  223. package/dist/inbox.cjs.map +1 -0
  224. package/dist/inbox.d.cts +2 -0
  225. package/dist/inbox.d.mts +2 -0
  226. package/dist/inbox.mjs +283 -0
  227. package/dist/inbox.mjs.map +1 -0
  228. package/dist/index-BtzMzhMA.d.cts +115 -0
  229. package/dist/index-BtzMzhMA.d.cts.map +1 -0
  230. package/dist/{index-CeEtxDmK.d.cts → index-DdRjYhiJ.d.cts} +42 -2
  231. package/dist/{index-CeEtxDmK.d.cts.map → index-DdRjYhiJ.d.cts.map} +1 -1
  232. package/dist/{index-CeEtxDmK.d.mts → index-DdRjYhiJ.d.mts} +42 -2
  233. package/dist/{index-CeEtxDmK.d.mts.map → index-DdRjYhiJ.d.mts.map} +1 -1
  234. package/dist/index-DuriFjYD.d.mts +115 -0
  235. package/dist/index-DuriFjYD.d.mts.map +1 -0
  236. package/dist/index.cjs +4 -1
  237. package/dist/index.d.cts +26 -3
  238. package/dist/index.d.cts.map +1 -0
  239. package/dist/index.d.mts +26 -3
  240. package/dist/index.d.mts.map +1 -0
  241. package/dist/index.mjs +3 -2
  242. package/dist/kysely-BHYV-WC-.d.cts +216 -0
  243. package/dist/kysely-BHYV-WC-.d.cts.map +1 -0
  244. package/dist/kysely-CAW3QSqp.d.mts +216 -0
  245. package/dist/kysely-CAW3QSqp.d.mts.map +1 -0
  246. package/dist/kysely-Cs4uPO8k.mjs +371 -0
  247. package/dist/kysely-Cs4uPO8k.mjs.map +1 -0
  248. package/dist/kysely-CukArHJ0.cjs +384 -0
  249. package/dist/kysely-CukArHJ0.cjs.map +1 -0
  250. package/dist/{telemetry-DGcFlVpB.d.cts → lambdaTelemetry-8vnmVZQ5.d.cts} +2 -2
  251. package/dist/lambdaTelemetry-8vnmVZQ5.d.cts.map +1 -0
  252. package/dist/{telemetry-DGcFlVpB.d.mts → lambdaTelemetry-8vnmVZQ5.d.mts} +2 -2
  253. package/dist/lambdaTelemetry-8vnmVZQ5.d.mts.map +1 -0
  254. package/dist/mobile-app.cjs +74 -0
  255. package/dist/mobile-app.cjs.map +1 -0
  256. package/dist/mobile-app.d.cts +73 -0
  257. package/dist/mobile-app.d.cts.map +1 -0
  258. package/dist/mobile-app.d.mts +73 -0
  259. package/dist/mobile-app.d.mts.map +1 -0
  260. package/dist/mobile-app.mjs +73 -0
  261. package/dist/mobile-app.mjs.map +1 -0
  262. package/dist/object-storage.cjs +8 -1
  263. package/dist/object-storage.cjs.map +1 -1
  264. package/dist/object-storage.d.cts +10 -1
  265. package/dist/object-storage.d.cts.map +1 -1
  266. package/dist/object-storage.d.mts +10 -1
  267. package/dist/object-storage.d.mts.map +1 -1
  268. package/dist/object-storage.mjs +7 -2
  269. package/dist/object-storage.mjs.map +1 -1
  270. package/dist/pattern-C1CEcglD.mjs +241 -0
  271. package/dist/pattern-C1CEcglD.mjs.map +1 -0
  272. package/dist/pattern-QFaUIr77.cjs +288 -0
  273. package/dist/pattern-QFaUIr77.cjs.map +1 -0
  274. package/dist/processors/index.cjs +214 -0
  275. package/dist/processors/index.cjs.map +1 -0
  276. package/dist/processors/index.d.cts +78 -0
  277. package/dist/processors/index.d.cts.map +1 -0
  278. package/dist/processors/index.d.mts +78 -0
  279. package/dist/processors/index.d.mts.map +1 -0
  280. package/dist/processors/index.mjs +193 -0
  281. package/dist/processors/index.mjs.map +1 -0
  282. package/dist/queue/index.cjs +5 -192
  283. package/dist/queue/index.d.cts +3 -53
  284. package/dist/queue/index.d.mts +3 -53
  285. package/dist/queue/index.mjs +3 -190
  286. package/dist/random-password.cjs +86 -0
  287. package/dist/random-password.cjs.map +1 -0
  288. package/dist/random-password.d.cts +30 -0
  289. package/dist/random-password.d.cts.map +1 -0
  290. package/dist/random-password.d.mts +30 -0
  291. package/dist/random-password.d.mts.map +1 -0
  292. package/dist/random-password.mjs +84 -0
  293. package/dist/random-password.mjs.map +1 -0
  294. package/dist/{lazyAccessors-BHtcqgz2.mjs → readRequestBody-BTIl3k-D.mjs} +99 -39
  295. package/dist/readRequestBody-BTIl3k-D.mjs.map +1 -0
  296. package/dist/{lazyAccessors-Dx9NLwJZ.cjs → readRequestBody-Dej_L3c4.cjs} +118 -46
  297. package/dist/readRequestBody-Dej_L3c4.cjs.map +1 -0
  298. package/dist/requestLogger-BZcXwdBs.cjs +207 -0
  299. package/dist/requestLogger-BZcXwdBs.cjs.map +1 -0
  300. package/dist/requestLogger-pA4gi3E1.mjs +178 -0
  301. package/dist/requestLogger-pA4gi3E1.mjs.map +1 -0
  302. package/dist/rest-api.cjs +74 -70
  303. package/dist/rest-api.cjs.map +1 -1
  304. package/dist/rest-api.d.cts +69 -58
  305. package/dist/rest-api.d.cts.map +1 -1
  306. package/dist/rest-api.d.mts +69 -58
  307. package/dist/rest-api.d.mts.map +1 -1
  308. package/dist/rest-api.mjs +74 -70
  309. package/dist/rest-api.mjs.map +1 -1
  310. package/dist/runSubscriber-CC_2C9F2.cjs +133 -0
  311. package/dist/runSubscriber-CC_2C9F2.cjs.map +1 -0
  312. package/dist/runSubscriber-DyHWp_Lf.mjs +116 -0
  313. package/dist/runSubscriber-DyHWp_Lf.mjs.map +1 -0
  314. package/dist/shutdown-BMJmAhSt.cjs +38 -0
  315. package/dist/shutdown-BMJmAhSt.cjs.map +1 -0
  316. package/dist/shutdown-C7xa8x9S.mjs +27 -0
  317. package/dist/shutdown-C7xa8x9S.mjs.map +1 -0
  318. package/dist/site.cjs +64 -4
  319. package/dist/site.cjs.map +1 -1
  320. package/dist/site.d.cts +90 -1
  321. package/dist/site.d.cts.map +1 -1
  322. package/dist/site.d.mts +90 -1
  323. package/dist/site.d.mts.map +1 -1
  324. package/dist/site.mjs +62 -6
  325. package/dist/site.mjs.map +1 -1
  326. package/dist/stages-DaTaoQei.d.cts +73 -0
  327. package/dist/stages-DaTaoQei.d.cts.map +1 -0
  328. package/dist/stages-DaTaoQei.d.mts +73 -0
  329. package/dist/stages-DaTaoQei.d.mts.map +1 -0
  330. package/dist/subscribers/index.cjs +134 -1
  331. package/dist/subscribers/index.cjs.map +1 -0
  332. package/dist/subscribers/index.d.cts +74 -3
  333. package/dist/subscribers/index.d.cts.map +1 -0
  334. package/dist/subscribers/index.d.mts +74 -3
  335. package/dist/subscribers/index.d.mts.map +1 -0
  336. package/dist/subscribers/index.mjs +132 -2
  337. package/dist/subscribers/index.mjs.map +1 -0
  338. package/dist/telemetry-B48RLjyk.d.cts +40 -0
  339. package/dist/telemetry-B48RLjyk.d.cts.map +1 -0
  340. package/dist/telemetry-BEoBn6GO.d.mts +40 -0
  341. package/dist/telemetry-BEoBn6GO.d.mts.map +1 -0
  342. package/dist/telemetry.cjs +56 -0
  343. package/dist/telemetry.cjs.map +1 -0
  344. package/dist/telemetry.d.cts +2 -0
  345. package/dist/telemetry.d.mts +2 -0
  346. package/dist/telemetry.mjs +55 -0
  347. package/dist/telemetry.mjs.map +1 -0
  348. package/dist/topic/index.cjs +2 -134
  349. package/dist/topic/index.d.cts +2 -3
  350. package/dist/topic/index.d.mts +2 -3
  351. package/dist/topic/index.mjs +2 -132
  352. package/dist/tracing-Bbj1uoFJ.mjs +127 -0
  353. package/dist/tracing-Bbj1uoFJ.mjs.map +1 -0
  354. package/dist/tracing-C0ooU0V2.cjs +150 -0
  355. package/dist/tracing-C0ooU0V2.cjs.map +1 -0
  356. package/dist/websocket-api.cjs +762 -0
  357. package/dist/websocket-api.cjs.map +1 -0
  358. package/dist/websocket-api.d.cts +443 -0
  359. package/dist/websocket-api.d.cts.map +1 -0
  360. package/dist/websocket-api.d.mts +443 -0
  361. package/dist/websocket-api.d.mts.map +1 -0
  362. package/dist/websocket-api.mjs +748 -0
  363. package/dist/websocket-api.mjs.map +1 -0
  364. package/dist/worker.cjs +140 -32
  365. package/dist/worker.cjs.map +1 -1
  366. package/dist/worker.d.cts +139 -47
  367. package/dist/worker.d.cts.map +1 -1
  368. package/dist/worker.d.mts +139 -47
  369. package/dist/worker.d.mts.map +1 -1
  370. package/dist/worker.mjs +141 -33
  371. package/dist/worker.mjs.map +1 -1
  372. package/package.json +155 -44
  373. package/dist/Construct-BeYVu_QF.mjs.map +0 -1
  374. package/dist/Construct-DfbwIntp.d.cts +0 -115
  375. package/dist/Construct-DfbwIntp.d.cts.map +0 -1
  376. package/dist/Construct-DqdlARxq.cjs.map +0 -1
  377. package/dist/Construct-l5aOn_jv.d.mts +0 -115
  378. package/dist/Construct-l5aOn_jv.d.mts.map +0 -1
  379. package/dist/Cron-DKqnnTdH.d.cts.map +0 -1
  380. package/dist/Cron-SyqS5oWJ.d.mts.map +0 -1
  381. package/dist/CronBuilder-BdnI6lxF.cjs.map +0 -1
  382. package/dist/CronBuilder-CRGnDfTq.d.mts +0 -41
  383. package/dist/CronBuilder-CRGnDfTq.d.mts.map +0 -1
  384. package/dist/CronBuilder-D_0HNBTr.mjs.map +0 -1
  385. package/dist/CronBuilder-Df1q9PNy.d.cts +0 -41
  386. package/dist/CronBuilder-Df1q9PNy.d.cts.map +0 -1
  387. package/dist/Endpoint-BpZHtJ2W.cjs +0 -1689
  388. package/dist/Endpoint-BpZHtJ2W.cjs.map +0 -1
  389. package/dist/Endpoint-C6yyHpRS.d.cts.map +0 -1
  390. package/dist/Endpoint-DuT4TEEq.d.mts.map +0 -1
  391. package/dist/Endpoint-ONsly_dq.mjs +0 -1671
  392. package/dist/Endpoint-ONsly_dq.mjs.map +0 -1
  393. package/dist/EndpointFactory-Bm3aKRdV.mjs.map +0 -1
  394. package/dist/EndpointFactory-CLvWuHyt.cjs.map +0 -1
  395. package/dist/HonoEndpointAdaptor-92zavCsV.cjs.map +0 -1
  396. package/dist/HonoEndpointAdaptor-yYaU7jVJ.mjs.map +0 -1
  397. package/dist/Queue-D9X6OoON.d.mts.map +0 -1
  398. package/dist/Queue-DYPB2KWL.d.cts.map +0 -1
  399. package/dist/Subscriber-C4heaAyO.d.mts +0 -51
  400. package/dist/Subscriber-C4heaAyO.d.mts.map +0 -1
  401. package/dist/Subscriber-CotDUELC.d.cts +0 -51
  402. package/dist/Subscriber-CotDUELC.d.cts.map +0 -1
  403. package/dist/SubscriberBuilder-BEv0eoHy.d.cts +0 -59
  404. package/dist/SubscriberBuilder-BEv0eoHy.d.cts.map +0 -1
  405. package/dist/SubscriberBuilder-C0ZEtGDI.cjs +0 -125
  406. package/dist/SubscriberBuilder-C0ZEtGDI.cjs.map +0 -1
  407. package/dist/SubscriberBuilder-h7B_cHMr.mjs +0 -114
  408. package/dist/SubscriberBuilder-h7B_cHMr.mjs.map +0 -1
  409. package/dist/SubscriberBuilder-tyH5yTk5.d.mts +0 -59
  410. package/dist/SubscriberBuilder-tyH5yTk5.d.mts.map +0 -1
  411. package/dist/Topic-DEVGo0Dm.d.cts +0 -89
  412. package/dist/Topic-DEVGo0Dm.d.cts.map +0 -1
  413. package/dist/Topic-zk_6Gthr.d.mts +0 -89
  414. package/dist/Topic-zk_6Gthr.d.mts.map +0 -1
  415. package/dist/auth.d.cts.map +0 -1
  416. package/dist/auth.d.mts.map +0 -1
  417. package/dist/cache.d.cts.map +0 -1
  418. package/dist/cache.d.mts.map +0 -1
  419. package/dist/construct-interface-DPlxfpoS.d.mts.map +0 -1
  420. package/dist/construct-interface-DgXTJcOD.d.cts.map +0 -1
  421. package/dist/credential.cjs.map +0 -1
  422. package/dist/credential.d.cts.map +0 -1
  423. package/dist/credential.d.mts.map +0 -1
  424. package/dist/credential.mjs.map +0 -1
  425. package/dist/database/kysely.cjs.map +0 -1
  426. package/dist/database/kysely.d.cts.map +0 -1
  427. package/dist/database/kysely.d.mts.map +0 -1
  428. package/dist/database/kysely.mjs.map +0 -1
  429. package/dist/functions-B6qCvfmy.cjs.map +0 -1
  430. package/dist/functions-C53GW2eQ.mjs.map +0 -1
  431. package/dist/index-B2urf3YI.d.cts +0 -26
  432. package/dist/index-B2urf3YI.d.cts.map +0 -1
  433. package/dist/index-BPSZ_Lp_.d.cts.map +0 -1
  434. package/dist/index-BoZ-iisU.d.mts.map +0 -1
  435. package/dist/index-CdaU--_B.d.cts +0 -165
  436. package/dist/index-CdaU--_B.d.cts.map +0 -1
  437. package/dist/index-DMCDvnsM.d.mts +0 -26
  438. package/dist/index-DMCDvnsM.d.mts.map +0 -1
  439. package/dist/index-PQRWOQj4.d.mts +0 -165
  440. package/dist/index-PQRWOQj4.d.mts.map +0 -1
  441. package/dist/lazyAccessors-BHtcqgz2.mjs.map +0 -1
  442. package/dist/lazyAccessors-Dx9NLwJZ.cjs.map +0 -1
  443. package/dist/processAudits-BpRlPQMW.mjs +0 -77
  444. package/dist/processAudits-BpRlPQMW.mjs.map +0 -1
  445. package/dist/processAudits-D_2W5x8k.cjs +0 -88
  446. package/dist/processAudits-D_2W5x8k.cjs.map +0 -1
  447. package/dist/queue/index.cjs.map +0 -1
  448. package/dist/queue/index.d.cts.map +0 -1
  449. package/dist/queue/index.d.mts.map +0 -1
  450. package/dist/queue/index.mjs.map +0 -1
  451. package/dist/telemetry-DGcFlVpB.d.cts.map +0 -1
  452. package/dist/telemetry-DGcFlVpB.d.mts.map +0 -1
  453. package/dist/topic/index.cjs.map +0 -1
  454. package/dist/topic/index.mjs.map +0 -1
@@ -1,1671 +0,0 @@
1
- import { a as __commonJSMin, o as __toESM } from "./Construct-BeYVu_QF.mjs";
2
- import { n as Function$1 } from "./functions-C53GW2eQ.mjs";
3
- import { convertSchemaWithComponents, convertStandardSchemaToJsonSchema } from "@geekmidas/schema/conversion";
4
- import { buildOpenApiSchema } from "@geekmidas/schema/openapi";
5
- //#region ../../node_modules/.pnpm/lodash.pick@4.4.0/node_modules/lodash.pick/index.js
6
- var require_lodash_pick = /* @__PURE__ */ __commonJSMin(((exports, module) => {
7
- /**
8
- * lodash (Custom Build) <https://lodash.com/>
9
- * Build: `lodash modularize exports="npm" -o ./`
10
- * Copyright jQuery Foundation and other contributors <https://jquery.org/>
11
- * Released under MIT license <https://lodash.com/license>
12
- * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
13
- * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
14
- */
15
- /** Used as references for various `Number` constants. */
16
- var MAX_SAFE_INTEGER = 9007199254740991;
17
- /** `Object#toString` result references. */
18
- var argsTag = "[object Arguments]";
19
- var funcTag = "[object Function]";
20
- var genTag = "[object GeneratorFunction]";
21
- var symbolTag = "[object Symbol]";
22
- /** Detect free variable `global` from Node.js. */
23
- var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
24
- /** Detect free variable `self`. */
25
- var freeSelf = typeof self == "object" && self && self.Object === Object && self;
26
- /** Used as a reference to the global object. */
27
- var root = freeGlobal || freeSelf || Function("return this")();
28
- /**
29
- * A faster alternative to `Function#apply`, this function invokes `func`
30
- * with the `this` binding of `thisArg` and the arguments of `args`.
31
- *
32
- * @private
33
- * @param {Function} func The function to invoke.
34
- * @param {*} thisArg The `this` binding of `func`.
35
- * @param {Array} args The arguments to invoke `func` with.
36
- * @returns {*} Returns the result of `func`.
37
- */
38
- function apply(func, thisArg, args) {
39
- switch (args.length) {
40
- case 0: return func.call(thisArg);
41
- case 1: return func.call(thisArg, args[0]);
42
- case 2: return func.call(thisArg, args[0], args[1]);
43
- case 3: return func.call(thisArg, args[0], args[1], args[2]);
44
- }
45
- return func.apply(thisArg, args);
46
- }
47
- /**
48
- * A specialized version of `_.map` for arrays without support for iteratee
49
- * shorthands.
50
- *
51
- * @private
52
- * @param {Array} [array] The array to iterate over.
53
- * @param {Function} iteratee The function invoked per iteration.
54
- * @returns {Array} Returns the new mapped array.
55
- */
56
- function arrayMap(array, iteratee) {
57
- var index = -1, length = array ? array.length : 0, result = Array(length);
58
- while (++index < length) result[index] = iteratee(array[index], index, array);
59
- return result;
60
- }
61
- /**
62
- * Appends the elements of `values` to `array`.
63
- *
64
- * @private
65
- * @param {Array} array The array to modify.
66
- * @param {Array} values The values to append.
67
- * @returns {Array} Returns `array`.
68
- */
69
- function arrayPush(array, values) {
70
- var index = -1, length = values.length, offset = array.length;
71
- while (++index < length) array[offset + index] = values[index];
72
- return array;
73
- }
74
- /** Used for built-in method references. */
75
- var objectProto = Object.prototype;
76
- /** Used to check objects for own properties. */
77
- var hasOwnProperty = objectProto.hasOwnProperty;
78
- /**
79
- * Used to resolve the
80
- * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
81
- * of values.
82
- */
83
- var objectToString = objectProto.toString;
84
- /** Built-in value references. */
85
- var Symbol = root.Symbol;
86
- var propertyIsEnumerable = objectProto.propertyIsEnumerable;
87
- var spreadableSymbol = Symbol ? Symbol.isConcatSpreadable : void 0;
88
- var nativeMax = Math.max;
89
- /**
90
- * The base implementation of `_.flatten` with support for restricting flattening.
91
- *
92
- * @private
93
- * @param {Array} array The array to flatten.
94
- * @param {number} depth The maximum recursion depth.
95
- * @param {boolean} [predicate=isFlattenable] The function invoked per iteration.
96
- * @param {boolean} [isStrict] Restrict to values that pass `predicate` checks.
97
- * @param {Array} [result=[]] The initial result value.
98
- * @returns {Array} Returns the new flattened array.
99
- */
100
- function baseFlatten(array, depth, predicate, isStrict, result) {
101
- var index = -1, length = array.length;
102
- predicate || (predicate = isFlattenable);
103
- result || (result = []);
104
- while (++index < length) {
105
- var value = array[index];
106
- if (depth > 0 && predicate(value)) {
107
- if (depth > 1) baseFlatten(value, depth - 1, predicate, isStrict, result);
108
- else arrayPush(result, value);
109
- } else if (!isStrict) result[result.length] = value;
110
- }
111
- return result;
112
- }
113
- /**
114
- * The base implementation of `_.pick` without support for individual
115
- * property identifiers.
116
- *
117
- * @private
118
- * @param {Object} object The source object.
119
- * @param {string[]} props The property identifiers to pick.
120
- * @returns {Object} Returns the new object.
121
- */
122
- function basePick(object, props) {
123
- object = Object(object);
124
- return basePickBy(object, props, function(value, key) {
125
- return key in object;
126
- });
127
- }
128
- /**
129
- * The base implementation of `_.pickBy` without support for iteratee shorthands.
130
- *
131
- * @private
132
- * @param {Object} object The source object.
133
- * @param {string[]} props The property identifiers to pick from.
134
- * @param {Function} predicate The function invoked per property.
135
- * @returns {Object} Returns the new object.
136
- */
137
- function basePickBy(object, props, predicate) {
138
- var index = -1, length = props.length, result = {};
139
- while (++index < length) {
140
- var key = props[index], value = object[key];
141
- if (predicate(value, key)) result[key] = value;
142
- }
143
- return result;
144
- }
145
- /**
146
- * The base implementation of `_.rest` which doesn't validate or coerce arguments.
147
- *
148
- * @private
149
- * @param {Function} func The function to apply a rest parameter to.
150
- * @param {number} [start=func.length-1] The start position of the rest parameter.
151
- * @returns {Function} Returns the new function.
152
- */
153
- function baseRest(func, start) {
154
- start = nativeMax(start === void 0 ? func.length - 1 : start, 0);
155
- return function() {
156
- var args = arguments, index = -1, length = nativeMax(args.length - start, 0), array = Array(length);
157
- while (++index < length) array[index] = args[start + index];
158
- index = -1;
159
- var otherArgs = Array(start + 1);
160
- while (++index < start) otherArgs[index] = args[index];
161
- otherArgs[start] = array;
162
- return apply(func, this, otherArgs);
163
- };
164
- }
165
- /**
166
- * Checks if `value` is a flattenable `arguments` object or array.
167
- *
168
- * @private
169
- * @param {*} value The value to check.
170
- * @returns {boolean} Returns `true` if `value` is flattenable, else `false`.
171
- */
172
- function isFlattenable(value) {
173
- return isArray(value) || isArguments(value) || !!(spreadableSymbol && value && value[spreadableSymbol]);
174
- }
175
- /**
176
- * Converts `value` to a string key if it's not a string or symbol.
177
- *
178
- * @private
179
- * @param {*} value The value to inspect.
180
- * @returns {string|symbol} Returns the key.
181
- */
182
- function toKey(value) {
183
- if (typeof value == "string" || isSymbol(value)) return value;
184
- var result = value + "";
185
- return result == "0" && 1 / value == -Infinity ? "-0" : result;
186
- }
187
- /**
188
- * Checks if `value` is likely an `arguments` object.
189
- *
190
- * @static
191
- * @memberOf _
192
- * @since 0.1.0
193
- * @category Lang
194
- * @param {*} value The value to check.
195
- * @returns {boolean} Returns `true` if `value` is an `arguments` object,
196
- * else `false`.
197
- * @example
198
- *
199
- * _.isArguments(function() { return arguments; }());
200
- * // => true
201
- *
202
- * _.isArguments([1, 2, 3]);
203
- * // => false
204
- */
205
- function isArguments(value) {
206
- return isArrayLikeObject(value) && hasOwnProperty.call(value, "callee") && (!propertyIsEnumerable.call(value, "callee") || objectToString.call(value) == argsTag);
207
- }
208
- /**
209
- * Checks if `value` is classified as an `Array` object.
210
- *
211
- * @static
212
- * @memberOf _
213
- * @since 0.1.0
214
- * @category Lang
215
- * @param {*} value The value to check.
216
- * @returns {boolean} Returns `true` if `value` is an array, else `false`.
217
- * @example
218
- *
219
- * _.isArray([1, 2, 3]);
220
- * // => true
221
- *
222
- * _.isArray(document.body.children);
223
- * // => false
224
- *
225
- * _.isArray('abc');
226
- * // => false
227
- *
228
- * _.isArray(_.noop);
229
- * // => false
230
- */
231
- var isArray = Array.isArray;
232
- /**
233
- * Checks if `value` is array-like. A value is considered array-like if it's
234
- * not a function and has a `value.length` that's an integer greater than or
235
- * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.
236
- *
237
- * @static
238
- * @memberOf _
239
- * @since 4.0.0
240
- * @category Lang
241
- * @param {*} value The value to check.
242
- * @returns {boolean} Returns `true` if `value` is array-like, else `false`.
243
- * @example
244
- *
245
- * _.isArrayLike([1, 2, 3]);
246
- * // => true
247
- *
248
- * _.isArrayLike(document.body.children);
249
- * // => true
250
- *
251
- * _.isArrayLike('abc');
252
- * // => true
253
- *
254
- * _.isArrayLike(_.noop);
255
- * // => false
256
- */
257
- function isArrayLike(value) {
258
- return value != null && isLength(value.length) && !isFunction(value);
259
- }
260
- /**
261
- * This method is like `_.isArrayLike` except that it also checks if `value`
262
- * is an object.
263
- *
264
- * @static
265
- * @memberOf _
266
- * @since 4.0.0
267
- * @category Lang
268
- * @param {*} value The value to check.
269
- * @returns {boolean} Returns `true` if `value` is an array-like object,
270
- * else `false`.
271
- * @example
272
- *
273
- * _.isArrayLikeObject([1, 2, 3]);
274
- * // => true
275
- *
276
- * _.isArrayLikeObject(document.body.children);
277
- * // => true
278
- *
279
- * _.isArrayLikeObject('abc');
280
- * // => false
281
- *
282
- * _.isArrayLikeObject(_.noop);
283
- * // => false
284
- */
285
- function isArrayLikeObject(value) {
286
- return isObjectLike(value) && isArrayLike(value);
287
- }
288
- /**
289
- * Checks if `value` is classified as a `Function` object.
290
- *
291
- * @static
292
- * @memberOf _
293
- * @since 0.1.0
294
- * @category Lang
295
- * @param {*} value The value to check.
296
- * @returns {boolean} Returns `true` if `value` is a function, else `false`.
297
- * @example
298
- *
299
- * _.isFunction(_);
300
- * // => true
301
- *
302
- * _.isFunction(/abc/);
303
- * // => false
304
- */
305
- function isFunction(value) {
306
- var tag = isObject(value) ? objectToString.call(value) : "";
307
- return tag == funcTag || tag == genTag;
308
- }
309
- /**
310
- * Checks if `value` is a valid array-like length.
311
- *
312
- * **Note:** This method is loosely based on
313
- * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).
314
- *
315
- * @static
316
- * @memberOf _
317
- * @since 4.0.0
318
- * @category Lang
319
- * @param {*} value The value to check.
320
- * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
321
- * @example
322
- *
323
- * _.isLength(3);
324
- * // => true
325
- *
326
- * _.isLength(Number.MIN_VALUE);
327
- * // => false
328
- *
329
- * _.isLength(Infinity);
330
- * // => false
331
- *
332
- * _.isLength('3');
333
- * // => false
334
- */
335
- function isLength(value) {
336
- return typeof value == "number" && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
337
- }
338
- /**
339
- * Checks if `value` is the
340
- * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
341
- * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
342
- *
343
- * @static
344
- * @memberOf _
345
- * @since 0.1.0
346
- * @category Lang
347
- * @param {*} value The value to check.
348
- * @returns {boolean} Returns `true` if `value` is an object, else `false`.
349
- * @example
350
- *
351
- * _.isObject({});
352
- * // => true
353
- *
354
- * _.isObject([1, 2, 3]);
355
- * // => true
356
- *
357
- * _.isObject(_.noop);
358
- * // => true
359
- *
360
- * _.isObject(null);
361
- * // => false
362
- */
363
- function isObject(value) {
364
- var type = typeof value;
365
- return !!value && (type == "object" || type == "function");
366
- }
367
- /**
368
- * Checks if `value` is object-like. A value is object-like if it's not `null`
369
- * and has a `typeof` result of "object".
370
- *
371
- * @static
372
- * @memberOf _
373
- * @since 4.0.0
374
- * @category Lang
375
- * @param {*} value The value to check.
376
- * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
377
- * @example
378
- *
379
- * _.isObjectLike({});
380
- * // => true
381
- *
382
- * _.isObjectLike([1, 2, 3]);
383
- * // => true
384
- *
385
- * _.isObjectLike(_.noop);
386
- * // => false
387
- *
388
- * _.isObjectLike(null);
389
- * // => false
390
- */
391
- function isObjectLike(value) {
392
- return !!value && typeof value == "object";
393
- }
394
- /**
395
- * Checks if `value` is classified as a `Symbol` primitive or object.
396
- *
397
- * @static
398
- * @memberOf _
399
- * @since 4.0.0
400
- * @category Lang
401
- * @param {*} value The value to check.
402
- * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.
403
- * @example
404
- *
405
- * _.isSymbol(Symbol.iterator);
406
- * // => true
407
- *
408
- * _.isSymbol('abc');
409
- * // => false
410
- */
411
- function isSymbol(value) {
412
- return typeof value == "symbol" || isObjectLike(value) && objectToString.call(value) == symbolTag;
413
- }
414
- module.exports = baseRest(function(object, props) {
415
- return object == null ? {} : basePick(object, arrayMap(baseFlatten(props, 1), toKey));
416
- });
417
- }));
418
- //#endregion
419
- //#region ../../node_modules/.pnpm/lodash.set@4.3.2/node_modules/lodash.set/index.js
420
- var require_lodash_set = /* @__PURE__ */ __commonJSMin(((exports, module) => {
421
- /**
422
- * lodash (Custom Build) <https://lodash.com/>
423
- * Build: `lodash modularize exports="npm" -o ./`
424
- * Copyright jQuery Foundation and other contributors <https://jquery.org/>
425
- * Released under MIT license <https://lodash.com/license>
426
- * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
427
- * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
428
- */
429
- /** Used as the `TypeError` message for "Functions" methods. */
430
- var FUNC_ERROR_TEXT = "Expected a function";
431
- /** Used to stand-in for `undefined` hash values. */
432
- var HASH_UNDEFINED = "__lodash_hash_undefined__";
433
- var MAX_SAFE_INTEGER = 9007199254740991;
434
- /** `Object#toString` result references. */
435
- var funcTag = "[object Function]";
436
- var genTag = "[object GeneratorFunction]";
437
- var symbolTag = "[object Symbol]";
438
- /** Used to match property names within property paths. */
439
- var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/;
440
- var reIsPlainProp = /^\w*$/;
441
- var reLeadingDot = /^\./;
442
- var rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g;
443
- /**
444
- * Used to match `RegExp`
445
- * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).
446
- */
447
- var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
448
- /** Used to match backslashes in property paths. */
449
- var reEscapeChar = /\\(\\)?/g;
450
- /** Used to detect host constructors (Safari). */
451
- var reIsHostCtor = /^\[object .+?Constructor\]$/;
452
- /** Used to detect unsigned integer values. */
453
- var reIsUint = /^(?:0|[1-9]\d*)$/;
454
- /** Detect free variable `global` from Node.js. */
455
- var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
456
- /** Detect free variable `self`. */
457
- var freeSelf = typeof self == "object" && self && self.Object === Object && self;
458
- /** Used as a reference to the global object. */
459
- var root = freeGlobal || freeSelf || Function("return this")();
460
- /**
461
- * Gets the value at `key` of `object`.
462
- *
463
- * @private
464
- * @param {Object} [object] The object to query.
465
- * @param {string} key The key of the property to get.
466
- * @returns {*} Returns the property value.
467
- */
468
- function getValue(object, key) {
469
- return object == null ? void 0 : object[key];
470
- }
471
- /**
472
- * Checks if `value` is a host object in IE < 9.
473
- *
474
- * @private
475
- * @param {*} value The value to check.
476
- * @returns {boolean} Returns `true` if `value` is a host object, else `false`.
477
- */
478
- function isHostObject(value) {
479
- var result = false;
480
- if (value != null && typeof value.toString != "function") try {
481
- result = !!(value + "");
482
- } catch (e) {}
483
- return result;
484
- }
485
- /** Used for built-in method references. */
486
- var arrayProto = Array.prototype;
487
- var funcProto = Function.prototype;
488
- var objectProto = Object.prototype;
489
- /** Used to detect overreaching core-js shims. */
490
- var coreJsData = root["__core-js_shared__"];
491
- /** Used to detect methods masquerading as native. */
492
- var maskSrcKey = function() {
493
- var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || "");
494
- return uid ? "Symbol(src)_1." + uid : "";
495
- }();
496
- /** Used to resolve the decompiled source of functions. */
497
- var funcToString = funcProto.toString;
498
- /** Used to check objects for own properties. */
499
- var hasOwnProperty = objectProto.hasOwnProperty;
500
- /**
501
- * Used to resolve the
502
- * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
503
- * of values.
504
- */
505
- var objectToString = objectProto.toString;
506
- /** Used to detect if a method is native. */
507
- var reIsNative = RegExp("^" + funcToString.call(hasOwnProperty).replace(reRegExpChar, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$");
508
- /** Built-in value references. */
509
- var Symbol = root.Symbol;
510
- var splice = arrayProto.splice;
511
- var Map = getNative(root, "Map");
512
- var nativeCreate = getNative(Object, "create");
513
- /** Used to convert symbols to primitives and strings. */
514
- var symbolProto = Symbol ? Symbol.prototype : void 0;
515
- var symbolToString = symbolProto ? symbolProto.toString : void 0;
516
- /**
517
- * Creates a hash object.
518
- *
519
- * @private
520
- * @constructor
521
- * @param {Array} [entries] The key-value pairs to cache.
522
- */
523
- function Hash(entries) {
524
- var index = -1, length = entries ? entries.length : 0;
525
- this.clear();
526
- while (++index < length) {
527
- var entry = entries[index];
528
- this.set(entry[0], entry[1]);
529
- }
530
- }
531
- /**
532
- * Removes all key-value entries from the hash.
533
- *
534
- * @private
535
- * @name clear
536
- * @memberOf Hash
537
- */
538
- function hashClear() {
539
- this.__data__ = nativeCreate ? nativeCreate(null) : {};
540
- }
541
- /**
542
- * Removes `key` and its value from the hash.
543
- *
544
- * @private
545
- * @name delete
546
- * @memberOf Hash
547
- * @param {Object} hash The hash to modify.
548
- * @param {string} key The key of the value to remove.
549
- * @returns {boolean} Returns `true` if the entry was removed, else `false`.
550
- */
551
- function hashDelete(key) {
552
- return this.has(key) && delete this.__data__[key];
553
- }
554
- /**
555
- * Gets the hash value for `key`.
556
- *
557
- * @private
558
- * @name get
559
- * @memberOf Hash
560
- * @param {string} key The key of the value to get.
561
- * @returns {*} Returns the entry value.
562
- */
563
- function hashGet(key) {
564
- var data = this.__data__;
565
- if (nativeCreate) {
566
- var result = data[key];
567
- return result === HASH_UNDEFINED ? void 0 : result;
568
- }
569
- return hasOwnProperty.call(data, key) ? data[key] : void 0;
570
- }
571
- /**
572
- * Checks if a hash value for `key` exists.
573
- *
574
- * @private
575
- * @name has
576
- * @memberOf Hash
577
- * @param {string} key The key of the entry to check.
578
- * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
579
- */
580
- function hashHas(key) {
581
- var data = this.__data__;
582
- return nativeCreate ? data[key] !== void 0 : hasOwnProperty.call(data, key);
583
- }
584
- /**
585
- * Sets the hash `key` to `value`.
586
- *
587
- * @private
588
- * @name set
589
- * @memberOf Hash
590
- * @param {string} key The key of the value to set.
591
- * @param {*} value The value to set.
592
- * @returns {Object} Returns the hash instance.
593
- */
594
- function hashSet(key, value) {
595
- var data = this.__data__;
596
- data[key] = nativeCreate && value === void 0 ? HASH_UNDEFINED : value;
597
- return this;
598
- }
599
- Hash.prototype.clear = hashClear;
600
- Hash.prototype["delete"] = hashDelete;
601
- Hash.prototype.get = hashGet;
602
- Hash.prototype.has = hashHas;
603
- Hash.prototype.set = hashSet;
604
- /**
605
- * Creates an list cache object.
606
- *
607
- * @private
608
- * @constructor
609
- * @param {Array} [entries] The key-value pairs to cache.
610
- */
611
- function ListCache(entries) {
612
- var index = -1, length = entries ? entries.length : 0;
613
- this.clear();
614
- while (++index < length) {
615
- var entry = entries[index];
616
- this.set(entry[0], entry[1]);
617
- }
618
- }
619
- /**
620
- * Removes all key-value entries from the list cache.
621
- *
622
- * @private
623
- * @name clear
624
- * @memberOf ListCache
625
- */
626
- function listCacheClear() {
627
- this.__data__ = [];
628
- }
629
- /**
630
- * Removes `key` and its value from the list cache.
631
- *
632
- * @private
633
- * @name delete
634
- * @memberOf ListCache
635
- * @param {string} key The key of the value to remove.
636
- * @returns {boolean} Returns `true` if the entry was removed, else `false`.
637
- */
638
- function listCacheDelete(key) {
639
- var data = this.__data__, index = assocIndexOf(data, key);
640
- if (index < 0) return false;
641
- if (index == data.length - 1) data.pop();
642
- else splice.call(data, index, 1);
643
- return true;
644
- }
645
- /**
646
- * Gets the list cache value for `key`.
647
- *
648
- * @private
649
- * @name get
650
- * @memberOf ListCache
651
- * @param {string} key The key of the value to get.
652
- * @returns {*} Returns the entry value.
653
- */
654
- function listCacheGet(key) {
655
- var data = this.__data__, index = assocIndexOf(data, key);
656
- return index < 0 ? void 0 : data[index][1];
657
- }
658
- /**
659
- * Checks if a list cache value for `key` exists.
660
- *
661
- * @private
662
- * @name has
663
- * @memberOf ListCache
664
- * @param {string} key The key of the entry to check.
665
- * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
666
- */
667
- function listCacheHas(key) {
668
- return assocIndexOf(this.__data__, key) > -1;
669
- }
670
- /**
671
- * Sets the list cache `key` to `value`.
672
- *
673
- * @private
674
- * @name set
675
- * @memberOf ListCache
676
- * @param {string} key The key of the value to set.
677
- * @param {*} value The value to set.
678
- * @returns {Object} Returns the list cache instance.
679
- */
680
- function listCacheSet(key, value) {
681
- var data = this.__data__, index = assocIndexOf(data, key);
682
- if (index < 0) data.push([key, value]);
683
- else data[index][1] = value;
684
- return this;
685
- }
686
- ListCache.prototype.clear = listCacheClear;
687
- ListCache.prototype["delete"] = listCacheDelete;
688
- ListCache.prototype.get = listCacheGet;
689
- ListCache.prototype.has = listCacheHas;
690
- ListCache.prototype.set = listCacheSet;
691
- /**
692
- * Creates a map cache object to store key-value pairs.
693
- *
694
- * @private
695
- * @constructor
696
- * @param {Array} [entries] The key-value pairs to cache.
697
- */
698
- function MapCache(entries) {
699
- var index = -1, length = entries ? entries.length : 0;
700
- this.clear();
701
- while (++index < length) {
702
- var entry = entries[index];
703
- this.set(entry[0], entry[1]);
704
- }
705
- }
706
- /**
707
- * Removes all key-value entries from the map.
708
- *
709
- * @private
710
- * @name clear
711
- * @memberOf MapCache
712
- */
713
- function mapCacheClear() {
714
- this.__data__ = {
715
- "hash": new Hash(),
716
- "map": new (Map || ListCache)(),
717
- "string": new Hash()
718
- };
719
- }
720
- /**
721
- * Removes `key` and its value from the map.
722
- *
723
- * @private
724
- * @name delete
725
- * @memberOf MapCache
726
- * @param {string} key The key of the value to remove.
727
- * @returns {boolean} Returns `true` if the entry was removed, else `false`.
728
- */
729
- function mapCacheDelete(key) {
730
- return getMapData(this, key)["delete"](key);
731
- }
732
- /**
733
- * Gets the map value for `key`.
734
- *
735
- * @private
736
- * @name get
737
- * @memberOf MapCache
738
- * @param {string} key The key of the value to get.
739
- * @returns {*} Returns the entry value.
740
- */
741
- function mapCacheGet(key) {
742
- return getMapData(this, key).get(key);
743
- }
744
- /**
745
- * Checks if a map value for `key` exists.
746
- *
747
- * @private
748
- * @name has
749
- * @memberOf MapCache
750
- * @param {string} key The key of the entry to check.
751
- * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
752
- */
753
- function mapCacheHas(key) {
754
- return getMapData(this, key).has(key);
755
- }
756
- /**
757
- * Sets the map `key` to `value`.
758
- *
759
- * @private
760
- * @name set
761
- * @memberOf MapCache
762
- * @param {string} key The key of the value to set.
763
- * @param {*} value The value to set.
764
- * @returns {Object} Returns the map cache instance.
765
- */
766
- function mapCacheSet(key, value) {
767
- getMapData(this, key).set(key, value);
768
- return this;
769
- }
770
- MapCache.prototype.clear = mapCacheClear;
771
- MapCache.prototype["delete"] = mapCacheDelete;
772
- MapCache.prototype.get = mapCacheGet;
773
- MapCache.prototype.has = mapCacheHas;
774
- MapCache.prototype.set = mapCacheSet;
775
- /**
776
- * Assigns `value` to `key` of `object` if the existing value is not equivalent
777
- * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
778
- * for equality comparisons.
779
- *
780
- * @private
781
- * @param {Object} object The object to modify.
782
- * @param {string} key The key of the property to assign.
783
- * @param {*} value The value to assign.
784
- */
785
- function assignValue(object, key, value) {
786
- var objValue = object[key];
787
- if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) || value === void 0 && !(key in object)) object[key] = value;
788
- }
789
- /**
790
- * Gets the index at which the `key` is found in `array` of key-value pairs.
791
- *
792
- * @private
793
- * @param {Array} array The array to inspect.
794
- * @param {*} key The key to search for.
795
- * @returns {number} Returns the index of the matched value, else `-1`.
796
- */
797
- function assocIndexOf(array, key) {
798
- var length = array.length;
799
- while (length--) if (eq(array[length][0], key)) return length;
800
- return -1;
801
- }
802
- /**
803
- * The base implementation of `_.isNative` without bad shim checks.
804
- *
805
- * @private
806
- * @param {*} value The value to check.
807
- * @returns {boolean} Returns `true` if `value` is a native function,
808
- * else `false`.
809
- */
810
- function baseIsNative(value) {
811
- if (!isObject(value) || isMasked(value)) return false;
812
- return (isFunction(value) || isHostObject(value) ? reIsNative : reIsHostCtor).test(toSource(value));
813
- }
814
- /**
815
- * The base implementation of `_.set`.
816
- *
817
- * @private
818
- * @param {Object} object The object to modify.
819
- * @param {Array|string} path The path of the property to set.
820
- * @param {*} value The value to set.
821
- * @param {Function} [customizer] The function to customize path creation.
822
- * @returns {Object} Returns `object`.
823
- */
824
- function baseSet(object, path, value, customizer) {
825
- if (!isObject(object)) return object;
826
- path = isKey(path, object) ? [path] : castPath(path);
827
- var index = -1, length = path.length, lastIndex = length - 1, nested = object;
828
- while (nested != null && ++index < length) {
829
- var key = toKey(path[index]), newValue = value;
830
- if (index != lastIndex) {
831
- var objValue = nested[key];
832
- newValue = customizer ? customizer(objValue, key, nested) : void 0;
833
- if (newValue === void 0) newValue = isObject(objValue) ? objValue : isIndex(path[index + 1]) ? [] : {};
834
- }
835
- assignValue(nested, key, newValue);
836
- nested = nested[key];
837
- }
838
- return object;
839
- }
840
- /**
841
- * The base implementation of `_.toString` which doesn't convert nullish
842
- * values to empty strings.
843
- *
844
- * @private
845
- * @param {*} value The value to process.
846
- * @returns {string} Returns the string.
847
- */
848
- function baseToString(value) {
849
- if (typeof value == "string") return value;
850
- if (isSymbol(value)) return symbolToString ? symbolToString.call(value) : "";
851
- var result = value + "";
852
- return result == "0" && 1 / value == -Infinity ? "-0" : result;
853
- }
854
- /**
855
- * Casts `value` to a path array if it's not one.
856
- *
857
- * @private
858
- * @param {*} value The value to inspect.
859
- * @returns {Array} Returns the cast property path array.
860
- */
861
- function castPath(value) {
862
- return isArray(value) ? value : stringToPath(value);
863
- }
864
- /**
865
- * Gets the data for `map`.
866
- *
867
- * @private
868
- * @param {Object} map The map to query.
869
- * @param {string} key The reference key.
870
- * @returns {*} Returns the map data.
871
- */
872
- function getMapData(map, key) {
873
- var data = map.__data__;
874
- return isKeyable(key) ? data[typeof key == "string" ? "string" : "hash"] : data.map;
875
- }
876
- /**
877
- * Gets the native function at `key` of `object`.
878
- *
879
- * @private
880
- * @param {Object} object The object to query.
881
- * @param {string} key The key of the method to get.
882
- * @returns {*} Returns the function if it's native, else `undefined`.
883
- */
884
- function getNative(object, key) {
885
- var value = getValue(object, key);
886
- return baseIsNative(value) ? value : void 0;
887
- }
888
- /**
889
- * Checks if `value` is a valid array-like index.
890
- *
891
- * @private
892
- * @param {*} value The value to check.
893
- * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.
894
- * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.
895
- */
896
- function isIndex(value, length) {
897
- length = length == null ? MAX_SAFE_INTEGER : length;
898
- return !!length && (typeof value == "number" || reIsUint.test(value)) && value > -1 && value % 1 == 0 && value < length;
899
- }
900
- /**
901
- * Checks if `value` is a property name and not a property path.
902
- *
903
- * @private
904
- * @param {*} value The value to check.
905
- * @param {Object} [object] The object to query keys on.
906
- * @returns {boolean} Returns `true` if `value` is a property name, else `false`.
907
- */
908
- function isKey(value, object) {
909
- if (isArray(value)) return false;
910
- var type = typeof value;
911
- if (type == "number" || type == "symbol" || type == "boolean" || value == null || isSymbol(value)) return true;
912
- return reIsPlainProp.test(value) || !reIsDeepProp.test(value) || object != null && value in Object(object);
913
- }
914
- /**
915
- * Checks if `value` is suitable for use as unique object key.
916
- *
917
- * @private
918
- * @param {*} value The value to check.
919
- * @returns {boolean} Returns `true` if `value` is suitable, else `false`.
920
- */
921
- function isKeyable(value) {
922
- var type = typeof value;
923
- return type == "string" || type == "number" || type == "symbol" || type == "boolean" ? value !== "__proto__" : value === null;
924
- }
925
- /**
926
- * Checks if `func` has its source masked.
927
- *
928
- * @private
929
- * @param {Function} func The function to check.
930
- * @returns {boolean} Returns `true` if `func` is masked, else `false`.
931
- */
932
- function isMasked(func) {
933
- return !!maskSrcKey && maskSrcKey in func;
934
- }
935
- /**
936
- * Converts `string` to a property path array.
937
- *
938
- * @private
939
- * @param {string} string The string to convert.
940
- * @returns {Array} Returns the property path array.
941
- */
942
- var stringToPath = memoize(function(string) {
943
- string = toString(string);
944
- var result = [];
945
- if (reLeadingDot.test(string)) result.push("");
946
- string.replace(rePropName, function(match, number, quote, string) {
947
- result.push(quote ? string.replace(reEscapeChar, "$1") : number || match);
948
- });
949
- return result;
950
- });
951
- /**
952
- * Converts `value` to a string key if it's not a string or symbol.
953
- *
954
- * @private
955
- * @param {*} value The value to inspect.
956
- * @returns {string|symbol} Returns the key.
957
- */
958
- function toKey(value) {
959
- if (typeof value == "string" || isSymbol(value)) return value;
960
- var result = value + "";
961
- return result == "0" && 1 / value == -Infinity ? "-0" : result;
962
- }
963
- /**
964
- * Converts `func` to its source code.
965
- *
966
- * @private
967
- * @param {Function} func The function to process.
968
- * @returns {string} Returns the source code.
969
- */
970
- function toSource(func) {
971
- if (func != null) {
972
- try {
973
- return funcToString.call(func);
974
- } catch (e) {}
975
- try {
976
- return func + "";
977
- } catch (e) {}
978
- }
979
- return "";
980
- }
981
- /**
982
- * Creates a function that memoizes the result of `func`. If `resolver` is
983
- * provided, it determines the cache key for storing the result based on the
984
- * arguments provided to the memoized function. By default, the first argument
985
- * provided to the memoized function is used as the map cache key. The `func`
986
- * is invoked with the `this` binding of the memoized function.
987
- *
988
- * **Note:** The cache is exposed as the `cache` property on the memoized
989
- * function. Its creation may be customized by replacing the `_.memoize.Cache`
990
- * constructor with one whose instances implement the
991
- * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)
992
- * method interface of `delete`, `get`, `has`, and `set`.
993
- *
994
- * @static
995
- * @memberOf _
996
- * @since 0.1.0
997
- * @category Function
998
- * @param {Function} func The function to have its output memoized.
999
- * @param {Function} [resolver] The function to resolve the cache key.
1000
- * @returns {Function} Returns the new memoized function.
1001
- * @example
1002
- *
1003
- * var object = { 'a': 1, 'b': 2 };
1004
- * var other = { 'c': 3, 'd': 4 };
1005
- *
1006
- * var values = _.memoize(_.values);
1007
- * values(object);
1008
- * // => [1, 2]
1009
- *
1010
- * values(other);
1011
- * // => [3, 4]
1012
- *
1013
- * object.a = 2;
1014
- * values(object);
1015
- * // => [1, 2]
1016
- *
1017
- * // Modify the result cache.
1018
- * values.cache.set(object, ['a', 'b']);
1019
- * values(object);
1020
- * // => ['a', 'b']
1021
- *
1022
- * // Replace `_.memoize.Cache`.
1023
- * _.memoize.Cache = WeakMap;
1024
- */
1025
- function memoize(func, resolver) {
1026
- if (typeof func != "function" || resolver && typeof resolver != "function") throw new TypeError(FUNC_ERROR_TEXT);
1027
- var memoized = function() {
1028
- var args = arguments, key = resolver ? resolver.apply(this, args) : args[0], cache = memoized.cache;
1029
- if (cache.has(key)) return cache.get(key);
1030
- var result = func.apply(this, args);
1031
- memoized.cache = cache.set(key, result);
1032
- return result;
1033
- };
1034
- memoized.cache = new (memoize.Cache || MapCache)();
1035
- return memoized;
1036
- }
1037
- memoize.Cache = MapCache;
1038
- /**
1039
- * Performs a
1040
- * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
1041
- * comparison between two values to determine if they are equivalent.
1042
- *
1043
- * @static
1044
- * @memberOf _
1045
- * @since 4.0.0
1046
- * @category Lang
1047
- * @param {*} value The value to compare.
1048
- * @param {*} other The other value to compare.
1049
- * @returns {boolean} Returns `true` if the values are equivalent, else `false`.
1050
- * @example
1051
- *
1052
- * var object = { 'a': 1 };
1053
- * var other = { 'a': 1 };
1054
- *
1055
- * _.eq(object, object);
1056
- * // => true
1057
- *
1058
- * _.eq(object, other);
1059
- * // => false
1060
- *
1061
- * _.eq('a', 'a');
1062
- * // => true
1063
- *
1064
- * _.eq('a', Object('a'));
1065
- * // => false
1066
- *
1067
- * _.eq(NaN, NaN);
1068
- * // => true
1069
- */
1070
- function eq(value, other) {
1071
- return value === other || value !== value && other !== other;
1072
- }
1073
- /**
1074
- * Checks if `value` is classified as an `Array` object.
1075
- *
1076
- * @static
1077
- * @memberOf _
1078
- * @since 0.1.0
1079
- * @category Lang
1080
- * @param {*} value The value to check.
1081
- * @returns {boolean} Returns `true` if `value` is an array, else `false`.
1082
- * @example
1083
- *
1084
- * _.isArray([1, 2, 3]);
1085
- * // => true
1086
- *
1087
- * _.isArray(document.body.children);
1088
- * // => false
1089
- *
1090
- * _.isArray('abc');
1091
- * // => false
1092
- *
1093
- * _.isArray(_.noop);
1094
- * // => false
1095
- */
1096
- var isArray = Array.isArray;
1097
- /**
1098
- * Checks if `value` is classified as a `Function` object.
1099
- *
1100
- * @static
1101
- * @memberOf _
1102
- * @since 0.1.0
1103
- * @category Lang
1104
- * @param {*} value The value to check.
1105
- * @returns {boolean} Returns `true` if `value` is a function, else `false`.
1106
- * @example
1107
- *
1108
- * _.isFunction(_);
1109
- * // => true
1110
- *
1111
- * _.isFunction(/abc/);
1112
- * // => false
1113
- */
1114
- function isFunction(value) {
1115
- var tag = isObject(value) ? objectToString.call(value) : "";
1116
- return tag == funcTag || tag == genTag;
1117
- }
1118
- /**
1119
- * Checks if `value` is the
1120
- * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
1121
- * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
1122
- *
1123
- * @static
1124
- * @memberOf _
1125
- * @since 0.1.0
1126
- * @category Lang
1127
- * @param {*} value The value to check.
1128
- * @returns {boolean} Returns `true` if `value` is an object, else `false`.
1129
- * @example
1130
- *
1131
- * _.isObject({});
1132
- * // => true
1133
- *
1134
- * _.isObject([1, 2, 3]);
1135
- * // => true
1136
- *
1137
- * _.isObject(_.noop);
1138
- * // => true
1139
- *
1140
- * _.isObject(null);
1141
- * // => false
1142
- */
1143
- function isObject(value) {
1144
- var type = typeof value;
1145
- return !!value && (type == "object" || type == "function");
1146
- }
1147
- /**
1148
- * Checks if `value` is object-like. A value is object-like if it's not `null`
1149
- * and has a `typeof` result of "object".
1150
- *
1151
- * @static
1152
- * @memberOf _
1153
- * @since 4.0.0
1154
- * @category Lang
1155
- * @param {*} value The value to check.
1156
- * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
1157
- * @example
1158
- *
1159
- * _.isObjectLike({});
1160
- * // => true
1161
- *
1162
- * _.isObjectLike([1, 2, 3]);
1163
- * // => true
1164
- *
1165
- * _.isObjectLike(_.noop);
1166
- * // => false
1167
- *
1168
- * _.isObjectLike(null);
1169
- * // => false
1170
- */
1171
- function isObjectLike(value) {
1172
- return !!value && typeof value == "object";
1173
- }
1174
- /**
1175
- * Checks if `value` is classified as a `Symbol` primitive or object.
1176
- *
1177
- * @static
1178
- * @memberOf _
1179
- * @since 4.0.0
1180
- * @category Lang
1181
- * @param {*} value The value to check.
1182
- * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.
1183
- * @example
1184
- *
1185
- * _.isSymbol(Symbol.iterator);
1186
- * // => true
1187
- *
1188
- * _.isSymbol('abc');
1189
- * // => false
1190
- */
1191
- function isSymbol(value) {
1192
- return typeof value == "symbol" || isObjectLike(value) && objectToString.call(value) == symbolTag;
1193
- }
1194
- /**
1195
- * Converts `value` to a string. An empty string is returned for `null`
1196
- * and `undefined` values. The sign of `-0` is preserved.
1197
- *
1198
- * @static
1199
- * @memberOf _
1200
- * @since 4.0.0
1201
- * @category Lang
1202
- * @param {*} value The value to process.
1203
- * @returns {string} Returns the string.
1204
- * @example
1205
- *
1206
- * _.toString(null);
1207
- * // => ''
1208
- *
1209
- * _.toString(-0);
1210
- * // => '-0'
1211
- *
1212
- * _.toString([1, 2, 3]);
1213
- * // => '1,2,3'
1214
- */
1215
- function toString(value) {
1216
- return value == null ? "" : baseToString(value);
1217
- }
1218
- /**
1219
- * Sets the value at `path` of `object`. If a portion of `path` doesn't exist,
1220
- * it's created. Arrays are created for missing index properties while objects
1221
- * are created for all other missing properties. Use `_.setWith` to customize
1222
- * `path` creation.
1223
- *
1224
- * **Note:** This method mutates `object`.
1225
- *
1226
- * @static
1227
- * @memberOf _
1228
- * @since 3.7.0
1229
- * @category Object
1230
- * @param {Object} object The object to modify.
1231
- * @param {Array|string} path The path of the property to set.
1232
- * @param {*} value The value to set.
1233
- * @returns {Object} Returns `object`.
1234
- * @example
1235
- *
1236
- * var object = { 'a': [{ 'b': { 'c': 3 } }] };
1237
- *
1238
- * _.set(object, 'a[0].b.c', 4);
1239
- * console.log(object.a[0].b.c);
1240
- * // => 4
1241
- *
1242
- * _.set(object, ['x', '0', 'y', 'z'], 5);
1243
- * console.log(object.x[0].y.z);
1244
- * // => 5
1245
- */
1246
- function set(object, path, value) {
1247
- return object == null ? object : baseSet(object, path, value);
1248
- }
1249
- module.exports = set;
1250
- }));
1251
- //#endregion
1252
- //#region src/endpoints/Endpoint.ts
1253
- var import_lodash_pick = /* @__PURE__ */ __toESM(require_lodash_pick(), 1);
1254
- var import_lodash_set = /* @__PURE__ */ __toESM(require_lodash_set(), 1);
1255
- /**
1256
- * Represents an HTTP endpoint that can handle requests with type-safe input/output validation,
1257
- * dependency injection, session management, and authorization.
1258
- *
1259
- * @template TRoute - The route path string with parameter placeholders (e.g., '/users/:id')
1260
- * @template TMethod - The HTTP method (GET, POST, PUT, DELETE, PATCH)
1261
- * @template TInput - The input schema definition for body, query, and path parameters
1262
- * @template OutSchema - The output schema for response validation
1263
- * @template TServices - Array of service dependencies to inject
1264
- * @template TLogger - The logger instance type
1265
- * @template TSession - The session data type
1266
- *
1267
- * @extends Function - Base function construct for handler execution
1268
- *
1269
- * @example
1270
- * ```typescript
1271
- * const endpoint = new Endpoint({
1272
- * route: '/users/:id',
1273
- * method: 'GET',
1274
- * input: { params: userIdSchema },
1275
- * output: userSchema,
1276
- * fn: async ({ params }) => getUserById(params.id)
1277
- * });
1278
- * ```
1279
- */
1280
- var Endpoint = class Endpoint extends Function$1 {
1281
- operationId;
1282
- /** The route path pattern with parameter placeholders */
1283
- route;
1284
- /** The HTTP method for this endpoint */
1285
- method;
1286
- /**
1287
- * The surface that serves it, when it was built from one.
1288
- *
1289
- * Carries the env parser the adaptors need, so a generated handler needs no
1290
- * import written for it — and the surface's id, so the build attributes the
1291
- * route to the API that serves it rather than inferring it by exclusion.
1292
- */
1293
- surface;
1294
- /** Optional description for OpenAPI documentation */
1295
- description;
1296
- /** Optional tags for OpenAPI documentation */
1297
- tags;
1298
- /** The HTTP success status code to return (default: 200) */
1299
- status;
1300
- /**
1301
- * Response content type for this endpoint. Defaults to `'application/json'`.
1302
- * Non-JSON types cause adaptors to emit the body as-is with the declared
1303
- * Content-Type header instead of JSON-serializing.
1304
- */
1305
- responseType;
1306
- /** Default headers to apply to all responses */
1307
- defaultHeaders = {};
1308
- /** Function to extract session data from the request context */
1309
- getSession = () => ({});
1310
- /** Function to determine if the request is authorized */
1311
- authorize = () => true;
1312
- /** Optional rate limiting configuration */
1313
- rateLimit;
1314
- /** Optional authorizer for this endpoint */
1315
- authorizer;
1316
- /** Optional actor extractor for audit records */
1317
- actorExtractor;
1318
- /** Declarative audit definitions */
1319
- audits = [];
1320
- /** RLS configuration for this endpoint */
1321
- rlsConfig;
1322
- /** Whether to bypass RLS for this endpoint */
1323
- rlsBypass;
1324
- /** The endpoint handler function */
1325
- endpointFn;
1326
- /**
1327
- * Builds a complete OpenAPI 3.1 schema from an array of endpoints.
1328
- *
1329
- * @param endpoints - Array of endpoint instances to document
1330
- * @param options - Optional configuration for OpenAPI generation
1331
- * @returns OpenAPI 3.1 specification object
1332
- *
1333
- * @example
1334
- * ```typescript
1335
- * const schema = await Endpoint.buildOpenApiSchema([
1336
- * getUserEndpoint,
1337
- * createUserEndpoint
1338
- * ], {
1339
- * title: 'User API',
1340
- * version: '1.0.0'
1341
- * });
1342
- * ```
1343
- */
1344
- static async buildOpenApiSchema(endpoints, options) {
1345
- return buildOpenApiSchema(endpoints, options);
1346
- }
1347
- /**
1348
- * Gets the full path including HTTP method and route.
1349
- * @returns Formatted string like 'GET /users/{id}'
1350
- */
1351
- get fullPath() {
1352
- return `${this.method} ${this._path}`;
1353
- }
1354
- /**
1355
- * Parses and validates input data for a specific input type (body, query, params).
1356
- *
1357
- * @param input - The raw input data to validate
1358
- * @param key - The input type key ('body', 'query', or 'params')
1359
- * @returns The validated input data for the specified key
1360
- * @throws {UnprocessableEntityError} When validation fails
1361
- */
1362
- async parseInput(input, key) {
1363
- const schema = this.input?.[key];
1364
- return Endpoint.parseSchema(schema, input);
1365
- }
1366
- /**
1367
- * Parses and validates the request body against the body schema.
1368
- *
1369
- * @param body - The raw request body to validate
1370
- * @returns The validated body data
1371
- * @throws {UnprocessableEntityError} When body validation fails
1372
- */
1373
- async parseBody(body) {
1374
- return this.parseInput(body, "body");
1375
- }
1376
- static isSuccessStatus(status) {
1377
- return status >= 200 && status < 300;
1378
- }
1379
- /**
1380
- * Creates a case-insensitive header lookup function from a headers object.
1381
- *
1382
- * @param headers - Object containing header key-value pairs
1383
- * @returns Function to retrieve header values by case-insensitive key, or all headers
1384
- *
1385
- * @example
1386
- * ```typescript
1387
- * const headerFn = Endpoint.createHeaders({ 'Content-Type': 'application/json' });
1388
- * headerFn('content-type'); // Returns 'application/json'
1389
- * headerFn(); // Returns { 'content-type': 'application/json' }
1390
- * ```
1391
- */
1392
- static createHeaders(headers) {
1393
- const headerMap = /* @__PURE__ */ new Map();
1394
- for (const [k, v] of Object.entries(headers)) {
1395
- const key = k.toLowerCase();
1396
- headerMap.set(key, v);
1397
- }
1398
- function get(key) {
1399
- if (key === void 0) return Object.fromEntries(headerMap.entries());
1400
- return headerMap.get(key.toLowerCase());
1401
- }
1402
- return get;
1403
- }
1404
- /**
1405
- * Parses cookie string and creates a cookie lookup function.
1406
- *
1407
- * @param cookieHeader - The Cookie header value
1408
- * @returns Function to retrieve cookie values by name, or all cookies
1409
- *
1410
- * @example
1411
- * ```typescript
1412
- * const cookieFn = Endpoint.createCookies('session=abc123; theme=dark');
1413
- * cookieFn('session'); // Returns 'abc123'
1414
- * cookieFn(); // Returns { session: 'abc123', theme: 'dark' }
1415
- * ```
1416
- */
1417
- static createCookies(cookieHeader) {
1418
- const cookieMap = /* @__PURE__ */ new Map();
1419
- if (cookieHeader) {
1420
- const cookies = cookieHeader.split(";");
1421
- for (const cookie of cookies) {
1422
- const [name, ...valueParts] = cookie.trim().split("=");
1423
- if (name) {
1424
- const value = valueParts.join("=");
1425
- cookieMap.set(name, decodeURIComponent(value));
1426
- }
1427
- }
1428
- }
1429
- function get(name) {
1430
- if (name === void 0) return Object.fromEntries(cookieMap.entries());
1431
- return cookieMap.get(name);
1432
- }
1433
- return get;
1434
- }
1435
- /**
1436
- * Formats a cookie as a Set-Cookie header string.
1437
- *
1438
- * @param name - Cookie name
1439
- * @param value - Cookie value
1440
- * @param options - Cookie options (httpOnly, secure, sameSite, etc.)
1441
- * @returns Formatted Set-Cookie header string
1442
- *
1443
- * @example
1444
- * ```typescript
1445
- * const header = Endpoint.formatCookieHeader('session', 'abc123', {
1446
- * httpOnly: true,
1447
- * secure: true,
1448
- * sameSite: 'strict',
1449
- * maxAge: 3600
1450
- * });
1451
- * // Returns: "session=abc123; Max-Age=3600; HttpOnly; Secure; SameSite=Strict"
1452
- * ```
1453
- */
1454
- static formatCookieHeader(name, value, options) {
1455
- let cookie = `${name}=${value}`;
1456
- if (options) {
1457
- if (options.domain) cookie += `; Domain=${options.domain}`;
1458
- if (options.path) cookie += `; Path=${options.path}`;
1459
- if (options.expires) cookie += `; Expires=${options.expires.toUTCString()}`;
1460
- if (options.maxAge !== void 0) cookie += `; Max-Age=${options.maxAge}`;
1461
- if (options.httpOnly) cookie += "; HttpOnly";
1462
- if (options.secure) cookie += "; Secure";
1463
- if (options.sameSite) cookie += `; SameSite=${options.sameSite.charAt(0).toUpperCase() + options.sameSite.slice(1)}`;
1464
- }
1465
- return cookie;
1466
- }
1467
- /**
1468
- * Extracts and refines input data from the endpoint context.
1469
- *
1470
- * @param ctx - The endpoint execution context
1471
- * @returns Object containing only the input data (body, query, params)
1472
- * @internal
1473
- */
1474
- refineInput(ctx) {
1475
- return (0, import_lodash_pick.default)(ctx, [
1476
- "body",
1477
- "query",
1478
- "params"
1479
- ]);
1480
- }
1481
- handler = (ctx, response) => {
1482
- for (const [key, value] of Object.entries(this.defaultHeaders)) response.header(key, value);
1483
- const handlerCtx = {
1484
- ...this.refineInput(ctx),
1485
- services: ctx.services,
1486
- logger: ctx.logger,
1487
- header: ctx.header,
1488
- cookie: ctx.cookie,
1489
- session: ctx.session,
1490
- ..."auditor" in ctx && { auditor: ctx.auditor },
1491
- ..."db" in ctx && { db: ctx.db }
1492
- };
1493
- return this.endpointFn(handlerCtx, response);
1494
- };
1495
- /**
1496
- * Type guard to check if an object is an Endpoint instance.
1497
- *
1498
- * @param obj - The object to check
1499
- * @returns True if the object is an Endpoint
1500
- */
1501
- static isEndpoint(obj) {
1502
- return Boolean(obj && obj.__IS_FUNCTION__ === true && obj.type === "dev.geekmidas.function.endpoint");
1503
- }
1504
- /**
1505
- * Helper to check if response has metadata
1506
- */
1507
- static hasMetadata(response) {
1508
- return response !== null && typeof response === "object" && "data" in response && "metadata" in response;
1509
- }
1510
- /**
1511
- * Converts Express-style route params to OpenAPI format.
1512
- * @returns Route with ':param' converted to '{param}'
1513
- * @internal
1514
- */
1515
- get _path() {
1516
- return this.route.replace(/:(\w+)/g, "{$1}");
1517
- }
1518
- /**
1519
- * Generates OpenAPI 3.1 schema for this endpoint.
1520
- *
1521
- * @returns OpenAPI route definition with operation details
1522
- */
1523
- async toOpenApi3Route(componentCollector) {
1524
- const status = String(this.status);
1525
- const operation = {
1526
- operationId: this.operationId,
1527
- ...this.description && { description: this.description },
1528
- ...this.tags && this.tags.length > 0 && { tags: this.tags },
1529
- responses: { [status]: { description: "Successful response" } }
1530
- };
1531
- const scheme = this.authorizer?.securityScheme;
1532
- if (this.authorizer && scheme && componentCollector) {
1533
- componentCollector.addSecurityScheme(this.authorizer.name, scheme);
1534
- operation.security = [{ [this.authorizer.name]: [] }];
1535
- }
1536
- if (this.outputSchema) {
1537
- const responseSchema = await convertSchemaWithComponents(this.outputSchema, componentCollector);
1538
- if (responseSchema) (0, import_lodash_set.default)(operation, [
1539
- "responses",
1540
- status,
1541
- "content",
1542
- this.responseType,
1543
- "schema"
1544
- ], responseSchema);
1545
- }
1546
- const pathParameters = [];
1547
- const queryParameters = [];
1548
- if (this.input && typeof this.input === "object") {
1549
- if ([
1550
- "POST",
1551
- "PUT",
1552
- "PATCH"
1553
- ].includes(this.method) && "body" in this.input && this.input.body) {
1554
- const bodySchema = await convertSchemaWithComponents(this.input.body, componentCollector);
1555
- if (bodySchema) (0, import_lodash_set.default)(operation, ["requestBody"], {
1556
- required: true,
1557
- content: { "application/json": { schema: bodySchema } }
1558
- });
1559
- }
1560
- if ("params" in this.input && this.input.params) {
1561
- const paramsSchema = await convertStandardSchemaToJsonSchema(this.input.params);
1562
- if (paramsSchema && paramsSchema.type === "object" && paramsSchema.properties) for (const [name, schema] of Object.entries(paramsSchema.properties)) pathParameters.push({
1563
- name,
1564
- in: "path",
1565
- required: paramsSchema.required?.includes(name) ?? true,
1566
- schema
1567
- });
1568
- }
1569
- if ("query" in this.input && this.input.query) {
1570
- const querySchema = await convertStandardSchemaToJsonSchema(this.input.query);
1571
- if (querySchema && querySchema.type === "object" && querySchema.properties) for (const [name, schema] of Object.entries(querySchema.properties)) queryParameters.push({
1572
- name,
1573
- in: "query",
1574
- required: querySchema.required?.includes(name) ?? false,
1575
- schema
1576
- });
1577
- }
1578
- }
1579
- if (queryParameters.length > 0) operation.parameters = queryParameters;
1580
- const routeObject = {};
1581
- if (pathParameters.length > 0) routeObject.parameters = pathParameters;
1582
- routeObject[this.method.toLowerCase()] = operation;
1583
- return { [this._path]: routeObject };
1584
- }
1585
- /**
1586
- * Creates a new Endpoint instance.
1587
- *
1588
- * @param options - Configuration options for the endpoint
1589
- * @param options.fn - The handler function to execute
1590
- * @param options.method - HTTP method
1591
- * @param options.route - Route path with parameter placeholders
1592
- * @param options.description - Optional description for documentation
1593
- * @param options.input - Input schemas for validation
1594
- * @param options.logger - Logger instance
1595
- * @param options.output - Output schema for response validation
1596
- * @param options.services - Service dependencies
1597
- * @param options.timeout - Execution timeout in milliseconds
1598
- * @param options.getSession - Session extraction function
1599
- * @param options.authorize - Authorization check function
1600
- * @param options.status - Success HTTP status code (default: 200)
1601
- * @param options.authorizer - Optional authorizer configuration
1602
- */
1603
- constructor({ fn, method, route, description, tags, input, logger, output: outputSchema, services, constructs, timeout, memorySize, getSession, authorize, rateLimit, status = 200, publisherService, events, authorizer, surface, auditorStorageService, actorExtractor, audits, databaseService, rlsConfig, rlsBypass, responseType }) {
1604
- super(fn, timeout, "dev.geekmidas.function.endpoint", input, outputSchema, services, logger, publisherService, events, memorySize, auditorStorageService, void 0, constructs);
1605
- this.route = route;
1606
- this.method = method;
1607
- this.description = description;
1608
- this.tags = tags;
1609
- this.status = status;
1610
- this.responseType = responseType ?? "application/json";
1611
- this.endpointFn = fn;
1612
- if (getSession) this.getSession = getSession;
1613
- if (authorize) this.authorize = authorize;
1614
- if (rateLimit) this.rateLimit = rateLimit;
1615
- if (authorizer) this.authorizer = authorizer;
1616
- this.surface = surface;
1617
- if (actorExtractor) this.actorExtractor = actorExtractor;
1618
- if (audits) this.audits = audits;
1619
- if (databaseService) this.databaseService = databaseService;
1620
- if (rlsConfig) this.rlsConfig = rlsConfig;
1621
- if (rlsBypass) this.rlsBypass = rlsBypass;
1622
- }
1623
- };
1624
- /**
1625
- * Response builder for fluent API in handlers
1626
- */
1627
- var ResponseBuilder = class {
1628
- metadata = {
1629
- headers: {},
1630
- cookies: /* @__PURE__ */ new Map()
1631
- };
1632
- header(key, value) {
1633
- this.metadata.headers[key] = value;
1634
- return this;
1635
- }
1636
- cookie(name, value, options) {
1637
- this.metadata.cookies?.set(name, {
1638
- value,
1639
- options
1640
- });
1641
- return this;
1642
- }
1643
- deleteCookie(name, options) {
1644
- this.metadata.cookies?.set(name, {
1645
- value: "",
1646
- options: {
1647
- ...options,
1648
- maxAge: 0,
1649
- expires: /* @__PURE__ */ new Date(0)
1650
- }
1651
- });
1652
- return this;
1653
- }
1654
- status(code) {
1655
- this.metadata.status = code;
1656
- return this;
1657
- }
1658
- send(data) {
1659
- return {
1660
- data,
1661
- metadata: this.metadata
1662
- };
1663
- }
1664
- getMetadata() {
1665
- return this.metadata;
1666
- }
1667
- };
1668
- //#endregion
1669
- export { ResponseBuilder as n, require_lodash_set as r, Endpoint as t };
1670
-
1671
- //# sourceMappingURL=Endpoint-ONsly_dq.mjs.map