@singi-labs/sifa-sdk 0.18.12 → 0.18.14
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/index.cjs +29 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +30 -5
- package/dist/index.d.ts +30 -5
- package/dist/index.js +28 -2
- package/dist/index.js.map +1 -1
- package/dist/{network-map-Cwv7SsL0.d.cts → network-map-8RDsXsr0.d.cts} +3 -3
- package/dist/{network-map-5WbfyFed.d.ts → network-map-DnQvqpqi.d.ts} +3 -3
- package/dist/{org-BHz9ymjp.d.cts → org-0uCYKpq1.d.cts} +1 -1
- package/dist/{org-Bgz5parA.d.ts → org-DvnZsZx9.d.ts} +1 -1
- package/dist/{profile-investment-CmiQxk5C.d.cts → profile-investment-CIG7Hy8g.d.cts} +16 -1
- package/dist/{profile-investment-CmiQxk5C.d.ts → profile-investment-CIG7Hy8g.d.ts} +16 -1
- package/dist/{profile-summary-BnydsN4P.d.cts → profile-summary-B9EQmnC7.d.cts} +1 -1
- package/dist/{profile-summary-H-R1juYp.d.ts → profile-summary-nbzILRkf.d.ts} +1 -1
- package/dist/publishing/index.cjs +5 -0
- package/dist/publishing/index.cjs.map +1 -1
- package/dist/publishing/index.js +5 -0
- package/dist/publishing/index.js.map +1 -1
- package/dist/query/fetchers/index.cjs +5 -0
- package/dist/query/fetchers/index.cjs.map +1 -1
- package/dist/query/fetchers/index.d.cts +5 -5
- package/dist/query/fetchers/index.d.ts +5 -5
- package/dist/query/fetchers/index.js +5 -0
- package/dist/query/fetchers/index.js.map +1 -1
- package/dist/query/hooks/index.cjs +5 -0
- package/dist/query/hooks/index.cjs.map +1 -1
- package/dist/query/hooks/index.d.cts +4 -4
- package/dist/query/hooks/index.d.ts +4 -4
- package/dist/query/hooks/index.js +5 -0
- package/dist/query/hooks/index.js.map +1 -1
- package/dist/query/index.d.cts +7 -7
- package/dist/query/index.d.ts +7 -7
- package/dist/schemas/index.cjs +6 -0
- package/dist/schemas/index.cjs.map +1 -1
- package/dist/schemas/index.d.cts +1 -1
- package/dist/schemas/index.d.ts +1 -1
- package/dist/schemas/index.js +6 -1
- package/dist/schemas/index.js.map +1 -1
- package/dist/schemas/write/index.cjs +7 -2
- package/dist/schemas/write/index.cjs.map +1 -1
- package/dist/schemas/write/index.js +7 -2
- package/dist/schemas/write/index.js.map +1 -1
- package/dist/{types-Co7D0VfD.d.ts → types-DqVbTzXo.d.ts} +8 -0
- package/dist/{types-LElwqDU4.d.cts → types-XejLm3AA.d.cts} +8 -0
- package/dist/{use-org-notification-emails-vNekuQKF.d.cts → use-org-notification-emails-BL2q3Vf2.d.cts} +2 -2
- package/dist/{use-org-notification-emails-C9CWyhSC.d.ts → use-org-notification-emails-BznKD18w.d.ts} +2 -2
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -4283,6 +4283,11 @@ var externalRecordRefSchema = zod.z.object({
|
|
|
4283
4283
|
uri: atUriSchema,
|
|
4284
4284
|
cid: cidSchema.optional()
|
|
4285
4285
|
});
|
|
4286
|
+
var agentRefSchema = zod.z.object({
|
|
4287
|
+
name: zod.z.string().min(1).refine(maxGraphemes(256)).max(2560),
|
|
4288
|
+
did: didSchema.optional(),
|
|
4289
|
+
entityRef: uriSchema.optional()
|
|
4290
|
+
}).passthrough();
|
|
4286
4291
|
var selfLabelsSchema = zod.z.object({
|
|
4287
4292
|
$type: zod.z.literal("com.atproto.label.defs#selfLabels").optional(),
|
|
4288
4293
|
values: zod.z.array(zod.z.object({ val: zod.z.string() }))
|
|
@@ -5217,6 +5222,27 @@ function isLinked(entityRef) {
|
|
|
5217
5222
|
return classifyEntityRef(entityRef) !== "unlinked";
|
|
5218
5223
|
}
|
|
5219
5224
|
|
|
5225
|
+
// src/logic/agent-ref.ts
|
|
5226
|
+
function clean3(value) {
|
|
5227
|
+
const trimmed = value?.trim();
|
|
5228
|
+
return trimmed ? trimmed : void 0;
|
|
5229
|
+
}
|
|
5230
|
+
function normalize2(name, did, entityRef) {
|
|
5231
|
+
const out = { name };
|
|
5232
|
+
const d = clean3(did);
|
|
5233
|
+
const e = clean3(entityRef);
|
|
5234
|
+
if (d) out.did = d;
|
|
5235
|
+
if (e) out.entityRef = e;
|
|
5236
|
+
return out;
|
|
5237
|
+
}
|
|
5238
|
+
function resolveAgentRef(nested, flat) {
|
|
5239
|
+
const nestedName = clean3(nested?.name);
|
|
5240
|
+
if (nestedName) return normalize2(nestedName, nested?.did, nested?.entityRef);
|
|
5241
|
+
const flatName = clean3(flat?.name);
|
|
5242
|
+
if (flatName) return normalize2(flatName, flat?.did, flat?.entityRef);
|
|
5243
|
+
return void 0;
|
|
5244
|
+
}
|
|
5245
|
+
|
|
5220
5246
|
// src/logic/org-floor.ts
|
|
5221
5247
|
var KNOWN_HANDLE_HOST_SUFFIXES = [
|
|
5222
5248
|
".bsky.social",
|
|
@@ -6201,7 +6227,7 @@ function describeSifaRecord(collection, value) {
|
|
|
6201
6227
|
}
|
|
6202
6228
|
|
|
6203
6229
|
// src/index.ts
|
|
6204
|
-
var SIFA_SDK_VERSION = "0.18.
|
|
6230
|
+
var SIFA_SDK_VERSION = "0.18.14";
|
|
6205
6231
|
|
|
6206
6232
|
exports.ACTIVITY_TIERS = ACTIVITY_TIERS;
|
|
6207
6233
|
exports.ACTIVITY_VERBS = ACTIVITY_VERBS;
|
|
@@ -6315,6 +6341,7 @@ exports.VERIFICATION_PROVIDERS = VERIFICATION_PROVIDERS;
|
|
|
6315
6341
|
exports.WORKPLACE_TYPE_LABELS = WORKPLACE_TYPE_LABELS;
|
|
6316
6342
|
exports.WORKPLACE_TYPE_OPTIONS = WORKPLACE_TYPE_OPTIONS;
|
|
6317
6343
|
exports.actorShowsIdentity = actorShowsIdentity;
|
|
6344
|
+
exports.agentRefSchema = agentRefSchema;
|
|
6318
6345
|
exports.atUriSchema = atUriSchema;
|
|
6319
6346
|
exports.buildMetaDescription = buildMetaDescription;
|
|
6320
6347
|
exports.buildTalkSlug = buildTalkSlug;
|
|
@@ -6443,6 +6470,7 @@ exports.rendersCompanyProfile = rendersCompanyProfile;
|
|
|
6443
6470
|
exports.rendersPersonalProfile = rendersPersonalProfile;
|
|
6444
6471
|
exports.repoGroupForCollection = repoGroupForCollection;
|
|
6445
6472
|
exports.resolveAccountFacetMode = resolveAccountFacetMode;
|
|
6473
|
+
exports.resolveAgentRef = resolveAgentRef;
|
|
6446
6474
|
exports.resolveCardHealth = resolveCardHealth;
|
|
6447
6475
|
exports.resolveCardUrl = resolveCardUrl;
|
|
6448
6476
|
exports.resolveEmbed = resolveEmbed;
|