From 0edcd84f7e6d550e57d8185c39b0ae0a708e925f Mon Sep 17 00:00:00 2001 From: Amadeo Pellicce Date: Wed, 2 Nov 2022 15:48:40 +0100 Subject: [PATCH 1/2] adding config to Chain Objects --- .gitignore | 1 + src/model/ChainObject.ts | 3 ++- src/model/types.ts | 5 +++++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index aff0018..21e5d7f 100644 --- a/.gitignore +++ b/.gitignore @@ -4,6 +4,7 @@ exec/ /tmp/**/ tmp.csv tmp +.yarn/install-state.gz # Logs logs diff --git a/src/model/ChainObject.ts b/src/model/ChainObject.ts index 5f705b6..cb50042 100644 --- a/src/model/ChainObject.ts +++ b/src/model/ChainObject.ts @@ -2,7 +2,7 @@ import { sortObjectKeys } from "../utils"; import { Logos } from "./Logos"; import { RepoObject } from "./RepoObject"; import { TagName } from "./Tag"; -import { Description, Links } from "./types"; +import { Config, Description, Links } from "./types"; import { getUUID } from "./UUID"; export type ObjectType = 'network' | 'asset'; @@ -12,6 +12,7 @@ export abstract class ChainObject extends RepoObject { networkCode: string; active: boolean; color: string | null; + config: Config | null; decimals: number; description: Description | null;// foreign keys links: Links | null; // foreign keys diff --git a/src/model/types.ts b/src/model/types.ts index 315537b..cb65508 100644 --- a/src/model/types.ts +++ b/src/model/types.ts @@ -15,3 +15,8 @@ export interface Links { whitepaper?: string; } + +type ConfigValue = string | number | boolean; +export interface Config { + [key: string]: ConfigValue; +} \ No newline at end of file From cac54ce18149f78791c664a55743cd2ef7c8bdde Mon Sep 17 00:00:00 2001 From: Amadeo Pellicce Date: Wed, 2 Nov 2022 15:49:00 +0100 Subject: [PATCH 2/2] 1.0.160 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 73363fc..a597198 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@map3xyz/assets-helper", - "version": "1.0.159", + "version": "1.0.160", "description": "A library for maintaining the assets repo.", "author": "pellicceama", "keywords": [