@noy-db/hub 0.3.0-pre.3 → 0.3.0-pre.4

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 (386) hide show
  1. package/dist/adapter/index.d.ts +2 -2
  2. package/dist/adapter/index.js +1 -1
  3. package/dist/aggregate/index.d.ts +3 -3
  4. package/dist/aggregate/index.js +4 -4
  5. package/dist/api-JOXUNSKP.js +20 -0
  6. package/dist/as/index.d.ts +4 -4
  7. package/dist/as/index.js +12 -9
  8. package/dist/at/index.d.ts +2 -2
  9. package/dist/attestation/index.d.ts +3 -3
  10. package/dist/attestation/index.js +21 -18
  11. package/dist/attestation/index.js.map +1 -1
  12. package/dist/{backup-NGRJ46SH.js → backup-MOB27UUN.js} +12 -9
  13. package/dist/{backup-NGRJ46SH.js.map → backup-MOB27UUN.js.map} +1 -1
  14. package/dist/blobs/index.d.ts +4 -4
  15. package/dist/blobs/index.js +11 -8
  16. package/dist/blobs/index.js.map +1 -1
  17. package/dist/bundle/index.d.ts +5 -5
  18. package/dist/bundle/index.js +21 -18
  19. package/dist/bundle/index.js.map +1 -1
  20. package/dist/{bundle-B-P3_Jvb.d.ts → bundle-Bs13EZtX.d.ts} +1 -1
  21. package/dist/by/index.js +2 -2
  22. package/dist/cargo/index.d.ts +4 -4
  23. package/dist/cargo/index.js +23 -20
  24. package/dist/{chunk-VBYVKOMJ.js → chunk-3QRQOBS7.js} +3 -3
  25. package/dist/{chunk-JFYIHLU3.js → chunk-3Y4QLJ6K.js} +2 -2
  26. package/dist/{chunk-BZIWKN74.js → chunk-43ISXURO.js} +2 -2
  27. package/dist/{chunk-7IP75FP2.js → chunk-4K3MQ5S3.js} +2 -2
  28. package/dist/{chunk-6DP5HBQD.js → chunk-5CY35H55.js} +9 -9
  29. package/dist/chunk-5EWYUR5P.js +37 -0
  30. package/dist/chunk-5EWYUR5P.js.map +1 -0
  31. package/dist/{chunk-2KSPDSWI.js → chunk-5MRE3C4Q.js} +5 -5
  32. package/dist/{chunk-5ZPWVNL3.js → chunk-5W7AOFWA.js} +2 -2
  33. package/dist/{chunk-PUNJAEY6.js → chunk-6HNKCKFZ.js} +7 -7
  34. package/dist/{chunk-PJDK2PPQ.js → chunk-6RXPSMKR.js} +3 -3
  35. package/dist/{chunk-Z44OY24N.js → chunk-7J7JRYXW.js} +9 -5
  36. package/dist/chunk-7J7JRYXW.js.map +1 -0
  37. package/dist/{chunk-MCJAUQGE.js → chunk-A5DYVMDR.js} +3 -3
  38. package/dist/{chunk-MIOLJG2R.js → chunk-AF5ZRTZ4.js} +5 -2
  39. package/dist/chunk-AF5ZRTZ4.js.map +1 -0
  40. package/dist/{chunk-TICO2I2O.js → chunk-BKGIWGCX.js} +2 -2
  41. package/dist/{chunk-O5DNEXQC.js → chunk-BMQOH7MM.js} +2 -2
  42. package/dist/{chunk-U6OM4E67.js → chunk-CPXPHQGX.js} +6 -6
  43. package/dist/{chunk-3UDPDRUC.js → chunk-EWR7HL3K.js} +4 -4
  44. package/dist/{chunk-CVXLJIAV.js → chunk-FH52CDEW.js} +5 -5
  45. package/dist/chunk-G4MGYGSS.js +130 -0
  46. package/dist/chunk-G4MGYGSS.js.map +1 -0
  47. package/dist/{chunk-FELHYKIO.js → chunk-G7RDYYTE.js} +2 -2
  48. package/dist/{chunk-N2FP26NH.js → chunk-GBTUANXF.js} +16 -297
  49. package/dist/chunk-GBTUANXF.js.map +1 -0
  50. package/dist/{chunk-UP6EMMDI.js → chunk-GOUNIHFA.js} +10 -10
  51. package/dist/{chunk-DHIN36UC.js → chunk-GQOT6QJR.js} +8 -8
  52. package/dist/{chunk-DGUR3CC4.js → chunk-GXGK22QU.js} +2 -2
  53. package/dist/{chunk-YTIAXSUE.js → chunk-GZZL5R73.js} +4 -4
  54. package/dist/{chunk-E4YJUNPU.js → chunk-H5XRIJX3.js} +7 -7
  55. package/dist/{chunk-DA34OEZU.js → chunk-H7RYPVMJ.js} +2 -2
  56. package/dist/{chunk-2ZORB5RW.js → chunk-HBKDR7R3.js} +3 -3
  57. package/dist/{chunk-BV7KNFJY.js → chunk-HLUKZ36Q.js} +9 -9
  58. package/dist/{chunk-ZNI3RTFV.js → chunk-HMXLN43G.js} +2 -2
  59. package/dist/{chunk-BYW7EU5L.js → chunk-HY6ZGGEC.js} +2 -2
  60. package/dist/{chunk-OVIVYAQL.js → chunk-K5P46KB3.js} +25 -10
  61. package/dist/chunk-K5P46KB3.js.map +1 -0
  62. package/dist/chunk-KYY7L72M.js +106 -0
  63. package/dist/chunk-KYY7L72M.js.map +1 -0
  64. package/dist/{chunk-5Z3RNFJC.js → chunk-LIP6JWYK.js} +3 -3
  65. package/dist/{chunk-OCDUQUAP.js → chunk-LN22XH4B.js} +1 -1
  66. package/dist/chunk-LN22XH4B.js.map +1 -0
  67. package/dist/chunk-LP7BEXCT.js +32 -0
  68. package/dist/chunk-LP7BEXCT.js.map +1 -0
  69. package/dist/{chunk-IJW6K6UX.js → chunk-LPRPVCNY.js} +5 -5
  70. package/dist/{chunk-6EVZXETK.js → chunk-M66NAZA4.js} +3 -3
  71. package/dist/{chunk-HGQG3VIP.js → chunk-N5YVZHCB.js} +2 -2
  72. package/dist/{chunk-IWVWB7BZ.js → chunk-NB47TXGP.js} +12 -12
  73. package/dist/chunk-NO272T7Q.js +194 -0
  74. package/dist/chunk-NO272T7Q.js.map +1 -0
  75. package/dist/{chunk-6OQ7NKMZ.js → chunk-O2DB4C3M.js} +6 -6
  76. package/dist/{chunk-LHYQE3BP.js → chunk-OFBFAVLI.js} +6 -6
  77. package/dist/{chunk-ZFME46HJ.js → chunk-OPTFANOX.js} +3 -3
  78. package/dist/chunk-OPTFANOX.js.map +1 -0
  79. package/dist/{chunk-5EZAJEES.js → chunk-OVO2RZAE.js} +81 -27
  80. package/dist/chunk-OVO2RZAE.js.map +1 -0
  81. package/dist/{chunk-6I2YPLAG.js → chunk-P27Z66EB.js} +7 -7
  82. package/dist/{chunk-7MHVHGQZ.js → chunk-P2LDXRGP.js} +2 -2
  83. package/dist/chunk-P3NGV5RV.js +41 -0
  84. package/dist/chunk-P3NGV5RV.js.map +1 -0
  85. package/dist/{chunk-YN66UOXT.js → chunk-P3V7JTB6.js} +25 -9
  86. package/dist/{chunk-YN66UOXT.js.map → chunk-P3V7JTB6.js.map} +1 -1
  87. package/dist/{chunk-NPVICKZE.js → chunk-P5WXDYMD.js} +8 -197
  88. package/dist/chunk-P5WXDYMD.js.map +1 -0
  89. package/dist/{chunk-CPAROOKP.js → chunk-PGFY7IRW.js} +12 -41
  90. package/dist/chunk-PGFY7IRW.js.map +1 -0
  91. package/dist/{chunk-6RASM2J4.js → chunk-QKVILR7N.js} +2 -2
  92. package/dist/{chunk-LKBLAUOB.js → chunk-QNTEDPWP.js} +3 -3
  93. package/dist/{chunk-P6UXDALK.js → chunk-RDHAGBEB.js} +3 -3
  94. package/dist/{chunk-XRE4JOEO.js → chunk-RTS23VIJ.js} +2 -2
  95. package/dist/{chunk-PYWW4KLO.js → chunk-SEQ2JI3Y.js} +9 -9
  96. package/dist/{chunk-VHEEU4ZO.js → chunk-SW56GSYC.js} +2 -2
  97. package/dist/{chunk-46YGCU6Z.js → chunk-T2EGAXPM.js} +2 -2
  98. package/dist/{chunk-LES2Z7B4.js → chunk-T45LAT2Y.js} +2 -2
  99. package/dist/{chunk-4NMFWOS2.js → chunk-T65UZXR6.js} +3 -3
  100. package/dist/{chunk-2N4MUSF3.js → chunk-TB5RNNJ4.js} +7 -7
  101. package/dist/chunk-TCIUO62Z.js +29 -0
  102. package/dist/chunk-TCIUO62Z.js.map +1 -0
  103. package/dist/chunk-THNJ3IKU.js +17 -0
  104. package/dist/chunk-THNJ3IKU.js.map +1 -0
  105. package/dist/{chunk-L4IRFTIF.js → chunk-TLJOJBZD.js} +3 -23
  106. package/dist/chunk-TLJOJBZD.js.map +1 -0
  107. package/dist/chunk-TQ3REHVF.js +95 -0
  108. package/dist/chunk-TQ3REHVF.js.map +1 -0
  109. package/dist/{chunk-NIA5VQ7G.js → chunk-TVRQ3RYH.js} +28 -9
  110. package/dist/chunk-TVRQ3RYH.js.map +1 -0
  111. package/dist/{chunk-6CNLU4TO.js → chunk-TYGW5TOR.js} +7 -7
  112. package/dist/{chunk-BLZRNHMG.js → chunk-U23JUUPX.js} +8 -1
  113. package/dist/{chunk-BLZRNHMG.js.map → chunk-U23JUUPX.js.map} +1 -1
  114. package/dist/{chunk-U5DWHU3S.js → chunk-U24XHXNK.js} +2 -2
  115. package/dist/chunk-ULIHDPKL.js +94 -0
  116. package/dist/chunk-ULIHDPKL.js.map +1 -0
  117. package/dist/chunk-UOEWDCUX.js +69 -0
  118. package/dist/chunk-UOEWDCUX.js.map +1 -0
  119. package/dist/{chunk-5A6TC3RQ.js → chunk-VAWY44JW.js} +8 -8
  120. package/dist/{chunk-5A6TC3RQ.js.map → chunk-VAWY44JW.js.map} +1 -1
  121. package/dist/{chunk-NTHKOFVL.js → chunk-VFRNWE5P.js} +52 -8
  122. package/dist/chunk-VFRNWE5P.js.map +1 -0
  123. package/dist/{chunk-4DZGZ7II.js → chunk-VMJ5URU7.js} +8 -8
  124. package/dist/chunk-VMJ5URU7.js.map +1 -0
  125. package/dist/{chunk-YDP2SA5K.js → chunk-VPCMJ5Z4.js} +5 -5
  126. package/dist/{chunk-ZAWD6O46.js → chunk-VRPBEOWU.js} +2 -2
  127. package/dist/{chunk-AY4P6PHN.js → chunk-VWGCJUTV.js} +2 -2
  128. package/dist/{chunk-IIK7W3AN.js → chunk-XJR3COJO.js} +5 -5
  129. package/dist/{chunk-ZD4D7UM6.js → chunk-XYYW64LB.js} +2 -2
  130. package/dist/{chunk-4NZCZUGL.js → chunk-YFF2RP3X.js} +2 -2
  131. package/dist/{chunk-WVIIJPTJ.js → chunk-Z3FZC5GV.js} +7 -7
  132. package/dist/{chunk-55HDKLI3.js → chunk-Z5PIUYNB.js} +8 -8
  133. package/dist/{chunk-ZRDYQZYH.js → chunk-Z7KI4WHR.js} +2 -2
  134. package/dist/chunk-ZKF6HH7V.js +120 -0
  135. package/dist/chunk-ZKF6HH7V.js.map +1 -0
  136. package/dist/{chunk-P6DN5QU7.js → chunk-ZKYMKF2S.js} +8 -8
  137. package/dist/{chunk-ADBMJDBW.js → chunk-ZPHDGUZZ.js} +445 -1077
  138. package/dist/chunk-ZPHDGUZZ.js.map +1 -0
  139. package/dist/{chunk-NMRKAGHE.js → chunk-ZROMNP7Q.js} +2 -2
  140. package/dist/classified/index.d.ts +4 -4
  141. package/dist/classified/index.js +3 -3
  142. package/dist/collection-facade-MKEBZDWW.js +39 -0
  143. package/dist/computed-BMMEFRFJ.js +11 -0
  144. package/dist/config-drift-KGM7ZRW4.js +24 -0
  145. package/dist/config-drift-KGM7ZRW4.js.map +1 -0
  146. package/dist/consent/index.d.ts +3 -3
  147. package/dist/consent/index.js +10 -7
  148. package/dist/consent/index.js.map +1 -1
  149. package/dist/crdt/index.d.ts +3 -3
  150. package/dist/delegation-BQNIEHZE.js +25 -0
  151. package/dist/derivations/index.d.ts +4 -4
  152. package/dist/derivations/index.js +12 -9
  153. package/dist/describe/index.d.ts +1 -1
  154. package/dist/{describe-0tiXAjoO.d.ts → describe-C6iHNlqJ.d.ts} +9 -0
  155. package/dist/{dev-unlock-B_s9DUWa.d.ts → dev-unlock-Cqd5Xv5J.d.ts} +1 -1
  156. package/dist/{enclave-IS7HZSQ7.js → enclave-YN6223OG.js} +21 -8
  157. package/dist/executor-CBTNU5VZ.js +9 -0
  158. package/dist/executor-DJHNSTIR.js +9 -0
  159. package/dist/executor-FGISLQIN.js +21 -0
  160. package/dist/export-accessible-P7SLRLK3.js +23 -0
  161. package/dist/extract-partition-RNVSFHAB.js +36 -0
  162. package/dist/{fanout-sidecar-DDKRG2MX.js → fanout-sidecar-WS22Q5WH.js} +12 -9
  163. package/dist/{fanout-sidecar-DDKRG2MX.js.map → fanout-sidecar-WS22Q5WH.js.map} +1 -1
  164. package/dist/fence-watcher-DHQ775JB.js +69 -0
  165. package/dist/fence-watcher-DHQ775JB.js.map +1 -0
  166. package/dist/find-RNBG7LBY.js +11 -0
  167. package/dist/forget/index.js +10 -7
  168. package/dist/forget/index.js.map +1 -1
  169. package/dist/guards/index.d.ts +4 -4
  170. package/dist/guards/index.js +3 -3
  171. package/dist/{hash-CWxn7sf6.d.ts → hash-D8Q5MJLA.d.ts} +1 -1
  172. package/dist/history/index.d.ts +4 -4
  173. package/dist/history/index.js +12 -9
  174. package/dist/history/index.js.map +1 -1
  175. package/dist/i18n/index.d.ts +3 -3
  176. package/dist/i18n/index.js +14 -11
  177. package/dist/i18n/index.js.map +1 -1
  178. package/dist/in/index.d.ts +2 -2
  179. package/dist/{index-D05bV0_g.d.ts → index-D4GQe1Rx.d.ts} +818 -49
  180. package/dist/{index-DTMUUwwW.d.ts → index-DRxk8q_7.d.ts} +3 -3
  181. package/dist/index.d.ts +46 -17
  182. package/dist/index.js +1021 -122
  183. package/dist/index.js.map +1 -1
  184. package/dist/indexing/index.d.ts +3 -3
  185. package/dist/indexing/index.js +4 -4
  186. package/dist/issue-W5QG53B5.js +19 -0
  187. package/dist/json-schema-I22JCYCG.js +44 -0
  188. package/dist/json-schema-I22JCYCG.js.map +1 -0
  189. package/dist/kernel/index.d.ts +3 -3
  190. package/dist/kernel/index.js +13 -10
  191. package/dist/lazy/index.d.ts +21 -0
  192. package/dist/lazy/index.js +12 -0
  193. package/dist/{ledger-YUAJUNFP.js → ledger-KZWBKAG5.js} +12 -9
  194. package/dist/liberate-GMGCHIND.js +24 -0
  195. package/dist/link-set-UQEIYQAM.js +31 -0
  196. package/dist/materialized-views/index.d.ts +4 -4
  197. package/dist/materialized-views/index.js +16 -13
  198. package/dist/{mime-magic-Qr_4HjP6.d.ts → mime-magic-DmwT7OzZ.d.ts} +1 -1
  199. package/dist/noydb-KS2O2MRI.js +60 -0
  200. package/dist/on/index.d.ts +2 -2
  201. package/dist/on/index.js +10 -7
  202. package/dist/overlay-views/index.d.ts +4 -4
  203. package/dist/overlay-views/index.js +4 -4
  204. package/dist/periods/index.d.ts +3 -3
  205. package/dist/periods/index.js +13 -10
  206. package/dist/pod/index.d.ts +3 -3
  207. package/dist/pod/index.js +12 -9
  208. package/dist/{policy-LRE6HTO5.js → policy-YIKUH4AD.js} +5 -5
  209. package/dist/portability/index.d.ts +3 -3
  210. package/dist/portability/index.js +8 -8
  211. package/dist/{public-envelope-WVRRUVAJ.js → public-envelope-MRN5YYZZ.js} +4 -4
  212. package/dist/query/index.d.ts +2 -2
  213. package/dist/query/index.js +6 -6
  214. package/dist/register-K6DDSIXN.js +21 -0
  215. package/dist/registry-IMNMHWTM.js +17 -0
  216. package/dist/registry-K6VUQXKV.js +19 -0
  217. package/dist/registry-ZVO3T4M5.js +9 -0
  218. package/dist/request-withdrawal-EHALV66Y.js +31 -0
  219. package/dist/request-withdrawal-EHALV66Y.js.map +1 -0
  220. package/dist/{reveal-WSUHXCSS.js → reveal-TBLTFWQ2.js} +6 -5
  221. package/dist/{reveal-WSUHXCSS.js.map → reveal-TBLTFWQ2.js.map} +1 -1
  222. package/dist/revoke-MHAUAESM.js +24 -0
  223. package/dist/revoke-MHAUAESM.js.map +1 -0
  224. package/dist/sealed-record/index.d.ts +3 -3
  225. package/dist/sealed-record/index.js +13 -10
  226. package/dist/sealed-record/index.js.map +1 -1
  227. package/dist/session/index.d.ts +4 -4
  228. package/dist/session/index.js +10 -7
  229. package/dist/session/index.js.map +1 -1
  230. package/dist/shadow/index.d.ts +3 -3
  231. package/dist/shadow/index.js +2 -2
  232. package/dist/signer-PQ74YXRY.js +25 -0
  233. package/dist/signer-PQ74YXRY.js.map +1 -0
  234. package/dist/snapshots/index.d.ts +3 -3
  235. package/dist/snapshots/index.js +11 -8
  236. package/dist/snapshots/index.js.map +1 -1
  237. package/dist/{stale-LX4BR43V.js → stale-7Q62KVI3.js} +2 -2
  238. package/dist/stale-7Q62KVI3.js.map +1 -0
  239. package/dist/storage-5E6YB2JY.js +21 -0
  240. package/dist/storage-5E6YB2JY.js.map +1 -0
  241. package/dist/{store-coordination-provider-KTRIC6PR.js → store-coordination-provider-JJCEMTAE.js} +3 -3
  242. package/dist/sync/index.d.ts +2 -2
  243. package/dist/sync/index.js +10 -7
  244. package/dist/sync/index.js.map +1 -1
  245. package/dist/team/index.d.ts +18 -4
  246. package/dist/team/index.js +24 -14
  247. package/dist/tiers/index.d.ts +2 -2
  248. package/dist/tiers/index.js +11 -8
  249. package/dist/to/index.d.ts +2 -2
  250. package/dist/to/index.js +1 -1
  251. package/dist/{transition-guard-C1Pyz8nH.d.ts → transition-guard-C4hvR-Ac.d.ts} +1 -1
  252. package/dist/tx/index.d.ts +3 -3
  253. package/dist/tx/index.js +3 -3
  254. package/dist/ui/index.d.ts +1 -1
  255. package/dist/util/index.js +1 -1
  256. package/dist/validators-Ctgkj5qd.d.ts +101 -0
  257. package/dist/{vault-diff-Fn0WeY2w.d.ts → vault-diff-B1Ir6EGs.d.ts} +1 -1
  258. package/dist/{verify-SW6J63Q2.js → verify-YB5LQHNA.js} +11 -7
  259. package/dist/{verify-SW6J63Q2.js.map → verify-YB5LQHNA.js.map} +1 -1
  260. package/dist/walk-5C3GPKT2.js +241 -0
  261. package/dist/walk-5C3GPKT2.js.map +1 -0
  262. package/dist/with/index.d.ts +3 -3
  263. package/dist/with/index.js +12 -9
  264. package/dist/{with-materialized-view-NKxs6iK5.d.ts → with-materialized-view-Bp65kKdQ.d.ts} +1 -1
  265. package/dist/{with-overlayed-view-B4fPYHwV.d.ts → with-overlayed-view-BRhdQNrK.d.ts} +1 -1
  266. package/dist/{with-rollup-Bl0sRFEt.d.ts → with-rollup-bQRPc3y1.d.ts} +1 -1
  267. package/dist/withdraw-accessible-JMX2TCPX.js +28 -0
  268. package/dist/withdraw-accessible-JMX2TCPX.js.map +1 -0
  269. package/package.json +7 -3
  270. package/dist/api-LORZ2EZU.js +0 -17
  271. package/dist/chunk-4DZGZ7II.js.map +0 -1
  272. package/dist/chunk-5EZAJEES.js.map +0 -1
  273. package/dist/chunk-ADBMJDBW.js.map +0 -1
  274. package/dist/chunk-CPAROOKP.js.map +0 -1
  275. package/dist/chunk-L4IRFTIF.js.map +0 -1
  276. package/dist/chunk-MIOLJG2R.js.map +0 -1
  277. package/dist/chunk-N2FP26NH.js.map +0 -1
  278. package/dist/chunk-NIA5VQ7G.js.map +0 -1
  279. package/dist/chunk-NPVICKZE.js.map +0 -1
  280. package/dist/chunk-NTHKOFVL.js.map +0 -1
  281. package/dist/chunk-OCDUQUAP.js.map +0 -1
  282. package/dist/chunk-OVIVYAQL.js.map +0 -1
  283. package/dist/chunk-QLQS5A7X.js +0 -524
  284. package/dist/chunk-QLQS5A7X.js.map +0 -1
  285. package/dist/chunk-Z44OY24N.js.map +0 -1
  286. package/dist/chunk-ZFME46HJ.js.map +0 -1
  287. package/dist/collection-facade-XPVRHBGU.js +0 -36
  288. package/dist/delegation-4HUHUE6T.js +0 -22
  289. package/dist/executor-ANFBCOYA.js +0 -9
  290. package/dist/executor-IKT47SH2.js +0 -9
  291. package/dist/executor-OIECZXTV.js +0 -18
  292. package/dist/export-accessible-NZWCFZHL.js +0 -20
  293. package/dist/extract-partition-52LX6RQH.js +0 -33
  294. package/dist/issue-F4SYPJGJ.js +0 -16
  295. package/dist/liberate-6LDETRIW.js +0 -21
  296. package/dist/noydb-WQNBVJIG.js +0 -54
  297. package/dist/registry-6HZ2JSQ7.js +0 -14
  298. package/dist/registry-GPXZQ7DT.js +0 -9
  299. package/dist/registry-USYD2ECC.js +0 -16
  300. package/dist/request-withdrawal-54V4L6CR.js +0 -28
  301. package/dist/revoke-JV26NTQD.js +0 -21
  302. package/dist/signer-AE56T5HE.js +0 -22
  303. package/dist/validators-Dzn7T-3x.d.ts +0 -62
  304. package/dist/withdraw-accessible-DGA4V2TP.js +0 -25
  305. /package/dist/{api-LORZ2EZU.js.map → api-JOXUNSKP.js.map} +0 -0
  306. /package/dist/{chunk-VBYVKOMJ.js.map → chunk-3QRQOBS7.js.map} +0 -0
  307. /package/dist/{chunk-JFYIHLU3.js.map → chunk-3Y4QLJ6K.js.map} +0 -0
  308. /package/dist/{chunk-BZIWKN74.js.map → chunk-43ISXURO.js.map} +0 -0
  309. /package/dist/{chunk-7IP75FP2.js.map → chunk-4K3MQ5S3.js.map} +0 -0
  310. /package/dist/{chunk-6DP5HBQD.js.map → chunk-5CY35H55.js.map} +0 -0
  311. /package/dist/{chunk-2KSPDSWI.js.map → chunk-5MRE3C4Q.js.map} +0 -0
  312. /package/dist/{chunk-5ZPWVNL3.js.map → chunk-5W7AOFWA.js.map} +0 -0
  313. /package/dist/{chunk-PUNJAEY6.js.map → chunk-6HNKCKFZ.js.map} +0 -0
  314. /package/dist/{chunk-PJDK2PPQ.js.map → chunk-6RXPSMKR.js.map} +0 -0
  315. /package/dist/{chunk-MCJAUQGE.js.map → chunk-A5DYVMDR.js.map} +0 -0
  316. /package/dist/{chunk-TICO2I2O.js.map → chunk-BKGIWGCX.js.map} +0 -0
  317. /package/dist/{chunk-O5DNEXQC.js.map → chunk-BMQOH7MM.js.map} +0 -0
  318. /package/dist/{chunk-U6OM4E67.js.map → chunk-CPXPHQGX.js.map} +0 -0
  319. /package/dist/{chunk-3UDPDRUC.js.map → chunk-EWR7HL3K.js.map} +0 -0
  320. /package/dist/{chunk-CVXLJIAV.js.map → chunk-FH52CDEW.js.map} +0 -0
  321. /package/dist/{chunk-FELHYKIO.js.map → chunk-G7RDYYTE.js.map} +0 -0
  322. /package/dist/{chunk-UP6EMMDI.js.map → chunk-GOUNIHFA.js.map} +0 -0
  323. /package/dist/{chunk-DHIN36UC.js.map → chunk-GQOT6QJR.js.map} +0 -0
  324. /package/dist/{chunk-DGUR3CC4.js.map → chunk-GXGK22QU.js.map} +0 -0
  325. /package/dist/{chunk-YTIAXSUE.js.map → chunk-GZZL5R73.js.map} +0 -0
  326. /package/dist/{chunk-E4YJUNPU.js.map → chunk-H5XRIJX3.js.map} +0 -0
  327. /package/dist/{chunk-DA34OEZU.js.map → chunk-H7RYPVMJ.js.map} +0 -0
  328. /package/dist/{chunk-2ZORB5RW.js.map → chunk-HBKDR7R3.js.map} +0 -0
  329. /package/dist/{chunk-BV7KNFJY.js.map → chunk-HLUKZ36Q.js.map} +0 -0
  330. /package/dist/{chunk-ZNI3RTFV.js.map → chunk-HMXLN43G.js.map} +0 -0
  331. /package/dist/{chunk-BYW7EU5L.js.map → chunk-HY6ZGGEC.js.map} +0 -0
  332. /package/dist/{chunk-5Z3RNFJC.js.map → chunk-LIP6JWYK.js.map} +0 -0
  333. /package/dist/{chunk-IJW6K6UX.js.map → chunk-LPRPVCNY.js.map} +0 -0
  334. /package/dist/{chunk-6EVZXETK.js.map → chunk-M66NAZA4.js.map} +0 -0
  335. /package/dist/{chunk-HGQG3VIP.js.map → chunk-N5YVZHCB.js.map} +0 -0
  336. /package/dist/{chunk-IWVWB7BZ.js.map → chunk-NB47TXGP.js.map} +0 -0
  337. /package/dist/{chunk-6OQ7NKMZ.js.map → chunk-O2DB4C3M.js.map} +0 -0
  338. /package/dist/{chunk-LHYQE3BP.js.map → chunk-OFBFAVLI.js.map} +0 -0
  339. /package/dist/{chunk-6I2YPLAG.js.map → chunk-P27Z66EB.js.map} +0 -0
  340. /package/dist/{chunk-7MHVHGQZ.js.map → chunk-P2LDXRGP.js.map} +0 -0
  341. /package/dist/{chunk-6RASM2J4.js.map → chunk-QKVILR7N.js.map} +0 -0
  342. /package/dist/{chunk-LKBLAUOB.js.map → chunk-QNTEDPWP.js.map} +0 -0
  343. /package/dist/{chunk-P6UXDALK.js.map → chunk-RDHAGBEB.js.map} +0 -0
  344. /package/dist/{chunk-XRE4JOEO.js.map → chunk-RTS23VIJ.js.map} +0 -0
  345. /package/dist/{chunk-PYWW4KLO.js.map → chunk-SEQ2JI3Y.js.map} +0 -0
  346. /package/dist/{chunk-VHEEU4ZO.js.map → chunk-SW56GSYC.js.map} +0 -0
  347. /package/dist/{chunk-46YGCU6Z.js.map → chunk-T2EGAXPM.js.map} +0 -0
  348. /package/dist/{chunk-LES2Z7B4.js.map → chunk-T45LAT2Y.js.map} +0 -0
  349. /package/dist/{chunk-4NMFWOS2.js.map → chunk-T65UZXR6.js.map} +0 -0
  350. /package/dist/{chunk-2N4MUSF3.js.map → chunk-TB5RNNJ4.js.map} +0 -0
  351. /package/dist/{chunk-6CNLU4TO.js.map → chunk-TYGW5TOR.js.map} +0 -0
  352. /package/dist/{chunk-U5DWHU3S.js.map → chunk-U24XHXNK.js.map} +0 -0
  353. /package/dist/{chunk-YDP2SA5K.js.map → chunk-VPCMJ5Z4.js.map} +0 -0
  354. /package/dist/{chunk-ZAWD6O46.js.map → chunk-VRPBEOWU.js.map} +0 -0
  355. /package/dist/{chunk-AY4P6PHN.js.map → chunk-VWGCJUTV.js.map} +0 -0
  356. /package/dist/{chunk-IIK7W3AN.js.map → chunk-XJR3COJO.js.map} +0 -0
  357. /package/dist/{chunk-ZD4D7UM6.js.map → chunk-XYYW64LB.js.map} +0 -0
  358. /package/dist/{chunk-4NZCZUGL.js.map → chunk-YFF2RP3X.js.map} +0 -0
  359. /package/dist/{chunk-WVIIJPTJ.js.map → chunk-Z3FZC5GV.js.map} +0 -0
  360. /package/dist/{chunk-55HDKLI3.js.map → chunk-Z5PIUYNB.js.map} +0 -0
  361. /package/dist/{chunk-ZRDYQZYH.js.map → chunk-Z7KI4WHR.js.map} +0 -0
  362. /package/dist/{chunk-P6DN5QU7.js.map → chunk-ZKYMKF2S.js.map} +0 -0
  363. /package/dist/{chunk-NMRKAGHE.js.map → chunk-ZROMNP7Q.js.map} +0 -0
  364. /package/dist/{collection-facade-XPVRHBGU.js.map → collection-facade-MKEBZDWW.js.map} +0 -0
  365. /package/dist/{delegation-4HUHUE6T.js.map → computed-BMMEFRFJ.js.map} +0 -0
  366. /package/dist/{enclave-IS7HZSQ7.js.map → delegation-BQNIEHZE.js.map} +0 -0
  367. /package/dist/{executor-ANFBCOYA.js.map → enclave-YN6223OG.js.map} +0 -0
  368. /package/dist/{executor-IKT47SH2.js.map → executor-CBTNU5VZ.js.map} +0 -0
  369. /package/dist/{executor-OIECZXTV.js.map → executor-DJHNSTIR.js.map} +0 -0
  370. /package/dist/{export-accessible-NZWCFZHL.js.map → executor-FGISLQIN.js.map} +0 -0
  371. /package/dist/{extract-partition-52LX6RQH.js.map → export-accessible-P7SLRLK3.js.map} +0 -0
  372. /package/dist/{issue-F4SYPJGJ.js.map → extract-partition-RNVSFHAB.js.map} +0 -0
  373. /package/dist/{ledger-YUAJUNFP.js.map → find-RNBG7LBY.js.map} +0 -0
  374. /package/dist/{liberate-6LDETRIW.js.map → issue-W5QG53B5.js.map} +0 -0
  375. /package/dist/{noydb-WQNBVJIG.js.map → lazy/index.js.map} +0 -0
  376. /package/dist/{policy-LRE6HTO5.js.map → ledger-KZWBKAG5.js.map} +0 -0
  377. /package/dist/{public-envelope-WVRRUVAJ.js.map → liberate-GMGCHIND.js.map} +0 -0
  378. /package/dist/{registry-6HZ2JSQ7.js.map → link-set-UQEIYQAM.js.map} +0 -0
  379. /package/dist/{registry-GPXZQ7DT.js.map → noydb-KS2O2MRI.js.map} +0 -0
  380. /package/dist/{registry-USYD2ECC.js.map → policy-YIKUH4AD.js.map} +0 -0
  381. /package/dist/{request-withdrawal-54V4L6CR.js.map → public-envelope-MRN5YYZZ.js.map} +0 -0
  382. /package/dist/{revoke-JV26NTQD.js.map → register-K6DDSIXN.js.map} +0 -0
  383. /package/dist/{signer-AE56T5HE.js.map → registry-IMNMHWTM.js.map} +0 -0
  384. /package/dist/{stale-LX4BR43V.js.map → registry-K6VUQXKV.js.map} +0 -0
  385. /package/dist/{withdraw-accessible-DGA4V2TP.js.map → registry-ZVO3T4M5.js.map} +0 -0
  386. /package/dist/{store-coordination-provider-KTRIC6PR.js.map → store-coordination-provider-JJCEMTAE.js.map} +0 -0
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  OverlayIdMismatchError
3
- } from "./chunk-BLZRNHMG.js";
3
+ } from "./chunk-U23JUUPX.js";
4
4
 
