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

Disabled left menu when no wallet, Progress bar changes #161

Merged
merged 2 commits into from
Oct 20, 2017

Conversation

vikas-cis-zz
Copy link

No description provided.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.01%) to 52.618% when pulling bb528b9 on vikas-cis:material_gui_bugs into ac9bddb on particl:develop.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.02%) to 52.586% when pulling 4e49a0b on vikas-cis:material_gui_bugs into ac9bddb on particl:develop.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.02%) to 52.586% when pulling 4e49a0b on vikas-cis:material_gui_bugs into ac9bddb on particl:develop.

@@ -57,6 +57,9 @@ export class AppComponent implements OnInit {
this.log.w('warn!');
this.log.i('info');
this.log.d('debug');
setTimeout(() => {
this.isWalletInitialized = this._modalsService.initializedWallet;
Copy link
Member

Choose a reason for hiding this comment

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

This fix is invalid.. you'll have to use an observable.. The best is probably to use the state service to create some sort of state around whether or not the wallet is initialized

@@ -22,25 +22,25 @@

<md-content layout-padding class="submenuarea">
<md-list class="sidesubmenu">
<a routerLinkActive="active" routerLink="/wallet/receive">
<a routerLinkActive="active" [routerLink]="(!isWalletInitialized) ? null : '/wallet/receive'">
Copy link
Member

Choose a reason for hiding this comment

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

This is really untidy.. Rather disable the links, that way the users get a cursor informing them the link is disabled.

You can use a css class that has

    pointer-events: none;
    cursor: not-allowed;

<md-list-item>
<div class="md-line" fxFlex="100%" fxLayout.lg="row" fxlayout.lt-sm="column" fxLayout.sm="column"
fxlayout.lt-xs="column" fxLayout.xs="column">
<h5 fxFlex="10%"> Privacy level </h5>

<div fxFlex="'column'" fxLayoutWrap>
<div class="privacy-labels" fxFlex="100%">
<span fxFlex="" fxLayoutAlign="start center" class="privacy-label cursor-pointer"
Copy link
Member

Choose a reason for hiding this comment

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

Please fix this indentation

<md-list-item>
<div class="md-line" fxFlex="100%" fxLayout.lg="row" fxlayout.lt-sm="column" fxLayout.sm="column"
fxlayout.lt-xs="column" fxLayout.xs="column">
<h5 fxFlex="10%"> Privacy level </h5>

<div fxFlex="'column'" fxLayoutWrap>
<div class="privacy-labels" fxFlex="100%">
<span fxFlex="" fxLayoutAlign="start center" class="privacy-label cursor-pointer"
(click)="progress = 10; setPrivacy(2)">Low</span>
Copy link
Member

Choose a reason for hiding this comment

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

I don't think low should ever be less than 3, infact I think the transaction will be rejected if its less than 3

Copy link
Member

Choose a reason for hiding this comment

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

you could even set low to 4

Copy link
Member

Choose a reason for hiding this comment

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

Maybe create one function, setPrivacy, which will set progress and set the level? Instead of doing 2 operations in the html...

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.2%) to 52.424% when pulling 8cffcdb on vikas-cis:material_gui_bugs into ac9bddb on particl:develop.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.2%) to 52.371% when pulling c925693 on vikas-cis:material_gui_bugs into 612e5fa on particl:develop.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.2%) to 52.384% when pulling c35bee2 on vikas-cis:material_gui_bugs into 612e5fa on particl:develop.

<md-list-item>
<md-icon>history</md-icon>
<span>History</span>
</md-list-item>
</a>
<a routerLinkActive="active" routerLink="/wallet/address-book">
Copy link
Member

Choose a reason for hiding this comment

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

Ok this solution is even worse. Please can we revert to the previous one

@@ -164,6 +164,7 @@ export class ModalsService {
const locked = this._rpcService.state.get('locked');
if (locked) {
this.initializedWallet = true;
this._rpcService.state.set('activeWallet', true);
Copy link
Member

Choose a reason for hiding this comment

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

Please move the setting of this stake to rpc-state.service

@@ -173,8 +174,10 @@ export class ModalsService {
// check if account is active
Copy link
Member

Choose a reason for hiding this comment

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

Please move this to rpc-state.service

@rynomster rynomster merged commit c35bee2 into particl:develop Oct 20, 2017
zaSmilingIdiot added a commit that referenced this pull request Feb 28, 2022
Sidebar: tweak "unlock to see market bid notifications" indicator
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants