@atproto/oauth-provider 0.2.5 → 0.2.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (177) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/dist/account/account-store.js +3 -3
  3. package/dist/account/account-store.js.map +1 -1
  4. package/dist/assets/app/bundle-manifest.json +2 -2
  5. package/dist/assets/app/main.js +3 -3
  6. package/dist/assets/app/main.js.map +1 -1
  7. package/dist/assets/asset.d.ts +0 -1
  8. package/dist/assets/asset.d.ts.map +1 -1
  9. package/dist/assets/assets-middleware.js +1 -2
  10. package/dist/assets/assets-middleware.js.map +1 -1
  11. package/dist/assets/index.js +2 -2
  12. package/dist/assets/index.js.map +1 -1
  13. package/dist/client/client-auth.js +2 -3
  14. package/dist/client/client-auth.js.map +1 -1
  15. package/dist/client/client-manager.d.ts +1 -1
  16. package/dist/client/client-manager.d.ts.map +1 -1
  17. package/dist/client/client-manager.js +3 -4
  18. package/dist/client/client-manager.js.map +1 -1
  19. package/dist/client/client-store.js +3 -4
  20. package/dist/client/client-store.js.map +1 -1
  21. package/dist/client/client-utils.d.ts +0 -1
  22. package/dist/client/client-utils.d.ts.map +1 -1
  23. package/dist/client/client-utils.js +2 -3
  24. package/dist/client/client-utils.js.map +1 -1
  25. package/dist/device/device-details.d.ts +0 -1
  26. package/dist/device/device-details.d.ts.map +1 -1
  27. package/dist/device/device-details.js +3 -3
  28. package/dist/device/device-details.js.map +1 -1
  29. package/dist/device/device-id.d.ts.map +1 -1
  30. package/dist/device/device-manager.d.ts +1 -2
  31. package/dist/device/device-manager.d.ts.map +1 -1
  32. package/dist/device/device-store.js +2 -3
  33. package/dist/device/device-store.js.map +1 -1
  34. package/dist/device/session-id.d.ts.map +1 -1
  35. package/dist/dpop/dpop-manager.d.ts +0 -1
  36. package/dist/dpop/dpop-manager.d.ts.map +1 -1
  37. package/dist/lib/html/build-document.d.ts +0 -1
  38. package/dist/lib/html/build-document.d.ts.map +1 -1
  39. package/dist/lib/html/escapers.js +4 -5
  40. package/dist/lib/html/escapers.js.map +1 -1
  41. package/dist/lib/html/util.js +2 -3
  42. package/dist/lib/html/util.js.map +1 -1
  43. package/dist/lib/http/accept.d.ts +0 -1
  44. package/dist/lib/http/accept.d.ts.map +1 -1
  45. package/dist/lib/http/accept.js +1 -2
  46. package/dist/lib/http/accept.js.map +1 -1
  47. package/dist/lib/http/context.js +1 -2
  48. package/dist/lib/http/context.js.map +1 -1
  49. package/dist/lib/http/method.d.ts +0 -1
  50. package/dist/lib/http/method.d.ts.map +1 -1
  51. package/dist/lib/http/method.js +1 -2
  52. package/dist/lib/http/method.js.map +1 -1
  53. package/dist/lib/http/middleware.d.ts +0 -1
  54. package/dist/lib/http/middleware.d.ts.map +1 -1
  55. package/dist/lib/http/middleware.js +4 -5
  56. package/dist/lib/http/middleware.js.map +1 -1
  57. package/dist/lib/http/parser.d.ts +2 -5
  58. package/dist/lib/http/parser.d.ts.map +1 -1
  59. package/dist/lib/http/parser.js +2 -2
  60. package/dist/lib/http/parser.js.map +1 -1
  61. package/dist/lib/http/path.js +1 -2
  62. package/dist/lib/http/path.js.map +1 -1
  63. package/dist/lib/http/request.d.ts +0 -1
  64. package/dist/lib/http/request.d.ts.map +1 -1
  65. package/dist/lib/http/request.js +9 -10
  66. package/dist/lib/http/request.js.map +1 -1
  67. package/dist/lib/http/response.d.ts +0 -3
  68. package/dist/lib/http/response.d.ts.map +1 -1
  69. package/dist/lib/http/response.js +7 -8
  70. package/dist/lib/http/response.js.map +1 -1
  71. package/dist/lib/http/route.d.ts +0 -1
  72. package/dist/lib/http/route.d.ts.map +1 -1
  73. package/dist/lib/http/route.js +1 -2
  74. package/dist/lib/http/route.js.map +1 -1
  75. package/dist/lib/http/router.d.ts +2 -4
  76. package/dist/lib/http/router.d.ts.map +1 -1
  77. package/dist/lib/http/stream.d.ts +2 -7
  78. package/dist/lib/http/stream.d.ts.map +1 -1
  79. package/dist/lib/http/stream.js +5 -5
  80. package/dist/lib/http/stream.js.map +1 -1
  81. package/dist/lib/http/types.d.ts +0 -1
  82. package/dist/lib/http/types.d.ts.map +1 -1
  83. package/dist/lib/http/url.d.ts +0 -1
  84. package/dist/lib/http/url.d.ts.map +1 -1
  85. package/dist/lib/http/url.js +1 -2
  86. package/dist/lib/http/url.js.map +1 -1
  87. package/dist/lib/redis.d.ts.map +1 -1
  88. package/dist/lib/redis.js +7 -6
  89. package/dist/lib/redis.js.map +1 -1
  90. package/dist/lib/util/cast.js +1 -2
  91. package/dist/lib/util/cast.js.map +1 -1
  92. package/dist/lib/util/crypto.js +2 -2
  93. package/dist/lib/util/crypto.js.map +1 -1
  94. package/dist/lib/util/date.js +2 -3
  95. package/dist/lib/util/date.js.map +1 -1
  96. package/dist/lib/util/hostname.d.ts +0 -1
  97. package/dist/lib/util/hostname.d.ts.map +1 -1
  98. package/dist/lib/util/hostname.js +4 -5
  99. package/dist/lib/util/hostname.js.map +1 -1
  100. package/dist/lib/util/redirect-uri.js +1 -2
  101. package/dist/lib/util/redirect-uri.js.map +1 -1
  102. package/dist/lib/util/time.js +1 -2
  103. package/dist/lib/util/time.js.map +1 -1
  104. package/dist/lib/util/well-known.d.ts +0 -1
  105. package/dist/lib/util/well-known.d.ts.map +1 -1
  106. package/dist/lib/util/well-known.js +1 -2
  107. package/dist/lib/util/well-known.js.map +1 -1
  108. package/dist/metadata/build-metadata.d.ts.map +1 -1
  109. package/dist/metadata/build-metadata.js +4 -4
  110. package/dist/metadata/build-metadata.js.map +1 -1
  111. package/dist/oauth-provider.d.ts +1 -2
  112. package/dist/oauth-provider.d.ts.map +1 -1
  113. package/dist/oauth-verifier.d.ts +1 -2
  114. package/dist/oauth-verifier.d.ts.map +1 -1
  115. package/dist/output/build-authorize-data.js +1 -2
  116. package/dist/output/build-authorize-data.js.map +1 -1
  117. package/dist/output/build-error-payload.js +2 -3
  118. package/dist/output/build-error-payload.js.map +1 -1
  119. package/dist/output/customization.d.ts +1 -1
  120. package/dist/output/customization.d.ts.map +1 -1
  121. package/dist/output/customization.js +3 -4
  122. package/dist/output/customization.js.map +1 -1
  123. package/dist/output/output-manager.d.ts +0 -1
  124. package/dist/output/output-manager.d.ts.map +1 -1
  125. package/dist/output/send-authorize-redirect.d.ts +0 -1
  126. package/dist/output/send-authorize-redirect.d.ts.map +1 -1
  127. package/dist/output/send-authorize-redirect.js +1 -2
  128. package/dist/output/send-authorize-redirect.js.map +1 -1
  129. package/dist/output/send-web-page.d.ts +0 -1
  130. package/dist/output/send-web-page.d.ts.map +1 -1
  131. package/dist/output/send-web-page.js +2 -3
  132. package/dist/output/send-web-page.js.map +1 -1
  133. package/dist/replay/replay-store-redis.d.ts +1 -1
  134. package/dist/replay/replay-store-redis.d.ts.map +1 -1
  135. package/dist/replay/replay-store.js +3 -4
  136. package/dist/replay/replay-store.js.map +1 -1
  137. package/dist/request/code.d.ts +1 -1
  138. package/dist/request/code.d.ts.map +1 -1
  139. package/dist/request/request-data.d.ts.map +1 -1
  140. package/dist/request/request-id.d.ts.map +1 -1
  141. package/dist/request/request-manager.d.ts.map +1 -1
  142. package/dist/request/request-manager.js +2 -1
  143. package/dist/request/request-manager.js.map +1 -1
  144. package/dist/request/request-store-redis.d.ts +1 -1
  145. package/dist/request/request-store-redis.d.ts.map +1 -1
  146. package/dist/request/request-store-redis.js.map +1 -1
  147. package/dist/request/request-store.js +2 -3
  148. package/dist/request/request-store.js.map +1 -1
  149. package/dist/request/request-uri.js +3 -3
  150. package/dist/request/request-uri.js.map +1 -1
  151. package/dist/signer/signed-token-payload.d.ts +90 -90
  152. package/dist/signer/signed-token-payload.d.ts.map +1 -1
  153. package/dist/signer/signer.d.ts +6 -6
  154. package/dist/signer/signer.d.ts.map +1 -1
  155. package/dist/token/refresh-token.d.ts +1 -1
  156. package/dist/token/refresh-token.d.ts.map +1 -1
  157. package/dist/token/token-claims.d.ts +90 -90
  158. package/dist/token/token-claims.d.ts.map +1 -1
  159. package/dist/token/token-id.d.ts +1 -1
  160. package/dist/token/token-id.d.ts.map +1 -1
  161. package/dist/token/token-store.js +2 -3
  162. package/dist/token/token-store.js.map +1 -1
  163. package/dist/token/verify-token-claims.js +1 -2
  164. package/dist/token/verify-token-claims.js.map +1 -1
  165. package/package.json +3 -7
  166. package/src/client/client-manager.ts +3 -3
  167. package/src/lib/http/stream.ts +4 -2
  168. package/src/lib/redis.ts +5 -3
  169. package/src/metadata/build-metadata.ts +6 -3
  170. package/src/oauth-provider.ts +1 -1
  171. package/src/oauth-verifier.ts +1 -1
  172. package/src/replay/replay-store-redis.ts +1 -1
  173. package/src/request/request-manager.ts +4 -1
  174. package/src/request/request-store-redis.ts +2 -1
  175. package/tsconfig.backend.tsbuildinfo +1 -0
  176. package/tsconfig.frontend.tsbuildinfo +1 -0
  177. package/tsconfig.tools.tsbuildinfo +1 -0