5
5
  // src/with-formula/overlay-views/virtual-collection.ts
6
6
  var OverlayedCollection = class {
@@ -206,4 +206,4 @@ var OverlayedCollection = class {
206
206
  export {
207
207
  OverlayedCollection
208
208
  };
209
- //# sourceMappingURL=chunk-NMRKAGHE.js.map
209
+ //# sourceMappingURL=chunk-ZROMNP7Q.js.map
@@ -1,8 +1,8 @@
1
- import { dL as ClassifiedFieldSpec, dM as ClassifiedStrategy } from '../index-D05bV0_g.js';
2
- export { dN as ClassifiedConfigError, dO as ClassifiedEntry, dP as ClassifiedGroup, dQ as ClassifiedList, dR as ClassifiedRevealCtx, dS as ClassifiedRevealError, dT as ClassifiedRider, dU as ClassifiedRotationError, dV as ClassifiedStorage, dW as ClassifiedVerdict, dX as ClassifiedVerifyCtx, dY as ClassifiedVerifyError, dZ as NO_CLASSIFIED, d_ as isClassifiedFieldSpec, d$ as isClassifiedGroup } from '../index-D05bV0_g.js';
3
- export { C as ClassifiedNeverStoredError, a as ClassifiedValidationError, R as ResolvedClassified, c as classified, l as luhnCheck, r as resolveClassifiedFields } from '../validators-Dzn7T-3x.js';
1
+ import { dL as ClassifiedFieldSpec, dM as ClassifiedStrategy } from '../index-D4GQe1Rx.js';
2
+ export { dN as ClassifiedConfigError, dO as ClassifiedEntry, dP as ClassifiedGroup, dQ as ClassifiedList, dR as ClassifiedRevealCtx, dS as ClassifiedRevealError, dT as ClassifiedRider, dU as ClassifiedRotationError, dV as ClassifiedStorage, dW as ClassifiedVerdict, dX as ClassifiedVerifyCtx, dY as ClassifiedVerifyError, dZ as NO_CLASSIFIED, d_ as isClassifiedFieldSpec, d$ as isClassifiedGroup } from '../index-D4GQe1Rx.js';
3
+ export { C as ClassifiedNeverStoredError, a as ClassifiedValidationError, R as ResolvedClassified, c as classified, l as luhnCheck, r as resolveClassifiedFields } from '../validators-Ctgkj5qd.js';
4
4
  import '../subject-index-O75wKshW.js';
5
- import '../describe-0tiXAjoO.js';
5
+ import '../describe-C6iHNlqJ.js';
6
6
  import '../index-B9QdHytu.js';
7
7
  import '@noy-db/attestation';
8
8
 
@@ -2,7 +2,7 @@ import {
2
2
  classified,
3
3
  luhnCheck,
4
4
  withClassified
5
- } from "../chunk-NTHKOFVL.js";
5
+ } from "../chunk-VFRNWE5P.js";
6
6
  import {
7
7
  ClassifiedNeverStoredError,
8
8
  ClassifiedValidationError,
@@ -11,13 +11,13 @@ import {
11
11
  isClassifiedFieldSpec,
12
12
  isClassifiedGroup,
13
13
  resolveClassifiedFields
14
- } from "../chunk-MIOLJG2R.js";
14
+ } from "../chunk-AF5ZRTZ4.js";
15
15
  import {
16
16
  ClassifiedConfigError,
17
17
  ClassifiedRevealError,
18
18
  ClassifiedRotationError,
19
19
  ClassifiedVerifyError
20
- } from "../chunk-BLZRNHMG.js";
20
+ } from "../chunk-U23JUUPX.js";
21
21
  import "../chunk-PZ5AY32C.js";
22
22
  export {
23
23
  ClassifiedConfigError,
@@ -0,0 +1,39 @@
1
+ import {
2
+ buildPersistedIndexCallbacks,
3
+ buildRetrievalDocs,
4
+ embedOnWrite,
5
+ flushIndex,
6
+ hasIndexedBlobFields,
7
+ retrieve,
8
+ search,
9
+ similarTo,
10
+ warmIndex
11
+ } from "./chunk-GOUNIHFA.js";
12
+ import "./chunk-AURFOK3D.js";
13
+ import "./chunk-SEQ2JI3Y.js";
14
+ import "./chunk-VAWY44JW.js";
15
+ import "./chunk-TB5RNNJ4.js";
16
+ import "./chunk-M66NAZA4.js";
17
+ import "./chunk-OVO2RZAE.js";
18
+ import "./chunk-QKVILR7N.js";
19
+ import "./chunk-LN22XH4B.js";
20
+ import "./chunk-PGFY7IRW.js";
21
+ import "./chunk-TCIUO62Z.js";
22
+ import "./chunk-UOEWDCUX.js";
23
+ import "./chunk-LP7BEXCT.js";
24
+ import "./chunk-TLJOJBZD.js";
25
+ import "./chunk-4K3MQ5S3.js";
26
+ import "./chunk-U23JUUPX.js";
27
+ import "./chunk-PZ5AY32C.js";
28
+ export {
29
+ buildPersistedIndexCallbacks,
30
+ buildRetrievalDocs,
31
+ embedOnWrite,
32
+ flushIndex,
33
+ hasIndexedBlobFields,
34
+ retrieve,
35
+ search,
36
+ similarTo,
37
+ warmIndex
38
+ };
39
+ //# sourceMappingURL=collection-facade-MKEBZDWW.js.map
@@ -0,0 +1,11 @@
1
+ import {
2
+ ComputedFieldError,
3
+ evalComputedFields
4
+ } from "./chunk-5EWYUR5P.js";
5
+ import "./chunk-U23JUUPX.js";
6
+ import "./chunk-PZ5AY32C.js";
7
+ export {
8
+ ComputedFieldError,
9
+ evalComputedFields
10
+ };
11
+ //# sourceMappingURL=computed-BMMEFRFJ.js.map
@@ -0,0 +1,24 @@
1
+ import "./chunk-PZ5AY32C.js";
2
+
3
+ // src/with-shape/classified/config-drift.ts
4
+ function markerForFields(vdigFields) {
5
+ if (vdigFields === null || vdigFields.size === 0) return null;
6
+ const digestOnly = [...vdigFields.keys()];
7
+ return { digestOnly, equatable: digestOnly.filter((f) => vdigFields.get(f)?.equatable === true) };
8
+ }
9
+ async function persistClassifiedMarkerForFields(store, vault, collectionName, vdigFields, dek) {
10
+ const marker = markerForFields(vdigFields);
11
+ if (marker === null) return;
12
+ const { persistClassifiedMarker } = await import("./register-K6DDSIXN.js");
13
+ await persistClassifiedMarker({ store, vault, collectionName, dek, marker });
14
+ }
15
+ async function readClassifiedMarkerDigestOnly(store, vault, collectionName, dek) {
16
+ const { loadPersistedSchema } = await import("./storage-5E6YB2JY.js");
17
+ const persisted = await loadPersistedSchema(store, vault, collectionName, dek);
18
+ return persisted?.classified?.digestOnly ?? [];
19
+ }
20
+ export {
21
+ persistClassifiedMarkerForFields,
22
+ readClassifiedMarkerDigestOnly
23
+ };
24
+ //# sourceMappingURL=config-drift-KGM7ZRW4.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/with-shape/classified/config-drift.ts"],"sourcesContent":["/**\n * C-A / R10 config-drift marker I/O — the store side of the guard, kept OUT of\n * the kernel `Collection` so the always-on kernel surface stays lean. The\n * kernel holds only the per-handle memoization; these helpers do the actual\n * persisted-schema read/write (via the persisted-schemas storage seam, lazily\n * imported so the classified spine tree-shakes).\n *\n * Marker semantics: a collection declaring classified digest-only fields writes\n * an `x-classified` marker into its `_schemas/<collection>` record on the first\n * classified write. A handle later opened WITHOUT `classifiedFields` (a naive\n * handle) reads it back and refuses to write — see RecordCodec.encryptRecord's\n * R10 guard.\n *\n * @module\n */\nimport type { NoydbStore, VdigFieldPolicy, ClassifiedMarker } from '../../kernel/types.js'\nimport type { EnclaveKey } from '../../kernel/enclave/index.js'\n\n/** Build the marker for a handle's digest-only field map, or null when it declares none. */\nfunction markerForFields(vdigFields: ReadonlyMap<string, VdigFieldPolicy> | null): ClassifiedMarker | null {\n if (vdigFields === null || vdigFields.size === 0) return null\n const digestOnly = [...vdigFields.keys()]\n return { digestOnly, equatable: digestOnly.filter((f) => vdigFields.get(f)?.equatable === true) }\n}\n\n/**\n * Persist the classified marker for a handle's digest-only fields. No-op when\n * the handle declares none. Idempotent (delegates to `persistClassifiedMarker`).\n */\nexport async function persistClassifiedMarkerForFields(\n store: NoydbStore,\n vault: string,\n collectionName: string,\n vdigFields: ReadonlyMap<string, VdigFieldPolicy> | null,\n dek: EnclaveKey,\n): Promise<void> {\n const marker = markerForFields(vdigFields)\n if (marker === null) return\n const { persistClassifiedMarker } = await import('../persisted-schemas/register.js')\n await persistClassifiedMarker({ store, vault, collectionName, dek, marker })\n}\n\n/**\n * Read a collection's persisted classified marker's declared digest-only field\n * set (empty when the collection carries no marker). Cross-session drift signal:\n * the R10 superset guard refuses a handle whose declared classified set does not\n * cover every field in this set.\n */\nexport async function readClassifiedMarkerDigestOnly(\n store: NoydbStore,\n vault: string,\n collectionName: string,\n dek: EnclaveKey,\n): Promise<readonly string[]> {\n const { loadPersistedSchema } = await import('../persisted-schemas/storage.js')\n const persisted = await loadPersistedSchema(store, vault, collectionName, dek)\n return persisted?.classified?.digestOnly ?? []\n}\n"],"mappings":";;;AAmBA,SAAS,gBAAgB,YAAkF;AACzG,MAAI,eAAe,QAAQ,WAAW,SAAS,EAAG,QAAO;AACzD,QAAM,aAAa,CAAC,GAAG,WAAW,KAAK,CAAC;AACxC,SAAO,EAAE,YAAY,WAAW,WAAW,OAAO,CAAC,MAAM,WAAW,IAAI,CAAC,GAAG,cAAc,IAAI,EAAE;AAClG;AAMA,eAAsB,iCACpB,OACA,OACA,gBACA,YACA,KACe;AACf,QAAM,SAAS,gBAAgB,UAAU;AACzC,MAAI,WAAW,KAAM;AACrB,QAAM,EAAE,wBAAwB,IAAI,MAAM,OAAO,wBAAkC;AACnF,QAAM,wBAAwB,EAAE,OAAO,OAAO,gBAAgB,KAAK,OAAO,CAAC;AAC7E;AAQA,eAAsB,+BACpB,OACA,OACA,gBACA,KAC4B;AAC5B,QAAM,EAAE,oBAAoB,IAAI,MAAM,OAAO,uBAAiC;AAC9E,QAAM,YAAY,MAAM,oBAAoB,OAAO,OAAO,gBAAgB,GAAG;AAC7E,SAAO,WAAW,YAAY,cAAc,CAAC;AAC/C;","names":[]}
@@ -1,7 +1,7 @@
1
- import { bp as ConsentStrategy } from '../index-D05bV0_g.js';
2
- export { bq as CONSENT_AUDIT_COLLECTION, br as ConsentAuditEntry, bs as ConsentAuditFilter, bt as ConsentContext, bu as ConsentOp, bv as loadConsentEntries, bw as writeConsentEntry } from '../index-D05bV0_g.js';
1
+ import { bp as ConsentStrategy } from '../index-D4GQe1Rx.js';
2
+ export { bq as CONSENT_AUDIT_COLLECTION, br as ConsentAuditEntry, bs as ConsentAuditFilter, bt as ConsentContext, bu as ConsentOp, bv as loadConsentEntries, bw as writeConsentEntry } from '../index-D4GQe1Rx.js';
3
3
  import '../subject-index-O75wKshW.js';
4
- import '../describe-0tiXAjoO.js';
4
+ import '../describe-C6iHNlqJ.js';
5
5
  import '../index-B9QdHytu.js';
6
6
  import '@noy-db/attestation';
7
7
 
@@ -2,14 +2,17 @@ import {
2
2
  CONSENT_AUDIT_COLLECTION,
3
3
  loadConsentEntries,
4
4
  writeConsentEntry
5
- } from "../chunk-ZFME46HJ.js";
5
+ } from "../chunk-OPTFANOX.js";
6
6
  import "../chunk-ZJADGNYF.js";
