apply directive to all inputs

This commit is contained in:
Javier 2016-07-12 11:50:32 -03:00
commit a8d2dd46a8
9 changed files with 17 additions and 17 deletions

View file

@ -43,12 +43,12 @@
</label> </label>
<div class="input"> <div class="input">
<input ng-show="!showAlternative" type="number" id="amount" <input ng-show="!showAlternative" type="number" id="amount" ignore-mouse-wheel
name="amount" ng-attr-placeholder="{{'Amount in ' + (showAlternative ? 'USD' : 'BTC')}}" name="amount" ng-attr-placeholder="{{'Amount in ' + (showAlternative ? 'USD' : 'BTC')}}"
ng-minlength="0.00000001" ng-maxlength="10000000000" ng-minlength="0.00000001" ng-maxlength="10000000000"
ng-model="amount" autocomplete="off" ng-disabled="buy.loading"> ng-model="amount" autocomplete="off" ng-disabled="buy.loading">
<input ng-show="showAlternative" type="number" id="fiat" <input ng-show="showAlternative" type="number" id="fiat" ignore-mouse-wheel
name="fiat" ng-attr-placeholder="{{'Amount in ' + (showAlternative ? 'USD' : 'BTC')}}" name="fiat" ng-attr-placeholder="{{'Amount in ' + (showAlternative ? 'USD' : 'BTC')}}"
ng-model="fiat" autocomplete="off" ng-disabled="buy.loading"> ng-model="fiat" autocomplete="off" ng-disabled="buy.loading">

View file

@ -49,12 +49,12 @@
<label>Amount in {{showAlternative ? 'USD' : 'BTC'}}</label> <label>Amount in {{showAlternative ? 'USD' : 'BTC'}}</label>
<div class="input"> <div class="input">
<input ng-show="!showAlternative" type="number" id="qty" <input ng-show="!showAlternative" type="number" id="qty" ignore-mouse-wheel
name="qty" ng-attr-placeholder="{{'Amount'}}" name="qty" ng-attr-placeholder="{{'Amount'}}"
ng-minlength="0.00000001" ng-maxlength="10000000000" ng-minlength="0.00000001" ng-maxlength="10000000000"
ng-model="qty" autocomplete="off" ng-change="buy.getBuyPrice(index.glideraToken, {'qty': qty})"> ng-model="qty" autocomplete="off" ng-change="buy.getBuyPrice(index.glideraToken, {'qty': qty})">
<input ng-show="showAlternative" type="number" id="fiat" <input ng-show="showAlternative" type="number" id="fiat" ignore-mouse-wheel
name="fiat" ng-attr-placeholder="{{'Amount'}}" name="fiat" ng-attr-placeholder="{{'Amount'}}"
ng-model="fiat" autocomplete="off" ng-change="buy.getBuyPrice(index.glideraToken, {'fiat': fiat})"> ng-model="fiat" autocomplete="off" ng-change="buy.getBuyPrice(index.glideraToken, {'fiat': fiat})">
@ -94,7 +94,7 @@
</p> </p>
<form name="buyForm" <form name="buyForm"
ng-submit="buy.sendRequest(index.glideraToken, index.glideraPermissions, twoFaCode)" novalidate> ng-submit="buy.sendRequest(index.glideraToken, index.glideraPermissions, twoFaCode)" novalidate>
<input type="number" ng-model="twoFaCode" required> <input type="number" ng-model="twoFaCode" required ignore-mouse-wheel>
<input class="button black expand round" <input class="button black expand round"
ng-style="{'background-color':index.backgroundColor}" ng-style="{'background-color':index.backgroundColor}"
type="submit" value="{{'Buy'}}" ng-disabled="buyForm.$invalid || buy.loading"> type="submit" value="{{'Buy'}}" ng-disabled="buyForm.$invalid || buy.loading">

View file

@ -87,7 +87,7 @@
<div ng-show="create.seedSourceId == 'trezor' || create.seedSourceId == 'ledger'"> <div ng-show="create.seedSourceId == 'trezor' || create.seedSourceId == 'ledger'">
<label class="oh"><span translate>Account Number</span> <label class="oh"><span translate>Account Number</span>
<input type="number" id="account" ng-model="account"> <input type="number" id="account" ng-model="account" ignore-mouse-wheel>
</label> </label>
</div> </div>

View file

