@fedify/fedify 1.6.2 → 1.6.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{actor-BMhjtSSP.js → actor-BfzxE2QN.js} +199 -184
- package/dist/{actor-sID3ZxDC.js → actor-CHPy3MD6.js} +3 -3
- package/dist/{assert-YJk-1DlZ.js → assert-0DSnLFa8.js} +1 -1
- package/dist/{assert_equals-Dnj7ejjL.js → assert_equals-XhPMqqO2.js} +19 -7
- package/dist/{assert_instance_of-DBIoG5k7.js → assert_instance_of-v5adm_-K.js} +1 -1
- package/dist/{assert_is_error-jyzqjHud.js → assert_is_error-Drwb_yQp.js} +1 -1
- package/dist/{assert_not_equals-wx-SRs4i.js → assert_not_equals-BRPdeJ9D.js} +1 -1
- package/dist/{assert_rejects-BZjUwo62.js → assert_rejects-D_nYI1gs.js} +2 -2
- package/dist/{assert_throws-gBPv3v2V.js → assert_throws-DNuPhPNp.js} +2 -2
- package/dist/{authdocloader-Cx832_tB.js → authdocloader-8yB-xGBR.js} +3 -3
- package/dist/{authdocloader-C0NAukol.js → authdocloader-qBxZEEi9.js} +3 -3
- package/dist/{builder-D3RO7FNo.js → builder-NApTRrpC.js} +3 -3
- package/dist/{client-C41u40q8.js → client-DFAp6PBu.js} +2 -2
- package/dist/compat/transformers.test.js +23 -23
- package/dist/{context-BJas1P69.js → context-DPm_2m4V.js} +2 -2
- package/dist/{docloader-sQOhKEBJ.js → docloader-BGQB_PFT.js} +1 -1
- package/dist/{docloader-BvrnWgo_.js → docloader-Chzwgszm.js} +1 -1
- package/dist/{esm-e_d5TL5c.js → esm-CASHO3OR.js} +2 -2
- package/dist/federation/builder.test.js +14 -14
- package/dist/federation/collection.test.js +9 -9
- package/dist/federation/handler.test.js +34 -31
- package/dist/federation/inbox.test.js +7 -7
- package/dist/federation/keycache.test.js +7 -7
- package/dist/federation/kv.test.js +9 -9
- package/dist/federation/middleware.test.js +31 -31
- package/dist/federation/mod.js +10 -10
- package/dist/federation/mq.test.js +9 -9
- package/dist/federation/retry.test.js +3 -3
- package/dist/federation/router.test.js +9 -9
- package/dist/federation/send.test.js +19 -19
- package/dist/{http-Bg69S5M3.js → http-CoPwpYGd.js} +22 -8
- package/dist/{http-CRixLRRg.js → http-DJcO8N65.js} +22 -8
- package/dist/{inbox-DOqV2pzD.js → inbox-CL7Y2POM.js} +2 -2
- package/dist/{key-C165LPcE.js → key-5iwxfdk7.js} +3 -3
- package/dist/{key-MStTavXZ.js → key-BQEmzABV.js} +4 -4
- package/dist/{key-B8GvtVuo.js → key-dki_alWE.js} +5 -5
- package/dist/{key-CjznLZb-.js → key-vNs-KWCR.js} +2 -2
- package/dist/{keycache-B1a4V1bo.js → keycache-oIWQCIss.js} +1 -1
- package/dist/{keys-ClfspZmG.js → keys-BF9Wnizj.js} +1 -1
- package/dist/{ld-Bgne7jyu.js → ld-Bro1OUaC.js} +3 -3
- package/dist/{lookup-bR-W7dO1.js → lookup-BE2D88-F.js} +1 -1
- package/dist/{lookup-Cj7hv3cS.js → lookup-BNZr2r1q.js} +3 -3
- package/dist/{lookup-BfzH97Bi.js → lookup-DVLRiy-x.js} +1 -1
- package/dist/middleware-30sYf6H-.js +17 -0
- package/dist/{middleware-Cc1LwuPX.js → middleware-BoJeFg8A.js} +16 -16
- package/dist/{middleware-Cth2CRY9.js → middleware-DIMI9i2M.js} +10 -10
- package/dist/middleware-DvIti4UE.js +33 -0
- package/dist/mod.js +10 -10
- package/dist/nodeinfo/client.test.js +13 -13
- package/dist/nodeinfo/handler.test.js +29 -29
- package/dist/nodeinfo/mod.js +2 -2
- package/dist/nodeinfo/semver.test.js +10 -10
- package/dist/nodeinfo/types.test.js +11 -11
- package/dist/{owner-BwbNQA42.js → owner-B5psHPX0.js} +3 -3
- package/dist/{proof-VM7AiB-j.js → proof-Bxho-Eev.js} +3 -3
- package/dist/{proof-D8juaMAC.js → proof-Ck9qUTzW.js} +3 -3
- package/dist/runtime/authdocloader.test.js +18 -18
- package/dist/runtime/docloader.test.js +11 -11
- package/dist/runtime/key.test.js +14 -14
- package/dist/runtime/langstr.test.js +9 -9
- package/dist/runtime/mod.js +6 -6
- package/dist/runtime/multibase/multibase.test.js +9 -9
- package/dist/runtime/url.test.js +5 -5
- package/dist/{semver-CbbIgUsa.js → semver-DWClQt_5.js} +2 -2
- package/dist/{send-E1bEkesZ.js → send-D4-hN_vq.js} +2 -2
- package/dist/sig/http.test.js +51 -23
- package/dist/sig/key.test.js +15 -15
- package/dist/sig/ld.test.js +13 -13
- package/dist/sig/mod.js +6 -6
- package/dist/sig/owner.test.js +17 -17
- package/dist/sig/proof.test.js +17 -17
- package/dist/{std__assert-CHXwj7zk.js → std__assert-CmyZxqPw.js} +1 -1
- package/dist/testing/docloader.test.js +9 -9
- package/dist/testing/mod.js +1 -1
- package/dist/{testing-jcGLO9Lp.js → testing-BZ0dJ4qn.js} +1 -1
- package/dist/{types-CIrnA1uA.js → types-BaxpHQDE.js} +3 -3
- package/dist/{types-CqoqWDkp.js → types-C7C_l-jz.js} +1 -1
- package/dist/vocab/actor.test.js +15 -15
- package/dist/vocab/announce.yaml +3 -1
- package/dist/vocab/create.yaml +3 -1
- package/dist/vocab/delete.yaml +3 -1
- package/dist/vocab/lookup.test.js +14 -14
- package/dist/vocab/mod.js +4 -4
- package/dist/vocab/question.yaml +3 -1
- package/dist/vocab/type.test.js +4 -4
- package/dist/vocab/update.yaml +3 -1
- package/dist/vocab/vocab.test.js +37 -34
- package/dist/{vocab-DMwazFlI.js → vocab-Bcgf3ubZ.js} +3 -3
- package/dist/{vocab-BOhnfQ4Q.js → vocab-DrV5TQKL.js} +199 -184
- package/dist/webfinger/handler.test.js +29 -29
- package/dist/webfinger/lookup.test.js +12 -12
- package/dist/webfinger/mod.js +2 -2
- package/dist/x/cfworkers.test.js +9 -9
- package/package.json +1 -1
- package/dist/middleware-9potsc1r.js +0 -33
- package/dist/middleware-BfaA_Kfc.js +0 -17
package/dist/vocab/vocab.test.js
CHANGED
@@ -3,39 +3,35 @@
|
|
3
3
|
import { URLPattern } from "urlpattern-polyfill";
|
4
4
|
globalThis.addEventListener = () => {};
|
5
5
|
|
6
|
-
import { assertEquals } from "../assert_equals-
|
7
|
-
import "../assert-
|
8
|
-
import { assertInstanceOf } from "../assert_instance_of-
|
9
|
-
import "../docloader-
|
6
|
+
import { assertEquals, isWindows } from "../assert_equals-XhPMqqO2.js";
|
7
|
+
import { assert } from "../assert-0DSnLFa8.js";
|
8
|
+
import { assertInstanceOf } from "../assert_instance_of-v5adm_-K.js";
|
9
|
+
import "../docloader-Chzwgszm.js";
|
10
10
|
import "../url-kTAI6_KP.js";
|
11
11
|
import { decode } from "../multibase-DeCHcK8L.js";
|
12
|
-
import { Activity, Announce, Create, CryptographicKey, Follow, Hashtag, Note, Object as Object$1, OrderedCollectionPage, Person, Place, Source, vocab_exports } from "../vocab-
|
12
|
+
import { Activity, Announce, Create, CryptographicKey, Follow, Hashtag, Note, Object as Object$1, OrderedCollectionPage, Person, Place, Question, Source, vocab_exports } from "../vocab-DrV5TQKL.js";
|
13
13
|
import { LanguageString } from "../langstr-DbWheeIS.js";
|
14
|
-
import { test } from "../testing-
|
15
|
-
import "../std__assert-
|
16
|
-
import { assertFalse, assertRejects } from "../assert_rejects-
|
17
|
-
import "../assert_is_error-
|
18
|
-
import { assertNotEquals } from "../assert_not_equals-
|
19
|
-
import { assertThrows } from "../assert_throws-
|
14
|
+
import { test } from "../testing-BZ0dJ4qn.js";
|
15
|
+
import "../std__assert-CmyZxqPw.js";
|
16
|
+
import { assertFalse, assertRejects } from "../assert_rejects-D_nYI1gs.js";
|
17
|
+
import "../assert_is_error-Drwb_yQp.js";
|
18
|
+
import { assertNotEquals } from "../assert_not_equals-BRPdeJ9D.js";
|
19
|
+
import { assertThrows } from "../assert_throws-DNuPhPNp.js";
|
20
20
|
import { mockDocumentLoader } from "../docloader-09nVWLAZ.js";
|
21
|
-
import { ed25519PublicKey, rsaPublicKey1 } from "../keys-
|
21
|
+
import { ed25519PublicKey, rsaPublicKey1 } from "../keys-BF9Wnizj.js";
|
22
22
|
import { pascalCase } from "@es-toolkit/es-toolkit";
|
23
23
|
import { parseLanguageTag } from "@phensley/language-tag";
|
24
24
|
import { Validator } from "@cfworker/json-schema";
|
25
25
|
import { readFile, readdir } from "node:fs/promises";
|
26
26
|
import { join } from "node:path";
|
27
27
|
|
28
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
29
|
-
const isWindows = globalThis.Deno?.build.os === "windows" || globalThis.navigator?.platform?.startsWith("Win") || globalThis.process?.platform?.startsWith("win") || false;
|
30
|
-
|
31
|
-
//#endregion
|
32
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.0/node_modules/@jsr/std__path/_common/assert_path.js
|
28
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/_common/assert_path.js
|
33
29
|
function assertPath(path) {
|
34
30
|
if (typeof path !== "string") throw new TypeError(`Path must be a string, received "${JSON.stringify(path)}"`);
|
35
31
|
}
|
36
32
|
|
37
33
|
//#endregion
|
38
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
34
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/_common/from_file_url.js
|
39
35
|
function assertArg$2(url) {
|
40
36
|
url = url instanceof URL ? url : new URL(url);
|
41
37
|
if (url.protocol !== "file:") throw new TypeError(`URL must be a file URL: received "${url.protocol}"`);
|
@@ -43,7 +39,7 @@ function assertArg$2(url) {
|
|
43
39
|
}
|
44
40
|
|
45
41
|
//#endregion
|
46
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
42
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/posix/from_file_url.js
|
47
43
|
/**
|
48
44
|
* Converts a file URL to a path string.
|
49
45
|
*
|
@@ -63,7 +59,7 @@ function assertArg$2(url) {
|
|
63
59
|
}
|
64
60
|
|
65
61
|
//#endregion
|
66
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
62
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/_common/strip_trailing_separators.js
|
67
63
|
function stripTrailingSeparators(segment, isSep) {
|
68
64
|
if (segment.length <= 1) return segment;
|
69
65
|
let end = segment.length;
|
@@ -73,18 +69,18 @@ function stripTrailingSeparators(segment, isSep) {
|
|
73
69
|
}
|
74
70
|
|
75
71
|
//#endregion
|
76
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
72
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/_common/constants.js
|
77
73
|
const CHAR_DOT = 46;
|
78
74
|
const CHAR_FORWARD_SLASH = 47;
|
79
75
|
|
80
76
|
//#endregion
|
81
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
77
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/posix/_util.js
|
82
78
|
function isPosixPathSeparator(code) {
|
83
79
|
return code === CHAR_FORWARD_SLASH;
|
84
80
|
}
|
85
81
|
|
86
82
|
//#endregion
|
87
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
83
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/windows/from_file_url.js
|
88
84
|
/**
|
89
85
|
* Converts a file URL to a path string.
|
90
86
|
*
|
@@ -108,14 +104,14 @@ function isPosixPathSeparator(code) {
|
|
108
104
|
}
|
109
105
|
|
110
106
|
//#endregion
|
111
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
107
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/_common/dirname.js
|
112
108
|
function assertArg$1(path) {
|
113
109
|
assertPath(path);
|
114
110
|
if (path.length === 0) return ".";
|
115
111
|
}
|
116
112
|
|
117
113
|
//#endregion
|
118
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
114
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/posix/dirname.js
|
119
115
|
/**
|
120
116
|
* Return the directory path of a `path`.
|
121
117
|
*
|
@@ -159,7 +155,7 @@ function assertArg$1(path) {
|
|
159
155
|
}
|
160
156
|
|
161
157
|
//#endregion
|
162
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
158
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/from_file_url.js
|
163
159
|
/**
|
164
160
|
* Converts a file URL to a path string.
|
165
161
|
*
|
@@ -184,14 +180,14 @@ function assertArg$1(path) {
|
|
184
180
|
}
|
185
181
|
|
186
182
|
//#endregion
|
187
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
183
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/_common/normalize.js
|
188
184
|
function assertArg(path) {
|
189
185
|
assertPath(path);
|
190
186
|
if (path.length === 0) return ".";
|
191
187
|
}
|
192
188
|
|
193
189
|
//#endregion
|
194
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
190
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/_common/normalize_string.js
|
195
191
|
function normalizeString(path, allowAboveRoot, separator, isPathSeparator) {
|
196
192
|
let res = "";
|
197
193
|
let lastSegmentLength = 0;
|
@@ -244,7 +240,7 @@ function normalizeString(path, allowAboveRoot, separator, isPathSeparator) {
|
|
244
240
|
}
|
245
241
|
|
246
242
|
//#endregion
|
247
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
243
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/posix/normalize.js
|
248
244
|
/**
|
249
245
|
* Normalize the `path`, resolving `'..'` and `'.'` segments.
|
250
246
|
* Note that resolving these segments does not necessarily mean that all will be eliminated.
|
@@ -292,7 +288,7 @@ function normalizeString(path, allowAboveRoot, separator, isPathSeparator) {
|
|
292
288
|
}
|
293
289
|
|
294
290
|
//#endregion
|
295
|
-
//#region node_modules/.pnpm/@jsr+std__path@1.1.
|
291
|
+
//#region node_modules/.pnpm/@jsr+std__path@1.1.1/node_modules/@jsr/std__path/posix/join.js
|
296
292
|
/**
|
297
293
|
* Join all given a sequence of `paths`,then normalizes the resulting path.
|
298
294
|
*
|
@@ -580,7 +576,7 @@ function isPlainObject(object) {
|
|
580
576
|
|
581
577
|
//#endregion
|
582
578
|
//#region node_modules/.pnpm/@jsr+std__yaml@1.0.8/node_modules/@jsr/std__yaml/_type/float.js
|
583
|
-
const YAML_FLOAT_PATTERN = new RegExp("^(?:[-+]?(?:0|[1-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");
|
579
|
+
const YAML_FLOAT_PATTERN = /* @__PURE__ */ new RegExp("^(?:[-+]?(?:0|[1-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");
|
584
580
|
function resolveYamlFloat(data) {
|
585
581
|
if (!YAML_FLOAT_PATTERN.test(data) || data[data.length - 1] === "_") return false;
|
586
582
|
return true;
|
@@ -875,8 +871,8 @@ const str = {
|
|
875
871
|
|
876
872
|
//#endregion
|
877
873
|
//#region node_modules/.pnpm/@jsr+std__yaml@1.0.8/node_modules/@jsr/std__yaml/_type/timestamp.js
|
878
|
-
const YAML_DATE_REGEXP = new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$");
|
879
|
-
const YAML_TIMESTAMP_REGEXP = new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");
|
874
|
+
const YAML_DATE_REGEXP = /* @__PURE__ */ new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$");
|
875
|
+
const YAML_TIMESTAMP_REGEXP = /* @__PURE__ */ new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");
|
880
876
|
function resolveYamlTimestamp(data) {
|
881
877
|
if (data === null) return false;
|
882
878
|
if (YAML_DATE_REGEXP.exec(data) !== null) return true;
|
@@ -1193,7 +1189,7 @@ var LoaderState = class {
|
|
1193
1189
|
}
|
1194
1190
|
#createError(message) {
|
1195
1191
|
const mark = markToString(this.input, this.position, this.line, this.position - this.lineStart);
|
1196
|
-
return new SyntaxError(`${message} ${mark}`);
|
1192
|
+
return /* @__PURE__ */ new SyntaxError(`${message} ${mark}`);
|
1197
1193
|
}
|
1198
1194
|
dispatchWarning(message) {
|
1199
1195
|
const error = this.#createError(message);
|
@@ -2783,6 +2779,13 @@ test("Activity.clone()", async () => {
|
|
2783
2779
|
summaries: ["plural"]
|
2784
2780
|
}), TypeError, "Cannot update both summary and summaries at the same time.");
|
2785
2781
|
});
|
2782
|
+
test("Question.voters", async () => {
|
2783
|
+
const question = new Question({ voters: 123 });
|
2784
|
+
const json = await question.toJsonLd({ format: "compact" });
|
2785
|
+
assert(typeof json === "object" && json != null);
|
2786
|
+
assert("votersCount" in json);
|
2787
|
+
assertEquals(json["votersCount"], 123);
|
2788
|
+
});
|
2786
2789
|
test({
|
2787
2790
|
name: "Deno.inspect(Object)",
|
2788
2791
|
ignore: !("Deno" in globalThis),
|
@@ -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-
|
6
|
-
import { Object as Object$1, getTypeId } from "./actor-
|
7
|
-
import { lookupWebFinger } from "./lookup-
|
5
|
+
import { deno_default, getDocumentLoader } from "./docloader-BGQB_PFT.js";
|
6
|
+
import { Object as Object$1, getTypeId } from "./actor-BfzxE2QN.js";
|
7
|
+
import { lookupWebFinger } from "./lookup-DVLRiy-x.js";
|
8
8
|
import { getLogger } from "@logtape/logtape";
|
9
9
|
import { SpanStatusCode, trace } from "@opentelemetry/api";
|
10
10
|
import { delay } from "@es-toolkit/es-toolkit";
|