7
- import "../chunk-5EZAJEES.js";
8
- import "../chunk-6RASM2J4.js";
9
- import "../chunk-CPAROOKP.js";
10
- import "../chunk-L4IRFTIF.js";
11
- import "../chunk-OCDUQUAP.js";
12
- import "../chunk-BLZRNHMG.js";
7
+ import "../chunk-OVO2RZAE.js";
8
+ import "../chunk-QKVILR7N.js";
9
+ import "../chunk-LN22XH4B.js";
10
+ import "../chunk-PGFY7IRW.js";
11
+ import "../chunk-TCIUO62Z.js";
12
+ import "../chunk-UOEWDCUX.js";
13
+ import "../chunk-LP7BEXCT.js";
14
+ import "../chunk-TLJOJBZD.js";
15
+ import "../chunk-U23JUUPX.js";
13
16
  import "../chunk-PZ5AY32C.js";
14
17
 
15
18
  // src/with-audit/consent/active.ts
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/with-audit/consent/active.ts"],"sourcesContent":["/**\n * Active consent strategy. Calling `withConsent()` returns a\n * `ConsentStrategy` that delegates to the real\n * `writeConsentEntry` / `loadConsentEntries` functions. Only\n * reachable through the `@noy-db/hub/consent` subpath.\n */\n\nimport { writeConsentEntry, loadConsentEntries } from './consent.js'\nimport type { ConsentStrategy } from './strategy.js'\n\n/**\n * Build the default consent strategy. Pass into\n * `createNoydb({ consentStrategy: withConsent() })` to enable\n * per-operation audit writes into the reserved `_consent_audit`\n * collection.\n */\nexport function withConsent(): ConsentStrategy {\n return {\n write: writeConsentEntry,\n read: loadConsentEntries,\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;AAgBO,SAAS,cAA+B;AAC7C,SAAO;AAAA,IACL,OAAO;AAAA,IACP,MAAM;AAAA,EACR;AACF;","names":[]}
1
+ {"version":3,"sources":["../../src/with-audit/consent/active.ts"],"sourcesContent":["/**\n * Active consent strategy. Calling `withConsent()` returns a\n * `ConsentStrategy` that delegates to the real\n * `writeConsentEntry` / `loadConsentEntries` functions. Only\n * reachable through the `@noy-db/hub/consent` subpath.\n */\n\nimport { writeConsentEntry, loadConsentEntries } from './consent.js'\nimport type { ConsentStrategy } from './strategy.js'\n\n/**\n * Build the default consent strategy. Pass into\n * `createNoydb({ consentStrategy: withConsent() })` to enable\n * per-operation audit writes into the reserved `_consent_audit`\n * collection.\n */\nexport function withConsent(): ConsentStrategy {\n return {\n write: writeConsentEntry,\n read: loadConsentEntries,\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAgBO,SAAS,cAA+B;AAC7C,SAAO;AAAA,IACL,OAAO;AAAA,IACP,MAAM;AAAA,EACR;AACF;","names":[]}
@@ -1,7 +1,7 @@
1
- import { bf as CrdtStrategy } from '../index-D05bV0_g.js';
2
- export { bg as CrdtMode, bh as CrdtState, bi as LwwMapState, bj as RgaState, bk as YjsState, bl as buildLwwMapState, bm as buildRgaState, bn as mergeCrdtStates, bo as resolveCrdtSnapshot } from '../index-D05bV0_g.js';
1
+ import { bf as CrdtStrategy } from '../index-D4GQe1Rx.js';
2
+ export { bg as CrdtMode, bh as CrdtState, bi as LwwMapState, bj as RgaState, bk as YjsState, bl as buildLwwMapState, bm as buildRgaState, bn as mergeCrdtStates, bo as resolveCrdtSnapshot } from '../index-D4GQe1Rx.js';
3
3
  import '../subject-index-O75wKshW.js';
4
- import '../describe-0tiXAjoO.js';
4
+ import '../describe-C6iHNlqJ.js';
5
5
  import '../index-B9QdHytu.js';
6
6
  import '@noy-db/attestation';
7
7
 
@@ -0,0 +1,25 @@
1
+ import {
2
+ DELEGATIONS_COLLECTION,
3
+ issueDelegation,
4
+ loadActiveDelegations,
5
+ revokeDelegation
6
+ } from "./chunk-VPCMJ5Z4.js";
7
+ import "./chunk-BMQOH7MM.js";
8
+ import "./chunk-ZJADGNYF.js";
9
+ import "./chunk-OVO2RZAE.js";
10
+ import "./chunk-QKVILR7N.js";
11
+ import "./chunk-LN22XH4B.js";
12
+ import "./chunk-PGFY7IRW.js";
13
+ import "./chunk-TCIUO62Z.js";
14
+ import "./chunk-UOEWDCUX.js";
15
+ import "./chunk-LP7BEXCT.js";
16
+ import "./chunk-TLJOJBZD.js";
17
+ import "./chunk-U23JUUPX.js";
18
+ import "./chunk-PZ5AY32C.js";
19
+ export {
20
+ DELEGATIONS_COLLECTION,
21
+ issueDelegation,
22
+ loadActiveDelegations,
23
+ revokeDelegation
24
+ };
25
+ //# sourceMappingURL=delegation-BQNIEHZE.js.map
@@ -1,8 +1,8 @@
1
- export { w as withDerivation, a as withRollup } from '../with-rollup-Bl0sRFEt.js';
2
- import { c2 as DerivationStrategy, c3 as DerivationContext } from '../index-D05bV0_g.js';
3
- export { c4 as ArrayOutputSpec, c5 as DerivationCapExceededError, c6 as DerivationCycleError, c7 as DerivationDepthError, c8 as DerivationOutputShapeError, c9 as DerivationOutputUnknownError, ca as DerivationRegistry, cb as DerivationStrategyHandle, cc as DerivedFromMeta, cd as OutputSpec, ce as RecordOutputSpec } from '../index-D05bV0_g.js';
1
+ export { w as withDerivation, a as withRollup } from '../with-rollup-bQRPc3y1.js';
2
+ import { c2 as DerivationStrategy, c3 as DerivationContext } from '../index-D4GQe1Rx.js';
3
+ export { c4 as ArrayOutputSpec, c5 as DerivationCapExceededError, c6 as DerivationCycleError, c7 as DerivationDepthError, c8 as DerivationOutputShapeError, c9 as DerivationOutputUnknownError, ca as DerivationRegistry, cb as DerivationStrategyHandle, cc as DerivedFromMeta, cd as OutputSpec, ce as RecordOutputSpec } from '../index-D4GQe1Rx.js';
4
4
  import '../subject-index-O75wKshW.js';
5
- import '../describe-0tiXAjoO.js';
5
+ import '../describe-C6iHNlqJ.js';
6
6
  import '../index-B9QdHytu.js';
7
7
  import '@noy-db/attestation';
8
8
 
@@ -1,25 +1,28 @@
1
1
  import {
2
2
  withDerivation,
3
3
  withRollup
4
- } from "../chunk-ZNI3RTFV.js";
4
+ } from "../chunk-HMXLN43G.js";
5
5
  import {
6
6
  DerivationRegistry
7
- } from "../chunk-P6UXDALK.js";
7
+ } from "../chunk-RDHAGBEB.js";
8
8
  import {
9
9
  DerivationExecutor
10
- } from "../chunk-ZD4D7UM6.js";
11
- import "../chunk-5EZAJEES.js";
12
- import "../chunk-6RASM2J4.js";
13
- import "../chunk-CPAROOKP.js";
14
- import "../chunk-L4IRFTIF.js";
15
- import "../chunk-OCDUQUAP.js";
10
+ } from "../chunk-XYYW64LB.js";
11
+ import "../chunk-OVO2RZAE.js";
12
+ import "../chunk-QKVILR7N.js";
13
+ import "../chunk-LN22XH4B.js";
14
+ import "../chunk-PGFY7IRW.js";
15
+ import "../chunk-TCIUO62Z.js";
16
+ import "../chunk-UOEWDCUX.js";
17
+ import "../chunk-LP7BEXCT.js";
18
+ import "../chunk-TLJOJBZD.js";
16
19
  import {
17
20
  DerivationCapExceededError,
18
21
  DerivationCycleError,
19
22
  DerivationDepthError,
20
23
  DerivationOutputShapeError,
21
24
  DerivationOutputUnknownError
22
- } from "../chunk-BLZRNHMG.js";
25
+ } from "../chunk-U23JUUPX.js";
23
26
  import "../chunk-PZ5AY32C.js";
