kassza 0.18.1 → 0.20.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (190) hide show
  1. package/README.md +1 -1
  2. package/dist/batch/index.cjs +5 -7
  3. package/dist/batch/index.d.cts +5 -9
  4. package/dist/batch/index.d.ts +5 -9
  5. package/dist/batch/index.js +5 -7
  6. package/dist/{binary-B89HM03_.cjs → binary-CdpKlNNI.cjs} +1 -2
  7. package/dist/{binary-D0M9U2MD.js → binary-DuKBSfH-.js} +1 -2
  8. package/dist/cli.cjs +14 -21
  9. package/dist/cli.js +14 -21
  10. package/dist/{client-DeWWQ-RZ.d.ts → client-B00WZ3FK.d.cts} +8 -36
  11. package/dist/{client-SVZu25MB.d.cts → client-BJfeFjCM.d.ts} +8 -36
  12. package/dist/{client-Cvb9yfxU.cjs → client-I_29IPMh.cjs} +25 -37
  13. package/dist/{client-CdWEA0et.js → client-JZ1M1sZX.js} +25 -37
  14. package/dist/{context-kb33TgzE.d.ts → context-BROX7Krw.d.ts} +7 -25
  15. package/dist/{context-CFNKzStE.d.cts → context-zGthvNo2.d.cts} +7 -25
  16. package/dist/cookie-stores/index.cjs +2 -2
  17. package/dist/cookie-stores/index.d.cts +3 -3
  18. package/dist/cookie-stores/index.d.ts +3 -3
  19. package/dist/cookie-stores/index.js +2 -2
  20. package/dist/{create-CflXrPip.js → create-BwRslos0.js} +9 -12
  21. package/dist/{create-CvUvLUaT.cjs → create-DH5jiZPA.cjs} +9 -12
  22. package/dist/{create-once-CW0x_yvp.js → create-once-B6cAXyET.js} +16 -22
  23. package/dist/{create-once-VKp0tVow.d.ts → create-once-BA0KAHIB.d.cts} +3 -7
  24. package/dist/{create-once-Bh6fOWkW.d.cts → create-once-CoybK69A.d.ts} +3 -7
  25. package/dist/{create-once-CHhDz0un.cjs → create-once-zeF7GVVP.cjs} +16 -22
  26. package/dist/{crypto-Dpn4FHQ6.cjs → crypto-B0PAHKJB.cjs} +1 -2
  27. package/dist/{crypto-usDg8L2K.js → crypto-BqGn_oGu.js} +1 -2
  28. package/dist/data-link/index.cjs +10 -13
  29. package/dist/data-link/index.d.cts +1 -5
  30. package/dist/data-link/index.d.ts +1 -5
  31. package/dist/data-link/index.js +10 -13
  32. package/dist/{dates-CXyj7Azy.js → dates-DWsZOdaO.js} +1 -2
  33. package/dist/{dates-9zvESP0i.d.cts → dates-nlGEokCf.d.cts} +0 -2
  34. package/dist/{dates-9zvESP0i.d.ts → dates-nlGEokCf.d.ts} +0 -2
  35. package/dist/{dates-CPgBodkP.cjs → dates-oOp3ypPP.cjs} +1 -2
  36. package/dist/delegation/index.cjs +9 -12
  37. package/dist/delegation/index.d.cts +3 -9
  38. package/dist/delegation/index.d.ts +3 -9
  39. package/dist/delegation/index.js +9 -12
  40. package/dist/{errors-EE96_6D_.cjs → errors-Bn6pe6yw.cjs} +12 -3
  41. package/dist/{errors-DtN4g5Z9.js → errors-CGGsW0Y5.js} +12 -3
  42. package/dist/{get-Byc9T5WO.d.cts → get-BL4Fr8-P.d.cts} +0 -2
  43. package/dist/{get-Byc9T5WO.d.ts → get-BL4Fr8-P.d.ts} +0 -2
  44. package/dist/{get-BdMTseh4.cjs → get-DFhT7kOp.cjs} +4 -5
  45. package/dist/{get-CZEShCcj.js → get-HrHwVkVt.js} +4 -5
  46. package/dist/{index-C-7yWV7L.d.cts → index-CinpAhQM.d.cts} +0 -8
  47. package/dist/{index-C-7yWV7L.d.ts → index-CinpAhQM.d.ts} +0 -8
  48. package/dist/{index-BqGgQ4t3.d.ts → index-DqoDUw6X.d.ts} +2 -20
  49. package/dist/{index-BhUPY_EH.d.cts → index-qk62lWr3.d.cts} +2 -20
  50. package/dist/index.cjs +7 -7
  51. package/dist/index.d.cts +11 -13
  52. package/dist/index.d.ts +11 -13
  53. package/dist/index.js +7 -7
  54. package/dist/ipn/index.cjs +4 -6
  55. package/dist/ipn/index.d.cts +0 -4
  56. package/dist/ipn/index.d.ts +0 -4
  57. package/dist/ipn/index.js +4 -6
  58. package/dist/{issue-Bin4tKD_.cjs → issue-DReARZnF.cjs} +12 -18
  59. package/dist/{issue-DMA1Nbr1.js → issue-Dy9zvRK1.js} +12 -18
  60. package/dist/journal/index.cjs +7 -11
  61. package/dist/journal/index.d.cts +2 -6
  62. package/dist/journal/index.d.ts +2 -6
  63. package/dist/journal/index.js +7 -11
  64. package/dist/{journal-DvI81Kt7.d.cts → journal-D_ypAW50.d.cts} +5 -9
  65. package/dist/{journal-Y9qrIB8G.d.ts → journal-JwiYpBui.d.ts} +5 -9
  66. package/dist/{json-4y4E2xxS.cjs → json-COC9rDwf.cjs} +1 -2
  67. package/dist/json-D3Bx7NhF.d.cts +2 -0
  68. package/dist/json-D3Bx7NhF.d.ts +2 -0
  69. package/dist/{json-DjnqnaJK.js → json-as-6J7d-.js} +1 -2
  70. package/dist/mcp/index.cjs +1 -1
  71. package/dist/mcp/index.d.cts +1 -9
  72. package/dist/mcp/index.d.ts +1 -9
  73. package/dist/mcp/index.js +1 -2
  74. package/dist/money/index.cjs +3 -3
  75. package/dist/money/index.d.cts +1 -1
  76. package/dist/money/index.d.ts +1 -1
  77. package/dist/money/index.js +3 -3
  78. package/dist/{money-K9j0wPit.cjs → money-NtVytaxG.cjs} +5 -7
  79. package/dist/{money-Cw457SD6.js → money-f280VT77.js} +5 -7
  80. package/dist/nav/index.cjs +15 -22
  81. package/dist/nav/index.d.cts +2 -22
  82. package/dist/nav/index.d.ts +2 -22
  83. package/dist/nav/index.js +15 -22
  84. package/dist/{nav-BcCerwWS.js → nav-NvNgaONz.js} +5 -7
  85. package/dist/{nav-BNbc8U0R.cjs → nav-VShZkjg8.cjs} +5 -7
  86. package/dist/node/index.cjs +1 -2
  87. package/dist/node/index.d.cts +1 -3
  88. package/dist/node/index.d.ts +1 -3
  89. package/dist/node/index.js +1 -2
  90. package/dist/observe/index.cjs +3 -5
  91. package/dist/observe/index.d.cts +1 -5
  92. package/dist/observe/index.d.ts +1 -5
  93. package/dist/observe/index.js +3 -5
  94. package/dist/{once-BN_3B5OF.cjs → once-BmXfrNbQ.cjs} +2 -3
  95. package/dist/{once-CqqZxsXG.js → once-CMhDPrs7.js} +2 -3
  96. package/dist/{parse-Cr7yQ3_z.js → parse-1RiSh4vY.js} +5 -7
  97. package/dist/{parse-DOA2XQ3e.cjs → parse-CmM5va-p.cjs} +5 -7
  98. package/dist/payments/barion.cjs +7 -6
  99. package/dist/payments/barion.d.cts +4 -6
  100. package/dist/payments/barion.d.ts +4 -6
  101. package/dist/payments/barion.js +7 -6
  102. package/dist/payments/index.cjs +2 -2
  103. package/dist/payments/index.d.cts +3 -9
  104. package/dist/payments/index.d.ts +3 -9
  105. package/dist/payments/index.js +2 -2
  106. package/dist/payments/paypal.cjs +8 -7
  107. package/dist/payments/paypal.d.cts +4 -6
  108. package/dist/payments/paypal.d.ts +4 -6
  109. package/dist/payments/paypal.js +8 -7
  110. package/dist/payments/revolut.cjs +7 -6
  111. package/dist/payments/revolut.d.cts +4 -6
  112. package/dist/payments/revolut.d.ts +4 -6
  113. package/dist/payments/revolut.js +7 -6
  114. package/dist/payments/simplepay.cjs +9 -8
  115. package/dist/payments/simplepay.d.cts +4 -6
  116. package/dist/payments/simplepay.d.ts +4 -6
  117. package/dist/payments/simplepay.js +9 -8
  118. package/dist/payments/stripe.cjs +6 -6
  119. package/dist/payments/stripe.d.cts +4 -6
  120. package/dist/payments/stripe.d.ts +4 -6
  121. package/dist/payments/stripe.js +6 -6
  122. package/dist/{push-BXj0Sf0Z.d.ts → push-CTxDD3yJ.d.cts} +2 -4
  123. package/dist/{push-D4nNbCNV.d.cts → push-DJh5YkyV.d.ts} +2 -4
  124. package/dist/{reference-B5TATqb5.js → reference-Cxz0m2zF.js} +6 -7
  125. package/dist/{reference-BIdYMK0t.cjs → reference-DoY12fc1.cjs} +6 -7
  126. package/dist/reports/index.cjs +3 -4
  127. package/dist/reports/index.d.cts +1 -7
  128. package/dist/reports/index.d.ts +1 -7
  129. package/dist/reports/index.js +3 -4
  130. package/dist/{request-body-uZHMRlQr.js → request-body-BM4sbsHd.js} +2 -3
  131. package/dist/{request-body-CH6ZGOrq.cjs → request-body-BhfkJhff.cjs} +2 -3
  132. package/dist/{rounding-TxoWy2ww.cjs → rounding-CHmSK5Z2.cjs} +1 -2
  133. package/dist/{rounding-BLyHjjI5.js → rounding-CZLj4DbV.js} +1 -2
  134. package/dist/{serialize-B2eFh3D-.js → serialize-CjymGkJj.js} +2 -4
  135. package/dist/{serialize-CquIsxA-.cjs → serialize-DEU7r6Bk.cjs} +2 -4
  136. package/dist/{server-xcEb7ko9.cjs → server-BKB4KsPn.cjs} +23 -35
  137. package/dist/{server-Dt6bEeBB.js → server-CPp6Gpbl.js} +23 -35
  138. package/dist/{session-Ckl5eJhV.d.ts → session-BBbSXlx3.d.cts} +1 -3
  139. package/dist/{session-DeM5vjvC.cjs → session-BYotpR_s.cjs} +2 -4
  140. package/dist/{session-SaEEXu2N.js → session-DZeE1ryt.js} +2 -4
  141. package/dist/{session-YbChChx7.d.cts → session-mKtpAeUB.d.ts} +1 -3
  142. package/dist/{shared-CrxlxI8n.cjs → shared-BOBTXDTo.cjs} +5 -6
  143. package/dist/{shared-D6DLa4b7.js → shared-Dbcfwr8x.js} +5 -6
  144. package/dist/storage/fs.cjs +3 -4
  145. package/dist/storage/fs.d.cts +2 -4
  146. package/dist/storage/fs.d.ts +2 -4
  147. package/dist/storage/fs.js +3 -4
  148. package/dist/storage/index.cjs +16 -25
  149. package/dist/storage/index.d.cts +2 -26
  150. package/dist/storage/index.d.ts +2 -26
  151. package/dist/storage/index.js +16 -25
  152. package/dist/{store-C1rHd9DB.d.cts → store-BkaZ8qkU.d.cts} +0 -2
  153. package/dist/{store-C1rHd9DB.d.ts → store-BkaZ8qkU.d.ts} +0 -2
  154. package/dist/stores/index.cjs +2 -2
  155. package/dist/stores/index.d.cts +3 -3
  156. package/dist/stores/index.d.ts +3 -3
  157. package/dist/stores/index.js +2 -2
  158. package/dist/{stores-DhjGBrl_.js → stores-BUnPNJQl.js} +12 -22
  159. package/dist/{stores-BNrS0dWl.cjs → stores-CH4rYKs_.cjs} +12 -22
  160. package/dist/{tax-number-BdqKsxNR.js → tax-number-C6jySuGR.js} +3 -6
  161. package/dist/{tax-number-BYFkBp4A.cjs → tax-number-XLdM5ETv.cjs} +3 -6
  162. package/dist/testing/index.cjs +20 -30
  163. package/dist/testing/index.d.cts +5 -15
  164. package/dist/testing/index.d.ts +5 -15
  165. package/dist/testing/index.js +20 -30
  166. package/dist/{types-DVRgwcqg.d.cts → types-Bfs08Mrc.d.cts} +0 -2
  167. package/dist/{types-DVRgwcqg.d.ts → types-Bfs08Mrc.d.ts} +0 -2
  168. package/dist/{types-ByAEvGsZ.d.ts → types-DeuUqIvU.d.cts} +2 -4
  169. package/dist/{types-D1zDOH_F.d.ts → types-Z6rQoqHn.d.ts} +1 -3
  170. package/dist/{types-lnKkQdot.d.cts → types-_HKTOCuQ.d.cts} +1 -3
  171. package/dist/{types-B1A8mUIE.d.cts → types-oiDulesz.d.ts} +2 -4
  172. package/dist/url-CRIlLxPE.cjs +23 -0
  173. package/dist/url-DeCMiKVm.js +12 -0
  174. package/dist/validators/index.cjs +6 -10
  175. package/dist/validators/index.d.cts +0 -12
  176. package/dist/validators/index.d.ts +0 -12
  177. package/dist/validators/index.js +6 -10
  178. package/dist/{vat-v_dcWCto.js → vat-B4J5Q0tu.js} +1 -2
  179. package/dist/{vat-g35srbNG.cjs → vat-BkoiiKm4.cjs} +1 -2
  180. package/dist/{warnings-DwTl5J-2.js → warnings-DJ0QvZOp.js} +1 -2
  181. package/dist/{warnings-B3DXnveC.d.cts → warnings-DpuYhn39.d.cts} +0 -4
  182. package/dist/{warnings-B3DXnveC.d.ts → warnings-DpuYhn39.d.ts} +0 -4
  183. package/dist/{warnings-DeIw5RFj.cjs → warnings-ciSzK6Jc.cjs} +1 -2
  184. package/dist/{webhook-Ckj-_hPD.cjs → webhook-BBTebz1x.cjs} +7 -11
  185. package/dist/{webhook-D6lEejob.d.ts → webhook-C9IBUdeT.d.ts} +1 -3
  186. package/dist/{webhook-CmdhGiH5.d.cts → webhook-DF2p_m2Q.d.cts} +1 -3
  187. package/dist/{webhook-CQVShAfI.js → webhook-SFlA_nCf.js} +7 -11
  188. package/package.json +1 -1
  189. package/dist/json-B70TwoX1.d.cts +0 -4
  190. package/dist/json-B70TwoX1.d.ts +0 -4
