Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
nni
Commits
15952874
Commit
15952874
authored
Sep 11, 2019
by
Lijiao
Committed by
chicm-ms
Sep 11, 2019
Browse files
Add Trial No. message in compare modal and add a button to link webui document (#1538)
parent
330e1e18
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
27 additions
and
6 deletions
+27
-6
src/webui/src/components/Modal/Compare.tsx
src/webui/src/components/Modal/Compare.tsx
+11
-1
src/webui/src/components/SlideBar.tsx
src/webui/src/components/SlideBar.tsx
+14
-4
src/webui/src/static/style/slideBar.scss
src/webui/src/static/style/slideBar.scss
+2
-1
No files found.
src/webui/src/components/Modal/Compare.tsx
View file @
15952874
...
@@ -107,6 +107,7 @@ class Compare extends React.Component<CompareProps, {}> {
...
@@ -107,6 +107,7 @@ class Compare extends React.Component<CompareProps, {}> {
initColumn
=
()
=>
{
initColumn
=
()
=>
{
const
{
compareRows
}
=
this
.
props
;
const
{
compareRows
}
=
this
.
props
;
const
idList
:
Array
<
string
>
=
[];
const
idList
:
Array
<
string
>
=
[];
const
sequenceIdList
:
Array
<
number
>
=
[];
const
durationList
:
Array
<
number
>
=
[];
const
durationList
:
Array
<
number
>
=
[];
const
parameterList
:
Array
<
object
>
=
[];
const
parameterList
:
Array
<
object
>
=
[];
...
@@ -117,6 +118,7 @@ class Compare extends React.Component<CompareProps, {}> {
...
@@ -117,6 +118,7 @@ class Compare extends React.Component<CompareProps, {}> {
Object
.
keys
(
compareRows
).
map
(
item
=>
{
Object
.
keys
(
compareRows
).
map
(
item
=>
{
const
temp
=
compareRows
[
item
];
const
temp
=
compareRows
[
item
];
idList
.
push
(
temp
.
id
);
idList
.
push
(
temp
.
id
);
sequenceIdList
.
push
(
temp
.
sequenceId
);
durationList
.
push
(
temp
.
duration
);
durationList
.
push
(
temp
.
duration
);
parameterList
.
push
(
temp
.
description
.
parameters
);
parameterList
.
push
(
temp
.
description
.
parameters
);
});
});
...
@@ -124,13 +126,21 @@ class Compare extends React.Component<CompareProps, {}> {
...
@@ -124,13 +126,21 @@ class Compare extends React.Component<CompareProps, {}> {
<
table
className
=
"compare"
>
<
table
className
=
"compare"
>
<
tbody
>
<
tbody
>
<
tr
>
<
tr
>
<
td
/
>
<
td
className
=
"column"
>
Id
</
td
>
{
Object
.
keys
(
idList
).
map
(
key
=>
{
{
Object
.
keys
(
idList
).
map
(
key
=>
{
return
(
return
(
<
td
className
=
"value idList"
key
=
{
key
}
>
{
idList
[
key
]
}
</
td
>
<
td
className
=
"value idList"
key
=
{
key
}
>
{
idList
[
key
]
}
</
td
>
);
);
})
}
})
}
</
tr
>
</
tr
>
<
tr
>
<
td
className
=
"column"
>
Trial No.
</
td
>
{
Object
.
keys
(
sequenceIdList
).
map
(
key
=>
{
return
(
<
td
className
=
"value idList"
key
=
{
key
}
>
{
sequenceIdList
[
key
]
}
</
td
>
);
})
}
</
tr
>
<
tr
>
<
tr
>
<
td
className
=
"column"
>
Default metric
</
td
>
<
td
className
=
"column"
>
Default metric
</
td
>
{
Object
.
keys
(
compareRows
).
map
(
index
=>
{
{
Object
.
keys
(
compareRows
).
map
(
index
=>
{
...
...
src/webui/src/components/SlideBar.tsx
View file @
15952874
...
@@ -223,6 +223,16 @@ class SlideBar extends React.Component<SliderProps, SliderState> {
...
@@ -223,6 +223,16 @@ class SlideBar extends React.Component<SliderProps, SliderState> {
<
span
>
{
DETAILTABS
}
</
span
>
<
span
>
{
DETAILTABS
}
</
span
>
</
Col
>
</
Col
>
<
Col
span
=
{
16
}
className
=
"desktop-right"
>
<
Col
span
=
{
16
}
className
=
"desktop-right"
>
<
span
>
<
Button
className
=
"fresh"
type
=
"ghost"
>
<
a
target
=
"_blank"
href
=
"https://nni.readthedocs.io/en/latest/Tutorial/WebUI.html"
>
<
Icon
type
=
"question"
/><
span
>
Help
</
span
>
</
a
>
</
Button
>
</
span
>
<
span
>
{
this
.
select
()
}
</
span
>
<
span
>
{
this
.
select
()
}
</
span
>
<
span
>
<
span
>
<
Dropdown
<
Dropdown
...
@@ -237,10 +247,10 @@ class SlideBar extends React.Component<SliderProps, SliderState> {
...
@@ -237,10 +247,10 @@ class SlideBar extends React.Component<SliderProps, SliderState> {
<
span
>
View
</
span
>
<
span
>
View
</
span
>
{
{
menuVisible
menuVisible
?
?
<
Icon
type
=
"up"
className
=
"margin-icon"
/>
<
Icon
type
=
"up"
className
=
"margin-icon"
/>
:
:
<
Icon
type
=
"down"
className
=
"margin-icon"
/>
<
Icon
type
=
"down"
className
=
"margin-icon"
/>
}
}
</
a
>
</
a
>
</
Dropdown
>
</
Dropdown
>
...
...
src/webui/src/static/style/slideBar.scss
View file @
15952874
...
@@ -9,10 +9,11 @@ $drowHoverBgColor: #e2e2e2;
...
@@ -9,10 +9,11 @@ $drowHoverBgColor: #e2e2e2;
border
:
none
;
border
:
none
;
color
:
#fff
;
color
:
#fff
;
font-size
:
16px
;
font-size
:
16px
;
padding
:
0
;
padding
:
0
8px
;
}
}
.fresh
:hover
{
.fresh
:hover
{
color
:
#fff
;
color
:
#fff
;
background-color
:
#006cb5
;
}
}
.dropdown
{
.dropdown
{
...
...
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