@snapshot-labs/snapshot.js 0.12.15 → 0.12.17
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/snapshot.cjs.js +55 -0
- package/dist/snapshot.esm.js +55 -0
- package/dist/snapshot.min.js +2 -2
- package/dist/src/index.d.ts +43 -0
- package/dist/src/schemas/index.d.ts +43 -0
- package/package.json +1 -1
- package/src/schemas/space.json +43 -0
- package/src/utils.ts +7 -0
package/dist/snapshot.cjs.js
CHANGED
|
@@ -727,6 +727,14 @@ var definitions = {
|
|
|
727
727
|
"0x3901D0fDe202aF1427216b79f5243f8A022d68cf"
|
|
728
728
|
]
|
|
729
729
|
},
|
|
730
|
+
delegationNetwork: {
|
|
731
|
+
type: "string",
|
|
732
|
+
snapshotNetwork: true,
|
|
733
|
+
title: "Delegation network",
|
|
734
|
+
minLength: 1,
|
|
735
|
+
maxLength: 32,
|
|
736
|
+
description: "The network of your delegation contract"
|
|
737
|
+
},
|
|
730
738
|
delegationApi: {
|
|
731
739
|
type: "string",
|
|
732
740
|
format: "uri",
|
|
@@ -860,6 +868,46 @@ var definitions = {
|
|
|
860
868
|
additionalProperties: false
|
|
861
869
|
}
|
|
862
870
|
},
|
|
871
|
+
labels: {
|
|
872
|
+
type: "array",
|
|
873
|
+
maxItems: 100,
|
|
874
|
+
uniqueItems: true,
|
|
875
|
+
items: {
|
|
876
|
+
type: "object",
|
|
877
|
+
properties: {
|
|
878
|
+
id: {
|
|
879
|
+
type: "string",
|
|
880
|
+
title: "Id",
|
|
881
|
+
minLength: 1,
|
|
882
|
+
maxLength: 8
|
|
883
|
+
},
|
|
884
|
+
name: {
|
|
885
|
+
type: "string",
|
|
886
|
+
title: "Name",
|
|
887
|
+
minLength: 1,
|
|
888
|
+
maxLength: 32
|
|
889
|
+
},
|
|
890
|
+
description: {
|
|
891
|
+
type: "string",
|
|
892
|
+
title: "Description",
|
|
893
|
+
minLength: 1,
|
|
894
|
+
maxLength: 100
|
|
895
|
+
},
|
|
896
|
+
color: {
|
|
897
|
+
type: "string",
|
|
898
|
+
title: "Color",
|
|
899
|
+
format: "color"
|
|
900
|
+
}
|
|
901
|
+
},
|
|
902
|
+
required: [
|
|
903
|
+
"id",
|
|
904
|
+
"name",
|
|
905
|
+
"description",
|
|
906
|
+
"color"
|
|
907
|
+
],
|
|
908
|
+
additionalProperties: false
|
|
909
|
+
}
|
|
910
|
+
},
|
|
863
911
|
parent: {
|
|
864
912
|
type: "string",
|
|
865
913
|
title: "parent"
|
|
@@ -3860,6 +3908,13 @@ ajv.addFormat('long', {
|
|
|
3860
3908
|
ajv.addFormat('lowercase', {
|
|
3861
3909
|
validate: (value) => value === value.toLowerCase()
|
|
3862
3910
|
});
|
|
3911
|
+
ajv.addFormat('color', {
|
|
3912
|
+
validate: (value) => {
|
|
3913
|
+
if (!value)
|
|
3914
|
+
return false;
|
|
3915
|
+
return !!value.match(/^#[0-9A-F]{6}$/);
|
|
3916
|
+
}
|
|
3917
|
+
});
|
|
3863
3918
|
ajv.addFormat('ethValue', {
|
|
3864
3919
|
validate: (value) => {
|
|
3865
3920
|
if (!value.match(/^([0-9]|[1-9][0-9]+)(\.[0-9]+)?$/))
|
package/dist/snapshot.esm.js
CHANGED
|
@@ -717,6 +717,14 @@ var definitions = {
|
|
|
717
717
|
"0x3901D0fDe202aF1427216b79f5243f8A022d68cf"
|
|
718
718
|
]
|
|
719
719
|
},
|
|
720
|
+
delegationNetwork: {
|
|
721
|
+
type: "string",
|
|
722
|
+
snapshotNetwork: true,
|
|
723
|
+
title: "Delegation network",
|
|
724
|
+
minLength: 1,
|
|
725
|
+
maxLength: 32,
|
|
726
|
+
description: "The network of your delegation contract"
|
|
727
|
+
},
|
|
720
728
|
delegationApi: {
|
|
721
729
|
type: "string",
|
|
722
730
|
format: "uri",
|
|
@@ -850,6 +858,46 @@ var definitions = {
|
|
|
850
858
|
additionalProperties: false
|
|
851
859
|
}
|
|
852
860
|
},
|
|
861
|
+
labels: {
|
|
862
|
+
type: "array",
|
|
863
|
+
maxItems: 100,
|
|
864
|
+
uniqueItems: true,
|
|
865
|
+
items: {
|
|
866
|
+
type: "object",
|
|
867
|
+
properties: {
|
|
868
|
+
id: {
|
|
869
|
+
type: "string",
|
|
870
|
+
title: "Id",
|
|
871
|
+
minLength: 1,
|
|
872
|
+
maxLength: 8
|
|
873
|
+
},
|
|
874
|
+
name: {
|
|
875
|
+
type: "string",
|
|
876
|
+
title: "Name",
|
|
877
|
+
minLength: 1,
|
|
878
|
+
maxLength: 32
|
|
879
|
+
},
|
|
880
|
+
description: {
|
|
881
|
+
type: "string",
|
|
882
|
+
title: "Description",
|
|
883
|
+
minLength: 1,
|
|
884
|
+
maxLength: 100
|
|
885
|
+
},
|
|
886
|
+
color: {
|
|
887
|
+
type: "string",
|
|
888
|
+
title: "Color",
|
|
889
|
+
format: "color"
|
|
890
|
+
}
|
|
891
|
+
},
|
|
892
|
+
required: [
|
|
893
|
+
"id",
|
|
894
|
+
"name",
|
|
895
|
+
"description",
|
|
896
|
+
"color"
|
|
897
|
+
],
|
|
898
|
+
additionalProperties: false
|
|
899
|
+
}
|
|
900
|
+
},
|
|
853
901
|
parent: {
|
|
854
902
|
type: "string",
|
|
855
903
|
title: "parent"
|
|
@@ -3850,6 +3898,13 @@ ajv.addFormat('long', {
|
|
|
3850
3898
|
ajv.addFormat('lowercase', {
|
|
3851
3899
|
validate: (value) => value === value.toLowerCase()
|
|
3852
3900
|
});
|
|
3901
|
+
ajv.addFormat('color', {
|
|
3902
|
+
validate: (value) => {
|
|
3903
|
+
if (!value)
|
|
3904
|
+
return false;
|
|
3905
|
+
return !!value.match(/^#[0-9A-F]{6}$/);
|
|
3906
|
+
}
|
|
3907
|
+
});
|
|
3853
3908
|
ajv.addFormat('ethValue', {
|
|
3854
3909
|
validate: (value) => {
|
|
3855
3910
|
if (!value.match(/^([0-9]|[1-9][0-9]+)(\.[0-9]+)?$/))
|