Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
nomad-lab
encyclopedia-gui
Commits
2dc10ce8
Commit
2dc10ce8
authored
Jul 28, 2019
by
Georg Huhs
Browse files
adaptations and some design fixes for production update
parent
6958e898
Pipeline
#53051
passed with stage
in 6 seconds
Changes
4
Pipelines
3
Hide whitespace changes
Inline
Side-by-side
client/bundle.js
View file @
2dc10ce8
...
...
@@ -8870,7 +8870,7 @@ class SearchMod {
if
(
this
.
queryTypes
[
i
]
===
'
F
'
)
queryObj
.
search_by
.
formula
=
item
;
else
if
(
this
.
queryTypes
[
i
]
===
'
E
'
)
elements
.
push
(
item
);
else
if
(
this
.
queryTypes
[
i
]
!==
'
S
'
){
// property
if
(
this
.
queryTypes
[
i
].
indexOf
(
'
band-gap
'
)
===
0
){
// special case
/*
if (this.queryTypes[i].indexOf('band-gap') === 0){ // special case
let bandGapData = this.queryTypes[i].split(':');
queryObj.band_gap = {"min": util.eV2J(bandGapData[1]),
"max": util.eV2J(bandGapData[2])};
...
...
@@ -8878,7 +8878,8 @@ class SearchMod {
}else if (this.queryTypes[i].indexOf('mass-density') === 0){ // special case
let massDensity = this.queryTypes[i].split(':');
queryObj.mass_density = {"min": massDensity[1], "max": massDensity[2]};
}
else
if
(
this
.
queryTypes
[
i
].
indexOf
(
'
has
'
)
===
0
){
// boolean fields
}else */
if
(
this
.
queryTypes
[
i
].
indexOf
(
'
has
'
)
===
0
){
// boolean fields
queryObj
[
replaceDashes
(
this
.
queryTypes
[
i
])]
=
'
Yes
'
;
}
else
// general fields
queryObj
[
replaceDashes
(
this
.
queryTypes
[
i
])]
=
item
.
split
(
'
|
'
);
...
...
@@ -9245,14 +9246,13 @@ class PropertiesBox {
<input type="checkbox" class="system-type-field" value="1D"> 1D<br>
</div>
<!--
<div class="field">
<div class="field-title"><span info-sys-data="mass-density">Mass density</span> <span style="font-weight: normal;">(kg/m<sup>3</sup>)</span></div>
<!-- <div class="test-slider"> </div> -->
Min: <input type="text" class="mass-density-min-field">
Max: <input type="text" class="mass-density-max-field">
</div>
-->
</div>
...
...
@@ -9290,18 +9290,13 @@ class PropertiesBox {
</div>
<div class="results-panel props-tab-panel" >
<!--
<div style="float: left; width: 47%;">
<div class="field">
<div class="field-title"><span info-sys-data="band-gap">Band gap</span> <span style="font-weight: normal;">(eV)</span></div>
Min: <input type="text" class="band-gap-min-field">
Max: <input type="text" class="band-gap-max-field">
<!--
<input type="range" class="band-gap-slider" min="5" max="200" step="5" value="100"/>
<input type="range" class="band-gap-slider" min="5" max="200" step="5" value="100"/>
-->
</div>
</div>
<div style="float: left; width: 5%;"> </div>
...
...
@@ -9312,20 +9307,21 @@ class PropertiesBox {
<input type="radio" name="band-gap-type" value="i"> Indirect<br>
<input type="radio" name="band-gap-type" value="d/i" checked> Both<br>
</div>
</div>
-->
<div style="clear: both;"></div>
<div class="field" style="background-color: #CCC; padding: 10px;">
<div style="font-weight: bold; padding-bottom: 6px" >Results containing...</div>
<div style="float: left; width: 47%;">
<input type="checkbox" class="has-band-structure-field" value="Band structure">
<span info-sys-data="has-band-structure">Band structure</span><br>
<input type="checkbox" class="has-dos-field" value="DOS">
<span info-sys-data="has-dos">DOS</span><br>
<input type="checkbox" class="has-fermi-surface-field" value="Fermi surface">
<span info-sys-data="has-fermi-surface">Fermi surface</span><br>
<input type="checkbox" class="has-band-structure-field" value="Band structure">
<span info-sys-data="has-band-structure">Band structure</span><br>
<input type="checkbox" class="has-dos-field" value="DOS">
<span info-sys-data="has-dos">DOS</span><br>
<!--
<input type="checkbox" class="has-fermi-surface-field" value="Fermi surface">
<span info-sys-data="has-fermi-surface">Fermi surface</span><br>
-->
</div>
<div style="float: right; width: 47%;">
<input type="checkbox" class="has-thermal-properties-field" value="Thermal properties">
...
...
@@ -9485,9 +9481,9 @@ class PropertiesBox {
this
.
addPropsFromTextFields
(
propsMap
,[
'
space-group-number
'
],
reset
);
this
.
addPropsFromDropdownList
(
propsMap
,[
'
structure-type
'
],
reset
);
this
.
addPropsFromCheckboxes
(
propsMap
,[
'
system-type
'
,
'
crystal-system
'
],
reset
);
this
.
addMassDensityProps
(
propsMap
,
reset
);
//
this.addMassDensityProps(propsMap, reset);
}
else
if
(
tabString
===
'
results
'
){
this
.
addBandgapProps
(
propsMap
,
reset
);
//
this.addBandgapProps(propsMap, reset);
this
.
addPropsFromCheckboxes
(
propsMap
,[
'
has-band-structure
'
,
'
has-dos
'
,
'
has-fermi-surface
'
,
'
has-thermal-properties
'
],
reset
);
...
...
client/css/styles.css
View file @
2dc10ce8
...
...
@@ -423,7 +423,7 @@ div.title span.unfolded::before{
#search-properties-box
{
background-color
:
#DDD
;
padding
:
4px
;
height
:
3
7
0px
;
height
:
3
3
0px
;
}
.props-box-tabs-wrapper
{
...
...
@@ -482,7 +482,7 @@ input[type='range'] {
background-image
:
-webkit-linear-gradient
(
top
,
#777
,
#AAA
,
#777
);
}
.space-group-field
{
width
:
90%
;}
.space-group-
number-
field
{
width
:
90%
;}
.mass-density-min-field
,
.mass-density-max-field
,
.band-gap-min-field
,
.band-gap-max-field
,
.bulk-modulus-field
{
width
:
54px
;
...
...
client/src/search-mod/PropertiesBox.view.js
View file @
2dc10ce8
...
...
@@ -70,14 +70,13 @@ class PropertiesBox {
<input type="checkbox" class="system-type-field" value="1D"> 1D<br>
</div>
<!--
<div class="field">
<div class="field-title"><span info-sys-data="mass-density">Mass density</span> <span style="font-weight: normal;">(kg/m<sup>3</sup>)</span></div>
<!-- <div class="test-slider"> </div> -->
Min: <input type="text" class="mass-density-min-field">
Max: <input type="text" class="mass-density-max-field">
</div>
-->
</div>
...
...
@@ -115,18 +114,13 @@ class PropertiesBox {
</div>
<div class="results-panel props-tab-panel" >
<!--
<div style="float: left; width: 47%;">
<div class="field">
<div class="field-title"><span info-sys-data="band-gap">Band gap</span> <span style="font-weight: normal;">(eV)</span></div>
Min: <input type="text" class="band-gap-min-field">
Max: <input type="text" class="band-gap-max-field">
<!--
<input type="range" class="band-gap-slider" min="5" max="200" step="5" value="100"/>
<input type="range" class="band-gap-slider" min="5" max="200" step="5" value="100"/>
-->
</div>
</div>
<div style="float: left; width: 5%;"> </div>
...
...
@@ -137,20 +131,21 @@ class PropertiesBox {
<input type="radio" name="band-gap-type" value="i"> Indirect<br>
<input type="radio" name="band-gap-type" value="d/i" checked> Both<br>
</div>
</div>
-->
<div style="clear: both;"></div>
<div class="field" style="background-color: #CCC; padding: 10px;">
<div style="font-weight: bold; padding-bottom: 6px" >Results containing...</div>
<div style="float: left; width: 47%;">
<input type="checkbox" class="has-band-structure-field" value="Band structure">
<span info-sys-data="has-band-structure">Band structure</span><br>
<input type="checkbox" class="has-dos-field" value="DOS">
<span info-sys-data="has-dos">DOS</span><br>
<input type="checkbox" class="has-fermi-surface-field" value="Fermi surface">
<span info-sys-data="has-fermi-surface">Fermi surface</span><br>
<input type="checkbox" class="has-band-structure-field" value="Band structure">
<span info-sys-data="has-band-structure">Band structure</span><br>
<input type="checkbox" class="has-dos-field" value="DOS">
<span info-sys-data="has-dos">DOS</span><br>
<!--
<input type="checkbox" class="has-fermi-surface-field" value="Fermi surface">
<span info-sys-data="has-fermi-surface">Fermi surface</span><br>
-->
</div>
<div style="float: right; width: 47%;">
<input type="checkbox" class="has-thermal-properties-field" value="Thermal properties">
...
...
@@ -310,9 +305,9 @@ class PropertiesBox {
this
.
addPropsFromTextFields
(
propsMap
,[
'
space-group-number
'
],
reset
);
this
.
addPropsFromDropdownList
(
propsMap
,[
'
structure-type
'
],
reset
);
this
.
addPropsFromCheckboxes
(
propsMap
,[
'
system-type
'
,
'
crystal-system
'
],
reset
);
this
.
addMassDensityProps
(
propsMap
,
reset
);
//
this.addMassDensityProps(propsMap, reset);
}
else
if
(
tabString
===
'
results
'
){
this
.
addBandgapProps
(
propsMap
,
reset
);
//
this.addBandgapProps(propsMap, reset);
this
.
addPropsFromCheckboxes
(
propsMap
,[
'
has-band-structure
'
,
'
has-dos
'
,
'
has-fermi-surface
'
,
'
has-thermal-properties
'
],
reset
);
...
...
client/src/search-mod/SearchMod.js
View file @
2dc10ce8
...
...
@@ -181,7 +181,7 @@ class SearchMod {
if
(
this
.
queryTypes
[
i
]
===
'
F
'
)
queryObj
.
search_by
.
formula
=
item
;
else
if
(
this
.
queryTypes
[
i
]
===
'
E
'
)
elements
.
push
(
item
);
else
if
(
this
.
queryTypes
[
i
]
!==
'
S
'
){
// property
if
(
this
.
queryTypes
[
i
].
indexOf
(
'
band-gap
'
)
===
0
){
// special case
/*
if (this.queryTypes[i].indexOf('band-gap') === 0){ // special case
let bandGapData = this.queryTypes[i].split(':');
queryObj.band_gap = {"min": util.eV2J(bandGapData[1]),
"max": util.eV2J(bandGapData[2])};
...
...
@@ -189,7 +189,8 @@ class SearchMod {
}else if (this.queryTypes[i].indexOf('mass-density') === 0){ // special case
let massDensity = this.queryTypes[i].split(':');
queryObj.mass_density = {"min": massDensity[1], "max": massDensity[2]};
}
else
if
(
this
.
queryTypes
[
i
].
indexOf
(
'
has
'
)
===
0
){
// boolean fields
}else */
if
(
this
.
queryTypes
[
i
].
indexOf
(
'
has
'
)
===
0
){
// boolean fields
queryObj
[
replaceDashes
(
this
.
queryTypes
[
i
])]
=
'
Yes
'
;
}
else
// general fields
queryObj
[
replaceDashes
(
this
.
queryTypes
[
i
])]
=
item
.
split
(
'
|
'
);
...
...
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