@ -194,7 +194,7 @@
<div ng-show="seedSourceId == 'trezor' || seedSourceId == 'ledger'"> <div ng-show="seedSourceId == 'trezor' || seedSourceId == 'ledger'">
<label class="oh"><span translate>Account Number</span> <label class="oh"><span translate>Account Number</span>
<input type="number" id="account" ng-model="account"> <input type="number" id="account" ng-model="account" ignore-mouse-wheel>
</label> </label>
</div> </div>

View file

@ -73,7 +73,7 @@
<div ng-show="join.seedSourceId == 'trezor' || join.seedSourceId == 'ledger'"> <div ng-show="join.seedSourceId == 'trezor' || join.seedSourceId == 'ledger'">
<label class="oh"><span translate>Account Number</span> <label class="oh"><span translate>Account Number</span>
<input type="number" id="account" ng-model="account"> <input type="number" id="account" ng-model="account" ignore-mouse-wheel>
</label> </label>
</div> </div>

View file

@ -60,7 +60,7 @@
<span translate>Amount</span> <span translate>Amount</span>
</label> </label>
<div class="input"> <div class="input">
<input type="number" id="amount" name="amount" ng-attr-placeholder="{{'Amount in'|translate}} {{unitName}}" <input type="number" id="amount" name="amount" ng-attr-placeholder="{{'Amount in'|translate}} {{unitName}}" ignore-mouse-wheel
ng-model="_customAmount" ng-minlength="0.00000001" ng-maxlength="10000000000" valid-amount required autocomplete="off"> ng-model="_customAmount" ng-minlength="0.00000001" ng-maxlength="10000000000" valid-amount required autocomplete="off">
<input type="number" id="alternative" name="alternative" ng-model="_customAlternative" style="display:none"> <input type="number" id="alternative" name="alternative" ng-model="_customAlternative" style="display:none">
<a class="postfix button" ng-style="{'background-color':color}" ng-click="toggleAlternative()">{{unitName}}</a> <a class="postfix button" ng-style="{'background-color':color}" ng-click="toggleAlternative()">{{unitName}}</a>
@ -70,7 +70,7 @@
<label for="alternative"><span translate>Amount</span> [{{ alternativeIsoCode }}] <label for="alternative"><span translate>Amount</span> [{{ alternativeIsoCode }}]
</label> </label>
<div class="input"> <div class="input">
<input type="number" id="alternative" name="alternative" ng-attr-placeholder="{{'Amount in'|translate}} {{alternativeName}}" <input type="number" id="alternative" name="alternative" ng-attr-placeholder="{{'Amount in'|translate}} {{alternativeName}}" ignore-mouse-wheel
ng-model="_customAlternative" required autocomplete="off" required> ng-model="_customAlternative" required autocomplete="off" required>
<input type="number" id="amount" name="amount" ng-model="_customAmount" style="display:none"> <input type="number" id="amount" name="amount" ng-model="_customAmount" style="display:none">
<a class="postfix button black" ng-click="toggleAlternative()"> {{ alternativeIsoCode }}</a> <a class="postfix button black" ng-click="toggleAlternative()"> {{ alternativeIsoCode }}</a>

View file

@ -54,12 +54,12 @@
</span> </span>
</label> </label>
<div class="input"> <div class="input">
<input ng-show="!showAlternative" type="number" id="amount" <input ng-show="!showAlternative" type="number" id="amount" ignore-mouse-wheel
name="amount" ng-attr-placeholder="{{'Amount in ' + (showAlternative ? 'USD' : 'BTC')}}" name="amount" ng-attr-placeholder="{{'Amount in ' + (showAlternative ? 'USD' : 'BTC')}}"
ng-minlength="0.00000001" ng-maxlength="10000000000" ng-minlength="0.00000001" ng-maxlength="10000000000"
ng-model="amount" autocomplete="off"> ng-model="amount" autocomplete="off">
<input ng-show="showAlternative" type="number" id="fiat" <input ng-show="showAlternative" type="number" id="fiat" ignore-mouse-wheel
name="fiat" ng-attr-placeholder="{{'Amount in ' + (showAlternative ? 'USD' : 'BTC')}}" name="fiat" ng-attr-placeholder="{{'Amount in ' + (showAlternative ? 'USD' : 'BTC')}}"
ng-model="fiat" autocomplete="off"> ng-model="fiat" autocomplete="off">

View file

