@dashevo/dpns-contract 0.24.0-dev.3 → 0.24.0-dev.30

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/Cargo.toml ADDED
@@ -0,0 +1,9 @@
1
+ [package]
2
+ name = "dpns-contract"
3
+ description = "DPNS data contract schema and tools"
4
+ version = "0.24.0-dev.1"
5
+ edition = "2021"
6
+ license = "MIT"
7
+
8
+ [dependencies]
9
+ serde_json = { version = "1.0" }
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # DPNS Contract
2
2
 
3
- [![Build Status](https://github.com/dashevo/platform/actions/workflows/release.yml/badge.svg)](https://github.com/dashevo/platform/actions/workflows/release.yml)
3
+ [![Build Status](https://github.com/dashpay/platform/actions/workflows/release.yml/badge.svg)](https://github.com/dashpay/platform/actions/workflows/release.yml)
4
4
  [![NPM version](https://img.shields.io/npm/v/@dashevo/dpns-contract.svg?style=flat-square)](https://npmjs.org/package/@dashevo/dpns-contract)
5
5
 
6
6
  JSON Contracts for Dash Platform Name Service
@@ -26,7 +26,7 @@ npm install @dashevo/dpns-contract
26
26
 
27
27
  ## Contributing
28
28
 
29
- Feel free to dive in! [Open an issue](https://github.com/dashevo/platform/issues/new/choose) or submit PRs.
29
+ Feel free to dive in! [Open an issue](https://github.com/dashpay/platform/issues/new/choose) or submit PRs.
30
30
 
31
31
  ## License
32
32
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dashevo/dpns-contract",
3
- "version": "0.24.0-dev.3",
3
+ "version": "0.24.0-dev.30",
4
4
  "description": "A contract and helper scripts for DPNS DApp",
5
5
  "scripts": {
6
6
  "lint": "eslint .",
@@ -31,7 +31,7 @@
31
31
  ],
32
32
  "license": "MIT",
33
33
  "devDependencies": {
34
- "@dashevo/dpp": "0.24.0-dev.3",
34
+ "@dashevo/dpp": "0.24.0-dev.30",
35
35
  "chai": "^4.3.4",
36
36
  "dirty-chai": "^2.0.1",
37
37
  "eslint": "^7.32.0",
@@ -49,7 +49,7 @@
49
49
  },
50
50
  "normalizedParentDomainName": {
51
51
  "type": "string",
52
- "pattern": "^$|^[[a-z0-9][a-z0-9-\\.]{0,61}[a-z0-9]$",
52
+ "pattern": "^$|^[a-z0-9][a-z0-9-\\.]{0,61}[a-z0-9]$",
53
53
  "minLength": 0,
54
54
  "maxLength": 63,
55
55
  "description": "A full parent domain name in lowercase for case-insensitive uniqueness validation. e.g. 'dash'",
package/src/lib.rs ADDED
@@ -0,0 +1,15 @@
1
+ use serde_json::{Error, Value};
2
+
3
+ pub const ID_BYTES: [u8; 32] = [
4
+ 230, 104, 198, 89, 175, 102, 174, 225, 231, 44, 24, 109, 222, 123, 91, 126, 10, 29, 113, 42, 9,
5
+ 196, 13, 87, 33, 246, 34, 191, 83, 197, 49, 85,
6
+ ];
7
+
8
+ pub const OWNER_ID_BYTES: [u8; 32] = [
9
+ 48, 18, 193, 155, 152, 236, 0, 51, 173, 219, 54, 205, 100, 183, 245, 16, 103, 15, 42, 53, 26,
10
+ 67, 4, 181, 246, 153, 65, 68, 40, 110, 253, 172,
11
+ ];
12
+
13
+ pub fn load_documents_schemas() -> Result<Value, Error> {
14
+ serde_json::from_str(include_str!("../schema/dpns-contract-documents.json"))
15
+ }