Skip to content

Commit

Permalink
toaster
Browse files Browse the repository at this point in the history
  • Loading branch information
LianaHus committed May 22, 2019
1 parent 0c34ac2 commit 21353bc
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
2 changes: 2 additions & 0 deletions src/app/components/side-panel.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ const css = csjs`
.swapitTitle {
text-transform: uppercase;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.swapitTitle a{
cursor: help;
Expand Down
2 changes: 1 addition & 1 deletion src/app/debugger/debuggerUI/TxBrowser.js
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ TxBrowser.prototype.render = function () {
/>
</div>
<div class="${css.txbuttons} btn-group p-1">
<button class='btn btn-primary btn-sm ${css.txbutton}' id='load' title='${this.state.debugging ? 'Stop' : 'Start'} debugging' onclick=${function () { self.submit() }}>${this.state.debugging ? 'Stop' : 'Start'} debugging</button>
<button class='btn btn-primary btn-sm ${css.txbutton} disabled='${this.state.txNumber ? 'false' : 'true'}' id='load' title='${this.state.debugging ? 'Stop' : 'Start'} debugging' onclick=${function () { self.submit() }}>${this.state.debugging ? 'Stop' : 'Start'} debugging</button>
</div>
</div>
<span id='error'></span>
Expand Down
2 changes: 1 addition & 1 deletion src/app/tabs/run-tab.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import { BaseApi } from 'remix-plugin'

const profile = {
name: 'run',
displayName: 'Deploy and run transactions',
displayName: 'Deploy & run transactions',
methods: [],
events: [],
icon: 'data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4NCjwhLS0gR2VuZXJhdG9yOiBBZG9iZSBJbGx1c3RyYXRvciAxNi4wLjAsIFNWRyBFeHBvcnQgUGx1Zy1JbiAuIFNWRyBWZXJzaW9uOiA2LjAwIEJ1aWxkIDApICAtLT4NCjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9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2 deletions src/app/ui/tooltip.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,10 @@ class Toaster {
}, 2000)
animation(this.tooltip, css.animateTop.className)
}
render (tooltipText, action, opts) {
render (tooltipText, actionElement, opts) {
opts = defaultOptions(opts)
if (typeof(tooltipText) === 'object' && tooltipText.message !== undefined)
tooltipText = tooltipText.message

return new Promise((resolve, reject) => {
const shortTooltipText = tooltipText.length > 201 ? tooltipText.substring(0, 200) + '...' : tooltipText
Expand All @@ -38,7 +40,7 @@ class Toaster {
${shortTooltipText}
${button}
</span>
${action}
${actionElement}
</div>`
let timeOut = () => {
return setTimeout(() => {
Expand Down

0 comments on commit 21353bc

Please sign in to comment.