Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
Breeze
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
3
Issues
3
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DeStream-public
Breeze
Commits
55bf8c24
Commit
55bf8c24
authored
Jul 07, 2017
by
Pieterjan Vanhoof
Committed by
GitHub
Jul 07, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #156 from stratisproject/ui
Add context menu, add logout confirmation
parents
f7e763d8
cd4b1d46
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
93 additions
and
10 deletions
+93
-10
main.ts
Breeze.UI/main.ts
+4
-0
package.json
Breeze.UI/package.json
+1
-0
app.module.ts
Breeze.UI/src/app/app.module.ts
+4
-1
logout-confirmation.component.css
...let/logout-confirmation/logout-confirmation.component.css
+0
-0
logout-confirmation.component.html
...et/logout-confirmation/logout-confirmation.component.html
+25
-0
logout-confirmation.component.spec.ts
...logout-confirmation/logout-confirmation.component.spec.ts
+25
-0
logout-confirmation.component.ts
...llet/logout-confirmation/logout-confirmation.component.ts
+22
-0
menu.component.ts
Breeze.UI/src/app/wallet/menu/menu.component.ts
+6
-3
sidebar.component.css
Breeze.UI/src/app/wallet/sidebar/sidebar.component.css
+0
-0
sidebar.component.ts
Breeze.UI/src/app/wallet/sidebar/sidebar.component.ts
+1
-1
status-bar.component.css
Breeze.UI/src/app/wallet/status-bar/status-bar.component.css
+0
-0
status-bar.component.ts
Breeze.UI/src/app/wallet/status-bar/status-bar.component.ts
+4
-4
transaction-details.component.css
...let/transaction-details/transaction-details.component.css
+0
-0
transaction-details.component.ts
...llet/transaction-details/transaction-details.component.ts
+1
-1
No files found.
Breeze.UI/main.ts
View file @
55bf8c24
...
...
@@ -19,6 +19,10 @@ if (serve) {
});
}
require
(
'electron-context-menu'
)({
showInspectElement
:
serve
});
// Keep a global reference of the window object, if you don't, the window will
// be closed automatically when the JavaScript object is garbage collected.
let
mainWindow
=
null
;
...
...
Breeze.UI/package.json
View file @
55bf8c24
...
...
@@ -54,6 +54,7 @@
"@ng-bootstrap/ng-bootstrap"
:
"^1.0.0-alpha.27"
,
"angular2-material-datepicker"
:
"^0.5.0"
,
"core-js"
:
"^2.4.1"
,
"electron-context-menu"
:
"^0.9.1"
,
"ngx-clipboard"
:
"^8.0.3"
,
"rxjs"
:
"5.4.1"
,
"zone.js"
:
"^0.8.12"
...
...
Breeze.UI/src/app/app.module.ts
View file @
55bf8c24
...
...
@@ -19,6 +19,7 @@ import { GlobalService } from './shared/services/global.service';
import
{
SendComponent
}
from
'./wallet/send/send.component'
;
import
{
ReceiveComponent
}
from
'./wallet/receive/receive.component'
;
import
{
TransactionDetailsComponent
}
from
'./wallet/transaction-details/transaction-details.component'
;
import
{
LogoutConfirmationComponent
}
from
'./wallet/logout-confirmation/logout-confirmation.component'
;
@
NgModule
({
...
...
@@ -36,6 +37,7 @@ import { TransactionDetailsComponent } from './wallet/transaction-details/transa
declarations
:
[
AppComponent
,
LoginComponent
,
LogoutConfirmationComponent
,
SendComponent
,
ReceiveComponent
,
TransactionDetailsComponent
...
...
@@ -43,7 +45,8 @@ import { TransactionDetailsComponent } from './wallet/transaction-details/transa
entryComponents
:
[
SendComponent
,
ReceiveComponent
,
TransactionDetailsComponent
TransactionDetailsComponent
,
LogoutConfirmationComponent
],
providers
:
[
ApiService
,
GlobalService
],
bootstrap
:
[
AppComponent
]
...
...
Breeze.UI/src/app/wallet/
sidebar/sidebar.component.s
css
→
Breeze.UI/src/app/wallet/
logout-confirmation/logout-confirmation.component.
css
View file @
55bf8c24
File moved
Breeze.UI/src/app/wallet/logout-confirmation/logout-confirmation.component.html
0 → 100644
View file @
55bf8c24
<div
id=
"modalLogout"
tabindex=
"-1"
role=
"dialog"
aria-labelledby=
"modal_logout"
aria-hidden=
"true"
>
<div
class=
"modal-dialog"
role=
"document"
>
<div>
<div
class=
"modal-header"
>
<div
class=
"bubble"
><i
class=
"icon-download"
></i></div>
</div>
<div
class=
"modal-body"
>
<h5
class=
"modal-title text-uppercase"
id=
"modalReceive"
>
Logout
</h5>
<form>
<div
class=
"form-group clearfix"
>
<label
class=
"float-left"
>
Are you sure you want to logout?
</label>
</div>
<div>
<button
type=
"button"
class=
"btn btn-lg btn-primary float-left"
data-dismiss=
"modal"
aria-label=
"Logout"
(
click
)="
onLogout
()"
>
Yes
</button>
<button
type=
"button"
class=
"btn btn-lg btn-primary float-right"
data-dismiss=
"modal"
aria-label=
"Close"
(
click
)="
activeModal
.
close
('
Close
click
')"
>
Cancel
</button>
</div>
<br>
</form>
</div>
<div
class=
"modal-footer"
>
<p></p>
</div>
</div>
</div>
</div>
Breeze.UI/src/app/wallet/logout-confirmation/logout-confirmation.component.spec.ts
0 → 100644
View file @
55bf8c24
import
{
async
,
ComponentFixture
,
TestBed
}
from
'@angular/core/testing'
;
import
{
LogoutConfirmationComponent
}
from
'./logout-confirmation.component'
;
describe
(
'LogoutConfirmationComponent'
,
()
=>
{
let
component
:
LogoutConfirmationComponent
;
let
fixture
:
ComponentFixture
<
LogoutConfirmationComponent
>
;
beforeEach
(
async
(()
=>
{
TestBed
.
configureTestingModule
({
declarations
:
[
LogoutConfirmationComponent
]
})
.
compileComponents
();
}));
beforeEach
(()
=>
{
fixture
=
TestBed
.
createComponent
(
LogoutConfirmationComponent
);
component
=
fixture
.
componentInstance
;
fixture
.
detectChanges
();
});
it
(
'should be created'
,
()
=>
{
expect
(
component
).
toBeTruthy
();
});
});
Breeze.UI/src/app/wallet/logout-confirmation/logout-confirmation.component.ts
0 → 100644
View file @
55bf8c24
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
Router
}
from
'@angular/router'
;
import
{
NgbModal
,
NgbActiveModal
}
from
'@ng-bootstrap/ng-bootstrap'
;
@
Component
({
selector
:
'app-logout-confirmation'
,
templateUrl
:
'./logout-confirmation.component.html'
,
styleUrls
:
[
'./logout-confirmation.component.css'
]
})
export
class
LogoutConfirmationComponent
implements
OnInit
{
constructor
(
private
activeModal
:
NgbActiveModal
,
private
router
:
Router
)
{
}
ngOnInit
()
{
}
private
onLogout
()
{
this
.
activeModal
.
close
();
this
.
router
.
navigate
([
'/login'
]);
}
}
Breeze.UI/src/app/wallet/menu/menu.component.ts
View file @
55bf8c24
import
{
Component
}
from
'@angular/core'
;
import
{
Router
}
from
'@angular/router'
;
import
{
NgbModal
,
NgbActiveModal
}
from
'@ng-bootstrap/ng-bootstrap'
;
import
{
LogoutConfirmationComponent
}
from
'../logout-confirmation/logout-confirmation.component'
;
@
Component
({
selector
:
'app-menu'
,
...
...
@@ -7,9 +10,9 @@ import { Router } from '@angular/router';
styleUrls
:
[
'./menu.component.css'
],
})
export
class
MenuComponent
{
constructor
(
private
router
:
Router
)
{}
constructor
(
private
modalService
:
NgbModal
)
{}
private
logOut
()
{
this
.
router
.
navigate
([
'/login'
]
);
const
modalRef
=
this
.
modalService
.
open
(
LogoutConfirmationComponent
);
}
}
Breeze.UI/src/app/wallet/s
tatus-bar/status-bar.component.s
css
→
Breeze.UI/src/app/wallet/s
idebar/sidebar.component.
css
View file @
55bf8c24
File moved
Breeze.UI/src/app/wallet/sidebar/sidebar.component.ts
View file @
55bf8c24
...
...
@@ -3,7 +3,7 @@ import { Component, OnInit } from '@angular/core';
@
Component
({
selector
:
'sidebar'
,
templateUrl
:
'./sidebar.component.html'
,
styleUrls
:
[
'./sidebar.component.
s
css'
]
styleUrls
:
[
'./sidebar.component.css'
]
})
export
class
SidebarComponent
implements
OnInit
{
...
...
Breeze.UI/src/app/wallet/
transaction-details/transaction-details.component.s
css
→
Breeze.UI/src/app/wallet/
status-bar/status-bar.component.
css
View file @
55bf8c24
File moved
Breeze.UI/src/app/wallet/status-bar/status-bar.component.ts
View file @
55bf8c24
...
...
@@ -10,7 +10,7 @@ import { Subscription } from 'rxjs/Subscription';
@
Component
({
selector
:
'status-bar'
,
templateUrl
:
'./status-bar.component.html'
,
styleUrls
:
[
'./status-bar.component.
s
css'
]
styleUrls
:
[
'./status-bar.component.css'
]
})
export
class
StatusBarComponent
implements
OnInit
{
...
...
@@ -46,15 +46,15 @@ export class StatusBarComponent implements OnInit {
if
(
!
this
.
isChainSynced
)
{
this
.
percentSynced
=
"syncing..."
;
}
}
else
{
this
.
percentSyncedNumber
=
((
this
.
lastBlockSyncedHeight
/
this
.
chainTip
)
*
100
);
if
(
this
.
percentSyncedNumber
.
toFixed
(
0
)
===
"100"
&&
this
.
lastBlockSyncedHeight
!=
this
.
chainTip
)
{
this
.
percentSyncedNumber
=
99
;
}
this
.
percentSynced
=
this
.
percentSyncedNumber
.
toFixed
(
0
)
+
"%"
;
}
this
.
percentSynced
=
this
.
percentSyncedNumber
.
toFixed
(
0
)
+
"%"
;
}
}
},
error
=>
{
...
...
Breeze.UI/src/app/wallet/transaction-details/transaction-details.component.css
0 → 100644
View file @
55bf8c24
Breeze.UI/src/app/wallet/transaction-details/transaction-details.component.ts
View file @
55bf8c24
...
...
@@ -5,7 +5,7 @@ import { NgbModal, NgbActiveModal } from '@ng-bootstrap/ng-bootstrap';
@
Component
({
selector
:
'transaction-details'
,
templateUrl
:
'./transaction-details.component.html'
,
styleUrls
:
[
'./transaction-details.component.
s
css'
]
styleUrls
:
[
'./transaction-details.component.css'
]
})
export
class
TransactionDetailsComponent
implements
OnInit
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment