Fix pending styling, refactor button titles and fix color for payable

pull/1/head
ninabreznik 7 years ago committed by yann300
parent d7e8ad0977
commit 2bb3f7082f
  1. 4
      assets/css/universal-dapp.css
  2. 6
      src/app/tabs/run-tab.js
  3. 9
      src/universal-dapp.js

@ -216,8 +216,8 @@
}
#runTabView .contractProperty.payable .call {
background-color: hsla(0, 82%, 82%, .5); /* lightRed in style-guide.js */
border-color: hsla(0, 82%, 82%, .5); /* lightRed in style-guide.js */
background-color: hsla(0, 82%, 82%, 1); /* red in style-guide.js */
border-color: hsla(0, 82%, 82%, 1); /* red in style-guide.js */
width: 25%;
}

@ -69,7 +69,8 @@ var css = csjs`
margin-top: 2%;
border: none;
}
.pendingTxsContainer extends ${styles.displayBox} {
.pendingTxsContainer {
${styles.displayBox}
display: flex;
flex-direction: column;
background-color: ${styles.colors.transparent};
@ -128,7 +129,8 @@ var css = csjs`
color: ${styles.colors.lightGrey};
font-style: italic;
}
.pendingTxsText extends ${styles.displayBox} {
.pendingTxsText {
${styles.displayBox}
text-align: center;
color: ${styles.colors.lightGrey};
font-style: italic;

@ -334,7 +334,8 @@ UniversalDApp.prototype.getCallButton = function (args) {
if (lookupOnly) {
$contractProperty.addClass('constant')
button.attr('title', (title + " - call)"))
button.attr('title', (title + ' - call'))
call()
}
if (args.funABI.inputs && args.funABI.inputs.length > 0) {
@ -343,11 +344,11 @@ UniversalDApp.prototype.getCallButton = function (args) {
if (args.funABI.payable === true) {
$contractProperty.addClass('payable')
button.attr('title', (title + " - transact (payable)"))
button.attr('title', (title + ' - transact (payable)'))
}
if (args.funABI.payable === false) {
button.attr('title', (title + " - transact (not payable)"))
if (!lookupOnly && args.funABI.payable === false) {
button.attr('title', (title + ' - transact (not payable)'))
}
return $contractProperty

Loading…
Cancel
Save