1
0
mirror of https://github.com/oceanprotocol/market.git synced 2024-06-23 01:36:47 +02:00
Commit Graph

55 Commits

Author SHA1 Message Date
Norbi
1f332c4148
Web3Feedback UI messages fix (#812)
* show isBalanceSufficient warning only on Use tab

* show warning icon when both isAssetNetwork and isGraphSynced are false

* refactor display messages code fix order and icon issues

* moved isBalanceSufficient message handle from Web3Feedback to ButtonBuy

* more refactoring, improve feedback message change

* fix isBalanceSufficient for buying a compute job

* fix lint error
2021-08-31 09:47:55 +02:00
a82ad003e2
fix fileinfo fetching without wallet connected (#803) 2021-08-23 12:15:13 +02:00
fd06afc9f8
fix checkIsConsumable dependencies (#788) 2021-08-16 13:02:01 +03:00
mihaisc
22da62b231
Check graph sync status (#745)
* fix balance check after network switch

* error location

* remove console

* fix messages

* fixed sync status

* remove comment
2021-07-22 02:40:44 -07:00
Norbi
565c0324f9
Create wallet network switcher (#676)
* created component for wallet network switching

* component styling

* display network names

* created networks config

* fix get network config function

* wip

* moved switcher component inside consume

* use isAssetNetwork to show Switcher component, added to publish

* get network properties using networkList and oceanConfig

* error fix

* hide wallet network switcher if no provider

* use chainId from useAsset ddo

* added switcher component to Compute

* added component to edit metadata and compute settings

* added component to advance settings form

* fixed lint errors

* included component inside Web3Feedback

* updated text and icon design

* button design update, and Web3Feedback position on edit asset

* fixed lint error

* message update

* tag error fixes

* disabled pool and trade buttons if not asset network

* mainnet aquarius fallback url

* filename typo fix

* replace NetworkName component with getNetworkDisplayName function

* added method to switch to EthereumChain networks, removed logs

* fixed lint error

* style tweaks

* markup and styles simplification

* restrict add datatoken

Co-authored-by: Norbi <katunanorbert@gmai.com>
Co-authored-by: Matthias Kretschmann <m@kretschmann.io>
2021-07-15 17:03:03 +02:00
08ee32f105
Merge branch 'main' into feature/multinetwork 2021-07-14 11:28:50 +02:00
mihaisc
b9bd6a3a25
add fileinfo fetching (#697)
Signed-off-by: mihaisc <mihai@work.localdomain>

Co-authored-by: mihaisc <mihai@work.localdomain>
2021-07-12 15:56:23 +02:00
Norbert
fa4c3a10ee Merge branch 'main' into feature/multinetwork 2021-07-07 10:09:28 +03:00
Kris Liew
675da0836f
bump ocean.js v0.16.2, ocean.assets.isConsumable implementation to disable buy button and display relevant message (#463)
* Implement ocean.assets.isConsumable

* Fix accountId from useWeb3() returning lower case on switching metamask account (allow/deny list)

* Update Ocean.js version v0.16.2 and package-lock.json

* Fix datePublished error on validate-remote

Co-authored-by: KIANLAU <kian_yee.lau@daimler.com>
Co-authored-by: Kris (SJ) <39853992+soonjing@users.noreply.github.com>
2021-07-06 14:51:37 +08:00
Norbi
14f2f2a747 Merge branch 'main' into feature/multinetwork 2021-07-01 14:44:21 +03:00
mihaisc
04d505da42
remove fileInfo check, cleanup (#689)
Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>
2021-06-16 18:49:40 +02:00
Kris Liew
e02babf2c2
[EPIC] Free Pricing (#681)
* Free Pricing Option at create Pricing (#621)

* Free Pricing Option + env var toggle

* Create Pricing step msg

* Default 'allowFreePricing' to true temp for review

* Fix price 0 on free tab

* Attempt fix useSiteMetadata

* Fix linting

* Feature/free price support consume compute (#654)

* Update fetch free price

* Feedback change UI remove 0's

* update button msg && fix

* compute algorithm list show 'Free' instead of '0'

* updateMetadata() v3 workaround solution for free pricing (#677)

* compute algorithm list show 'Free' instead of '0'

* workaround editMetaData free price

* utils function for compute & download

* `allowFreePricing` default to false
2021-06-16 09:32:11 +08:00
f9f3768f5f
fix most remaining typing errors 2021-06-11 11:23:24 +02:00
b8930cc738
Merge branch 'main' into feature/multinetwork 2021-06-11 11:14:43 +02:00
Jamie Hewitt
e26ed0e81a
Issue 582 market rbac integration (#597)
* adding env for RBAC server url to app.config.js

* creating util function for requesting auth from the rbac server

* fixing typing error

* testing rbac request on homepage

* removing console logs

* importing RBAC url from config file

* creating develpment .env file

* return true if no rbac url env is set

* creating permissions parent component

* wrapping homepage content in permission element

* wrapping publish in permissions wrapper

* wrapping search results in permissions wrapper

* wrapping asset actions in permissions element

* creating an error alert for permission denied

* updating react hook dependency

* passing address to rbac component

* sedning address to RBAC server

* wrapping asset in permission component

* removing unused import of Permission component

* sending request based on address

* chaning default permission case to restrict access

* updating eventType as consume

* Adding loader icon while waiting form permission response

* only sending request to RBAC if address is defined

* adding wallet connection info message

* changing the env name and checking for undefined

* updating .env.development

* Check for undefined RBAC_URL in permissions component

* removing .env.development and updating .env.example

* updating .env.example comment

* switching alert messages and reducing return statements

* removing console.log message

* fixing linting issue

* Revert "fixing linting issue"

This reverts commit 8bcb80be3d.

* Fixing linting errors

* pull from origin main

* Revert "pull from origin main"

This reverts commit 9535e41a5f.
2021-06-10 12:06:26 +03:00
claudiaHash
b1d8a77895
Update file metadata from provider (#631)
* get file metadata from provider

* get file metadata without a wallet connected

* unused import deleted

* get file metadata from provider


get file metadata without a wallet connected


unused import deleted

* loader added

* lint fix

* loaded added on file icon

* fileMetadata empty object init

* lint error fixed, deleted unused imports

Co-authored-by: claudia.holhos <claudia.holhos@hpm.ro>
2021-06-10 11:39:24 +03:00
9d7486d626
prototype network feedback based on asset network checks 2021-06-04 15:01:22 +02:00
Norbi
574e4a02f1
used price from useAsset instead of ddo (#590)
Co-authored-by: Norbi <katunanorbert@gmai.com>
2021-05-11 11:33:05 +03:00
Bogdan Fazakas
1d13000772
Help messages & price display for starting compute job (#478)
* add dataset, algo and total price to form footer

* styled price component on start compute

* fix lint issues

* added help messages for compute jobs in BuyButton

* consume button text alignment fix

* help text copy changes

* styles cleanup

* use graph price on dataset display, remove buy compute timeout text

* minimal total price output

* spacing, copy

* more spacing & copy

* calculation output, timeout output

* price output refactor

Co-authored-by: Matthias Kretschmann <m@kretschmann.io>
2021-04-08 17:10:51 +02:00
Bogdan Fazakas
18f2c99e78
Start compute job (#439)
* Wip start compute job

* Wip select algorithm design

* Asset selection form component, for start compute job (#442)

* prototype AssetSelection

* assetselection styling

* typing "fix"

* put back file info icon

* AssetSelection styling in context

* update start job method, fixed algo select, and fixed option typing

* compute logic update

* add has previous orders for algo asset

* fixed search algorithm assets in start compute form

* fixed lint errors

* updated previous order for algo logic and compute flow

* update use price hook and added buy DT for algo

* display only alg of type exchange and sort by value

* display only trusted algo for asset if field is set

* added logic for allow all published algorithms or no algorithms allowed

* asset selection style & spacing tweaks

* refactor get algorithms for compute and edit compute

* fixed form options and more refactoring

* new ButtonBuy component

* shared component between consume/compute
* dealing with various states: loading, previous orders, help text output

* effect dependencies

* move error output into toast

* formik data flow refactor

* ditch custom field change handler
* fix initialValues
* typed form data & validation
* fixes multiple form validation issues along the way

* isInitialValid → validateOnMount

* metadata display tweaks

* error feedback tweaks

* oler assets checks, confeti on succes job, market fee on order, removed algo compute logic

* more startJob logging

* feedback & messaging changes

* metadata display

* return all algos, fixed & dynamic priced ones

* fix DOM nesting

* messaging updates

* copy tweaks

* check algorithm previous history for both acces and compute sercive types

* handle start compute error

* extra checks on start compute response

* styling tweaks, fix toast UI errors

* AssetSelection: empty screen, tweak min/max height

* fix FRE issues on start compute

* check is ordarable before start compute job

* logging tweaks

* disable eslint no-unused-vars rule for some Apollo code blocks

* fix metadata editing for compute assets

* consider dataset timeout for compute too

Co-authored-by: Matthias Kretschmann <m@kretschmann.io>
2021-04-01 17:21:08 +02:00
bdccb0966f
Web3/Ocean splitup + full Polygon/Matic support (#433) 2021-03-17 11:44:26 +01:00
mihaisc
273769388c
Pool statistics from the graph (#288)
* graphql

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* ignore generated

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* delete generated

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix travis

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix travis

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix fetch

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix travis

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix fetch

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* update readme

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* pool creator liquidit& statistics

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* graph with the graph

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* cleanup

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix query

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* update poll interval

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* update graph url

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* ocean bump

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* run apollo codegen before starting gatsby

* put back graph loading state

* typing fix

* graph tweak, add error state

* readme update

* remove unused functions, move graph provider

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix package-lock

* fix graph when switching tabs

* generate apollo files into one folder

* fix loading

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix codegen camelcase

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* bump apollo packages

* document subgraph usage, add example

* rewrite into Data Sources, add quick examples

* more data sources docs

* docs updates, typos

Co-authored-by: Matthias Kretschmann <m@kretschmann.io>
2021-01-21 16:02:48 +01:00
960c5b3234
Update metadata, the proper way (#292)
* prototype view switching

* refactor, more UI

* formik form setup & data flow

* debug output, fixes, refactor

* description preview refactor

* publish/update date changes

* output created & updated date at top of asset
* use ddo.created & ddo.updated everywhere
* stop pushing metadata.main.datePublished

* owner check for edit link

* all the feedback states and switching between them: loading, error, success

* refactor feedback, one component for publish & edit

* action & date output fixes

* move all content, iterate form fields from it

* UI updates

* styling tweaks

* ddo dataflow refactor, more useAsset usage

* more useAsset usage

* form actions styling

* prepare edit history component

* metadata output tweaks

* copy

* safeguard against profile urls without protocol defined

* refetch ddo after edit

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* switch author for dataTokenOptions in metadata preview

* refactor

* copy

* showPricing fix

* validation: minimum characters for title & description

* disable submit button when validation fails

* form validation fixes

* manually trigger onChange validation in publish & edit forms

Co-authored-by: mihaisc <mihai.scarlat@smartcontrol.ro>
2020-12-10 14:30:40 +01:00
mihaisc
b5a11d6d0f
Handle price fetching better (#265)
* fix price refresh, add AssetProvider

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* price comment

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix trade

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix trade

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix pool liquidity

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix AssetProvider

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix import

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* remove console.log

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* pool refresh fix

* simplify, logging

* handle errors

* cleanup

Co-authored-by: Matthias Kretschmann <m@kretschmann.io>
2020-11-20 14:31:28 +01:00
mihaisc
bb80c4df78
Swap tokens (#204)
* swap

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* validation and calculation

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* refactor

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* remove unused effect

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* fix interval

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* increase refresh timer, remove optional params

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* make inputs show up without wallet

* style fixes

* restyling

* styling

* more styling

* fix refresh price

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* remove test effect

* fixes, get data as early as possible from DDO and initial state

* refactor

* refactor

* refactor

* label tweaks

* copy

* typo

* prototype output

* remove price header

* ouput swap fee

* fix

* spacing

* copy

* refactor pool transaction titles

* copy

* update math

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* use messaging tweaks

* tab tweaks, output refactor

* fix dark mode selection style

* prototype output

* method tweaks

* slippage to 1%, added warnig banner

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* form tweaks

* error fix

* empty inputs by default

* longer intervals

* maxOcean validation fix

* slippage tolerance UI

* modified slippage UI

* refactor, refresh ocean user balance

* move typings/models around

* typing fix

* fixed output values

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* bump oceanlib

Signed-off-by: mihaisc <mihai.scarlat@smartcontrol.ro>

* remove console.log

* remove placeholder

* tweak

* non-web3 browser tweak

Co-authored-by: Matthias Kretschmann <m@kretschmann.io>
2020-11-16 16:21:15 +01:00
a5b7c66331
re-fetch pool numbers every 10 sec. (#191)
* re-fetch pool numbers every 10 sec.

* visual indicator

* refresh values on remove screen

* show indicator only when ocean connected

* put back await
2020-11-02 11:58:05 +01:00
551f4ab7ee
add back balance check for all use actions (#166) 2020-10-29 21:34:53 +01:00
a81d7b9d8b
disable whole effect 2020-10-27 17:34:22 +01:00
960d20d1ea
disable user balance check for buy
* quick hack for #145
2020-10-27 17:30:40 +01:00
8454bf9cc7
remove priceType from metadata, new hasPool check 2020-10-20 18:23:08 +02:00
a5815669c7
refactor consume 2020-10-19 12:14:57 +02:00
be9fde8827
get datatoken balance for use in consume/compute 2020-10-19 11:33:06 +02:00
4b0f7c0042
typing fixes 2020-10-08 14:45:55 +02:00
d7ff2694f7
consume fixes, tab fixes 2020-09-23 13:55:53 +02:00
a4510459f1
updates for new @oceanprotocol/react price model 2020-09-10 20:32:30 +02:00
cda52aef1c
safeguard against assets without attributes.additionalInformation 2020-09-10 19:54:32 +02:00
6c47b8e44e
fix publishing 2020-09-09 14:58:57 +02:00
63fe171dd7
hide pool for simple pricing 2020-08-26 08:50:09 +02:00
9e37127360
useMetadata fixes 2020-08-20 16:59:17 +02:00
e114c3f650
refactor for new useMetadata 2020-08-20 14:22:32 +02:00
297c6a1ab1
Trade → Pool 2020-08-18 17:14:54 +02:00
812322181f
start interacting with balancer 2020-08-18 12:56:37 +02:00
e3892143c5
more feedback fixes 2020-08-11 09:41:23 +02:00
5ce00c9ddc
use decimal.js for price comparison 2020-08-11 09:30:17 +02:00
e7b17a9d65
consolidate balance check 2020-08-11 08:20:40 +02:00
76e14be730
refactor price component 2020-08-07 18:12:39 +02:00
a3d98477ee
package updates, handle empty price 2020-08-06 13:00:22 +02:00
82049e9446
handle all price output 2020-08-05 13:21:14 +02:00
bc30a13597
tabs component 2020-07-31 13:15:00 +02:00
a73fac1611
cleanup 2020-07-21 14:04:32 +02:00