Skip to content

Commit 4ac408d

Browse files
committed
up
Signed-off-by: mihaisc <[email protected]>
1 parent d8c0d1c commit 4ac408d

11 files changed

+25
-877
lines changed

.eslintrc

+10-23
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,14 @@
11
{
22
"parser": "@typescript-eslint/parser",
3-
"root": true,
4-
"extends": [
5-
"eslint:recommended",
6-
"plugin:@typescript-eslint/recommended"
7-
],
8-
"plugins": [
9-
"@typescript-eslint"
10-
],
3+
"parserOptions": {
4+
"project": ["./tsconfig.json"]
5+
},
6+
"extends": ["oceanprotocol", "plugin:prettier/recommended"],
7+
"plugins": ["@typescript-eslint"],
118
"rules": {
12-
"comma-spacing": [
13-
"error",
14-
{
15-
"before": false,
16-
"after": true
17-
}
18-
],
19-
"prefer-const": [
20-
"off"
21-
],
22-
"prettier/prettier": "error",
23-
"mocha-no-only/mocha-no-only": [
24-
"error"
25-
],
9+
"no-use-before-define": "off",
10+
"eqeqeq": "off",
11+
"@typescript-eslint/no-use-before-define": "error",
12+
"no-undef": ["warn"]
2613
}
27-
}
14+
}

.prettierrc

+5-30
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,6 @@
11
{
2-
"overrides": [
3-
{
4-
"files": "*.sol",
5-
"options": {
6-
"bracketSpacing": true,
7-
"explicitTypes": "always",
8-
"printWidth": 120,
9-
"singleQuote": false,
10-
"tabWidth": 4,
11-
"useTabs": false
12-
}
13-
},
14-
{
15-
"files": "*.ts",
16-
"options": {
17-
"bracketSpacing": true,
18-
"explicitTypes": "always",
19-
"newline-before-return": true,
20-
"no-duplicate-variable": [true, "check-parameters"],
21-
"no-var-keyword": true,
22-
"printWidth": 120,
23-
"semi": true,
24-
"singleQuote": true,
25-
"tabWidth": 2,
26-
"trailingComma": "es5",
27-
"useTabs": false
28-
}
29-
}
30-
]
31-
}
2+
"semi": false,
3+
"singleQuote": true,
4+
"trailingComma": "none",
5+
"tabWidth": 2
6+
}

schema.graphql

+10-26
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ type Dispenser @entity {
235235
type DispenserTransaction @entity {
236236
id: ID!
237237
dispenserId: Dispenser!
238-
datatoken: Datatoken!
238+
datatoken: Token!
239239
user: User!
240240
amount: BigDecimal!
241241
block: Int!
@@ -246,11 +246,11 @@ type DispenserTransaction @entity {
246246

247247

248248
type PoolSnapshotTokenValue @entity {
249-
id: ID! # pool tx + tokenAddress
250-
tokenAddress: String!
251-
value: BigDecimal!
249+
id: ID! # pool tx + tokenAddress
250+
token: Token!
251+
value: BigDecimal!
252252
tokenReserve: BigDecimal!
253-
feeValue: BigDecimal! # Swap fee value in OCEAN
253+
feeValue: BigDecimal! # Swap fee value in OCEAN
254254
type: String!
255255
poolSnapshot: PoolSnapshot!
256256
}
@@ -260,41 +260,25 @@ type PoolSnapshot @entity {
260260
id: ID!
261261
pool: Pool!
262262
totalShares: BigDecimal!
263-
swapVolume: BigDecimal!
264-
swapFees: BigDecimal!
265-
timestamp: Int!
263+
swapVolume: BigDecimal! # swap value 24h
264+
swapFees: BigDecimal! # swap fee value 24h
265+
timestamp: Int! # date without time
266+
spotPrice: BigDecimal! # TODO: last spot price or first one?
266267
tokens: [PoolSnapshotTokenValue!] @derivedFrom(field: "poolSnapshot")
267268
}
268269

269270

271+
// shouldn't we move this to aquarius?
270272
type MetadataUpdate @entity {
271273
id: ID! # update tx + datatokenAddress
272274
datatokenId: Datatoken!
273275

274276
datatokenAddress: String!
275277
userAddress: String!
276278

277-
//all fields from the market edit
278-
name
279-
description
280-
author
281-
links
282-
timeout
283279

284280

285281
block: Int!
286282
timestamp: Int!
287283
tx: Bytes!
288284
}
289-
290-
type Asset {
291-
292-
did
293-
name
294-
description
295-
author
296-
services ? [ access, compute ] ?
297-
298-
datatoken : Datatoken
299-
}
300-

src/lzma/bit-tree-decoder.ts

-42
This file was deleted.

src/lzma/len-decoder.ts

-42
This file was deleted.

0 commit comments

Comments
 (0)