Skip to content
This repository has been archived by the owner on Jan 14, 2022. It is now read-only.

Currency picker fix - #849 #855

Merged
merged 3 commits into from
Dec 12, 2018
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/assets/styles/common.css
Original file line number Diff line number Diff line change
Expand Up @@ -1600,3 +1600,9 @@ table tbody tr:nth-of-type(odd) {
padding-left: 32px;
}
}

li.dropdown.disabled a {
color: grey;
}


4 changes: 2 additions & 2 deletions src/components/bread-crumb/bread-crumb.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@
*/
-->
<div class="row breadcrumb-row">
<div class="col-sm-8">
<div class="col-sm-7">
<ol class="breadcrumb">
<li data-ng-repeat="section in sections">
<a class="text-capitalize" data-ng-if="section.url != '#'" href="{{section.url}}">{{section.name | alterWordSeparation: 'spaceSeparated'}}</a>
<span class="text-capitalize" data-ng-if="section.url == '#'">{{section.name | alterWordSeparation: 'spaceSeparated'}}</span>
</li>
</ol>
</div>
<div class="col-sm-4 breadcrumb breadcrumb-currency-picker pull-right">
<div class="col-sm-5 breadcrumb breadcrumb-currency-picker pull-right">
<ul class="hidden-xs"><currency-selector /></ul>
<ul class="hidden-xs"><rounding-selector /></ul>
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/components/currency-selector/currency-selector.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<li class="dropdown" data-uib-dropdown>
<a class="dropdown-toggle LSK-menu" id="main-currency-selector" data-uib-dropdown-toggle data-aria-haspopup="true" role="button" data-aria-expanded="false">
<span class="visible-xs">Currency&nbsp;<span class="caret"></span></span>
<span class="hidden-xs">{{currency.symbol}}&nbsp;<span class="caret"></span></span>
<span class="hidden-xs"><strong>{{currency.symbol}}</strong>&nbsp;<span class="caret"></span></span>
</a>
<ul class="dropdown-menu dropdown-menu-right currency-selector" role="menu" data-aria-labelledby="main-currency-selector">
<li ng-class="key">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ AppRounding.directive('roundingSelector', ($rootScope) => {
restrict: 'E',
replace: true,
controller: RoundingSelectorCtrl,
controllerAs: 'cs',
controllerAs: 'rs',
link: RoundingSelectorLink,
template,
};
Expand Down
14 changes: 7 additions & 7 deletions src/components/rounding-selector/rounding-selector.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,23 +15,23 @@
*
*/
-->
<li class="dropdown" data-uib-dropdown>
<li class="dropdown" data-uib-dropdown data-ng-class="{'disabled': ($root.currency.symbol !== 'BTC' && $root.currency.symbol !== 'LSK')}">
<a class="dropdown-toggle rounding-menu" id="main-rounding-selector" data-uib-dropdown-toggle data-aria-haspopup="true" role="button" data-aria-expanded="false">
<span class="visible-xs">Decimal&nbsp;<span class="caret"></span></span>
<span class="hidden-xs">Decimal&nbsp;places&nbsp;<span class="caret"></span></span>
<span class="visible-xs">Decimal&nbsp;places<span class="caret"></span></span>
<span class="hidden-xs">Decimal&nbsp;places:&nbsp;<strong>{{$root.decimalPlaces !== undefined ? $root.decimalPlaces : 'd'}}</strong>&nbsp;<span class="caret"></span></span>
</a>
<ul class="dropdown-menu dropdown-menu-right" role="decimal-menu" data-aria-labelledby="decimal-menu-dropdown">
<li data-ng-class='{active: $root.decimalPlaces === undefined}'>
<a data-ng-click='cs.setDecimalPlaces(undefined)' class='trim-floating-points'>Trim trailing zeros</a>
<a data-ng-click='rs.setDecimalPlaces(undefined)' class='trim-floating-points'>Trim trailing zeros</a>
</li>
<li data-ng-class='{active: $root.decimalPlaces === 0}'>
<a data-ng-click='cs.setDecimalPlaces(0)' class='round-to-0'>Round to whole number</a>
<a data-ng-click='rs.setDecimalPlaces(0)' class='round-to-0'>Round to whole number</a>
</li>
<li data-ng-class='{active: $root.decimalPlaces === 4}'>
<a data-ng-click='cs.setDecimalPlaces(4)' class='round-to-4'>Round to 4th decimal place</a>
<a data-ng-click='rs.setDecimalPlaces(4)' class='round-to-4'>Round to 4th decimal place</a>
</li>
<li data-ng-class='{active: $root.decimalPlaces === 8}'>
<a data-ng-click='cs.setDecimalPlaces(8)' class='show-all-8'>Show all decimals</a>
<a data-ng-click='rs.setDecimalPlaces(8)' class='show-all-8'>Show all decimals</a>
</li>
</ul>
</li>