@singi-labs/sifa-sdk 0.22.0 → 0.23.0
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/{follow-profile-CgLLLQtJ.d.cts → follow-profile-BG_6eZwW.d.cts} +1 -1
- package/dist/{follow-profile-CVcA2w1v.d.ts → follow-profile-DGZzB5iM.d.ts} +1 -1
- package/dist/{index-BQAKeEoj.d.cts → index-BKvI1Bvg.d.cts} +1 -1
- package/dist/{index-DDh2RLvx.d.ts → index-BR8LDBo1.d.ts} +1 -1
- package/dist/index.cjs +30 -7
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +11 -11
- package/dist/index.d.ts +11 -11
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/dist/jsonld/index.d.cts +2 -2
- package/dist/jsonld/index.d.ts +2 -2
- package/dist/{network-map-2OKh3wSB.d.ts → network-map-CMyjk6jc.d.ts} +4 -4
- package/dist/{network-map-DJonNOl0.d.cts → network-map-CqLYThmY.d.cts} +4 -4
- package/dist/{org-settings-BShvhyFp.d.ts → org-settings-BliQdqbB.d.cts} +57 -1
- package/dist/{profile-investment-QSwX2GL5.d.cts → profile-investment-BmuXFlZw.d.cts} +2 -0
- package/dist/{profile-investment-QSwX2GL5.d.ts → profile-investment-BmuXFlZw.d.ts} +2 -0
- package/dist/{org-settings-C73Sin5E.d.cts → profile-self-D59D_rhI.d.ts} +57 -1
- package/dist/{profile-summary-BCOKt3qS.d.cts → profile-summary-CoTNGDpt.d.cts} +1 -1
- package/dist/{profile-summary-DF8-evvA.d.ts → profile-summary-Sv6rqQbx.d.ts} +1 -1
- package/dist/publishing/index.cjs +21 -1
- package/dist/publishing/index.cjs.map +1 -1
- package/dist/query/fetchers/index.cjs +21 -1
- package/dist/query/fetchers/index.cjs.map +1 -1
- package/dist/query/fetchers/index.d.cts +9 -9
- package/dist/query/fetchers/index.d.ts +9 -9
- package/dist/query/fetchers/profile-mutations.js.map +1 -1
- package/dist/query/hooks/index.cjs +21 -1
- package/dist/query/hooks/index.cjs.map +1 -1
- package/dist/query/hooks/index.d.cts +7 -7
- package/dist/query/hooks/index.d.ts +7 -7
- package/dist/query/index.cjs.map +1 -1
- package/dist/query/index.d.cts +12 -12
- package/dist/query/index.d.ts +12 -12
- package/dist/resume/index.d.cts +2 -2
- package/dist/resume/index.d.ts +2 -2
- package/dist/schemas/index.cjs +29 -6
- package/dist/schemas/index.cjs.map +1 -1
- package/dist/schemas/index.d.cts +3 -3
- package/dist/schemas/index.d.ts +3 -3
- package/dist/schemas/index.js +2 -0
- package/dist/schemas/index.js.map +1 -1
- package/dist/schemas/profile-self.js +18 -6
- package/dist/schemas/profile-self.js.map +1 -1
- package/dist/schemas/shared.js +28 -1
- package/dist/schemas/shared.js.map +1 -1
- package/dist/schemas/write/index.cjs +33 -6
- package/dist/schemas/write/index.cjs.map +1 -1
- package/dist/schemas/write/index.d.cts +2 -45
- package/dist/schemas/write/index.d.ts +2 -45
- package/dist/schemas/write/index.js +5 -1
- package/dist/schemas/write/index.js.map +1 -1
- package/dist/schemas/write/profile-self.js +19 -5
- package/dist/schemas/write/profile-self.js.map +1 -1
- package/dist/testing/index.d.cts +2 -2
- package/dist/testing/index.d.ts +2 -2
- package/dist/{types-JydVIhN5.d.cts → types-BC4A9-W9.d.cts} +2 -2
- package/dist/{types-CkomzDlY.d.ts → types-CcVRIHcX.d.ts} +2 -2
- package/dist/{use-user-settings-DQ6Dyby7.d.ts → use-user-settings-CI9eZQpp.d.ts} +11 -6
- package/dist/{use-user-settings-Bn6g8bgr.d.cts → use-user-settings-CfQKSBAC.d.cts} +11 -6
- package/dist/{user-settings-BdNrDa9O.d.ts → user-settings-BVFxLAOa.d.cts} +6 -11
- package/dist/{user-settings-C8JUD4DM.d.cts → user-settings-C65eFsPR.d.ts} +6 -11
- package/dist/{verification-providers-DeyGqaoC.d.cts → verification-providers-DQLIOSCK.d.cts} +7 -1
- package/dist/{verification-providers-DeyGqaoC.d.ts → verification-providers-DQLIOSCK.d.ts} +7 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { a as AccountVerification } from './verification-providers-
|
|
2
|
+
import { a as AccountVerification } from './verification-providers-DQLIOSCK.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* A single typeahead row. Discriminated on `source`: a curated `entity` row
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { a as AccountVerification } from './verification-providers-
|
|
2
|
+
import { a as AccountVerification } from './verification-providers-DQLIOSCK.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* A single typeahead row. Discriminated on `source`: a curated `entity` row
|
package/dist/index.cjs
CHANGED
|
@@ -3841,8 +3841,8 @@ var presentationLinkSchema = zod.z.object({
|
|
|
3841
3841
|
type: zod.z.string().max(256).nullable().optional()
|
|
3842
3842
|
});
|
|
3843
3843
|
function maxGraphemes(max) {
|
|
3844
|
+
const segmenter = new Intl.Segmenter(void 0, { granularity: "grapheme" });
|
|
3844
3845
|
return (value) => {
|
|
3845
|
-
const segmenter = new Intl.Segmenter(void 0, { granularity: "grapheme" });
|
|
3846
3846
|
let count = 0;
|
|
3847
3847
|
for (const _ of segmenter.segment(value)) {
|
|
3848
3848
|
count++;
|
|
@@ -3851,6 +3851,26 @@ function maxGraphemes(max) {
|
|
|
3851
3851
|
return true;
|
|
3852
3852
|
};
|
|
3853
3853
|
}
|
|
3854
|
+
function maxBytes(max) {
|
|
3855
|
+
const encoder = new TextEncoder();
|
|
3856
|
+
return (value) => {
|
|
3857
|
+
if (value.length * 3 <= max) return true;
|
|
3858
|
+
return encoder.encode(value).length <= max;
|
|
3859
|
+
};
|
|
3860
|
+
}
|
|
3861
|
+
function lexiconString(graphemes, bytes) {
|
|
3862
|
+
return zod.z.string().refine(maxGraphemes(graphemes), {
|
|
3863
|
+
message: `Must be at most ${graphemes} characters`,
|
|
3864
|
+
abort: true
|
|
3865
|
+
}).refine(maxBytes(bytes), {
|
|
3866
|
+
message: "This text is too long. Emoji and some scripts take more space, so shorten it a little."
|
|
3867
|
+
});
|
|
3868
|
+
}
|
|
3869
|
+
var profileDisplayNameSchema = lexiconString(64, 640);
|
|
3870
|
+
var profileNameSchema = lexiconString(64, 640);
|
|
3871
|
+
var profilePronounsSchema = lexiconString(20, 200);
|
|
3872
|
+
var profileHeadlineSchema = lexiconString(120, 1200);
|
|
3873
|
+
var profileAboutSchema = lexiconString(5e3, 5e4);
|
|
3854
3874
|
var didSchema = zod.z.string().regex(/^did:[a-z]+:[a-zA-Z0-9._:%-]+$/, "Invalid DID");
|
|
3855
3875
|
var datetimeSchema = zod.z.string().datetime({ offset: true });
|
|
3856
3876
|
var partialDateSchema = zod.z.string().regex(/^\d{4}(-\d{2}(-\d{2}(T.+)?)?)?$/, "Expected YYYY, YYYY-MM, YYYY-MM-DD, or a datetime");
|
|
@@ -7685,12 +7705,14 @@ var ProfilePublicationRecordSchema = zod.z.object({
|
|
|
7685
7705
|
createdAt: datetimeSchema
|
|
7686
7706
|
});
|
|
7687
7707
|
var ProfileSelfRecordSchema = zod.z.object({
|
|
7688
|
-
|
|
7689
|
-
|
|
7708
|
+
displayName: profileDisplayNameSchema.optional(),
|
|
7709
|
+
pronouns: profilePronounsSchema.optional(),
|
|
7710
|
+
headline: profileHeadlineSchema.optional(),
|
|
7711
|
+
about: profileAboutSchema.optional(),
|
|
7690
7712
|
industry: zod.z.string().refine(maxGraphemes(100)).max(1e3).optional(),
|
|
7691
|
-
givenName:
|
|
7692
|
-
familyName:
|
|
7693
|
-
namePronunciation:
|
|
7713
|
+
givenName: profileNameSchema.optional(),
|
|
7714
|
+
familyName: profileNameSchema.optional(),
|
|
7715
|
+
namePronunciation: profileNameSchema.optional(),
|
|
7694
7716
|
location: zod.z.unknown().optional(),
|
|
7695
7717
|
openTo: zod.z.array(zod.z.string()).max(10).optional(),
|
|
7696
7718
|
preferredWorkplace: zod.z.array(zod.z.string()).max(3).optional(),
|
|
@@ -8010,7 +8032,7 @@ function describeSifaRecord(collection, value) {
|
|
|
8010
8032
|
}
|
|
8011
8033
|
|
|
8012
8034
|
// src/index.ts
|
|
8013
|
-
var SIFA_SDK_VERSION = "0.
|
|
8035
|
+
var SIFA_SDK_VERSION = "0.23.0";
|
|
8014
8036
|
|
|
8015
8037
|
exports.ACTIVITY_TIERS = ACTIVITY_TIERS;
|
|
8016
8038
|
exports.ACTIVITY_VERBS = ACTIVITY_VERBS;
|
|
@@ -8285,6 +8307,7 @@ exports.looksLikeDomain = looksLikeDomain;
|
|
|
8285
8307
|
exports.makeGraphFollowRecordSchema = makeGraphFollowRecordSchema;
|
|
8286
8308
|
exports.matchesSiteActivityPreset = matchesSiteActivityPreset;
|
|
8287
8309
|
exports.matchesSitePresetTags = matchesSitePresetTags;
|
|
8310
|
+
exports.maxBytes = maxBytes;
|
|
8288
8311
|
exports.maxGraphemes = maxGraphemes;
|
|
8289
8312
|
exports.meetsContrastAA = meetsContrastAA;
|
|
8290
8313
|
exports.normalizeCompanyKey = normalizeCompanyKey;
|