@fedify/vocab 2.4.0-dev.1634 → 2.4.0-pr.934.40
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/deno.json +1 -1
- package/dist/mod.cjs +15 -425
- package/dist/mod.d.cts +1 -109
- package/dist/mod.d.ts +1 -109
- package/dist/mod.js +16 -426
- package/dist-tests/{actor-BQd8S953.mjs → actor-CnnyTI7i.mjs} +2 -2
- package/dist-tests/actor.test.mjs +2 -2
- package/dist-tests/application.yaml +0 -15
- package/dist-tests/audio.yaml +1 -2
- package/dist-tests/document.yaml +1 -14
- package/dist-tests/group.yaml +0 -15
- package/dist-tests/image.yaml +1 -2
- package/dist-tests/link.yaml +1 -14
- package/dist-tests/lookup.test.mjs +2 -2
- package/dist-tests/organization.yaml +0 -15
- package/dist-tests/page.yaml +1 -2
- package/dist-tests/person.yaml +0 -15
- package/dist-tests/service.yaml +0 -15
- package/dist-tests/type.test.mjs +1 -1
- package/dist-tests/video.yaml +1 -2
- package/dist-tests/{vocab-Bjwctrxn.mjs → vocab-OU5GYbNg.mjs} +16 -426
- package/dist-tests/vocab.test.mjs +1 -152
- package/package.json +4 -4
- package/src/__snapshots__/vocab.test.ts.snap +15 -54
- package/src/application.yaml +0 -15
- package/src/audio.yaml +1 -2
- package/src/document.yaml +1 -14
- package/src/group.yaml +0 -15
- package/src/image.yaml +1 -2
- package/src/link.yaml +1 -14
- package/src/organization.yaml +0 -15
- package/src/page.yaml +1 -2
- package/src/person.yaml +0 -15
- package/src/preprocessors.ts +1 -3
- package/src/service.yaml +0 -15
- package/src/video.yaml +1 -2
- package/src/vocab.test.ts +0 -244
package/dist/mod.js
CHANGED
|
@@ -4,13 +4,13 @@ import { SpanStatusCode, trace } from "@opentelemetry/api";
|
|
|
4
4
|
import { domainToASCII, domainToUnicode } from "node:url";
|
|
5
5
|
import jsonld from "@fedify/vocab-runtime/jsonld";
|
|
6
6
|
import { getLogger } from "@logtape/logtape";
|
|
7
|
-
import { LanguageString, LanguageString as LanguageString$1, decodeMultibase, encodeMultibase, exportMultibaseKey, exportSpki, formatIri, getDocumentLoader, haveSameFe34Origin, haveSameIriOrigin, importMultibaseKey, importPem, isDecimal,
|
|
7
|
+
import { LanguageString, LanguageString as LanguageString$1, decodeMultibase, encodeMultibase, exportMultibaseKey, exportSpki, formatIri, getDocumentLoader, haveSameFe34Origin, haveSameIriOrigin, importMultibaseKey, importPem, isDecimal, parseDecimal, parseIri, parseJsonLdId } from "@fedify/vocab-runtime";
|
|
8
8
|
import { compactJsonLdCache, isTrustedIriOrigin, normalizeJsonLdIris } from "@fedify/vocab-runtime/internal/jsonld-cache";
|
|
9
9
|
import { isTemporalDuration, isTemporalInstant } from "@fedify/vocab-runtime/temporal";
|
|
10
10
|
import { delay } from "es-toolkit";
|
|
11
11
|
//#region deno.json
|
|
12
12
|
var name = "@fedify/vocab";
|
|
13
|
-
var version = "2.4.0-
|
|
13
|
+
var version = "2.4.0-pr.934.40+3331d302";
|
|
14
14
|
//#endregion
|
|
15
15
|
//#region src/type.ts
|
|
16
16
|
function getTypeId(object) {
|
|
@@ -25,8 +25,7 @@ function getTypeId(object) {
|
|
|
25
25
|
* When an `icon` or `image` property on a vocabulary object contains an
|
|
26
26
|
* explicit ActivityStreams `Link` rather than an `Image`, this preprocessor
|
|
27
27
|
* converts it into an `Image` by mapping `href` to `url`, copying
|
|
28
|
-
* `mediaType`, `name`, `width`, `height`, and
|
|
29
|
-
* discarding the rest.
|
|
28
|
+
* `mediaType`, `name`, `width`, and `height`, and discarding the rest.
|
|
30
29
|
*
|
|
31
30
|
* If the value is not a Link, or the Link has no `href`, it returns
|
|
32
31
|
* `undefined` so the normal range decoder continues.
|
|
@@ -47,8 +46,7 @@ const normalizeLinkToImage = async (value, context) => {
|
|
|
47
46
|
mediaType: link.mediaType,
|
|
48
47
|
names: link.names != null && link.names.length > 0 ? link.names : void 0,
|
|
49
48
|
width: link.width,
|
|
50
|
-
height: link.height
|
|
51
|
-
digestMultibase: link.digestMultibase
|
|
49
|
+
height: link.height
|
|
52
50
|
});
|
|
53
51
|
};
|
|
54
52
|
//#endregion
|
|
@@ -21972,7 +21970,6 @@ var Application = class Application extends Object$1 {
|
|
|
21972
21970
|
#_trust_axq166E2eZADq34V4MYUc8KMZdC_publicKey = /* @__PURE__ */ new Set();
|
|
21973
21971
|
#_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = [];
|
|
21974
21972
|
#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = /* @__PURE__ */ new Set();
|
|
21975
|
-
#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [];
|
|
21976
21973
|
#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [];
|
|
21977
21974
|
#_3ghX3VfZXXbLvhCRH7QJqpzLrXjB_inbox = [];
|
|
21978
21975
|
#_trust_3ghX3VfZXXbLvhCRH7QJqpzLrXjB_inbox = /* @__PURE__ */ new Set();
|
|
@@ -22041,13 +22038,6 @@ var Application = class Application extends Object$1 {
|
|
|
22041
22038
|
for (let i = 0; i < values.assertionMethods.length; i++) this.#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.add(i);
|
|
22042
22039
|
} else throw new TypeError("The assertionMethods must be an array of type Multikey | URL.");
|
|
22043
22040
|
}
|
|
22044
|
-
if ("gateway" in values && values.gateway != null) if (values.gateway instanceof URL && isGatewayUrl(values.gateway)) this.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [values.gateway];
|
|
22045
|
-
else throw new TypeError("The gateway must be of type URL.");
|
|
22046
|
-
if ("gateways" in values && values.gateways != null) {
|
|
22047
|
-
if ("gateway" in values && values.gateway != null) throw new TypeError("Cannot initialize both gateway and gateways at the same time.");
|
|
22048
|
-
if (Array.isArray(values.gateways) && values.gateways.every((v) => v instanceof URL && isGatewayUrl(v))) this.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = values.gateways;
|
|
22049
|
-
else throw new TypeError("The gateways must be an array of type URL.");
|
|
22050
|
-
}
|
|
22051
22041
|
if ("manuallyApprovesFollowers" in values && values.manuallyApprovesFollowers != null) if (typeof values.manuallyApprovesFollowers === "boolean") this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [values.manuallyApprovesFollowers];
|
|
22052
22042
|
else throw new TypeError("The manuallyApprovesFollowers must be of type boolean.");
|
|
22053
22043
|
if ("inbox" in values && values.inbox != null) if (values.inbox instanceof OrderedCollection || values.inbox instanceof OrderedCollectionPage || values.inbox instanceof URL) {
|
|
@@ -22178,14 +22168,6 @@ var Application = class Application extends Object$1 {
|
|
|
22178
22168
|
for (let i = 0; i < values.assertionMethods.length; i++) clone.#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.add(i);
|
|
22179
22169
|
} else throw new TypeError("The assertionMethods must be an array of type Multikey | URL.");
|
|
22180
22170
|
}
|
|
22181
|
-
clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = this.#_hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
22182
|
-
if ("gateway" in values && values.gateway != null) if (values.gateway instanceof URL && isGatewayUrl(values.gateway)) clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [values.gateway];
|
|
22183
|
-
else throw new TypeError("The gateway must be of type URL.");
|
|
22184
|
-
if ("gateways" in values && values.gateways != null) {
|
|
22185
|
-
if ("gateway" in values && values.gateway != null) throw new TypeError("Cannot update both gateway and gateways at the same time.");
|
|
22186
|
-
if (Array.isArray(values.gateways) && values.gateways.every((v) => v instanceof URL && isGatewayUrl(v))) clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = values.gateways;
|
|
22187
|
-
else throw new TypeError("The gateways must be an array of type URL.");
|
|
22188
|
-
}
|
|
22189
22171
|
clone.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers;
|
|
22190
22172
|
if ("manuallyApprovesFollowers" in values && values.manuallyApprovesFollowers != null) if (typeof values.manuallyApprovesFollowers === "boolean") clone.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [values.manuallyApprovesFollowers];
|
|
22191
22173
|
else throw new TypeError("The manuallyApprovesFollowers must be of type boolean.");
|
|
@@ -22659,24 +22641,6 @@ var Application = class Application extends Object$1 {
|
|
|
22659
22641
|
yield v;
|
|
22660
22642
|
}
|
|
22661
22643
|
}
|
|
22662
|
-
/** Gateways where the latest version of this portable actor object can be
|
|
22663
|
-
* retrieved.
|
|
22664
|
-
*
|
|
22665
|
-
* See [FEP-ef61](https://w3id.org/fep/ef61) for details.
|
|
22666
|
-
*/
|
|
22667
|
-
get gateway() {
|
|
22668
|
-
if (this._warning != null) getLogger(this._warning.category).warn(this._warning.message, this._warning.values);
|
|
22669
|
-
if (this.#_hQiaHhZP8hqxckxTBrpsGNs57E3.length < 1) return null;
|
|
22670
|
-
return this.#_hQiaHhZP8hqxckxTBrpsGNs57E3[0];
|
|
22671
|
-
}
|
|
22672
|
-
/** Gateways where the latest version of this portable actor object can be
|
|
22673
|
-
* retrieved.
|
|
22674
|
-
*
|
|
22675
|
-
* See [FEP-ef61](https://w3id.org/fep/ef61) for details.
|
|
22676
|
-
*/
|
|
22677
|
-
get gateways() {
|
|
22678
|
-
return this.#_hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
22679
|
-
}
|
|
22680
22644
|
/** When `true`, conveys that for this actor, follow requests are not usually
|
|
22681
22645
|
* automatically approved, but instead are examined by a person who may accept
|
|
22682
22646
|
* or reject the request, at some time in the future. Setting of `false`
|
|
@@ -24546,12 +24510,6 @@ var Application = class Application extends Object$1 {
|
|
|
24546
24510
|
}
|
|
24547
24511
|
if (compactItems.length > 0) result["assertionMethod"] = compactItems.length > 1 ? compactItems : compactItems[0];
|
|
24548
24512
|
compactItems = [];
|
|
24549
|
-
for (const v of this.#_hQiaHhZP8hqxckxTBrpsGNs57E3) {
|
|
24550
|
-
const item = formatIri(v);
|
|
24551
|
-
compactItems.push(item);
|
|
24552
|
-
}
|
|
24553
|
-
if (compactItems.length > 0) result["gateways"] = compactItems;
|
|
24554
|
-
compactItems = [];
|
|
24555
24513
|
for (const v of this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers) {
|
|
24556
24514
|
const item = v;
|
|
24557
24515
|
compactItems.push(item);
|
|
@@ -24767,7 +24725,6 @@ var Application = class Application extends Object$1 {
|
|
|
24767
24725
|
if (this.id != null) result["id"] = formatIri(this.id);
|
|
24768
24726
|
result["@context"] = [
|
|
24769
24727
|
"https://www.w3.org/ns/activitystreams",
|
|
24770
|
-
"https://w3id.org/fep/ef61",
|
|
24771
24728
|
"https://w3id.org/security/v1",
|
|
24772
24729
|
"https://w3id.org/security/data-integrity/v1",
|
|
24773
24730
|
"https://www.w3.org/ns/did/v1",
|
|
@@ -24840,12 +24797,6 @@ var Application = class Application extends Object$1 {
|
|
|
24840
24797
|
}
|
|
24841
24798
|
if (array.length > 0) values["https://w3id.org/security#assertionMethod"] = array;
|
|
24842
24799
|
array = [];
|
|
24843
|
-
for (const v of this.#_hQiaHhZP8hqxckxTBrpsGNs57E3) {
|
|
24844
|
-
const element = { "@id": formatIri(v) };
|
|
24845
|
-
array.push(element);
|
|
24846
|
-
}
|
|
24847
|
-
if (array.length > 0) values["https://w3id.org/fep/ef61/gateways"] = { "@list": array };
|
|
24848
|
-
array = [];
|
|
24849
24800
|
for (const v of this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers) {
|
|
24850
24801
|
const element = { "@value": v };
|
|
24851
24802
|
array.push(element);
|
|
@@ -24970,7 +24921,6 @@ var Application = class Application extends Object$1 {
|
|
|
24970
24921
|
if (options.format === "expand") return await jsonld.expand(values, { documentLoader: options.contextLoader });
|
|
24971
24922
|
const docContext = options.context ?? [
|
|
24972
24923
|
"https://www.w3.org/ns/activitystreams",
|
|
24973
|
-
"https://w3id.org/fep/ef61",
|
|
24974
24924
|
"https://w3id.org/security/v1",
|
|
24975
24925
|
"https://w3id.org/security/data-integrity/v1",
|
|
24976
24926
|
"https://www.w3.org/ns/did/v1",
|
|
@@ -25134,15 +25084,6 @@ var Application = class Application extends Object$1 {
|
|
|
25134
25084
|
_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.push(decoded);
|
|
25135
25085
|
}
|
|
25136
25086
|
instance.#_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod;
|
|
25137
|
-
const _hQiaHhZP8hqxckxTBrpsGNs57E3 = [];
|
|
25138
|
-
let _hQiaHhZP8hqxckxTBrpsGNs57E3__array = values["https://w3id.org/fep/ef61/gateways"];
|
|
25139
|
-
for (const v of _hQiaHhZP8hqxckxTBrpsGNs57E3__array == null ? [] : _hQiaHhZP8hqxckxTBrpsGNs57E3__array.length === 1 && "@list" in _hQiaHhZP8hqxckxTBrpsGNs57E3__array[0] ? _hQiaHhZP8hqxckxTBrpsGNs57E3__array[0]["@list"] : _hQiaHhZP8hqxckxTBrpsGNs57E3__array) {
|
|
25140
|
-
if (v == null) continue;
|
|
25141
|
-
const decoded = parseGatewayUrl(typeof v["@id"] === "string" ? v["@id"] : v["@value"]);
|
|
25142
|
-
if (typeof decoded === "undefined") continue;
|
|
25143
|
-
_hQiaHhZP8hqxckxTBrpsGNs57E3.push(decoded);
|
|
25144
|
-
}
|
|
25145
|
-
instance.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = _hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
25146
25087
|
const _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [];
|
|
25147
25088
|
let _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array = values["https://www.w3.org/ns/activitystreams#manuallyApprovesFollowers"];
|
|
25148
25089
|
for (const v of _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array == null ? [] : _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array.length === 1 && "@list" in _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array[0] ? _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array[0]["@list"] : _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array) {
|
|
@@ -25484,12 +25425,6 @@ var Application = class Application extends Object$1 {
|
|
|
25484
25425
|
} : v);
|
|
25485
25426
|
if (_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length == 1) proxy.assertionMethod = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod[0];
|
|
25486
25427
|
if (_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length > 1 || !("assertionMethod" in proxy) && _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length > 0) proxy.assertionMethods = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod;
|
|
25487
|
-
const _hQiaHhZP8hqxckxTBrpsGNs57E3 = this.#_hQiaHhZP8hqxckxTBrpsGNs57E3.map((v) => v instanceof URL ? {
|
|
25488
|
-
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
25489
|
-
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
25490
|
-
} : v);
|
|
25491
|
-
if (_hQiaHhZP8hqxckxTBrpsGNs57E3.length == 1) proxy.gateway = _hQiaHhZP8hqxckxTBrpsGNs57E3[0];
|
|
25492
|
-
if (_hQiaHhZP8hqxckxTBrpsGNs57E3.length > 1 || !("gateway" in proxy) && _hQiaHhZP8hqxckxTBrpsGNs57E3.length > 0) proxy.gateways = _hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
25493
25428
|
const _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers.map((v) => v instanceof URL ? {
|
|
25494
25429
|
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
25495
25430
|
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
@@ -26580,7 +26515,6 @@ var Document = class Document extends Object$1 {
|
|
|
26580
26515
|
}
|
|
26581
26516
|
#_2e9AP7WdHBJYAgXG6GEyq7nSkNMe_width = [];
|
|
26582
26517
|
#_2cGKFeFJMmiNpGZFEF75mCwFQsKb_height = [];
|
|
26583
|
-
#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = [];
|
|
26584
26518
|
/**
|
|
26585
26519
|
* Constructs a new instance of Document with the given values.
|
|
26586
26520
|
* @param values The values to initialize the instance with.
|
|
@@ -26592,8 +26526,6 @@ var Document = class Document extends Object$1 {
|
|
|
26592
26526
|
else throw new TypeError("The width must be of type number.");
|
|
26593
26527
|
if ("height" in values && values.height != null) if (typeof values.height === "number" && Number.isInteger(values.height) && values.height >= 0) this.#_2cGKFeFJMmiNpGZFEF75mCwFQsKb_height = [values.height];
|
|
26594
26528
|
else throw new TypeError("The height must be of type number.");
|
|
26595
|
-
if ("digestMultibase" in values && values.digestMultibase != null) if (typeof values.digestMultibase === "string") this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = [values.digestMultibase];
|
|
26596
|
-
else throw new TypeError("The digestMultibase must be of type string.");
|
|
26597
26529
|
}
|
|
26598
26530
|
/**
|
|
26599
26531
|
* Clones this instance, optionally updating it with the given values.
|
|
@@ -26616,9 +26548,6 @@ var Document = class Document extends Object$1 {
|
|
|
26616
26548
|
clone.#_2cGKFeFJMmiNpGZFEF75mCwFQsKb_height = this.#_2cGKFeFJMmiNpGZFEF75mCwFQsKb_height;
|
|
26617
26549
|
if ("height" in values && values.height != null) if (typeof values.height === "number" && Number.isInteger(values.height) && values.height >= 0) clone.#_2cGKFeFJMmiNpGZFEF75mCwFQsKb_height = [values.height];
|
|
26618
26550
|
else throw new TypeError("The height must be of type number.");
|
|
26619
|
-
clone.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase;
|
|
26620
|
-
if ("digestMultibase" in values && values.digestMultibase != null) if (typeof values.digestMultibase === "string") clone.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = [values.digestMultibase];
|
|
26621
|
-
else throw new TypeError("The digestMultibase must be of type string.");
|
|
26622
26551
|
return clone;
|
|
26623
26552
|
}
|
|
26624
26553
|
/** Specifies a hint as to the rendering width in
|
|
@@ -26637,16 +26566,6 @@ var Document = class Document extends Object$1 {
|
|
|
26637
26566
|
if (this.#_2cGKFeFJMmiNpGZFEF75mCwFQsKb_height.length < 1) return null;
|
|
26638
26567
|
return this.#_2cGKFeFJMmiNpGZFEF75mCwFQsKb_height[0];
|
|
26639
26568
|
}
|
|
26640
|
-
/** The multibase-encoded integrity digest of an external resource represented
|
|
26641
|
-
* by this document.
|
|
26642
|
-
*
|
|
26643
|
-
* See [FEP-ef61](https://w3id.org/fep/ef61) for details.
|
|
26644
|
-
*/
|
|
26645
|
-
get digestMultibase() {
|
|
26646
|
-
if (this._warning != null) getLogger(this._warning.category).warn(this._warning.message, this._warning.values);
|
|
26647
|
-
if (this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase.length < 1) return null;
|
|
26648
|
-
return this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase[0];
|
|
26649
|
-
}
|
|
26650
26569
|
/**
|
|
26651
26570
|
* Converts this object to a JSON-LD structure.
|
|
26652
26571
|
* @param options The options to use.
|
|
@@ -26682,18 +26601,11 @@ var Document = class Document extends Object$1 {
|
|
|
26682
26601
|
compactItems.push(item);
|
|
26683
26602
|
}
|
|
26684
26603
|
if (compactItems.length > 0) result["height"] = compactItems.length > 1 ? compactItems : compactItems[0];
|
|
26685
|
-
compactItems = [];
|
|
26686
|
-
for (const v of this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase) {
|
|
26687
|
-
const item = v;
|
|
26688
|
-
compactItems.push(item);
|
|
26689
|
-
}
|
|
26690
|
-
if (compactItems.length > 0) result["digestMultibase"] = compactItems.length > 1 ? compactItems : compactItems[0];
|
|
26691
26604
|
result["type"] = "Document";
|
|
26692
26605
|
if (this.id != null) result["id"] = formatIri(this.id);
|
|
26693
26606
|
result["@context"] = [
|
|
26694
26607
|
"https://www.w3.org/ns/activitystreams",
|
|
26695
|
-
"https://w3id.org/security/data-integrity/
|
|
26696
|
-
{ "digestMultibase": "https://www.w3.org/ns/credentials/v2#digestMultibase" },
|
|
26608
|
+
"https://w3id.org/security/data-integrity/v1",
|
|
26697
26609
|
"https://gotosocial.org/ns"
|
|
26698
26610
|
];
|
|
26699
26611
|
return result;
|
|
@@ -26722,19 +26634,12 @@ var Document = class Document extends Object$1 {
|
|
|
26722
26634
|
array.push(element);
|
|
26723
26635
|
}
|
|
26724
26636
|
if (array.length > 0) values["https://www.w3.org/ns/activitystreams#height"] = array;
|
|
26725
|
-
array = [];
|
|
26726
|
-
for (const v of this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase) {
|
|
26727
|
-
const element = { "@value": v };
|
|
26728
|
-
array.push(element);
|
|
26729
|
-
}
|
|
26730
|
-
if (array.length > 0) values["https://www.w3.org/ns/credentials/v2#digestMultibase"] = array;
|
|
26731
26637
|
values["@type"] = ["https://www.w3.org/ns/activitystreams#Document"];
|
|
26732
26638
|
if (this.id != null) values["@id"] = formatIri(this.id);
|
|
26733
26639
|
if (options.format === "expand") return await jsonld.expand(values, { documentLoader: options.contextLoader });
|
|
26734
26640
|
const docContext = options.context ?? [
|
|
26735
26641
|
"https://www.w3.org/ns/activitystreams",
|
|
26736
|
-
"https://w3id.org/security/data-integrity/
|
|
26737
|
-
{ "digestMultibase": "https://www.w3.org/ns/credentials/v2#digestMultibase" },
|
|
26642
|
+
"https://w3id.org/security/data-integrity/v1",
|
|
26738
26643
|
"https://gotosocial.org/ns"
|
|
26739
26644
|
];
|
|
26740
26645
|
const compacted = await jsonld.compact(values, docContext, { documentLoader: options.contextLoader });
|
|
@@ -26835,15 +26740,6 @@ var Document = class Document extends Object$1 {
|
|
|
26835
26740
|
_2cGKFeFJMmiNpGZFEF75mCwFQsKb_height.push(decoded);
|
|
26836
26741
|
}
|
|
26837
26742
|
instance.#_2cGKFeFJMmiNpGZFEF75mCwFQsKb_height = _2cGKFeFJMmiNpGZFEF75mCwFQsKb_height;
|
|
26838
|
-
const _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = [];
|
|
26839
|
-
let _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase__array = values["https://www.w3.org/ns/credentials/v2#digestMultibase"];
|
|
26840
|
-
for (const v of _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase__array == null ? [] : _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase__array.length === 1 && "@list" in _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase__array[0] ? _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase__array[0]["@list"] : _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase__array) {
|
|
26841
|
-
if (v == null) continue;
|
|
26842
|
-
const decoded = v["@value"];
|
|
26843
|
-
if (typeof decoded === "undefined") continue;
|
|
26844
|
-
_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase.push(decoded);
|
|
26845
|
-
}
|
|
26846
|
-
instance.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase;
|
|
26847
26743
|
if (!("_fromSubclass" in options) || !options._fromSubclass) try {
|
|
26848
26744
|
if (cacheJsonLd != null && cacheJsonLd !== expanded) {
|
|
26849
26745
|
const compactArray = Array.isArray(json) && json.length === 1;
|
|
@@ -26868,11 +26764,6 @@ var Document = class Document extends Object$1 {
|
|
|
26868
26764
|
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
26869
26765
|
} : v);
|
|
26870
26766
|
if (_2cGKFeFJMmiNpGZFEF75mCwFQsKb_height.length == 1) proxy.height = _2cGKFeFJMmiNpGZFEF75mCwFQsKb_height[0];
|
|
26871
|
-
const _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase.map((v) => v instanceof URL ? {
|
|
26872
|
-
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
26873
|
-
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
26874
|
-
} : v);
|
|
26875
|
-
if (_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase.length == 1) proxy.digestMultibase = _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase[0];
|
|
26876
26767
|
return proxy;
|
|
26877
26768
|
}
|
|
26878
26769
|
};
|
|
@@ -26942,8 +26833,7 @@ var Audio = class Audio extends Document {
|
|
|
26942
26833
|
if (this.id != null) result["id"] = formatIri(this.id);
|
|
26943
26834
|
result["@context"] = [
|
|
26944
26835
|
"https://www.w3.org/ns/activitystreams",
|
|
26945
|
-
"https://w3id.org/security/data-integrity/
|
|
26946
|
-
{ "digestMultibase": "https://www.w3.org/ns/credentials/v2#digestMultibase" },
|
|
26836
|
+
"https://w3id.org/security/data-integrity/v1",
|
|
26947
26837
|
"https://gotosocial.org/ns"
|
|
26948
26838
|
];
|
|
26949
26839
|
return result;
|
|
@@ -26958,8 +26848,7 @@ var Audio = class Audio extends Document {
|
|
|
26958
26848
|
if (options.format === "expand") return await jsonld.expand(values, { documentLoader: options.contextLoader });
|
|
26959
26849
|
const docContext = options.context ?? [
|
|
26960
26850
|
"https://www.w3.org/ns/activitystreams",
|
|
26961
|
-
"https://w3id.org/security/data-integrity/
|
|
26962
|
-
{ "digestMultibase": "https://www.w3.org/ns/credentials/v2#digestMultibase" },
|
|
26851
|
+
"https://w3id.org/security/data-integrity/v1",
|
|
26963
26852
|
"https://gotosocial.org/ns"
|
|
26964
26853
|
];
|
|
26965
26854
|
const compacted = await jsonld.compact(values, docContext, { documentLoader: options.contextLoader });
|
|
@@ -29710,7 +29599,6 @@ var Group = class Group extends Object$1 {
|
|
|
29710
29599
|
#_trust_axq166E2eZADq34V4MYUc8KMZdC_publicKey = /* @__PURE__ */ new Set();
|
|
29711
29600
|
#_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = [];
|
|
29712
29601
|
#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = /* @__PURE__ */ new Set();
|
|
29713
|
-
#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [];
|
|
29714
29602
|
#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [];
|
|
29715
29603
|
#_3ghX3VfZXXbLvhCRH7QJqpzLrXjB_inbox = [];
|
|
29716
29604
|
#_trust_3ghX3VfZXXbLvhCRH7QJqpzLrXjB_inbox = /* @__PURE__ */ new Set();
|
|
@@ -29779,13 +29667,6 @@ var Group = class Group extends Object$1 {
|
|
|
29779
29667
|
for (let i = 0; i < values.assertionMethods.length; i++) this.#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.add(i);
|
|
29780
29668
|
} else throw new TypeError("The assertionMethods must be an array of type Multikey | URL.");
|
|
29781
29669
|
}
|
|
29782
|
-
if ("gateway" in values && values.gateway != null) if (values.gateway instanceof URL && isGatewayUrl(values.gateway)) this.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [values.gateway];
|
|
29783
|
-
else throw new TypeError("The gateway must be of type URL.");
|
|
29784
|
-
if ("gateways" in values && values.gateways != null) {
|
|
29785
|
-
if ("gateway" in values && values.gateway != null) throw new TypeError("Cannot initialize both gateway and gateways at the same time.");
|
|
29786
|
-
if (Array.isArray(values.gateways) && values.gateways.every((v) => v instanceof URL && isGatewayUrl(v))) this.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = values.gateways;
|
|
29787
|
-
else throw new TypeError("The gateways must be an array of type URL.");
|
|
29788
|
-
}
|
|
29789
29670
|
if ("manuallyApprovesFollowers" in values && values.manuallyApprovesFollowers != null) if (typeof values.manuallyApprovesFollowers === "boolean") this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [values.manuallyApprovesFollowers];
|
|
29790
29671
|
else throw new TypeError("The manuallyApprovesFollowers must be of type boolean.");
|
|
29791
29672
|
if ("inbox" in values && values.inbox != null) if (values.inbox instanceof OrderedCollection || values.inbox instanceof OrderedCollectionPage || values.inbox instanceof URL) {
|
|
@@ -29916,14 +29797,6 @@ var Group = class Group extends Object$1 {
|
|
|
29916
29797
|
for (let i = 0; i < values.assertionMethods.length; i++) clone.#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.add(i);
|
|
29917
29798
|
} else throw new TypeError("The assertionMethods must be an array of type Multikey | URL.");
|
|
29918
29799
|
}
|
|
29919
|
-
clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = this.#_hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
29920
|
-
if ("gateway" in values && values.gateway != null) if (values.gateway instanceof URL && isGatewayUrl(values.gateway)) clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [values.gateway];
|
|
29921
|
-
else throw new TypeError("The gateway must be of type URL.");
|
|
29922
|
-
if ("gateways" in values && values.gateways != null) {
|
|
29923
|
-
if ("gateway" in values && values.gateway != null) throw new TypeError("Cannot update both gateway and gateways at the same time.");
|
|
29924
|
-
if (Array.isArray(values.gateways) && values.gateways.every((v) => v instanceof URL && isGatewayUrl(v))) clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = values.gateways;
|
|
29925
|
-
else throw new TypeError("The gateways must be an array of type URL.");
|
|
29926
|
-
}
|
|
29927
29800
|
clone.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers;
|
|
29928
29801
|
if ("manuallyApprovesFollowers" in values && values.manuallyApprovesFollowers != null) if (typeof values.manuallyApprovesFollowers === "boolean") clone.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [values.manuallyApprovesFollowers];
|
|
29929
29802
|
else throw new TypeError("The manuallyApprovesFollowers must be of type boolean.");
|
|
@@ -30397,24 +30270,6 @@ var Group = class Group extends Object$1 {
|
|
|
30397
30270
|
yield v;
|
|
30398
30271
|
}
|
|
30399
30272
|
}
|
|
30400
|
-
/** Gateways where the latest version of this portable actor object can be
|
|
30401
|
-
* retrieved.
|
|
30402
|
-
*
|
|
30403
|
-
* See [FEP-ef61](https://w3id.org/fep/ef61) for details.
|
|
30404
|
-
*/
|
|
30405
|
-
get gateway() {
|
|
30406
|
-
if (this._warning != null) getLogger(this._warning.category).warn(this._warning.message, this._warning.values);
|
|
30407
|
-
if (this.#_hQiaHhZP8hqxckxTBrpsGNs57E3.length < 1) return null;
|
|
30408
|
-
return this.#_hQiaHhZP8hqxckxTBrpsGNs57E3[0];
|
|
30409
|
-
}
|
|
30410
|
-
/** Gateways where the latest version of this portable actor object can be
|
|
30411
|
-
* retrieved.
|
|
30412
|
-
*
|
|
30413
|
-
* See [FEP-ef61](https://w3id.org/fep/ef61) for details.
|
|
30414
|
-
*/
|
|
30415
|
-
get gateways() {
|
|
30416
|
-
return this.#_hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
30417
|
-
}
|
|
30418
30273
|
/** When `true`, conveys that for this actor, follow requests are not usually
|
|
30419
30274
|
* automatically approved, but instead are examined by a person who may accept
|
|
30420
30275
|
* or reject the request, at some time in the future. Setting of `false`
|
|
@@ -32284,12 +32139,6 @@ var Group = class Group extends Object$1 {
|
|
|
32284
32139
|
}
|
|
32285
32140
|
if (compactItems.length > 0) result["assertionMethod"] = compactItems.length > 1 ? compactItems : compactItems[0];
|
|
32286
32141
|
compactItems = [];
|
|
32287
|
-
for (const v of this.#_hQiaHhZP8hqxckxTBrpsGNs57E3) {
|
|
32288
|
-
const item = formatIri(v);
|
|
32289
|
-
compactItems.push(item);
|
|
32290
|
-
}
|
|
32291
|
-
if (compactItems.length > 0) result["gateways"] = compactItems;
|
|
32292
|
-
compactItems = [];
|
|
32293
32142
|
for (const v of this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers) {
|
|
32294
32143
|
const item = v;
|
|
32295
32144
|
compactItems.push(item);
|
|
@@ -32505,7 +32354,6 @@ var Group = class Group extends Object$1 {
|
|
|
32505
32354
|
if (this.id != null) result["id"] = formatIri(this.id);
|
|
32506
32355
|
result["@context"] = [
|
|
32507
32356
|
"https://www.w3.org/ns/activitystreams",
|
|
32508
|
-
"https://w3id.org/fep/ef61",
|
|
32509
32357
|
"https://w3id.org/security/v1",
|
|
32510
32358
|
"https://w3id.org/security/data-integrity/v1",
|
|
32511
32359
|
"https://www.w3.org/ns/did/v1",
|
|
@@ -32578,12 +32426,6 @@ var Group = class Group extends Object$1 {
|
|
|
32578
32426
|
}
|
|
32579
32427
|
if (array.length > 0) values["https://w3id.org/security#assertionMethod"] = array;
|
|
32580
32428
|
array = [];
|
|
32581
|
-
for (const v of this.#_hQiaHhZP8hqxckxTBrpsGNs57E3) {
|
|
32582
|
-
const element = { "@id": formatIri(v) };
|
|
32583
|
-
array.push(element);
|
|
32584
|
-
}
|
|
32585
|
-
if (array.length > 0) values["https://w3id.org/fep/ef61/gateways"] = { "@list": array };
|
|
32586
|
-
array = [];
|
|
32587
32429
|
for (const v of this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers) {
|
|
32588
32430
|
const element = { "@value": v };
|
|
32589
32431
|
array.push(element);
|
|
@@ -32708,7 +32550,6 @@ var Group = class Group extends Object$1 {
|
|
|
32708
32550
|
if (options.format === "expand") return await jsonld.expand(values, { documentLoader: options.contextLoader });
|
|
32709
32551
|
const docContext = options.context ?? [
|
|
32710
32552
|
"https://www.w3.org/ns/activitystreams",
|
|
32711
|
-
"https://w3id.org/fep/ef61",
|
|
32712
32553
|
"https://w3id.org/security/v1",
|
|
32713
32554
|
"https://w3id.org/security/data-integrity/v1",
|
|
32714
32555
|
"https://www.w3.org/ns/did/v1",
|
|
@@ -32872,15 +32713,6 @@ var Group = class Group extends Object$1 {
|
|
|
32872
32713
|
_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.push(decoded);
|
|
32873
32714
|
}
|
|
32874
32715
|
instance.#_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod;
|
|
32875
|
-
const _hQiaHhZP8hqxckxTBrpsGNs57E3 = [];
|
|
32876
|
-
let _hQiaHhZP8hqxckxTBrpsGNs57E3__array = values["https://w3id.org/fep/ef61/gateways"];
|
|
32877
|
-
for (const v of _hQiaHhZP8hqxckxTBrpsGNs57E3__array == null ? [] : _hQiaHhZP8hqxckxTBrpsGNs57E3__array.length === 1 && "@list" in _hQiaHhZP8hqxckxTBrpsGNs57E3__array[0] ? _hQiaHhZP8hqxckxTBrpsGNs57E3__array[0]["@list"] : _hQiaHhZP8hqxckxTBrpsGNs57E3__array) {
|
|
32878
|
-
if (v == null) continue;
|
|
32879
|
-
const decoded = parseGatewayUrl(typeof v["@id"] === "string" ? v["@id"] : v["@value"]);
|
|
32880
|
-
if (typeof decoded === "undefined") continue;
|
|
32881
|
-
_hQiaHhZP8hqxckxTBrpsGNs57E3.push(decoded);
|
|
32882
|
-
}
|
|
32883
|
-
instance.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = _hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
32884
32716
|
const _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [];
|
|
32885
32717
|
let _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array = values["https://www.w3.org/ns/activitystreams#manuallyApprovesFollowers"];
|
|
32886
32718
|
for (const v of _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array == null ? [] : _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array.length === 1 && "@list" in _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array[0] ? _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array[0]["@list"] : _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array) {
|
|
@@ -33222,12 +33054,6 @@ var Group = class Group extends Object$1 {
|
|
|
33222
33054
|
} : v);
|
|
33223
33055
|
if (_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length == 1) proxy.assertionMethod = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod[0];
|
|
33224
33056
|
if (_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length > 1 || !("assertionMethod" in proxy) && _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length > 0) proxy.assertionMethods = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod;
|
|
33225
|
-
const _hQiaHhZP8hqxckxTBrpsGNs57E3 = this.#_hQiaHhZP8hqxckxTBrpsGNs57E3.map((v) => v instanceof URL ? {
|
|
33226
|
-
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
33227
|
-
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
33228
|
-
} : v);
|
|
33229
|
-
if (_hQiaHhZP8hqxckxTBrpsGNs57E3.length == 1) proxy.gateway = _hQiaHhZP8hqxckxTBrpsGNs57E3[0];
|
|
33230
|
-
if (_hQiaHhZP8hqxckxTBrpsGNs57E3.length > 1 || !("gateway" in proxy) && _hQiaHhZP8hqxckxTBrpsGNs57E3.length > 0) proxy.gateways = _hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
33231
33057
|
const _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers.map((v) => v instanceof URL ? {
|
|
33232
33058
|
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
33233
33059
|
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
@@ -33386,7 +33212,6 @@ var Link = class Link {
|
|
|
33386
33212
|
#_pVjLsybKQdmkjuU7MHjiVmNnuj7_href = [];
|
|
33387
33213
|
#_2a1c5GkfkQsnyyLybF8UXBQfFuHZ_rel = [];
|
|
33388
33214
|
#_3BLrzmscsjHCw8TF5BHRW9WkPnX8_mediaType = [];
|
|
33389
|
-
#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = [];
|
|
33390
33215
|
#_4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name = [];
|
|
33391
33216
|
#_f57HKWCp1YRBbTJE8PF12RbDJGf_hreflang = [];
|
|
33392
33217
|
#_2cGKFeFJMmiNpGZFEF75mCwFQsKb_height = [];
|
|
@@ -33418,8 +33243,6 @@ var Link = class Link {
|
|
|
33418
33243
|
}
|
|
33419
33244
|
if ("mediaType" in values && values.mediaType != null) if (typeof values.mediaType === "string") this.#_3BLrzmscsjHCw8TF5BHRW9WkPnX8_mediaType = [values.mediaType];
|
|
33420
33245
|
else throw new TypeError("The mediaType must be of type string.");
|
|
33421
|
-
if ("digestMultibase" in values && values.digestMultibase != null) if (typeof values.digestMultibase === "string") this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = [values.digestMultibase];
|
|
33422
|
-
else throw new TypeError("The digestMultibase must be of type string.");
|
|
33423
33246
|
if ("name" in values && values.name != null) if (typeof values.name === "string" || values.name instanceof LanguageString$1) this.#_4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name = [values.name];
|
|
33424
33247
|
else throw new TypeError("The name must be of type string | LanguageString.");
|
|
33425
33248
|
if ("names" in values && values.names != null) {
|
|
@@ -33467,9 +33290,6 @@ var Link = class Link {
|
|
|
33467
33290
|
clone.#_3BLrzmscsjHCw8TF5BHRW9WkPnX8_mediaType = this.#_3BLrzmscsjHCw8TF5BHRW9WkPnX8_mediaType;
|
|
33468
33291
|
if ("mediaType" in values && values.mediaType != null) if (typeof values.mediaType === "string") clone.#_3BLrzmscsjHCw8TF5BHRW9WkPnX8_mediaType = [values.mediaType];
|
|
33469
33292
|
else throw new TypeError("The mediaType must be of type string.");
|
|
33470
|
-
clone.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase;
|
|
33471
|
-
if ("digestMultibase" in values && values.digestMultibase != null) if (typeof values.digestMultibase === "string") clone.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = [values.digestMultibase];
|
|
33472
|
-
else throw new TypeError("The digestMultibase must be of type string.");
|
|
33473
33293
|
clone.#_4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name = this.#_4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name;
|
|
33474
33294
|
if ("name" in values && values.name != null) if (typeof values.name === "string" || values.name instanceof LanguageString$1) clone.#_4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name = [values.name];
|
|
33475
33295
|
else throw new TypeError("The name must be of type string | LanguageString.");
|
|
@@ -33533,15 +33353,6 @@ var Link = class Link {
|
|
|
33533
33353
|
if (this.#_3BLrzmscsjHCw8TF5BHRW9WkPnX8_mediaType.length < 1) return null;
|
|
33534
33354
|
return this.#_3BLrzmscsjHCw8TF5BHRW9WkPnX8_mediaType[0];
|
|
33535
33355
|
}
|
|
33536
|
-
/** The multibase-encoded integrity digest of the linked resource.
|
|
33537
|
-
*
|
|
33538
|
-
* See [FEP-ef61](https://w3id.org/fep/ef61) for details.
|
|
33539
|
-
*/
|
|
33540
|
-
get digestMultibase() {
|
|
33541
|
-
if (this._warning != null) getLogger(this._warning.category).warn(this._warning.message, this._warning.values);
|
|
33542
|
-
if (this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase.length < 1) return null;
|
|
33543
|
-
return this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase[0];
|
|
33544
|
-
}
|
|
33545
33356
|
/** A simple, human-readable, plain-text name for the object. HTML markup MUST
|
|
33546
33357
|
* NOT be included. The name MAY be expressed using multiple language-tagged
|
|
33547
33358
|
* values.
|
|
@@ -33754,12 +33565,6 @@ var Link = class Link {
|
|
|
33754
33565
|
}
|
|
33755
33566
|
if (compactItems.length > 0) result["mediaType"] = compactItems.length > 1 ? compactItems : compactItems[0];
|
|
33756
33567
|
compactItems = [];
|
|
33757
|
-
for (const v of this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase) {
|
|
33758
|
-
const item = v;
|
|
33759
|
-
compactItems.push(item);
|
|
33760
|
-
}
|
|
33761
|
-
if (compactItems.length > 0) result["digestMultibase"] = compactItems.length > 1 ? compactItems : compactItems[0];
|
|
33762
|
-
compactItems = [];
|
|
33763
33568
|
for (const v of this.#_4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name) {
|
|
33764
33569
|
const item = typeof v === "string" ? v : {
|
|
33765
33570
|
"@value": v.toString(),
|
|
@@ -33802,7 +33607,7 @@ var Link = class Link {
|
|
|
33802
33607
|
if (compactItems.length > 0) result["preview"] = compactItems.length > 1 ? compactItems : compactItems[0];
|
|
33803
33608
|
result["type"] = "Link";
|
|
33804
33609
|
if (this.id != null) result["id"] = formatIri(this.id);
|
|
33805
|
-
result["@context"] =
|
|
33610
|
+
result["@context"] = "https://www.w3.org/ns/activitystreams";
|
|
33806
33611
|
return result;
|
|
33807
33612
|
}
|
|
33808
33613
|
let array;
|
|
@@ -33826,12 +33631,6 @@ var Link = class Link {
|
|
|
33826
33631
|
}
|
|
33827
33632
|
if (array.length > 0) values["https://www.w3.org/ns/activitystreams#mediaType"] = array;
|
|
33828
33633
|
array = [];
|
|
33829
|
-
for (const v of this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase) {
|
|
33830
|
-
const element = { "@value": v };
|
|
33831
|
-
array.push(element);
|
|
33832
|
-
}
|
|
33833
|
-
if (array.length > 0) values["https://www.w3.org/ns/credentials/v2#digestMultibase"] = array;
|
|
33834
|
-
array = [];
|
|
33835
33634
|
for (const v of this.#_4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name) {
|
|
33836
33635
|
const element = typeof v === "string" ? { "@value": v } : {
|
|
33837
33636
|
"@value": v.toString(),
|
|
@@ -33873,7 +33672,7 @@ var Link = class Link {
|
|
|
33873
33672
|
values["@type"] = ["https://www.w3.org/ns/activitystreams#Link"];
|
|
33874
33673
|
if (this.id != null) values["@id"] = formatIri(this.id);
|
|
33875
33674
|
if (options.format === "expand") return await jsonld.expand(values, { documentLoader: options.contextLoader });
|
|
33876
|
-
const docContext = options.context ??
|
|
33675
|
+
const docContext = options.context ?? "https://www.w3.org/ns/activitystreams";
|
|
33877
33676
|
const compacted = await jsonld.compact(values, docContext, { documentLoader: options.contextLoader });
|
|
33878
33677
|
if (docContext != null) {}
|
|
33879
33678
|
return compacted;
|
|
@@ -33972,15 +33771,6 @@ var Link = class Link {
|
|
|
33972
33771
|
_3BLrzmscsjHCw8TF5BHRW9WkPnX8_mediaType.push(decoded);
|
|
33973
33772
|
}
|
|
33974
33773
|
instance.#_3BLrzmscsjHCw8TF5BHRW9WkPnX8_mediaType = _3BLrzmscsjHCw8TF5BHRW9WkPnX8_mediaType;
|
|
33975
|
-
const _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = [];
|
|
33976
|
-
let _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase__array = values["https://www.w3.org/ns/credentials/v2#digestMultibase"];
|
|
33977
|
-
for (const v of _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase__array == null ? [] : _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase__array.length === 1 && "@list" in _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase__array[0] ? _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase__array[0]["@list"] : _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase__array) {
|
|
33978
|
-
if (v == null) continue;
|
|
33979
|
-
const decoded = v["@value"];
|
|
33980
|
-
if (typeof decoded === "undefined") continue;
|
|
33981
|
-
_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase.push(decoded);
|
|
33982
|
-
}
|
|
33983
|
-
instance.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase;
|
|
33984
33774
|
const _4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name = [];
|
|
33985
33775
|
let _4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name__array = values["https://www.w3.org/ns/activitystreams#name"];
|
|
33986
33776
|
for (const v of _4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name__array == null ? [] : _4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name__array.length === 1 && "@list" in _4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name__array[0] ? _4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name__array[0]["@list"] : _4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name__array) {
|
|
@@ -34145,11 +33935,6 @@ var Link = class Link {
|
|
|
34145
33935
|
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
34146
33936
|
} : v);
|
|
34147
33937
|
if (_3BLrzmscsjHCw8TF5BHRW9WkPnX8_mediaType.length == 1) proxy.mediaType = _3BLrzmscsjHCw8TF5BHRW9WkPnX8_mediaType[0];
|
|
34148
|
-
const _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase = this.#_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase.map((v) => v instanceof URL ? {
|
|
34149
|
-
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
34150
|
-
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
34151
|
-
} : v);
|
|
34152
|
-
if (_2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase.length == 1) proxy.digestMultibase = _2ydcBe182LRq82jFGE6Rxw6VfvEM_digestMultibase[0];
|
|
34153
33938
|
const _4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name = this.#_4ZHbBuK7PrsvGgrjM8wgc6KMWjav_name.map((v) => v instanceof URL ? {
|
|
34154
33939
|
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
34155
33940
|
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
@@ -34412,8 +34197,7 @@ var Image = class Image extends Document {
|
|
|
34412
34197
|
if (this.id != null) result["id"] = formatIri(this.id);
|
|
34413
34198
|
result["@context"] = [
|
|
34414
34199
|
"https://www.w3.org/ns/activitystreams",
|
|
34415
|
-
"https://w3id.org/security/data-integrity/
|
|
34416
|
-
{ "digestMultibase": "https://www.w3.org/ns/credentials/v2#digestMultibase" },
|
|
34200
|
+
"https://w3id.org/security/data-integrity/v1",
|
|
34417
34201
|
"https://gotosocial.org/ns"
|
|
34418
34202
|
];
|
|
34419
34203
|
return result;
|
|
@@ -34428,8 +34212,7 @@ var Image = class Image extends Document {
|
|
|
34428
34212
|
if (options.format === "expand") return await jsonld.expand(values, { documentLoader: options.contextLoader });
|
|
34429
34213
|
const docContext = options.context ?? [
|
|
34430
34214
|
"https://www.w3.org/ns/activitystreams",
|
|
34431
|
-
"https://w3id.org/security/data-integrity/
|
|
34432
|
-
{ "digestMultibase": "https://www.w3.org/ns/credentials/v2#digestMultibase" },
|
|
34215
|
+
"https://w3id.org/security/data-integrity/v1",
|
|
34433
34216
|
"https://gotosocial.org/ns"
|
|
34434
34217
|
];
|
|
34435
34218
|
const compacted = await jsonld.compact(values, docContext, { documentLoader: options.contextLoader });
|
|
@@ -37040,7 +36823,6 @@ var Organization = class Organization extends Object$1 {
|
|
|
37040
36823
|
#_trust_axq166E2eZADq34V4MYUc8KMZdC_publicKey = /* @__PURE__ */ new Set();
|
|
37041
36824
|
#_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = [];
|
|
37042
36825
|
#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = /* @__PURE__ */ new Set();
|
|
37043
|
-
#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [];
|
|
37044
36826
|
#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [];
|
|
37045
36827
|
#_3ghX3VfZXXbLvhCRH7QJqpzLrXjB_inbox = [];
|
|
37046
36828
|
#_trust_3ghX3VfZXXbLvhCRH7QJqpzLrXjB_inbox = /* @__PURE__ */ new Set();
|
|
@@ -37109,13 +36891,6 @@ var Organization = class Organization extends Object$1 {
|
|
|
37109
36891
|
for (let i = 0; i < values.assertionMethods.length; i++) this.#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.add(i);
|
|
37110
36892
|
} else throw new TypeError("The assertionMethods must be an array of type Multikey | URL.");
|
|
37111
36893
|
}
|
|
37112
|
-
if ("gateway" in values && values.gateway != null) if (values.gateway instanceof URL && isGatewayUrl(values.gateway)) this.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [values.gateway];
|
|
37113
|
-
else throw new TypeError("The gateway must be of type URL.");
|
|
37114
|
-
if ("gateways" in values && values.gateways != null) {
|
|
37115
|
-
if ("gateway" in values && values.gateway != null) throw new TypeError("Cannot initialize both gateway and gateways at the same time.");
|
|
37116
|
-
if (Array.isArray(values.gateways) && values.gateways.every((v) => v instanceof URL && isGatewayUrl(v))) this.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = values.gateways;
|
|
37117
|
-
else throw new TypeError("The gateways must be an array of type URL.");
|
|
37118
|
-
}
|
|
37119
36894
|
if ("manuallyApprovesFollowers" in values && values.manuallyApprovesFollowers != null) if (typeof values.manuallyApprovesFollowers === "boolean") this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [values.manuallyApprovesFollowers];
|
|
37120
36895
|
else throw new TypeError("The manuallyApprovesFollowers must be of type boolean.");
|
|
37121
36896
|
if ("inbox" in values && values.inbox != null) if (values.inbox instanceof OrderedCollection || values.inbox instanceof OrderedCollectionPage || values.inbox instanceof URL) {
|
|
@@ -37246,14 +37021,6 @@ var Organization = class Organization extends Object$1 {
|
|
|
37246
37021
|
for (let i = 0; i < values.assertionMethods.length; i++) clone.#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.add(i);
|
|
37247
37022
|
} else throw new TypeError("The assertionMethods must be an array of type Multikey | URL.");
|
|
37248
37023
|
}
|
|
37249
|
-
clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = this.#_hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
37250
|
-
if ("gateway" in values && values.gateway != null) if (values.gateway instanceof URL && isGatewayUrl(values.gateway)) clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [values.gateway];
|
|
37251
|
-
else throw new TypeError("The gateway must be of type URL.");
|
|
37252
|
-
if ("gateways" in values && values.gateways != null) {
|
|
37253
|
-
if ("gateway" in values && values.gateway != null) throw new TypeError("Cannot update both gateway and gateways at the same time.");
|
|
37254
|
-
if (Array.isArray(values.gateways) && values.gateways.every((v) => v instanceof URL && isGatewayUrl(v))) clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = values.gateways;
|
|
37255
|
-
else throw new TypeError("The gateways must be an array of type URL.");
|
|
37256
|
-
}
|
|
37257
37024
|
clone.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers;
|
|
37258
37025
|
if ("manuallyApprovesFollowers" in values && values.manuallyApprovesFollowers != null) if (typeof values.manuallyApprovesFollowers === "boolean") clone.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [values.manuallyApprovesFollowers];
|
|
37259
37026
|
else throw new TypeError("The manuallyApprovesFollowers must be of type boolean.");
|
|
@@ -37727,24 +37494,6 @@ var Organization = class Organization extends Object$1 {
|
|
|
37727
37494
|
yield v;
|
|
37728
37495
|
}
|
|
37729
37496
|
}
|
|
37730
|
-
/** Gateways where the latest version of this portable actor object can be
|
|
37731
|
-
* retrieved.
|
|
37732
|
-
*
|
|
37733
|
-
* See [FEP-ef61](https://w3id.org/fep/ef61) for details.
|
|
37734
|
-
*/
|
|
37735
|
-
get gateway() {
|
|
37736
|
-
if (this._warning != null) getLogger(this._warning.category).warn(this._warning.message, this._warning.values);
|
|
37737
|
-
if (this.#_hQiaHhZP8hqxckxTBrpsGNs57E3.length < 1) return null;
|
|
37738
|
-
return this.#_hQiaHhZP8hqxckxTBrpsGNs57E3[0];
|
|
37739
|
-
}
|
|
37740
|
-
/** Gateways where the latest version of this portable actor object can be
|
|
37741
|
-
* retrieved.
|
|
37742
|
-
*
|
|
37743
|
-
* See [FEP-ef61](https://w3id.org/fep/ef61) for details.
|
|
37744
|
-
*/
|
|
37745
|
-
get gateways() {
|
|
37746
|
-
return this.#_hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
37747
|
-
}
|
|
37748
37497
|
/** When `true`, conveys that for this actor, follow requests are not usually
|
|
37749
37498
|
* automatically approved, but instead are examined by a person who may accept
|
|
37750
37499
|
* or reject the request, at some time in the future. Setting of `false`
|
|
@@ -39614,12 +39363,6 @@ var Organization = class Organization extends Object$1 {
|
|
|
39614
39363
|
}
|
|
39615
39364
|
if (compactItems.length > 0) result["assertionMethod"] = compactItems.length > 1 ? compactItems : compactItems[0];
|
|
39616
39365
|
compactItems = [];
|
|
39617
|
-
for (const v of this.#_hQiaHhZP8hqxckxTBrpsGNs57E3) {
|
|
39618
|
-
const item = formatIri(v);
|
|
39619
|
-
compactItems.push(item);
|
|
39620
|
-
}
|
|
39621
|
-
if (compactItems.length > 0) result["gateways"] = compactItems;
|
|
39622
|
-
compactItems = [];
|
|
39623
39366
|
for (const v of this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers) {
|
|
39624
39367
|
const item = v;
|
|
39625
39368
|
compactItems.push(item);
|
|
@@ -39835,7 +39578,6 @@ var Organization = class Organization extends Object$1 {
|
|
|
39835
39578
|
if (this.id != null) result["id"] = formatIri(this.id);
|
|
39836
39579
|
result["@context"] = [
|
|
39837
39580
|
"https://www.w3.org/ns/activitystreams",
|
|
39838
|
-
"https://w3id.org/fep/ef61",
|
|
39839
39581
|
"https://w3id.org/security/v1",
|
|
39840
39582
|
"https://w3id.org/security/data-integrity/v1",
|
|
39841
39583
|
"https://www.w3.org/ns/did/v1",
|
|
@@ -39908,12 +39650,6 @@ var Organization = class Organization extends Object$1 {
|
|
|
39908
39650
|
}
|
|
39909
39651
|
if (array.length > 0) values["https://w3id.org/security#assertionMethod"] = array;
|
|
39910
39652
|
array = [];
|
|
39911
|
-
for (const v of this.#_hQiaHhZP8hqxckxTBrpsGNs57E3) {
|
|
39912
|
-
const element = { "@id": formatIri(v) };
|
|
39913
|
-
array.push(element);
|
|
39914
|
-
}
|
|
39915
|
-
if (array.length > 0) values["https://w3id.org/fep/ef61/gateways"] = { "@list": array };
|
|
39916
|
-
array = [];
|
|
39917
39653
|
for (const v of this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers) {
|
|
39918
39654
|
const element = { "@value": v };
|
|
39919
39655
|
array.push(element);
|
|
@@ -40038,7 +39774,6 @@ var Organization = class Organization extends Object$1 {
|
|
|
40038
39774
|
if (options.format === "expand") return await jsonld.expand(values, { documentLoader: options.contextLoader });
|
|
40039
39775
|
const docContext = options.context ?? [
|
|
40040
39776
|
"https://www.w3.org/ns/activitystreams",
|
|
40041
|
-
"https://w3id.org/fep/ef61",
|
|
40042
39777
|
"https://w3id.org/security/v1",
|
|
40043
39778
|
"https://w3id.org/security/data-integrity/v1",
|
|
40044
39779
|
"https://www.w3.org/ns/did/v1",
|
|
@@ -40202,15 +39937,6 @@ var Organization = class Organization extends Object$1 {
|
|
|
40202
39937
|
_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.push(decoded);
|
|
40203
39938
|
}
|
|
40204
39939
|
instance.#_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod;
|
|
40205
|
-
const _hQiaHhZP8hqxckxTBrpsGNs57E3 = [];
|
|
40206
|
-
let _hQiaHhZP8hqxckxTBrpsGNs57E3__array = values["https://w3id.org/fep/ef61/gateways"];
|
|
40207
|
-
for (const v of _hQiaHhZP8hqxckxTBrpsGNs57E3__array == null ? [] : _hQiaHhZP8hqxckxTBrpsGNs57E3__array.length === 1 && "@list" in _hQiaHhZP8hqxckxTBrpsGNs57E3__array[0] ? _hQiaHhZP8hqxckxTBrpsGNs57E3__array[0]["@list"] : _hQiaHhZP8hqxckxTBrpsGNs57E3__array) {
|
|
40208
|
-
if (v == null) continue;
|
|
40209
|
-
const decoded = parseGatewayUrl(typeof v["@id"] === "string" ? v["@id"] : v["@value"]);
|
|
40210
|
-
if (typeof decoded === "undefined") continue;
|
|
40211
|
-
_hQiaHhZP8hqxckxTBrpsGNs57E3.push(decoded);
|
|
40212
|
-
}
|
|
40213
|
-
instance.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = _hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
40214
39940
|
const _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [];
|
|
40215
39941
|
let _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array = values["https://www.w3.org/ns/activitystreams#manuallyApprovesFollowers"];
|
|
40216
39942
|
for (const v of _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array == null ? [] : _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array.length === 1 && "@list" in _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array[0] ? _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array[0]["@list"] : _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array) {
|
|
@@ -40552,12 +40278,6 @@ var Organization = class Organization extends Object$1 {
|
|
|
40552
40278
|
} : v);
|
|
40553
40279
|
if (_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length == 1) proxy.assertionMethod = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod[0];
|
|
40554
40280
|
if (_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length > 1 || !("assertionMethod" in proxy) && _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length > 0) proxy.assertionMethods = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod;
|
|
40555
|
-
const _hQiaHhZP8hqxckxTBrpsGNs57E3 = this.#_hQiaHhZP8hqxckxTBrpsGNs57E3.map((v) => v instanceof URL ? {
|
|
40556
|
-
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
40557
|
-
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
40558
|
-
} : v);
|
|
40559
|
-
if (_hQiaHhZP8hqxckxTBrpsGNs57E3.length == 1) proxy.gateway = _hQiaHhZP8hqxckxTBrpsGNs57E3[0];
|
|
40560
|
-
if (_hQiaHhZP8hqxckxTBrpsGNs57E3.length > 1 || !("gateway" in proxy) && _hQiaHhZP8hqxckxTBrpsGNs57E3.length > 0) proxy.gateways = _hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
40561
40281
|
const _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers.map((v) => v instanceof URL ? {
|
|
40562
40282
|
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
40563
40283
|
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
@@ -40729,8 +40449,7 @@ var Page = class Page extends Document {
|
|
|
40729
40449
|
if (this.id != null) result["id"] = formatIri(this.id);
|
|
40730
40450
|
result["@context"] = [
|
|
40731
40451
|
"https://www.w3.org/ns/activitystreams",
|
|
40732
|
-
"https://w3id.org/security/data-integrity/
|
|
40733
|
-
{ "digestMultibase": "https://www.w3.org/ns/credentials/v2#digestMultibase" },
|
|
40452
|
+
"https://w3id.org/security/data-integrity/v1",
|
|
40734
40453
|
"https://gotosocial.org/ns"
|
|
40735
40454
|
];
|
|
40736
40455
|
return result;
|
|
@@ -40745,8 +40464,7 @@ var Page = class Page extends Document {
|
|
|
40745
40464
|
if (options.format === "expand") return await jsonld.expand(values, { documentLoader: options.contextLoader });
|
|
40746
40465
|
const docContext = options.context ?? [
|
|
40747
40466
|
"https://www.w3.org/ns/activitystreams",
|
|
40748
|
-
"https://w3id.org/security/data-integrity/
|
|
40749
|
-
{ "digestMultibase": "https://www.w3.org/ns/credentials/v2#digestMultibase" },
|
|
40467
|
+
"https://w3id.org/security/data-integrity/v1",
|
|
40750
40468
|
"https://gotosocial.org/ns"
|
|
40751
40469
|
];
|
|
40752
40470
|
const compacted = await jsonld.compact(values, docContext, { documentLoader: options.contextLoader });
|
|
@@ -40861,7 +40579,6 @@ var Person = class Person extends Object$1 {
|
|
|
40861
40579
|
#_trust_axq166E2eZADq34V4MYUc8KMZdC_publicKey = /* @__PURE__ */ new Set();
|
|
40862
40580
|
#_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = [];
|
|
40863
40581
|
#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = /* @__PURE__ */ new Set();
|
|
40864
|
-
#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [];
|
|
40865
40582
|
#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [];
|
|
40866
40583
|
#_3ghX3VfZXXbLvhCRH7QJqpzLrXjB_inbox = [];
|
|
40867
40584
|
#_trust_3ghX3VfZXXbLvhCRH7QJqpzLrXjB_inbox = /* @__PURE__ */ new Set();
|
|
@@ -40930,13 +40647,6 @@ var Person = class Person extends Object$1 {
|
|
|
40930
40647
|
for (let i = 0; i < values.assertionMethods.length; i++) this.#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.add(i);
|
|
40931
40648
|
} else throw new TypeError("The assertionMethods must be an array of type Multikey | URL.");
|
|
40932
40649
|
}
|
|
40933
|
-
if ("gateway" in values && values.gateway != null) if (values.gateway instanceof URL && isGatewayUrl(values.gateway)) this.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [values.gateway];
|
|
40934
|
-
else throw new TypeError("The gateway must be of type URL.");
|
|
40935
|
-
if ("gateways" in values && values.gateways != null) {
|
|
40936
|
-
if ("gateway" in values && values.gateway != null) throw new TypeError("Cannot initialize both gateway and gateways at the same time.");
|
|
40937
|
-
if (Array.isArray(values.gateways) && values.gateways.every((v) => v instanceof URL && isGatewayUrl(v))) this.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = values.gateways;
|
|
40938
|
-
else throw new TypeError("The gateways must be an array of type URL.");
|
|
40939
|
-
}
|
|
40940
40650
|
if ("manuallyApprovesFollowers" in values && values.manuallyApprovesFollowers != null) if (typeof values.manuallyApprovesFollowers === "boolean") this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [values.manuallyApprovesFollowers];
|
|
40941
40651
|
else throw new TypeError("The manuallyApprovesFollowers must be of type boolean.");
|
|
40942
40652
|
if ("inbox" in values && values.inbox != null) if (values.inbox instanceof OrderedCollection || values.inbox instanceof OrderedCollectionPage || values.inbox instanceof URL) {
|
|
@@ -41067,14 +40777,6 @@ var Person = class Person extends Object$1 {
|
|
|
41067
40777
|
for (let i = 0; i < values.assertionMethods.length; i++) clone.#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.add(i);
|
|
41068
40778
|
} else throw new TypeError("The assertionMethods must be an array of type Multikey | URL.");
|
|
41069
40779
|
}
|
|
41070
|
-
clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = this.#_hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
41071
|
-
if ("gateway" in values && values.gateway != null) if (values.gateway instanceof URL && isGatewayUrl(values.gateway)) clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [values.gateway];
|
|
41072
|
-
else throw new TypeError("The gateway must be of type URL.");
|
|
41073
|
-
if ("gateways" in values && values.gateways != null) {
|
|
41074
|
-
if ("gateway" in values && values.gateway != null) throw new TypeError("Cannot update both gateway and gateways at the same time.");
|
|
41075
|
-
if (Array.isArray(values.gateways) && values.gateways.every((v) => v instanceof URL && isGatewayUrl(v))) clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = values.gateways;
|
|
41076
|
-
else throw new TypeError("The gateways must be an array of type URL.");
|
|
41077
|
-
}
|
|
41078
40780
|
clone.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers;
|
|
41079
40781
|
if ("manuallyApprovesFollowers" in values && values.manuallyApprovesFollowers != null) if (typeof values.manuallyApprovesFollowers === "boolean") clone.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [values.manuallyApprovesFollowers];
|
|
41080
40782
|
else throw new TypeError("The manuallyApprovesFollowers must be of type boolean.");
|
|
@@ -41548,24 +41250,6 @@ var Person = class Person extends Object$1 {
|
|
|
41548
41250
|
yield v;
|
|
41549
41251
|
}
|
|
41550
41252
|
}
|
|
41551
|
-
/** Gateways where the latest version of this portable actor object can be
|
|
41552
|
-
* retrieved.
|
|
41553
|
-
*
|
|
41554
|
-
* See [FEP-ef61](https://w3id.org/fep/ef61) for details.
|
|
41555
|
-
*/
|
|
41556
|
-
get gateway() {
|
|
41557
|
-
if (this._warning != null) getLogger(this._warning.category).warn(this._warning.message, this._warning.values);
|
|
41558
|
-
if (this.#_hQiaHhZP8hqxckxTBrpsGNs57E3.length < 1) return null;
|
|
41559
|
-
return this.#_hQiaHhZP8hqxckxTBrpsGNs57E3[0];
|
|
41560
|
-
}
|
|
41561
|
-
/** Gateways where the latest version of this portable actor object can be
|
|
41562
|
-
* retrieved.
|
|
41563
|
-
*
|
|
41564
|
-
* See [FEP-ef61](https://w3id.org/fep/ef61) for details.
|
|
41565
|
-
*/
|
|
41566
|
-
get gateways() {
|
|
41567
|
-
return this.#_hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
41568
|
-
}
|
|
41569
41253
|
/** When `true`, conveys that for this actor, follow requests are not usually
|
|
41570
41254
|
* automatically approved, but instead are examined by a person who may accept
|
|
41571
41255
|
* or reject the request, at some time in the future. Setting of `false`
|
|
@@ -43435,12 +43119,6 @@ var Person = class Person extends Object$1 {
|
|
|
43435
43119
|
}
|
|
43436
43120
|
if (compactItems.length > 0) result["assertionMethod"] = compactItems.length > 1 ? compactItems : compactItems[0];
|
|
43437
43121
|
compactItems = [];
|
|
43438
|
-
for (const v of this.#_hQiaHhZP8hqxckxTBrpsGNs57E3) {
|
|
43439
|
-
const item = formatIri(v);
|
|
43440
|
-
compactItems.push(item);
|
|
43441
|
-
}
|
|
43442
|
-
if (compactItems.length > 0) result["gateways"] = compactItems;
|
|
43443
|
-
compactItems = [];
|
|
43444
43122
|
for (const v of this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers) {
|
|
43445
43123
|
const item = v;
|
|
43446
43124
|
compactItems.push(item);
|
|
@@ -43656,7 +43334,6 @@ var Person = class Person extends Object$1 {
|
|
|
43656
43334
|
if (this.id != null) result["id"] = formatIri(this.id);
|
|
43657
43335
|
result["@context"] = [
|
|
43658
43336
|
"https://www.w3.org/ns/activitystreams",
|
|
43659
|
-
"https://w3id.org/fep/ef61",
|
|
43660
43337
|
"https://w3id.org/security/v1",
|
|
43661
43338
|
"https://w3id.org/security/data-integrity/v1",
|
|
43662
43339
|
"https://www.w3.org/ns/did/v1",
|
|
@@ -43729,12 +43406,6 @@ var Person = class Person extends Object$1 {
|
|
|
43729
43406
|
}
|
|
43730
43407
|
if (array.length > 0) values["https://w3id.org/security#assertionMethod"] = array;
|
|
43731
43408
|
array = [];
|
|
43732
|
-
for (const v of this.#_hQiaHhZP8hqxckxTBrpsGNs57E3) {
|
|
43733
|
-
const element = { "@id": formatIri(v) };
|
|
43734
|
-
array.push(element);
|
|
43735
|
-
}
|
|
43736
|
-
if (array.length > 0) values["https://w3id.org/fep/ef61/gateways"] = { "@list": array };
|
|
43737
|
-
array = [];
|
|
43738
43409
|
for (const v of this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers) {
|
|
43739
43410
|
const element = { "@value": v };
|
|
43740
43411
|
array.push(element);
|
|
@@ -43859,7 +43530,6 @@ var Person = class Person extends Object$1 {
|
|
|
43859
43530
|
if (options.format === "expand") return await jsonld.expand(values, { documentLoader: options.contextLoader });
|
|
43860
43531
|
const docContext = options.context ?? [
|
|
43861
43532
|
"https://www.w3.org/ns/activitystreams",
|
|
43862
|
-
"https://w3id.org/fep/ef61",
|
|
43863
43533
|
"https://w3id.org/security/v1",
|
|
43864
43534
|
"https://w3id.org/security/data-integrity/v1",
|
|
43865
43535
|
"https://www.w3.org/ns/did/v1",
|
|
@@ -44023,15 +43693,6 @@ var Person = class Person extends Object$1 {
|
|
|
44023
43693
|
_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.push(decoded);
|
|
44024
43694
|
}
|
|
44025
43695
|
instance.#_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod;
|
|
44026
|
-
const _hQiaHhZP8hqxckxTBrpsGNs57E3 = [];
|
|
44027
|
-
let _hQiaHhZP8hqxckxTBrpsGNs57E3__array = values["https://w3id.org/fep/ef61/gateways"];
|
|
44028
|
-
for (const v of _hQiaHhZP8hqxckxTBrpsGNs57E3__array == null ? [] : _hQiaHhZP8hqxckxTBrpsGNs57E3__array.length === 1 && "@list" in _hQiaHhZP8hqxckxTBrpsGNs57E3__array[0] ? _hQiaHhZP8hqxckxTBrpsGNs57E3__array[0]["@list"] : _hQiaHhZP8hqxckxTBrpsGNs57E3__array) {
|
|
44029
|
-
if (v == null) continue;
|
|
44030
|
-
const decoded = parseGatewayUrl(typeof v["@id"] === "string" ? v["@id"] : v["@value"]);
|
|
44031
|
-
if (typeof decoded === "undefined") continue;
|
|
44032
|
-
_hQiaHhZP8hqxckxTBrpsGNs57E3.push(decoded);
|
|
44033
|
-
}
|
|
44034
|
-
instance.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = _hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
44035
43696
|
const _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [];
|
|
44036
43697
|
let _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array = values["https://www.w3.org/ns/activitystreams#manuallyApprovesFollowers"];
|
|
44037
43698
|
for (const v of _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array == null ? [] : _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array.length === 1 && "@list" in _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array[0] ? _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array[0]["@list"] : _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array) {
|
|
@@ -44373,12 +44034,6 @@ var Person = class Person extends Object$1 {
|
|
|
44373
44034
|
} : v);
|
|
44374
44035
|
if (_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length == 1) proxy.assertionMethod = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod[0];
|
|
44375
44036
|
if (_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length > 1 || !("assertionMethod" in proxy) && _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length > 0) proxy.assertionMethods = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod;
|
|
44376
|
-
const _hQiaHhZP8hqxckxTBrpsGNs57E3 = this.#_hQiaHhZP8hqxckxTBrpsGNs57E3.map((v) => v instanceof URL ? {
|
|
44377
|
-
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
44378
|
-
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
44379
|
-
} : v);
|
|
44380
|
-
if (_hQiaHhZP8hqxckxTBrpsGNs57E3.length == 1) proxy.gateway = _hQiaHhZP8hqxckxTBrpsGNs57E3[0];
|
|
44381
|
-
if (_hQiaHhZP8hqxckxTBrpsGNs57E3.length > 1 || !("gateway" in proxy) && _hQiaHhZP8hqxckxTBrpsGNs57E3.length > 0) proxy.gateways = _hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
44382
44037
|
const _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers.map((v) => v instanceof URL ? {
|
|
44383
44038
|
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
44384
44039
|
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
@@ -47613,7 +47268,6 @@ var Service = class Service extends Object$1 {
|
|
|
47613
47268
|
#_trust_axq166E2eZADq34V4MYUc8KMZdC_publicKey = /* @__PURE__ */ new Set();
|
|
47614
47269
|
#_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = [];
|
|
47615
47270
|
#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = /* @__PURE__ */ new Set();
|
|
47616
|
-
#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [];
|
|
47617
47271
|
#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [];
|
|
47618
47272
|
#_3ghX3VfZXXbLvhCRH7QJqpzLrXjB_inbox = [];
|
|
47619
47273
|
#_trust_3ghX3VfZXXbLvhCRH7QJqpzLrXjB_inbox = /* @__PURE__ */ new Set();
|
|
@@ -47682,13 +47336,6 @@ var Service = class Service extends Object$1 {
|
|
|
47682
47336
|
for (let i = 0; i < values.assertionMethods.length; i++) this.#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.add(i);
|
|
47683
47337
|
} else throw new TypeError("The assertionMethods must be an array of type Multikey | URL.");
|
|
47684
47338
|
}
|
|
47685
|
-
if ("gateway" in values && values.gateway != null) if (values.gateway instanceof URL && isGatewayUrl(values.gateway)) this.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [values.gateway];
|
|
47686
|
-
else throw new TypeError("The gateway must be of type URL.");
|
|
47687
|
-
if ("gateways" in values && values.gateways != null) {
|
|
47688
|
-
if ("gateway" in values && values.gateway != null) throw new TypeError("Cannot initialize both gateway and gateways at the same time.");
|
|
47689
|
-
if (Array.isArray(values.gateways) && values.gateways.every((v) => v instanceof URL && isGatewayUrl(v))) this.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = values.gateways;
|
|
47690
|
-
else throw new TypeError("The gateways must be an array of type URL.");
|
|
47691
|
-
}
|
|
47692
47339
|
if ("manuallyApprovesFollowers" in values && values.manuallyApprovesFollowers != null) if (typeof values.manuallyApprovesFollowers === "boolean") this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [values.manuallyApprovesFollowers];
|
|
47693
47340
|
else throw new TypeError("The manuallyApprovesFollowers must be of type boolean.");
|
|
47694
47341
|
if ("inbox" in values && values.inbox != null) if (values.inbox instanceof OrderedCollection || values.inbox instanceof OrderedCollectionPage || values.inbox instanceof URL) {
|
|
@@ -47819,14 +47466,6 @@ var Service = class Service extends Object$1 {
|
|
|
47819
47466
|
for (let i = 0; i < values.assertionMethods.length; i++) clone.#_trust_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.add(i);
|
|
47820
47467
|
} else throw new TypeError("The assertionMethods must be an array of type Multikey | URL.");
|
|
47821
47468
|
}
|
|
47822
|
-
clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = this.#_hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
47823
|
-
if ("gateway" in values && values.gateway != null) if (values.gateway instanceof URL && isGatewayUrl(values.gateway)) clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = [values.gateway];
|
|
47824
|
-
else throw new TypeError("The gateway must be of type URL.");
|
|
47825
|
-
if ("gateways" in values && values.gateways != null) {
|
|
47826
|
-
if ("gateway" in values && values.gateway != null) throw new TypeError("Cannot update both gateway and gateways at the same time.");
|
|
47827
|
-
if (Array.isArray(values.gateways) && values.gateways.every((v) => v instanceof URL && isGatewayUrl(v))) clone.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = values.gateways;
|
|
47828
|
-
else throw new TypeError("The gateways must be an array of type URL.");
|
|
47829
|
-
}
|
|
47830
47469
|
clone.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers;
|
|
47831
47470
|
if ("manuallyApprovesFollowers" in values && values.manuallyApprovesFollowers != null) if (typeof values.manuallyApprovesFollowers === "boolean") clone.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [values.manuallyApprovesFollowers];
|
|
47832
47471
|
else throw new TypeError("The manuallyApprovesFollowers must be of type boolean.");
|
|
@@ -48300,24 +47939,6 @@ var Service = class Service extends Object$1 {
|
|
|
48300
47939
|
yield v;
|
|
48301
47940
|
}
|
|
48302
47941
|
}
|
|
48303
|
-
/** Gateways where the latest version of this portable actor object can be
|
|
48304
|
-
* retrieved.
|
|
48305
|
-
*
|
|
48306
|
-
* See [FEP-ef61](https://w3id.org/fep/ef61) for details.
|
|
48307
|
-
*/
|
|
48308
|
-
get gateway() {
|
|
48309
|
-
if (this._warning != null) getLogger(this._warning.category).warn(this._warning.message, this._warning.values);
|
|
48310
|
-
if (this.#_hQiaHhZP8hqxckxTBrpsGNs57E3.length < 1) return null;
|
|
48311
|
-
return this.#_hQiaHhZP8hqxckxTBrpsGNs57E3[0];
|
|
48312
|
-
}
|
|
48313
|
-
/** Gateways where the latest version of this portable actor object can be
|
|
48314
|
-
* retrieved.
|
|
48315
|
-
*
|
|
48316
|
-
* See [FEP-ef61](https://w3id.org/fep/ef61) for details.
|
|
48317
|
-
*/
|
|
48318
|
-
get gateways() {
|
|
48319
|
-
return this.#_hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
48320
|
-
}
|
|
48321
47942
|
/** When `true`, conveys that for this actor, follow requests are not usually
|
|
48322
47943
|
* automatically approved, but instead are examined by a person who may accept
|
|
48323
47944
|
* or reject the request, at some time in the future. Setting of `false`
|
|
@@ -50187,12 +49808,6 @@ var Service = class Service extends Object$1 {
|
|
|
50187
49808
|
}
|
|
50188
49809
|
if (compactItems.length > 0) result["assertionMethod"] = compactItems.length > 1 ? compactItems : compactItems[0];
|
|
50189
49810
|
compactItems = [];
|
|
50190
|
-
for (const v of this.#_hQiaHhZP8hqxckxTBrpsGNs57E3) {
|
|
50191
|
-
const item = formatIri(v);
|
|
50192
|
-
compactItems.push(item);
|
|
50193
|
-
}
|
|
50194
|
-
if (compactItems.length > 0) result["gateways"] = compactItems;
|
|
50195
|
-
compactItems = [];
|
|
50196
49811
|
for (const v of this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers) {
|
|
50197
49812
|
const item = v;
|
|
50198
49813
|
compactItems.push(item);
|
|
@@ -50408,7 +50023,6 @@ var Service = class Service extends Object$1 {
|
|
|
50408
50023
|
if (this.id != null) result["id"] = formatIri(this.id);
|
|
50409
50024
|
result["@context"] = [
|
|
50410
50025
|
"https://www.w3.org/ns/activitystreams",
|
|
50411
|
-
"https://w3id.org/fep/ef61",
|
|
50412
50026
|
"https://w3id.org/security/v1",
|
|
50413
50027
|
"https://w3id.org/security/data-integrity/v1",
|
|
50414
50028
|
"https://www.w3.org/ns/did/v1",
|
|
@@ -50481,12 +50095,6 @@ var Service = class Service extends Object$1 {
|
|
|
50481
50095
|
}
|
|
50482
50096
|
if (array.length > 0) values["https://w3id.org/security#assertionMethod"] = array;
|
|
50483
50097
|
array = [];
|
|
50484
|
-
for (const v of this.#_hQiaHhZP8hqxckxTBrpsGNs57E3) {
|
|
50485
|
-
const element = { "@id": formatIri(v) };
|
|
50486
|
-
array.push(element);
|
|
50487
|
-
}
|
|
50488
|
-
if (array.length > 0) values["https://w3id.org/fep/ef61/gateways"] = { "@list": array };
|
|
50489
|
-
array = [];
|
|
50490
50098
|
for (const v of this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers) {
|
|
50491
50099
|
const element = { "@value": v };
|
|
50492
50100
|
array.push(element);
|
|
@@ -50611,7 +50219,6 @@ var Service = class Service extends Object$1 {
|
|
|
50611
50219
|
if (options.format === "expand") return await jsonld.expand(values, { documentLoader: options.contextLoader });
|
|
50612
50220
|
const docContext = options.context ?? [
|
|
50613
50221
|
"https://www.w3.org/ns/activitystreams",
|
|
50614
|
-
"https://w3id.org/fep/ef61",
|
|
50615
50222
|
"https://w3id.org/security/v1",
|
|
50616
50223
|
"https://w3id.org/security/data-integrity/v1",
|
|
50617
50224
|
"https://www.w3.org/ns/did/v1",
|
|
@@ -50775,15 +50382,6 @@ var Service = class Service extends Object$1 {
|
|
|
50775
50382
|
_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.push(decoded);
|
|
50776
50383
|
}
|
|
50777
50384
|
instance.#_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod;
|
|
50778
|
-
const _hQiaHhZP8hqxckxTBrpsGNs57E3 = [];
|
|
50779
|
-
let _hQiaHhZP8hqxckxTBrpsGNs57E3__array = values["https://w3id.org/fep/ef61/gateways"];
|
|
50780
|
-
for (const v of _hQiaHhZP8hqxckxTBrpsGNs57E3__array == null ? [] : _hQiaHhZP8hqxckxTBrpsGNs57E3__array.length === 1 && "@list" in _hQiaHhZP8hqxckxTBrpsGNs57E3__array[0] ? _hQiaHhZP8hqxckxTBrpsGNs57E3__array[0]["@list"] : _hQiaHhZP8hqxckxTBrpsGNs57E3__array) {
|
|
50781
|
-
if (v == null) continue;
|
|
50782
|
-
const decoded = parseGatewayUrl(typeof v["@id"] === "string" ? v["@id"] : v["@value"]);
|
|
50783
|
-
if (typeof decoded === "undefined") continue;
|
|
50784
|
-
_hQiaHhZP8hqxckxTBrpsGNs57E3.push(decoded);
|
|
50785
|
-
}
|
|
50786
|
-
instance.#_hQiaHhZP8hqxckxTBrpsGNs57E3 = _hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
50787
50385
|
const _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = [];
|
|
50788
50386
|
let _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array = values["https://www.w3.org/ns/activitystreams#manuallyApprovesFollowers"];
|
|
50789
50387
|
for (const v of _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array == null ? [] : _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array.length === 1 && "@list" in _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array[0] ? _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array[0]["@list"] : _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers__array) {
|
|
@@ -51125,12 +50723,6 @@ var Service = class Service extends Object$1 {
|
|
|
51125
50723
|
} : v);
|
|
51126
50724
|
if (_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length == 1) proxy.assertionMethod = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod[0];
|
|
51127
50725
|
if (_4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length > 1 || !("assertionMethod" in proxy) && _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod.length > 0) proxy.assertionMethods = _4EHQFWZSz1k1d4LmPrQiMba2GbP3_assertionMethod;
|
|
51128
|
-
const _hQiaHhZP8hqxckxTBrpsGNs57E3 = this.#_hQiaHhZP8hqxckxTBrpsGNs57E3.map((v) => v instanceof URL ? {
|
|
51129
|
-
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
51130
|
-
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
51131
|
-
} : v);
|
|
51132
|
-
if (_hQiaHhZP8hqxckxTBrpsGNs57E3.length == 1) proxy.gateway = _hQiaHhZP8hqxckxTBrpsGNs57E3[0];
|
|
51133
|
-
if (_hQiaHhZP8hqxckxTBrpsGNs57E3.length > 1 || !("gateway" in proxy) && _hQiaHhZP8hqxckxTBrpsGNs57E3.length > 0) proxy.gateways = _hQiaHhZP8hqxckxTBrpsGNs57E3;
|
|
51134
50726
|
const _36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers = this.#_36QNc9MxfkKf6h8sEUQSHnV9NZA_manuallyApprovesFollowers.map((v) => v instanceof URL ? {
|
|
51135
50727
|
[Symbol.for("Deno.customInspect")]: (inspect, options) => "URL " + inspect(v.href, options),
|
|
51136
50728
|
[Symbol.for("nodejs.util.inspect.custom")]: (_depth, options, inspect) => "URL " + inspect(v.href, options)
|
|
@@ -52775,8 +52367,7 @@ var Video = class Video extends Document {
|
|
|
52775
52367
|
if (this.id != null) result["id"] = formatIri(this.id);
|
|
52776
52368
|
result["@context"] = [
|
|
52777
52369
|
"https://www.w3.org/ns/activitystreams",
|
|
52778
|
-
"https://w3id.org/security/data-integrity/
|
|
52779
|
-
{ "digestMultibase": "https://www.w3.org/ns/credentials/v2#digestMultibase" },
|
|
52370
|
+
"https://w3id.org/security/data-integrity/v1",
|
|
52780
52371
|
"https://gotosocial.org/ns"
|
|
52781
52372
|
];
|
|
52782
52373
|
return result;
|
|
@@ -52791,8 +52382,7 @@ var Video = class Video extends Document {
|
|
|
52791
52382
|
if (options.format === "expand") return await jsonld.expand(values, { documentLoader: options.contextLoader });
|
|
52792
52383
|
const docContext = options.context ?? [
|
|
52793
52384
|
"https://www.w3.org/ns/activitystreams",
|
|
52794
|
-
"https://w3id.org/security/data-integrity/
|
|
52795
|
-
{ "digestMultibase": "https://www.w3.org/ns/credentials/v2#digestMultibase" },
|
|
52385
|
+
"https://w3id.org/security/data-integrity/v1",
|
|
52796
52386
|
"https://gotosocial.org/ns"
|
|
52797
52387
|
];
|
|
52798
52388
|
const compacted = await jsonld.compact(values, docContext, { documentLoader: options.contextLoader });
|