@@ -1,10 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.asArray = void 0;
3
+ exports.asArray = asArray;
4
4
  function asArray(value) {
5
5
  if (value == null)
6
6
  return [];
7
7
  return Array.isArray(value) ? value : [value];
8
8
  }
9
- exports.asArray = asArray;
10
9
  //# sourceMappingURL=cast.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"cast.js","sourceRoot":"","sources":["../../../src/lib/util/cast.ts"],"names":[],"mappings":";;;AAAA,SAAgB,OAAO,CAAI,KAAc;IACvC,IAAI,KAAK,IAAI,IAAI;QAAE,OAAO,EAAE,CAAA;IAC5B,OAAO,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAA;AAC/C,CAAC;AAHD,0BAGC"}
1
+ {"version":3,"file":"cast.js","sourceRoot":"","sources":["../../../src/lib/util/cast.ts"],"names":[],"mappings":";;AAAA,0BAGC;AAHD,SAAgB,OAAO,CAAI,KAAc;IACvC,IAAI,KAAK,IAAI,IAAI;QAAE,OAAO,EAAE,CAAA;IAC5B,OAAO,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAA;AAC/C,CAAC"}
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.VERIFY_ALGOS = exports.randomHexId = void 0;
3
+ exports.VERIFY_ALGOS = void 0;
4
+ exports.randomHexId = randomHexId;
4
5
  const node_crypto_1 = require("node:crypto");
5
6
  async function randomHexId(bytesLength = 16) {
6
7
  return new Promise((resolve, reject) => {
@@ -11,7 +12,6 @@ async function randomHexId(bytesLength = 16) {
11
12
  });
12
13
  });
13
14
  }
14
- exports.randomHexId = randomHexId;
15
15
  // Basically all algorithms supported by "jose"'s jwtVerify().
16
16
  // @TODO: Is there a way to get this list from the runtime instead of hardcoding it?
17
17
  exports.VERIFY_ALGOS = [
@@ -1 +1 @@
1
- {"version":3,"file":"crypto.js","sourceRoot":"","sources":["../../../src/lib/util/crypto.ts"],"names":[],"mappings":";;;AAAA,6CAAyC;AAElC,KAAK,UAAU,WAAW,CAAC,WAAW,GAAG,EAAE;IAChD,OAAO,IAAI,OAAO,CAAS,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;QAC7C,IAAA,yBAAW,EAAC,WAAW,EAAE,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE;YACpC,IAAI,GAAG;gBAAE,OAAO,MAAM,CAAC,GAAG,CAAC,CAAA;YAC3B,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAA;QAC9B,CAAC,CAAC,CAAA;IACJ,CAAC,CAAC,CAAA;AACJ,CAAC;AAPD,kCAOC;AAED,8DAA8D;AAC9D,oFAAoF;AACvE,QAAA,YAAY,GAAG;IAC1B,OAAO;IACP,OAAO;IACP,OAAO;IAEP,OAAO;IACP,OAAO;IACP,OAAO;IAEP,OAAO;IACP,QAAQ;IACR,OAAO;IACP,OAAO;CACC,CAAA"}
1
+ {"version":3,"file":"crypto.js","sourceRoot":"","sources":["../../../src/lib/util/crypto.ts"],"names":[],"mappings":";;;AAEA,kCAOC;AATD,6CAAyC;AAElC,KAAK,UAAU,WAAW,CAAC,WAAW,GAAG,EAAE;IAChD,OAAO,IAAI,OAAO,CAAS,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;QAC7C,IAAA,yBAAW,EAAC,WAAW,EAAE,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE;YACpC,IAAI,GAAG;gBAAE,OAAO,MAAM,CAAC,GAAG,CAAC,CAAA;YAC3B,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAA;QAC9B,CAAC,CAAC,CAAA;IACJ,CAAC,CAAC,CAAA;AACJ,CAAC;AAED,8DAA8D;AAC9D,oFAAoF;AACvE,QAAA,YAAY,GAAG;IAC1B,OAAO;IACP,OAAO;IACP,OAAO;IAEP,OAAO;IACP,OAAO;IACP,OAAO;IAEP,OAAO;IACP,QAAQ;IACR,OAAO;IACP,OAAO;CACC,CAAA"}
@@ -1,12 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.dateToRelativeSeconds = exports.dateToEpoch = void 0;
3
+ exports.dateToEpoch = dateToEpoch;
4
+ exports.dateToRelativeSeconds = dateToRelativeSeconds;
4
5
  function dateToEpoch(date = new Date()) {
5
6
  return Math.floor(date.getTime() / 1000);
6
7
  }
7
- exports.dateToEpoch = dateToEpoch;
8
8
  function dateToRelativeSeconds(date) {
9
9
  return Math.floor((date.getTime() - Date.now()) / 1000);
10
10
  }
11
- exports.dateToRelativeSeconds = dateToRelativeSeconds;
12
11
  //# sourceMappingURL=date.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"date.js","sourceRoot":"","sources":["../../../src/lib/util/date.ts"],"names":[],"mappings":";;;AAAA,SAAgB,WAAW,CAAC,OAAa,IAAI,IAAI,EAAE;IACjD,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,EAAE,GAAG,IAAI,CAAC,CAAA;AAC1C,CAAC;AAFD,kCAEC;AAED,SAAgB,qBAAqB,CAAC,IAAU;IAC9C,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,OAAO,EAAE,GAAG,IAAI,CAAC,GAAG,EAAE,CAAC,GAAG,IAAI,CAAC,CAAA;AACzD,CAAC;AAFD,sDAEC"}
1
+ {"version":3,"file":"date.js","sourceRoot":"","sources":["../../../src/lib/util/date.ts"],"names":[],"mappings":";;AAAA,kCAEC;AAED,sDAEC;AAND,SAAgB,WAAW,CAAC,OAAa,IAAI,IAAI,EAAE;IACjD,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,EAAE,GAAG,IAAI,CAAC,CAAA;AAC1C,CAAC;AAED,SAAgB,qBAAqB,CAAC,IAAU;IAC9C,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,OAAO,EAAE,GAAG,IAAI,CAAC,GAAG,EAAE,CAAC,GAAG,IAAI,CAAC,CAAA;AACzD,CAAC"}
@@ -1,4 +1,3 @@
1
- /// <reference types="node" />
2
1
  import { ParsedDomain } from 'psl';
3
2
  export declare function isInternetUrl(url: URL): boolean;
4
3
  export declare function isInternetHost(host: string): boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"hostname.d.ts","sourceRoot":"","sources":["../../../src/lib/util/hostname.ts"],"names":[],"mappings":";AAAA,OAAO,EAAS,YAAY,EAAE,MAAM,KAAK,CAAA;AAEzC,wBAAgB,aAAa,CAAC,GAAG,EAAE,GAAG,GAAG,OAAO,CAE/C;AAED,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAEpD;AAED,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,MAAM,GAAG,GAAG,GAAG,YAAY,GAAG,IAAI,CAG7E;AAED,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,MAAM,GAAG,YAAY,GAAG,IAAI,CAO3E"}
