Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
baas-ide
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
guxukai
baas-ide
Commits
0f60ad47
Commit
0f60ad47
authored
Jan 23, 2017
by
yann300
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
renaming formatData / formatSelf
parent
404815b9
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
9 deletions
+9
-9
SolidityLocals.js
src/ui/SolidityLocals.js
+1
-1
SolidityState.js
src/ui/SolidityState.js
+1
-1
SolidityTypeFormatter.js
src/ui/SolidityTypeFormatter.js
+2
-2
TreeView.js
src/ui/TreeView.js
+5
-5
No files found.
src/ui/SolidityLocals.js
View file @
0f60ad47
...
@@ -12,7 +12,7 @@ class SolidityLocals {
...
@@ -12,7 +12,7 @@ class SolidityLocals {
this
.
traceManager
=
_traceManager
this
.
traceManager
=
_traceManager
this
.
basicPanel
=
new
DropdownPanel
(
'Solidity Locals'
,
{
this
.
basicPanel
=
new
DropdownPanel
(
'Solidity Locals'
,
{
json
:
true
,
json
:
true
,
format
Data
:
solidityTypeFormatter
.
formatData
,
format
Self
:
solidityTypeFormatter
.
formatSelf
,
extractData
:
solidityTypeFormatter
.
extractData
extractData
:
solidityTypeFormatter
.
extractData
})
})
this
.
init
()
this
.
init
()
...
...
src/ui/SolidityState.js
View file @
0f60ad47
...
@@ -11,7 +11,7 @@ function SolidityState (_parent, _traceManager, _codeManager, _solidityProxy) {
...
@@ -11,7 +11,7 @@ function SolidityState (_parent, _traceManager, _codeManager, _solidityProxy) {
this
.
solidityProxy
=
_solidityProxy
this
.
solidityProxy
=
_solidityProxy
this
.
basicPanel
=
new
DropdownPanel
(
'Solidity State'
,
{
this
.
basicPanel
=
new
DropdownPanel
(
'Solidity State'
,
{
json
:
true
,
json
:
true
,
format
Data
:
solidityTypeFormatter
.
formatData
,
format
Self
:
solidityTypeFormatter
.
formatSelf
,
extractData
:
solidityTypeFormatter
.
extractData
extractData
:
solidityTypeFormatter
.
extractData
})
})
this
.
init
()
this
.
init
()
...
...
src/ui/SolidityTypeFormatter.js
View file @
0f60ad47
...
@@ -3,11 +3,11 @@ var yo = require('yo-yo')
...
@@ -3,11 +3,11 @@ var yo = require('yo-yo')
var
BN
=
require
(
'ethereumjs-util'
).
BN
var
BN
=
require
(
'ethereumjs-util'
).
BN
module
.
exports
=
{
module
.
exports
=
{
format
Data
:
formatData
,
format
Self
:
formatSelf
,
extractData
:
extractData
extractData
:
extractData
}
}
function
format
Data
(
key
,
data
)
{
function
format
Self
(
key
,
data
)
{
var
style
=
fontColor
(
data
)
var
style
=
fontColor
(
data
)
var
keyStyle
=
data
.
isProperty
?
'color:#847979'
:
''
var
keyStyle
=
data
.
isProperty
?
'color:#847979'
:
''
if
(
data
.
type
===
'string'
)
{
if
(
data
.
type
===
'string'
)
{
...
...
src/ui/TreeView.js
View file @
0f60ad47
...
@@ -11,7 +11,7 @@ class TreeView {
...
@@ -11,7 +11,7 @@ class TreeView {
this
.
beforeJsonNodeRendered
=
opts
.
beforeJsonNodeRendered
||
noop
this
.
beforeJsonNodeRendered
=
opts
.
beforeJsonNodeRendered
||
noop
this
.
beforeJsonValueRendered
=
opts
.
beforeJsonValueRendered
||
noop
this
.
beforeJsonValueRendered
=
opts
.
beforeJsonValueRendered
||
noop
this
.
extractData
=
opts
.
extractData
||
this
.
extractDataDefault
this
.
extractData
=
opts
.
extractData
||
this
.
extractDataDefault
this
.
format
Data
=
opts
.
formatData
||
this
.
formatData
Default
this
.
format
Self
=
opts
.
formatSelf
||
this
.
formatSelf
Default
this
.
view
=
null
this
.
view
=
null
this
.
cssLabel
=
ui
.
formatCss
(
opts
.
css
||
{},
style
.
label
)
this
.
cssLabel
=
ui
.
formatCss
(
opts
.
css
||
{},
style
.
label
)
this
.
cssUl
=
ui
.
formatCss
(
opts
.
css
||
{},
style
.
cssUl
)
this
.
cssUl
=
ui
.
formatCss
(
opts
.
css
||
{},
style
.
cssUl
)
...
@@ -38,7 +38,7 @@ class TreeView {
...
@@ -38,7 +38,7 @@ class TreeView {
var
children
=
(
data
.
children
||
[]).
map
((
child
,
index
)
=>
{
var
children
=
(
data
.
children
||
[]).
map
((
child
,
index
)
=>
{
return
this
.
renderObject
(
child
.
value
,
data
,
child
.
key
,
expand
,
keyPath
+
'_'
+
child
.
key
)
return
this
.
renderObject
(
child
.
value
,
data
,
child
.
key
,
expand
,
keyPath
+
'_'
+
child
.
key
)
})
})
return
this
.
formatData
Internal
(
key
,
data
,
children
,
expand
,
keyPath
)
return
this
.
formatData
(
key
,
data
,
children
,
expand
,
keyPath
)
}
}
renderProperties
(
json
,
expand
)
{
renderProperties
(
json
,
expand
)
{
...
@@ -48,8 +48,8 @@ class TreeView {
...
@@ -48,8 +48,8 @@ class TreeView {
return
yo
`<ul style=
${
this
.
cssUl
}
>
${
children
}
</ul>`
return
yo
`<ul style=
${
this
.
cssUl
}
>
${
children
}
</ul>`
}
}
formatData
Internal
(
key
,
data
,
children
,
expand
,
keyPath
)
{
formatData
(
key
,
data
,
children
,
expand
,
keyPath
)
{
var
label
=
yo
`<span style=
${
this
.
cssLabel
}
><label style=
${
ui
.
formatCss
(
style
.
caret
)}
></label><span style=
${
ui
.
formatCss
(
style
.
data
)}
>
${
this
.
format
Data
(
key
,
data
)}
</span></span>`
var
label
=
yo
`<span style=
${
this
.
cssLabel
}
><label style=
${
ui
.
formatCss
(
style
.
caret
)}
></label><span style=
${
ui
.
formatCss
(
style
.
data
)}
>
${
this
.
format
Self
(
key
,
data
)}
</span></span>`
var
renderedChildren
=
''
var
renderedChildren
=
''
if
(
children
.
length
)
{
if
(
children
.
length
)
{
renderedChildren
=
yo
`<ul style=
${
this
.
cssUl
}
>
${
children
}
</ul>`
renderedChildren
=
yo
`<ul style=
${
this
.
cssUl
}
>
${
children
}
</ul>`
...
@@ -66,7 +66,7 @@ class TreeView {
...
@@ -66,7 +66,7 @@ class TreeView {
return
yo
`<li style=
${
this
.
cssLi
}
>
${
label
}${
renderedChildren
}
</li>`
return
yo
`<li style=
${
this
.
cssLi
}
>
${
label
}${
renderedChildren
}
</li>`
}
}
format
Data
Default
(
key
,
data
)
{
format
Self
Default
(
key
,
data
)
{
return
yo
`<label>
${
key
}
:
${
data
.
self
}
</label>`
return
yo
`<label>
${
key
}
:
${
data
.
self
}
</label>`
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment