@fedify/fedify 1.10.5 → 1.10.7
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.
- package/dist/{actor-CjkHF7Cj.cjs → actor-BGIAXtRd.cjs} +3112 -4674
- package/dist/{actor-Ch9BTg3N.js → actor-C-_2S5Mn.mjs} +8 -15
- package/dist/{actor-CQdxP8N-.js → actor-Cujbx4Zv.js} +1205 -2768
- package/dist/{actor-eeONG_sv.d.ts → actor-DXwwgFeR.d.ts} +3 -3
- package/dist/{actor-D190nbTD.d.cts → actor-DxvGbmjm.d.cts} +3 -3
- package/dist/{assert-MZs1qjMx.js → assert-DikXweDx.mjs} +5 -9
- package/dist/{assert_equals-DSbWqCm3.js → assert_equals-Ew3jOFa3.mjs} +55 -69
- package/dist/{assert_instance_of-DHz7EHNU.js → assert_instance_of-C4Ri6VuN.mjs} +5 -9
- package/dist/{assert_is_error-BPGph1Jx.js → assert_is_error-C50x8tnw.mjs} +5 -9
- package/dist/{assert_not_equals-f3m3epl3.js → assert_not_equals--wG9hV7u.mjs} +6 -13
- package/dist/{assert_rejects-DiIiJbZn.js → assert_rejects-CJC9ThS-.mjs} +6 -11
- package/dist/{assert_throws-BOO88avQ.js → assert_throws-BIL7gChy.mjs} +6 -10
- package/dist/{authdocloader-fR-Fqcpa.js → authdocloader-1Sk2bqFx.mjs} +9 -14
- package/dist/{authdocloader-COFZT9Wh.js → authdocloader-D4Y6iyTF.js} +8 -15
- package/dist/{authdocloader-zc5ibOmU.cjs → authdocloader-DQfruCir.cjs} +14 -22
- package/dist/{builder-YD0q32nG.js → builder-CZbrDRl7.mjs} +31 -40
- package/dist/{client-B3mQJNO7.d.ts → client-D7t26_op.d.ts} +2 -2
- package/dist/{client-BgCucCG7.js → client-Dyb8MI3u.mjs} +11 -15
- package/dist/{client-n6L4GtQL.d.cts → client-yc0Z0P6Y.d.cts} +2 -2
- package/dist/{collection-CSzG2j1P.js → collection-BD6-SZ6O.mjs} +7 -12
- package/dist/compat/mod.cjs +5 -8
- package/dist/compat/mod.d.cts +78 -12
- package/dist/compat/mod.d.ts +78 -12
- package/dist/compat/mod.js +4 -8
- package/dist/compat/transformers.test.mjs +62 -0
- package/dist/{context-Cr5DIxq_.d.ts → context-C6n2yrj0.d.ts} +33 -26
- package/dist/{context-WJoO0SQs.d.cts → context-PfghnHYj.d.cts} +33 -26
- package/dist/{denokv-D0nfNQ1x.js → denokv-NJPMXyK0.mjs} +22 -11
- package/dist/{docloader-BucCRHZI.d.ts → docloader-D7k5A9JP.d.ts} +2 -7
- package/dist/{docloader-ChxNLZAA.d.cts → docloader-DbM94pGY.d.cts} +2 -7
- package/dist/{docloader-BETPdM09.js → docloader-Dtaju6oI.js} +18 -156
- package/dist/{docloader-irBWMSOZ.cjs → docloader-Q3DfzuUi.cjs} +116 -220
- package/dist/{esm-iGH0sRsE.js → esm-DOJg552-.mjs} +49 -85
- package/dist/federation/{builder.test.js → builder.test.mjs} +22 -41
- package/dist/federation/collection.test.d.mts +2 -0
- package/dist/federation/collection.test.mjs +21 -0
- package/dist/federation/handler.test.d.mts +2 -0
- package/dist/federation/{handler.test.js → handler.test.mjs} +29 -58
- package/dist/federation/idempotency.test.d.mts +2 -0
- package/dist/federation/{idempotency.test.js → idempotency.test.mjs} +29 -59
- package/dist/federation/inbox.test.d.mts +2 -0
- package/dist/federation/{inbox.test.js → inbox.test.mjs} +10 -15
- package/dist/federation/keycache.test.d.mts +2 -0
- package/dist/federation/{keycache.test.js → keycache.test.mjs} +13 -18
- package/dist/federation/kv.test.d.mts +2 -0
- package/dist/federation/{kv.test.js → kv.test.mjs} +12 -26
- package/dist/federation/middleware.test.d.mts +2 -0
- package/dist/federation/{middleware.test.js → middleware.test.mjs} +182 -197
- package/dist/federation/mod.cjs +245 -21
- package/dist/federation/mod.d.cts +4 -13
- package/dist/federation/mod.d.ts +4 -13
- package/dist/federation/mod.js +240 -18
- package/dist/federation/mq.test.d.mts +2 -0
- package/dist/federation/{mq.test.js → mq.test.mjs} +23 -38
- package/dist/federation/retry.test.d.mts +2 -0
- package/dist/federation/{retry.test.js → retry.test.mjs} +9 -14
- package/dist/federation/router.test.d.mts +2 -0
- package/dist/federation/{router.test.js → router.test.mjs} +12 -19
- package/dist/federation/send.test.d.mts +2 -0
- package/dist/federation/{send.test.js → send.test.mjs} +24 -34
- package/dist/{http-PgdBoDIj.js → http-BRwSVBn1.mjs} +16 -32
- package/dist/{http-DS9z_HzB.d.ts → http-BYXQvoZQ.d.ts} +5 -9
- package/dist/{http-C_1RU1U_.d.cts → http-CMzg-A9P.d.cts} +5 -9
- package/dist/{http-CQAqR_vx.cjs → http-DCrun8ql.cjs} +51 -68
- package/dist/{http-CxiIW4rD.js → http-DRnRwr3i.js} +17 -33
- package/dist/{inbox-DcDIqTbR.js → inbox-pD1nbb_5.mjs} +17 -25
- package/dist/key-Cmbps6xt.cjs +4 -0
- package/dist/{key-dNFkodH5.cjs → key-DEYIxAFs.cjs} +42 -50
- package/dist/key-DMO0TgTa.mjs +5 -0
- package/dist/{key-I-ibyaZH.js → key-DdL5Oc59.mjs} +12 -18
- package/dist/{key-Cg0kO4dA.js → key-vIzWPiil.js} +19 -19
- package/dist/{keycache-hSs_XFSb.js → keycache-BVR9f06Y.mjs} +6 -10
- package/dist/{keys-CElJez9H.js → keys-Co-0pK8a.mjs} +6 -10
- package/dist/{kv-DipCBaw2.d.ts → kv-C6UC8M9S.d.ts} +1 -1
- package/dist/{kv-BqEOXcZv.d.cts → kv-ClC9WJh5.d.cts} +1 -1
- package/dist/{kv-QzKcOQgP.js → kv-OuT2IU64.mjs} +6 -10
- package/dist/{ld-b16r91YS.js → ld-BFaDk5gX.mjs} +17 -31
- package/dist/{lookup-CySNcNcC.js → lookup-CMYXdjVH.mjs} +8 -17
- package/dist/{lookup-Bfq9Jpm0.cjs → lookup-CZGJqSjm.cjs} +16 -23
- package/dist/{lookup-CiSAeWJl.js → lookup-jlmCTRsO.js} +5 -11
- package/dist/middleware-BWlZ-wms.cjs +4 -0
- package/dist/{middleware-C5emnCh-.js → middleware-BXD5WJbj.mjs} +276 -321
- package/dist/{middleware-Dxo56yae.cjs → middleware-BhMQrJXH.cjs} +494 -547
- package/dist/{middleware-Bs4xDuXR.js → middleware-CmA2E9Bu.js} +349 -393
- package/dist/middleware-H3Ce7yn3.mjs +5 -0
- package/dist/{mod-D5rfgGFE.d.cts → mod-BQ3lrlXU.d.cts} +3 -3
- package/dist/{mod-Dz5Y15Uy.d.cts → mod-C72agZIN.d.cts} +4 -4
- package/dist/{mod-CxMBb_dd.d.cts → mod-CDbqB60V.d.cts} +2 -2
- package/dist/{mod-DS4kJskR.d.ts → mod-Lj0W1nnG.d.ts} +3 -3
- package/dist/{mod-BZfdiPBo.d.ts → mod-_HNKaczF.d.ts} +4 -4
- package/dist/{mod-ChbckRnC.d.ts → mod-lHd-Zdd_.d.ts} +2 -2
- package/dist/mod.cjs +31 -33
- package/dist/mod.d.cts +15 -17
- package/dist/mod.d.ts +15 -17
- package/dist/mod.js +20 -23
- package/dist/{mq-B7R1Q-M5.d.cts → mq-CrItclRD.d.cts} +1 -1
- package/dist/{mq-CRGm1e_F.d.ts → mq-D_ZZRdby.d.ts} +1 -1
- package/dist/nodeinfo/client.test.d.mts +2 -0
- package/dist/nodeinfo/{client.test.js → client.test.mjs} +23 -45
- package/dist/nodeinfo/handler.test.d.mts +2 -0
- package/dist/nodeinfo/{handler.test.js → handler.test.mjs} +14 -43
- package/dist/nodeinfo/mod.cjs +5 -9
- package/dist/nodeinfo/mod.d.cts +2 -5
- package/dist/nodeinfo/mod.d.ts +2 -5
- package/dist/nodeinfo/mod.js +4 -9
- package/dist/nodeinfo/semver.test.d.mts +2 -0
- package/dist/nodeinfo/{semver.test.js → semver.test.mjs} +28 -51
- package/dist/nodeinfo/types.test.d.mts +2 -0
- package/dist/nodeinfo/{types.test.js → types.test.mjs} +10 -21
- package/dist/otel/exporter.test.d.mts +2 -0
- package/dist/otel/{exporter.test.js → exporter.test.mjs} +122 -180
- package/dist/otel/mod.cjs +16 -22
- package/dist/otel/mod.d.cts +2 -2
- package/dist/otel/mod.d.ts +2 -2
- package/dist/otel/mod.js +9 -16
- package/dist/{otel-Chy5T2Xh.js → otel-0v4Zy01l.mjs} +5 -10
- package/dist/{owner-AcrG3Xz1.d.cts → owner-0yNTyGMb.d.cts} +4 -4
- package/dist/{owner-Bs-sPbHX.js → owner-CNdS8zxf.mjs} +11 -16
- package/dist/{owner-8NMhXwJd.d.ts → owner-CPEbNpnZ.d.ts} +4 -4
- package/dist/{proof-SgRikE_Y.js → proof-Co7YmDpv.mjs} +20 -32
- package/dist/{proof-flD2DeA-.js → proof-DHPbi_Mx.js} +34 -60
- package/dist/{proof-BvQS195q.cjs → proof-DcPdtve2.cjs} +115 -140
- package/dist/{retry-D4GJ670a.js → retry-Ddbq3AcK.mjs} +4 -7
- package/dist/rolldown-runtime-C7fyD9f2.js +15 -0
- package/dist/runtime/authdocloader.test.d.mts +2 -0
- package/dist/runtime/{authdocloader.test.js → authdocloader.test.mjs} +16 -28
- package/dist/runtime/docloader.test.d.mts +2 -0
- package/dist/runtime/{docloader.test.js → docloader.test.mjs} +55 -77
- package/dist/runtime/key.test.d.mts +2 -0
- package/dist/runtime/{key.test.js → key.test.mjs} +27 -57
- package/dist/runtime/langstr.test.d.mts +2 -0
- package/dist/runtime/{langstr.test.js → langstr.test.mjs} +9 -19
- package/dist/runtime/link.test.d.mts +2 -0
- package/dist/runtime/{link.test.js → link.test.mjs} +7 -11
- package/dist/runtime/mod.cjs +7 -13
- package/dist/runtime/mod.d.cts +103 -6
- package/dist/runtime/mod.d.ts +103 -6
- package/dist/runtime/mod.js +6 -13
- package/dist/runtime/multibase/multibase.test.d.mts +2 -0
- package/dist/runtime/multibase/{multibase.test.js → multibase.test.mjs} +16 -33
- package/dist/runtime/url.test.d.mts +2 -0
- package/dist/runtime/{url.test.js → url.test.mjs} +10 -15
- package/dist/{semver-dArNLkR9.js → semver-CgD82xxg.mjs} +13 -28
- package/dist/{send-C0gFHa2i.js → send-BRCWNcMa.mjs} +7 -12
- package/dist/sig/http.test.d.mts +2 -0
- package/dist/sig/{http.test.js → http.test.mjs} +119 -203
- package/dist/sig/key.test.d.mts +2 -0
- package/dist/sig/{key.test.js → key.test.mjs} +13 -22
- package/dist/sig/ld.test.d.mts +2 -0
- package/dist/sig/{ld.test.js → ld.test.mjs} +24 -39
- package/dist/sig/mod.cjs +7 -13
- package/dist/sig/mod.d.cts +3 -7
- package/dist/sig/mod.d.ts +3 -7
- package/dist/sig/mod.js +6 -13
- package/dist/sig/owner.test.d.mts +2 -0
- package/dist/sig/{owner.test.js → owner.test.mjs} +23 -39
- package/dist/sig/proof.test.d.mts +2 -0
- package/dist/sig/{proof.test.js → proof.test.mjs} +18 -31
- package/dist/{std__assert-X-_kMxKM.js → std__assert-2v7gYiZp.mjs} +13 -24
- package/dist/testing/docloader.test.d.mts +2 -0
- package/dist/testing/docloader.test.mjs +12 -0
- package/dist/testing/{mod.d.ts → mod.d.mts} +371 -541
- package/dist/testing/mod.mjs +5 -0
- package/dist/{testing-C1GIraJh.js → testing-BLIh1cXz.mjs} +27 -35
- package/dist/{transformers-BFT6d7J5.js → transformers-BV4OeK9o.js} +3 -7
- package/dist/{transformers-CoBS-oFG.cjs → transformers-CLtJ5H8o.cjs} +20 -25
- package/dist/{types-BgUCCngg.cjs → types-B34v-m2N.cjs} +45 -64
- package/dist/{types-BIgY6c-l.js → types-CAnkAQGM.mjs} +5 -9
- package/dist/{types-Bu-epI-z.js → types-CXZk86AG.js} +18 -36
- package/dist/vocab/actor.test.d.mts +2 -0
- package/dist/vocab/{actor.test.js → actor.test.mjs} +308 -550
- package/dist/vocab/cjs.test.d.mts +2 -0
- package/dist/vocab/cjs.test.mjs +14 -0
- package/dist/vocab/lookup.test.d.mts +2 -0
- package/dist/vocab/{lookup.test.js → lookup.test.mjs} +34 -51
- package/dist/vocab/mod.cjs +256 -16
- package/dist/vocab/mod.d.cts +3 -5
- package/dist/vocab/mod.d.ts +3 -5
- package/dist/vocab/mod.js +249 -10
- package/dist/vocab/type.test.d.mts +2 -0
- package/dist/vocab/type.test.mjs +16 -0
- package/dist/vocab/vocab.test.d.mts +2 -0
- package/dist/vocab/{vocab.test.js → vocab.test.mjs} +178 -311
- package/dist/{vocab-BASuuzcJ.d.ts → vocab-DaT4UsJF.d.ts} +2 -2
- package/dist/{vocab-DPMmFPJ1.d.cts → vocab-DnlmNyXi.d.cts} +2 -2
- package/dist/{type-DUhon7qK.js → vocab-rT_94Pke.mjs} +1178 -2876
- package/dist/webfinger/handler.test.d.mts +2 -0
- package/dist/webfinger/{handler.test.js → handler.test.mjs} +23 -56
- package/dist/webfinger/lookup.test.d.mts +2 -0
- package/dist/webfinger/{lookup.test.js → lookup.test.mjs} +13 -27
- package/dist/webfinger/mod.cjs +5 -9
- package/dist/webfinger/mod.d.cts +1 -3
- package/dist/webfinger/mod.d.ts +1 -3
- package/dist/webfinger/mod.js +4 -9
- package/dist/x/cfworkers.cjs +25 -14
- package/dist/x/cfworkers.d.cts +33 -6
- package/dist/x/cfworkers.d.ts +33 -6
- package/dist/x/cfworkers.js +22 -12
- package/dist/x/cfworkers.test.d.mts +2 -0
- package/dist/x/{cfworkers.test.js → cfworkers.test.mjs} +28 -26
- package/dist/x/hono.cjs +25 -14
- package/dist/x/hono.d.cts +1 -11
- package/dist/x/hono.d.ts +1 -11
- package/dist/x/hono.js +22 -12
- package/dist/x/sveltekit.cjs +23 -12
- package/dist/x/sveltekit.d.cts +1 -11
- package/dist/x/sveltekit.d.ts +1 -11
- package/dist/x/sveltekit.js +20 -10
- package/package.json +2 -2
- package/dist/chunk-DqRYRqnO.cjs +0 -34
- package/dist/compat/transformers.test.d.ts +0 -3
- package/dist/compat/transformers.test.js +0 -86
- package/dist/compat-DmDDELst.cjs +0 -4
- package/dist/compat-nxUqe4Z-.js +0 -4
- package/dist/federation/builder.test.d.ts +0 -3
- package/dist/federation/collection.test.d.ts +0 -3
- package/dist/federation/collection.test.js +0 -35
- package/dist/federation/handler.test.d.ts +0 -3
- package/dist/federation/idempotency.test.d.ts +0 -3
- package/dist/federation/inbox.test.d.ts +0 -3
- package/dist/federation/keycache.test.d.ts +0 -3
- package/dist/federation/kv.test.d.ts +0 -3
- package/dist/federation/middleware.test.d.ts +0 -3
- package/dist/federation/mq.test.d.ts +0 -3
- package/dist/federation/retry.test.d.ts +0 -3
- package/dist/federation/router.test.d.ts +0 -3
- package/dist/federation/send.test.d.ts +0 -3
- package/dist/federation-C15gGOh1.cjs +0 -266
- package/dist/federation-K-xsO03l.js +0 -248
- package/dist/key-Bnod5wJl.js +0 -10
- package/dist/key-C6swTX71.js +0 -10
- package/dist/key-_Uq8gkmM.cjs +0 -10
- package/dist/middleware-BWsOtDIF.cjs +0 -17
- package/dist/middleware-Bm4bJzjg.js +0 -26
- package/dist/middleware-BvODpE_U.js +0 -17
- package/dist/mod-C2tOeRkN.d.cts +0 -1
- package/dist/mod-CD7gfdq3.d.ts +0 -104
- package/dist/mod-CnULG6Aa.d.ts +0 -82
- package/dist/mod-FZd39qVq.d.cts +0 -1
- package/dist/mod-JUhOKMHj.d.cts +0 -102
- package/dist/mod-OQfb33eH.d.cts +0 -80
- package/dist/nodeinfo/client.test.d.ts +0 -3
- package/dist/nodeinfo/handler.test.d.ts +0 -3
- package/dist/nodeinfo/semver.test.d.ts +0 -3
- package/dist/nodeinfo/types.test.d.ts +0 -3
- package/dist/nodeinfo-Co9lJrWl.cjs +0 -4
- package/dist/nodeinfo-DfycQ8Wf.js +0 -4
- package/dist/otel/exporter.test.d.ts +0 -3
- package/dist/runtime/authdocloader.test.d.ts +0 -3
- package/dist/runtime/docloader.test.d.ts +0 -3
- package/dist/runtime/key.test.d.ts +0 -3
- package/dist/runtime/langstr.test.d.ts +0 -3
- package/dist/runtime/link.test.d.ts +0 -3
- package/dist/runtime/multibase/multibase.test.d.ts +0 -3
- package/dist/runtime/url.test.d.ts +0 -3
- package/dist/runtime-C58AJWSv.cjs +0 -4
- package/dist/runtime-DPYEDf-o.js +0 -4
- package/dist/sig/http.test.d.ts +0 -3
- package/dist/sig/key.test.d.ts +0 -3
- package/dist/sig/ld.test.d.ts +0 -3
- package/dist/sig/owner.test.d.ts +0 -3
- package/dist/sig/proof.test.d.ts +0 -3
- package/dist/sig-ByHXzqUi.cjs +0 -4
- package/dist/sig-Cj3tk-ig.js +0 -4
- package/dist/testing/docloader.test.d.ts +0 -3
- package/dist/testing/docloader.test.js +0 -24
- package/dist/testing/mod.js +0 -10
- package/dist/vocab/actor.test.d.ts +0 -3
- package/dist/vocab/lookup.test.d.ts +0 -3
- package/dist/vocab/type.test.d.ts +0 -3
- package/dist/vocab/type.test.js +0 -25
- package/dist/vocab/vocab.test.d.ts +0 -3
- package/dist/vocab-5i6DEIi6.cjs +0 -294
- package/dist/vocab-CBavAdew.js +0 -258
- package/dist/webfinger/handler.test.d.ts +0 -3
- package/dist/webfinger/lookup.test.d.ts +0 -3
- package/dist/webfinger-BjOEdFPs.cjs +0 -4
- package/dist/webfinger-De_bU0iE.js +0 -4
- package/dist/x/cfworkers.test.d.ts +0 -3
- /package/dist/{mod-1pDWKvUL.d.ts → compat/transformers.test.d.mts} +0 -0
- /package/dist/{mod-g0xFzAP9.d.ts → federation/builder.test.d.mts} +0 -0
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import "@js-temporal/polyfill";
|
|
2
|
+
import "urlpattern-polyfill";
|
|
3
|
+
globalThis.addEventListener = () => {};
|
|
4
|
+
import { t as test } from "../testing-BLIh1cXz.mjs";
|
|
5
|
+
import { createRequire } from "node:module";
|
|
6
|
+
import { strictEqual } from "node:assert";
|
|
7
|
+
//#region src/vocab/cjs.test.ts
|
|
8
|
+
test("CommonJS vocab entry exports Object", { ignore: "Deno" in globalThis }, () => {
|
|
9
|
+
const vocab = createRequire(import.meta.url)("./mod.cjs");
|
|
10
|
+
strictEqual(typeof vocab.Object, "function");
|
|
11
|
+
strictEqual(typeof vocab.Update, "function");
|
|
12
|
+
});
|
|
13
|
+
//#endregion
|
|
14
|
+
export {};
|
|
@@ -1,23 +1,17 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
import {
|
|
7
|
-
import { assertEquals } from "../assert_equals-
|
|
8
|
-
import
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import "../
|
|
13
|
-
import {
|
|
14
|
-
import "../assert_is_error-BPGph1Jx.js";
|
|
15
|
-
import "../assert_not_equals-f3m3epl3.js";
|
|
16
|
-
import "../assert_throws-BOO88avQ.js";
|
|
17
|
-
import { createTestTracerProvider } from "../otel-Chy5T2Xh.js";
|
|
18
|
-
import { esm_default } from "../esm-iGH0sRsE.js";
|
|
1
|
+
import "@js-temporal/polyfill";
|
|
2
|
+
import "urlpattern-polyfill";
|
|
3
|
+
globalThis.addEventListener = () => {};
|
|
4
|
+
import { C as Person, _ as Note, i as Collection, v as Object$1 } from "../vocab-rT_94Pke.mjs";
|
|
5
|
+
import { n as traverseCollection, t as lookupObject } from "../lookup-CMYXdjVH.mjs";
|
|
6
|
+
import { a as mockDocumentLoader, t as test } from "../testing-BLIh1cXz.mjs";
|
|
7
|
+
import { t as assertEquals } from "../assert_equals-Ew3jOFa3.mjs";
|
|
8
|
+
import "../std__assert-2v7gYiZp.mjs";
|
|
9
|
+
import { t as assertRejects } from "../assert_rejects-CJC9ThS-.mjs";
|
|
10
|
+
import { t as assertInstanceOf } from "../assert_instance_of-C4Ri6VuN.mjs";
|
|
11
|
+
import { t as assert } from "../assert-DikXweDx.mjs";
|
|
12
|
+
import { t as esm_default } from "../esm-DOJg552-.mjs";
|
|
13
|
+
import { t as createTestTracerProvider } from "../otel-0v4Zy01l.mjs";
|
|
19
14
|
import { deepStrictEqual } from "node:assert";
|
|
20
|
-
|
|
21
15
|
//#region src/vocab/lookup.test.ts
|
|
22
16
|
test("lookupObject()", {
|
|
23
17
|
sanitizeResources: false,
|
|
@@ -53,10 +47,8 @@ test("lookupObject()", {
|
|
|
53
47
|
assertInstanceOf(person, Person);
|
|
54
48
|
assertEquals(person.id, new URL("https://example.com/person"));
|
|
55
49
|
assertEquals(person.name, "John Doe");
|
|
56
|
-
|
|
57
|
-
assertEquals(
|
|
58
|
-
const person3 = await lookupObject("acct:johndoe@example.com", options);
|
|
59
|
-
assertEquals(person3, person);
|
|
50
|
+
assertEquals(await lookupObject("johndoe@example.com", options), person);
|
|
51
|
+
assertEquals(await lookupObject("acct:johndoe@example.com", options), person);
|
|
60
52
|
});
|
|
61
53
|
await t.step("object", async () => {
|
|
62
54
|
const object = await lookupObject("https://example.com/object", options);
|
|
@@ -141,11 +133,10 @@ test("lookupObject()", {
|
|
|
141
133
|
await t.step("cancellation with immediate abort", async () => {
|
|
142
134
|
const controller = new AbortController();
|
|
143
135
|
controller.abort();
|
|
144
|
-
|
|
136
|
+
assertEquals(await lookupObject("johndoe@example.com", {
|
|
145
137
|
...options,
|
|
146
138
|
signal: controller.signal
|
|
147
|
-
});
|
|
148
|
-
assertEquals(result, null);
|
|
139
|
+
}), null);
|
|
149
140
|
});
|
|
150
141
|
esm_default.removeRoutes();
|
|
151
142
|
esm_default.get("https://example.com/slow-object", () => new Promise((resolve) => {
|
|
@@ -225,11 +216,10 @@ test("FEP-fe34: lookupObject() cross-origin security", {
|
|
|
225
216
|
};
|
|
226
217
|
throw new Error(`Unexpected URL: ${url}`);
|
|
227
218
|
};
|
|
228
|
-
|
|
219
|
+
assertEquals(await lookupObject("https://example.com/note", {
|
|
229
220
|
documentLoader: crossOriginDocumentLoader,
|
|
230
221
|
contextLoader: mockDocumentLoader
|
|
231
|
-
});
|
|
232
|
-
assertEquals(result, null);
|
|
222
|
+
}), null);
|
|
233
223
|
});
|
|
234
224
|
await t.step("crossOrigin: throw - throws error for cross-origin objects", async () => {
|
|
235
225
|
const crossOriginDocumentLoader = async (url) => {
|
|
@@ -340,11 +330,10 @@ test("FEP-fe34: lookupObject() cross-origin security", {
|
|
|
340
330
|
};
|
|
341
331
|
throw new Error(`Unexpected URL: ${url}`);
|
|
342
332
|
};
|
|
343
|
-
|
|
333
|
+
assertEquals(await lookupObject("@user@example.com", {
|
|
344
334
|
documentLoader: webfingerDocumentLoader,
|
|
345
335
|
contextLoader: mockDocumentLoader
|
|
346
|
-
});
|
|
347
|
-
assertEquals(result1, null);
|
|
336
|
+
}), null);
|
|
348
337
|
await assertRejects(() => lookupObject("@user@example.com", {
|
|
349
338
|
documentLoader: webfingerDocumentLoader,
|
|
350
339
|
contextLoader: mockDocumentLoader,
|
|
@@ -374,11 +363,10 @@ test("FEP-fe34: lookupObject() cross-origin security", {
|
|
|
374
363
|
};
|
|
375
364
|
throw new Error(`Unexpected URL: ${url}`);
|
|
376
365
|
};
|
|
377
|
-
|
|
366
|
+
assertEquals(await lookupObject("https://api.example.com/note", {
|
|
378
367
|
documentLoader: subdomainDocumentLoader,
|
|
379
368
|
contextLoader: mockDocumentLoader
|
|
380
|
-
});
|
|
381
|
-
assertEquals(result, null);
|
|
369
|
+
}), null);
|
|
382
370
|
});
|
|
383
371
|
await t.step("different port same-origin check", async () => {
|
|
384
372
|
const differentPortDocumentLoader = async (url) => {
|
|
@@ -394,11 +382,10 @@ test("FEP-fe34: lookupObject() cross-origin security", {
|
|
|
394
382
|
};
|
|
395
383
|
throw new Error(`Unexpected URL: ${url}`);
|
|
396
384
|
};
|
|
397
|
-
|
|
385
|
+
assertEquals(await lookupObject("https://example.com:8080/note", {
|
|
398
386
|
documentLoader: differentPortDocumentLoader,
|
|
399
387
|
contextLoader: mockDocumentLoader
|
|
400
|
-
});
|
|
401
|
-
assertEquals(result, null);
|
|
388
|
+
}), null);
|
|
402
389
|
});
|
|
403
390
|
await t.step("protocol difference same-origin check", async () => {
|
|
404
391
|
const differentProtocolDocumentLoader = async (url) => {
|
|
@@ -414,22 +401,20 @@ test("FEP-fe34: lookupObject() cross-origin security", {
|
|
|
414
401
|
};
|
|
415
402
|
throw new Error(`Unexpected URL: ${url}`);
|
|
416
403
|
};
|
|
417
|
-
|
|
404
|
+
assertEquals(await lookupObject("https://example.com/note", {
|
|
418
405
|
documentLoader: differentProtocolDocumentLoader,
|
|
419
406
|
contextLoader: mockDocumentLoader
|
|
420
|
-
});
|
|
421
|
-
assertEquals(result, null);
|
|
407
|
+
}), null);
|
|
422
408
|
});
|
|
423
409
|
await t.step("error handling with crossOrigin throw option", async () => {
|
|
424
410
|
const errorDocumentLoader = async (_url) => {
|
|
425
411
|
throw new Error("Network error");
|
|
426
412
|
};
|
|
427
|
-
|
|
413
|
+
assertEquals(await lookupObject("https://example.com/note", {
|
|
428
414
|
documentLoader: errorDocumentLoader,
|
|
429
415
|
contextLoader: mockDocumentLoader,
|
|
430
416
|
crossOrigin: "throw"
|
|
431
|
-
});
|
|
432
|
-
assertEquals(result, null);
|
|
417
|
+
}), null);
|
|
433
418
|
});
|
|
434
419
|
await t.step("malformed JSON handling with cross-origin policy", async () => {
|
|
435
420
|
const malformedJsonDocumentLoader = async (url) => {
|
|
@@ -459,12 +444,11 @@ test("FEP-fe34: lookupObject() cross-origin security", {
|
|
|
459
444
|
});
|
|
460
445
|
test("lookupObject() records OpenTelemetry span events", async () => {
|
|
461
446
|
const [tracerProvider, exporter] = createTestTracerProvider();
|
|
462
|
-
|
|
447
|
+
assertInstanceOf(await lookupObject("https://example.com/object", {
|
|
463
448
|
documentLoader: mockDocumentLoader,
|
|
464
449
|
contextLoader: mockDocumentLoader,
|
|
465
450
|
tracerProvider
|
|
466
|
-
});
|
|
467
|
-
assertInstanceOf(object, Object$1);
|
|
451
|
+
}), Object$1);
|
|
468
452
|
const spans = exporter.getSpans("activitypub.lookup_object");
|
|
469
453
|
assertEquals(spans.length, 1);
|
|
470
454
|
const span = spans[0];
|
|
@@ -475,8 +459,7 @@ test("lookupObject() records OpenTelemetry span events", async () => {
|
|
|
475
459
|
assert(event.attributes != null);
|
|
476
460
|
assert(typeof event.attributes["activitypub.object.type"] === "string");
|
|
477
461
|
assert(typeof event.attributes["activitypub.object.json"] === "string");
|
|
478
|
-
|
|
479
|
-
assertEquals(recordedObject.id, "https://example.com/object");
|
|
462
|
+
assertEquals(JSON.parse(event.attributes["activitypub.object.json"]).id, "https://example.com/object");
|
|
480
463
|
});
|
|
481
|
-
|
|
482
|
-
|
|
464
|
+
//#endregion
|
|
465
|
+
export {};
|
package/dist/vocab/mod.cjs
CHANGED
|
@@ -1,12 +1,252 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
require(
|
|
6
|
-
const
|
|
7
|
-
require(
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
const { Temporal } = require("@js-temporal/polyfill");
|
|
2
|
+
const { URLPattern } = require("urlpattern-polyfill");
|
|
3
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
4
|
+
const require_docloader = require("../docloader-Q3DfzuUi.cjs");
|
|
5
|
+
const require_actor = require("../actor-BGIAXtRd.cjs");
|
|
6
|
+
const require_lookup = require("../lookup-CZGJqSjm.cjs");
|
|
7
|
+
let _logtape_logtape = require("@logtape/logtape");
|
|
8
|
+
let _opentelemetry_api = require("@opentelemetry/api");
|
|
9
|
+
let es_toolkit = require("es-toolkit");
|
|
10
|
+
//#region src/vocab/handle.ts
|
|
11
|
+
/**
|
|
12
|
+
* Regular expression to match a fediverse handle in the format `@user@server`
|
|
13
|
+
* or `user@server`. The `user` part can contain alphanumeric characters and
|
|
14
|
+
* some special characters except `@`. The `server` part is all characters
|
|
15
|
+
* after the `@` symbol in the middle.
|
|
16
|
+
*/
|
|
17
|
+
const handleRegexp = /^@?((?:[-A-Za-z0-9._~!$&'()*+,;=]|%[A-Fa-f0-9]{2})+)@([^@]+)$/;
|
|
18
|
+
/**
|
|
19
|
+
* Parses a fediverse handle in the format `@user@server` or `user@server`.
|
|
20
|
+
* The `user` part can contain alphanumeric characters and some special
|
|
21
|
+
* characters except `@`. The `server` part is all characters after the `@`
|
|
22
|
+
* symbol in the middle.
|
|
23
|
+
*
|
|
24
|
+
* @example
|
|
25
|
+
* ```typescript
|
|
26
|
+
* const handle = parseFediverseHandle("@username@example.com");
|
|
27
|
+
* console.log(handle?.username); // "username"
|
|
28
|
+
* console.log(handle?.host); // "example.com"
|
|
29
|
+
* ```
|
|
30
|
+
*
|
|
31
|
+
* @param handle - The fediverse handle string to parse.
|
|
32
|
+
* @returns A {@link FediverseHandle} object with `username` and `host`
|
|
33
|
+
* if the input is valid; otherwise `null`.
|
|
34
|
+
* @since 1.8.0
|
|
35
|
+
*/
|
|
36
|
+
function parseFediverseHandle(handle) {
|
|
37
|
+
const match = handleRegexp.exec(handle);
|
|
38
|
+
if (match) return {
|
|
39
|
+
username: match[1],
|
|
40
|
+
host: match[2]
|
|
41
|
+
};
|
|
42
|
+
return null;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Checks if a string is a valid fediverse handle in the format `@user@server`
|
|
46
|
+
* or `user@server`. The `user` part can contain alphanumeric characters and
|
|
47
|
+
* some special characters except `@`. The `server` part is all characters
|
|
48
|
+
* after the `@` symbol in the middle.
|
|
49
|
+
*
|
|
50
|
+
* @example
|
|
51
|
+
* ```typescript
|
|
52
|
+
* console.log(isFediverseHandle("@username@example.com")); // true
|
|
53
|
+
* console.log(isFediverseHandle("username@example.com")); // true
|
|
54
|
+
* console.log(isFediverseHandle("@username@")); // false
|
|
55
|
+
* ```
|
|
56
|
+
*
|
|
57
|
+
* @param handle - The string to test as a fediverse handle.
|
|
58
|
+
* @returns `true` if the string matches the fediverse handle pattern;
|
|
59
|
+
* otherwise `false`.
|
|
60
|
+
* @since 1.8.0
|
|
61
|
+
*/
|
|
62
|
+
function isFediverseHandle(handle) {
|
|
63
|
+
return handleRegexp.test(handle);
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Converts a fediverse handle in the format `@user@server` or `user@server`
|
|
67
|
+
* to an `acct:` URI, which is a URL-like identifier for ActivityPub actors.
|
|
68
|
+
*
|
|
69
|
+
* @example
|
|
70
|
+
* ```typescript
|
|
71
|
+
* const identifier = toAcctUrl("@username@example.com");
|
|
72
|
+
* console.log(identifier?.href); // "acct:username@example.com"
|
|
73
|
+
* ```
|
|
74
|
+
*
|
|
75
|
+
* @param handle - The fediverse handle string to convert.
|
|
76
|
+
* @returns A `URL` object representing the `acct:` URI if conversion succeeds;
|
|
77
|
+
* otherwise `null`.
|
|
78
|
+
* @since 1.8.0
|
|
79
|
+
*/
|
|
80
|
+
function toAcctUrl(handle) {
|
|
81
|
+
const parsed = parseFediverseHandle(handle);
|
|
82
|
+
if (!parsed) return null;
|
|
83
|
+
return new URL(`acct:${parsed.username}@${parsed.host}`);
|
|
84
|
+
}
|
|
85
|
+
//#endregion
|
|
86
|
+
//#region src/vocab/lookup.ts
|
|
87
|
+
const logger = (0, _logtape_logtape.getLogger)([
|
|
88
|
+
"fedify",
|
|
89
|
+
"vocab",
|
|
90
|
+
"lookup"
|
|
91
|
+
]);
|
|
92
|
+
/**
|
|
93
|
+
* Looks up an ActivityStreams object by its URI (including `acct:` URIs)
|
|
94
|
+
* or a fediverse handle (e.g., `@user@server` or `user@server`).
|
|
95
|
+
*
|
|
96
|
+
* @example
|
|
97
|
+
* ``` typescript
|
|
98
|
+
* // Look up an actor by its fediverse handle:
|
|
99
|
+
* await lookupObject("@hongminhee@fosstodon.org");
|
|
100
|
+
* // returning a `Person` object.
|
|
101
|
+
*
|
|
102
|
+
* // A fediverse handle can omit the leading '@':
|
|
103
|
+
* await lookupObject("hongminhee@fosstodon.org");
|
|
104
|
+
* // returning a `Person` object.
|
|
105
|
+
*
|
|
106
|
+
* // A `acct:` URI can be used as well:
|
|
107
|
+
* await lookupObject("acct:hongminhee@fosstodon.org");
|
|
108
|
+
* // returning a `Person` object.
|
|
109
|
+
*
|
|
110
|
+
* // Look up an object by its URI:
|
|
111
|
+
* await lookupObject("https://todon.eu/@hongminhee/112060633798771581");
|
|
112
|
+
* // returning a `Note` object.
|
|
113
|
+
*
|
|
114
|
+
* // It can be a `URL` object as well:
|
|
115
|
+
* await lookupObject(new URL("https://todon.eu/@hongminhee/112060633798771581"));
|
|
116
|
+
* // returning a `Note` object.
|
|
117
|
+
* ```
|
|
118
|
+
*
|
|
119
|
+
* @param identifier The URI or fediverse handle to look up.
|
|
120
|
+
* @param options Lookup options.
|
|
121
|
+
* @returns The object, or `null` if not found.
|
|
122
|
+
* @since 0.2.0
|
|
123
|
+
*/
|
|
124
|
+
async function lookupObject(identifier, options = {}) {
|
|
125
|
+
return await (options.tracerProvider ?? _opentelemetry_api.trace.getTracerProvider()).getTracer(require_docloader.name, require_docloader.version).startActiveSpan("activitypub.lookup_object", async (span) => {
|
|
126
|
+
try {
|
|
127
|
+
const result = await lookupObjectInternal(identifier, options);
|
|
128
|
+
if (result == null) span.setStatus({ code: _opentelemetry_api.SpanStatusCode.ERROR });
|
|
129
|
+
else {
|
|
130
|
+
if (result.id != null) span.setAttribute("activitypub.object.id", result.id.href);
|
|
131
|
+
span.setAttribute("activitypub.object.type", require_actor.getTypeId(result).href);
|
|
132
|
+
if (result.replyTargetIds.length > 0) span.setAttribute("activitypub.object.in_reply_to", result.replyTargetIds.map((id) => id.href));
|
|
133
|
+
span.addEvent("activitypub.object.fetched", {
|
|
134
|
+
"activitypub.object.type": require_actor.getTypeId(result).href,
|
|
135
|
+
"activitypub.object.json": JSON.stringify(await result.toJsonLd(options))
|
|
136
|
+
});
|
|
137
|
+
}
|
|
138
|
+
return result;
|
|
139
|
+
} catch (error) {
|
|
140
|
+
span.recordException(error);
|
|
141
|
+
span.setStatus({
|
|
142
|
+
code: _opentelemetry_api.SpanStatusCode.ERROR,
|
|
143
|
+
message: String(error)
|
|
144
|
+
});
|
|
145
|
+
throw error;
|
|
146
|
+
} finally {
|
|
147
|
+
span.end();
|
|
148
|
+
}
|
|
149
|
+
});
|
|
150
|
+
}
|
|
151
|
+
async function lookupObjectInternal(identifier, options = {}) {
|
|
152
|
+
const documentLoader = options.documentLoader ?? require_docloader.getDocumentLoader({ userAgent: options.userAgent });
|
|
153
|
+
if (typeof identifier === "string") identifier = toAcctUrl(identifier) ?? new URL(identifier);
|
|
154
|
+
let remoteDoc = null;
|
|
155
|
+
if (identifier.protocol === "http:" || identifier.protocol === "https:") try {
|
|
156
|
+
remoteDoc = await documentLoader(identifier.href, { signal: options.signal });
|
|
157
|
+
} catch (error) {
|
|
158
|
+
logger.debug("Failed to fetch remote document:\n{error}", { error });
|
|
159
|
+
}
|
|
160
|
+
if (remoteDoc == null) {
|
|
161
|
+
const jrd = await require_lookup.lookupWebFinger(identifier, {
|
|
162
|
+
userAgent: options.userAgent,
|
|
163
|
+
tracerProvider: options.tracerProvider,
|
|
164
|
+
allowPrivateAddress: "allowPrivateAddress" in options && options.allowPrivateAddress === true,
|
|
165
|
+
signal: options.signal
|
|
166
|
+
});
|
|
167
|
+
if (jrd?.links == null) return null;
|
|
168
|
+
for (const l of jrd.links) {
|
|
169
|
+
if (l.type !== "application/activity+json" && !l.type?.match(/application\/ld\+json;\s*profile="https:\/\/www.w3.org\/ns\/activitystreams"/) || l.rel !== "self" || l.href == null) continue;
|
|
170
|
+
try {
|
|
171
|
+
remoteDoc = await documentLoader(l.href, { signal: options.signal });
|
|
172
|
+
break;
|
|
173
|
+
} catch (error) {
|
|
174
|
+
logger.debug("Failed to fetch remote document:\n{error}", { error });
|
|
175
|
+
continue;
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
if (remoteDoc == null) return null;
|
|
180
|
+
let object;
|
|
181
|
+
try {
|
|
182
|
+
object = await require_actor.Object.fromJsonLd(remoteDoc.document, {
|
|
183
|
+
documentLoader,
|
|
184
|
+
contextLoader: options.contextLoader,
|
|
185
|
+
tracerProvider: options.tracerProvider,
|
|
186
|
+
baseUrl: new URL(remoteDoc.documentUrl)
|
|
187
|
+
});
|
|
188
|
+
} catch (error) {
|
|
189
|
+
if (error instanceof TypeError) {
|
|
190
|
+
logger.debug("Failed to parse JSON-LD document: {error}\n{document}", {
|
|
191
|
+
...remoteDoc,
|
|
192
|
+
error
|
|
193
|
+
});
|
|
194
|
+
return null;
|
|
195
|
+
}
|
|
196
|
+
throw error;
|
|
197
|
+
}
|
|
198
|
+
if (options.crossOrigin !== "trust" && object.id != null && object.id.origin !== new URL(remoteDoc.documentUrl).origin) {
|
|
199
|
+
if (options.crossOrigin === "throw") throw new Error(`The object's @id (${object.id.href}) has a different origin than the document URL (${remoteDoc.documentUrl}); refusing to return the object. If you want to bypass this check and are aware of the security implications, set the crossOrigin option to "trust".`);
|
|
200
|
+
logger.warn("The object's @id ({objectId}) has a different origin than the document URL ({documentUrl}); refusing to return the object. If you want to bypass this check and are aware of the security implications, set the crossOrigin option to \"trust\".", {
|
|
201
|
+
...remoteDoc,
|
|
202
|
+
objectId: object.id.href
|
|
203
|
+
});
|
|
204
|
+
return null;
|
|
205
|
+
}
|
|
206
|
+
return object;
|
|
207
|
+
}
|
|
208
|
+
/**
|
|
209
|
+
* Traverses a collection, yielding each item in the collection.
|
|
210
|
+
* If the collection is paginated, it will fetch the next page
|
|
211
|
+
* automatically.
|
|
212
|
+
*
|
|
213
|
+
* @example
|
|
214
|
+
* ``` typescript
|
|
215
|
+
* const collection = await lookupObject(collectionUrl);
|
|
216
|
+
* if (collection instanceof Collection) {
|
|
217
|
+
* for await (const item of traverseCollection(collection)) {
|
|
218
|
+
* console.log(item.id?.href);
|
|
219
|
+
* }
|
|
220
|
+
* }
|
|
221
|
+
* ```
|
|
222
|
+
*
|
|
223
|
+
* @param collection The collection to traverse.
|
|
224
|
+
* @param options Options for traversing the collection.
|
|
225
|
+
* @returns An async iterable of each item in the collection.
|
|
226
|
+
* @since 1.1.0
|
|
227
|
+
*/
|
|
228
|
+
async function* traverseCollection(collection, options = {}) {
|
|
229
|
+
const interval = Temporal.Duration.from(options.interval ?? { seconds: 0 }).total("millisecond");
|
|
230
|
+
let page = await collection.getFirst(options);
|
|
231
|
+
if (page == null) for await (const item of collection.getItems(options)) yield item;
|
|
232
|
+
else while (page != null) {
|
|
233
|
+
for await (const item of page.getItems(options)) yield item;
|
|
234
|
+
if (interval > 0) await (0, es_toolkit.delay)(interval);
|
|
235
|
+
page = await page.getNext(options);
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
//#endregion
|
|
239
|
+
//#region src/vocab/constants.ts
|
|
240
|
+
/**
|
|
241
|
+
* The special public collection for [public addressing]. *Do not mutate this
|
|
242
|
+
* object.*
|
|
243
|
+
*
|
|
244
|
+
* [public addressing]: https://www.w3.org/TR/activitypub/#public-addressing
|
|
245
|
+
*
|
|
246
|
+
* @since 0.7.0
|
|
247
|
+
*/
|
|
248
|
+
const PUBLIC_COLLECTION = new URL("https://www.w3.org/ns/activitystreams#Public");
|
|
249
|
+
//#endregion
|
|
10
250
|
exports.Accept = require_actor.Accept;
|
|
11
251
|
exports.Activity = require_actor.Activity;
|
|
12
252
|
exports.Add = require_actor.Add;
|
|
@@ -48,12 +288,12 @@ exports.Mention = require_actor.Mention;
|
|
|
48
288
|
exports.Move = require_actor.Move;
|
|
49
289
|
exports.Multikey = require_actor.Multikey;
|
|
50
290
|
exports.Note = require_actor.Note;
|
|
51
|
-
exports.Object = require_actor.Object
|
|
291
|
+
exports.Object = require_actor.Object;
|
|
52
292
|
exports.Offer = require_actor.Offer;
|
|
53
293
|
exports.OrderedCollection = require_actor.OrderedCollection;
|
|
54
294
|
exports.OrderedCollectionPage = require_actor.OrderedCollectionPage;
|
|
55
295
|
exports.Organization = require_actor.Organization;
|
|
56
|
-
exports.PUBLIC_COLLECTION =
|
|
296
|
+
exports.PUBLIC_COLLECTION = PUBLIC_COLLECTION;
|
|
57
297
|
exports.Page = require_actor.Page;
|
|
58
298
|
exports.Person = require_actor.Person;
|
|
59
299
|
exports.Place = require_actor.Place;
|
|
@@ -79,9 +319,9 @@ exports.getActorHandle = require_actor.getActorHandle;
|
|
|
79
319
|
exports.getActorTypeName = require_actor.getActorTypeName;
|
|
80
320
|
exports.getTypeId = require_actor.getTypeId;
|
|
81
321
|
exports.isActor = require_actor.isActor;
|
|
82
|
-
exports.isFediverseHandle =
|
|
83
|
-
exports.lookupObject =
|
|
322
|
+
exports.isFediverseHandle = isFediverseHandle;
|
|
323
|
+
exports.lookupObject = lookupObject;
|
|
84
324
|
exports.normalizeActorHandle = require_actor.normalizeActorHandle;
|
|
85
|
-
exports.parseFediverseHandle =
|
|
86
|
-
exports.toAcctUrl =
|
|
87
|
-
exports.traverseCollection =
|
|
325
|
+
exports.parseFediverseHandle = parseFediverseHandle;
|
|
326
|
+
exports.toAcctUrl = toAcctUrl;
|
|
327
|
+
exports.traverseCollection = traverseCollection;
|
package/dist/vocab/mod.d.cts
CHANGED
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
import "../
|
|
2
|
-
import "../
|
|
3
|
-
import {
|
|
4
|
-
import { Actor, ActorTypeName, GetActorHandleOptions, NormalizeActorHandleOptions, Recipient, getActorClassByTypeName, getActorHandle, getActorTypeName, isActor, normalizeActorHandle } from "../actor-D190nbTD.cjs";
|
|
5
|
-
import { FediverseHandle, LookupObjectOptions, PUBLIC_COLLECTION, TraverseCollectionOptions, getTypeId, isFediverseHandle, lookupObject, parseFediverseHandle, toAcctUrl, traverseCollection } from "../mod-D5rfgGFE.cjs";
|
|
1
|
+
import { $ as Read, A as Image, B as Multikey, C as Event, D as Group, E as Follow, F as Like, G as OrderedCollectionPage, H as Object$1, I as Link, J as Person, K as Organization, L as Listen, M as Invite, N as Join, O as Hashtag, P as Leave, Q as Question, R as Mention, S as Endpoints, T as Flag, U as Offer, V as Note, W as OrderedCollection, X as Profile, Y as Place, Z as PropertyValue, _ as DidService, a as Application, at as TentativeAccept, b as Emoji, c as Audio, ct as Travel, d as Collection, dt as Video, et as Reject, f as CollectionPage, ft as View, g as Delete, h as DataIntegrityProof, i as Announce, it as Source, j as IntransitiveActivity, k as Ignore, l as Block, lt as Undo, m as CryptographicKey, n as Activity, nt as Remove, o as Arrive, ot as TentativeReject, p as Create, q as Page, r as Add, rt as Service, s as Article, st as Tombstone, t as Accept, tt as Relationship, u as ChatMessage, ut as Update, v as Dislike, w as Export, x as EmojiReact, y as Document, z as Move } from "../vocab-DnlmNyXi.cjs";
|
|
2
|
+
import { a as Recipient, c as getActorTypeName, i as NormalizeActorHandleOptions, l as isActor, n as ActorTypeName, o as getActorClassByTypeName, r as GetActorHandleOptions, s as getActorHandle, t as Actor, u as normalizeActorHandle } from "../actor-DxvGbmjm.cjs";
|
|
3
|
+
import { a as toAcctUrl, c as TraverseCollectionOptions, i as parseFediverseHandle, l as lookupObject, n as FediverseHandle, o as PUBLIC_COLLECTION, r as isFediverseHandle, s as LookupObjectOptions, t as getTypeId, u as traverseCollection } from "../mod-BQ3lrlXU.cjs";
|
|
6
4
|
export { Accept, Activity, Actor, ActorTypeName, Add, Announce, Application, Arrive, Article, Audio, Block, ChatMessage, Collection, CollectionPage, Create, CryptographicKey, DataIntegrityProof, Delete, DidService, Dislike, Document, Emoji, EmojiReact, Endpoints, Event, Export, FediverseHandle, Flag, Follow, GetActorHandleOptions, Group, Hashtag, Ignore, Image, IntransitiveActivity, Invite, Join, Leave, Like, Link, Listen, LookupObjectOptions, Mention, Move, Multikey, NormalizeActorHandleOptions, Note, Object$1 as Object, Offer, OrderedCollection, OrderedCollectionPage, Organization, PUBLIC_COLLECTION, Page, Person, Place, Profile, PropertyValue, Question, Read, Recipient, Reject, Relationship, Remove, Service, Source, TentativeAccept, TentativeReject, Tombstone, Travel, TraverseCollectionOptions, Undo, Update, Video, View, getActorClassByTypeName, getActorHandle, getActorTypeName, getTypeId, isActor, isFediverseHandle, lookupObject, normalizeActorHandle, parseFediverseHandle, toAcctUrl, traverseCollection };
|
package/dist/vocab/mod.d.ts
CHANGED
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import { Temporal } from "@js-temporal/polyfill";
|
|
2
2
|
import { URLPattern } from "urlpattern-polyfill";
|
|
3
|
-
import "../
|
|
4
|
-
import "../
|
|
5
|
-
import {
|
|
6
|
-
import { Actor, ActorTypeName, GetActorHandleOptions, NormalizeActorHandleOptions, Recipient, getActorClassByTypeName, getActorHandle, getActorTypeName, isActor, normalizeActorHandle } from "../actor-eeONG_sv.js";
|
|
7
|
-
import { FediverseHandle, LookupObjectOptions, PUBLIC_COLLECTION, TraverseCollectionOptions, getTypeId, isFediverseHandle, lookupObject, parseFediverseHandle, toAcctUrl, traverseCollection } from "../mod-DS4kJskR.js";
|
|
3
|
+
import { $ as Read, A as Image, B as Multikey, C as Event, D as Group, E as Follow, F as Like, G as OrderedCollectionPage, H as Object$1, I as Link, J as Person, K as Organization, L as Listen, M as Invite, N as Join, O as Hashtag, P as Leave, Q as Question, R as Mention, S as Endpoints, T as Flag, U as Offer, V as Note, W as OrderedCollection, X as Profile, Y as Place, Z as PropertyValue, _ as DidService, a as Application, at as TentativeAccept, b as Emoji, c as Audio, ct as Travel, d as Collection, dt as Video, et as Reject, f as CollectionPage, ft as View, g as Delete, h as DataIntegrityProof, i as Announce, it as Source, j as IntransitiveActivity, k as Ignore, l as Block, lt as Undo, m as CryptographicKey, n as Activity, nt as Remove, o as Arrive, ot as TentativeReject, p as Create, q as Page, r as Add, rt as Service, s as Article, st as Tombstone, t as Accept, tt as Relationship, u as ChatMessage, ut as Update, v as Dislike, w as Export, x as EmojiReact, y as Document, z as Move } from "../vocab-DaT4UsJF.js";
|
|
4
|
+
import { a as Recipient, c as getActorTypeName, i as NormalizeActorHandleOptions, l as isActor, n as ActorTypeName, o as getActorClassByTypeName, r as GetActorHandleOptions, s as getActorHandle, t as Actor, u as normalizeActorHandle } from "../actor-DXwwgFeR.js";
|
|
5
|
+
import { a as toAcctUrl, c as TraverseCollectionOptions, i as parseFediverseHandle, l as lookupObject, n as FediverseHandle, o as PUBLIC_COLLECTION, r as isFediverseHandle, s as LookupObjectOptions, t as getTypeId, u as traverseCollection } from "../mod-Lj0W1nnG.js";
|
|
8
6
|
export { Accept, Activity, Actor, ActorTypeName, Add, Announce, Application, Arrive, Article, Audio, Block, ChatMessage, Collection, CollectionPage, Create, CryptographicKey, DataIntegrityProof, Delete, DidService, Dislike, Document, Emoji, EmojiReact, Endpoints, Event, Export, FediverseHandle, Flag, Follow, GetActorHandleOptions, Group, Hashtag, Ignore, Image, IntransitiveActivity, Invite, Join, Leave, Like, Link, Listen, LookupObjectOptions, Mention, Move, Multikey, NormalizeActorHandleOptions, Note, Object$1 as Object, Offer, OrderedCollection, OrderedCollectionPage, Organization, PUBLIC_COLLECTION, Page, Person, Place, Profile, PropertyValue, Question, Read, Recipient, Reject, Relationship, Remove, Service, Source, TentativeAccept, TentativeReject, Tombstone, Travel, TraverseCollectionOptions, Undo, Update, Video, View, getActorClassByTypeName, getActorHandle, getActorTypeName, getTypeId, isActor, isFediverseHandle, lookupObject, normalizeActorHandle, parseFediverseHandle, toAcctUrl, traverseCollection };
|