@singi-labs/sifa-sdk 0.12.32 → 0.12.34
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/{feed-D2ZV8Eaj.d.cts → feed-C8aHEPw4.d.cts} +5 -0
- package/dist/{feed-D2ZV8Eaj.d.ts → feed-C8aHEPw4.d.ts} +5 -0
- package/dist/{index-CQx2Yk7v.d.ts → index-Bf_BI0TG.d.ts} +3 -13
- package/dist/{index-D4DUzpXJ.d.ts → index-CBx6UJvX.d.ts} +15 -3
- package/dist/{index-DX-0n-2z.d.cts → index-CEoJMzkP.d.cts} +3 -13
- package/dist/{index-XXLVtfGw.d.cts → index-DMN5tQBL.d.cts} +15 -3
- package/dist/index.cjs +9 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +9 -1
- package/dist/index.js.map +1 -1
- package/dist/{org-5dARVOZ9.d.ts → org-C8LR9MpF.d.ts} +29 -2
- package/dist/{org-DOQL077g.d.cts → org-OFRiuRqU.d.cts} +29 -2
- package/dist/query/fetchers/index.cjs +8 -0
- package/dist/query/fetchers/index.cjs.map +1 -1
- package/dist/query/fetchers/index.d.cts +3 -3
- package/dist/query/fetchers/index.d.ts +3 -3
- package/dist/query/fetchers/index.js +8 -0
- package/dist/query/fetchers/index.js.map +1 -1
- package/dist/query/hooks/index.cjs +33 -0
- package/dist/query/hooks/index.cjs.map +1 -1
- package/dist/query/hooks/index.d.cts +3 -3
- package/dist/query/hooks/index.d.ts +3 -3
- package/dist/query/hooks/index.js +33 -1
- package/dist/query/hooks/index.js.map +1 -1
- package/dist/query/index.cjs +34 -0
- package/dist/query/index.cjs.map +1 -1
- package/dist/query/index.d.cts +5 -5
- package/dist/query/index.d.ts +5 -5
- package/dist/query/index.js +33 -1
- package/dist/query/index.js.map +1 -1
- package/dist/schemas/index.cjs +8 -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 +8 -0
- package/dist/schemas/index.js.map +1 -1
- package/package.json +1 -1
package/dist/query/index.cjs
CHANGED
|
@@ -329,6 +329,12 @@ function updateSkill(config, rkey, data, options = {}) {
|
|
|
329
329
|
...options
|
|
330
330
|
});
|
|
331
331
|
}
|
|
332
|
+
function updateSkillSubCategories(config, rkeys, subCategory, options = {}) {
|
|
333
|
+
return apiWrite(config, "/api/profile/skills/subcategory", "POST", {
|
|
334
|
+
body: { rkeys, subCategory },
|
|
335
|
+
...options
|
|
336
|
+
});
|
|
337
|
+
}
|
|
332
338
|
function deleteSkill(config, rkey, options = {}) {
|
|
333
339
|
return apiWrite(config, `/api/profile/skill/${encodeURIComponent(rkey)}`, "DELETE", options);
|
|
334
340
|
}
|
|
@@ -688,6 +694,14 @@ var EntitySelectResponseSchema = zod.z.object({
|
|
|
688
694
|
kind: zod.z.string(),
|
|
689
695
|
canonicalName: zod.z.string(),
|
|
690
696
|
domain: zod.z.string().nullable(),
|
|
697
|
+
/**
|
|
698
|
+
* The entity's website, gated to sources trustworthy enough to prefill into a
|
|
699
|
+
* record the user signs. Narrower than `domain`, which is a display value and
|
|
700
|
+
* may come from a crawl. Null when the entity has no such source.
|
|
701
|
+
*/
|
|
702
|
+
website: httpUrlNullable.default(null),
|
|
703
|
+
/** Which tier `website` came from. Crawled is never an accepted source. */
|
|
704
|
+
websiteTier: zod.z.enum(["org", "curated"]).nullable().default(null),
|
|
691
705
|
entityRef: httpUrlNullable
|
|
692
706
|
});
|
|
693
707
|
var EntityImportSearchResponseSchema = zod.z.object({
|
|
@@ -1713,6 +1727,24 @@ function useUpdateSkill(ownerHandleOrDid, options) {
|
|
|
1713
1727
|
...options
|
|
1714
1728
|
});
|
|
1715
1729
|
}
|
|
1730
|
+
function useUpdateSkillSubCategories(ownerHandleOrDid, options) {
|
|
1731
|
+
const config = useSifaConfig();
|
|
1732
|
+
const queryClient = reactQuery.useQueryClient();
|
|
1733
|
+
return reactQuery.useMutation({
|
|
1734
|
+
mutationFn: ({ rkeys, subCategory }) => updateSkillSubCategories(config, rkeys, subCategory),
|
|
1735
|
+
// `...options` comes first so a caller-supplied onSuccess cannot replace the
|
|
1736
|
+
// wrapper below and silently skip profile invalidation; the wrapper calls it
|
|
1737
|
+
// instead. The older skill hooks in this file spread options last and still
|
|
1738
|
+
// carry that bug.
|
|
1739
|
+
...options,
|
|
1740
|
+
onSuccess: async (result, variables, onMutateResult, context) => {
|
|
1741
|
+
if (result.success) {
|
|
1742
|
+
await invalidateProfile3(queryClient, ownerHandleOrDid);
|
|
1743
|
+
}
|
|
1744
|
+
await options?.onSuccess?.(result, variables, onMutateResult, context);
|
|
1745
|
+
}
|
|
1746
|
+
});
|
|
1747
|
+
}
|
|
1716
1748
|
function useDeleteSkill(ownerHandleOrDid, options) {
|
|
1717
1749
|
const config = useSifaConfig();
|
|
1718
1750
|
const queryClient = reactQuery.useQueryClient();
|
|
@@ -2911,6 +2943,7 @@ exports.updateProfileOverride = updateProfileOverride;
|
|
|
2911
2943
|
exports.updateProfileSelf = updateProfileSelf;
|
|
2912
2944
|
exports.updateRecord = updateRecord;
|
|
2913
2945
|
exports.updateSkill = updateSkill;
|
|
2946
|
+
exports.updateSkillSubCategories = updateSkillSubCategories;
|
|
2914
2947
|
exports.uploadAvatar = uploadAvatar;
|
|
2915
2948
|
exports.useActivityFeed = useActivityFeed;
|
|
2916
2949
|
exports.useActivityTeaser = useActivityTeaser;
|
|
@@ -3016,6 +3049,7 @@ exports.useUpdateProfileOverride = useUpdateProfileOverride;
|
|
|
3016
3049
|
exports.useUpdateProfileSelf = useUpdateProfileSelf;
|
|
3017
3050
|
exports.useUpdateRecord = useUpdateRecord;
|
|
3018
3051
|
exports.useUpdateSkill = useUpdateSkill;
|
|
3052
|
+
exports.useUpdateSkillSubCategories = useUpdateSkillSubCategories;
|
|
3019
3053
|
exports.useUploadAvatar = useUploadAvatar;
|
|
3020
3054
|
exports.useVerifyExternalAccount = useVerifyExternalAccount;
|
|
3021
3055
|
exports.useWipePreview = useWipePreview;
|