Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: add plugin system, add IEO plugin #607

Closed
wants to merge 1 commit into from

Conversation

akhlopiachyi
Copy link
Contributor

No description provided.

@sonarcloud
Copy link

sonarcloud bot commented Apr 30, 2021

SonarCloud Quality Gate failed.

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot E 2 Security Hotspots
Code Smell A 17 Code Smells

No Coverage information No Coverage information
11.5% 11.5% Duplication

@akhlopiachyi akhlopiachyi added Ready Ready for a review Required: QA Need to test labels May 4, 2021
Comment on lines +1 to +5
[
{
"name": "ieo"
}
]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we should have IEO plugin enabled by default, keep this file empty


export const PG_TITLE_PREFIX = 'Cryptobase';

export const pgRoutes = (isLoggedIn: boolean, isLight?: boolean): string[][] => {
export const pgRoutes = (isLoggedIn: boolean, Plugins: PluginsManager, isLight?: boolean): string[][] => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this file will have conflicts with P2P PR, could we please merge this PR after P2P patch?

@@ -87,10 +88,14 @@ class SidebarContainer extends React.Component<Props, State> {
'pg-sidebar-wrapper--hidden': !isActive,
});

const imageSrc = this.tryRequireRoot(lang)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

imageSrc is declared but not used anywhere

Comment on lines +226 to +244
private tryRequireRoot = (name: string) => {
try {
require(`../../assets/images/sidebar/${name}.svg`);

return true;
} catch (err) {
return false;
}
};

private tryRequirePlugins = (name: string) => {
try {
require(`../../plugins/assets/images/${name}.svg`);

return true;
} catch (err) {
return false;
}
};
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

make a common func that accepts src address as argument

@@ -118,7 +119,7 @@ export const marketStreams = (market: Market) => {
];

if (incrementalOrderBook()) {
store.dispatch(depthIncrementSubscribe(market.id));
store(Plugins.getReduxReducer()).dispatch(depthIncrementSubscribe(market.id));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

does WS work as expected with this patch?

Comment on lines +13 to +40
```javascript
plugins: [{
name: 'ieo',
config: {
fields: {
name: 'IEO',
description: true,
ratio: true,
metadata: true,
},
}
}]
```

In order to have **Auctions** plugin set these to `env.js`

```javascript
plugins: [{
name: 'ieo',
config: {
fields: {
name: 'Auctions',
description: false,
ratio: false,
metadata: false,
},
}
}]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I remember baseapp side doesn't listen for additional IEO configuration, could you please update README

@akushniruk akushniruk added Outdated and removed Ready Ready for a review Required: QA Need to test labels Feb 9, 2023
@akushniruk
Copy link
Member

need rewrite to new react 18 etc

@kh-ruslan kh-ruslan closed this Feb 22, 2023
@kh-ruslan
Copy link

moved to baseapp-aurora

@kh-ruslan kh-ruslan deleted the feature/ieo-plugin branch February 22, 2023 14:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

4 participants