1
+ {"version":3,"file":"hostname.d.ts","sourceRoot":"","sources":["../../../src/lib/util/hostname.ts"],"names":[],"mappings":"AAAA,OAAO,EAAS,YAAY,EAAE,MAAM,KAAK,CAAA;AAEzC,wBAAgB,aAAa,CAAC,GAAG,EAAE,GAAG,GAAG,OAAO,CAE/C;AAED,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAEpD;AAED,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,MAAM,GAAG,GAAG,GAAG,YAAY,GAAG,IAAI,CAG7E;AAED,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,MAAM,GAAG,YAAY,GAAG,IAAI,CAO3E"}
@@ -1,20 +1,20 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.parseDomainPublicSuffix = exports.parseUrlPublicSuffix = exports.isInternetHost = exports.isInternetUrl = void 0;
3
+ exports.isInternetUrl = isInternetUrl;
4
+ exports.isInternetHost = isInternetHost;
5
+ exports.parseUrlPublicSuffix = parseUrlPublicSuffix;
6
+ exports.parseDomainPublicSuffix = parseDomainPublicSuffix;
4
7
  const psl_1 = require("psl");
5
8
  function isInternetUrl(url) {
6
9
  return parseUrlPublicSuffix(url) !== null;
7
10
  }
8
- exports.isInternetUrl = isInternetUrl;
9
11
  function isInternetHost(host) {
10
12
  return parseDomainPublicSuffix(host) !== null;
11
13
  }
12
- exports.isInternetHost = isInternetHost;
13
14
  function parseUrlPublicSuffix(input) {
14
15
  const { hostname } = new URL(input);
15
16
  return parseDomainPublicSuffix(hostname);
16
17
  }