24
27
  export {
25
28
  DerivationCapExceededError,
@@ -1 +1 @@
1
- export { C as CollectionDescription, a as CollectionMeta, D as DescribeOptions, b as DescribedField, F as FieldMeta, S as SemanticType } from '../describe-0tiXAjoO.js';
1
+ export { C as CollectionDescription, a as CollectionMeta, D as DescribeOptions, b as DescribedField, F as FieldMeta, S as SemanticType } from '../describe-C6iHNlqJ.js';
@@ -133,6 +133,15 @@ interface DescribedField {
133
133
  } | {
134
134
  readonly rider: string;
135
135
  };
136
+ /**
137
+ * Present (and `true`) only when the field opted into the equatable blind
138
+ * index. Additive metadata — emitted UNGATED (no `withClassified()` needed;
139
+ * `toJSONSchema()` carries it too), so it advertises *that* the field is
140
+ * equatable beyond the DEK-consent boundary. Intended: it's a structural
141
+ * property a schema consumer legitimately needs and discloses no value. A
142
+ * deployment wanting it gated can gate this behind its value-bearing door.
143
+ */
144
+ readonly equatable?: true;
136
145
  };
137
146
  }
138
147
  interface CollectionDescription {
@@ -1,4 +1,4 @@
1
- import { cR as Role, cF as UnlockedKeyring } from './index-D05bV0_g.js';
1
+ import { cR as Role, cF as UnlockedKeyring } from './index-D4GQe1Rx.js';
2
2
 
3
3
  /**
4
4
  * Session tokens —
@@ -12,17 +12,27 @@ import {
12
12
  rotateRecordCek,
13
13
  sealRecordToHost,
14
14
  writeEnvelopeBody
15
- } from "./chunk-5EZAJEES.js";
15
+ } from "./chunk-OVO2RZAE.js";
16
16
  import {
17
17
  buildTombstone,
18
18
  isTombstone
19
- } from "./chunk-6RASM2J4.js";
19
+ } from "./chunk-QKVILR7N.js";
20
+ import "./chunk-LN22XH4B.js";
20
21
  import {
21
22
  ctEqualTags,
22
23
  deriveVdigSlotKey,
23
- evaluateKofN,
24
+ evaluateKofN
25
+ } from "./chunk-PGFY7IRW.js";
26
+ import "./chunk-TCIUO62Z.js";
27
+ import {
28
+ computeBidxTarget,
29
+ deriveClassifyIndexKey,
30
+ deriveClassifyIndexSalt,
31
+ mintBidxTag
32
+ } from "./chunk-UOEWDCUX.js";
33
+ import {
24
34
  pbkdf2VerifyDigest
25
- } from "./chunk-CPAROOKP.js";
35
+ } from "./chunk-LP7BEXCT.js";
26
36
  import {
27
37
  base64ToBuffer,
28
38
  bufferToBase64,
@@ -50,9 +60,8 @@ import {
50
60
  unwrapKey,
51
61
  wrapCek,
52
62
  wrapKey
53
- } from "./chunk-L4IRFTIF.js";
54
- import "./chunk-OCDUQUAP.js";
55
- import "./chunk-BLZRNHMG.js";
63
+ } from "./chunk-TLJOJBZD.js";
64
+ import "./chunk-U23JUUPX.js";
56
65
  import "./chunk-PZ5AY32C.js";
57
66
  export {
58
67
  RecordCodec,
@@ -60,11 +69,14 @@ export {
60
69
  base64ToBuffer,
61
70
  bufferToBase64,
62
71
  buildTombstone,
72
+ computeBidxTarget,
63
73
  ctEqualTags,
64
74
  decrypt,
65
75
  decryptBytes,
66
76
  decryptBytesWithAAD,
67
77
  decryptDeterministic,
78
+ deriveClassifyIndexKey,
79
+ deriveClassifyIndexSalt,
68
80
  deriveDeterministicKey,
69
81
  deriveKey,
70
82
  derivePassphraseKey,
@@ -86,6 +98,7 @@ export {
86
98
  hmacSha256Hex,
87
99
  importCek,
88
100
  isTombstone,
101
+ mintBidxTag,
89
102
  openEnvelopeJson,
90
103
  pbkdf2VerifyDigest,
91
104
  queryByDet,
@@ -101,4 +114,4 @@ export {
101
114
  wrapKey,
102
115
  writeEnvelopeBody
103
116
  };
104
- //# sourceMappingURL=enclave-IS7HZSQ7.js.map
117
+ //# sourceMappingURL=enclave-YN6223OG.js.map
@@ -0,0 +1,9 @@
1
+ import {
2
+ DerivationExecutor
3
+ } from "./chunk-XYYW64LB.js";
4
+ import "./chunk-U23JUUPX.js";
5
+ import "./chunk-PZ5AY32C.js";
6
+ export {
7
+ DerivationExecutor
8
+ };
9
+ //# sourceMappingURL=executor-CBTNU5VZ.js.map
@@ -0,0 +1,9 @@
1
+ import {
2
+ GuardExecutor
3
+ } from "./chunk-GXGK22QU.js";
4
+ import "./chunk-U23JUUPX.js";
5
+ import "./chunk-PZ5AY32C.js";
6
+ export {
7
+ GuardExecutor
8
+ };
9
+ //# sourceMappingURL=executor-DJHNSTIR.js.map
@@ -0,0 +1,21 @@
1
+ import {
2
+ MaterializedViewExecutor
3
+ } from "./chunk-FH52CDEW.js";
4
+ import "./chunk-LIP6JWYK.js";
5
+ import "./chunk-OVO2RZAE.js";
6
+ import "./chunk-QKVILR7N.js";
7
+ import "./chunk-LN22XH4B.js";
8
+ import "./chunk-PGFY7IRW.js";
9
+ import "./chunk-TCIUO62Z.js";
10
+ import "./chunk-UOEWDCUX.js";
11
+ import "./chunk-LP7BEXCT.js";
12
+ import "./chunk-TLJOJBZD.js";
13
+ import "./chunk-P5WXDYMD.js";
14
+ import "./chunk-ZKF6HH7V.js";
15
+ import "./chunk-4K3MQ5S3.js";
16
+ import "./chunk-U23JUUPX.js";
17
+ import "./chunk-PZ5AY32C.js";
18
+ export {
19
+ MaterializedViewExecutor
20
+ };
21
+ //# sourceMappingURL=executor-FGISLQIN.js.map
@@ -0,0 +1,23 @@
1
+ import {
2
+ buildAccessibleBundle,
3
+ exportAccessibleData,
4
+ resolveAccessibleCollections
5
+ } from "./chunk-P2LDXRGP.js";
6
+ import "./chunk-EWR7HL3K.js";
7
+ import "./chunk-3QRQOBS7.js";
8
+ import "./chunk-OVO2RZAE.js";
9
+ import "./chunk-QKVILR7N.js";
10
+ import "./chunk-LN22XH4B.js";
11
+ import "./chunk-PGFY7IRW.js";
12
+ import "./chunk-TCIUO62Z.js";
13
+ import "./chunk-UOEWDCUX.js";
14
+ import "./chunk-LP7BEXCT.js";
15
+ import "./chunk-TLJOJBZD.js";
16
+ import "./chunk-U23JUUPX.js";
17
+ import "./chunk-PZ5AY32C.js";
18
+ export {
19
+ buildAccessibleBundle,
20
+ exportAccessibleData,
21
+ resolveAccessibleCollections
22
+ };
23
+ //# sourceMappingURL=export-accessible-P7SLRLK3.js.map
@@ -0,0 +1,36 @@
1
+ import {
2
+ extractPartition,
3
+ extractPartitionCore,
4
+ reKeyBlobs,
5
+ reKeyClosure,
6
+ reKeyLedger,
7
+ reKeySchemas,
8
+ sealDeks
9
+ } from "./chunk-NB47TXGP.js";
10
+ import "./chunk-CPXPHQGX.js";
11
+ import "./chunk-Z5PIUYNB.js";
12
+ import "./chunk-EWR7HL3K.js";
13
+ import "./chunk-3QRQOBS7.js";
14
+ import "./chunk-ZJADGNYF.js";
15
+ import "./chunk-I7FD46FF.js";
16
+ import "./chunk-M66NAZA4.js";
17
+ import "./chunk-OVO2RZAE.js";
18
+ import "./chunk-QKVILR7N.js";
19
+ import "./chunk-LN22XH4B.js";
20
+ import "./chunk-PGFY7IRW.js";
21
+ import "./chunk-TCIUO62Z.js";
22
+ import "./chunk-UOEWDCUX.js";
23
+ import "./chunk-LP7BEXCT.js";
24
+ import "./chunk-TLJOJBZD.js";
25
+ import "./chunk-U23JUUPX.js";
26
+ import "./chunk-PZ5AY32C.js";
27
+ export {
28
+ extractPartition,
29
+ extractPartitionCore,
30
+ reKeyBlobs,
31
+ reKeyClosure,
32
+ reKeyLedger,
33
+ reKeySchemas,
34
+ sealDeks
35
+ };
36
+ //# sourceMappingURL=extract-partition-RNVSFHAB.js.map
@@ -1,15 +1,18 @@
1
1
  import {
2
2
  openEnvelopeJson
3
- } from "./chunk-5EZAJEES.js";
4
- import "./chunk-6RASM2J4.js";
5
- import "./chunk-CPAROOKP.js";
6
- import {
7
- encrypt
8
- } from "./chunk-L4IRFTIF.js";
3
+ } from "./chunk-OVO2RZAE.js";
4
+ import "./chunk-QKVILR7N.js";
9
5
  import {
10
6
  NOYDB_FORMAT_VERSION
11
- } from "./chunk-OCDUQUAP.js";
12
- import "./chunk-BLZRNHMG.js";
7
+ } from "./chunk-LN22XH4B.js";
8
+ import "./chunk-PGFY7IRW.js";
9
+ import "./chunk-TCIUO62Z.js";
10
+ import "./chunk-UOEWDCUX.js";
11
+ import "./chunk-LP7BEXCT.js";
12
+ import {
13
+ encrypt
14
+ } from "./chunk-TLJOJBZD.js";
15
+ import "./chunk-U23JUUPX.js";
13
16
  import "./chunk-PZ5AY32C.js";
14
17
 
15
18
  // src/with-formula/derivations/fanout-sidecar.ts
@@ -68,4 +71,4 @@ export {
68
71
  loadFanoutSidecar,
69
72
  saveFanoutSidecar
70
73
  };
71
- //# sourceMappingURL=fanout-sidecar-DDKRG2MX.js.map
74
+ //# sourceMappingURL=fanout-sidecar-WS22Q5WH.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/with-formula/derivations/fanout-sidecar.ts"],"sourcesContent":["/**\n * Per-source-row fanout sidecar for `shape: 'array'` derivations.\n *\n * Each `(sourceCollection, sourceId, outputKey)` triple gets its own\n * envelope at:\n *\n * _meta/derivations-fanout/<sourceCollection>/<sourceId>/<outputKey>\n *\n * The envelope records the last-emitted derived row ids so the\n * dispatcher can compute the diff on every source-row update in O(1):\n * read prior keys, compute `toDelete = prev \\ new`, write new, persist\n * back.\n *\n * The body is encrypted (AES-GCM under the `_meta` collection DEK) when\n * the vault is encrypted — the `keys[]` are derived-row ids produced by a\n * user-supplied key extractor and can be content-bearing (SKU, tag, email),\n * so a ciphertext-only store must not read them, the derivation graph, or\n * `emittedAt`. Back-compat: sidecars written before this fix are plaintext\n * (`_iv === ''`); `loadFanoutSidecar` dual-reads them.\n *\n * @module\n */\nimport type { NoydbStore, EncryptedEnvelope } from '../../kernel/types.js'\nimport { NOYDB_FORMAT_VERSION } from '../../kernel/types.js'\nimport { encrypt, openEnvelopeJson, type EnclaveKey } from '../../kernel/enclave/index.js'\n\ntype GetDEK = (collectionName: string) => Promise<EnclaveKey>\n\n/** The `_meta` collection name whose DEK encrypts the sidecar body. */\nconst FANOUT_DEK_COLLECTION = '_meta'\n\n/** Magic-prefixed JSON payload at `_meta/<recordId>`. */\nexport interface FanoutSidecar {\n readonly _noydb_fanout: 1\n /** Source collection name. */\n readonly source: string\n /** Source record id. */\n readonly sourceId: string\n /** Strategy output key (the key in `strategy.outputs`). */\n readonly outputKey: string\n /** Output collection name (audit / forensics). */\n readonly outputCollection: string\n /** Derived-row ids last emitted for this (source, output) pair. */\n readonly keys: ReadonlyArray<string>\n /** ISO timestamp of last dispatch. */\n readonly emittedAt: string\n}\n\n/**\n * Build the canonical `_meta` record id for a fanout sidecar.\n *\n * The full path inside the store is `_meta/<this-string>`. We pack the\n * full triple into the id so a single `_meta` collection holds all\n * sidecars (collection-per-source would proliferate names; the\n * existing `_meta` flat namespace is cheaper).\n */\nfunction recordId(source: string, sourceId: string, outputKey: string): string {\n // Use `/` as a separator. None of the components is supposed to\n // contain it (collection names + output keys are bare identifiers;\n // source ids are typically ULIDs / UUIDs / app-chosen strings\n // without slashes). If a future source carries `/` in its id, we'd\n // need an escape; deferred until that's a real case.\n return `derivations-fanout/${source}/${sourceId}/${outputKey}`\n}\n\n/**\n * Read the sidecar; returns `undefined` only when it's legitimately absent\n * (no envelope at that id) — the correct signal for callers to skip\n * orphan-row reconciliation because there's nothing to reconcile against.\n *\n * A PRESENT envelope that fails to decrypt or parse is a data-integrity\n * problem, not an absence, and is deliberately NOT caught here: swallowing\n * it to `undefined` would look identical to \"no sidecar\" and make callers\n * (the array-derivation dispatch in `vault.ts`/`collection.ts`) silently\n * skip deleting stale derived rows on a shrink. Let `openEnvelopeJson`'s\n * `DecryptionError`/`TamperedError` and `JSON.parse` failures propagate,\n * matching the no-catch convention of sibling decrypt call-sites (e.g.\n * `with-audit/consent/consent.ts`'s `decryptEntry`).\n *\n * Dual-reads for back-compat: an envelope with `_iv === ''` is a legacy\n * plaintext sidecar (parse `_data` directly); otherwise the body was\n * encrypted under the `_meta` DEK and is decrypted first.\n */\nexport async function loadFanoutSidecar(\n store: NoydbStore,\n vault: string,\n source: string,\n sourceId: string,\n outputKey: string,\n getDEK: GetDEK,\n encrypted: boolean,\n): Promise<FanoutSidecar | undefined> {\n const envelope = await store.get(vault, '_meta', recordId(source, sourceId, outputKey))\n if (!envelope) return undefined\n // Legacy plaintext (`_iv === ''`) reads directly; encrypted bodies decrypt.\n const json = (!encrypted || envelope._iv === '')\n ? envelope._data\n : await openEnvelopeJson(envelope, await getDEK(FANOUT_DEK_COLLECTION))\n const parsed = JSON.parse(json) as FanoutSidecar\n if (parsed._noydb_fanout !== 1) return undefined\n if (!Array.isArray(parsed.keys)) return undefined\n return parsed\n}\n\n/**\n * Persist (insert/replace) the sidecar with a fresh key set. The body is\n * encrypted under the `_meta` DEK when the vault is encrypted (the `keys[]`\n * can be content-bearing); plaintext only in debug/unencrypted vaults.\n */\nexport async function saveFanoutSidecar(\n store: NoydbStore,\n vault: string,\n payload: {\n readonly source: string\n readonly sourceId: string\n readonly outputKey: string\n readonly outputCollection: string\n readonly keys: ReadonlyArray<string>\n },\n getDEK: GetDEK,\n encrypted: boolean,\n): Promise<void> {\n const doc: FanoutSidecar = {\n _noydb_fanout: 1,\n source: payload.source,\n sourceId: payload.sourceId,\n outputKey: payload.outputKey,\n outputCollection: payload.outputCollection,\n keys: payload.keys,\n emittedAt: new Date().toISOString(),\n }\n const id = recordId(payload.source, payload.sourceId, payload.outputKey)\n const prior = await store.get(vault, '_meta', id)\n const json = JSON.stringify(doc)\n let envelope: EncryptedEnvelope\n if (!encrypted) {\n envelope = {\n _noydb: NOYDB_FORMAT_VERSION,\n _v: (prior?._v ?? 0) + 1,\n _ts: new Date().toISOString(),\n _iv: '',\n _data: json,\n }\n } else {\n const { iv, data } = await encrypt(json, await getDEK(FANOUT_DEK_COLLECTION))\n envelope = {\n _noydb: NOYDB_FORMAT_VERSION,\n _v: (prior?._v ?? 0) + 1,\n _ts: new Date().toISOString(),\n _iv: iv,\n _data: data,\n }\n }\n await store.put(vault, '_meta', id, envelope)\n}\n\n/** Delete the sidecar (used on source-row delete cascade). */\nexport async function deleteFanoutSidecar(\n store: NoydbStore,\n vault: string,\n source: string,\n sourceId: string,\n outputKey: string,\n): Promise<void> {\n await store.delete(vault, '_meta', recordId(source, sourceId, outputKey))\n}\n"],"mappings":";;;;;;;;;;;;;;;AA6BA,IAAM,wBAAwB;AA2B9B,SAAS,SAAS,QAAgB,UAAkB,WAA2B;AAM7E,SAAO,sBAAsB,MAAM,IAAI,QAAQ,IAAI,SAAS;AAC9D;AAoBA,eAAsB,kBACpB,OACA,OACA,QACA,UACA,WACA,QACA,WACoC;AACpC,QAAM,WAAW,MAAM,MAAM,IAAI,OAAO,SAAS,SAAS,QAAQ,UAAU,SAAS,CAAC;AACtF,MAAI,CAAC,SAAU,QAAO;AAEtB,QAAM,OAAQ,CAAC,aAAa,SAAS,QAAQ,KACzC,SAAS,QACT,MAAM,iBAAiB,UAAU,MAAM,OAAO,qBAAqB,CAAC;AACxE,QAAM,SAAS,KAAK,MAAM,IAAI;AAC9B,MAAI,OAAO,kBAAkB,EAAG,QAAO;AACvC,MAAI,CAAC,MAAM,QAAQ,OAAO,IAAI,EAAG,QAAO;AACxC,SAAO;AACT;AAOA,eAAsB,kBACpB,OACA,OACA,SAOA,QACA,WACe;AACf,QAAM,MAAqB;AAAA,IACzB,eAAe;AAAA,IACf,QAAQ,QAAQ;AAAA,IAChB,UAAU,QAAQ;AAAA,IAClB,WAAW,QAAQ;AAAA,IACnB,kBAAkB,QAAQ;AAAA,IAC1B,MAAM,QAAQ;AAAA,IACd,YAAW,oBAAI,KAAK,GAAE,YAAY;AAAA,EACpC;AACA,QAAM,KAAK,SAAS,QAAQ,QAAQ,QAAQ,UAAU,QAAQ,SAAS;AACvE,QAAM,QAAQ,MAAM,MAAM,IAAI,OAAO,SAAS,EAAE;AAChD,QAAM,OAAO,KAAK,UAAU,GAAG;AAC/B,MAAI;AACJ,MAAI,CAAC,WAAW;AACd,eAAW;AAAA,MACT,QAAQ;AAAA,MACR,KAAK,OAAO,MAAM,KAAK;AAAA,MACvB,MAAK,oBAAI,KAAK,GAAE,YAAY;AAAA,MAC5B,KAAK;AAAA,MACL,OAAO;AAAA,IACT;AAAA,EACF,OAAO;AACL,UAAM,EAAE,IAAI,KAAK,IAAI,MAAM,QAAQ,MAAM,MAAM,OAAO,qBAAqB,CAAC;AAC5E,eAAW;AAAA,MACT,QAAQ;AAAA,MACR,KAAK,OAAO,MAAM,KAAK;AAAA,MACvB,MAAK,oBAAI,KAAK,GAAE,YAAY;AAAA,MAC5B,KAAK;AAAA,MACL,OAAO;AAAA,IACT;AAAA,EACF;AACA,QAAM,MAAM,IAAI,OAAO,SAAS,IAAI,QAAQ;AAC9C;AAGA,eAAsB,oBACpB,OACA,OACA,QACA,UACA,WACe;AACf,QAAM,MAAM,OAAO,OAAO,SAAS,SAAS,QAAQ,UAAU,SAAS,CAAC;AAC1E;","names":[]}
1
+ {"version":3,"sources":["../src/with-formula/derivations/fanout-sidecar.ts"],"sourcesContent":["/**\n * Per-source-row fanout sidecar for `shape: 'array'` derivations.\n *\n * Each `(sourceCollection, sourceId, outputKey)` triple gets its own\n * envelope at:\n *\n * _meta/derivations-fanout/<sourceCollection>/<sourceId>/<outputKey>\n *\n * The envelope records the last-emitted derived row ids so the\n * dispatcher can compute the diff on every source-row update in O(1):\n * read prior keys, compute `toDelete = prev \\ new`, write new, persist\n * back.\n *\n * The body is encrypted (AES-GCM under the `_meta` collection DEK) when\n * the vault is encrypted — the `keys[]` are derived-row ids produced by a\n * user-supplied key extractor and can be content-bearing (SKU, tag, email),\n * so a ciphertext-only store must not read them, the derivation graph, or\n * `emittedAt`. Back-compat: sidecars written before this fix are plaintext\n * (`_iv === ''`); `loadFanoutSidecar` dual-reads them.\n *\n * @module\n */\nimport type { NoydbStore, EncryptedEnvelope } from '../../kernel/types.js'\nimport { NOYDB_FORMAT_VERSION } from '../../kernel/types.js'\nimport { encrypt, openEnvelopeJson, type EnclaveKey } from '../../kernel/enclave/index.js'\n\ntype GetDEK = (collectionName: string) => Promise<EnclaveKey>\n\n/** The `_meta` collection name whose DEK encrypts the sidecar body. */\nconst FANOUT_DEK_COLLECTION = '_meta'\n\n/** Magic-prefixed JSON payload at `_meta/<recordId>`. */\nexport interface FanoutSidecar {\n readonly _noydb_fanout: 1\n /** Source collection name. */\n readonly source: string\n /** Source record id. */\n readonly sourceId: string\n /** Strategy output key (the key in `strategy.outputs`). */\n readonly outputKey: string\n /** Output collection name (audit / forensics). */\n readonly outputCollection: string\n /** Derived-row ids last emitted for this (source, output) pair. */\n readonly keys: ReadonlyArray<string>\n /** ISO timestamp of last dispatch. */\n readonly emittedAt: string\n}\n\n/**\n * Build the canonical `_meta` record id for a fanout sidecar.\n *\n * The full path inside the store is `_meta/<this-string>`. We pack the\n * full triple into the id so a single `_meta` collection holds all\n * sidecars (collection-per-source would proliferate names; the\n * existing `_meta` flat namespace is cheaper).\n */\nfunction recordId(source: string, sourceId: string, outputKey: string): string {\n // Use `/` as a separator. None of the components is supposed to\n // contain it (collection names + output keys are bare identifiers;\n // source ids are typically ULIDs / UUIDs / app-chosen strings\n // without slashes). If a future source carries `/` in its id, we'd\n // need an escape; deferred until that's a real case.\n return `derivations-fanout/${source}/${sourceId}/${outputKey}`\n}\n\n/**\n * Read the sidecar; returns `undefined` only when it's legitimately absent\n * (no envelope at that id) — the correct signal for callers to skip\n * orphan-row reconciliation because there's nothing to reconcile against.\n *\n * A PRESENT envelope that fails to decrypt or parse is a data-integrity\n * problem, not an absence, and is deliberately NOT caught here: swallowing\n * it to `undefined` would look identical to \"no sidecar\" and make callers\n * (the array-derivation dispatch in `vault.ts`/`collection.ts`) silently\n * skip deleting stale derived rows on a shrink. Let `openEnvelopeJson`'s\n * `DecryptionError`/`TamperedError` and `JSON.parse` failures propagate,\n * matching the no-catch convention of sibling decrypt call-sites (e.g.\n * `with-audit/consent/consent.ts`'s `decryptEntry`).\n *\n * Dual-reads for back-compat: an envelope with `_iv === ''` is a legacy\n * plaintext sidecar (parse `_data` directly); otherwise the body was\n * encrypted under the `_meta` DEK and is decrypted first.\n */\nexport async function loadFanoutSidecar(\n store: NoydbStore,\n vault: string,\n source: string,\n sourceId: string,\n outputKey: string,\n getDEK: GetDEK,\n encrypted: boolean,\n): Promise<FanoutSidecar | undefined> {\n const envelope = await store.get(vault, '_meta', recordId(source, sourceId, outputKey))\n if (!envelope) return undefined\n // Legacy plaintext (`_iv === ''`) reads directly; encrypted bodies decrypt.\n const json = (!encrypted || envelope._iv === '')\n ? envelope._data\n : await openEnvelopeJson(envelope, await getDEK(FANOUT_DEK_COLLECTION))\n const parsed = JSON.parse(json) as FanoutSidecar\n if (parsed._noydb_fanout !== 1) return undefined\n if (!Array.isArray(parsed.keys)) return undefined\n return parsed\n}\n\n/**\n * Persist (insert/replace) the sidecar with a fresh key set. The body is\n * encrypted under the `_meta` DEK when the vault is encrypted (the `keys[]`\n * can be content-bearing); plaintext only in debug/unencrypted vaults.\n */\nexport async function saveFanoutSidecar(\n store: NoydbStore,\n vault: string,\n payload: {\n readonly source: string\n readonly sourceId: string\n readonly outputKey: string\n readonly outputCollection: string\n readonly keys: ReadonlyArray<string>\n },\n getDEK: GetDEK,\n encrypted: boolean,\n): Promise<void> {\n const doc: FanoutSidecar = {\n _noydb_fanout: 1,\n source: payload.source,\n sourceId: payload.sourceId,\n outputKey: payload.outputKey,\n outputCollection: payload.outputCollection,\n keys: payload.keys,\n emittedAt: new Date().toISOString(),\n }\n const id = recordId(payload.source, payload.sourceId, payload.outputKey)\n const prior = await store.get(vault, '_meta', id)\n const json = JSON.stringify(doc)\n let envelope: EncryptedEnvelope\n if (!encrypted) {\n envelope = {\n _noydb: NOYDB_FORMAT_VERSION,\n _v: (prior?._v ?? 0) + 1,\n _ts: new Date().toISOString(),\n _iv: '',\n _data: json,\n }\n } else {\n const { iv, data } = await encrypt(json, await getDEK(FANOUT_DEK_COLLECTION))\n envelope = {\n _noydb: NOYDB_FORMAT_VERSION,\n _v: (prior?._v ?? 0) + 1,\n _ts: new Date().toISOString(),\n _iv: iv,\n _data: data,\n }\n }\n await store.put(vault, '_meta', id, envelope)\n}\n\n/** Delete the sidecar (used on source-row delete cascade). */\nexport async function deleteFanoutSidecar(\n store: NoydbStore,\n vault: string,\n source: string,\n sourceId: string,\n outputKey: string,\n): Promise<void> {\n await store.delete(vault, '_meta', recordId(source, sourceId, outputKey))\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AA6BA,IAAM,wBAAwB;AA2B9B,SAAS,SAAS,QAAgB,UAAkB,WAA2B;AAM7E,SAAO,sBAAsB,MAAM,IAAI,QAAQ,IAAI,SAAS;AAC9D;AAoBA,eAAsB,kBACpB,OACA,OACA,QACA,UACA,WACA,QACA,WACoC;AACpC,QAAM,WAAW,MAAM,MAAM,IAAI,OAAO,SAAS,SAAS,QAAQ,UAAU,SAAS,CAAC;AACtF,MAAI,CAAC,SAAU,QAAO;AAEtB,QAAM,OAAQ,CAAC,aAAa,SAAS,QAAQ,KACzC,SAAS,QACT,MAAM,iBAAiB,UAAU,MAAM,OAAO,qBAAqB,CAAC;AACxE,QAAM,SAAS,KAAK,MAAM,IAAI;AAC9B,MAAI,OAAO,kBAAkB,EAAG,QAAO;AACvC,MAAI,CAAC,MAAM,QAAQ,OAAO,IAAI,EAAG,QAAO;AACxC,SAAO;AACT;AAOA,eAAsB,kBACpB,OACA,OACA,SAOA,QACA,WACe;AACf,QAAM,MAAqB;AAAA,IACzB,eAAe;AAAA,IACf,QAAQ,QAAQ;AAAA,IAChB,UAAU,QAAQ;AAAA,IAClB,WAAW,QAAQ;AAAA,IACnB,kBAAkB,QAAQ;AAAA,IAC1B,MAAM,QAAQ;AAAA,IACd,YAAW,oBAAI,KAAK,GAAE,YAAY;AAAA,EACpC;AACA,QAAM,KAAK,SAAS,QAAQ,QAAQ,QAAQ,UAAU,QAAQ,SAAS;AACvE,QAAM,QAAQ,MAAM,MAAM,IAAI,OAAO,SAAS,EAAE;AAChD,QAAM,OAAO,KAAK,UAAU,GAAG;AAC/B,MAAI;AACJ,MAAI,CAAC,WAAW;AACd,eAAW;AAAA,MACT,QAAQ;AAAA,MACR,KAAK,OAAO,MAAM,KAAK;AAAA,MACvB,MAAK,oBAAI,KAAK,GAAE,YAAY;AAAA,MAC5B,KAAK;AAAA,MACL,OAAO;AAAA,IACT;AAAA,EACF,OAAO;AACL,UAAM,EAAE,IAAI,KAAK,IAAI,MAAM,QAAQ,MAAM,MAAM,OAAO,qBAAqB,CAAC;AAC5E,eAAW;AAAA,MACT,QAAQ;AAAA,MACR,KAAK,OAAO,MAAM,KAAK;AAAA,MACvB,MAAK,oBAAI,KAAK,GAAE,YAAY;AAAA,MAC5B,KAAK;AAAA,MACL,OAAO;AAAA,IACT;AAAA,EACF;AACA,QAAM,MAAM,IAAI,OAAO,SAAS,IAAI,QAAQ;AAC9C;AAGA,eAAsB,oBACpB,OACA,OACA,QACA,UACA,WACe;AACf,QAAM,MAAM,OAAO,OAAO,SAAS,SAAS,QAAQ,UAAU,SAAS,CAAC;AAC1E;","names":[]}
@@ -0,0 +1,69 @@
1
+ import "./chunk-PZ5AY32C.js";
2
+
3
+ // src/with-shape/schema-update/fence-watcher.ts
4
+ var FenceWatcher = class {
5
+ #coordination;
6
+ #vault;
7
+ #writerId;
8
+ #sessionId;
9
+ #onFlush;
10
+ #now;
11
+ #emit;
12
+ #lastState = null;
13
+ #quiescedAtVersion = null;
14
+ #timer;
15
+ constructor(opts) {
16
+ this.#coordination = opts.coordination;
17
+ this.#vault = opts.vault;
18
+ this.#writerId = opts.clientId;
19
+ this.#sessionId = opts.sessionId ?? opts.clientId;
20
+ this.#onFlush = opts.onFlush;
21
+ this.#now = opts.now ?? (() => Date.now());
22
+ this.#emit = opts.emit ?? (() => {
23
+ });
24
+ }
25
+ /** Publish liveness (and the current ack) without changing quiesce state. */
26
+ async beat() {
27
+ await this.#coordination.reportPresence(this.#vault, {
28
+ writerId: this.#writerId,
29
+ sessionId: this.#sessionId,
30
+ lastSeen: this.#now(),
31
+ quiescedAtVersion: this.#quiescedAtVersion
32
+ });
33
+ }
34
+ /** Poll the fence; quiesce on draining; emit on transitions. */
35
+ async check() {
36
+ const fence = await this.#coordination.readFence(this.#vault);
37
+ if (fence.fenceState !== this.#lastState) {
38
+ this.#lastState = fence.fenceState;
39
+ this.#emit({ currentSchemaVersion: fence.currentSchemaVersion, fenceState: fence.fenceState });
40
+ }
41
+ if (fence.fenceState === "draining" && this.#quiescedAtVersion !== fence.currentSchemaVersion) {
42
+ await this.#onFlush();
43
+ this.#quiescedAtVersion = fence.currentSchemaVersion;
44
+ await this.beat();
45
+ }
46
+ if (fence.fenceState === "normal") {
47
+ this.#quiescedAtVersion = null;
48
+ }
49
+ }
50
+ start(intervalMs) {
51
+ if (this.#timer) return;
52
+ this.#timer = setInterval(() => {
53
+ void this.beat();
54
+ void this.check();
55
+ }, intervalMs);
56
+ const timer = this.#timer;
57
+ if (typeof timer.unref === "function") timer.unref();
58
+ }
59
+ stop() {
60
+ if (this.#timer) {
61
+ clearInterval(this.#timer);
62
+ this.#timer = void 0;
63
+ }
64
+ }
65
+ };
66
+ export {
67
+ FenceWatcher
68
+ };
69
+ //# sourceMappingURL=fence-watcher-DHQ775JB.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/with-shape/schema-update/fence-watcher.ts"],"sourcesContent":["/**\n * Per-client schema-fence watcher. Watches the fence via the injected\n * {@link CoordinationProvider}; on `draining` it drains in-flight writes\n * and reports presence (its ack); emits a same-instance signal on every\n * state transition (for UI). Driven by an interval in production and by\n * explicit `check()`/`beat()` in tests.\n *\n * The transport is the coordination port: the default\n * {@link StoreCoordinationProvider} maps `reportPresence` →\n * `_meta/schema-fence:client:<id>` and `readFence` → `_meta/schema-fence`,\n * so behavior is byte-for-byte the same; `by-tabs` / `by-peer` swap in\n * real-time push transports.\n */\nimport { type FenceState } from './fence.js'\nimport type { CoordinationProvider } from '../../port/by/index.js'\n\nexport interface FenceWatcherEvent {\n readonly currentSchemaVersion: number\n readonly fenceState: FenceState\n}\n\nexport class FenceWatcher {\n readonly #coordination: CoordinationProvider\n readonly #vault: string\n readonly #writerId: string\n readonly #sessionId: string\n readonly #onFlush: () => Promise<void>\n readonly #now: () => number\n readonly #emit: (e: FenceWatcherEvent) => void\n #lastState: FenceState | null = null\n #quiescedAtVersion: number | null = null\n #timer: ReturnType<typeof setInterval> | undefined\n\n constructor(opts: {\n coordination: CoordinationProvider\n vault: string\n clientId: string\n sessionId?: string\n onFlush: () => Promise<void>\n now?: () => number\n emit?: (e: FenceWatcherEvent) => void\n }) {\n this.#coordination = opts.coordination\n this.#vault = opts.vault\n this.#writerId = opts.clientId\n this.#sessionId = opts.sessionId ?? opts.clientId\n this.#onFlush = opts.onFlush\n this.#now = opts.now ?? (() => Date.now())\n this.#emit = opts.emit ?? (() => {})\n }\n\n /** Publish liveness (and the current ack) without changing quiesce state. */\n async beat(): Promise<void> {\n await this.#coordination.reportPresence(this.#vault, {\n writerId: this.#writerId,\n sessionId: this.#sessionId,\n lastSeen: this.#now(),\n quiescedAtVersion: this.#quiescedAtVersion,\n })\n }\n\n /** Poll the fence; quiesce on draining; emit on transitions. */\n async check(): Promise<void> {\n const fence = await this.#coordination.readFence(this.#vault)\n if (fence.fenceState !== this.#lastState) {\n this.#lastState = fence.fenceState\n this.#emit({ currentSchemaVersion: fence.currentSchemaVersion, fenceState: fence.fenceState })\n }\n if (fence.fenceState === 'draining' && this.#quiescedAtVersion !== fence.currentSchemaVersion) {\n await this.#onFlush()\n this.#quiescedAtVersion = fence.currentSchemaVersion\n await this.beat()\n }\n if (fence.fenceState === 'normal') {\n this.#quiescedAtVersion = null\n }\n }\n\n start(intervalMs: number): void {\n if (this.#timer) return\n this.#timer = setInterval(() => { void this.beat(); void this.check() }, intervalMs)\n const timer = this.#timer as unknown as { unref?: () => void }\n if (typeof timer.unref === 'function') timer.unref() // don't keep the process alive\n }\n\n stop(): void {\n if (this.#timer) { clearInterval(this.#timer); this.#timer = undefined }\n }\n}\n"],"mappings":";;;AAqBO,IAAM,eAAN,MAAmB;AAAA,EACf;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACT,aAAgC;AAAA,EAChC,qBAAoC;AAAA,EACpC;AAAA,EAEA,YAAY,MAQT;AACD,SAAK,gBAAgB,KAAK;AAC1B,SAAK,SAAS,KAAK;AACnB,SAAK,YAAY,KAAK;AACtB,SAAK,aAAa,KAAK,aAAa,KAAK;AACzC,SAAK,WAAW,KAAK;AACrB,SAAK,OAAO,KAAK,QAAQ,MAAM,KAAK,IAAI;AACxC,SAAK,QAAQ,KAAK,SAAS,MAAM;AAAA,IAAC;AAAA,EACpC;AAAA;AAAA,EAGA,MAAM,OAAsB;AAC1B,UAAM,KAAK,cAAc,eAAe,KAAK,QAAQ;AAAA,MACnD,UAAU,KAAK;AAAA,MACf,WAAW,KAAK;AAAA,MAChB,UAAU,KAAK,KAAK;AAAA,MACpB,mBAAmB,KAAK;AAAA,IAC1B,CAAC;AAAA,EACH;AAAA;AAAA,EAGA,MAAM,QAAuB;AAC3B,UAAM,QAAQ,MAAM,KAAK,cAAc,UAAU,KAAK,MAAM;AAC5D,QAAI,MAAM,eAAe,KAAK,YAAY;AACxC,WAAK,aAAa,MAAM;AACxB,WAAK,MAAM,EAAE,sBAAsB,MAAM,sBAAsB,YAAY,MAAM,WAAW,CAAC;AAAA,IAC/F;AACA,QAAI,MAAM,eAAe,cAAc,KAAK,uBAAuB,MAAM,sBAAsB;AAC7F,YAAM,KAAK,SAAS;AACpB,WAAK,qBAAqB,MAAM;AAChC,YAAM,KAAK,KAAK;AAAA,IAClB;AACA,QAAI,MAAM,eAAe,UAAU;AACjC,WAAK,qBAAqB;AAAA,IAC5B;AAAA,EACF;AAAA,EAEA,MAAM,YAA0B;AAC9B,QAAI,KAAK,OAAQ;AACjB,SAAK,SAAS,YAAY,MAAM;AAAE,WAAK,KAAK,KAAK;AAAG,WAAK,KAAK,MAAM;AAAA,IAAE,GAAG,UAAU;AACnF,UAAM,QAAQ,KAAK;AACnB,QAAI,OAAO,MAAM,UAAU,WAAY,OAAM,MAAM;AAAA,EACrD;AAAA,EAEA,OAAa;AACX,QAAI,KAAK,QAAQ;AAAE,oBAAc,KAAK,MAAM;AAAG,WAAK,SAAS;AAAA,IAAU;AAAA,EACzE;AACF;","names":[]}