@ -48,12 +48,12 @@
<label><span>Amount in</span> {{showAlternative ? 'USD' : 'BTC'}}</label> <label><span>Amount in</span> {{showAlternative ? 'USD' : 'BTC'}}</label>
<div class="input"> <div class="input">
<input ng-show="!showAlternative" type="number" id="qty" <input ng-show="!showAlternative" type="number" id="qty" ignore-mouse-wheel
name="qty" ng-attr-placeholder="{{'Amount'}}" name="qty" ng-attr-placeholder="{{'Amount'}}"
ng-minlength="0.00000001" ng-maxlength="10000000000" ng-minlength="0.00000001" ng-maxlength="10000000000"
ng-model="qty" autocomplete="off" ng-change="sell.getSellPrice(index.glideraToken, {'qty': qty})"> ng-model="qty" autocomplete="off" ng-change="sell.getSellPrice(index.glideraToken, {'qty': qty})">
<input ng-show="showAlternative" type="number" id="fiat" <input ng-show="showAlternative" type="number" id="fiat" ignore-mouse-wheel
name="fiat" ng-attr-placeholder="{{'Amount'}}" name="fiat" ng-attr-placeholder="{{'Amount'}}"
ng-model="fiat" autocomplete="off" ng-change="sell.getSellPrice(index.glideraToken, {'fiat': fiat})"> ng-model="fiat" autocomplete="off" ng-change="sell.getSellPrice(index.glideraToken, {'fiat': fiat})">
@ -94,7 +94,7 @@
</p> </p>
<form name="sellForm" <form name="sellForm"
ng-submit="sell.createTx(index.glideraToken, index.glideraPermissions, twoFaCode)" novalidate> ng-submit="sell.createTx(index.glideraToken, index.glideraPermissions, twoFaCode)" novalidate>
<input type="number" ng-model="twoFaCode" required> <input type="number" ng-model="twoFaCode" required ignore-mouse-wheel>
<input class="button black expand round" <input class="button black expand round"
ng-style="{'background-color':index.backgroundColor}" ng-style="{'background-color':index.backgroundColor}"
type="submit" value="{{'Sell'}}" ng-disabled="sellForm.$invalid "> type="submit" value="{{'Sell'}}" ng-disabled="sellForm.$invalid ">

View file

@ -428,7 +428,7 @@
</label> </label>
<div class="input"> <div class="input">
<input type="number" id="amount" ng-disabled=" home.lockAmount" name="amount" ng-attr-placeholder="{{'Amount in'|translate}} {{home.unitName}}" ng-model="_amount" valid-amount required autocomplete="off" ng-focus="home.formFocus('amount')" ng-blur="home.formFocus(false)" ignore-mouse-wheel> <input type="number" id="amount" ng-disabled=" home.lockAmount" name="amount" ng-attr-placeholder="{{'Amount in'|translate}} {{home.unitName}}" ng-model="_amount" valid-amount required autocomplete="off" ng-focus="home.formFocus('amount')" ng-blur="home.formFocus(false)" ignore-mouse-wheel>
<input type="number" id="alternative" name="alternative" ng-model="_alternative" style="display:none" ignore-mouse-wheel> <input type="number" id="alternative" name="alternative" ng-model="_alternative" style="display:none">
<a class="postfix button" ng-style="{'background-color':index.backgroundColor}" ng-click="home.showAlternative()">{{home.unitName}}</a> <a class="postfix button" ng-style="{'background-color':index.backgroundColor}" ng-click="home.showAlternative()">{{home.unitName}}</a>
</div> </div>
</div> </div>
@ -437,7 +437,7 @@
</label> </label>
<div class="input"> <div class="input">
<input type="number" id="alternative" ng-disabled="!home.isRateAvailable || home.lockAmount" name="alternative" ng-attr-placeholder="{{'Amount in'|translate}} {{ home.alternativeName }}" ng-model="_alternative" required autocomplete="off" ng-focus="home.formFocus('amount')" ng-blur="home.formFocus(false)" ignore-mouse-wheel> <input type="number" id="alternative" ng-disabled="!home.isRateAvailable || home.lockAmount" name="alternative" ng-attr-placeholder="{{'Amount in'|translate}} {{ home.alternativeName }}" ng-model="_alternative" required autocomplete="off" ng-focus="home.formFocus('amount')" ng-blur="home.formFocus(false)" ignore-mouse-wheel>
<input type="number" id="amount" name="amount" ng-model="_amount" style="display:none" ignore-mouse-wheel> <input type="number" id="amount" name="amount" ng-model="_amount" style="display:none">
<a class="postfix button black" ng-click="home.hideAlternative()"> {{ home.alternativeIsoCode }}</a> <a class="postfix button black" ng-click="home.hideAlternative()"> {{ home.alternativeIsoCode }}</a>
</div> </div>
</div> </div>