17
- exports.parseUrlPublicSuffix = parseUrlPublicSuffix;
18
18
  function parseDomainPublicSuffix(domain) {
19
19
  const parsed = (0, psl_1.parse)(domain);
20
20
  if ('listed' in parsed && parsed.listed && parsed.domain) {
@@ -24,5 +24,4 @@ function parseDomainPublicSuffix(domain) {
24
24
  return null;
25
25
  }
26
26
  }
27
- exports.parseDomainPublicSuffix = parseDomainPublicSuffix;
28
27
  //# sourceMappingURL=hostname.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"hostname.js","sourceRoot":"","sources":["../../../src/lib/util/hostname.ts"],"names":[],"mappings":";;;AAAA,6BAAyC;AAEzC,SAAgB,aAAa,CAAC,GAAQ;IACpC,OAAO,oBAAoB,CAAC,GAAG,CAAC,KAAK,IAAI,CAAA;AAC3C,CAAC;AAFD,sCAEC;AAED,SAAgB,cAAc,CAAC,IAAY;IACzC,OAAO,uBAAuB,CAAC,IAAI,CAAC,KAAK,IAAI,CAAA;AAC/C,CAAC;AAFD,wCAEC;AAED,SAAgB,oBAAoB,CAAC,KAAmB;IACtD,MAAM,EAAE,QAAQ,EAAE,GAAG,IAAI,GAAG,CAAC,KAAK,CAAC,CAAA;IACnC,OAAO,uBAAuB,CAAC,QAAQ,CAAC,CAAA;AAC1C,CAAC;AAHD,oDAGC;AAED,SAAgB,uBAAuB,CAAC,MAAc;IACpD,MAAM,MAAM,GAAG,IAAA,WAAK,EAAC,MAAM,CAAC,CAAA;IAC5B,IAAI,QAAQ,IAAI,MAAM,IAAI,MAAM,CAAC,MAAM,IAAI,MAAM,CAAC,MAAM,EAAE,CAAC;QACzD,OAAO,MAAM,CAAA;IACf,CAAC;SAAM,CAAC;QACN,OAAO,IAAI,CAAA;IACb,CAAC;AACH,CAAC;AAPD,0DAOC"}
1
+ {"version":3,"file":"hostname.js","sourceRoot":"","sources":["../../../src/lib/util/hostname.ts"],"names":[],"mappings":";;AAEA,sCAEC;AAED,wCAEC;AAED,oDAGC;AAED,0DAOC;AAtBD,6BAAyC;AAEzC,SAAgB,aAAa,CAAC,GAAQ;IACpC,OAAO,oBAAoB,CAAC,GAAG,CAAC,KAAK,IAAI,CAAA;AAC3C,CAAC;AAED,SAAgB,cAAc,CAAC,IAAY;IACzC,OAAO,uBAAuB,CAAC,IAAI,CAAC,KAAK,IAAI,CAAA;AAC/C,CAAC;AAED,SAAgB,oBAAoB,CAAC,KAAmB;IACtD,MAAM,EAAE,QAAQ,EAAE,GAAG,IAAI,GAAG,CAAC,KAAK,CAAC,CAAA;IACnC,OAAO,uBAAuB,CAAC,QAAQ,CAAC,CAAA;AAC1C,CAAC;AAED,SAAgB,uBAAuB,CAAC,MAAc;IACpD,MAAM,MAAM,GAAG,IAAA,WAAK,EAAC,MAAM,CAAC,CAAA;IAC5B,IAAI,QAAQ,IAAI,MAAM,IAAI,MAAM,CAAC,MAAM,IAAI,MAAM,CAAC,MAAM,EAAE,CAAC;QACzD,OAAO,MAAM,CAAA;IACf,CAAC;SAAM,CAAC;QACN,OAAO,IAAI,CAAA;IACb,CAAC;AACH,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.compareRedirectUri = void 0;
3
+ exports.compareRedirectUri = compareRedirectUri;
4
4
  const oauth_types_1 = require("@atproto/oauth-types");
5
5
  /**
6
6
  *
@@ -40,5 +40,4 @@ function compareRedirectUri(allowed_uri, request_uri) {
40
40
  }
41
41
  return false;
42
42
  }
43
- exports.compareRedirectUri = compareRedirectUri;
44
43
  //# sourceMappingURL=redirect-uri.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"redirect-uri.js","sourceRoot":"","sources":["../../../src/lib/util/redirect-uri.ts"],"names":[],"mappings":";;;AAAA,sDAAqD;AAErD;;;;GAIG;AACH,SAAgB,kBAAkB,CAChC,WAAmB,EACnB,WAAmB;IAEnB,4DAA4D;IAC5D,EAAE;IACF,0EAA0E;IAC1E,yEAAyE;IACzE,wEAAwE;IACxE,wEAAwE;IACxE,kEAAkE;IAClE,IAAI,WAAW,KAAK,WAAW;QAAE,OAAO,IAAI,CAAA;IAE5C,4DAA4D;IAC5D,MAAM,UAAU,GAAG,IAAI,GAAG,CAAC,WAAW,CAAC,CAAA;IACvC,IAAI,IAAA,4BAAc,EAAC,UAAU,CAAC,QAAQ,CAAC,EAAE,CAAC;QACxC,MAAM,UAAU,GAAG,IAAI,GAAG,CAAC,WAAW,CAAC,CAAA;QAEvC,OAA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;QACF,wEAAwE;QACxE,aAAa;QACb,CAAC,CAAC,UAAU,CAAC,IAAI,IAAI,UAAU,CAAC,IAAI,KAAK,UAAU,CAAC,IAAI,CAAC;YACzD,UAAU,CAAC,QAAQ,KAAK,UAAU,CAAC,QAAQ;YAC3C,UAAU,CAAC,QAAQ,KAAK,UAAU,CAAC,QAAQ;YAC3C,UAAU,CAAC,QAAQ,KAAK,UAAU,CAAC,QAAQ;YAC3C,UAAU,CAAC,MAAM,KAAK,UAAU,CAAC,MAAM;YACvC,UAAU,CAAC,IAAI,KAAK,UAAU,CAAC,IAAI;YACnC,UAAU,CAAC,QAAQ,KAAK,UAAU,CAAC,QAAQ;YAC3C,UAAU,CAAC,QAAQ,KAAK,UAAU,CAAC,QAAQ,CAC5C,CAAA;IACH,CAAC;IAED,OAAO,KAAK,CAAA;AACd,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.constantTime = void 0;
3
+ exports.constantTime = constantTime;
4
4
  /**
5
5
  * Utility function to protect against timing attacks.
6
6
  */
@@ -24,5 +24,4 @@ async function constantTime(delay, fn) {
24
24
  await new Promise((resolve) => setTimeout(resolve, n * delay));
25
25
  }
26
26
  }
27
- exports.constantTime = constantTime;
28
27
  //# sourceMappingURL=time.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"time.js","sourceRoot":"","sources":["../../../src/lib/util/time.ts"],"names":[],"mappings":";;;AAEA;;GAEG;AACI,KAAK,UAAU,YAAY,CAChC,KAAa,EACb,EAAsB;IAEtB,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,KAAK,CAAC,IAAI,KAAK,IAAI,CAAC,EAAE,CAAC;QAC1C,MAAM,IAAI,SAAS,CAAC,8BAA8B,CAAC,CAAA;IACrD,CAAC;IAED,MAAM,KAAK,GAAG,IAAI,CAAC,GAAG,EAAE,CAAA;IACxB,IAAI,CAAC;QACH,OAAO,MAAM,EAAE,EAAE,CAAA;IACn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CAAC,EAAE,CAAC;YACV,OAAO,CAAC,IAAI,CACV,oCAAoC,KAAK,wCAAwC,KAAK,8EAA8E,CACrK,CAAA;QACH,CAAC;QAED,MAAM,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC,GAAG,KAAK,CAAC,CAAC,CAAA;IAChE,CAAC;AACH,CAAC"}
@@ -1,3 +1,2 @@
1
- /// <reference types="node" />
2
1
  export declare function buildWellknownUrl(url: URL, name: string): URL;
3
2
  //# sourceMappingURL=well-known.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"well-known.d.ts","sourceRoot":"","sources":["../../../src/lib/util/well-known.ts"],"names":[],"mappings":";AAAA,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,GAAG,GAAG,CAO7D"}
1
+ {"version":3,"file":"well-known.d.ts","sourceRoot":"","sources":["../../../src/lib/util/well-known.ts"],"names":[],"mappings":"AAAA,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,GAAG,GAAG,CAO7D"}
@@ -1,11 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.buildWellknownUrl = void 0;
3
+ exports.buildWellknownUrl = buildWellknownUrl;
4
4
  function buildWellknownUrl(url, name) {
5
5
  const path = url.pathname === '/'
6
6
  ? `/.well-known/${name}`
7
7
  : `${url.pathname.replace(/\/+$/, '')}/${name}`;
8
8
  return new URL(path, url);
9
9
  }
10
- exports.buildWellknownUrl = buildWellknownUrl;
11
10
  //# sourceMappingURL=well-known.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"well-known.js","sourceRoot":"","sources":["../../../src/lib/util/well-known.ts"],"names":[],"mappings":";;;AAAA,SAAgB,iBAAiB,CAAC,GAAQ,EAAE,IAAY;IACtD,MAAM,IAAI,GACR,GAAG,CAAC,QAAQ,KAAK,GAAG;QAClB,CAAC,CAAC,gBAAgB,IAAI,EAAE;QACxB,CAAC,CAAC,GAAG,GAAG,CAAC,QAAQ,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,IAAI,IAAI,EAAE,CAAA;IAEnD,OAAO,IAAI,GAAG,CAAC,IAAI,EAAE,GAAG,CAAC,CAAA;AAC3B,CAAC;AAPD,8CAOC"}
1
+ {"version":3,"file":"well-known.js","sourceRoot":"","sources":["../../../src/lib/util/well-known.ts"],"names":[],"mappings":";;AAAA,8CAOC;AAPD,SAAgB,iBAAiB,CAAC,GAAQ,EAAE,IAAY;IACtD,MAAM,IAAI,GACR,GAAG,CAAC,QAAQ,KAAK,GAAG;QAClB,CAAC,CAAC,gBAAgB,IAAI,EAAE;QACxB,CAAC,CAAC,GAAG,GAAG,CAAC,QAAQ,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,IAAI,IAAI,EAAE,CAAA;IAEnD,OAAO,IAAI,GAAG,CAAC,IAAI,EAAE,GAAG,CAAC,CAAA;AAC3B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"build-metadata.d.ts","sourceRoot":"","sources":["../../src/metadata/build-metadata.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AACrC,OAAO,EAAE,gCAAgC,EAAE,MAAM,sBAAsB,CAAA;AAKvE,MAAM,MAAM,cAAc,GAAG;IAC3B,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAA;IAC3B,qCAAqC,CAAC,EAAE,MAAM,EAAE,CAAA;IAChD,mBAAmB,CAAC,EAAE,MAAM,EAAE,CAAA;CAC/B,CAAA;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAC3B,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,MAAM,EACd,cAAc,CAAC,EAAE,cAAc,GAC9B,gCAAgC,CAsGlC"}
1
+ {"version":3,"file":"build-metadata.d.ts","sourceRoot":"","sources":["../../src/metadata/build-metadata.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AACrC,OAAO,EACL,gCAAgC,EAEjC,MAAM,sBAAsB,CAAA;AAK7B,MAAM,MAAM,cAAc,GAAG;IAC3B,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAA;IAC3B,qCAAqC,CAAC,EAAE,MAAM,EAAE,CAAA;IAChD,mBAAmB,CAAC,EAAE,MAAM,EAAE,CAAA;CAC/B,CAAA;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAC3B,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,MAAM,EACd,cAAc,CAAC,EAAE,cAAc,GAC9B,gCAAgC,CAsGlC"}
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.buildMetadata = void 0;
3
+ exports.buildMetadata = buildMetadata;
4
+ const oauth_types_1 = require("@atproto/oauth-types");
4
5
  const client_js_1 = require("../client/client.js");
5
6
  const crypto_js_1 = require("../lib/util/crypto.js");
6
7
  /**
@@ -8,7 +9,7 @@ const crypto_js_1 = require("../lib/util/crypto.js");
8
9
  * @see {@link https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata}
9
10
  */
10
11
  function buildMetadata(issuer, keyset, customMetadata) {
11
- return {
12
+ return oauth_types_1.oauthAuthorizationServerMetadataSchema.parse({
12
13
  issuer,
13
14
  scopes_supported: [
14
15
  'atproto',
@@ -89,7 +90,6 @@ function buildMetadata(issuer, keyset, customMetadata) {
89
90
  protected_resources: customMetadata?.protected_resources,
90
91
  // https://drafts.aaronpk.com/draft-parecki-oauth-client-id-metadata-document/draft-parecki-oauth-client-id-metadata-document.html
91
92
  client_id_metadata_document_supported: true,
92
- };
93
+ });
93
94
  }
94
- exports.buildMetadata = buildMetadata;
95
95
  //# sourceMappingURL=build-metadata.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"build-metadata.js","sourceRoot":"","sources":["../../src/metadata/build-metadata.ts"],"names":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jE,+DAA+D;QAE/D,0DAA0D;QAC1D,qCAAqC,EAAE,IAAI,GAAG,CAAC,YAAY,EAAE,MAAM,CAAC,CAAC,IAAI;QAEzE,qCAAqC,EAAE,IAAI;QAE3C,4DAA4D;QAC5D,iCAAiC,EAAE,CAAC,GAAG,wBAAY,CAAC;QAEpD,6DAA6D;QAC7D,qCAAqC,EACnC,cAAc,EAAE,qCAAqC;QAEvD,wFAAwF;QACxF,mBAAmB,EAAE,cAAc,EAAE,mBAAmB;QAExD,kIAAkI;QAClI,qCAAqC,EAAE,IAAI;KAC5C,CAAC,CAAA;AACJ,CAAC"}
@@ -1,8 +1,7 @@
1
- /// <reference types="node" />
2
1
  import { SimpleStore } from '@atproto-labs/simple-store';
3
2
  import { Jwks, Keyset } from '@atproto/jwk';
4
3
  import { OAuthAccessToken, OAuthAuthorizationCodeGrantTokenRequest, OAuthAuthorizationRequestJar, OAuthAuthorizationRequestPar, OAuthAuthorizationRequestParameters, OAuthAuthorizationRequestQuery, OAuthAuthorizationServerMetadata, OAuthClientCredentials, OAuthClientCredentialsNone, OAuthClientMetadata, OAuthIntrospectionResponse, OAuthParResponse, OAuthRefreshTokenGrantTokenRequest, OAuthTokenIdentification, OAuthTokenRequest, OAuthTokenResponse, OAuthTokenType } from '@atproto/oauth-types';
5
- import { Redis, type RedisOptions } from 'ioredis';
4
+ import type { Redis, RedisOptions } from 'ioredis';
6
5
  import { AccountManager } from './account/account-manager.js';
7
6
  import { AccountStore, DeviceAccountInfo, SignInCredentials } from './account/account-store.js';
8
7
  import { Account } from './account/account.js';
@@ -1 +1 @@
1
- {"version":3,"file":"oauth-provider.d.ts","sourceRoot":"","sources":["../src/oauth-provider.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAA;AAExD,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAC3C,OAAO,EAEL,gBAAgB,EAChB,uCAAuC,EACvC,4BAA4B,EAC5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,SAAS,eAAe,GAAG,eAAe,EAC7C,GAAG,SAAS,cAAc,GAAG,cAAc,EAC3C,OAAO,CAAC,EAAE,aAAa,CAAC,GAAG,EAAE,GAAG,CAAC;CAgfpC"}
@@ -1,7 +1,6 @@
1
- /// <reference types="node" />
2
1
  import { Key, Keyset } from '@atproto/jwk';
3
2
  import { OAuthAccessToken, OAuthTokenType } from '@atproto/oauth-types';
4
- import { Redis, type RedisOptions } from 'ioredis';
3
+ import type { Redis, RedisOptions } from 'ioredis';
5
4
  import { AccessTokenType } from './access-token/access-token-type.js';
6
5
  import { DpopManager, DpopManagerOptions } from './dpop/dpop-manager.js';
7
6
  import { DpopNonce } from './dpop/dpop-nonce.js';
@@ -1 +1 @@
1
- {"version":3,"file":"oauth-verifier.d.ts","sourceRoot":"","sources":["../src/oauth-verifier.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,EAAe,MAAM,cAAc,CAAA;AACvD,OAAO,EACL,gBAAgB,EAChB,cAAc,EAEf,MAAM,sBAAsB,CAAA;AAC7B,OAAO,EAAE,KAAK,EAAE,KAAK,YAAY,EAAE,MAAM,SAAS,CAAA;AAElD,OAAO,EAAE,eAAe,EAAE,MAAM,qCAAqC,CAAA;AACrE,OAAO,EAAE,WAAW,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAA;AACxE,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAA;AAMhD,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAA;AAC7C,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAA;AAG1D,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAA;AACtD,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAA;AAC3C,OAAO,EACL,wBAAwB,EACxB,uBAAuB,EAExB,MAAM,gCAAgC,CAAA;AAEvC,MAAM,MAAM,oBAAoB,GAAG,QAAQ,CACzC,kBAAkB,EAClB;IACE;;;OAG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C,EAAE,MAAM,CAAA;QACtB,IAAI,CAAC,EAAE,OAAO,CAAA;KACf,EACD,aAAa,CAAC,EAAE,wBAAwB,GACvC,OAAO,CAAC,uBAAuB,CAAC;CA2BpC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.buildAuthorizeData = void 0;
3
+ exports.buildAuthorizeData = buildAuthorizeData;
4
4
  function buildAuthorizeData(data) {
5
5
  return {
6
6
  clientId: data.client.id,
@@ -19,5 +19,4 @@ function buildAuthorizeData(data) {
19
19
  })),
20
20
  };
21
21
  }
22
- exports.buildAuthorizeData = buildAuthorizeData;
23
22
  //# sourceMappingURL=build-authorize-data.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"build-authorize-data.js","sourceRoot":"","sources":["../../src/output/build-authorize-data.ts"],"names":[],"mappings":";;;AAyDA,SAAgB,kBAAkB,CAChC,IAAkC;IAElC,OAAO;QACL,QAAQ,EAAE,IAAI,CAAC,MAAM,CAAC,EAAE;QACxB,cAAc,EAAE,IAAI,CAAC,MAAM,CAAC,QAAQ;QACpC,aAAa,EAAE,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,SAAS;QACzC,UAAU,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG;QAC9B,UAAU,EAAE,QAAQ,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE;QACxC,SAAS,EAAE,IAAI,CAAC,UAAU,CAAC,UAAU;QACrC,yBAAyB,EAAE,IAAI,CAAC,UAAU,CAAC,MAAM,KAAK,SAAS;QAC/D,YAAY,EAAE,IAAI,CAAC,SAAS,CAAC,YAAY;QACzC,QAAQ,EAAE,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,GAAG,CACnC,CAAC,OAAO,EAAW,EAAE,CAAC,CAAC;YACrB,OAAO,EAAE,OAAO,CAAC,OAAO;YACxB,QAAQ,EAAE,OAAO,CAAC,QAAQ;YAC1B,aAAa,EAAE,OAAO,CAAC,aAAa;YACpC,eAAe,EAAE,OAAO,CAAC,eAAe;SACzC,CAAC,CACH;KACF,CAAA;AACH,CAAC;AArBD,gDAqBC"}
1
+ {"version":3,"file":"build-authorize-data.js","sourceRoot":"","sources":["../../src/output/build-authorize-data.ts"],"names":[],"mappings":";;AAyDA,gDAqBC;AArBD,SAAgB,kBAAkB,CAChC,IAAkC;IAElC,OAAO;QACL,QAAQ,EAAE,IAAI,CAAC,MAAM,CAAC,EAAE;QACxB,cAAc,EAAE,IAAI,CAAC,MAAM,CAAC,QAAQ;QACpC,aAAa,EAAE,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,SAAS;QACzC,UAAU,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG;QAC9B,UAAU,EAAE,QAAQ,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE;QACxC,SAAS,EAAE,IAAI,CAAC,UAAU,CAAC,UAAU;QACrC,yBAAyB,EAAE,IAAI,CAAC,UAAU,CAAC,MAAM,KAAK,SAAS;QAC/D,YAAY,EAAE,IAAI,CAAC,SAAS,CAAC,YAAY;QACzC,QAAQ,EAAE,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,GAAG,CACnC,CAAC,OAAO,EAAW,EAAE,CAAC,CAAC;YACrB,OAAO,EAAE,OAAO,CAAC,OAAO;YACxB,QAAQ,EAAE,OAAO,CAAC,QAAQ;YAC1B,aAAa,EAAE,OAAO,CAAC,aAAa;YACpC,eAAe,EAAE,OAAO,CAAC,eAAe;SACzC,CAAC,CACH;KACF,CAAA;AACH,CAAC"}
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.buildErrorPayload = exports.buildErrorStatus = void 0;
3
+ exports.buildErrorStatus = buildErrorStatus;
4
+ exports.buildErrorPayload = buildErrorPayload;
4
5
  const jwk_1 = require("@atproto/jwk");
5
6
  const jose_1 = require("jose");
6
7
  const zod_1 = require("zod");
@@ -39,7 +40,6 @@ function buildErrorStatus(error) {
39
40
  }
40
41
  return 500;
41
42
  }
42
- exports.buildErrorStatus = buildErrorStatus;
43
43
  function buildErrorPayload(error) {
44
44
  if (error instanceof oauth_error_js_1.OAuthError) {
45
45
  return error.toJSON();
@@ -86,7 +86,6 @@ function buildErrorPayload(error) {
86
86
  : 'Server error',
87
87
  };
88
88
  }
89
- exports.buildErrorPayload = buildErrorPayload;
90
89
  function isBoom(v) {
91
90
  return (v instanceof Error &&
92
91
  v.isBoom === true &&
@@ -1 +1 @@
1
- {"version":3,"file":"build-error-payload.js","sourceRoot":"","sources":["../../src/output/build-error-payload.ts"],"names":[],"mappings":";;;AAAA,sCAA6C;AAC7C,+BAA6B;AAC7B,6BAA8B;AAE9B,6DAAqD;AAErD,MAAM,EAAE,SAAS,EAAE,GAAG,aAAM,CAAA;AAE5B,MAAM,eAAe,GAAG,iBAAiB,CAAA;AACzC,MAAM,YAAY,GAAG,cAAc,CAAA;AAEnC,SAAgB,gBAAgB,CAAC,KAAc;IAC7C,IAAI,KAAK,YAAY,2BAAU,EAAE,CAAC;QAChC,OAAO,KAAK,CAAC,UAAU,CAAA;IACzB,CAAC;IAED,IAAI,KAAK,YAAY,oBAAc,EAAE,CAAC;QACpC,OAAO,GAAG,CAAA;IACZ,CAAC;IAED,IAAI,KAAK,YAAY,cAAQ,EAAE,CAAC;QAC9B,OAAO,GAAG,CAAA;IACZ,CAAC;IAED,IAAI,KAAK,YAAY,SAAS,EAAE,CAAC;QAC/B,OAAO,GAAG,CAAA;IACZ,CAAC;IAED,IAAI,KAAK,YAAY,SAAS,EAAE,CAAC;QAC/B,OAAO,GAAG,CAAA;IACZ,CAAC;IAED,IAAI,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC;QAClB,OAAO,KAAK,CAAC,MAAM,CAAC,UAAU,CAAA;IAChC,CAAC;IAED,IAAI,WAAW,CAAC,KAAK,CAAC,EAAE,CAAC;QACvB,OAAO,KAAK,CAAC,IAAI,CAAA;IACnB,CAAC;IAED,MAAM,MAAM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jC,CAAA;AACH,CAAC"}
@@ -18,7 +18,7 @@ export declare function buildCustomizationData({ name, logo, links, }?: Customiz
18
18
  links: {
19
19
  href: string;
20
20
  title: string;
21
- rel?: string | undefined;
21
+ rel?: string;
22
22
  }[] | undefined;
23
23
  };
24
24
  export declare function buildCustomizationCss(customization?: Customization): string;
@@ -1 +1 @@
1
- {"version":3,"file":"customization.d.ts","sourceRoot":"","sources":["../../src/output/customization.ts"],"names":[],"mappings":"AACA,QAAA,MAAM,UAAU,wCAAyC,CAAA;AACzD,KAAK,SAAS,GAAG,CAAC,OAAO,UAAU,CAAC,CAAC,MAAM,CAAC,CAAA;AAI5C,MAAM,MAAM,aAAa,GAAG;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE;SAAG,CAAC,IAAI,SAAS,CAAC,CAAC,EAAE,MAAM;KAAE,CAAA;IACtC,KAAK,CAAC,EAAE,KAAK,CAAC;QACZ,IAAI,EAAE,MAAM,CAAA;QACZ,KAAK,EAAE,MAAM,CAAA;QACb,GAAG,CAAC,EAAE,MAAM,CAAA;KACb,CAAC,CAAA;CACH,CAAA;AAED,wBAAgB,sBAAsB,CAAC,EACrC,IAAI,EACJ,IAAI,EACJ,KAAK,GACN,GAAE,aAAkB;;;;;;;;EAMpB;AAED,wBAAgB,qBAAqB,CAAC,aAAa,CAAC,EAAE,aAAa,UAKlE;AAED,wBAAiB,sBAAsB,CAAC,aAAa,CAAC,EAAE,aAAa,oCAkBpE"}
1
+ {"version":3,"file":"customization.d.ts","sourceRoot":"","sources":["../../src/output/customization.ts"],"names":[],"mappings":"AACA,QAAA,MAAM,UAAU,wCAAyC,CAAA;AACzD,KAAK,SAAS,GAAG,CAAC,OAAO,UAAU,CAAC,CAAC,MAAM,CAAC,CAAA;AAI5C,MAAM,MAAM,aAAa,GAAG;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE;SAAG,CAAC,IAAI,SAAS,CAAC,CAAC,EAAE,MAAM;KAAE,CAAA;IACtC,KAAK,CAAC,EAAE,KAAK,CAAC;QACZ,IAAI,EAAE,MAAM,CAAA;QACZ,KAAK,EAAE,MAAM,CAAA;QACb,GAAG,CAAC,EAAE,MAAM,CAAA;KACb,CAAC,CAAA;CACH,CAAA;AAED,wBAAgB,sBAAsB,CAAC,EACrC,IAAI,EACJ,IAAI,EACJ,KAAK,GACN,GAAE,aAAkB;;;;cAVX,MAAM;eACL,MAAM;cACP,MAAM;;EAcf;AAED,wBAAgB,qBAAqB,CAAC,aAAa,CAAC,EAAE,aAAa,UAKlE;AAED,wBAAiB,sBAAsB,CAAC,aAAa,CAAC,EAAE,aAAa,oCAkBpE"}
@@ -1,6 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.buildCustomizationVars = exports.buildCustomizationCss = exports.buildCustomizationData = void 0;
3
+ exports.buildCustomizationData = buildCustomizationData;
4
+ exports.buildCustomizationCss = buildCustomizationCss;
5
+ exports.buildCustomizationVars = buildCustomizationVars;
4
6
  // Matches colors defined in tailwind.config.js
5
7
  const colorNames = ['brand', 'error', 'warning'];
6
8
  const isColorName = (name) => colorNames.includes(name);
@@ -11,14 +13,12 @@ function buildCustomizationData({ name, logo, links, } = {}) {
11
13
  links,
12
14
  };
13
15
  }
14
- exports.buildCustomizationData = buildCustomizationData;
15
16
  function buildCustomizationCss(customization) {
16
17
  const vars = Array.from(buildCustomizationVars(customization));
17
18
  if (vars.length)
18
19
  return `:root { ${vars.join(' ')} }`;
19
20
  return '';
20
21
  }
21
- exports.buildCustomizationCss = buildCustomizationCss;
22
22
  function* buildCustomizationVars(customization) {
23
23
  if (customization?.colors) {
24
24
  for (const [name, value] of Object.entries(customization.colors)) {
@@ -36,7 +36,6 @@ function* buildCustomizationVars(customization) {
36
36
  }
37
37
  }
38
38
  }
39
- exports.buildCustomizationVars = buildCustomizationVars;
40
39
  function parseColor(color) {
41
40
  if (typeof color !== 'string') {
42
41
  throw new TypeError(`Invalid color value: ${typeof color}`);
@@ -1 +1 @@
1
- {"version":3,"file":"customization.js","sourceRoot":"","sources":["../../src/output/customization.ts"],"names":[],"mappings":";;;AAAA,+CAA+C;AAC/C,MAAM,UAAU,GAAG,CAAC,OAAO,EAAE,OAAO,EAAE,SAAS,CAAU,CAAA;AAEzD,MAAM,WAAW,GAAG,CAAC,IAAY,EAAqB,EAAE,CACrD,UAAgC,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAA;AAalD,SAAgB,sBAAsB,CAAC,EACrC,IAAI,EACJ,IAAI,EACJ,KAAK,MACY,EAAE;IACnB,OAAO;QACL,IAAI;QACJ,IAAI;QACJ,KAAK;KACN,CAAA;AACH,CAAC;AAVD,wDAUC;AAED,SAAgB,qBAAqB,CAAC,aAA6B;IACjE,MAAM,IAAI,GAAG,KAAK,CAAC,IAAI,CAAC,sBAAsB,CAAC,aAAa,CAAC,CAAC,CAAA;IAC9D,IAAI,IAAI,CAAC,MAAM;QAAE,OAAO,WAAW,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,CAAA;IAErD,OAAO,EAAE,CAAA;AACX,CAAC;AALD,sDAKC;AAED,QAAe,CAAC,CAAC,sBAAsB,CAAC,aAA6B;IACnE,IAAI,aAAa,EAAE,MAAM,EAAE,CAAC;QAC1B,KAAK,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,aAAa,CAAC,MAAM,CAAC,EAAE,CAAC;YACjE,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,EAAE,CAAC;gBACvB,MAAM,IAAI,SAAS,CAAC,uBAAuB,IAAI,EAAE,CAAC,CAAA;YACpD,CAAC;YAED,wBAAwB;YACxB,IAAI,KAAK,KAAK,SAAS;gBAAE,SAAQ;YAEjC,MAAM,EAAE,CAAC,EAAE,CAAC,EAAE,C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tB,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,GAAG,CAAC,CAAC;QAAE,OAAO,CAAC,CAAA;IACjD,MAAM,IAAI,SAAS,CAAC,4BAA4B,CAAC,EAAE,CAAC,CAAA;AACtD,CAAC"}
@@ -1,4 +1,3 @@
1
- /// <reference types="node" />
2
1
  import { ServerResponse } from 'node:http';
3
2
  import { Asset } from '../assets/asset.js';
4
3
  import { Html } from '../lib/html/index.js';
@@ -1 +1 @@
1
- {"version":3,"file":"output-manager.d.ts","sourceRoot":"","sources":["../../src/output/output-manager.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAA;AAE1C,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAA;AAE1C,OAAO,EAAW,IAAI,EAAQ,MAAM,sBAAsB,CAAA;AAC1D,OAAO,EACL,4BAA4B,EAE7B,MAAM,2BAA2B,CAAA;AAElC,OAAO,EAGL,aAAa,EACd,MAAM,oBAAoB,CAAA;AAG3B,qBAAa,aAAa;IACxB,QAAQ,CAAC,mBAAmB,EAAE,IAAI,CAAA;IAClC,QAAQ,CAAC,kBAAkB,EAAE,IAAI,CAAA;IACjC,QAAQ,CAAC,kBAAkB,CAAC,EAAE,aAAa,CAAC,OAAO,CAAC,CAAA;IAMpD,QAAQ,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC,EAAE,EAAE,KAAK,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC,CAG7C;gBAEC,aAAa,CAAC,EAAE,aAAa;IAYnC,iBAAiB,CACrB,GAAG,EAAE,cAAc,EACnB,IAAI,EAAE,4BAA4B,GACjC,OAAO,CAAC,IAAI,CAAC;IAoBV,aAAa,CAAC,GAAG,EAAE,cAAc,EAAE,GAAG,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC;CAoBtE"}
1
+ {"version":3,"file":"output-manager.d.ts","sourceRoot":"","sources":["../../src/output/output-manager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAA;AAE1C,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAA;AAE1C,OAAO,EAAW,IAAI,EAAQ,MAAM,sBAAsB,CAAA;AAC1D,OAAO,EACL,4BAA4B,EAE7B,MAAM,2BAA2B,CAAA;AAElC,OAAO,EAGL,aAAa,EACd,MAAM,oBAAoB,CAAA;AAG3B,qBAAa,aAAa;IACxB,QAAQ,CAAC,mBAAmB,EAAE,IAAI,CAAA;IAClC,QAAQ,CAAC,kBAAkB,EAAE,IAAI,CAAA;IACjC,QAAQ,CAAC,kBAAkB,CAAC,EAAE,aAAa,CAAC,OAAO,CAAC,CAAA;IAMpD,QAAQ,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC,EAAE,EAAE,KAAK,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC,CAG7C;gBAEC,aAAa,CAAC,EAAE,aAAa;IAYnC,iBAAiB,CACrB,GAAG,EAAE,cAAc,EACnB,IAAI,EAAE,4BAA4B,GACjC,OAAO,CAAC,IAAI,CAAC;IAoBV,aAAa,CAAC,GAAG,EAAE,cAAc,EAAE,GAAG,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC;CAoBtE"}
@@ -1,4 +1,3 @@
1
- /// <reference types="node" />
2
1
  import { OAuthAuthorizationRequestParameters, OAuthTokenType } from '@atproto/oauth-types';
3
2
  import { ServerResponse } from 'node:http';
4
3
  import { Code } from '../request/code.js';
@@ -1 +1 @@
1
- {"version":3,"file":"send-authorize-redirect.d.ts","sourceRoot":"","sources":["../../src/output/send-authorize-redirect.ts"],"names":[],"mappings":";AAAA,OAAO,EACL,mCAAmC,EACnC,cAAc,EACf,MAAM,sBAAsB,CAAA;AAC7B,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAA;AAI1C,OAAO,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAA;AAMzC,MAAM,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A;IACd,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAA;AAED,MAAM,MAAM,2BAA2B,GAAG;IACxC,MAAM,EAAE,MAAM,CAAA;IACd,UAAU,EAAE,mCAAmC,CAAA;IAC/C,QAAQ,EAAE,+BAA+B,CAAA;CAC1C,CAAA;AAED,wBAAsB,qBAAqB,CACzC,GAAG,EAAE,cAAc,EACnB,MAAM,EAAE,2BAA2B,GAClC,OAAO,CAAC,IAAI,CAAC,CAuCf"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.sendAuthorizeRedirect = void 0;
3
+ exports.sendAuthorizeRedirect = sendAuthorizeRedirect;
4
4
  const invalid_request_error_js_1 = require("../errors/invalid-request-error.js");
5
5
  const index_js_1 = require("../lib/html/index.js");
6
6
  const send_web_page_js_1 = require("./send-web-page.js");
@@ -38,7 +38,6 @@ async function sendAuthorizeRedirect(res, result) {
38
38
  // @ts-expect-error fool proof
39
39
  throw new Error(`Unsupported mode: ${mode}`);
40
40
  }
41
- exports.sendAuthorizeRedirect = sendAuthorizeRedirect;
42
41
  function writeQuery(res, uri, entries) {
43
42
  const url = new URL(uri);
44
43
  for (const [key, value] of entries)
@@ -1 +1 @@
1
- {"version":3,"file":"send-authorize-redirect.js","sourceRoot":"","sources":["../../src/output/send-authorize-redirect.ts"],"names":[],"mappings":";;;AAMA,iFAAwE;AACxE,mDAA+C;AAE/C,yDAAgD;AAEhD,+EAA+E;AAC/E,MAAM,oBAAoB,GAAG,GAAG,CAAA;AA6BzB,KAAK,UAAU,qBAAqB,CACzC,GAAmB,EACnB,MAAmC;IAEnC,MAAM,EAAE,MAAM,EAAE,UAAU,EAAE,QAAQ,EAAE,GAAG,MAAM,CAAA;IAE/C,MAAM,GAAG,GAAG,UAAU,CAAC,YAAY,CAAA;IACnC,IAAI,CAAC,GAAG;QAAE,MAAM,IAAI,8CAAm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K,MAAM,CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,OAAO;QAAE,YAAY,CAAC,GAAG,CAAC,GAAG,EAAE,KAAK,CAAC,CAAA;IAChE,GAAG,CAAC,IAAI,GAAG,YAAY,CAAC,QAAQ,EAAE,CAAA;IAClC,GAAG,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,QAAQ,EAAE,GAAG,CAAC,IAAI,EAAE,CAAC,CAAC,GAAG,EAAE,CAAA;AACnE,CAAC;AAED,KAAK,UAAU,aAAa,CAC1B,GAAmB,EACnB,GAAW,EACX,OAAoC;IAEpC,4CAA4C;IAC5C,uGAAuG;IACvG,GAAG,CAAC,SAAS,CAAC,YAAY,EAAE,4CAA4C,CAAC,CAAA;IACzE,GAAG,CAAC,SAAS,CAAC,eAAe,EAAE,UAAU,CAAC,CAAA;IAC1C,GAAG,CAAC,SAAS,CAAC,oBAAoB,EAAE,uCAAuC,CAAC,CAAA;IAE5E,OAAO,IAAA,8BAAW,EAAC,GAAG,EAAE;QACtB,SAAS,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE;QACzB,IAAI,EAAE,IAAA,eAAI,EAAA;oCACsB,GAAG;UAC7B,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,EAAE,KAAK,CAAC,EAAE,EAAE,CAAC;YAC9B,IAAA,eAAI,EAAA,8BAA8B,GAAG,YAAY,KAAK,MAAM;SAC7D,CAAC;;;KAGL;QACD,OAAO,EAAE,CAAC,IAAA,aAAE,EAAA,6BAA6B,CAAC;KAC3C,CAAC,CAAA;AACJ,CAAC"}
@@ -1,4 +1,3 @@
1
- /// <reference types="node" />
2
1
  import { ServerResponse } from 'node:http';
3
2
  import { BuildDocumentOptions, Html } from '../lib/html/index.js';
4
3
  export declare function declareBackendData(name: string, data: unknown): Html;
@@ -1 +1 @@
1
- {"version":3,"file":"send-web-page.d.ts","sourceRoot":"","sources":["../../src/output/send-web-page.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAA;AAE1C,OAAO,EAGL,oBAAoB,EACpB,IAAI,EAEL,MAAM,sBAAsB,CAAA;AAG7B,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,QAM7D;AAED,wBAAsB,WAAW,CAC/B,GAAG,EAAE,cAAc,EACnB,EAAE,MAAY,EAAE,GAAG,OAAO,EAAE,EAAE,oBAAoB,GAAG;IAAE,MAAM,CAAC,EAAE,MAAM,CAAA;CAAE,GACvE,OAAO,CAAC,IAAI,CAAC,CAiCf"}
1
+ {"version":3,"file":"send-web-page.d.ts","sourceRoot":"","sources":["../../src/output/send-web-page.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAA;AAE1C,OAAO,EAGL,oBAAoB,EACpB,IAAI,EAEL,MAAM,sBAAsB,CAAA;AAG7B,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,QAM7D;AAED,wBAAsB,WAAW,CAC/B,GAAG,EAAE,cAAc,EACnB,EAAE,MAAY,EAAE,GAAG,OAAO,EAAE,EAAE,oBAAoB,GAAG;IAAE,MAAM,CAAC,EAAE,MAAM,CAAA;CAAE,GACvE,OAAO,CAAC,IAAI,CAAC,CAiCf"}
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.sendWebPage = exports.declareBackendData = void 0;
3
+ exports.declareBackendData = declareBackendData;
4
+ exports.sendWebPage = sendWebPage;
4
5
  const node_crypto_1 = require("node:crypto");
5
6
  const index_js_1 = require("../lib/html/index.js");
6
7
  const response_js_1 = require("../lib/http/response.js");
@@ -11,7 +12,6 @@ function declareBackendData(name, data) {
11
12
  // "readBackendData" in "src/assets/app/backend-data.ts".
12
13
  return (0, index_js_1.js) `window[${name}]=${data};document.currentScript.remove();`;
13
14
  }
14
- exports.declareBackendData = declareBackendData;
15
15
  async function sendWebPage(res, { status = 200, ...options }) {
16
16
  // @TODO: make these headers configurable (?)
17
17
  res.setHeader('Permissions-Policy', 'otp-credentials=*, document-domain=()');
@@ -37,7 +37,6 @@ async function sendWebPage(res, { status = 200, ...options }) {
37
37
  const html = (0, index_js_1.buildDocument)(options);
38
38
  return (0, response_js_1.writeHtml)(res, html.toString(), status);
39
39
  }
40
- exports.sendWebPage = sendWebPage;
41
40
  function assetToHash(asset) {
42
41
  return asset instanceof index_js_1.Html
43
42
  ? (0, node_crypto_1.createHash)('sha256').update(asset.toString()).digest('base64')
@@ -1 +1 @@
1
- {"version":3,"file":"send-web-page.js","sourceRoot":"","sources":["../../src/output/send-web-page.ts"],"names":[],"mappings":";;;AAAA,6CAAwC;AAGxC,mDAM6B;AAC7B,yDAAmD;AAEnD,SAAgB,kBAAkB,CAAC,IAAY,EAAE,IAAa;IAC5D,8EAA8E;IAC9E,8EAA8E;IAC9E,8DAA8D;IAC9D,yDAAyD;IACzD,OAAO,IAAA,aAAE,EAAA,UAAU,IAAI,KAAK,IAAI,mCAAmC,CAAA;AACrE,CAAC;AAND,gDAMC;AAEM,KAAK,UAAU,WAAW,CAC/B,GAAmB,EACnB,EAAE,MAAM,GAAG,GAAG,EAAE,GAAG,OAAO,EAA8C;IAExE,6CAA6C;IAC7C,GAAG,CAAC,SAAS,CAAC,oBAAoB,EAAE,uCAAuC,CAAC,CAAA;IAC5E,GAAG,CAAC,SAAS,CAAC,8BAA8B,EAAE,gBAAgB,CAAC,CAAA;IAC/D,GAAG,CAAC,SAAS,CAAC,8BAA8B,EAAE,aAAa,CAAC,CAAA;IAC5D,GAAG,CAAC,SAAS,CAAC,4BAA4B,EAAE,aAAa,CAAC,CAAA;IAC1D,GAAG,CAAC,SAAS,CAAC,iBAAiB,EAAE,aAAa,CAAC,CAAA;IAC/C,GAAG,CAAC,SAAS,CAAC,iBAAiB,EAAE,MAAM,CAAC,CAAA;IACxC,GAAG,CAAC,SAAS,CAAC,wBAAwB,EAAE,SAA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I,EACpE,EAAE;QACF,oBACE,OAAO,CAAC,MAAM,EAAE,GAAG,CAAC,WAAW,CAAC,CAAC,GAAG,CAAC,aAAa,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,EACnE,EAAE;QACF,6BAA6B;QAC7B,oBAAoB;QACpB,2BAA2B;KAC5B,CAAC,IAAI,CAAC,IAAI,CAAC,CACb,CAAA;IAED,MAAM,IAAI,GAAG,IAAA,wBAAa,EAAC,OAAO,CAAC,CAAA;IAEnC,OAAO,IAAA,uBAAS,EAAC,GAAG,EAAE,IAAI,CAAC,QAAQ,EAAE,EAAE,MAAM,CAAC,CAAA;AAChD,CAAC;AAED,SAAS,WAAW,CAAC,KAAsB;IACzC,OAAO,KAAK,YAAY,eAAI;QAC1B,CAAC,CAAC,IAAA,wBAAU,EAAC,QAAQ,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAC,MAAM,CAAC,QAAQ,CAAC;QAChE,CAAC,CAAC,KAAK,CAAC,MAAM,CAAA;AAClB,CAAC;AAED,SAAS,aAAa,CAAC,IAAY;IACjC,OAAO,WAAW,IAAI,GAAG,CAAA;AAC3B,CAAC"}
@@ -1,4 +1,4 @@
1
- import { Redis } from 'ioredis';
1
+ import type { Redis } from 'ioredis';
2
2
  import { CreateRedisOptions } from '../lib/redis.js';
3
3
  import type { ReplayStore } from './replay-store.js';
4
4
  export type { CreateRedisOptions, Redis };
@@ -1 +1 @@
1
- {"version":3,"file":"replay-store-redis.d.ts","sourceRoot":"","sources":["../../src/replay/replay-store-redis.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAA;AAE/B,OAAO,EAAE,kBAAkB,EAAe,MAAM,iBAAiB,CAAA;AACjE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAEpD,YAAY,EAAE,kBAAkB,EAAE,KAAK,EAAE,CAAA;AAEzC,MAAM,MAAM,uBAAuB,GAAG;IACpC,KAAK,EAAE,kBAAkB,CAAA;CAC1B,CAAA;AAED,qBAAa,gBAAiB,YAAW,WAAW;IAClD,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAO;gBAEjB,OAAO,EAAE,uBAAuB;IAI5C;;OAEG;IACG,MAAM,CACV,SAAS,EAAE,MAAM,EACjB,KAAK,EAAE,MAAM,EACb,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,OAAO,CAAC;CAKpB"}
1
+ {"version":3,"file":"replay-store-redis.d.ts","sourceRoot":"","sources":["../../src/replay/replay-store-redis.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,SAAS,CAAA;AAEpC,OAAO,EAAE,kBAAkB,EAAe,MAAM,iBAAiB,CAAA;AACjE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAEpD,YAAY,EAAE,kBAAkB,EAAE,KAAK,EAAE,CAAA;AAEzC,MAAM,MAAM,uBAAuB,GAAG;IACpC,KAAK,EAAE,kBAAkB,CAAA;CAC1B,CAAA;AAED,qBAAa,gBAAiB,YAAW,WAAW;IAClD,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAO;gBAEjB,OAAO,EAAE,uBAAuB;IAI5C;;OAEG;IACG,MAAM,CACV,SAAS,EAAE,MAAM,EACjB,KAAK,EAAE,MAAM,EACb,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,OAAO,CAAC;CAKpB"}
@@ -1,22 +1,21 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.asReplayStore = exports.ifReplayStore = exports.isReplayStore = void 0;
3
+ exports.isReplayStore = isReplayStore;
4
+ exports.ifReplayStore = ifReplayStore;
5
+ exports.asReplayStore = asReplayStore;
4
6
  function isReplayStore(implementation) {
5
7
  return typeof implementation.unique === 'function';
6
8
  }
7
- exports.isReplayStore = isReplayStore;
8
9
  function ifReplayStore(implementation) {
9
10
  if (implementation && isReplayStore(implementation)) {
10
11
  return implementation;
11
12
  }
12
13
  return undefined;
13
14
  }
14
- exports.ifReplayStore = ifReplayStore;
15
15
  function asReplayStore(implementation) {
16
16
  const store = ifReplayStore(implementation);
17
17
  if (store)
18
18
  return store;
19
19
  throw new Error('Invalid ReplayStore implementation');
20
20
  }
21
- exports.asReplayStore = asReplayStore;
22
21
  //# sourceMappingURL=replay-store.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"replay-store.js","sourceRoot":"","sources":["../../src/replay/replay-store.ts"],"names":[],"mappings":";;;AAoBA,SAAgB,aAAa,CAC3B,cAA8D;IAE9D,OAAO,OAAO,cAAc,CAAC,MAAM,KAAK,UAAU,CAAA;AACpD,CAAC;AAJD,sCAIC;AAED,SAAgB,aAAa,CAC3B,cAA+D;IAE/D,IAAI,cAAc,IAAI,aAAa,CAAC,cAAc,CAAC,EAAE,CAAC;QACpD,OAAO,cAAc,CAAA;IACvB,CAAC;IAED,OAAO,SAAS,CAAA;AAClB,CAAC;AARD,sCAQC;AAED,SAAgB,aAAa,CAC3B,cAA+D;IAE/D,MAAM,KAAK,GAAG,aAAa,CAAC,cAAc,CAAC,CAAA;IAC3C,IAAI,KAAK;QAAE,OAAO,KAAK,CAAA;IAEvB,MAAM,IAAI,KAAK,CAAC,oCAAoC,CAAC,CAAA;AACvD,CAAC;AAPD,sCAOC"}
1
+ {"version":3,"file":"replay-store.js","sourceRoot":"","sources":["../../src/replay/replay-store.ts"],"names":[],"mappings":";;AAoBA,sCAIC;AAED,sCAQC;AAED,sCAOC;AAvBD,SAAgB,aAAa,CAC3B,cAA8D;IAE9D,OAAO,OAAO,cAAc,CAAC,MAAM,KAAK,UAAU,CAAA;AACpD,CAAC;AAED,SAAgB,aAAa,CAC3B,cAA+D;IAE/D,IAAI,cAAc,IAAI,aAAa,CAAC,cAAc,CAAC,EAAE,CAAC;QACpD,OAAO,cAAc,CAAA;IACvB,CAAC;IAED,OAAO,SAAS,CAAA;AAClB,CAAC;AAED,SAAgB,aAAa,CAC3B,cAA+D;IAE/D,MAAM,KAAK,GAAG,aAAa,CAAC,cAAc,CAAC,CAAA;IAC3C,IAAI,KAAK;QAAE,OAAO,KAAK,CAAA;IAEvB,MAAM,IAAI,KAAK,CAAC,oCAAoC,CAAC,CAAA;AACvD,CAAC"}