From 697e8c07682574c64111901a54f173be54686d25 Mon Sep 17 00:00:00 2001 From: Kevin Serrano Date: Tue, 28 Jun 2016 12:48:03 -0700 Subject: [PATCH 1/4] Truncate account name further. --- ui/app/accounts/account-list-item.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/app/accounts/account-list-item.js b/ui/app/accounts/account-list-item.js index 6bba6e145..b17bef711 100644 --- a/ui/app/accounts/account-list-item.js +++ b/ui/app/accounts/account-list-item.js @@ -49,7 +49,7 @@ NewComponent.prototype.render = function () { overflow: 'hidden', textOverflow: 'ellipsis', }, - }, ethUtil.toChecksumAddress(identity.address)), + }, ethUtil.toChecksumAddress(identity.address).substring(0,7)), h(EtherBalance, { value: account.balance, }), From f9540cf48c9f7e42c41e9e1648bb57ee2b5d441f Mon Sep 17 00:00:00 2001 From: Kevin Serrano Date: Tue, 28 Jun 2016 13:07:46 -0700 Subject: [PATCH 2/4] Wallet name now is properly truncated. --- ui/app/accounts/account-list-item.js | 2 +- ui/app/components/account-panel.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/app/accounts/account-list-item.js b/ui/app/accounts/account-list-item.js index b17bef711..6bba6e145 100644 --- a/ui/app/accounts/account-list-item.js +++ b/ui/app/accounts/account-list-item.js @@ -49,7 +49,7 @@ NewComponent.prototype.render = function () { overflow: 'hidden', textOverflow: 'ellipsis', }, - }, ethUtil.toChecksumAddress(identity.address).substring(0,7)), + }, ethUtil.toChecksumAddress(identity.address)), h(EtherBalance, { value: account.balance, }), diff --git a/ui/app/components/account-panel.js b/ui/app/components/account-panel.js index c69557d62..d50522fa2 100644 --- a/ui/app/components/account-panel.js +++ b/ui/app/components/account-panel.js @@ -48,7 +48,7 @@ AccountPanel.prototype.render = function () { address: panelState.identiconKey, imageify: state.imageifyIdenticons, }), - h('span.font-small', panelState.identiconLabel), + h('span.font-small', panelState.identiconLabel.substring(0, 7) + '...'), ]), // account address, balance From 661d9bffb3ea91cc6d7bc855fd0ec587866f61bf Mon Sep 17 00:00:00 2001 From: Kevin Serrano Date: Tue, 28 Jun 2016 13:10:29 -0700 Subject: [PATCH 3/4] Changelog update and reduce allowed characters from 30 to 20. --- CHANGELOG.md | 3 ++- ui/app/components/editable-label.js | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 25a5fedb3..4c03aad19 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,8 @@ - Fixed bug where MetaMask interfered with PDF loading. - Moved switch account icon into menu bar. - Changed status shapes to be a yellow warning sign for failure and ellipsis for pending transactions. -- Now enforce 30 character limit on wallet names. +- Now enforce 20 character limit on wallet names. +- Wallet titles are now properly truncated in transaction confirmation. ## 2.4.4 2016-06-23 diff --git a/ui/app/components/editable-label.js b/ui/app/components/editable-label.js index 05ffd4c92..4f690ebfe 100644 --- a/ui/app/components/editable-label.js +++ b/ui/app/components/editable-label.js @@ -18,7 +18,7 @@ EditableLabel.prototype.render = function () { return h('div.editable-label', [ h('input.sizing-input', { defaultValue: props.textValue, - maxLength: '30', + maxLength: '20', onKeyPress: (event) => { this.saveIfEnter(event) }, From 1cd17af2ad494e36ee37740648ccd8c47994ec82 Mon Sep 17 00:00:00 2001 From: Kevin Serrano Date: Tue, 28 Jun 2016 13:10:57 -0700 Subject: [PATCH 4/4] Second layer of 20 character check modified. --- ui/app/components/editable-label.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/app/components/editable-label.js b/ui/app/components/editable-label.js index 4f690ebfe..41936f5e0 100644 --- a/ui/app/components/editable-label.js +++ b/ui/app/components/editable-label.js @@ -45,7 +45,7 @@ EditableLabel.prototype.saveIfEnter = function (event) { EditableLabel.prototype.saveText = function () { var container = findDOMNode(this) var text = container.querySelector('.editable-label input').value - var truncatedText = text.substring(0, 30) + var truncatedText = text.substring(0, 20) this.props.saveText(truncatedText) this.setState({ isEditingLabel: false, textLabel: truncatedText }) }