diff --git a/interface/client/styles/popupWindows.import.less b/interface/client/styles/popupWindows.import.less index f8f9e23b3..f2685de8f 100644 --- a/interface/client/styles/popupWindows.import.less +++ b/interface/client/styles/popupWindows.import.less @@ -63,10 +63,10 @@ right: 0; padding: 0 @gridHeight; padding-top: @gridHeight * 3; - background: linear-gradient(transparent 0%, @colorGrayLight 20%); + background: linear-gradient(transparent 0%, @colorGrayLight 35%); &.dapp-small { - background: linear-gradient(transparent 50%, @colorGrayLight 70%); + background: linear-gradient(transparent 50%, @colorGrayLight 70%); } } @@ -75,7 +75,7 @@ font-weight: 600; } - &.update-available { + &.update-available { -webkit-user-select: all; .text { @@ -183,7 +183,7 @@ } } - // Parameters + // Parameters .fees, .parameters { font-size: 0.9em; @@ -216,7 +216,7 @@ &:hover strong { word-break: break-all; } - + } .type { text-align: right; @@ -230,9 +230,9 @@ } ::selection { - color: #FFF; + color: #FFF; background: @colorLink; - } + } } ol li::before { @@ -574,7 +574,7 @@ } .data { font-size: 0.9em; - + pre { margin: 0 -@defaultMargin; overflow: auto; diff --git a/interface/client/templates/popupWindows/sendTransactionConfirmation.html b/interface/client/templates/popupWindows/sendTransactionConfirmation.html index 3dbf4db12..4cc9c5ff8 100644 --- a/interface/client/templates/popupWindows/sendTransactionConfirmation.html +++ b/interface/client/templates/popupWindows/sendTransactionConfirmation.html @@ -11,7 +11,7 @@

{{i18n "mist.popupWindows.sendTransactionConfirmation.title.sendTransaction"

{{i18n "mist.popupWindows.sendTransactionConfirmation.title.createContract"}}

{{/if}} {{/if}} - +
@@ -34,7 +34,7 @@

{{i18n "mist.popupWindows.sendTransactionConfirmation.title.createContract"}

{{/if}}
- +
{{#if to}} {{#if TemplateVar.get "toIsContract"}} @@ -65,45 +65,11 @@

{{i18n "mist.popupWindows.sendTransactionConfirmation.title.createContract"} {{/unless}} {{/if}} - {{#if data}} - - {{#if showFormattedParams}} -
-

{{{i18n "mist.popupWindows.sendTransactionConfirmation.parameters"}}} - {{{i18n "mist.popupWindows.sendTransactionConfirmation.showRawBytecode"}}} -

-
    - {{# each param in params}} -
  1. {{> dapp_output output=param }}
  2. - {{/each}} -
-
- {{else}} -
-

{{i18n "mist.popupWindows.sendTransactionConfirmation.data"}} - - {{# if params}} - {{{i18n "mist.popupWindows.sendTransactionConfirmation.showDecodedParameters"}}} - {{else}} - {{#if to}} - {{#unless (TemplateVar.get "lookingUpFunctionSignature")}} - {{i18n "mist.popupWindows.sendTransactionConfirmation.lookupData"}} - - {{/unless}} - {{/if}} - {{/if}} -

- -
{{{formattedData}}}
-
- {{/if}} - {{/if}} -
  • - {{i18n "mist.popupWindows.sendTransactionConfirmation.estimatedFee"}} + {{i18n "mist.popupWindows.sendTransactionConfirmation.estimatedFee"}}
    {{#if $eq (TemplateVar.get "estimatedGas") "invalid"}} @@ -120,7 +86,7 @@

    {{i18n "mist.popupWindows.sendTransactionConfirmation.data"}} {{/if}}

    -
  • +
  • {{i18n "mist.popupWindows.sendTransactionConfirmation.gasLimit"}} @@ -138,23 +104,56 @@

    {{i18n "mist.popupWindows.sendTransactionConfirmation.data"}}

+ {{#if data}} + {{#if showFormattedParams}} +
+

{{{i18n "mist.popupWindows.sendTransactionConfirmation.parameters"}}} + {{{i18n "mist.popupWindows.sendTransactionConfirmation.showRawBytecode"}}} +

+
    + {{# each param in params}} +
  1. {{> dapp_output output=param }}
  2. + {{/each}} +
+
+ {{else}} +
+

{{i18n "mist.popupWindows.sendTransactionConfirmation.data"}} + + {{# if params}} + {{{i18n "mist.popupWindows.sendTransactionConfirmation.showDecodedParameters"}}} + {{else}} + {{#if to}} + {{#unless (TemplateVar.get "lookingUpFunctionSignature")}} + {{i18n "mist.popupWindows.sendTransactionConfirmation.lookupData"}} + + {{/unless}} + {{/if}} + {{/if}} +

+ +
{{{formattedData}}}
+
+ {{/if}} + {{/if}} +

{{/with}} - +
diff --git a/interface/client/templates/popupWindows/sendTransactionConfirmation.js b/interface/client/templates/popupWindows/sendTransactionConfirmation.js index c0c9e5c48..52d913731 100644 --- a/interface/client/templates/popupWindows/sendTransactionConfirmation.js +++ b/interface/client/templates/popupWindows/sendTransactionConfirmation.js @@ -6,7 +6,7 @@ Template Controllers var setWindowSize = function(template){ Tracker.afterFlush(function(){ - ipc.send('backendAction_setWindowSize', 580, template.$('.popup-windows').height() + 60); + ipc.send('backendAction_setWindowSize', 580, template.$('.popup-windows').height() + 120); }); } @@ -103,7 +103,7 @@ Template['popupWindows_sendTransactionConfirmation'].onCreated(function(){ var data = Session.get('data'); if(data) { - + // set window size setWindowSize(template); @@ -127,10 +127,10 @@ Template['popupWindows_sendTransactionConfirmation'].onCreated(function(){ web3.eth.getCode(data.to, function(e, res){ if(!e && res && res.length > 2) { TemplateVar.set(template, 'toIsContract', true); - setWindowSize(template); + setWindowSize(template); } }); - + if (data.data) { localSignatureLookup(data.data).then(function(textSignature) { // Clean version of function signature. Striping params @@ -261,7 +261,7 @@ Template['popupWindows_sendTransactionConfirmation'].helpers({ @method (transactionInvalid) */ 'transactionInvalid': function() { - return TemplateVar.get('estimatedGas') === 'invalid' + return TemplateVar.get('estimatedGas') === 'invalid' || TemplateVar.get('estimatedGas') === 0 || typeof TemplateVar.get('estimatedGas') === 'undefined'; } @@ -294,7 +294,7 @@ Template['popupWindows_sendTransactionConfirmation'].events({ */ 'submit form': function(e, template){ e.preventDefault(); - + var data = Session.get('data'), pw = template.find('input[type="password"]').value, gas = web3.fromDecimal(TemplateVar.get('providedGas')); @@ -373,7 +373,7 @@ Template['popupWindows_sendTransactionConfirmation'].events({ remoteSignatureLookup(data.data).then(function(textSignature) { TemplateVar.set(template, 'lookingUpFunctionSignature', false); - + // Clean version of function signature. Striping params TemplateVar.set(template, 'executionFunction', textSignature.replace(/\(.+$/g, '')); TemplateVar.set(template, 'hasSignature', true); @@ -385,10 +385,9 @@ Template['popupWindows_sendTransactionConfirmation'].events({ ipc.send('backendAction_decodeFunctionSignature', textSignature, data.data); } }).catch(function(bytesSignature) { - TemplateVar.set(template, 'lookingUpFunctionSignature', false); + TemplateVar.set(template, 'lookingUpFunctionSignature', false); TemplateVar.set(template, 'executionFunction', bytesSignature); TemplateVar.set(template, 'hasSignature', false); }); } }); -