@learncard/idx-plugin 1.0.33 → 1.0.35
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/idx-plugin.cjs.development.js +84 -14
- package/dist/idx-plugin.cjs.development.js.map +3 -3
- package/dist/idx-plugin.cjs.production.min.js +281 -281
- package/dist/idx-plugin.cjs.production.min.js.map +3 -3
- package/dist/idx-plugin.esm.js +84 -14
- package/dist/idx-plugin.esm.js.map +3 -3
- package/package.json +4 -4
package/dist/idx-plugin.esm.js
CHANGED
|
@@ -10990,18 +10990,31 @@ var ProfileValidator = mod.string().or(
|
|
|
10990
10990
|
var CredentialSubjectValidator = mod.object({ id: mod.string().optional() }).catchall(mod.any());
|
|
10991
10991
|
var CredentialStatusValidator = mod.object({ type: mod.string(), id: mod.string() }).catchall(mod.any());
|
|
10992
10992
|
var CredentialSchemaValidator = mod.object({ id: mod.string(), type: mod.string() }).catchall(mod.any());
|
|
10993
|
-
var RefreshServiceValidator = mod.object({ id: mod.string(), type: mod.string() }).catchall(mod.any());
|
|
10993
|
+
var RefreshServiceValidator = mod.object({ id: mod.string().optional(), type: mod.string() }).catchall(mod.any());
|
|
10994
|
+
var TermsOfUseValidator = mod.object({ type: mod.string(), id: mod.string().optional() }).catchall(mod.any());
|
|
10995
|
+
var VC2EvidenceValidator = mod.object({ type: mod.string().or(mod.string().array().nonempty()), id: mod.string().optional() }).catchall(mod.any());
|
|
10994
10996
|
var UnsignedVCValidator = mod.object({
|
|
10995
10997
|
"@context": ContextValidator,
|
|
10996
10998
|
id: mod.string().optional(),
|
|
10997
10999
|
type: mod.string().array().nonempty(),
|
|
10998
11000
|
issuer: ProfileValidator,
|
|
10999
|
-
issuanceDate: mod.string(),
|
|
11000
|
-
expirationDate: mod.string().optional(),
|
|
11001
11001
|
credentialSubject: CredentialSubjectValidator.or(CredentialSubjectValidator.array()),
|
|
11002
|
-
|
|
11003
|
-
credentialSchema: CredentialSchemaValidator.
|
|
11004
|
-
|
|
11002
|
+
refreshService: RefreshServiceValidator.or(RefreshServiceValidator.array()).optional(),
|
|
11003
|
+
credentialSchema: CredentialSchemaValidator.or(
|
|
11004
|
+
CredentialSchemaValidator.array()
|
|
11005
|
+
).optional(),
|
|
11006
|
+
issuanceDate: mod.string().optional(),
|
|
11007
|
+
expirationDate: mod.string().optional(),
|
|
11008
|
+
credentialStatus: CredentialStatusValidator.or(
|
|
11009
|
+
CredentialStatusValidator.array()
|
|
11010
|
+
).optional(),
|
|
11011
|
+
name: mod.string().optional(),
|
|
11012
|
+
description: mod.string().optional(),
|
|
11013
|
+
validFrom: mod.string().optional(),
|
|
11014
|
+
validUntil: mod.string().optional(),
|
|
11015
|
+
status: CredentialStatusValidator.or(CredentialStatusValidator.array()).optional(),
|
|
11016
|
+
termsOfUse: TermsOfUseValidator.or(TermsOfUseValidator.array()).optional(),
|
|
11017
|
+
evidence: VC2EvidenceValidator.or(VC2EvidenceValidator.array()).optional()
|
|
11005
11018
|
}).catchall(mod.any());
|
|
11006
11019
|
var ProofValidator = mod.object({
|
|
11007
11020
|
type: mod.string(),
|
|
@@ -11253,7 +11266,7 @@ var AchievementSubjectValidator = mod.object({
|
|
|
11253
11266
|
}).catchall(mod.any());
|
|
11254
11267
|
var EvidenceValidator = mod.object({
|
|
11255
11268
|
id: mod.string().optional(),
|
|
11256
|
-
type: mod.string().array().nonempty(),
|
|
11269
|
+
type: mod.string().or(mod.string().array().nonempty()),
|
|
11257
11270
|
narrative: mod.string().optional(),
|
|
11258
11271
|
name: mod.string().optional(),
|
|
11259
11272
|
description: mod.string().optional(),
|
|
@@ -11726,6 +11739,28 @@ var LCNNotificationValidator = mod.object({
|
|
|
11726
11739
|
data: LCNNotificationDataValidator.optional(),
|
|
11727
11740
|
sent: mod.string().datetime().optional()
|
|
11728
11741
|
});
|
|
11742
|
+
var AUTH_GRANT_AUDIENCE_DOMAIN_PREFIX = "auth-grant:";
|
|
11743
|
+
var AuthGrantValidator = mod.object({
|
|
11744
|
+
id: mod.string(),
|
|
11745
|
+
name: mod.string(),
|
|
11746
|
+
description: mod.string().optional(),
|
|
11747
|
+
challenge: mod.string().startsWith(AUTH_GRANT_AUDIENCE_DOMAIN_PREFIX).min(10, { message: "Challenge is too short" }).max(100, { message: "Challenge is too long" }),
|
|
11748
|
+
status: mod.enum(["revoked", "active"], {
|
|
11749
|
+
required_error: "Status is required",
|
|
11750
|
+
invalid_type_error: "Status must be either active or revoked"
|
|
11751
|
+
}),
|
|
11752
|
+
scope: mod.string(),
|
|
11753
|
+
createdAt: mod.string().datetime({ message: "createdAt must be a valid ISO 8601 datetime string" }),
|
|
11754
|
+
expiresAt: mod.string().datetime({ message: "expiresAt must be a valid ISO 8601 datetime string" }).nullish().optional()
|
|
11755
|
+
});
|
|
11756
|
+
var FlatAuthGrantValidator = mod.object({ id: mod.string() }).catchall(mod.any());
|
|
11757
|
+
var AuthGrantStatusValidator = mod.enum(["active", "revoked"]);
|
|
11758
|
+
var AuthGrantQueryValidator = mod.object({
|
|
11759
|
+
id: StringQuery,
|
|
11760
|
+
name: StringQuery,
|
|
11761
|
+
description: StringQuery,
|
|
11762
|
+
status: AuthGrantStatusValidator
|
|
11763
|
+
}).partial();
|
|
11729
11764
|
|
|
11730
11765
|
// ../ceramic/dist/ceramic-plugin.esm.js
|
|
11731
11766
|
var __create2 = Object.create;
|
|
@@ -66006,18 +66041,31 @@ var ProfileValidator2 = mod2.string().or(
|
|
|
66006
66041
|
var CredentialSubjectValidator2 = mod2.object({ id: mod2.string().optional() }).catchall(mod2.any());
|
|
66007
66042
|
var CredentialStatusValidator2 = mod2.object({ type: mod2.string(), id: mod2.string() }).catchall(mod2.any());
|
|
66008
66043
|
var CredentialSchemaValidator2 = mod2.object({ id: mod2.string(), type: mod2.string() }).catchall(mod2.any());
|
|
66009
|
-
var RefreshServiceValidator2 = mod2.object({ id: mod2.string(), type: mod2.string() }).catchall(mod2.any());
|
|
66044
|
+
var RefreshServiceValidator2 = mod2.object({ id: mod2.string().optional(), type: mod2.string() }).catchall(mod2.any());
|
|
66045
|
+
var TermsOfUseValidator2 = mod2.object({ type: mod2.string(), id: mod2.string().optional() }).catchall(mod2.any());
|
|
66046
|
+
var VC2EvidenceValidator2 = mod2.object({ type: mod2.string().or(mod2.string().array().nonempty()), id: mod2.string().optional() }).catchall(mod2.any());
|
|
66010
66047
|
var UnsignedVCValidator2 = mod2.object({
|
|
66011
66048
|
"@context": ContextValidator2,
|
|
66012
66049
|
id: mod2.string().optional(),
|
|
66013
66050
|
type: mod2.string().array().nonempty(),
|
|
66014
66051
|
issuer: ProfileValidator2,
|
|
66015
|
-
issuanceDate: mod2.string(),
|
|
66016
|
-
expirationDate: mod2.string().optional(),
|
|
66017
66052
|
credentialSubject: CredentialSubjectValidator2.or(CredentialSubjectValidator2.array()),
|
|
66018
|
-
|
|
66019
|
-
credentialSchema: CredentialSchemaValidator2.
|
|
66020
|
-
|
|
66053
|
+
refreshService: RefreshServiceValidator2.or(RefreshServiceValidator2.array()).optional(),
|
|
66054
|
+
credentialSchema: CredentialSchemaValidator2.or(
|
|
66055
|
+
CredentialSchemaValidator2.array()
|
|
66056
|
+
).optional(),
|
|
66057
|
+
issuanceDate: mod2.string().optional(),
|
|
66058
|
+
expirationDate: mod2.string().optional(),
|
|
66059
|
+
credentialStatus: CredentialStatusValidator2.or(
|
|
66060
|
+
CredentialStatusValidator2.array()
|
|
66061
|
+
).optional(),
|
|
66062
|
+
name: mod2.string().optional(),
|
|
66063
|
+
description: mod2.string().optional(),
|
|
66064
|
+
validFrom: mod2.string().optional(),
|
|
66065
|
+
validUntil: mod2.string().optional(),
|
|
66066
|
+
status: CredentialStatusValidator2.or(CredentialStatusValidator2.array()).optional(),
|
|
66067
|
+
termsOfUse: TermsOfUseValidator2.or(TermsOfUseValidator2.array()).optional(),
|
|
66068
|
+
evidence: VC2EvidenceValidator2.or(VC2EvidenceValidator2.array()).optional()
|
|
66021
66069
|
}).catchall(mod2.any());
|
|
66022
66070
|
var ProofValidator2 = mod2.object({
|
|
66023
66071
|
type: mod2.string(),
|
|
@@ -66269,7 +66317,7 @@ var AchievementSubjectValidator2 = mod2.object({
|
|
|
66269
66317
|
}).catchall(mod2.any());
|
|
66270
66318
|
var EvidenceValidator2 = mod2.object({
|
|
66271
66319
|
id: mod2.string().optional(),
|
|
66272
|
-
type: mod2.string().array().nonempty(),
|
|
66320
|
+
type: mod2.string().or(mod2.string().array().nonempty()),
|
|
66273
66321
|
narrative: mod2.string().optional(),
|
|
66274
66322
|
name: mod2.string().optional(),
|
|
66275
66323
|
description: mod2.string().optional(),
|
|
@@ -66742,6 +66790,28 @@ var LCNNotificationValidator2 = mod2.object({
|
|
|
66742
66790
|
data: LCNNotificationDataValidator2.optional(),
|
|
66743
66791
|
sent: mod2.string().datetime().optional()
|
|
66744
66792
|
});
|
|
66793
|
+
var AUTH_GRANT_AUDIENCE_DOMAIN_PREFIX2 = "auth-grant:";
|
|
66794
|
+
var AuthGrantValidator2 = mod2.object({
|
|
66795
|
+
id: mod2.string(),
|
|
66796
|
+
name: mod2.string(),
|
|
66797
|
+
description: mod2.string().optional(),
|
|
66798
|
+
challenge: mod2.string().startsWith(AUTH_GRANT_AUDIENCE_DOMAIN_PREFIX2).min(10, { message: "Challenge is too short" }).max(100, { message: "Challenge is too long" }),
|
|
66799
|
+
status: mod2.enum(["revoked", "active"], {
|
|
66800
|
+
required_error: "Status is required",
|
|
66801
|
+
invalid_type_error: "Status must be either active or revoked"
|
|
66802
|
+
}),
|
|
66803
|
+
scope: mod2.string(),
|
|
66804
|
+
createdAt: mod2.string().datetime({ message: "createdAt must be a valid ISO 8601 datetime string" }),
|
|
66805
|
+
expiresAt: mod2.string().datetime({ message: "expiresAt must be a valid ISO 8601 datetime string" }).nullish().optional()
|
|
66806
|
+
});
|
|
66807
|
+
var FlatAuthGrantValidator2 = mod2.object({ id: mod2.string() }).catchall(mod2.any());
|
|
66808
|
+
var AuthGrantStatusValidator2 = mod2.enum(["active", "revoked"]);
|
|
66809
|
+
var AuthGrantQueryValidator2 = mod2.object({
|
|
66810
|
+
id: StringQuery2,
|
|
66811
|
+
name: StringQuery2,
|
|
66812
|
+
description: StringQuery2,
|
|
66813
|
+
status: AuthGrantStatusValidator2
|
|
66814
|
+
}).partial();
|
|
66745
66815
|
var streamIdToCeramicURI = /* @__PURE__ */ __name3((id) => `lc:ceramic:${id}`, "streamIdToCeramicURI");
|
|
66746
66816
|
var CeramicURIValidator = mod2.string().refine(
|
|
66747
66817
|
(string22) => string22.split(":").length === 3 && string22.split(":")[0] === "lc",
|