@fedify/fedify 1.9.0-dev.1426 → 1.9.0-dev.1482

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 (87) hide show
  1. package/README.md +25 -14
  2. package/dist/{actor-CgMSXJ7T.js → actor-B6O9lL4G.js} +187 -187
  3. package/dist/{actor-DBVIhd3g.js → actor-QVcR1Xrn.js} +1 -1
  4. package/dist/{authdocloader-GJlMpzlI.js → authdocloader-Cntcn_YV.js} +3 -3
  5. package/dist/{authdocloader-Cl_S6m_U.js → authdocloader-TZ2fecyQ.js} +3 -3
  6. package/dist/{builder-DeF3DvGa.js → builder-BhJh7eKg.js} +4 -4
  7. package/dist/{client-D1DkBgMW.js → client-CoVxRMaH.js} +1 -1
  8. package/dist/compat/transformers.test.js +16 -16
  9. package/dist/{denokv-2x6-IpXO.js → denokv-Bv33Xxea.js} +7 -0
  10. package/dist/{docloader-BSCctXal.js → docloader-LrxjeHj-.js} +2 -2
  11. package/dist/{esm-CC8HHtIX.js → esm-iDLKkyo2.js} +1 -1
  12. package/dist/federation/builder.test.js +5 -5
  13. package/dist/federation/collection.test.js +3 -3
  14. package/dist/federation/handler.test.js +17 -17
  15. package/dist/federation/inbox.test.js +4 -4
  16. package/dist/federation/keycache.test.js +4 -4
  17. package/dist/federation/kv.test.js +3 -3
  18. package/dist/federation/middleware.test.js +18 -18
  19. package/dist/federation/mod.js +10 -10
  20. package/dist/federation/mq.test.js +5 -5
  21. package/dist/federation/retry.test.js +3 -3
  22. package/dist/federation/router.test.js +3 -3
  23. package/dist/federation/send.test.js +10 -10
  24. package/dist/fixtures/oeee.cafe/ap/users/3609fd4e-d51d-4db8-9f04-4189815864dd.json +24 -0
  25. package/dist/{http-CEL1OpoJ.js → http-Bnzs68Tb.js} +50 -4
  26. package/dist/{http-BRkdMiKk.js → http-Dl3V8s7N.js} +51 -5
  27. package/dist/{inbox-DgeNUDDq.js → inbox-Bc9TqfwY.js} +1 -1
  28. package/dist/{key-BFZkjEdF.js → key--_X6meDH.js} +2 -2
  29. package/dist/{key-DxDW5e94.js → key-CsEfx1oS.js} +2 -2
  30. package/dist/{key-CnDYMoEy.js → key-Czna_Jyn.js} +4 -4
  31. package/dist/{key-DqLks8WZ.js → key-DShOGANW.js} +3 -3
  32. package/dist/{keycache-DiK_ysAm.js → keycache-886nSyeS.js} +1 -1
  33. package/dist/{keys-CU3pwbgD.js → keys-B6UF_RpQ.js} +1 -1
  34. package/dist/{ld-DZBKkjYA.js → ld-CbkvjE14.js} +2 -2
  35. package/dist/{lookup-2btkCjyT.js → lookup-8fiFfa7V.js} +1 -1
  36. package/dist/{lookup-Cni8TEY-.js → lookup-BAJ-9RA_.js} +1 -1
  37. package/dist/middleware-BBCOja5n.js +17 -0
  38. package/dist/middleware-BaOSpj7d.js +26 -0
  39. package/dist/{middleware-CccxNSFX.js → middleware-DN_7x21r.js} +10 -10
  40. package/dist/{middleware-DPJZ1_pj.js → middleware-DjUYz7vp.js} +13 -13
  41. package/dist/mod.js +10 -10
  42. package/dist/nodeinfo/client.test.js +5 -5
  43. package/dist/nodeinfo/handler.test.js +16 -16
  44. package/dist/nodeinfo/mod.js +2 -2
  45. package/dist/nodeinfo/semver.test.js +3 -3
  46. package/dist/nodeinfo/types.test.js +3 -3
  47. package/dist/{owner-C7mGG_7y.js → owner-CgCEc3SM.js} +2 -2
  48. package/dist/{proof-CMLfMbze.js → proof-BaQpwWHy.js} +3 -3
  49. package/dist/{proof-jMo9AJgi.js → proof-Dn70Cmj3.js} +2 -2
  50. package/dist/runtime/authdocloader.test.js +9 -9
  51. package/dist/runtime/docloader.test.js +28 -4
  52. package/dist/runtime/key.test.js +5 -5
  53. package/dist/runtime/langstr.test.js +3 -3
  54. package/dist/runtime/mod.js +6 -6
  55. package/dist/runtime/multibase/multibase.test.js +3 -3
  56. package/dist/runtime/url.test.js +3 -3
  57. package/dist/{send-DxWNr0-E.js → send-Ci-BbAM3.js} +2 -2
  58. package/dist/sig/http.test.js +24 -8
  59. package/dist/sig/key.test.js +6 -6
  60. package/dist/sig/ld.test.js +7 -7
  61. package/dist/sig/mod.js +6 -6
  62. package/dist/sig/owner.test.js +7 -7
  63. package/dist/sig/proof.test.js +7 -7
  64. package/dist/testing/docloader.test.js +3 -3
  65. package/dist/testing/mod.js +3 -3
  66. package/dist/{testing-DsZhG4d1.js → testing-BZD0yq6K.js} +2 -2
  67. package/dist/{type-Caga0-TR.js → type-BjSxSeX3.js} +187 -187
  68. package/dist/{types-DJjc-Yj8.js → types-CzPx8n7N.js} +1 -1
  69. package/dist/vocab/actor.test.js +5 -5
  70. package/dist/vocab/lookup.test.js +4 -4
  71. package/dist/vocab/mod.js +4 -4
  72. package/dist/vocab/type.test.js +3 -3
  73. package/dist/vocab/vocab.test.js +4 -4
  74. package/dist/{vocab-B7bJTtQA.js → vocab-B4QSDf66.js} +3 -3
  75. package/dist/webfinger/handler.test.js +16 -16
  76. package/dist/webfinger/lookup.test.js +4 -4
  77. package/dist/webfinger/mod.js +2 -2
  78. package/dist/x/cfworkers.d.ts +8 -0
  79. package/dist/x/cfworkers.js +14 -0
  80. package/dist/x/cfworkers.test.js +16 -3
  81. package/dist/x/hono.d.ts +8 -0
  82. package/dist/x/hono.js +12 -0
  83. package/dist/x/sveltekit.d.ts +4 -0
  84. package/dist/x/sveltekit.js +12 -0
  85. package/package.json +1 -1
  86. package/dist/middleware-BrcymdJX.js +0 -26
  87. package/dist/middleware-mCOJY7S6.js +0 -17
@@ -2,7 +2,7 @@
2
2
  import { Temporal } from "@js-temporal/polyfill";
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
 
5
- import { getUserAgent } from "./docloader-BSCctXal.js";
5
+ import { getUserAgent } from "./docloader-LrxjeHj-.js";
6
6
  import { getLogger } from "@logtape/logtape";
7
7
 
8
8
  //#region src/nodeinfo/semver.ts
@@ -3,19 +3,19 @@
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
  globalThis.addEventListener = () => {};
5
5
 
6
- import { Application, Group, Organization, Person, Service, __export } from "../type-Caga0-TR.js";
6
+ import { Application, Group, Organization, Person, Service, __export } from "../type-BjSxSeX3.js";
7
7
  import { assertEquals } from "../assert_equals-DSbWqCm3.js";
8
8
  import { assert } from "../assert-MZs1qjMx.js";
9
9
  import "../assert_instance_of-DHz7EHNU.js";
10
- import "../lookup-2btkCjyT.js";
11
- import { getActorClassByTypeName, getActorHandle, getActorTypeName, isActor, normalizeActorHandle } from "../actor-DBVIhd3g.js";
12
- import { test } from "../testing-DsZhG4d1.js";
10
+ import "../lookup-8fiFfa7V.js";
11
+ import { getActorClassByTypeName, getActorHandle, getActorTypeName, isActor, normalizeActorHandle } from "../actor-QVcR1Xrn.js";
12
+ import { test } from "../testing-BZD0yq6K.js";
13
13
  import { assertStrictEquals } from "../std__assert-X-_kMxKM.js";
14
14
  import { assertFalse, assertRejects } from "../assert_rejects-DiIiJbZn.js";
15
15
  import "../assert_is_error-BPGph1Jx.js";
16
16
  import "../assert_not_equals-f3m3epl3.js";
17
17
  import { assertThrows } from "../assert_throws-BOO88avQ.js";
18
- import { esm_default } from "../esm-CC8HHtIX.js";
18
+ import { esm_default } from "../esm-iDLKkyo2.js";
19
19
 
20
20
  //#region ../../node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/precondition/PreconditionFailure.js
