Skip to content

Commit 23cf09b

Browse files
committed
� Conflicts: � dist/RNAcentral-sequence-search.js � dist/RNAcentral-sequence-search.js.map
2 parents f626079 + 0f8c379 commit 23cf09b

File tree

6 files changed

+35
-14
lines changed

6 files changed

+35
-14
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,8 @@ parameter | description
120120
----------------------------|-----------------------------------------------------------------------------------|
121121
h3Color | change the color of the `Similar sequences` and `Rfam classification` text |
122122
h3Size | change the size of the `Similar sequences` and `Rfam classification` text |
123-
exactMatchBackgroundColor | change the background color of the "Exact match" area |
123+
exactMatchBackgroundColor | change the background color of the "Exact match" area |
124+
jobIdBackgroundColor | change the background color of the "Job id" area |
124125
similarSeqText | change the `Similar sequences` text |
125126
facetColor | change the color of the facet title |
126127
facetSize | change the size of the facet title |

dist/RNAcentral-sequence-search.js

Lines changed: 8 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/RNAcentral-sequence-search.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/containers/SequenceSearch/components/Results/index.jsx

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ class Results extends React.Component {
4343
};
4444
const loadMoreButtonColor = this.props.customStyle && this.props.customStyle.loadMoreButtonColor ? this.props.customStyle.loadMoreButtonColor : "";
4545
const similarSeqText = this.props.customStyle && this.props.customStyle.similarSeqText ? this.props.customStyle.similarSeqText : "Similar sequences";
46+
const jobIdBackgroundColor = this.props.customStyle && this.props.customStyle.jobIdBackgroundColor ? this.props.customStyle.jobIdBackgroundColor : "";
4647

4748
// exact match URS ids
4849
const exactMatch = this.props.exactMatch;
@@ -78,10 +79,21 @@ class Results extends React.Component {
7879
</div>
7980
)
8081
}
82+
{
83+
(this.props.jobId && this.props.jobList && !this.props.jobList.length > 0 || this.props.jobId && this.props.jobList && this.props.jobList.length > 0 && !this.props.jobList.includes(this.props.jobId) ) && (
84+
<div className="row" key={`job-id`}>
85+
<div className="small-9 columns">
86+
<div className="callout secondary" style={{backgroundColor: jobIdBackgroundColor}}>
87+
<p>Job id: <span className="job-id">{ this.props.jobId }</span></p>
88+
</div>
89+
</div>
90+
</div>
91+
)
92+
}
8193
{
8294
this.props.jobId && this.props.status === "partial_success" && (
8395
<div className="row" key={`partial-success-div`}>
84-
<div className="small-12 columns">
96+
<div className="small-9 columns">
8597
<div className="callout warning">
8698
<h4>Search against some databases failed.</h4>
8799
<p>This usually happens when the nhmmer is unable to complete the search within a 5 minute time limit.</p>
@@ -93,7 +105,7 @@ class Results extends React.Component {
93105
{
94106
this.props.jobId && this.props.status === "does_not_exist" && (
95107
<div className="row" key={`does-not-exist-div`}>
96-
<div className="small-12 columns">
108+
<div className="small-9 columns">
97109
<div className="callout alert">
98110
<h4>Job with id='{ this.props.jobId }' does not exist.</h4>
99111
</div>
@@ -104,7 +116,7 @@ class Results extends React.Component {
104116
{
105117
this.props.jobId && this.props.status === "error" && (
106118
<div className="row" key={`error-div`}>
107-
<div className="small-12 columns">
119+
<div className="small-9 columns">
108120
<div className="callout alert">
109121
<h4>There was an error.</h4>
110122
<a href="mailto:rnacentral@gmail.com">Contact us</a> if the problem persists.

src/containers/SequenceSearch/components/Results/index.scss

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
.job-id {
2+
font-family: Consolas, "Liberation Mono", Courier, monospace;
3+
font-weight: normal;
4+
padding: 0.125rem 0.3125rem 0.0625rem;
5+
overflow-x: auto;
6+
font-size: .95rem;
7+
}
8+
19
.result {
210
list-style: none;
311
}

src/containers/SequenceSearch/components/SearchForm/index.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ class SearchForm extends React.Component {
8282
<form onSubmit={(e) => this.onSubmit(e)}>
8383
<div className="row">
8484
<div className="small-9 columns">
85-
<textarea id="sequence" name="sequence" rows="7" value={this.props.sequence} onChange={(e) => this.props.onSequenceTextareaChange(e)} placeholder="Enter RNA/DNA sequence (with an optional description in FASTA format) or job ID" />
85+
<textarea id="sequence" name="sequence" rows="7" value={this.props.sequence} onChange={(e) => this.props.onSequenceTextareaChange(e)} placeholder="Enter RNA/DNA sequence (with an optional description in FASTA format) or job id" />
8686
</div>
8787
<div className="small-3 columns">
8888
<div className="row">

0 commit comments

Comments
 (0)