@@ -1,4 +1,5 @@
1
- //#region src/storage/errors.ts
1
+ const require_url = require("./url-CRIlLxPE.cjs");
2
+ // src/storage/errors.ts
2
3
  var StorageError = class extends Error {
3
4
  name = "StorageError";
4
5
  operation;
@@ -30,8 +31,7 @@ async function guardStorageCall(service, operation, key, call) {
30
31
  });
31
32
  }
32
33
  }
33
- //#endregion
34
- //#region src/storage/shared.ts
34
+ // src/storage/shared.ts
35
35
  const PDF_CONTENT_TYPE = "application/pdf";
36
36
  const DEFAULT_URL_EXPIRES_SECONDS = 3600;
37
37
  const S3_MAX_PRESIGN_SECONDS = 604800;
@@ -52,7 +52,7 @@ function assertStorageKey(key) {
52
52
  }
53
53
  function normalizePrefix(prefix) {
54
54
  if (!prefix) return "";
55
- const trimmed = prefix.replace(/^\/+|\/+$/g, "");
55
+ const trimmed = require_url.trimSlashes(prefix);
56
56
  if (trimmed === "") return "";
57
57
  assertStorageKey(trimmed);
58
58
  return `${trimmed}/`;
@@ -67,7 +67,7 @@ function encodeKeyPath(key) {
67
67
  return key.split("/").map(encodeRfc3986).join("/");
68
68
  }
69
69
  function joinPublicUrl(baseUrl, key) {
70
- return `${baseUrl.replace(/\/+$/, "")}/${encodeKeyPath(key)}`;
70
+ return `${require_url.trimTrailingSlashes(baseUrl)}/${encodeKeyPath(key)}`;
71
71
  }
72
72
  function assertExpires(expiresInSeconds, maximum, key) {
73
73
  if (!Number.isInteger(expiresInSeconds) || expiresInSeconds < 1 || expiresInSeconds > maximum) throw new StorageError(`Az expiresInSeconds 1 és ${maximum} közötti egész szám legyen, kapott: ${expiresInSeconds}`, {
@@ -96,7 +96,6 @@ function toArrayBuffer(bytes) {
96
96
  function basename(key) {
97
97
  return key.slice(key.lastIndexOf("/") + 1);
98
98
  }
99
- //#endregion
100
99
  Object.defineProperty(exports, "DEFAULT_URL_EXPIRES_SECONDS", {
101
100
  enumerable: true,
102
101
  get: function() {
@@ -1,4 +1,5 @@
1
- //#region src/storage/errors.ts
1
+ import { n as trimTrailingSlashes, t as trimSlashes } from "./url-DeCMiKVm.js";
2
+ // src/storage/errors.ts
2
3
  var StorageError = class extends Error {
3
4
  name = "StorageError";
4
5
  operation;
@@ -30,8 +31,7 @@ async function guardStorageCall(service, operation, key, call) {
30
31
  });
31
32
  }
32
33
  }
33
- //#endregion
34
- //#region src/storage/shared.ts
34
+ // src/storage/shared.ts
35
35
  const PDF_CONTENT_TYPE = "application/pdf";
36
36
  const DEFAULT_URL_EXPIRES_SECONDS = 3600;
37
37
  const S3_MAX_PRESIGN_SECONDS = 604800;
@@ -52,7 +52,7 @@ function assertStorageKey(key) {
52
52
  }
53
53
  function normalizePrefix(prefix) {
54
54
  if (!prefix) return "";
55
- const trimmed = prefix.replace(/^\/+|\/+$/g, "");
55
+ const trimmed = trimSlashes(prefix);
56
56
  if (trimmed === "") return "";
57
57
  assertStorageKey(trimmed);
58
58
  return `${trimmed}/`;
@@ -67,7 +67,7 @@ function encodeKeyPath(key) {
67
67
  return key.split("/").map(encodeRfc3986).join("/");
68
68
  }
69
69
  function joinPublicUrl(baseUrl, key) {
70
- return `${baseUrl.replace(/\/+$/, "")}/${encodeKeyPath(key)}`;
70
+ return `${trimTrailingSlashes(baseUrl)}/${encodeKeyPath(key)}`;
71
71
  }
72
72
  function assertExpires(expiresInSeconds, maximum, key) {
73
73
  if (!Number.isInteger(expiresInSeconds) || expiresInSeconds < 1 || expiresInSeconds > maximum) throw new StorageError(`Az expiresInSeconds 1 és ${maximum} közötti egész szám legyen, kapott: ${expiresInSeconds}`, {
@@ -96,5 +96,4 @@ function toArrayBuffer(bytes) {
96
96
  function basename(key) {
97
97
  return key.slice(key.lastIndexOf("/") + 1);
98
98
  }
99
- //#endregion
100
99
  export { guardStorageCall as _, assertStorageKey as a, encodeRfc3986 as c, normalizePrefix as d, resolveKey as f, describeError as g, StorageError as h, assertExpires as i, joinPublicUrl as l, unsupportedSignedUrl as m, PDF_CONTENT_TYPE as n, basename as o, toArrayBuffer as p, S3_MAX_PRESIGN_SECONDS as r, encodeKeyPath as s, DEFAULT_URL_EXPIRES_SECONDS as t, missingPublicBaseUrl as u, isStorageError as v };
@@ -1,9 +1,9 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_errors = require("../errors-EE96_6D_.cjs");
3
- const require_shared = require("../shared-CrxlxI8n.cjs");
2
+ const require_errors = require("../errors-Bn6pe6yw.cjs");
3
+ const require_shared = require("../shared-BOBTXDTo.cjs");
4
4
  let node_fs_promises = require("node:fs/promises");
5
5
  let node_path = require("node:path");
6
- //#region src/storage/fs.ts
6
+ // src/storage/fs.ts
7
7
  function isInside(root, target) {
8
8
  const path = (0, node_path.relative)(root, target);
9
9
  return path !== "" && !path.startsWith("..") && !(0, node_path.isAbsolute)(path);
@@ -84,5 +84,4 @@ function fsStorage(options) {
84
84
  }
85
85
  };
86
86
  }
87
- //#endregion
88
87
  exports.fsStorage = fsStorage;
@@ -1,5 +1,4 @@
1
- import { t as CompleteStorageAdapter } from "../types-DVRgwcqg.cjs";
2
- //#region src/storage/fs.d.ts
1
+ import { t as CompleteStorageAdapter } from "../types-Bfs08Mrc.cjs";
3
2
  export interface FsStorageOptions {
4
3
  readonly directory: string;
5
4
  readonly publicBaseUrl?: string | undefined;
@@ -9,5 +8,4 @@ export interface FsStorage extends CompleteStorageAdapter {
9
8
  readonly directory: string;
10
9
  pathFor(key: string): string;
11
10
  }
12
- export declare function fsStorage(options: FsStorageOptions): FsStorage;
13
- //#endregion
11
+ export declare function fsStorage(options: FsStorageOptions): FsStorage;
@@ -1,5 +1,4 @@
1
- import { t as CompleteStorageAdapter } from "../types-DVRgwcqg.js";
2
- //#region src/storage/fs.d.ts
1
+ import { t as CompleteStorageAdapter } from "../types-Bfs08Mrc.js";
3
2
  export interface FsStorageOptions {
4
3
  readonly directory: string;
5
4
  readonly publicBaseUrl?: string | undefined;
@@ -9,5 +8,4 @@ export interface FsStorage extends CompleteStorageAdapter {
9
8
  readonly directory: string;
10
9
  pathFor(key: string): string;
11
10
  }
12
- export declare function fsStorage(options: FsStorageOptions): FsStorage;
13
- //#endregion
11
+ export declare function fsStorage(options: FsStorageOptions): FsStorage;
@@ -1,8 +1,8 @@
1
- import { r as SzamlazzError } from "../errors-DtN4g5Z9.js";
2
- import { _ as guardStorageCall, d as normalizePrefix, f as resolveKey, h as StorageError, l as joinPublicUrl, m as unsupportedSignedUrl, u as missingPublicBaseUrl } from "../shared-D6DLa4b7.js";
1
+ import { r as SzamlazzError } from "../errors-CGGsW0Y5.js";
2
+ import { _ as guardStorageCall, d as normalizePrefix, f as resolveKey, h as StorageError, l as joinPublicUrl, m as unsupportedSignedUrl, u as missingPublicBaseUrl } from "../shared-Dbcfwr8x.js";
3
3
  import { mkdir, readFile, realpath, rename, rm, writeFile } from "node:fs/promises";
4
4
  import { dirname, isAbsolute, relative, resolve } from "node:path";
5
- //#region src/storage/fs.ts
5
+ // src/storage/fs.ts
6
6
  function isInside(root, target) {
7
7
  const path = relative(root, target);
8
8
  return path !== "" && !path.startsWith("..") && !isAbsolute(path);
@@ -83,5 +83,4 @@ function fsStorage(options) {
83
83
  }
84
84
  };
85
85
  }
86
- //#endregion
87
86
  export { fsStorage };
@@ -1,9 +1,10 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_errors = require("../errors-EE96_6D_.cjs");
3
- const require_binary = require("../binary-B89HM03_.cjs");
4
- const require_dates = require("../dates-CPgBodkP.cjs");
5
- const require_shared = require("../shared-CrxlxI8n.cjs");
6
- //#region src/storage/keys.ts
2
+ const require_errors = require("../errors-Bn6pe6yw.cjs");
3
+ const require_binary = require("../binary-CdpKlNNI.cjs");
4
+ const require_dates = require("../dates-oOp3ypPP.cjs");
5
+ const require_shared = require("../shared-BOBTXDTo.cjs");
6
+ const require_url = require("../url-CRIlLxPE.cjs");
7
+ // src/storage/keys.ts
7
8
  const DEFAULT_INVOICE_KEY_PREFIX = "szamlak";
8
9
  const DEFAULT_RECEIPT_KEY_PREFIX = "nyugtak";
9
10
  const KIND_FOLDERS = {
@@ -36,8 +37,7 @@ function invoicePdfKey(input) {
36
37
  function receiptPdfKey(input) {
37
38
  return datedPdfKey(input.prefix ?? "nyugtak", void 0, input.number, input.date);
38
39
  }
39
- //#endregion
40
- //#region src/storage/memory.ts
40
+ // src/storage/memory.ts
41
41
  const MEMORY_BASE_URL = "memory://storage";
42
42
  function memoryStorage(options = {}) {
43
43
  const prefix = require_shared.normalizePrefix(options.prefix);
@@ -78,8 +78,7 @@ function memoryStorage(options = {}) {
78
78
  }
79
79
  };
80
80
  }
81
- //#endregion
82
- //#region src/storage/r2-binding.ts
81
+ // src/storage/r2-binding.ts
83
82
  function r2BindingStorage(bucket, options = {}) {
84
83
  const prefix = require_shared.normalizePrefix(options.prefix);
85
84
  return {
@@ -115,8 +114,7 @@ function r2BindingStorage(bucket, options = {}) {
115
114
  }
116
115
  };
117
116
  }
118
- //#endregion
119
- //#region src/storage/s3.ts
117
+ // src/storage/s3.ts
120
118
  function statusOf(error) {
121
119
  const status = error?.$metadata?.httpStatusCode;
122
120
  return typeof status === "number" ? status : void 0;
@@ -212,8 +210,7 @@ function s3Storage(options) {
212
210
  }
213
211
  };
214
212
  }
215
- //#endregion
216
- //#region src/storage/sigv4.ts
213
+ // src/storage/sigv4.ts
217
214
  const AWS_SIGV4_ALGORITHM = "AWS4-HMAC-SHA256";
218
215
  const UNSIGNED_PAYLOAD = "UNSIGNED-PAYLOAD";
219
216
  const encoder = new TextEncoder();
@@ -322,8 +319,7 @@ async function presignAwsUrl(input) {
322
319
  const query = `${canonicalQuery(url.searchParams)}&X-Amz-Signature=${signature}`;
323
320
  return `${url.origin}${canonicalPath(url)}?${query}`;
324
321
  }
325
- //#endregion
326
- //#region src/storage/s3-fetch.ts
322
+ // src/storage/s3-fetch.ts
327
323
  function requireOption(value, name) {
328
324
  if (typeof value !== "string" || value.trim() === "") throw new require_errors.SzamlazzError(`Az s3FetchStorage ${name} opciója kötelező.`, { category: "configuration" });
329
325
  return value;
@@ -340,7 +336,7 @@ function bucketBaseUrl(options) {
340
336
  cause: error
341
337
  });
342
338
  }
343
- const basePath = endpoint.pathname.replace(/\/+$/, "");
339
+ const basePath = require_url.trimTrailingSlashes(endpoint.pathname);
344
340
  if (options.forcePathStyle ?? true) return `${endpoint.origin}${basePath}/${bucket}`;
345
341
  return `${endpoint.protocol}//${bucket}.${endpoint.host}${basePath}`;
346
342
  }
@@ -454,8 +450,7 @@ function s3FetchStorage(options) {
454
450
  }
455
451
  };
456
452
  }
457
- //#endregion
458
- //#region src/storage/store-pdf.ts
453
+ // src/storage/store-pdf.ts
459
454
  async function storePdf(storage, key, pdf) {
460
455
  if (!require_binary.isPdf(pdf)) throw new require_shared.StorageError("A tárolandó tartalom nem PDF (hiányzik a %PDF fejléc).", {
461
456
  operation: "put",
@@ -463,8 +458,7 @@ async function storePdf(storage, key, pdf) {
463
458
  });
464
459
  return storage.put(key, pdf, { contentType: require_shared.PDF_CONTENT_TYPE });
465
460
  }
466
- //#endregion
467
- //#region src/storage/supabase.ts
461
+ // src/storage/supabase.ts
468
462
  const SUPABASE_MAX_SIGNED_URL_SECONDS = 31536e3;
469
463
  function isNotFound(error) {
470
464
  return error.status === 404 || error.statusCode === "404" || /not[\s_-]?found/i.test(error.message);
@@ -523,8 +517,7 @@ function supabaseStorage(options) {
523
517
  }
524
518
  };
525
519
  }
526
- //#endregion
527
- //#region src/storage/uploadthing.ts
520
+ // src/storage/uploadthing.ts
528
521
  const UPLOADTHING_MAX_CUSTOM_ID_LENGTH = 128;
529
522
  const UPLOADTHING_MAX_SIGNED_URL_SECONDS = 604800;
530
523
  function uploadthingStorage(options) {
@@ -571,8 +564,7 @@ function uploadthingStorage(options) {
571
564
  }
572
565
  };
573
566
  }
574
- //#endregion
575
- //#region src/storage/vercel-blob.ts
567
+ // src/storage/vercel-blob.ts
576
568
  function missingFunction(name, key, operation) {
577
569
  return new require_shared.StorageError(`Ehhez a művelethez add át a @vercel/blob ${name} függvényét a vercelBlobStorage-nak.`, {
578
570
  operation,
@@ -616,7 +608,6 @@ function vercelBlobStorage(options) {
616
608
  }
617
609
  };
618
610
  }
619
- //#endregion
620
611
  exports.DEFAULT_INVOICE_KEY_PREFIX = DEFAULT_INVOICE_KEY_PREFIX;
621
612
  exports.DEFAULT_RECEIPT_KEY_PREFIX = DEFAULT_RECEIPT_KEY_PREFIX;
622
613
  exports.PDF_CONTENT_TYPE = require_shared.PDF_CONTENT_TYPE;
@@ -1,6 +1,5 @@
1
- import { t as DateInput } from "../dates-9zvESP0i.cjs";
2
- import { a as StoredFile, i as StorageUrlOptions, n as StorageAdapter, r as StoragePutOptions, t as CompleteStorageAdapter } from "../types-DVRgwcqg.cjs";
3
- //#region src/storage/errors.d.ts
1
+ import { t as DateInput } from "../dates-nlGEokCf.cjs";
2
+ import { a as StoredFile, i as StorageUrlOptions, n as StorageAdapter, r as StoragePutOptions, t as CompleteStorageAdapter } from "../types-Bfs08Mrc.cjs";
4
3
  type StorageOperation = "put" | "get" | "delete" | "getUrl" | "key";
5
4
  interface StorageErrorOptions {
6
5
  readonly operation: StorageOperation;
@@ -17,8 +16,6 @@ export declare class StorageError extends Error {
17
16
  }
18
17
  export declare function isStorageError(error: unknown): error is StorageError;
19
18
  export declare function guardStorageCall<T>(service: string, operation: StorageOperation, key: string, call: () => PromiseLike<T>): Promise<T>;
20
- //#endregion
21
- //#region src/storage/keys.d.ts
22
19
  type InvoiceDocumentKind = "invoice" | "proforma" | "advance" | "final" | "corrective" | "storno" | "deliveryNote";
23
20
  interface InvoicePdfKeyInput {
24
21
  readonly number: string;
@@ -36,8 +33,6 @@ export declare const DEFAULT_RECEIPT_KEY_PREFIX = "nyugtak";
36
33
  export declare function sanitizeKeySegment(value: string): string;
37
34
  export declare function invoicePdfKey(input: InvoicePdfKeyInput): string;
38
35
  export declare function receiptPdfKey(input: ReceiptPdfKeyInput): string;
39
- //#endregion
40
- //#region src/storage/memory.d.ts
41
36
  interface MemoryStoredObject {
42
37
  readonly body: Uint8Array;
43
38
  readonly contentType: string;
@@ -51,8 +46,6 @@ interface MemoryStorage extends CompleteStorageAdapter {
51
46
  clear(): void;
52
47
  }
53
48
  export declare function memoryStorage(options?: MemoryStorageOptions): MemoryStorage;
54
- //#endregion
55
- //#region src/storage/r2-binding.d.ts
56
49
  interface R2ObjectLike {
57
50
  readonly key: string;
58
51
  readonly size: number;
@@ -75,8 +68,6 @@ interface R2BindingStorageOptions {
75
68
  readonly prefix?: string | undefined;
76
69
  }
77
70
  export declare function r2BindingStorage(bucket: R2BucketLike, options?: R2BindingStorageOptions): CompleteStorageAdapter;
78
- //#endregion
79
- //#region src/storage/s3.d.ts
80
71
  type S3CommandLike = object;
81
72
  interface S3ClientLike {
82
73
  send(command: S3CommandLike): Promise<unknown>;
@@ -111,8 +102,6 @@ interface S3StorageOptions {
111
102
  readonly getSignedUrl?: S3GetSignedUrl | undefined;
112
103
  }
113
104
  export declare function s3Storage(options: S3StorageOptions): CompleteStorageAdapter;
114
- //#endregion
115
- //#region src/storage/s3-fetch.d.ts
116
105
  interface S3FetchStorageOptions {
117
106
  readonly bucket: string;
118
107
  readonly region: string;
@@ -126,13 +115,9 @@ interface S3FetchStorageOptions {
126
115
  readonly fetch?: typeof globalThis.fetch | undefined;
127
116
  }
128
117
  export declare function s3FetchStorage(options: S3FetchStorageOptions): CompleteStorageAdapter;
129
- //#endregion
130
- //#region src/storage/shared.d.ts
131
118
  export declare const PDF_CONTENT_TYPE = "application/pdf";
132
119
  export declare const S3_MAX_PRESIGN_SECONDS = 604800;
133
120
  export declare function assertStorageKey(key: string): string;
134
- //#endregion
135
- //#region src/storage/sigv4.d.ts
136
121
  interface AwsCredentials {
137
122
  readonly accessKeyId: string;
138
123
  readonly secretAccessKey: string;
@@ -158,11 +143,7 @@ interface PresignAwsUrlInput extends AwsSigningScope {
158
143
  }
159
144
  export declare function signAwsRequest(input: SignAwsRequestInput): Promise<Record<string, string>>;
160
145
  export declare function presignAwsUrl(input: PresignAwsUrlInput): Promise<string>;
161
- //#endregion
162
- //#region src/storage/store-pdf.d.ts
163
146
  export declare function storePdf(storage: StorageAdapter, key: string, pdf: Uint8Array): Promise<StoredFile>;
164
- //#endregion
165
- //#region src/storage/supabase.d.ts
166
147
  export declare const SUPABASE_MAX_SIGNED_URL_SECONDS = 31536e3;
167
148
  interface SupabaseStorageErrorLike {
168
149
  readonly message: string;
@@ -207,8 +188,6 @@ interface SupabaseStorageOptions {
207
188
  readonly prefix?: string | undefined;
208
189
  }
209
190
  export declare function supabaseStorage(options: SupabaseStorageOptions): CompleteStorageAdapter;
210
- //#endregion
211
- //#region src/storage/uploadthing.d.ts
212
191
  export declare const UPLOADTHING_MAX_CUSTOM_ID_LENGTH = 128;
213
192
  export declare const UPLOADTHING_MAX_SIGNED_URL_SECONDS = 604800;
214
193
  type UploadThingAcl = "public-read" | "private";
@@ -250,8 +229,6 @@ interface UploadThingStorageOptions {
250
229
  readonly prefix?: string | undefined;
251
230
  }
252
231
  export declare function uploadthingStorage(options: UploadThingStorageOptions): StorageAdapter;
253
- //#endregion
254
- //#region src/storage/vercel-blob.d.ts
255
232
  type VercelBlobAccess = "public" | "private";
256
233
  interface VercelBlobPutOptions {
257
234
  readonly access: VercelBlobAccess;
@@ -284,5 +261,4 @@ interface VercelBlobStorageOptions extends VercelBlobFunctions {
284
261
  readonly cacheControlMaxAge?: number | undefined;
285
262
  }
286
263
  export declare function vercelBlobStorage(options: VercelBlobStorageOptions): StorageAdapter;
287
- //#endregion
288
264
  export type { AwsCredentials, CompleteStorageAdapter, InvoiceDocumentKind, InvoicePdfKeyInput, MemoryStorage, MemoryStorageOptions, MemoryStoredObject, PresignAwsUrlInput, R2BindingStorageOptions, R2BucketLike, R2ObjectBodyLike, R2ObjectLike, R2PutOptionsLike, ReceiptPdfKeyInput, S3ClientLike, S3CommandLike, S3Commands, S3FetchStorageOptions, S3GetSignedUrl, S3ObjectInput, S3PresignOptions, S3PutObjectInput, S3StorageOptions, SignAwsRequestInput, StorageAdapter, StorageErrorOptions, StorageOperation, StoragePutOptions, StorageUrlOptions, StoredFile, SupabaseBucketApiLike, SupabaseClientLike, SupabaseResultLike, SupabaseStorageErrorLike, SupabaseStorageOptions, SupabaseUploadOptions, UploadThingAcl, UploadThingApiLike, UploadThingFileLike, UploadThingStorageOptions, UploadThingUploadOptions, UploadThingUploadResult, UploadThingUploadedFile, VercelBlobAccess, VercelBlobCommandOptions, VercelBlobFunctions, VercelBlobHeadResult, VercelBlobPutOptions, VercelBlobPutResult, VercelBlobStorageOptions };
@@ -1,6 +1,5 @@
1
- import { t as DateInput } from "../dates-9zvESP0i.js";
2
- import { a as StoredFile, i as StorageUrlOptions, n as StorageAdapter, r as StoragePutOptions, t as CompleteStorageAdapter } from "../types-DVRgwcqg.js";
3
- //#region src/storage/errors.d.ts
1
+ import { t as DateInput } from "../dates-nlGEokCf.js";
2
+ import { a as StoredFile, i as StorageUrlOptions, n as StorageAdapter, r as StoragePutOptions, t as CompleteStorageAdapter } from "../types-Bfs08Mrc.js";
4
3
  type StorageOperation = "put" | "get" | "delete" | "getUrl" | "key";
5
4
  interface StorageErrorOptions {
6
5
  readonly operation: StorageOperation;
@@ -17,8 +16,6 @@ export declare class StorageError extends Error {
17
16
  }
18
17
  export declare function isStorageError(error: unknown): error is StorageError;
19
18
  export declare function guardStorageCall<T>(service: string, operation: StorageOperation, key: string, call: () => PromiseLike<T>): Promise<T>;
20
- //#endregion
21
- //#region src/storage/keys.d.ts
22
19
  type InvoiceDocumentKind = "invoice" | "proforma" | "advance" | "final" | "corrective" | "storno" | "deliveryNote";
23
20
  interface InvoicePdfKeyInput {
24
21
  readonly number: string;
@@ -36,8 +33,6 @@ export declare const DEFAULT_RECEIPT_KEY_PREFIX = "nyugtak";
36
33
  export declare function sanitizeKeySegment(value: string): string;
37
34
  export declare function invoicePdfKey(input: InvoicePdfKeyInput): string;
38
35
  export declare function receiptPdfKey(input: ReceiptPdfKeyInput): string;
39
- //#endregion
40
- //#region src/storage/memory.d.ts
41
36
  interface MemoryStoredObject {
42
37
  readonly body: Uint8Array;
43
38
  readonly contentType: string;
@@ -51,8 +46,6 @@ interface MemoryStorage extends CompleteStorageAdapter {
51
46
  clear(): void;
52
47
  }
53
48
  export declare function memoryStorage(options?: MemoryStorageOptions): MemoryStorage;
54
- //#endregion
55
- //#region src/storage/r2-binding.d.ts
56
49
  interface R2ObjectLike {
57
50
  readonly key: string;
58
51
  readonly size: number;
@@ -75,8 +68,6 @@ interface R2BindingStorageOptions {
75
68
  readonly prefix?: string | undefined;
76
69
  }
77
70
  export declare function r2BindingStorage(bucket: R2BucketLike, options?: R2BindingStorageOptions): CompleteStorageAdapter;
78
- //#endregion
79
- //#region src/storage/s3.d.ts
80
71
  type S3CommandLike = object;
81
72
  interface S3ClientLike {
82
73
  send(command: S3CommandLike): Promise<unknown>;
@@ -111,8 +102,6 @@ interface S3StorageOptions {
111
102
  readonly getSignedUrl?: S3GetSignedUrl | undefined;
112
103
  }
113
104
  export declare function s3Storage(options: S3StorageOptions): CompleteStorageAdapter;
114
- //#endregion
115
- //#region src/storage/s3-fetch.d.ts
116
105
  interface S3FetchStorageOptions {
117
106
  readonly bucket: string;
118
107
  readonly region: string;
@@ -126,13 +115,9 @@ interface S3FetchStorageOptions {
126
115
  readonly fetch?: typeof globalThis.fetch | undefined;
127
116
  }
128
117
  export declare function s3FetchStorage(options: S3FetchStorageOptions): CompleteStorageAdapter;
129
- //#endregion
130
- //#region src/storage/shared.d.ts
131
118
  export declare const PDF_CONTENT_TYPE = "application/pdf";
132
119
  export declare const S3_MAX_PRESIGN_SECONDS = 604800;
133
120
  export declare function assertStorageKey(key: string): string;
134
- //#endregion
135
- //#region src/storage/sigv4.d.ts
136
121
  interface AwsCredentials {
137
122
  readonly accessKeyId: string;
138
123
  readonly secretAccessKey: string;
@@ -158,11 +143,7 @@ interface PresignAwsUrlInput extends AwsSigningScope {
158
143
  }
159
144
  export declare function signAwsRequest(input: SignAwsRequestInput): Promise<Record<string, string>>;
160
145
  export declare function presignAwsUrl(input: PresignAwsUrlInput): Promise<string>;
161
- //#endregion
162
- //#region src/storage/store-pdf.d.ts
163
146
  export declare function storePdf(storage: StorageAdapter, key: string, pdf: Uint8Array): Promise<StoredFile>;
164
- //#endregion
165
- //#region src/storage/supabase.d.ts
166
147
  export declare const SUPABASE_MAX_SIGNED_URL_SECONDS = 31536e3;
167
148
  interface SupabaseStorageErrorLike {
168
149
  readonly message: string;
@@ -207,8 +188,6 @@ interface SupabaseStorageOptions {
207
188
  readonly prefix?: string | undefined;
208
189
  }
209
190
  export declare function supabaseStorage(options: SupabaseStorageOptions): CompleteStorageAdapter;
210
- //#endregion
211
- //#region src/storage/uploadthing.d.ts
212
191
  export declare const UPLOADTHING_MAX_CUSTOM_ID_LENGTH = 128;
213
192
  export declare const UPLOADTHING_MAX_SIGNED_URL_SECONDS = 604800;
214
193
  type UploadThingAcl = "public-read" | "private";
@@ -250,8 +229,6 @@ interface UploadThingStorageOptions {
250
229
  readonly prefix?: string | undefined;
251
230
  }
252
231
  export declare function uploadthingStorage(options: UploadThingStorageOptions): StorageAdapter;
253
- //#endregion
254
- //#region src/storage/vercel-blob.d.ts
255
232
  type VercelBlobAccess = "public" | "private";
256
233
  interface VercelBlobPutOptions {
257
234
  readonly access: VercelBlobAccess;
@@ -284,5 +261,4 @@ interface VercelBlobStorageOptions extends VercelBlobFunctions {
284
261
  readonly cacheControlMaxAge?: number | undefined;
285
262
  }
286
263
  export declare function vercelBlobStorage(options: VercelBlobStorageOptions): StorageAdapter;
287
- //#endregion
288
264
  export type { AwsCredentials, CompleteStorageAdapter, InvoiceDocumentKind, InvoicePdfKeyInput, MemoryStorage, MemoryStorageOptions, MemoryStoredObject, PresignAwsUrlInput, R2BindingStorageOptions, R2BucketLike, R2ObjectBodyLike, R2ObjectLike, R2PutOptionsLike, ReceiptPdfKeyInput, S3ClientLike, S3CommandLike, S3Commands, S3FetchStorageOptions, S3GetSignedUrl, S3ObjectInput, S3PresignOptions, S3PutObjectInput, S3StorageOptions, SignAwsRequestInput, StorageAdapter, StorageErrorOptions, StorageOperation, StoragePutOptions, StorageUrlOptions, StoredFile, SupabaseBucketApiLike, SupabaseClientLike, SupabaseResultLike, SupabaseStorageErrorLike, SupabaseStorageOptions, SupabaseUploadOptions, UploadThingAcl, UploadThingApiLike, UploadThingFileLike, UploadThingStorageOptions, UploadThingUploadOptions, UploadThingUploadResult, UploadThingUploadedFile, VercelBlobAccess, VercelBlobCommandOptions, VercelBlobFunctions, VercelBlobHeadResult, VercelBlobPutOptions, VercelBlobPutResult, VercelBlobStorageOptions };
@@ -1,8 +1,9 @@
1
- import { r as SzamlazzError } from "../errors-DtN4g5Z9.js";
2
- import { a as isPdf } from "../binary-D0M9U2MD.js";
3
- import { a as todayInBudapest, n as toAgentDate } from "../dates-CXyj7Azy.js";
4
- import { _ as guardStorageCall, a as assertStorageKey, c as encodeRfc3986, d as normalizePrefix, f as resolveKey, g as describeError, h as StorageError, i as assertExpires, l as joinPublicUrl, m as unsupportedSignedUrl, n as PDF_CONTENT_TYPE, o as basename, p as toArrayBuffer, r as S3_MAX_PRESIGN_SECONDS, s as encodeKeyPath, u as missingPublicBaseUrl, v as isStorageError } from "../shared-D6DLa4b7.js";
5
- //#region src/storage/keys.ts
1
+ import { r as SzamlazzError } from "../errors-CGGsW0Y5.js";
2
+ import { a as isPdf } from "../binary-DuKBSfH-.js";
3
+ import { a as todayInBudapest, n as toAgentDate } from "../dates-DWsZOdaO.js";
4
+ import { _ as guardStorageCall, a as assertStorageKey, c as encodeRfc3986, d as normalizePrefix, f as resolveKey, g as describeError, h as StorageError, i as assertExpires, l as joinPublicUrl, m as unsupportedSignedUrl, n as PDF_CONTENT_TYPE, o as basename, p as toArrayBuffer, r as S3_MAX_PRESIGN_SECONDS, s as encodeKeyPath, u as missingPublicBaseUrl, v as isStorageError } from "../shared-Dbcfwr8x.js";
5
+ import { n as trimTrailingSlashes } from "../url-DeCMiKVm.js";
6
+ // src/storage/keys.ts
6
7
  const DEFAULT_INVOICE_KEY_PREFIX = "szamlak";
7
8
  const DEFAULT_RECEIPT_KEY_PREFIX = "nyugtak";
8
9
  const KIND_FOLDERS = {
@@ -35,8 +36,7 @@ function invoicePdfKey(input) {
35
36
  function receiptPdfKey(input) {
36
37
  return datedPdfKey(input.prefix ?? "nyugtak", void 0, input.number, input.date);
37
38
  }
38
- //#endregion
39
- //#region src/storage/memory.ts
39
+ // src/storage/memory.ts
40
40
  const MEMORY_BASE_URL = "memory://storage";
41
41
  function memoryStorage(options = {}) {
42
42
  const prefix = normalizePrefix(options.prefix);
@@ -77,8 +77,7 @@ function memoryStorage(options = {}) {
77
77
  }
78
78
  };
79
79
  }
80
- //#endregion
81
- //#region src/storage/r2-binding.ts
80
+ // src/storage/r2-binding.ts
82
81
  function r2BindingStorage(bucket, options = {}) {
83
82
  const prefix = normalizePrefix(options.prefix);
84
83
  return {
@@ -114,8 +113,7 @@ function r2BindingStorage(bucket, options = {}) {
114
113
  }
115
114
  };
116
115
  }
117
- //#endregion
118
- //#region src/storage/s3.ts
116
+ // src/storage/s3.ts
119
117
  function statusOf(error) {
120
118
  const status = error?.$metadata?.httpStatusCode;
121
119
  return typeof status === "number" ? status : void 0;
@@ -211,8 +209,7 @@ function s3Storage(options) {
211
209
  }
212
210
  };
213
211
  }
214
- //#endregion
215
- //#region src/storage/sigv4.ts
212
+ // src/storage/sigv4.ts
216
213
  const AWS_SIGV4_ALGORITHM = "AWS4-HMAC-SHA256";
217
214
  const UNSIGNED_PAYLOAD = "UNSIGNED-PAYLOAD";
218
215
  const encoder = new TextEncoder();
@@ -321,8 +318,7 @@ async function presignAwsUrl(input) {
321
318
  const query = `${canonicalQuery(url.searchParams)}&X-Amz-Signature=${signature}`;
322
319
  return `${url.origin}${canonicalPath(url)}?${query}`;
323
320
  }
324
- //#endregion
325
- //#region src/storage/s3-fetch.ts
321
+ // src/storage/s3-fetch.ts
326
322
  function requireOption(value, name) {
327
323
  if (typeof value !== "string" || value.trim() === "") throw new SzamlazzError(`Az s3FetchStorage ${name} opciója kötelező.`, { category: "configuration" });
328
324
  return value;
@@ -339,7 +335,7 @@ function bucketBaseUrl(options) {
339
335
  cause: error
340
336
  });
341
337
  }
342
- const basePath = endpoint.pathname.replace(/\/+$/, "");
338
+ const basePath = trimTrailingSlashes(endpoint.pathname);
343
339
  if (options.forcePathStyle ?? true) return `${endpoint.origin}${basePath}/${bucket}`;
344
340
  return `${endpoint.protocol}//${bucket}.${endpoint.host}${basePath}`;
345
341
  }
@@ -453,8 +449,7 @@ function s3FetchStorage(options) {
453
449
  }
454
450
  };
455
451
  }
456
- //#endregion
457
- //#region src/storage/store-pdf.ts
452
+ // src/storage/store-pdf.ts
458
453
  async function storePdf(storage, key, pdf) {
459
454
  if (!isPdf(pdf)) throw new StorageError("A tárolandó tartalom nem PDF (hiányzik a %PDF fejléc).", {
460
455
  operation: "put",
@@ -462,8 +457,7 @@ async function storePdf(storage, key, pdf) {
462
457
  });
463
458
  return storage.put(key, pdf, { contentType: PDF_CONTENT_TYPE });
464
459
  }
465
- //#endregion
466
- //#region src/storage/supabase.ts
460
+ // src/storage/supabase.ts
467
461
  const SUPABASE_MAX_SIGNED_URL_SECONDS = 31536e3;
468
462
  function isNotFound(error) {
469
463
  return error.status === 404 || error.statusCode === "404" || /not[\s_-]?found/i.test(error.message);
@@ -522,8 +516,7 @@ function supabaseStorage(options) {
522
516
  }
523
517
  };
524
518
  }
525
- //#endregion
526
- //#region src/storage/uploadthing.ts
519
+ // src/storage/uploadthing.ts
527
520
  const UPLOADTHING_MAX_CUSTOM_ID_LENGTH = 128;
528
521
  const UPLOADTHING_MAX_SIGNED_URL_SECONDS = 604800;
529
522
  function uploadthingStorage(options) {
@@ -570,8 +563,7 @@ function uploadthingStorage(options) {
570
563
  }
571
564
  };
572
565
  }
573
- //#endregion
574
- //#region src/storage/vercel-blob.ts
566
+ // src/storage/vercel-blob.ts
575
567
  function missingFunction(name, key, operation) {
576
568
  return new StorageError(`Ehhez a művelethez add át a @vercel/blob ${name} függvényét a vercelBlobStorage-nak.`, {
577
569
  operation,
@@ -615,5 +607,4 @@ function vercelBlobStorage(options) {
615
607
  }
616
608
  };
617
609
  }
618
- //#endregion
619
610
  export { DEFAULT_INVOICE_KEY_PREFIX, DEFAULT_RECEIPT_KEY_PREFIX, PDF_CONTENT_TYPE, S3_MAX_PRESIGN_SECONDS, SUPABASE_MAX_SIGNED_URL_SECONDS, StorageError, UPLOADTHING_MAX_CUSTOM_ID_LENGTH, UPLOADTHING_MAX_SIGNED_URL_SECONDS, assertStorageKey, guardStorageCall, invoicePdfKey, isStorageError, memoryStorage, presignAwsUrl, r2BindingStorage, receiptPdfKey, s3FetchStorage, s3Storage, sanitizeKeySegment, signAwsRequest, storePdf, supabaseStorage, uploadthingStorage, vercelBlobStorage };
@@ -1,4 +1,3 @@
1
- //#region src/core/store.d.ts
2
1
  type Awaitable<T> = T | Promise<T>;
3
2
  interface KeyValueStore {
4
3
  get(key: string): Awaitable<string | undefined | null>;
@@ -15,5 +14,4 @@ interface StoreCapabilities {
15
14
  }
16
15
  declare function storeCapabilities(store: KeyValueStore): StoreCapabilities;
17
16
  declare function memoryStore(): KeyValueStore;
18
- //#endregion
19
17
  export { storeCapabilities as a, memoryStore as i, KeyValueStore as n, StoreCapabilities as r, Awaitable as t };
@@ -1,4 +1,3 @@
1
- //#region src/core/store.d.ts
2
1
  type Awaitable<T> = T | Promise<T>;
3
2
  interface KeyValueStore {
4
3
  get(key: string): Awaitable<string | undefined | null>;
@@ -15,5 +14,4 @@ interface StoreCapabilities {
15
14
  }
16
15
  declare function storeCapabilities(store: KeyValueStore): StoreCapabilities;
17
16
  declare function memoryStore(): KeyValueStore;
18
- //#endregion
19
17
  export { storeCapabilities as a, memoryStore as i, KeyValueStore as n, StoreCapabilities as r, Awaitable as t };
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_session = require("../session-DeM5vjvC.cjs");
3
- const require_stores = require("../stores-BNrS0dWl.cjs");
2
+ const require_session = require("../session-BYotpR_s.cjs");
3
+ const require_stores = require("../stores-CH4rYKs_.cjs");
4
4
  exports.CLOUDFLARE_KV_MIN_TTL_SECONDS = require_stores.CLOUDFLARE_KV_MIN_TTL_SECONDS;
5
5
  exports.DURABLE_OBJECT_STORE_URL = require_stores.DURABLE_OBJECT_STORE_URL;
6
6
  exports.SESSION_TTL_SECONDS = require_session.SESSION_TTL_SECONDS;
@@ -1,4 +1,4 @@
1
- import { a as storeCapabilities, i as memoryStore, n as KeyValueStore, r as StoreCapabilities, t as Awaitable } from "../store-C1rHd9DB.cjs";
2
- import { n as SESSION_TTL_SECONDS, r as memoryCookieStore, t as CookieStore } from "../session-YbChChx7.cjs";
3
- import { C as CookieStoreErrorEvent, E as resilientCookieStore, S as CookieStoreAdapterOptions, T as ResilientCookieStoreOptions, _ as ioredisCookieStore, a as DurableObjectStubLike, b as CloudflareKvNamespaceLike, c as DiagnoseStoreOptions, d as diagnoseStore, f as UpstashRedisLike, g as IoRedisLike, h as nodeRedisCookieStore, i as DurableObjectStoreOperation, l as StoreDiagnosis, m as NodeRedisLike, n as DurableObjectStorageLike, o as durableObjectStore, p as upstashRedisCookieStore, r as DurableObjectStoreEntry, s as handleDurableObjectStoreRequest, t as DURABLE_OBJECT_STORE_URL, u as StoreSuitability, v as customCookieStore, w as CookieStoreOperation, x as cloudflareKvCookieStore, y as CLOUDFLARE_KV_MIN_TTL_SECONDS } from "../index-BhUPY_EH.cjs";
1
+ import { a as storeCapabilities, i as memoryStore, n as KeyValueStore, r as StoreCapabilities, t as Awaitable } from "../store-BkaZ8qkU.cjs";
2
+ import { n as SESSION_TTL_SECONDS, r as memoryCookieStore, t as CookieStore } from "../session-BBbSXlx3.cjs";
3
+ import { C as CookieStoreErrorEvent, E as resilientCookieStore, S as CookieStoreAdapterOptions, T as ResilientCookieStoreOptions, _ as ioredisCookieStore, a as DurableObjectStubLike, b as CloudflareKvNamespaceLike, c as DiagnoseStoreOptions, d as diagnoseStore, f as UpstashRedisLike, g as IoRedisLike, h as nodeRedisCookieStore, i as DurableObjectStoreOperation, l as StoreDiagnosis, m as NodeRedisLike, n as DurableObjectStorageLike, o as durableObjectStore, p as upstashRedisCookieStore, r as DurableObjectStoreEntry, s as handleDurableObjectStoreRequest, t as DURABLE_OBJECT_STORE_URL, u as StoreSuitability, v as customCookieStore, w as CookieStoreOperation, x as cloudflareKvCookieStore, y as CLOUDFLARE_KV_MIN_TTL_SECONDS } from "../index-qk62lWr3.cjs";
4
4
  export { type Awaitable, CLOUDFLARE_KV_MIN_TTL_SECONDS, type CloudflareKvNamespaceLike, type CookieStore, type CookieStoreAdapterOptions, type CookieStoreErrorEvent, type CookieStoreOperation, DURABLE_OBJECT_STORE_URL, type DiagnoseStoreOptions, type DurableObjectStorageLike, type DurableObjectStoreEntry, type DurableObjectStoreOperation, type DurableObjectStubLike, type IoRedisLike, type KeyValueStore, type NodeRedisLike, type ResilientCookieStoreOptions, SESSION_TTL_SECONDS, type StoreCapabilities, type StoreDiagnosis, type StoreSuitability, type UpstashRedisLike, cloudflareKvCookieStore, cloudflareKvCookieStore as cloudflareKvStore, customCookieStore, customCookieStore as customStore, diagnoseStore, durableObjectStore, handleDurableObjectStoreRequest, ioredisCookieStore, ioredisCookieStore as ioredisStore, memoryCookieStore, memoryStore, nodeRedisCookieStore, nodeRedisCookieStore as nodeRedisStore, resilientCookieStore, resilientCookieStore as resilientStore, storeCapabilities, upstashRedisCookieStore, upstashRedisCookieStore as upstashRedisStore };
@@ -1,4 +1,4 @@
1
- import { a as storeCapabilities, i as memoryStore, n as KeyValueStore, r as StoreCapabilities, t as Awaitable } from "../store-C1rHd9DB.js";
2
- import { n as SESSION_TTL_SECONDS, r as memoryCookieStore, t as CookieStore } from "../session-Ckl5eJhV.js";
3
- import { C as CookieStoreErrorEvent, E as resilientCookieStore, S as CookieStoreAdapterOptions, T as ResilientCookieStoreOptions, _ as ioredisCookieStore, a as DurableObjectStubLike, b as CloudflareKvNamespaceLike, c as DiagnoseStoreOptions, d as diagnoseStore, f as UpstashRedisLike, g as IoRedisLike, h as nodeRedisCookieStore, i as DurableObjectStoreOperation, l as StoreDiagnosis, m as NodeRedisLike, n as DurableObjectStorageLike, o as durableObjectStore, p as upstashRedisCookieStore, r as DurableObjectStoreEntry, s as handleDurableObjectStoreRequest, t as DURABLE_OBJECT_STORE_URL, u as StoreSuitability, v as customCookieStore, w as CookieStoreOperation, x as cloudflareKvCookieStore, y as CLOUDFLARE_KV_MIN_TTL_SECONDS } from "../index-BqGgQ4t3.js";
1
+ import { a as storeCapabilities, i as memoryStore, n as KeyValueStore, r as StoreCapabilities, t as Awaitable } from "../store-BkaZ8qkU.js";
2
+ import { n as SESSION_TTL_SECONDS, r as memoryCookieStore, t as CookieStore } from "../session-mKtpAeUB.js";
3
+ import { C as CookieStoreErrorEvent, E as resilientCookieStore, S as CookieStoreAdapterOptions, T as ResilientCookieStoreOptions, _ as ioredisCookieStore, a as DurableObjectStubLike, b as CloudflareKvNamespaceLike, c as DiagnoseStoreOptions, d as diagnoseStore, f as UpstashRedisLike, g as IoRedisLike, h as nodeRedisCookieStore, i as DurableObjectStoreOperation, l as StoreDiagnosis, m as NodeRedisLike, n as DurableObjectStorageLike, o as durableObjectStore, p as upstashRedisCookieStore, r as DurableObjectStoreEntry, s as handleDurableObjectStoreRequest, t as DURABLE_OBJECT_STORE_URL, u as StoreSuitability, v as customCookieStore, w as CookieStoreOperation, x as cloudflareKvCookieStore, y as CLOUDFLARE_KV_MIN_TTL_SECONDS } from "../index-DqoDUw6X.js";
4
4
  export { type Awaitable, CLOUDFLARE_KV_MIN_TTL_SECONDS, type CloudflareKvNamespaceLike, type CookieStore, type CookieStoreAdapterOptions, type CookieStoreErrorEvent, type CookieStoreOperation, DURABLE_OBJECT_STORE_URL, type DiagnoseStoreOptions, type DurableObjectStorageLike, type DurableObjectStoreEntry, type DurableObjectStoreOperation, type DurableObjectStubLike, type IoRedisLike, type KeyValueStore, type NodeRedisLike, type ResilientCookieStoreOptions, SESSION_TTL_SECONDS, type StoreCapabilities, type StoreDiagnosis, type StoreSuitability, type UpstashRedisLike, cloudflareKvCookieStore, cloudflareKvCookieStore as cloudflareKvStore, customCookieStore, customCookieStore as customStore, diagnoseStore, durableObjectStore, handleDurableObjectStoreRequest, ioredisCookieStore, ioredisCookieStore as ioredisStore, memoryCookieStore, memoryStore, nodeRedisCookieStore, nodeRedisCookieStore as nodeRedisStore, resilientCookieStore, resilientCookieStore as resilientStore, storeCapabilities, upstashRedisCookieStore, upstashRedisCookieStore as upstashRedisStore };