21
21
  var PreconditionFailure = class PreconditionFailure extends Error {
@@ -3,18 +3,18 @@
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
  globalThis.addEventListener = () => {};
5
5
 
6
- import { Collection, Note, Object as Object$1, Person } from "../type-Caga0-TR.js";
6
+ import { Collection, Note, Object as Object$1, Person } from "../type-BjSxSeX3.js";
7
7
  import { assertEquals } from "../assert_equals-DSbWqCm3.js";
8
8
  import "../assert-MZs1qjMx.js";
9
9
  import { assertInstanceOf } from "../assert_instance_of-DHz7EHNU.js";
10
- import { lookupObject, traverseCollection } from "../lookup-2btkCjyT.js";
11
- import { mockDocumentLoader, test } from "../testing-DsZhG4d1.js";
10
+ import { lookupObject, traverseCollection } from "../lookup-8fiFfa7V.js";
11
+ import { mockDocumentLoader, test } from "../testing-BZD0yq6K.js";
12
12
  import "../std__assert-X-_kMxKM.js";
13
13
  import "../assert_rejects-DiIiJbZn.js";
14
14
  import "../assert_is_error-BPGph1Jx.js";
15
15
  import "../assert_not_equals-f3m3epl3.js";
16
16
  import "../assert_throws-BOO88avQ.js";
17
- import { esm_default } from "../esm-CC8HHtIX.js";
17
+ import { esm_default } from "../esm-iDLKkyo2.js";
18
18
 
19
19
  //#region src/vocab/lookup.test.ts
20
20
  test("lookupObject()", {
package/dist/vocab/mod.js CHANGED
@@ -2,9 +2,9 @@
2
2
  import { Temporal } from "@js-temporal/polyfill";
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
 
5
- import "../docloader-BSCctXal.js";
6
- import { Accept, Activity, Add, Announce, Application, Arrive, Article, Audio, Block, ChatMessage, Collection, CollectionPage, Create, CryptographicKey, DataIntegrityProof, Delete, DidService, Dislike, Document, Emoji, EmojiReact, Endpoints, Event, Export, Flag, Follow, Group, Hashtag, Ignore, Image, IntransitiveActivity, Invite, Join, Leave, Like, Link, Listen, Mention, Move, Multikey, Note, Object as Object$1, Offer, OrderedCollection, OrderedCollectionPage, Organization, Page, Person, Place, Profile, PropertyValue, Question, Read, Reject, Relationship, Remove, Service, Source, TentativeAccept, TentativeReject, Tombstone, Travel, Undo, Update, Video, View, getActorClassByTypeName, getActorHandle, getActorTypeName, getTypeId, isActor, normalizeActorHandle } from "../actor-CgMSXJ7T.js";
7
- import "../lookup-Cni8TEY-.js";
8
- import { PUBLIC_COLLECTION, isFediverseHandle, lookupObject, parseFediverseHandle, toAcctUrl, traverseCollection } from "../vocab-B7bJTtQA.js";
5
+ import "../docloader-LrxjeHj-.js";
6
+ import { Accept, Activity, Add, Announce, Application, Arrive, Article, Audio, Block, ChatMessage, Collection, CollectionPage, Create, CryptographicKey, DataIntegrityProof, Delete, DidService, Dislike, Document, Emoji, EmojiReact, Endpoints, Event, Export, Flag, Follow, Group, Hashtag, Ignore, Image, IntransitiveActivity, Invite, Join, Leave, Like, Link, Listen, Mention, Move, Multikey, Note, Object as Object$1, Offer, OrderedCollection, OrderedCollectionPage, Organization, Page, Person, Place, Profile, PropertyValue, Question, Read, Reject, Relationship, Remove, Service, Source, TentativeAccept, TentativeReject, Tombstone, Travel, Undo, Update, Video, View, getActorClassByTypeName, getActorHandle, getActorTypeName, getTypeId, isActor, normalizeActorHandle } from "../actor-B6O9lL4G.js";
7
+ import "../lookup-BAJ-9RA_.js";
8
+ import { PUBLIC_COLLECTION, isFediverseHandle, lookupObject, parseFediverseHandle, toAcctUrl, traverseCollection } from "../vocab-B4QSDf66.js";
9
9
 
10
10
  export { Accept, Activity, Add, Announce, Application, Arrive, Article, Audio, Block, ChatMessage, Collection, CollectionPage, Create, CryptographicKey, DataIntegrityProof, Delete, DidService, Dislike, Document, Emoji, EmojiReact, Endpoints, Event, Export, Flag, Follow, Group, Hashtag, Ignore, Image, IntransitiveActivity, Invite, Join, Leave, Like, Link, Listen, Mention, Move, Multikey, Note, Object$1 as Object, Offer, OrderedCollection, OrderedCollectionPage, Organization, PUBLIC_COLLECTION, Page, Person, Place, Profile, PropertyValue, Question, Read, Reject, Relationship, Remove, Service, Source, TentativeAccept, TentativeReject, Tombstone, Travel, Undo, Update, Video, View, getActorClassByTypeName, getActorHandle, getActorTypeName, getTypeId, isActor, isFediverseHandle, lookupObject, normalizeActorHandle, parseFediverseHandle, toAcctUrl, traverseCollection };
@@ -3,10 +3,10 @@
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
  globalThis.addEventListener = () => {};
5
5
 
6
- import { Person, getTypeId } from "../type-Caga0-TR.js";
6
+ import { Person, getTypeId } from "../type-BjSxSeX3.js";
7
7
  import { assertEquals } from "../assert_equals-DSbWqCm3.js";
8
- import "../lookup-2btkCjyT.js";
9
- import { test } from "../testing-DsZhG4d1.js";
8
+ import "../lookup-8fiFfa7V.js";
9
+ import { test } from "../testing-BZD0yq6K.js";
10
10
 
11
11
  //#region src/vocab/type.test.ts
12
12
  test("getTypeId()", () => {
@@ -3,18 +3,18 @@
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
  globalThis.addEventListener = () => {};
5
5
 
6
- import { Activity, Announce, Collection, Create, CryptographicKey, Follow, Hashtag, LanguageString, Note, Object as Object$1, OrderedCollectionPage, Person, Place, Question, Source, decode, vocab_exports } from "../type-Caga0-TR.js";
6
+ import { Activity, Announce, Collection, Create, CryptographicKey, Follow, Hashtag, LanguageString, Note, Object as Object$1, OrderedCollectionPage, Person, Place, Question, Source, decode, vocab_exports } from "../type-BjSxSeX3.js";
7
7
  import { assertEquals } from "../assert_equals-DSbWqCm3.js";
8
8
  import { assert } from "../assert-MZs1qjMx.js";
9
9
  import { assertInstanceOf } from "../assert_instance_of-DHz7EHNU.js";
10
- import "../lookup-2btkCjyT.js";
11
- import { mockDocumentLoader, test } from "../testing-DsZhG4d1.js";
10
+ import "../lookup-8fiFfa7V.js";
11
+ import { mockDocumentLoader, test } from "../testing-BZD0yq6K.js";
12
12
  import "../std__assert-X-_kMxKM.js";
13
13
  import { assertFalse, assertRejects } from "../assert_rejects-DiIiJbZn.js";
14
14
  import "../assert_is_error-BPGph1Jx.js";
15
15
  import { assertNotEquals } from "../assert_not_equals-f3m3epl3.js";
16
16
  import { assertThrows } from "../assert_throws-BOO88avQ.js";
17
- import { ed25519PublicKey, rsaPublicKey1 } from "../keys-CU3pwbgD.js";
17
+ import { ed25519PublicKey, rsaPublicKey1 } from "../keys-B6UF_RpQ.js";
18
18
  import { pascalCase } from "es-toolkit";
19
19
  import { parseLanguageTag } from "@phensley/language-tag";
20
20
  import { Validator } from "@cfworker/json-schema";
@@ -2,9 +2,9 @@
2
2
  import { Temporal } from "@js-temporal/polyfill";
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
 
5
- import { deno_default, getDocumentLoader } from "./docloader-BSCctXal.js";
6
- import { Object as Object$1, getTypeId } from "./actor-CgMSXJ7T.js";
7
- import { lookupWebFinger } from "./lookup-Cni8TEY-.js";
5
+ import { deno_default, getDocumentLoader } from "./docloader-LrxjeHj-.js";
6
+ import { Object as Object$1, getTypeId } from "./actor-B6O9lL4G.js";
7
+ import { lookupWebFinger } from "./lookup-BAJ-9RA_.js";
8
8
  import { getLogger } from "@logtape/logtape";
9
9
  import { SpanStatusCode, trace } from "@opentelemetry/api";
10
10
  import { delay } from "es-toolkit";
@@ -3,30 +3,30 @@
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
  globalThis.addEventListener = () => {};
5
5
 
6
- import { Image, Link, Person } from "../type-Caga0-TR.js";
6
+ import { Image, Link, Person } from "../type-BjSxSeX3.js";
7
7
  import { assertEquals } from "../assert_equals-DSbWqCm3.js";
8
8
  import "../assert-MZs1qjMx.js";
9
9
  import "../assert_instance_of-DHz7EHNU.js";
10
10
  import { MemoryKvStore } from "../kv-CRZrzyXm.js";
11
- import { createFederation, handleWebFinger } from "../middleware-DPJZ1_pj.js";
11
+ import { createFederation, handleWebFinger } from "../middleware-DjUYz7vp.js";
12
12
  import "../semver-dArNLkR9.js";
13
- import "../client-D1DkBgMW.js";
14
- import "../lookup-2btkCjyT.js";
13
+ import "../client-CoVxRMaH.js";
14
+ import "../lookup-8fiFfa7V.js";
15
15
  import "../types-BIgY6c-l.js";
16
- import "../actor-DBVIhd3g.js";
17
- import "../key-BFZkjEdF.js";
18
- import "../http-CEL1OpoJ.js";
19
- import "../authdocloader-GJlMpzlI.js";
20
- import "../ld-DZBKkjYA.js";
21
- import "../owner-C7mGG_7y.js";
22
- import "../proof-jMo9AJgi.js";
23
- import "../inbox-DgeNUDDq.js";
24
- import "../builder-DeF3DvGa.js";
16
+ import "../actor-QVcR1Xrn.js";
17
+ import "../key--_X6meDH.js";
18
+ import "../http-Bnzs68Tb.js";
19
+ import "../authdocloader-Cntcn_YV.js";
20
+ import "../ld-CbkvjE14.js";
21
+ import "../owner-CgCEc3SM.js";
22
+ import "../proof-Dn70Cmj3.js";
23
+ import "../inbox-Bc9TqfwY.js";
24
+ import "../builder-BhJh7eKg.js";
25
25
  import "../collection-CSzG2j1P.js";
26
- import "../keycache-DiK_ysAm.js";
26
+ import "../keycache-886nSyeS.js";
27
27
  import "../retry-D4GJ670a.js";
28
- import "../send-DxWNr0-E.js";
29
- import { createRequestContext, test } from "../testing-DsZhG4d1.js";
28
+ import "../send-Ci-BbAM3.js";
29
+ import { createRequestContext, test } from "../testing-BZD0yq6K.js";
30
30
  import "../std__assert-X-_kMxKM.js";
31
31
  import "../assert_rejects-DiIiJbZn.js";
32
32
  import "../assert_is_error-BPGph1Jx.js";
@@ -3,18 +3,18 @@
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
  globalThis.addEventListener = () => {};
5
5
 
6
- import { lookupWebFinger } from "../type-Caga0-TR.js";
6
+ import { lookupWebFinger } from "../type-BjSxSeX3.js";
7
7
  import { assertEquals } from "../assert_equals-DSbWqCm3.js";
8
8
  import "../assert-MZs1qjMx.js";
9
9
  import "../assert_instance_of-DHz7EHNU.js";
10
- import "../lookup-2btkCjyT.js";
11
- import { test } from "../testing-DsZhG4d1.js";
10
+ import "../lookup-8fiFfa7V.js";
11
+ import { test } from "../testing-BZD0yq6K.js";
12
12
  import "../std__assert-X-_kMxKM.js";
13
13
  import "../assert_rejects-DiIiJbZn.js";
14
14
  import "../assert_is_error-BPGph1Jx.js";
15
15
  import "../assert_not_equals-f3m3epl3.js";
16
16
  import "../assert_throws-BOO88avQ.js";
17
- import { esm_default } from "../esm-CC8HHtIX.js";
17
+ import { esm_default } from "../esm-iDLKkyo2.js";
18
18
  import { withTimeout } from "es-toolkit";
19
19
 
20
20
  //#region src/webfinger/lookup.test.ts
@@ -2,8 +2,8 @@
2
2
  import { Temporal } from "@js-temporal/polyfill";
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
 
5
- import "../docloader-BSCctXal.js";
6
- import { lookupWebFinger } from "../lookup-Cni8TEY-.js";
5
+ import "../docloader-LrxjeHj-.js";
6
+ import { lookupWebFinger } from "../lookup-BAJ-9RA_.js";
7
7
  import "../webfinger-C3GIyXIg.js";
8
8
 
9
9
  export { lookupWebFinger };
@@ -15,6 +15,10 @@ import { KVNamespace, Queue } from "@cloudflare/workers-types/experimental";
15
15
  * operation, as Cloudflare Workers KV does not support atomic compare-and-swap
16
16
  * operations. If you need this functionality, consider using a different
17
17
  * key–value store that supports atomic operations.
18
+ *
19
+ * @deprecated This class has been moved to `@fedify/cfworkers` package.
20
+ * Import `WorkersKvStore` from `@fedify/cfworkers` instead.
21
+ * This class will be removed in Fedify v2.0.
18
22
  * @since 1.6.0
19
23
  */
20
24
  declare class WorkersKvStore implements KvStore {
@@ -34,6 +38,10 @@ declare class WorkersKvStore implements KvStore {
34
38
  * way as other message queue systems. Instead, you should use
35
39
  * the {@link Federation.processQueuedTask} method to process messages
36
40
  * passed to the queue.
41
+ *
42
+ * @deprecated This class has been moved to `@fedify/cfworkers` package.
43
+ * Import `WorkersMessageQueue` from `@fedify/cfworkers` instead.
44
+ * This class will be removed in Fedify v2.0.
37
45
  * @since 1.6.0
38
46
  */
39
47
  declare class WorkersMessageQueue implements MessageQueue {
@@ -2,6 +2,8 @@
2
2
  import { Temporal } from "@js-temporal/polyfill";
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
 
5
+ import { getLogger } from "@logtape/logtape";
6
+
5
7
  //#region src/x/cfworkers.ts
6
8
  /**
7
9
  * Implementation of the {@link KvStore} interface for Cloudflare Workers KV
@@ -12,11 +14,17 @@
12
14
  * operation, as Cloudflare Workers KV does not support atomic compare-and-swap
13
15
  * operations. If you need this functionality, consider using a different
14
16
  * key–value store that supports atomic operations.
17
+ *
18
+ * @deprecated This class has been moved to `@fedify/cfworkers` package.
19
+ * Import `WorkersKvStore` from `@fedify/cfworkers` instead.
20
+ * This class will be removed in Fedify v2.0.
15
21
  * @since 1.6.0
16
22
  */
17
23
  var WorkersKvStore = class {
18
24
  #namespace;
19
25
  constructor(namespace) {
26
+ const logger = getLogger(["fedify", "cfworkers"]);
27
+ logger.warn("The `@fedify/fedify/x/cfworkers` module is deprecated; use `WorkersKvStore` from `@fedify/cfworkers` package instead.");
20
28
  this.#namespace = namespace;
21
29
  }
22
30
  #encodeKey(key) {
@@ -49,6 +57,10 @@ var WorkersKvStore = class {
49
57
  * way as other message queue systems. Instead, you should use
50
58
  * the {@link Federation.processQueuedTask} method to process messages
51
59
  * passed to the queue.
60
+ *
61
+ * @deprecated This class has been moved to `@fedify/cfworkers` package.
62
+ * Import `WorkersMessageQueue` from `@fedify/cfworkers` instead.
63
+ * This class will be removed in Fedify v2.0.
52
64
  * @since 1.6.0
53
65
  */
54
66
  var WorkersMessageQueue = class {
@@ -60,6 +72,8 @@ var WorkersMessageQueue = class {
60
72
  */
61
73
  nativeRetrial = true;
62
74
  constructor(queue) {
75
+ const logger = getLogger(["fedify", "cfworkers"]);
76
+ logger.warn("The `@fedify/fedify/x/cfworkers` module is deprecated; use `WorkersMessageQueue` from `@fedify/cfworkers` package instead.");
63
77
  this.#queue = queue;
64
78
  }
65
79
  enqueue(message, options) {
@@ -3,18 +3,19 @@
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
  globalThis.addEventListener = () => {};
5
5
 
6
- import "../type-Caga0-TR.js";
6
+ import "../type-BjSxSeX3.js";
7
7
  import { assertEquals } from "../assert_equals-DSbWqCm3.js";
8
8
  import "../assert-MZs1qjMx.js";
9
9
  import "../assert_instance_of-DHz7EHNU.js";
10
- import "../lookup-2btkCjyT.js";
11
- import { test } from "../testing-DsZhG4d1.js";
10
+ import "../lookup-8fiFfa7V.js";
11
+ import { test } from "../testing-BZD0yq6K.js";
12
12
  import "../std__assert-X-_kMxKM.js";
13
13
  import "../assert_rejects-DiIiJbZn.js";
14
14
  import "../assert_is_error-BPGph1Jx.js";
15
15
  import "../assert_not_equals-f3m3epl3.js";
16
16
  import "../assert_throws-BOO88avQ.js";
17
17
  import { delay } from "es-toolkit";
18
+ import { getLogger } from "@logtape/logtape";
18
19
 
19
20
  //#region src/x/cfworkers.ts
20
21
  /**
@@ -26,11 +27,17 @@ import { delay } from "es-toolkit";
26
27
  * operation, as Cloudflare Workers KV does not support atomic compare-and-swap
27
28
  * operations. If you need this functionality, consider using a different
28
29
  * key–value store that supports atomic operations.
30
+ *
31
+ * @deprecated This class has been moved to `@fedify/cfworkers` package.
32
+ * Import `WorkersKvStore` from `@fedify/cfworkers` instead.
33
+ * This class will be removed in Fedify v2.0.
29
34
  * @since 1.6.0
30
35
  */
31
36
  var WorkersKvStore = class {
32
37
  #namespace;
33
38
  constructor(namespace) {
39
+ const logger = getLogger(["fedify", "cfworkers"]);
40
+ logger.warn("The `@fedify/fedify/x/cfworkers` module is deprecated; use `WorkersKvStore` from `@fedify/cfworkers` package instead.");
34
41
  this.#namespace = namespace;
35
42
  }
36
43
  #encodeKey(key) {
@@ -63,6 +70,10 @@ var WorkersKvStore = class {
63
70
  * way as other message queue systems. Instead, you should use
64
71
  * the {@link Federation.processQueuedTask} method to process messages
65
72
  * passed to the queue.
73
+ *
74
+ * @deprecated This class has been moved to `@fedify/cfworkers` package.
75
+ * Import `WorkersMessageQueue` from `@fedify/cfworkers` instead.
76
+ * This class will be removed in Fedify v2.0.
66
77
  * @since 1.6.0
67
78
  */
68
79
  var WorkersMessageQueue = class {
@@ -74,6 +85,8 @@ var WorkersMessageQueue = class {
74
85
  */
75
86
  nativeRetrial = true;
76
87
  constructor(queue) {
88
+ const logger = getLogger(["fedify", "cfworkers"]);
89
+ logger.warn("The `@fedify/fedify/x/cfworkers` module is deprecated; use `WorkersMessageQueue` from `@fedify/cfworkers` package instead.");
77
90
  this.#queue = queue;
78
91
  }
79
92
  enqueue(message, options) {
package/dist/x/hono.d.ts CHANGED
@@ -25,6 +25,10 @@ type HonoMiddleware<THonoContext extends HonoContext> = (ctx: THonoContext, next
25
25
  * A factory function to create a context data for the {@link Federation}
26
26
  * object.
27
27
  *
28
+ * @deprecated This type has been moved to `@fedify/hono` package.
29
+ * Import `ContextDataFactory` from `@fedify/hono` instead.
30
+ * This type will be removed in Fedify v2.0.
31
+ *
28
32
  * @template TContextData A type of the context data for the {@link Federation}
29
33
  * object.
30
34
  * @template THonoContext A type of the Hono context.
@@ -35,6 +39,10 @@ type ContextDataFactory<TContextData, THonoContext> = (context: THonoContext) =>
35
39
  /**
36
40
  * Create a Hono middleware to integrate with the {@link Federation} object.
37
41
  *
42
+ * @deprecated This function has been moved to `@fedify/hono` package.
43
+ * Import `federation` from `@fedify/hono` instead.
44
+ * This function will be removed in Fedify v2.0.
45
+ *
38
46
  * @template TContextData A type of the context data for the {@link Federation}
39
47
  * object.
40
48
  * @template THonoContext A type of the Hono context.
package/dist/x/hono.js CHANGED
@@ -2,10 +2,16 @@
2
2
  import { Temporal } from "@js-temporal/polyfill";
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
 
5
+ import { getLogger } from "@logtape/logtape";
6
+
5
7
  //#region src/x/hono.ts
6
8
  /**
7
9
  * Create a Hono middleware to integrate with the {@link Federation} object.
8
10
  *
11
+ * @deprecated This function has been moved to `@fedify/hono` package.
12
+ * Import `federation` from `@fedify/hono` instead.
13
+ * This function will be removed in Fedify v2.0.
14
+ *
9
15
  * @template TContextData A type of the context data for the {@link Federation}
10
16
  * object.
11
17
  * @template THonoContext A type of the Hono context.
@@ -15,6 +21,12 @@
15
21
  * @returns A Hono middleware.
16
22
  */
17
23
  function federation(federation$1, contextDataFactory) {
24
+ const logger = getLogger([
25
+ "fedify",
26
+ "federation",
27
+ "hono"
28
+ ]);
29
+ logger.warn("The `@fedify/fedify/x/hono` module is deprecated; use `federation` from `@fedify/hono` package instead.");
18
30
  return async (ctx, next) => {
19
31
  let contextData = contextDataFactory(ctx);
20
32
  if (contextData instanceof Promise) contextData = await contextData;
@@ -24,6 +24,10 @@ type HookParams = {
24
24
  * Create a SvelteKit hook handler to integrate with the {@link Federation}
25
25
  * object.
26
26
  *
27
+ * @deprecated This function has been moved to `@fedify/sveltekit` package.
28
+ * Import `fedifyHook` from `@fedify/sveltekit` instead.
29
+ * This function will be removed in Fedify v2.0.
30
+ *
27
31
  * @example hooks.server.ts
28
32
  * ``` typescript
29
33
  * import { federation } from "./federation"; // Import the `Federation` object
@@ -2,11 +2,17 @@
2
2
  import { Temporal } from "@js-temporal/polyfill";
3
3
  import { URLPattern } from "urlpattern-polyfill";
4
4
 
5
+ import { getLogger } from "@logtape/logtape";
6
+
5
7
  //#region src/x/sveltekit.ts
6
8
  /**
7
9
  * Create a SvelteKit hook handler to integrate with the {@link Federation}
8
10
  * object.
9
11
  *
12
+ * @deprecated This function has been moved to `@fedify/sveltekit` package.
13
+ * Import `fedifyHook` from `@fedify/sveltekit` instead.
14
+ * This function will be removed in Fedify v2.0.
15
+ *
10
16
  * @example hooks.server.ts
11
17
  * ``` typescript
12
18
  * import { federation } from "./federation"; // Import the `Federation` object
@@ -23,6 +29,12 @@
23
29
  * @since 1.3.0
24
30
  */
25
31
  function fedifyHook(federation, createContextData) {
32
+ const logger = getLogger([
33
+ "fedify",
34
+ "federation",
35
+ "sveltekit"
36
+ ]);
37
+ logger.warn("The `@fedify/fedify/x/sveltekit` module is deprecated; use `fedifyHook` from `@fedify/sveltekit` package instead.");
26
38
  return async ({ event, resolve }) => {
27
39
  return await federation.fetch(event.request, {
28
40
  contextData: await createContextData(event),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fedify/fedify",
3
- "version": "1.9.0-dev.1426+9dd4221c",
3
+ "version": "1.9.0-dev.1482+542d3bc6",
4
4
  "description": "An ActivityPub server framework",
5
5
  "keywords": [
6
6
  "ActivityPub",
@@ -1,26 +0,0 @@
1
-
2
- import { Temporal } from "@js-temporal/polyfill";
3
- import { URLPattern } from "urlpattern-polyfill";
4
- globalThis.addEventListener = () => {};
5
-
6
- import "./type-Caga0-TR.js";
7
- import { ContextImpl, FederationImpl, InboxContextImpl, KvSpecDeterminer, createFederation } from "./middleware-DPJZ1_pj.js";
8
- import "./semver-dArNLkR9.js";
9
- import "./client-D1DkBgMW.js";
10
- import "./lookup-2btkCjyT.js";
11
- import "./types-BIgY6c-l.js";
12
- import "./actor-DBVIhd3g.js";
13
- import "./key-BFZkjEdF.js";
14
- import "./http-CEL1OpoJ.js";
15
- import "./authdocloader-GJlMpzlI.js";
16
- import "./ld-DZBKkjYA.js";
17
- import "./owner-C7mGG_7y.js";
18
- import "./proof-jMo9AJgi.js";
19
- import "./inbox-DgeNUDDq.js";
20
- import "./builder-DeF3DvGa.js";
21
- import "./collection-CSzG2j1P.js";
22
- import "./keycache-DiK_ysAm.js";
23
- import "./retry-D4GJ670a.js";
24
- import "./send-DxWNr0-E.js";
25
-
26
- export { FederationImpl };
@@ -1,17 +0,0 @@
1
-
2
- import { Temporal } from "@js-temporal/polyfill";
3
- import { URLPattern } from "urlpattern-polyfill";
4
-
5
- import "./transformers-Dna8Fg7k.js";
6
- import "./docloader-BSCctXal.js";
7
- import "./actor-CgMSXJ7T.js";
8
- import { ContextImpl, FederationImpl, InboxContextImpl, KvSpecDeterminer, createFederation } from "./middleware-CccxNSFX.js";
9
- import "./lookup-Cni8TEY-.js";
10
- import "./key-DxDW5e94.js";
11
- import "./http-BRkdMiKk.js";
12
- import "./proof-CMLfMbze.js";
13
- import "./types-DJjc-Yj8.js";
14
- import "./authdocloader-Cl_S6m_U.js";
15
- import "./vocab-B7bJTtQA.js";
16
-
17
- export { FederationImpl };