sequenceserver 2.0.0.beta1 → 2.0.0.beta3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 9e93a0ff5ecf5f80747e270285cf563557ecfb46
4
- data.tar.gz: 17d972e191f301ffb704bb3838b5f7de0b8f0f4c
2
+ SHA256:
3
+ metadata.gz: c896a2ea19a91dbb08a321031f4ef62489ea85191821d9f67bfed2e88dd918ad
4
+ data.tar.gz: 9d4e09e3097a6fa5ec1bf691e7d1ca216cbcb062b63df4dfbdd4d0daee9e1906
5
5
  SHA512:
6
- metadata.gz: 15ef2d18c14fc2cfaec9a422ee1b569cfa380ea23df1258045c4085ccb2fbfef8f0b26a5eccde5a58ceb68eace7c67669cef6bade15dc11ec0e85fbfb07bb4dd
7
- data.tar.gz: 9ecd465890cb316446748d181b9c4a2a29a53b203d943142d76f23e2a53cd8bbabbaf5f798f8478317aef09ed0b3d23dfbbe4487f97eee013167de4b2dee410c
6
+ metadata.gz: 8eb71af6ecddeef7bab23be7b6208f2309406a8ebd68079e0c231fcceed7991e82113f671f815fd2c817e7126521bd9d7ab2be944268f0a867b869c77c283364
7
+ data.tar.gz: b5e2acc07ccdcd254f769e772c1d46579ae3009b81ff8e327b221ccac7b39c28885ffa0f108c5fdd8ba66d57db310ed7673977a2b1f80798a23979784a963b9f
data/.travis.yml CHANGED
@@ -2,43 +2,34 @@ language: ruby
2
2
 
3
3
  rvm:
4
4
  - 2.3
5
- - 2.4
6
5
  - 2.5
7
6
 
8
- addons:
9
- sauce_connect: true
10
-
11
7
  branches:
12
8
  only:
13
9
  - 1.0.x # stable
14
10
  - master
15
11
 
16
12
  install:
17
- - wget -c "ftp://ftp.ncbi.nlm.nih.gov/blast/executables/blast+/2.6.0/ncbi-blast-2.6.0+-x64-linux.tar.gz"
13
+ - wget -c "https://github.com/mozilla/geckodriver/releases/download/v0.24.0/geckodriver-v0.24.0-linux64.tar.gz"
14
+ - mkdir geckodriver && tar xvf geckodriver-*.tar.gz -C geckodriver
15
+ - export PATH="geckodriver:$PATH"
16
+ - wget -c "ftp://ftp.ncbi.nlm.nih.gov/blast/executables/blast+/2.9.0/ncbi-blast-2.9.0+-x64-linux.tar.gz"
18
17
  - tar xvf ncbi-blast-*.tar.gz
19
18
  - gem install bundler && bundle
20
- - bundle exec bin/sequenceserver -s -b ncbi-blast-2.6.0+/bin -d spec/database/sample
19
+ - bundle exec bin/sequenceserver -s -b ncbi-blast-2.9.0+/bin -d spec/database/sample
21
20
 
22
21
  before_script:
23
22
  - curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter && chmod +x ./cc-test-reporter
24
23
  - ./cc-test-reporter before-build
25
24
  script:
26
- - bundle exec rspec --exclude-pattern 'capybara*' # unit tests
27
- - platform='macOS 10.14' browserName=safari browserVersion=12 bundle exec rspec spec/capybara_spec.rb
28
- - platform='macOS 10.14' browserName=chrome browserVersion=71 bundle exec rspec spec/capybara_spec.rb
29
- - platform='macOS 10.14' browserName=firefox browserVersion=64 bundle exec rspec spec/capybara_spec.rb
30
- - platform='Windows 10' browserName=microsoftedge browserVersion='16.16299' bundle exec rspec spec/capybara_spec.rb
31
- - platform='Windows 10' browserName=chrome browserVersion=71 bundle exec rspec spec/capybara_spec.rb
32
- - platform='Windows 10' browserName=firefox browserVersion=64 bundle exec rspec spec/capybara_spec.rb
33
- - platform='Linux' browserName=chrome browserVersion=48 bundle exec rspec spec/capybara_spec.rb
34
- - platform='Linux' browserName=firefox browserVersion=45 bundle exec rspec spec/capybara_spec.rb
25
+ - bundle exec rspec
35
26
  after_script:
36
27
  - ./cc-test-reporter after-build # --exit-code $TRAVIS_TEST_RESULT
37
28
 
38
29
  cache:
39
30
  directories:
40
31
  - vendor/bundle
41
- - ncbi-blast-2.6.0+
32
+ - ncbi-blast-2.9.0+
42
33
 
43
34
  sudo: false
44
35
 
data/Dockerfile CHANGED
@@ -11,18 +11,13 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
11
11
  curl wget \
12
12
  gnupg \
13
13
  git \
14
- ncbi-blast+ \
15
14
  zlib1g-dev
16
15
 
17
- RUN curl -sL https://deb.nodesource.com/setup_8.x | bash - && \
18
- apt-get update && apt-get install -y --no-install-recommends \
19
- nodejs npm && \
20
- rm -rf /var/lib/apt/lists/*
21
-
22
16
  VOLUME ["/db"]
23
17
  EXPOSE 4567
24
18
 
25
19
  COPY . /sequenceserver
26
20
  WORKDIR /sequenceserver
27
- RUN gem install bundler && bundle && npm install
21
+ RUN gem install bundler && bundle install --without=development
22
+ RUN yes '' | bundle exec bin/sequenceserver -s
28
23
  ENTRYPOINT ["bundle", "exec", "bin/sequenceserver", "-d", "/db"]
data/README.md CHANGED
@@ -4,7 +4,7 @@
4
4
  [![gitter chat](https://badges.gitter.im/gitterHQ/gitter.png)](https://gitter.im/wurmlab/sequenceserver)
5
5
 
6
6
  **Beta version:**
7
- [![new gem version](https://img.shields.io/badge/version-1.1.0%20(new%20beta)-yellowgreen.svg)](http://rubygems.org/gems/sequenceserver) **GitHub Master:** [![build status](https://secure.travis-ci.org/wurmlab/sequenceserver.png)](https://travis-ci.org/wurmlab/sequenceserver)
7
+ [![new gem version](https://img.shields.io/badge/version-2.0%20(beta)-yellowgreen.svg)](http://rubygems.org/gems/sequenceserver) **GitHub Master:** [![build status](https://secure.travis-ci.org/wurmlab/sequenceserver.png)](https://travis-ci.org/wurmlab/sequenceserver)
8
8
 
9
9
 
10
10
 
@@ -39,13 +39,15 @@ use of 'bundler' Ruby gem to install dependencies and to run SequenceServer:
39
39
  # Use bundler command to run SequenceServer
40
40
  bundle exec bin/sequenceserver
41
41
 
42
- If you use SequenceServer, please cite our preprint:
42
+ If you use SequenceServer, please cite:
43
43
 
44
- > [Priyam A, Woodcroft BJ, Rai V, Munagala A, Moghul I, Ter F, Gibbins MA, Moon H, Leonard G, Rumpf W & Wurm Y. 2015. Sequenceserver: A modern graphical user interface for custom BLAST databases. biorxiv doi: 10.1101/033142](http://www.biorxiv.org/content/early/2015/11/27/033142).
44
+ > [Sequenceserver: A modern graphical user interface for custom BLAST
45
+ databases. Molecular Biology and Evolution
46
+ (2019).](https://doi.org/10.1093/molbev/msz185)
45
47
 
46
- ## Version 1.1.0-beta12
48
+ ## Version 2.0 (beta)
47
49
 
48
- This is a beta release of SequenceServer 2.0
50
+ Beta release of SequenceServer version 2.0.
49
51
 
50
52
  Here, we have changed the underlying architecture to persist jobs so that
51
53
  the results can be bookmarked or shared, and to support integration with
@@ -58,15 +60,15 @@ The new beta releases are announced on [Google Group](https://groups.google.com/
58
60
 
59
61
  ### Install and configure
60
62
 
61
- To get the latest 1.1.0-beta release, run:
63
+ To get the latest 2.0 (beta) release, run:
62
64
 
63
65
  gem install --pre sequenceserver
64
66
 
65
67
  If you are new to the above command, please consult the 'Install or update'
66
68
  section on our website http://sequenceserver.com.
67
69
 
68
- If you want to install and use the beta versions from source, the process is
69
- the same as for the old stable release (instructions above).
70
+ If you want to install and use the beta versions from source, the process
71
+ is the same as for the old stable release (instructions above).
70
72
 
71
73
  ### Develop and contribute
72
74
 
@@ -124,7 +126,3 @@ docker run --rm -ti -p 4567:4567 -v $(pwd)/db:/db wurmlab/sequenceserver:1.0.11
124
126
  * Anurag Priyam (architect) - [email](mailto:anurag08priyam@gmail.com) | [@yeban](//twitter.com/yeban)
125
127
  * Yannick Wurm (PI) - [email](mailto:yannickwurm@gmail.com) | [@yannick\_\_](//twitter.com/yannick__)
126
128
  * [Mailing list / forum](https://groups.google.com/forum/#!forum/sequenceserver)
127
-
128
- ## Big Thanks
129
-
130
- Cross-browser Testing Platform and Open Source <3 Provided by [Sauce Labs](https://saucelabs.com)
@@ -1,4 +1,4 @@
1
1
  # Define version number.
2
2
  module SequenceServer
3
- VERSION = '2.0.0.beta1'.freeze
3
+ VERSION = '2.0.0.beta3'.freeze
4
4
  end
data/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "SequenceServer",
3
3
  "description": "BLAST searching made easy!",
4
- "version": "1.1.0-beta",
4
+ "version": "2.0.0-beta",
5
5
  "homepage": "http://www.sequenceserver.com",
6
6
  "repository": "https://github.com/yannickwurm/sequenceserver",
7
7
  "author": {
data/public/js/report.js CHANGED
@@ -112,22 +112,14 @@ var Report = React.createClass({
112
112
  },
113
113
 
114
114
  /**
115
- * Incrementally update state so that the rendering process is
116
- * not overwhelemed when there are too many queries.
115
+ * Incrementally update state (50 queries at a time) so that the rendering
116
+ * process is not overwhelemed when there are too many queries.
117
117
  */
118
118
  updateState: function(responseJSON) {
119
119
  var queries = responseJSON.queries;
120
-
121
- // Render results for first 50 queries and set flag if total queries is
122
- // more than 250.
123
- var numHits = 0;
120
+ responseJSON.num_queries = queries.length;
124
121
  responseJSON.veryBig = queries.length > 250;
125
- //responseJSON.veryBig = !_.every(queries, (query) => {
126
- //numHits += query.hits.length;
127
- //return (numHits <= 500);
128
- //});
129
122
  responseJSON.queries = queries.splice(0, 50);
130
- responseJSON.num_queries = queries.length;
131
123
  this.setState(responseJSON);
132
124
 
133
125
  // Render results for remaining queries.
@@ -306,10 +298,6 @@ var Report = React.createClass({
306
298
  if (this.updateCycle === 1 ) this.affixSidebar();
307
299
  },
308
300
 
309
- /**
310
- * Prevents folding of hits during text-selection, etc.
311
- */
312
-
313
301
  /**
314
302
  * Called after all results have been rendered.
315
303
  */
@@ -926,6 +914,7 @@ var SideBar = React.createClass({
926
914
  }).get();
927
915
  var database_ids = _.map(this.props.data.querydb, _.iteratee('id'));
928
916
  downloadFASTA(sequence_ids, database_ids);
917
+ return false;
929
918
  },
930
919
 
931
920
  /**
@@ -937,6 +926,7 @@ var SideBar = React.createClass({
937
926
  }).get();
938
927
  var database_ids = _.map(this.props.data.querydb, _.iteratee('id'));
939
928
  downloadFASTA(sequence_ids, database_ids);
929
+ return false;
940
930
  },
941
931
 
942
932
  downloadAlignmentOfAll: function() {
@@ -956,6 +946,7 @@ var SideBar = React.createClass({
956
946
  }, this));
957
947
  console.log('len '+hsps_arr.length);
958
948
  aln_exporter.export_alignments(hsps_arr, "alignment-"+sequence_ids.length+"_hits");
949
+ return false;
959
950
  },
960
951
 
961
952
  downloadAlignmentOfSelected: function () {
@@ -977,6 +968,7 @@ var SideBar = React.createClass({
977
968
  });
978
969
  }, this));
979
970
  aln_exporter.export_alignments(hsps_arr, "alignment-"+sequence_ids.length+"_hits");
971
+ return false;
980
972
  },
981
973
 
982
974
 
@@ -1043,29 +1035,28 @@ var SideBar = React.createClass({
1043
1035
  <ul className="nav">
1044
1036
  {
1045
1037
  !this.props.data.imported_xml && <li>
1046
- <a className="download-fasta-of-all"
1038
+ <a href="#" className="btn-link download-fasta-of-all"
1047
1039
  onClick={this.downloadFastaOfAll}>
1048
1040
  FASTA of all hits
1049
1041
  </a>
1050
1042
  </li>
1051
1043
  }
1052
1044
  {
1053
- !this.props.data.imported_xml && <li>
1054
- <a
1055
- className="download-fasta-of-selected disabled"
1056
- onClick={this.downloadFastaOfSelected}>
1057
- FASTA of <span className="text-bold"></span> selected hit(s)
1058
- </a>
1059
- </li>
1045
+ !this.props.data.imported_xml && <li>
1046
+ <a href="#" className="btn-link download-fasta-of-selected disabled"
1047
+ onClick={this.downloadFastaOfSelected}>
1048
+ FASTA of <span className="text-bold"></span> selected hit(s)
1049
+ </a>
1050
+ </li>
1060
1051
  }
1061
1052
  <li>
1062
- <a className="download-alignment-of-all"
1053
+ <a href="#" className="btn-link download-alignment-of-all"
1063
1054
  onClick={this.downloadAlignmentOfAll}>
1064
1055
  Alignment of all hits
1065
1056
  </a>
1066
1057
  </li>
1067
1058
  <li>
1068
- <a className="download-alignment-of-selected disabled"
1059
+ <a href="#" className="btn-link download-alignment-of-selected disabled"
1069
1060
  onClick={this.downloadAlignmentOfSelected}>
1070
1061
  Alignment of <span className="text-bold"></span> selected hit(s)
1071
1062
  </a>
@@ -15,5 +15,5 @@ g[d]=b(a[d],d,a);return g},u.pairs=function(a){for(var b=u.keys(a),c=b.length,d=
15
15
  c&&(b=c.call(this,a)),l.asap(d,this);var e=this.props.name;if("radio"===this.props.type&&null!=e){for(var f=this.getDOMNode(),h=f;h.parentNode;)h=h.parentNode;for(var i=h.querySelectorAll("input[name="+JSON.stringify(""+e)+'][type="radio"]'),j=0,m=i.length;j<m;j++){var o=i[j];if(o!==f&&o.form===f.form){var q=k.getID(o);n(q);var r=p[q];n(r),l.asap(d,r)}}}return b}});c.exports=q}(a("49"))}),c.registerDynamic("79",["6b","6c","4c","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("6b"),e=a("6c"),f=a("4c"),g=(a("48"),f.createFactory("option")),h=e.createClass({displayName:"ReactDOMOption",tagName:"OPTION",mixins:[d],componentWillMount:function(){},render:function(){return g(this.props,this.props.children)}});c.exports=h}(a("49"))}),c.registerDynamic("7a",["6a","78","6b","6c","4c","5b","4f"],!0,function(a,b,c){"use strict";function d(){if(this._pendingUpdate){this._pendingUpdate=!1;var a=h.getValue(this);null!=a&&this.isMounted()&&f(this,a)}}function e(a,b,c){if(null==a[b])return null;if(a.multiple){if(!Array.isArray(a[b]))return new Error("The `"+b+"` prop supplied to <select> must be an array if `multiple` is true.")}else if(Array.isArray(a[b]))return new Error("The `"+b+"` prop supplied to <select> must be a scalar value if `multiple` is false.")}function f(a,b){var c,d,e,f=a.getDOMNode().options;if(a.props.multiple){for(c={},d=0,e=b.length;d<e;d++)c[""+b[d]]=!0;for(d=0,e=f.length;d<e;d++){var g=c.hasOwnProperty(f[d].value);f[d].selected!==g&&(f[d].selected=g)}}else{for(c=""+b,d=0,e=f.length;d<e;d++)if(f[d].value===c)return void(f[d].selected=!0);f.length&&(f[0].selected=!0)}}var g=(this||self,a("6a")),h=a("78"),i=a("6b"),j=a("6c"),k=a("4c"),l=a("5b"),m=a("4f"),n=k.createFactory("select"),o=j.createClass({displayName:"ReactDOMSelect",tagName:"SELECT",mixins:[g,h.Mixin,i],propTypes:{defaultValue:e,value:e},render:function(){var a=m({},this.props);return a.onChange=this._handleChange,a.value=null,n(a,this.props.children)},componentWillMount:function(){this._pendingUpdate=!1},componentDidMount:function(){var a=h.getValue(this);null!=a?f(this,a):null!=this.props.defaultValue&&f(this,this.props.defaultValue)},componentDidUpdate:function(a){var b=h.getValue(this);null!=b?(this._pendingUpdate=!1,f(this,b)):!a.multiple!=!this.props.multiple&&(null!=this.props.defaultValue?f(this,this.props.defaultValue):f(this,this.props.multiple?[]:""))},_handleChange:function(a){var b,c=h.getOnChange(this);return c&&(b=c.call(this,a)),this._pendingUpdate=!0,l.asap(d,this),b}});c.exports=o}),c.registerDynamic("6a",["7b"],!0,function(a,b,c){"use strict";var d=(this||self,a("7b")),e={componentDidMount:function(){this.props.autoFocus&&d(this.getDOMNode())}};c.exports=e}),c.registerDynamic("78",["7c","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){j(null==a.props.checkedLink||null==a.props.valueLink)}function e(a){d(a),j(null==a.props.value&&null==a.props.onChange)}function f(a){d(a),j(null==a.props.checked&&null==a.props.onChange)}function g(a){this.props.valueLink.requestChange(a.target.value)}function h(a){this.props.checkedLink.requestChange(a.target.checked)}var i=a("7c"),j=a("74"),k={button:!0,checkbox:!0,image:!0,hidden:!0,radio:!0,reset:!0,submit:!0},l={Mixin:{propTypes:{value:function(a,b,c){return!a[b]||k[a.type]||a.onChange||a.readOnly||a.disabled?null:new Error("You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set either `onChange` or `readOnly`.")},checked:function(a,b,c){return!a[b]||a.onChange||a.readOnly||a.disabled?null:new Error("You provided a `checked` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultChecked`. Otherwise, set either `onChange` or `readOnly`.")},onChange:i.func}},getValue:function(a){return a.props.valueLink?(e(a),a.props.valueLink.value):a.props.value},getChecked:function(a){return a.props.checkedLink?(f(a),a.props.checkedLink.value):a.props.checked},getOnChange:function(a){return a.props.valueLink?(e(a),g):a.props.checkedLink?(f(a),h):a.props.onChange}};c.exports=l}(a("49"))}),c.registerDynamic("6b",["7d"],!0,function(a,b,c){"use strict";var d=(this||self,a("7d")),e={getDOMNode:function(){return d(this)}};c.exports=e}),c.registerDynamic("7e",["6a","77","78","6b","6c","4c","5b","4f","74","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(){this.isMounted()&&this.forceUpdate()}var e=a("6a"),f=a("77"),g=a("78"),h=a("6b"),i=a("6c"),j=a("4c"),k=a("5b"),l=a("4f"),m=a("74"),n=(a("48"),j.createFactory("textarea")),o=i.createClass({displayName:"ReactDOMTextarea",tagName:"TEXTAREA",mixins:[e,g.Mixin,h],getInitialState:function(){var a=this.props.defaultValue,b=this.props.children;null!=b&&(m(null==a),Array.isArray(b)&&(m(b.length<=1),b=b[0]),a=""+b),null==a&&(a="");var c=g.getValue(this);return{initialValue:""+(null!=c?c:a)}},render:function(){var a=l({},this.props);return m(null==a.dangerouslySetInnerHTML),a.defaultValue=null,a.value=null,a.onChange=this._handleChange,n(a,this.state.initialValue)},componentDidUpdate:function(a,b,c){var d=g.getValue(this);if(null!=d){var e=this.getDOMNode();f.setValueForProperty(e,"value",""+d)}},_handleChange:function(a){var b,c=g.getOnChange(this);return c&&(b=c.call(this,a)),k.asap(d,this),b}});c.exports=o}(a("49"))}),c.registerDynamic("7f",["77","80","81","4f","82"],!0,function(a,b,c){"use strict";var d=(this||self,a("77")),e=a("80"),f=a("81"),g=a("4f"),h=a("82"),i=function(a){};g(i.prototype,{construct:function(a){this._currentElement=a,this._stringText=""+a,this._rootNodeID=null,this._mountIndex=0},mountComponent:function(a,b,c){this._rootNodeID=a;var e=h(this._stringText);return b.renderToStaticMarkup?e:"<span "+d.createMarkupForID(a)+">"+e+"</span>"},receiveComponent:function(a,b){if(a!==this._currentElement){this._currentElement=a;var c=""+a;c!==this._stringText&&(this._stringText=c,f.BackendIDOperations.updateTextContentByID(this._rootNodeID,c))}},unmountComponent:function(){e.unmountIDFromEnvironment(this._rootNodeID)}}),c.exports=i}),c.registerDynamic("83",["66","49"],!0,function(a,b,c){this||self;!function(b){var d=a("66"),e={listen:function(a,b,c){return a.addEventListener?(a.addEventListener(b,c,!1),{remove:function(){a.removeEventListener(b,c,!1)}}):a.attachEvent?(a.attachEvent("on"+b,c),{remove:function(){a.detachEvent("on"+b,c)}}):void 0},capture:function(a,b,c){return a.addEventListener?(a.addEventListener(b,c,!0),{remove:function(){a.removeEventListener(b,c,!0)}}):{remove:d}},registerDefault:function(){}};c.exports=e}(a("49"))}),c.registerDynamic("84",[],!0,function(a,b,c){"use strict";function d(a){return a===window?{x:window.pageXOffset||document.documentElement.scrollLeft,y:window.pageYOffset||document.documentElement.scrollTop}:{x:a.scrollLeft,y:a.scrollTop}}this||self;c.exports=d}),c.registerDynamic("85",["83","57","45","86","62","5b","4f","87","84","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){var b=l.getID(a),c=k.getReactRootIDFromNodeID(b),d=l.findReactContainerForID(c),e=l.getFirstReactDOM(d);return e}function e(a,b){this.topLevelType=a,this.nativeEvent=b,this.ancestors=[]}function f(a){for(var b=l.getFirstReactDOM(o(a.nativeEvent))||window,c=b;c;)a.ancestors.push(c),c=d(c);for(var e=0,f=a.ancestors.length;e<f;e++){b=a.ancestors[e];var g=l.getID(b)||"";q._handleTopLevel(a.topLevelType,b,g,a.nativeEvent)}}function g(a){var b=p(window);a(b)}var h=a("83"),i=a("57"),j=a("45"),k=a("86"),l=a("62"),m=a("5b"),n=a("4f"),o=a("87"),p=a("84");n(e.prototype,{destructor:function(){this.topLevelType=null,this.nativeEvent=null,this.ancestors.length=0}}),j.addPoolingTo(e,j.twoArgumentPooler);var q={_enabled:!0,_handleTopLevel:null,WINDOW_HANDLE:i.canUseDOM?window:null,setHandleTopLevel:function(a){q._handleTopLevel=a},setEnabled:function(a){q._enabled=!!a},isEnabled:function(){return q._enabled},trapBubbledEvent:function(a,b,c){var d=c;return d?h.listen(d,b,q.dispatchEvent.bind(null,a)):null},trapCapturedEvent:function(a,b,c){var d=c;return d?h.capture(d,b,q.dispatchEvent.bind(null,a)):null},monitorScrollValue:function(a){var b=g.bind(null,a);h.listen(window,"scroll",b)},dispatchEvent:function(a,b){if(q._enabled){var c=e.getPooled(a,b);try{m.batchedUpdates(f,c)}finally{e.release(c)}}}};c.exports=q}(a("49"))}),c.registerDynamic("88",[],!0,function(a,b,c){function d(a){return a.replace(e,function(a,b){return b.toUpperCase()})}var e=(this||self,/-(.)/g);c.exports=d}),c.registerDynamic("89",["88"],!0,function(a,b,c){"use strict";function d(a){return e(a.replace(f,"ms-"))}var e=(this||self,a("88")),f=/^-ms-/;c.exports=d}),c.registerDynamic("8a",[],!0,function(a,b,c){"use strict";function d(a,b){return a+b.charAt(0).toUpperCase()+b.substring(1)}var e=(this||self,{boxFlex:!0,boxFlexGroup:!0,columnCount:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,strokeDashoffset:!0,strokeOpacity:!0,strokeWidth:!0}),f=["Webkit","ms","Moz","O"];Object.keys(e).forEach(function(a){f.forEach(function(b){e[d(b,a)]=e[a]})});var g={background:{backgroundImage:!0,backgroundPosition:!0,backgroundRepeat:!0,backgroundColor:!0},border:{borderWidth:!0,borderStyle:!0,borderColor:!0},borderBottom:{borderBottomWidth:!0,borderBottomStyle:!0,borderBottomColor:!0},borderLeft:{borderLeftWidth:!0,borderLeftStyle:!0,borderLeftColor:!0},borderRight:{borderRightWidth:!0,borderRightStyle:!0,borderRightColor:!0},borderTop:{borderTopWidth:!0,borderTopStyle:!0,borderTopColor:!0},font:{fontStyle:!0,fontVariant:!0,fontWeight:!0,fontSize:!0,lineHeight:!0,fontFamily:!0}},h={isUnitlessNumber:e,shorthandPropertyExpansions:g};c.exports=h}),c.registerDynamic("8b",["8a"],!0,function(a,b,c){"use strict";function d(a,b){var c=null==b||"boolean"==typeof b||""===b;if(c)return"";var d=isNaN(b);return d||0===b||f.hasOwnProperty(a)&&f[a]?""+b:("string"==typeof b&&(b=b.trim()),b+"px")}var e=(this||self,a("8a")),f=e.isUnitlessNumber;c.exports=d}),c.registerDynamic("8c",[],!0,function(a,b,c){function d(a){return a.replace(e,"-$1").toLowerCase()}var e=(this||self,/([A-Z])/g);c.exports=d}),c.registerDynamic("8d",["8c"],!0,function(a,b,c){"use strict";function d(a){return e(a).replace(f,"-ms-")}var e=(this||self,a("8c")),f=/^ms-/;c.exports=d}),c.registerDynamic("8e",[],!0,function(a,b,c){"use strict";function d(a){var b={};return function(c){return b.hasOwnProperty(c)||(b[c]=a.call(this,c)),b[c]}}this||self;c.exports=d}),c.registerDynamic("8f",["8a","57","89","8b","8d","8e","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("8a"),e=a("57"),f=(a("89"),a("8b")),g=a("8d"),h=a("8e"),i=(a("48"),h(function(a){return g(a)})),j="cssFloat";e.canUseDOM&&void 0===document.documentElement.style.cssFloat&&(j="styleFloat");var k={createMarkupForStyles:function(a){var b="";for(var c in a)if(a.hasOwnProperty(c)){var d=a[c];null!=d&&(b+=i(c)+":",b+=f(c,d)+";")}return b||null},setValueForStyles:function(a,b){var c=a.style;for(var e in b)if(b.hasOwnProperty(e)){var g=f(e,b[e]);if("float"===e&&(e=j),g)c[e]=g;else{var h=d.shorthandPropertyExpansions[e];if(h)for(var i in h)c[i]="";else c[e]=""}}}};c.exports=k}(a("49"))}),c.registerDynamic("90",["74","49"],!0,function(a,b,c){this||self;!function(b){function d(a){var b=a.length;if(e(!Array.isArray(a)&&("object"==typeof a||"function"==typeof a)),e("number"==typeof b),e(0===b||b-1 in a),a.hasOwnProperty)try{return Array.prototype.slice.call(a)}catch(a){}for(var c=Array(b),d=0;d<b;d++)c[d]=a[d];return c}var e=a("74");c.exports=d}(a("49"))}),c.registerDynamic("91",["90"],!0,function(a,b,c){function d(a){return!!a&&("object"==typeof a||"function"==typeof a)&&"length"in a&&!("setInterval"in a)&&"number"!=typeof a.nodeType&&(Array.isArray(a)||"callee"in a||"item"in a)}function e(a){return d(a)?Array.isArray(a)?a.slice():f(a):[a]}var f=(this||self,a("90"));c.exports=e}),c.registerDynamic("92",["57","91","93","74","49"],!0,function(a,b,c){this||self;!function(b){function d(a){var b=a.match(k);return b&&b[1].toLowerCase()}function e(a,b){var c=j;i(!!j);var e=d(a),f=e&&h(e);if(f){c.innerHTML=f[1]+a+f[2];for(var k=f[0];k--;)c=c.lastChild}else c.innerHTML=a;var l=c.getElementsByTagName("script");l.length&&(i(b),g(l).forEach(b));for(var m=g(c.childNodes);c.lastChild;)c.removeChild(c.lastChild);return m}var f=a("57"),g=a("91"),h=a("93"),i=a("74"),j=f.canUseDOM?document.createElement("div"):null,k=/^\s*<(\w+)/;c.exports=e}(a("49"))}),c.registerDynamic("93",["57","74","49"],!0,function(a,b,c){this||self;!function(b){function d(a){return f(!!g),m.hasOwnProperty(a)||(a="*"),h.hasOwnProperty(a)||("*"===a?g.innerHTML="<link />":g.innerHTML="<"+a+"></"+a+">",h[a]=!g.firstChild),h[a]?m[a]:null}var e=a("57"),f=a("74"),g=e.canUseDOM?document.createElement("div"):null,h={circle:!0,clipPath:!0,defs:!0,ellipse:!0,g:!0,line:!0,linearGradient:!0,path:!0,polygon:!0,polyline:!0,radialGradient:!0,rect:!0,stop:!0,text:!0},i=[1,'<select multiple="true">',"</select>"],j=[1,"<table>","</table>"],k=[3,"<table><tbody><tr>","</tr></tbody></table>"],l=[1,"<svg>","</svg>"],m={"*":[1,"?<div>","</div>"],area:[1,"<map>","</map>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],legend:[1,"<fieldset>","</fieldset>"],param:[1,"<object>","</object>"],tr:[2,"<table><tbody>","</tbody></table>"],optgroup:i,option:i,caption:j,colgroup:j,tbody:j,tfoot:j,thead:j,td:k,th:k,circle:l,clipPath:l,defs:l,ellipse:l,g:l,line:l,linearGradient:l,path:l,polygon:l,polyline:l,radialGradient:l,rect:l,stop:l,text:l};c.exports=d}(a("49"))}),c.registerDynamic("94",["57","92","66","93","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){return a.substring(1,a.indexOf(" "))}var e=a("57"),f=a("92"),g=a("66"),h=a("93"),i=a("74"),j=/^(<[^ \/>]+)/,k="data-danger-index",l={dangerouslyRenderMarkup:function(a){i(e.canUseDOM);for(var b,c={},l=0;l<a.length;l++)i(a[l]),b=d(a[l]),b=h(b)?b:"*",c[b]=c[b]||[],c[b][l]=a[l];var m=[],n=0;for(b in c)if(c.hasOwnProperty(b)){var o,p=c[b];for(o in p)if(p.hasOwnProperty(o)){var q=p[o];p[o]=q.replace(j,"$1 "+k+'="'+o+'" ')}for(var r=f(p.join(""),g),s=0;s<r.length;++s){var t=r[s];t.hasAttribute&&t.hasAttribute(k)&&(o=+t.getAttribute(k),t.removeAttribute(k),i(!m.hasOwnProperty(o)),m[o]=t,n+=1)}}return i(n===m.length),i(m.length===a.length),m},dangerouslyReplaceNodeWithMarkup:function(a,b){i(e.canUseDOM),i(b),i("html"!==a.tagName.toLowerCase());var c=f(b,g)[0];a.parentNode.replaceChild(c,a)}};c.exports=l}(a("49"))}),c.registerDynamic("95",["57","82","96"],!0,function(a,b,c){"use strict";var d=(this||self,a("57")),e=a("82"),f=a("96"),g=function(a,b){a.textContent=b};d.canUseDOM&&("textContent"in document.documentElement||(g=function(a,b){f(a,e(b))})),c.exports=g}),c.registerDynamic("97",["94","98","95","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b,c){a.insertBefore(b,a.childNodes[c]||null)}var e=a("94"),f=a("98"),g=a("95"),h=a("74"),i={dangerouslyReplaceNodeWithMarkup:e.dangerouslyReplaceNodeWithMarkup,updateTextContent:g,processUpdates:function(a,b){for(var c,i=null,j=null,k=0;k<a.length;k++)if(c=a[k],c.type===f.MOVE_EXISTING||c.type===f.REMOVE_NODE){var l=c.fromIndex,m=c.parentNode.childNodes[l],n=c.parentID;h(m),i=i||{},i[n]=i[n]||[],i[n][l]=m,j=j||[],j.push(m)}var o=e.dangerouslyRenderMarkup(b);if(j)for(var p=0;p<j.length;p++)j[p].parentNode.removeChild(j[p]);for(var q=0;q<a.length;q++)switch(c=a[q],c.type){case f.INSERT_MARKUP:d(c.parentNode,o[c.markupIndex],c.toIndex);break;case f.MOVE_EXISTING:d(c.parentNode,i[c.parentID][c.fromIndex],c.toIndex);break;case f.TEXT_CONTENT:g(c.parentNode,c.textContent);break;case f.REMOVE_NODE:}}};c.exports=i}(a("49"))}),c.registerDynamic("99",["82"],!0,function(a,b,c){"use strict";function d(a){return'"'+e(a)+'"'}var e=(this||self,a("82"));c.exports=d}),c.registerDynamic("77",["64","99","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b){return null==b||e.hasBooleanValue[a]&&!b||e.hasNumericValue[a]&&isNaN(b)||e.hasPositiveNumericValue[a]&&b<1||e.hasOverloadedBooleanValue[a]&&b===!1}var e=a("64"),f=a("99"),g=(a("48"),{createMarkupForID:function(a){return e.ID_ATTRIBUTE_NAME+"="+f(a)},createMarkupForProperty:function(a,b){if(e.isStandardName.hasOwnProperty(a)&&e.isStandardName[a]){if(d(a,b))return"";var c=e.getAttributeName[a];return e.hasBooleanValue[a]||e.hasOverloadedBooleanValue[a]&&b===!0?c:c+"="+f(b)}return e.isCustomAttribute(a)?null==b?"":a+"="+f(b):null},setValueForProperty:function(a,b,c){if(e.isStandardName.hasOwnProperty(b)&&e.isStandardName[b]){var f=e.getMutationMethod[b];if(f)f(a,c);else if(d(b,c))this.deleteValueForProperty(a,b);else if(e.mustUseAttribute[b])a.setAttribute(e.getAttributeName[b],""+c);else{var g=e.getPropertyName[b];e.hasSideEffects[b]&&""+a[g]==""+c||(a[g]=c)}}else e.isCustomAttribute(b)&&(null==c?a.removeAttribute(b):a.setAttribute(b,""+c))},deleteValueForProperty:function(a,b){if(e.isStandardName.hasOwnProperty(b)&&e.isStandardName[b]){var c=e.getMutationMethod[b];if(c)c(a,void 0);else if(e.mustUseAttribute[b])a.removeAttribute(e.getAttributeName[b]);else{var d=e.getPropertyName[b],f=e.getDefaultValueForProperty(a.nodeName,d);e.hasSideEffects[b]&&""+a[d]===f||(a[d]=f)}}else e.isCustomAttribute(b)&&a.removeAttribute(b)}});c.exports=g}(a("49"))}),c.registerDynamic("9a",["8f","97","77","62","9b","74","96","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("8f"),e=a("97"),f=a("77"),g=a("62"),h=a("9b"),i=a("74"),j=a("96"),k={dangerouslySetInnerHTML:"`dangerouslySetInnerHTML` must be set using `updateInnerHTMLByID()`.",style:"`style` must be set using `updateStylesByID()`."},l={updatePropertyByID:function(a,b,c){var d=g.getNode(a);i(!k.hasOwnProperty(b)),null!=c?f.setValueForProperty(d,b,c):f.deleteValueForProperty(d,b)},deletePropertyByID:function(a,b,c){var d=g.getNode(a);i(!k.hasOwnProperty(b)),f.deleteValueForProperty(d,b,c)},updateStylesByID:function(a,b){var c=g.getNode(a);d.setValueForStyles(c,b)},updateInnerHTMLByID:function(a,b){var c=g.getNode(a);j(c,b)},updateTextContentByID:function(a,b){var c=g.getNode(a);e.updateTextContent(c,b)},dangerouslyReplaceNodeWithMarkupByID:function(a,b){var c=g.getNode(a);e.dangerouslyReplaceNodeWithMarkup(c,b)},dangerouslyProcessChildrenUpdates:function(a,b){for(var c=0;c<a.length;c++)a[c].parentNode=g.getNode(a[c].parentID);e.processUpdates(a,b)}};h.measureMethods(l,"ReactDOMIDOperations",{updatePropertyByID:"updatePropertyByID",deletePropertyByID:"deletePropertyByID",updateStylesByID:"updateStylesByID",updateInnerHTMLByID:"updateInnerHTMLByID",updateTextContentByID:"updateTextContentByID",dangerouslyReplaceNodeWithMarkupByID:"dangerouslyReplaceNodeWithMarkupByID",dangerouslyProcessChildrenUpdates:"dangerouslyProcessChildrenUpdates"}),c.exports=l}(a("49"))}),c.registerDynamic("80",["9a","62","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("9a"),e=a("62"),f={processChildrenUpdates:d.dangerouslyProcessChildrenUpdates,replaceNodeWithMarkupByID:d.dangerouslyReplaceNodeWithMarkupByID,unmountIDFromEnvironment:function(a){e.purgeID(a)}};c.exports=f}(a("49"))}),c.registerDynamic("98",["6d"],!0,function(a,b,c){"use strict";var d=(this||self,a("6d")),e=d({INSERT_MARKUP:null,MOVE_EXISTING:null,REMOVE_NODE:null,TEXT_CONTENT:null});c.exports=e}),c.registerDynamic("47",["4c","46","86","9c","74","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){return q[a]}function e(a,b){return a&&null!=a.key?g(a.key):b.toString(36)}function f(a){return(""+a).replace(r,d)}function g(a){return"$"+f(a)}function h(a,b,c,d,f){var i=typeof a;if("undefined"!==i&&"boolean"!==i||(a=null),null===a||"string"===i||"number"===i||j.isValidElement(a))return d(f,a,""===b?o+e(a,0):b,c),1;var l,q,r,s=0;if(Array.isArray(a))for(var t=0;t<a.length;t++)l=a[t],q=(""!==b?b+p:o)+e(l,t),r=c+s,s+=h(l,q,r,d,f);else{var u=m(a);if(u){var v,w=u.call(a);if(u!==a.entries)for(var x=0;!(v=w.next()).done;)l=v.value,q=(""!==b?b+p:o)+e(l,x++),r=c+s,s+=h(l,q,r,d,f);else for(;!(v=w.next()).done;){var y=v.value;y&&(l=y[1],q=(""!==b?b+p:o)+g(y[0])+p+e(l,0),r=c+s,s+=h(l,q,r,d,f))}}else if("object"===i){n(1!==a.nodeType);var z=k.extract(a);for(var A in z)z.hasOwnProperty(A)&&(l=z[A],q=(""!==b?b+p:o)+g(A)+p+e(l,0),r=c+s,s+=h(l,q,r,d,f))}}return s}function i(a,b,c){return null==a?0:h(a,"",0,b,c)}var j=a("4c"),k=a("46"),l=a("86"),m=a("9c"),n=a("74"),o=(a("48"),l.SEPARATOR),p=":",q={"=":"=0",".":"=1",":":"=2"},r=/[=.:]/g;c.exports=i}(a("49"))}),c.registerDynamic("9d",["47","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b,c){var d=a,e=!d.hasOwnProperty(c);e&&null!=b&&(d[c]=b)}function e(a){if(null==a)return a;var b={};return f(a,d,b),b}var f=a("47");a("48");c.exports=e}(a("49"))}),c.registerDynamic("9e",["9f","9d","a0","a1"],!0,function(a,b,c){"use strict";var d=(this||self,a("9f")),e=a("9d"),f=a("a0"),g=a("a1"),h={instantiateChildren:function(a,b,c){var d=e(a);for(var g in d)if(d.hasOwnProperty(g)){var h=d[g],i=f(h,null);d[g]=i}return d},updateChildren:function(a,b,c,h){var i=e(b);if(!i&&!a)return null;var j;for(j in i)if(i.hasOwnProperty(j)){var k=a&&a[j],l=k&&k._currentElement,m=i[j];if(g(l,m))d.receiveComponent(k,m,c,h),i[j]=k;else{k&&d.unmountComponent(k,j);var n=f(m,null);i[j]=n}}for(j in a)!a.hasOwnProperty(j)||i&&i.hasOwnProperty(j)||d.unmountComponent(a[j]);return i},unmountChildren:function(a){for(var b in a){var c=a[b];d.unmountComponent(c)}}};c.exports=h}),c.registerDynamic("a2",["a3","98","9f","9e","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b,c){o.push({parentID:a,parentNode:null,type:k.INSERT_MARKUP,markupIndex:p.push(b)-1,textContent:null,fromIndex:null,toIndex:c})}function e(a,b,c){o.push({parentID:a,parentNode:null,type:k.MOVE_EXISTING,markupIndex:null,textContent:null,fromIndex:b,toIndex:c})}function f(a,b){o.push({parentID:a,parentNode:null,type:k.REMOVE_NODE,markupIndex:null,textContent:null,fromIndex:b,toIndex:null})}function g(a,b){o.push({parentID:a,parentNode:null,type:k.TEXT_CONTENT,markupIndex:null,textContent:b,fromIndex:null,toIndex:null})}function h(){o.length&&(j.processChildrenUpdates(o,p),i())}function i(){o.length=0,p.length=0}var j=a("a3"),k=a("98"),l=a("9f"),m=a("9e"),n=0,o=[],p=[],q={Mixin:{mountChildren:function(a,b,c){var d=m.instantiateChildren(a,b,c);this._renderedChildren=d;var e=[],f=0;for(var g in d)if(d.hasOwnProperty(g)){var h=d[g],i=this._rootNodeID+g,j=l.mountComponent(h,i,b,c);h._mountIndex=f,e.push(j),f++}return e},updateTextContent:function(a){n++;var b=!0;try{var c=this._renderedChildren;m.unmountChildren(c);for(var d in c)c.hasOwnProperty(d)&&this._unmountChildByName(c[d],d);this.setTextContent(a),b=!1}finally{n--,n||(b?i():h())}},updateChildren:function(a,b,c){n++;var d=!0;try{this._updateChildren(a,b,c),d=!1}finally{n--,n||(d?i():h())}},_updateChildren:function(a,b,c){var d=this._renderedChildren,e=m.updateChildren(d,a,b,c);if(this._renderedChildren=e,e||d){var f,g=0,h=0;for(f in e)if(e.hasOwnProperty(f)){var i=d&&d[f],j=e[f];i===j?(this.moveChild(i,h,g),g=Math.max(i._mountIndex,g),i._mountIndex=h):(i&&(g=Math.max(i._mountIndex,g),this._unmountChildByName(i,f)),this._mountChildByNameAtIndex(j,f,h,b,c)),h++}for(f in d)!d.hasOwnProperty(f)||e&&e.hasOwnProperty(f)||this._unmountChildByName(d[f],f)}},unmountChildren:function(){var a=this._renderedChildren;m.unmountChildren(a),this._renderedChildren=null},moveChild:function(a,b,c){a._mountIndex<c&&e(this._rootNodeID,a._mountIndex,b)},createChild:function(a,b){d(this._rootNodeID,b,a._mountIndex)},removeChild:function(a){f(this._rootNodeID,a._mountIndex)},setTextContent:function(a){g(this._rootNodeID,a)},_mountChildByNameAtIndex:function(a,b,c,d,e){var f=this._rootNodeID+b,g=l.mountComponent(a,f,d,e);a._mountIndex=c,this.createChild(a,g)},_unmountChildByName:function(a,b){this.removeChild(a),a._mountIndex=null}}};c.exports=q}(a("49"))}),c.registerDynamic("82",[],!0,function(a,b,c){"use strict";function d(a){return f[a]}function e(a){return(""+a).replace(g,d)}var f=(this||self,{"&":"&amp;",">":"&gt;","<":"&lt;",'"':"&quot;","'":"&#x27;"}),g=/[&><"']/g;c.exports=e}),c.registerDynamic("81",["8f","64","77","71","80","62","a2","9b","4f","82","74","5c","58","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){a&&(null!=a.dangerouslySetInnerHTML&&(r(null==a.children),r("object"==typeof a.dangerouslySetInnerHTML&&"__html"in a.dangerouslySetInnerHTML)),r(null==a.style||"object"==typeof a.style))}function e(a,b,c,d){var e=m.findReactContainerForID(a);if(e){var f=e.nodeType===y?e.ownerDocument:e;u(b,f)}d.getPutListenerQueue().enqueuePutListener(a,b,c)}function f(a){D.call(C,a)||(r(B.test(a)),C[a]=!0)}function g(a){f(a),this._tag=a,this._renderedChildren=null,this._previousStyleCopy=null,this._rootNodeID=null}var h=a("8f"),i=a("64"),j=a("77"),k=a("71"),l=a("80"),m=a("62"),n=a("a2"),o=a("9b"),p=a("4f"),q=a("82"),r=a("74"),s=(a("5c"),a("58")),t=(a("48"),k.deleteListener),u=k.listenTo,v=k.registrationNameModules,w={string:!0,number:!0},x=s({style:null}),y=1,z=null,A={area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0},B=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,C={},D={}.hasOwnProperty;g.displayName="ReactDOMComponent",g.Mixin={construct:function(a){this._currentElement=a},mountComponent:function(a,b,c){this._rootNodeID=a,d(this._currentElement.props);var e=A[this._tag]?"":"</"+this._tag+">";return this._createOpenTagMarkupAndPutListeners(b)+this._createContentMarkup(b,c)+e},_createOpenTagMarkupAndPutListeners:function(a){var b=this._currentElement.props,c="<"+this._tag;for(var d in b)if(b.hasOwnProperty(d)){var f=b[d];if(null!=f)if(v.hasOwnProperty(d))e(this._rootNodeID,d,f,a);else{d===x&&(f&&(f=this._previousStyleCopy=p({},b.style)),f=h.createMarkupForStyles(f));var g=j.createMarkupForProperty(d,f);g&&(c+=" "+g)}}if(a.renderToStaticMarkup)return c+">";var i=j.createMarkupForID(this._rootNodeID);return c+" "+i+">"},_createContentMarkup:function(a,b){var c="";"listing"!==this._tag&&"pre"!==this._tag&&"textarea"!==this._tag||(c="\n");var d=this._currentElement.props,e=d.dangerouslySetInnerHTML;if(null!=e){if(null!=e.__html)return c+e.__html}else{var f=w[typeof d.children]?d.children:null,g=null!=f?null:d.children;if(null!=f)return c+q(f);if(null!=g){var h=this.mountChildren(g,a,b);return c+h.join("")}}return c},receiveComponent:function(a,b,c){var d=this._currentElement;this._currentElement=a,this.updateComponent(b,d,a,c)},updateComponent:function(a,b,c,e){d(this._currentElement.props),this._updateDOMProperties(b.props,a),this._updateDOMChildren(b.props,a,e)},_updateDOMProperties:function(a,b){var c,d,f,g=this._currentElement.props;for(c in a)if(!g.hasOwnProperty(c)&&a.hasOwnProperty(c))if(c===x){var h=this._previousStyleCopy;for(d in h)h.hasOwnProperty(d)&&(f=f||{},f[d]="");this._previousStyleCopy=null}else v.hasOwnProperty(c)?t(this._rootNodeID,c):(i.isStandardName[c]||i.isCustomAttribute(c))&&z.deletePropertyByID(this._rootNodeID,c);for(c in g){var j=g[c],k=c===x?this._previousStyleCopy:a[c];if(g.hasOwnProperty(c)&&j!==k)if(c===x)if(j?j=this._previousStyleCopy=p({},j):this._previousStyleCopy=null,k){for(d in k)!k.hasOwnProperty(d)||j&&j.hasOwnProperty(d)||(f=f||{},f[d]="");for(d in j)j.hasOwnProperty(d)&&k[d]!==j[d]&&(f=f||{},f[d]=j[d])}else f=j;else v.hasOwnProperty(c)?e(this._rootNodeID,c,j,b):(i.isStandardName[c]||i.isCustomAttribute(c))&&z.updatePropertyByID(this._rootNodeID,c,j)}f&&z.updateStylesByID(this._rootNodeID,f)},_updateDOMChildren:function(a,b,c){var d=this._currentElement.props,e=w[typeof a.children]?a.children:null,f=w[typeof d.children]?d.children:null,g=a.dangerouslySetInnerHTML&&a.dangerouslySetInnerHTML.__html,h=d.dangerouslySetInnerHTML&&d.dangerouslySetInnerHTML.__html,i=null!=e?null:a.children,j=null!=f?null:d.children,k=null!=e||null!=g,l=null!=f||null!=h;null!=i&&null==j?this.updateChildren(null,b,c):k&&!l&&this.updateTextContent(""),null!=f?e!==f&&this.updateTextContent(""+f):null!=h?g!==h&&z.updateInnerHTMLByID(this._rootNodeID,h):null!=j&&this.updateChildren(j,b,c)},unmountComponent:function(){this.unmountChildren(),k.deleteAllListeners(this._rootNodeID),l.unmountIDFromEnvironment(this._rootNodeID),this._rootNodeID=null}},o.measureMethods(g,"ReactDOMComponent",{mountComponent:"mountComponent",updateComponent:"updateComponent"}),p(g.prototype,g.Mixin,n.Mixin),g.injection={injectIDOperations:function(a){g.BackendIDOperations=z=a}},c.exports=g}(a("49"))}),c.registerDynamic("a4",["64","5a","a3","6c","a5","71","a6","81","9b","a7","5b"],!0,function(a,b,c){"use strict";var d=(this||self,a("64")),e=a("5a"),f=a("a3"),g=a("6c"),h=a("a5"),i=a("71"),j=a("a6"),k=a("81"),l=a("9b"),m=a("a7"),n=a("5b"),o={Component:f.injection,Class:g.injection,DOMComponent:k.injection,DOMProperty:d.injection,EmptyComponent:h.injection,EventPluginHub:e.injection,EventEmitter:i.injection,NativeComponent:j.injection,Perf:l.injection,RootIndex:m.injection,Updates:n.injection};c.exports=o}),c.registerDynamic("a8",["a9","45","71","aa","ab","68","4f"],!0,function(a,b,c){"use strict";function d(){this.reinitializeTransaction(),this.renderToStaticMarkup=!1,this.reactMountReady=e.getPooled(null),this.putListenerQueue=i.getPooled()}var e=(this||self,a("a9")),f=a("45"),g=a("71"),h=a("aa"),i=a("ab"),j=a("68"),k=a("4f"),l={initialize:h.getSelectionInformation,close:h.restoreSelection},m={initialize:function(){var a=g.isEnabled();return g.setEnabled(!1),a},close:function(a){g.setEnabled(a)}},n={initialize:function(){this.reactMountReady.reset()},close:function(){this.reactMountReady.notifyAll()}},o={initialize:function(){this.putListenerQueue.reset()},close:function(){this.putListenerQueue.putListeners()}},p=[o,l,m,n],q={getTransactionWrappers:function(){return p},getReactMountReady:function(){return this.reactMountReady},getPutListenerQueue:function(){return this.putListenerQueue},destructor:function(){e.release(this.reactMountReady),this.reactMountReady=null,i.release(this.putListenerQueue),this.putListenerQueue=null}};k(d.prototype,j.Mixin,q),f.addPoolingTo(d),c.exports=d}),c.registerDynamic("ac",[],!0,function(a,b,c){"use strict";function d(a){for(;a&&a.firstChild;)a=a.firstChild;return a}function e(a){for(;a;){if(a.nextSibling)return a.nextSibling;a=a.parentNode}}function f(a,b){for(var c=d(a),f=0,g=0;c;){if(3===c.nodeType){if(g=f+c.textContent.length,f<=b&&g>=b)return{node:c,offset:b-f};f=g}c=d(e(c))}}this||self;c.exports=f}),c.registerDynamic("50",["57"],!0,function(a,b,c){"use strict";function d(){return!f&&e.canUseDOM&&(f="textContent"in document.documentElement?"textContent":"innerText"),f}var e=(this||self,a("57")),f=null;c.exports=d}),c.registerDynamic("ad",["57","ac","50"],!0,function(a,b,c){"use strict";function d(a,b,c,d){return a===c&&b===d}function e(a){var b=document.selection,c=b.createRange(),d=c.text.length,e=c.duplicate();e.moveToElementText(a),e.setEndPoint("EndToStart",c);var f=e.text.length,g=f+d;return{start:f,end:g}}function f(a){var b=window.getSelection&&window.getSelection();if(!b||0===b.rangeCount)return null;var c=b.anchorNode,e=b.anchorOffset,f=b.focusNode,g=b.focusOffset,h=b.getRangeAt(0),i=d(b.anchorNode,b.anchorOffset,b.focusNode,b.focusOffset),j=i?0:h.toString().length,k=h.cloneRange();k.selectNodeContents(a),k.setEnd(h.startContainer,h.startOffset);var l=d(k.startContainer,k.startOffset,k.endContainer,k.endOffset),m=l?0:k.toString().length,n=m+j,o=document.createRange();o.setStart(c,e),o.setEnd(f,g);var p=o.collapsed;return{start:p?n:m,end:p?m:n}}function g(a,b){var c,d,e=document.selection.createRange().duplicate();"undefined"==typeof b.end?(c=b.start,d=c):b.start>b.end?(c=b.end,d=b.start):(c=b.start,d=b.end),e.moveToElementText(a),e.moveStart("character",c),e.setEndPoint("EndToStart",e),e.moveEnd("character",d-c),
16
16
  e.select()}function h(a,b){if(window.getSelection){var c=window.getSelection(),d=a[k()].length,e=Math.min(b.start,d),f="undefined"==typeof b.end?e:Math.min(b.end,d);if(!c.extend&&e>f){var g=f;f=e,e=g}var h=j(a,e),i=j(a,f);if(h&&i){var l=document.createRange();l.setStart(h.node,h.offset),c.removeAllRanges(),e>f?(c.addRange(l),c.extend(i.node,i.offset)):(l.setEnd(i.node,i.offset),c.addRange(l))}}}var i=(this||self,a("57")),j=a("ac"),k=a("50"),l=i.canUseDOM&&"selection"in document&&!("getSelection"in window),m={getOffsets:l?e:f,setOffsets:l?g:h};c.exports=m}),c.registerDynamic("7b",[],!0,function(a,b,c){"use strict";function d(a){try{a.focus()}catch(a){}}this||self;c.exports=d}),c.registerDynamic("aa",["ad","ae","7b","af"],!0,function(a,b,c){"use strict";function d(a){return f(document.documentElement,a)}var e=(this||self,a("ad")),f=a("ae"),g=a("7b"),h=a("af"),i={hasSelectionCapabilities:function(a){return a&&("INPUT"===a.nodeName&&"text"===a.type||"TEXTAREA"===a.nodeName||"true"===a.contentEditable)},getSelectionInformation:function(){var a=h();return{focusedElem:a,selectionRange:i.hasSelectionCapabilities(a)?i.getSelection(a):null}},restoreSelection:function(a){var b=h(),c=a.focusedElem,e=a.selectionRange;b!==c&&d(c)&&(i.hasSelectionCapabilities(c)&&i.setSelection(c,e),g(c))},getSelection:function(a){var b;if("selectionStart"in a)b={start:a.selectionStart,end:a.selectionEnd};else if(document.selection&&"INPUT"===a.nodeName){var c=document.selection.createRange();c.parentElement()===a&&(b={start:-c.moveStart("character",-a.value.length),end:-c.moveEnd("character",-a.value.length)})}else b=e.getOffsets(a);return b||{start:0,end:0}},setSelection:function(a,b){var c=b.start,d=b.end;if("undefined"==typeof d&&(d=c),"selectionStart"in a)a.selectionStart=c,a.selectionEnd=Math.min(d,a.value.length);else if(document.selection&&"INPUT"===a.nodeName){var f=a.createTextRange();f.collapse(!0),f.moveStart("character",c),f.moveEnd("character",d-c),f.select()}else e.setOffsets(a,b)}};c.exports=i}),c.registerDynamic("af",[],!0,function(a,b,c){function d(){try{return document.activeElement||document.body}catch(a){return document.body}}this||self;c.exports=d}),c.registerDynamic("5d",[],!0,function(a,b,c){"use strict";function d(a){return a&&("INPUT"===a.nodeName&&e[a.type]||"TEXTAREA"===a.nodeName)}var e=(this||self,{color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0});c.exports=d}),c.registerDynamic("b0",[],!0,function(a,b,c){"use strict";function d(a,b){if(a===b)return!0;var c;for(c in a)if(a.hasOwnProperty(c)&&(!b.hasOwnProperty(c)||a[c]!==b[c]))return!1;for(c in b)if(b.hasOwnProperty(c)&&!a.hasOwnProperty(c))return!1;return!0}this||self;c.exports=d}),c.registerDynamic("b1",["55","56","aa","52","af","5d","58","b0"],!0,function(a,b,c){"use strict";function d(a){if("selectionStart"in a&&h.hasSelectionCapabilities(a))return{start:a.selectionStart,end:a.selectionEnd};if(window.getSelection){var b=window.getSelection();return{anchorNode:b.anchorNode,anchorOffset:b.anchorOffset,focusNode:b.focusNode,focusOffset:b.focusOffset}}if(document.selection){var c=document.selection.createRange();return{parentElement:c.parentElement(),text:c.text,top:c.boundingTop,left:c.boundingLeft}}}function e(a){if(s||null==p||p!==j())return null;var b=d(p);if(!r||!m(r,b)){r=b;var c=i.getPooled(o.select,q,a);return c.type="select",c.target=p,g.accumulateTwoPhaseDispatches(c),c}}var f=(this||self,a("55")),g=a("56"),h=a("aa"),i=a("52"),j=a("af"),k=a("5d"),l=a("58"),m=a("b0"),n=f.topLevelTypes,o={select:{phasedRegistrationNames:{bubbled:l({onSelect:null}),captured:l({onSelectCapture:null})},dependencies:[n.topBlur,n.topContextMenu,n.topFocus,n.topKeyDown,n.topMouseDown,n.topMouseUp,n.topSelectionChange]}},p=null,q=null,r=null,s=!1,t={eventTypes:o,extractEvents:function(a,b,c,d){switch(a){case n.topFocus:(k(b)||"true"===b.contentEditable)&&(p=b,q=c,r=null);break;case n.topBlur:p=null,q=null,r=null;break;case n.topMouseDown:s=!0;break;case n.topContextMenu:case n.topMouseUp:return s=!1,e(d);case n.topSelectionChange:case n.topKeyDown:case n.topKeyUp:return e(d)}}};c.exports=t}),c.registerDynamic("b2",[],!0,function(a,b,c){"use strict";var d=(this||self,Math.pow(2,53)),e={createReactRootIndex:function(){return Math.ceil(Math.random()*d)}};c.exports=e}),c.registerDynamic("56",["55","5a","72","73","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b,c){var d=b.dispatchConfig.phasedRegistrationNames[c];return q(a,d)}function e(a,b,c){var e=b?p.bubbled:p.captured,f=d(a,c,e);f&&(c._dispatchListeners=n(c._dispatchListeners,f),c._dispatchIDs=n(c._dispatchIDs,a))}function f(a){a&&a.dispatchConfig.phasedRegistrationNames&&m.injection.getInstanceHandle().traverseTwoPhase(a.dispatchMarker,e,a)}function g(a,b,c){if(c&&c.dispatchConfig.registrationName){var d=c.dispatchConfig.registrationName,e=q(a,d);e&&(c._dispatchListeners=n(c._dispatchListeners,e),c._dispatchIDs=n(c._dispatchIDs,a))}}function h(a){a&&a.dispatchConfig.registrationName&&g(a.dispatchMarker,null,a)}function i(a){o(a,f)}function j(a,b,c,d){m.injection.getInstanceHandle().traverseEnterLeave(c,d,g,a,b)}function k(a){o(a,h)}var l=a("55"),m=a("5a"),n=a("72"),o=a("73"),p=l.PropagationPhases,q=m.getListener,r={accumulateTwoPhaseDispatches:i,accumulateDirectDispatches:k,accumulateEnterLeaveDispatches:j};c.exports=r}(a("49"))}),c.registerDynamic("b3",["52"],!0,function(a,b,c){"use strict";function d(a,b,c){e.call(this,a,b,c)}var e=(this||self,a("52")),f={clipboardData:function(a){return"clipboardData"in a?a.clipboardData:window.clipboardData}};e.augmentClass(d,f),c.exports=d}),c.registerDynamic("b4",["b5"],!0,function(a,b,c){"use strict";function d(a,b,c){e.call(this,a,b,c)}var e=(this||self,a("b5")),f={relatedTarget:null};e.augmentClass(d,f),c.exports=d}),c.registerDynamic("b6",["b7"],!0,function(a,b,c){"use strict";function d(a){if(a.key){var b=f[a.key]||a.key;if("Unidentified"!==b)return b}if("keypress"===a.type){var c=e(a);return 13===c?"Enter":String.fromCharCode(c)}return"keydown"===a.type||"keyup"===a.type?g[a.keyCode]||"Unidentified":""}var e=(this||self,a("b7")),f={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},g={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"};c.exports=d}),c.registerDynamic("b8",["b5","b7","b6","b9"],!0,function(a,b,c){"use strict";function d(a,b,c){e.call(this,a,b,c)}var e=(this||self,a("b5")),f=a("b7"),g=a("b6"),h=a("b9"),i={key:g,location:null,ctrlKey:null,shiftKey:null,altKey:null,metaKey:null,repeat:null,locale:null,getModifierState:h,charCode:function(a){return"keypress"===a.type?f(a):0},keyCode:function(a){return"keydown"===a.type||"keyup"===a.type?a.keyCode:0},which:function(a){return"keypress"===a.type?f(a):"keydown"===a.type||"keyup"===a.type?a.keyCode:0}};e.augmentClass(d,i),c.exports=d}),c.registerDynamic("ba",["61"],!0,function(a,b,c){"use strict";function d(a,b,c){e.call(this,a,b,c)}var e=(this||self,a("61")),f={dataTransfer:null};e.augmentClass(d,f),c.exports=d}),c.registerDynamic("bb",["b5","b9"],!0,function(a,b,c){"use strict";function d(a,b,c){e.call(this,a,b,c)}var e=(this||self,a("b5")),f=a("b9"),g={touches:null,targetTouches:null,changedTouches:null,altKey:null,metaKey:null,ctrlKey:null,shiftKey:null,getModifierState:f};e.augmentClass(d,g),c.exports=d}),c.registerDynamic("52",["45","4f","66","87"],!0,function(a,b,c){"use strict";function d(a,b,c){this.dispatchConfig=a,this.dispatchMarker=b,this.nativeEvent=c;var d=this.constructor.Interface;for(var e in d)if(d.hasOwnProperty(e)){var f=d[e];f?this[e]=f(c):this[e]=c[e]}var h=null!=c.defaultPrevented?c.defaultPrevented:c.returnValue===!1;h?this.isDefaultPrevented=g.thatReturnsTrue:this.isDefaultPrevented=g.thatReturnsFalse,this.isPropagationStopped=g.thatReturnsFalse}var e=(this||self,a("45")),f=a("4f"),g=a("66"),h=a("87"),i={type:null,target:h,currentTarget:g.thatReturnsNull,eventPhase:null,bubbles:null,cancelable:null,timeStamp:function(a){return a.timeStamp||Date.now()},defaultPrevented:null,isTrusted:null};f(d.prototype,{preventDefault:function(){this.defaultPrevented=!0;var a=this.nativeEvent;a.preventDefault?a.preventDefault():a.returnValue=!1,this.isDefaultPrevented=g.thatReturnsTrue},stopPropagation:function(){var a=this.nativeEvent;a.stopPropagation?a.stopPropagation():a.cancelBubble=!0,this.isPropagationStopped=g.thatReturnsTrue},persist:function(){this.isPersistent=g.thatReturnsTrue},isPersistent:g.thatReturnsFalse,destructor:function(){var a=this.constructor.Interface;for(var b in a)this[b]=null;this.dispatchConfig=null,this.dispatchMarker=null,this.nativeEvent=null}}),d.Interface=i,d.augmentClass=function(a,b){var c=this,d=Object.create(c.prototype);f(d,a.prototype),a.prototype=d,a.prototype.constructor=a,a.Interface=f({},c.Interface,b),a.augmentClass=c.augmentClass,e.addPoolingTo(a,e.threeArgumentPooler)},e.addPoolingTo(d,e.threeArgumentPooler),c.exports=d}),c.registerDynamic("87",[],!0,function(a,b,c){"use strict";function d(a){var b=a.target||a.srcElement||window;return 3===b.nodeType?b.parentNode:b}this||self;c.exports=d}),c.registerDynamic("b5",["52","87"],!0,function(a,b,c){"use strict";function d(a,b,c){e.call(this,a,b,c)}var e=(this||self,a("52")),f=a("87"),g={view:function(a){if(a.view)return a.view;var b=f(a);if(null!=b&&b.window===b)return b;var c=b.ownerDocument;return c?c.defaultView||c.parentWindow:window},detail:function(a){return a.detail||0}};e.augmentClass(d,g),c.exports=d}),c.registerDynamic("b9",[],!0,function(a,b,c){"use strict";function d(a){var b=this,c=b.nativeEvent;if(c.getModifierState)return c.getModifierState(a);var d=f[a];return!!d&&!!c[d]}function e(a){return d}var f=(this||self,{Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"});c.exports=e}),c.registerDynamic("61",["b5","bc","b9"],!0,function(a,b,c){"use strict";function d(a,b,c){e.call(this,a,b,c)}var e=(this||self,a("b5")),f=a("bc"),g=a("b9"),h={screenX:null,screenY:null,clientX:null,clientY:null,ctrlKey:null,shiftKey:null,altKey:null,metaKey:null,getModifierState:g,button:function(a){var b=a.button;return"which"in a?b:2===b?2:4===b?1:0},buttons:null,relatedTarget:function(a){return a.relatedTarget||(a.fromElement===a.srcElement?a.toElement:a.fromElement)},pageX:function(a){return"pageX"in a?a.pageX:a.clientX+f.currentScrollLeft},pageY:function(a){return"pageY"in a?a.pageY:a.clientY+f.currentScrollTop}};e.augmentClass(d,h),c.exports=d}),c.registerDynamic("bd",["61"],!0,function(a,b,c){"use strict";function d(a,b,c){e.call(this,a,b,c)}var e=(this||self,a("61")),f={deltaX:function(a){return"deltaX"in a?a.deltaX:"wheelDeltaX"in a?-a.wheelDeltaX:0},deltaY:function(a){return"deltaY"in a?a.deltaY:"wheelDeltaY"in a?-a.wheelDeltaY:"wheelDelta"in a?-a.wheelDelta:0},deltaZ:null,deltaMode:null};e.augmentClass(d,f),c.exports=d}),c.registerDynamic("b7",[],!0,function(a,b,c){"use strict";function d(a){var b,c=a.keyCode;return"charCode"in a?(b=a.charCode,0===b&&13===c&&(b=13)):b=c,b>=32||13===b?b:0}this||self;c.exports=d}),c.registerDynamic("be",["55","bf","56","b3","52","b4","b8","61","ba","bb","b5","bd","b7","74","58","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("55"),e=a("bf"),f=a("56"),g=a("b3"),h=a("52"),i=a("b4"),j=a("b8"),k=a("61"),l=a("ba"),m=a("bb"),n=a("b5"),o=a("bd"),p=a("b7"),q=a("74"),r=a("58"),s=(a("48"),d.topLevelTypes),t={blur:{phasedRegistrationNames:{bubbled:r({onBlur:!0}),captured:r({onBlurCapture:!0})}},click:{phasedRegistrationNames:{bubbled:r({onClick:!0}),captured:r({onClickCapture:!0})}},contextMenu:{phasedRegistrationNames:{bubbled:r({onContextMenu:!0}),captured:r({onContextMenuCapture:!0})}},copy:{phasedRegistrationNames:{bubbled:r({onCopy:!0}),captured:r({onCopyCapture:!0})}},cut:{phasedRegistrationNames:{bubbled:r({onCut:!0}),captured:r({onCutCapture:!0})}},doubleClick:{phasedRegistrationNames:{bubbled:r({onDoubleClick:!0}),captured:r({onDoubleClickCapture:!0})}},drag:{phasedRegistrationNames:{bubbled:r({onDrag:!0}),captured:r({onDragCapture:!0})}},dragEnd:{phasedRegistrationNames:{bubbled:r({onDragEnd:!0}),captured:r({onDragEndCapture:!0})}},dragEnter:{phasedRegistrationNames:{bubbled:r({onDragEnter:!0}),captured:r({onDragEnterCapture:!0})}},dragExit:{phasedRegistrationNames:{bubbled:r({onDragExit:!0}),captured:r({onDragExitCapture:!0})}},dragLeave:{phasedRegistrationNames:{bubbled:r({onDragLeave:!0}),captured:r({onDragLeaveCapture:!0})}},dragOver:{phasedRegistrationNames:{bubbled:r({onDragOver:!0}),captured:r({onDragOverCapture:!0})}},dragStart:{phasedRegistrationNames:{bubbled:r({onDragStart:!0}),captured:r({onDragStartCapture:!0})}},drop:{phasedRegistrationNames:{bubbled:r({onDrop:!0}),captured:r({onDropCapture:!0})}},focus:{phasedRegistrationNames:{bubbled:r({onFocus:!0}),captured:r({onFocusCapture:!0})}},input:{phasedRegistrationNames:{bubbled:r({onInput:!0}),captured:r({onInputCapture:!0})}},keyDown:{phasedRegistrationNames:{bubbled:r({onKeyDown:!0}),captured:r({onKeyDownCapture:!0})}},keyPress:{phasedRegistrationNames:{bubbled:r({onKeyPress:!0}),captured:r({onKeyPressCapture:!0})}},keyUp:{phasedRegistrationNames:{bubbled:r({onKeyUp:!0}),captured:r({onKeyUpCapture:!0})}},load:{phasedRegistrationNames:{bubbled:r({onLoad:!0}),captured:r({onLoadCapture:!0})}},error:{phasedRegistrationNames:{bubbled:r({onError:!0}),captured:r({onErrorCapture:!0})}},mouseDown:{phasedRegistrationNames:{bubbled:r({onMouseDown:!0}),captured:r({onMouseDownCapture:!0})}},mouseMove:{phasedRegistrationNames:{bubbled:r({onMouseMove:!0}),captured:r({onMouseMoveCapture:!0})}},mouseOut:{phasedRegistrationNames:{bubbled:r({onMouseOut:!0}),captured:r({onMouseOutCapture:!0})}},mouseOver:{phasedRegistrationNames:{bubbled:r({onMouseOver:!0}),captured:r({onMouseOverCapture:!0})}},mouseUp:{phasedRegistrationNames:{bubbled:r({onMouseUp:!0}),captured:r({onMouseUpCapture:!0})}},paste:{phasedRegistrationNames:{bubbled:r({onPaste:!0}),captured:r({onPasteCapture:!0})}},reset:{phasedRegistrationNames:{bubbled:r({onReset:!0}),captured:r({onResetCapture:!0})}},scroll:{phasedRegistrationNames:{bubbled:r({onScroll:!0}),captured:r({onScrollCapture:!0})}},submit:{phasedRegistrationNames:{bubbled:r({onSubmit:!0}),captured:r({onSubmitCapture:!0})}},touchCancel:{phasedRegistrationNames:{bubbled:r({onTouchCancel:!0}),captured:r({onTouchCancelCapture:!0})}},touchEnd:{phasedRegistrationNames:{bubbled:r({onTouchEnd:!0}),captured:r({onTouchEndCapture:!0})}},touchMove:{phasedRegistrationNames:{bubbled:r({onTouchMove:!0}),captured:r({onTouchMoveCapture:!0})}},touchStart:{phasedRegistrationNames:{bubbled:r({onTouchStart:!0}),captured:r({onTouchStartCapture:!0})}},wheel:{phasedRegistrationNames:{bubbled:r({onWheel:!0}),captured:r({onWheelCapture:!0})}}},u={topBlur:t.blur,topClick:t.click,topContextMenu:t.contextMenu,topCopy:t.copy,topCut:t.cut,topDoubleClick:t.doubleClick,topDrag:t.drag,topDragEnd:t.dragEnd,topDragEnter:t.dragEnter,topDragExit:t.dragExit,topDragLeave:t.dragLeave,topDragOver:t.dragOver,topDragStart:t.dragStart,topDrop:t.drop,topError:t.error,topFocus:t.focus,topInput:t.input,topKeyDown:t.keyDown,topKeyPress:t.keyPress,topKeyUp:t.keyUp,topLoad:t.load,topMouseDown:t.mouseDown,topMouseMove:t.mouseMove,topMouseOut:t.mouseOut,topMouseOver:t.mouseOver,topMouseUp:t.mouseUp,topPaste:t.paste,topReset:t.reset,topScroll:t.scroll,topSubmit:t.submit,topTouchCancel:t.touchCancel,topTouchEnd:t.touchEnd,topTouchMove:t.touchMove,topTouchStart:t.touchStart,topWheel:t.wheel};for(var v in u)u[v].dependencies=[v];var w={eventTypes:t,executeDispatch:function(a,b,c){var d=e.executeDispatch(a,b,c);d===!1&&(a.stopPropagation(),a.preventDefault())},extractEvents:function(a,b,c,d){var e=u[a];if(!e)return null;var r;switch(a){case s.topInput:case s.topLoad:case s.topError:case s.topReset:case s.topSubmit:r=h;break;case s.topKeyPress:if(0===p(d))return null;case s.topKeyDown:case s.topKeyUp:r=j;break;case s.topBlur:case s.topFocus:r=i;break;case s.topClick:if(2===d.button)return null;case s.topContextMenu:case s.topDoubleClick:case s.topMouseDown:case s.topMouseMove:case s.topMouseOut:case s.topMouseOver:case s.topMouseUp:r=k;break;case s.topDrag:case s.topDragEnd:case s.topDragEnter:case s.topDragExit:case s.topDragLeave:case s.topDragOver:case s.topDragStart:case s.topDrop:r=l;break;case s.topTouchCancel:case s.topTouchEnd:case s.topTouchMove:case s.topTouchStart:r=m;break;case s.topScroll:r=n;break;case s.topWheel:r=o;break;case s.topCopy:case s.topCut:case s.topPaste:r=g}q(r);var t=r.getPooled(e,c,d);return f.accumulateTwoPhaseDispatches(t),t}};c.exports=w}(a("49"))}),c.registerDynamic("c0",["64"],!0,function(a,b,c){"use strict";var d=(this||self,a("64")),e=d.injection.MUST_USE_ATTRIBUTE,f={Properties:{clipPath:e,cx:e,cy:e,d:e,dx:e,dy:e,fill:e,fillOpacity:e,fontFamily:e,fontSize:e,fx:e,fy:e,gradientTransform:e,gradientUnits:e,markerEnd:e,markerMid:e,markerStart:e,offset:e,opacity:e,patternContentUnits:e,patternUnits:e,points:e,preserveAspectRatio:e,r:e,rx:e,ry:e,spreadMethod:e,stopColor:e,stopOpacity:e,stroke:e,strokeDasharray:e,strokeLinecap:e,strokeOpacity:e,strokeWidth:e,textAnchor:e,transform:e,version:e,viewBox:e,x1:e,x2:e,x:e,y1:e,y2:e,y:e},DOMAttributeNames:{clipPath:"clip-path",fillOpacity:"fill-opacity",fontFamily:"font-family",fontSize:"font-size",gradientTransform:"gradientTransform",gradientUnits:"gradientUnits",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",patternContentUnits:"patternContentUnits",patternUnits:"patternUnits",preserveAspectRatio:"preserveAspectRatio",spreadMethod:"spreadMethod",stopColor:"stop-color",stopOpacity:"stop-opacity",strokeDasharray:"stroke-dasharray",strokeLinecap:"stroke-linecap",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",textAnchor:"text-anchor",viewBox:"viewBox"}};c.exports=f}),c.registerDynamic("c1",["c2","74","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b){this.props=a,this.context=b}var e=a("c2"),f=a("74");a("48");d.prototype.setState=function(a,b){f("object"==typeof a||"function"==typeof a||null==a),e.enqueueSetState(this,a),b&&e.enqueueCallback(this,b)},d.prototype.forceUpdate=function(a){e.enqueueForceUpdate(this),a&&e.enqueueCallback(this,a)};c.exports=d}(a("49"))}),c.registerDynamic("c3",[],!0,function(a,b,c){"use strict";var d=(this||self,{guard:function(a,b){return a}});c.exports=d}),c.registerDynamic("58",[],!0,function(a,b,c){var d=(this||self,function(a){var b;for(b in a)if(a.hasOwnProperty(b))return b;return null});c.exports=d}),c.registerDynamic("6c",["c1","c4","4c","c3","c5","c6","c7","c8","c2","4f","74","6d","58","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b){var c=y.hasOwnProperty(b)?y[b]:null;A.hasOwnProperty(b)&&s(c===w.OVERRIDE_BASE),a.hasOwnProperty(b)&&s(c===w.DEFINE_MANY||c===w.DEFINE_MANY_MERGED)}function e(a,b){if(b){s("function"!=typeof b),s(!m.isValidElement(b));var c=a.prototype;b.hasOwnProperty(v)&&z.mixins(a,b.mixins);for(var e in b)if(b.hasOwnProperty(e)&&e!==v){var f=b[e];if(d(c,e),z.hasOwnProperty(e))z[e](a,f);else{var g=y.hasOwnProperty(e),j=c.hasOwnProperty(e),k=f&&f.__reactDontBind,l="function"==typeof f,n=l&&!g&&!j&&!k;if(n)c.__reactAutoBindMap||(c.__reactAutoBindMap={}),c.__reactAutoBindMap[e]=f,c[e]=f;else if(j){var o=y[e];s(g&&(o===w.DEFINE_MANY_MERGED||o===w.DEFINE_MANY)),o===w.DEFINE_MANY_MERGED?c[e]=h(c[e],f):o===w.DEFINE_MANY&&(c[e]=i(c[e],f))}else c[e]=f}}}}function f(a,b){if(b)for(var c in b){var d=b[c];if(b.hasOwnProperty(c)){var e=c in z;s(!e);var f=c in a;s(!f),a[c]=d}}}function g(a,b){s(a&&b&&"object"==typeof a&&"object"==typeof b);for(var c in b)b.hasOwnProperty(c)&&(s(void 0===a[c]),a[c]=b[c]);return a}function h(a,b){return function(){var c=a.apply(this,arguments),d=b.apply(this,arguments);if(null==c)return d;if(null==d)return c;var e={};return g(e,c),g(e,d),e}}function i(a,b){return function(){a.apply(this,arguments),b.apply(this,arguments)}}function j(a,b){var c=b.bind(a);return c}function k(a){for(var b in a.__reactAutoBindMap)if(a.__reactAutoBindMap.hasOwnProperty(b)){var c=a.__reactAutoBindMap[b];a[b]=j(a,n.guard(c,a.constructor.displayName+"."+b))}}var l=a("c1"),m=(a("c4"),a("4c")),n=a("c3"),o=a("c5"),p=a("c6"),q=(a("c7"),a("c8"),a("c2")),r=a("4f"),s=a("74"),t=a("6d"),u=a("58"),v=(a("48"),u({mixins:null})),w=t({DEFINE_ONCE:null,DEFINE_MANY:null,OVERRIDE_BASE:null,DEFINE_MANY_MERGED:null}),x=[],y={mixins:w.DEFINE_MANY,statics:w.DEFINE_MANY,propTypes:w.DEFINE_MANY,contextTypes:w.DEFINE_MANY,childContextTypes:w.DEFINE_MANY,getDefaultProps:w.DEFINE_MANY_MERGED,getInitialState:w.DEFINE_MANY_MERGED,getChildContext:w.DEFINE_MANY_MERGED,render:w.DEFINE_ONCE,componentWillMount:w.DEFINE_MANY,componentDidMount:w.DEFINE_MANY,componentWillReceiveProps:w.DEFINE_MANY,shouldComponentUpdate:w.DEFINE_ONCE,componentWillUpdate:w.DEFINE_MANY,componentDidUpdate:w.DEFINE_MANY,componentWillUnmount:w.DEFINE_MANY,updateComponent:w.OVERRIDE_BASE},z={displayName:function(a,b){a.displayName=b},mixins:function(a,b){if(b)for(var c=0;c<b.length;c++)e(a,b[c])},childContextTypes:function(a,b){a.childContextTypes=r({},a.childContextTypes,b)},contextTypes:function(a,b){a.contextTypes=r({},a.contextTypes,b)},getDefaultProps:function(a,b){a.getDefaultProps?a.getDefaultProps=h(a.getDefaultProps,b):a.getDefaultProps=b},propTypes:function(a,b){a.propTypes=r({},a.propTypes,b)},statics:function(a,b){f(a,b)}},A={replaceState:function(a,b){q.enqueueReplaceState(this,a),b&&q.enqueueCallback(this,b)},isMounted:function(){var a=o.get(this);return a&&a!==p.currentlyMountingInstance},setProps:function(a,b){q.enqueueSetProps(this,a),b&&q.enqueueCallback(this,b)},replaceProps:function(a,b){q.enqueueReplaceProps(this,a),b&&q.enqueueCallback(this,b)}},B=function(){};r(B.prototype,l.prototype,A);var C={createClass:function(a){var b=function(a,b){this.__reactAutoBindMap&&k(this),this.props=a,this.context=b,this.state=null;var c=this.getInitialState?this.getInitialState():null;s("object"==typeof c&&!Array.isArray(c)),this.state=c};b.prototype=new B,b.prototype.constructor=b,x.forEach(e.bind(null,b)),e(b,a),b.getDefaultProps&&(b.defaultProps=b.getDefaultProps()),s(b.prototype.render);for(var c in y)b.prototype[c]||(b.prototype[c]=null);return b.type=b,b},injection:{injectMixin:function(a){x.push(a)}}};c.exports=C}(a("49"))}),c.registerDynamic("c9",["6c","4c","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){var b=f.createFactory(a),c=e.createClass({tagName:a.toUpperCase(),displayName:"ReactFullPageComponent"+a,componentWillUnmount:function(){g(!1)},render:function(){return b(this.props)}});return c}var e=a("6c"),f=a("4c"),g=a("74");c.exports=d}(a("49"))}),c.registerDynamic("ca",["4f"],!0,function(a,b,c){function d(a){for(var b=0,c=0;c<a.length;c++){var d=a[c];b+=d.totalTime}return b}function e(a){for(var b=[],c=0;c<a.length;c++){var d,e=a[c];for(d in e.writes)e.writes[d].forEach(function(a){b.push({id:d,type:k[a.type]||a.type,args:a.args})})}return b}function f(a){for(var b,c={},d=0;d<a.length;d++){var e=a[d],f=i({},e.exclusive,e.inclusive);for(var g in f)b=e.displayNames[g].current,c[b]=c[b]||{componentName:b,inclusive:0,exclusive:0,render:0,count:0},e.render[g]&&(c[b].render+=e.render[g]),e.exclusive[g]&&(c[b].exclusive+=e.exclusive[g]),e.inclusive[g]&&(c[b].inclusive+=e.inclusive[g]),e.counts[g]&&(c[b].count+=e.counts[g])}var h=[];for(b in c)c[b].exclusive>=j&&h.push(c[b]);return h.sort(function(a,b){return b.exclusive-a.exclusive}),h}function g(a,b){for(var c,d={},e=0;e<a.length;e++){var f,g=a[e],k=i({},g.exclusive,g.inclusive);b&&(f=h(g));for(var l in k)if(!b||f[l]){var m=g.displayNames[l];c=m.owner+" > "+m.current,d[c]=d[c]||{componentName:c,time:0,count:0},g.inclusive[l]&&(d[c].time+=g.inclusive[l]),g.counts[l]&&(d[c].count+=g.counts[l])}}var n=[];for(c in d)d[c].time>=j&&n.push(d[c]);return n.sort(function(a,b){return b.time-a.time}),n}function h(a){var b={},c=Object.keys(a.writes),d=i({},a.exclusive,a.inclusive);for(var e in d){for(var f=!1,g=0;g<c.length;g++)if(0===c[g].indexOf(e)){f=!0;break}!f&&a.counts[e]>0&&(b[e]=!0)}return b}var i=(this||self,a("4f")),j=1.2,k={_mountImageIntoNode:"set innerHTML",INSERT_MARKUP:"set innerHTML",MOVE_EXISTING:"move",REMOVE_NODE:"remove",TEXT_CONTENT:"set textContent",updatePropertyByID:"update attribute",deletePropertyByID:"delete attribute",updateStylesByID:"update styles",updateInnerHTMLByID:"set innerHTML",dangerouslyReplaceNodeWithMarkupByID:"replace"},l={getExclusiveSummary:f,getInclusiveSummary:g,getDOMSummary:e,getTotalTime:d};c.exports=l}),c.registerDynamic("cb",["57"],!0,function(a,b,c){"use strict";var d,e=(this||self,a("57"));e.canUseDOM&&(d=window.performance||window.msPerformance||window.webkitPerformance),c.exports=d||{}}),c.registerDynamic("cc",["cb"],!0,function(a,b,c){var d=(this||self,a("cb"));d&&d.now||(d=Date);var e=d.now.bind(d);c.exports=e}),c.registerDynamic("cd",["64","ca","62","9b","cc"],!0,function(a,b,c){"use strict";function d(a){return Math.floor(100*a)/100}function e(a,b,c){a[b]=(a[b]||0)+c}var f=(this||self,a("64")),g=a("ca"),h=a("62"),i=a("9b"),j=a("cc"),k={_allMeasurements:[],_mountStack:[0],_injected:!1,start:function(){k._injected||i.injection.injectMeasure(k.measure),k._allMeasurements.length=0,i.enableMeasure=!0},stop:function(){i.enableMeasure=!1},getLastMeasurements:function(){return k._allMeasurements},printExclusive:function(a){a=a||k._allMeasurements;var b=g.getExclusiveSummary(a);console.table(b.map(function(a){return{"Component class name":a.componentName,"Total inclusive time (ms)":d(a.inclusive),"Exclusive mount time (ms)":d(a.exclusive),"Exclusive render time (ms)":d(a.render),"Mount time per instance (ms)":d(a.exclusive/a.count),"Render time per instance (ms)":d(a.render/a.count),Instances:a.count}}))},printInclusive:function(a){a=a||k._allMeasurements;var b=g.getInclusiveSummary(a);console.table(b.map(function(a){return{"Owner > component":a.componentName,"Inclusive time (ms)":d(a.time),Instances:a.count}})),console.log("Total time:",g.getTotalTime(a).toFixed(2)+" ms")},getMeasurementsSummaryMap:function(a){var b=g.getInclusiveSummary(a,!0);return b.map(function(a){return{"Owner > component":a.componentName,"Wasted time (ms)":a.time,Instances:a.count}})},printWasted:function(a){a=a||k._allMeasurements,console.table(k.getMeasurementsSummaryMap(a)),console.log("Total time:",g.getTotalTime(a).toFixed(2)+" ms")},printDOM:function(a){a=a||k._allMeasurements;var b=g.getDOMSummary(a);console.table(b.map(function(a){var b={};return b[f.ID_ATTRIBUTE_NAME]=a.id,b.type=a.type,b.args=JSON.stringify(a.args),b})),console.log("Total time:",g.getTotalTime(a).toFixed(2)+" ms")},_recordWrite:function(a,b,c,d){var e=k._allMeasurements[k._allMeasurements.length-1].writes;e[a]=e[a]||[],e[a].push({type:b,time:c,args:d})},measure:function(a,b,c){return function(){for(var d=[],f=0,g=arguments.length;f<g;f++)d.push(arguments[f]);var i,l,m;if("_renderNewRootComponent"===b||"flushBatchedUpdates"===b)return k._allMeasurements.push({exclusive:{},inclusive:{},render:{},counts:{},writes:{},displayNames:{},totalTime:0}),m=j(),l=c.apply(this,d),k._allMeasurements[k._allMeasurements.length-1].totalTime=j()-m,l;if("_mountImageIntoNode"===b||"ReactDOMIDOperations"===a){if(m=j(),l=c.apply(this,d),i=j()-m,"_mountImageIntoNode"===b){var n=h.getID(d[1]);k._recordWrite(n,b,i,d[0])}else"dangerouslyProcessChildrenUpdates"===b?d[0].forEach(function(a){var b={};null!==a.fromIndex&&(b.fromIndex=a.fromIndex),null!==a.toIndex&&(b.toIndex=a.toIndex),null!==a.textContent&&(b.textContent=a.textContent),null!==a.markupIndex&&(b.markup=d[1][a.markupIndex]),k._recordWrite(a.parentID,a.type,i,b)}):k._recordWrite(d[0],b,i,Array.prototype.slice.call(d,1));return l}if("ReactCompositeComponent"!==a||"mountComponent"!==b&&"updateComponent"!==b&&"_renderValidatedComponent"!==b)return c.apply(this,d);if("string"==typeof this._currentElement.type)return c.apply(this,d);var o="mountComponent"===b?d[0]:this._rootNodeID,p="_renderValidatedComponent"===b,q="mountComponent"===b,r=k._mountStack,s=k._allMeasurements[k._allMeasurements.length-1];if(p?e(s.counts,o,1):q&&r.push(0),m=j(),l=c.apply(this,d),i=j()-m,p)e(s.render,o,i);else if(q){var t=r.pop();r[r.length-1]+=i,e(s.exclusive,o,i-t),e(s.inclusive,o,i)}else e(s.inclusive,o,i);return s.displayNames[o]={current:this.getName(),owner:this._currentElement._owner?this._currentElement._owner.getName():"<root>"},l}}};c.exports=k}),c.registerDynamic("ce",["54","59","5e","5f","60","57","63","65","6b","6c","80","67","81","69","6e","70","9a","75","76","79","7a","7e","7f","4c","85","a4","86","62","a8","b1","b2","be","c0","c9","cd","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){return o.createClass({tagName:a.toUpperCase(),render:function(){return new C(a,null,null,null,null,this.props)}})}function e(){E.EventEmitter.injectReactEventListener(D),E.EventPluginHub.injectEventPluginOrder(i),E.EventPluginHub.injectInstanceHandle(F),E.EventPluginHub.injectMount(G),E.EventPluginHub.injectEventPluginsByName({SimpleEventPlugin:K,EnterLeaveEventPlugin:j,ChangeEventPlugin:g,MobileSafariClickEventPlugin:m,SelectEventPlugin:I,BeforeInputEventPlugin:f}),E.NativeComponent.injectGenericComponentClass(r),E.NativeComponent.injectTextComponentClass(B),E.NativeComponent.injectAutoWrapper(d),E.Class.injectMixin(n),E.NativeComponent.injectComponentClasses({button:s,form:t,iframe:w,img:u,input:x,option:y,select:z,textarea:A,html:M("html"),head:M("head"),body:M("body")}),E.DOMProperty.injectDOMPropertyConfig(l),E.DOMProperty.injectDOMPropertyConfig(L),E.EmptyComponent.injectEmptyComponent("noscript"),E.Updates.injectReconcileTransaction(H),E.Updates.injectBatchingStrategy(q),E.RootIndex.injectCreateReactRootIndex(k.canUseDOM?h.createReactRootIndex:J.createReactRootIndex),E.Component.injectEnvironment(p),E.DOMComponent.injectIDOperations(v)}var f=a("54"),g=a("59"),h=a("5e"),i=a("5f"),j=a("60"),k=a("57"),l=a("63"),m=a("65"),n=a("6b"),o=a("6c"),p=a("80"),q=a("67"),r=a("81"),s=a("69"),t=a("6e"),u=a("70"),v=a("9a"),w=a("75"),x=a("76"),y=a("79"),z=a("7a"),A=a("7e"),B=a("7f"),C=a("4c"),D=a("85"),E=a("a4"),F=a("86"),G=a("62"),H=a("a8"),I=a("b1"),J=a("b2"),K=a("be"),L=a("c0"),M=a("c9");c.exports={inject:e}}(a("49"))}),c.registerDynamic("7c",["4c","46","c8","66"],!0,function(a,b,c){"use strict";function d(a){function b(b,c,d,e,f){if(e=e||v,null==c[d]){var g=t[f];return b?new Error("Required "+g+" `"+d+"` was not specified in "+("`"+e+"`.")):null}return a(c,d,e,f)}var c=b.bind(null,!1);return c.isRequired=b.bind(null,!0),c}function e(a){function b(b,c,d,e){var f=b[c],g=p(f);if(g!==a){var h=t[e],i=q(f);return new Error("Invalid "+h+" `"+c+"` of type `"+i+"` "+("supplied to `"+d+"`, expected `"+a+"`."))}return null}return d(b)}function f(){return d(u.thatReturns(null))}function g(a){function b(b,c,d,e){var f=b[c];if(!Array.isArray(f)){var g=t[e],h=p(f);return new Error("Invalid "+g+" `"+c+"` of type "+("`"+h+"` supplied to `"+d+"`, expected an array."))}for(var i=0;i<f.length;i++){var j=a(f,i,d,e);if(j instanceof Error)return j}return null}return d(b)}function h(){function a(a,b,c,d){if(!r.isValidElement(a[b])){var e=t[d];return new Error("Invalid "+e+" `"+b+"` supplied to "+("`"+c+"`, expected a ReactElement."))}return null}return d(a)}function i(a){function b(b,c,d,e){if(!(b[c]instanceof a)){var f=t[e],g=a.name||v;return new Error("Invalid "+f+" `"+c+"` supplied to "+("`"+d+"`, expected instance of `"+g+"`."))}return null}return d(b)}function j(a){
17
17
  function b(b,c,d,e){for(var f=b[c],g=0;g<a.length;g++)if(f===a[g])return null;var h=t[e],i=JSON.stringify(a);return new Error("Invalid "+h+" `"+c+"` of value `"+f+"` "+("supplied to `"+d+"`, expected one of "+i+"."))}return d(b)}function k(a){function b(b,c,d,e){var f=b[c],g=p(f);if("object"!==g){var h=t[e];return new Error("Invalid "+h+" `"+c+"` of type "+("`"+g+"` supplied to `"+d+"`, expected an object."))}for(var i in f)if(f.hasOwnProperty(i)){var j=a(f,i,d,e);if(j instanceof Error)return j}return null}return d(b)}function l(a){function b(b,c,d,e){for(var f=0;f<a.length;f++){var g=a[f];if(null==g(b,c,d,e))return null}var h=t[e];return new Error("Invalid "+h+" `"+c+"` supplied to "+("`"+d+"`."))}return d(b)}function m(){function a(a,b,c,d){if(!o(a[b])){var e=t[d];return new Error("Invalid "+e+" `"+b+"` supplied to "+("`"+c+"`, expected a ReactNode."))}return null}return d(a)}function n(a){function b(b,c,d,e){var f=b[c],g=p(f);if("object"!==g){var h=t[e];return new Error("Invalid "+h+" `"+c+"` of type `"+g+"` "+("supplied to `"+d+"`, expected `object`."))}for(var i in a){var j=a[i];if(j){var k=j(f,i,d,e);if(k)return k}}return null}return d(b)}function o(a){switch(typeof a){case"number":case"string":case"undefined":return!0;case"boolean":return!a;case"object":if(Array.isArray(a))return a.every(o);if(null===a||r.isValidElement(a))return!0;a=s.extractIfFragment(a);for(var b in a)if(!o(a[b]))return!1;return!0;default:return!1}}function p(a){var b=typeof a;return Array.isArray(a)?"array":a instanceof RegExp?"object":b}function q(a){var b=p(a);if("object"===b){if(a instanceof Date)return"date";if(a instanceof RegExp)return"regexp"}return b}var r=(this||self,a("4c")),s=a("46"),t=a("c8"),u=a("66"),v="<<anonymous>>",w=h(),x=m(),y={array:e("array"),bool:e("boolean"),func:e("function"),number:e("number"),object:e("object"),string:e("string"),any:f(),arrayOf:g,element:w,instanceOf:i,node:x,objectOf:k,oneOf:j,oneOfType:l,shape:n};c.exports=y}),c.registerDynamic("ab",["45","71","4f"],!0,function(a,b,c){"use strict";function d(){this.listenersToPut=[]}var e=(this||self,a("45")),f=a("71"),g=a("4f");g(d.prototype,{enqueuePutListener:function(a,b,c){this.listenersToPut.push({rootNodeID:a,propKey:b,propValue:c})},putListeners:function(){for(var a=0;a<this.listenersToPut.length;a++){var b=this.listenersToPut[a];f.putListener(b.rootNodeID,b.propKey,b.propValue)}},reset:function(){this.listenersToPut.length=0},destructor:function(){this.reset()}}),e.addPoolingTo(d),c.exports=d}),c.registerDynamic("cf",["45","a9","ab","68","4f","66"],!0,function(a,b,c){"use strict";function d(a){this.reinitializeTransaction(),this.renderToStaticMarkup=a,this.reactMountReady=f.getPooled(null),this.putListenerQueue=g.getPooled()}var e=(this||self,a("45")),f=a("a9"),g=a("ab"),h=a("68"),i=a("4f"),j=a("66"),k={initialize:function(){this.reactMountReady.reset()},close:j},l={initialize:function(){this.putListenerQueue.reset()},close:j},m=[l,k],n={getTransactionWrappers:function(){return m},getReactMountReady:function(){return this.reactMountReady},getPutListenerQueue:function(){return this.putListenerQueue},destructor:function(){f.release(this.reactMountReady),this.reactMountReady=null,g.release(this.putListenerQueue),this.putListenerQueue=null}};i(d.prototype,h.Mixin,n),e.addPoolingTo(d),c.exports=d}),c.registerDynamic("d0",["4c","86","d1","cf","d2","a0","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){l(f.isValidElement(a));var b;try{var c=g.createReactRootID();return b=i.getPooled(!1),b.perform(function(){var d=k(a,null),e=d.mountComponent(c,b,j);return h.addChecksumToMarkup(e)},null)}finally{i.release(b)}}function e(a){l(f.isValidElement(a));var b;try{var c=g.createReactRootID();return b=i.getPooled(!0),b.perform(function(){var d=k(a,null);return d.mountComponent(c,b,j)},null)}finally{i.release(b)}}var f=a("4c"),g=a("86"),h=a("d1"),i=a("cf"),j=a("d2"),k=a("a0"),l=a("74");c.exports={renderToString:d,renderToStaticMarkup:e}}(a("49"))}),c.registerDynamic("64",["74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b){return(a&b)===b}var e=a("74"),f={MUST_USE_ATTRIBUTE:1,MUST_USE_PROPERTY:2,HAS_SIDE_EFFECTS:4,HAS_BOOLEAN_VALUE:8,HAS_NUMERIC_VALUE:16,HAS_POSITIVE_NUMERIC_VALUE:48,HAS_OVERLOADED_BOOLEAN_VALUE:64,injectDOMPropertyConfig:function(a){var b=a.Properties||{},c=a.DOMAttributeNames||{},g=a.DOMPropertyNames||{},i=a.DOMMutationMethods||{};a.isCustomAttribute&&h._isCustomAttributeFunctions.push(a.isCustomAttribute);for(var j in b){e(!h.isStandardName.hasOwnProperty(j)),h.isStandardName[j]=!0;var k=j.toLowerCase();if(h.getPossibleStandardName[k]=j,c.hasOwnProperty(j)){var l=c[j];h.getPossibleStandardName[l]=j,h.getAttributeName[j]=l}else h.getAttributeName[j]=k;h.getPropertyName[j]=g.hasOwnProperty(j)?g[j]:j,i.hasOwnProperty(j)?h.getMutationMethod[j]=i[j]:h.getMutationMethod[j]=null;var m=b[j];h.mustUseAttribute[j]=d(m,f.MUST_USE_ATTRIBUTE),h.mustUseProperty[j]=d(m,f.MUST_USE_PROPERTY),h.hasSideEffects[j]=d(m,f.HAS_SIDE_EFFECTS),h.hasBooleanValue[j]=d(m,f.HAS_BOOLEAN_VALUE),h.hasNumericValue[j]=d(m,f.HAS_NUMERIC_VALUE),h.hasPositiveNumericValue[j]=d(m,f.HAS_POSITIVE_NUMERIC_VALUE),h.hasOverloadedBooleanValue[j]=d(m,f.HAS_OVERLOADED_BOOLEAN_VALUE),e(!h.mustUseAttribute[j]||!h.mustUseProperty[j]),e(h.mustUseProperty[j]||!h.hasSideEffects[j]),e(!!h.hasBooleanValue[j]+!!h.hasNumericValue[j]+!!h.hasOverloadedBooleanValue[j]<=1)}}},g={},h={ID_ATTRIBUTE_NAME:"data-reactid",isStandardName:{},getPossibleStandardName:{},getAttributeName:{},getPropertyName:{},getMutationMethod:{},mustUseAttribute:{},mustUseProperty:{},hasSideEffects:{},hasBooleanValue:{},hasNumericValue:{},hasPositiveNumericValue:{},hasOverloadedBooleanValue:{},_isCustomAttributeFunctions:[],isCustomAttribute:function(a){for(var b=0;b<h._isCustomAttributeFunctions.length;b++){var c=h._isCustomAttributeFunctions[b];if(c(a))return!0}return!1},getDefaultValueForProperty:function(a,b){var c,d=g[a];return d||(g[a]=d={}),b in d||(c=document.createElement(a),d[b]=c[b]),d[b]},injection:f};c.exports=h}(a("49"))}),c.registerDynamic("d3",["74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(){if(h)for(var a in i){var b=i[a],c=h.indexOf(a);if(g(c>-1),!j.plugins[c]){g(b.extractEvents),j.plugins[c]=b;var d=b.eventTypes;for(var f in d)g(e(d[f],b,f))}}}function e(a,b,c){g(!j.eventNameDispatchConfigs.hasOwnProperty(c)),j.eventNameDispatchConfigs[c]=a;var d=a.phasedRegistrationNames;if(d){for(var e in d)if(d.hasOwnProperty(e)){var h=d[e];f(h,b,c)}return!0}return!!a.registrationName&&(f(a.registrationName,b,c),!0)}function f(a,b,c){g(!j.registrationNameModules[a]),j.registrationNameModules[a]=b,j.registrationNameDependencies[a]=b.eventTypes[c].dependencies}var g=a("74"),h=null,i={},j={plugins:[],eventNameDispatchConfigs:{},registrationNameModules:{},registrationNameDependencies:{},injectEventPluginOrder:function(a){g(!h),h=Array.prototype.slice.call(a),d()},injectEventPluginsByName:function(a){var b=!1;for(var c in a)if(a.hasOwnProperty(c)){var e=a[c];i.hasOwnProperty(c)&&i[c]===e||(g(!i[c]),i[c]=e,b=!0)}b&&d()},getPluginModuleForEvent:function(a){var b=a.dispatchConfig;if(b.registrationName)return j.registrationNameModules[b.registrationName]||null;for(var c in b.phasedRegistrationNames)if(b.phasedRegistrationNames.hasOwnProperty(c)){var d=j.registrationNameModules[b.phasedRegistrationNames[c]];if(d)return d}return null},_resetEventPlugins:function(){h=null;for(var a in i)i.hasOwnProperty(a)&&delete i[a];j.plugins.length=0;var b=j.eventNameDispatchConfigs;for(var c in b)b.hasOwnProperty(c)&&delete b[c];var d=j.registrationNameModules;for(var e in d)d.hasOwnProperty(e)&&delete d[e]}};c.exports=j}(a("49"))}),c.registerDynamic("55",["6d"],!0,function(a,b,c){"use strict";var d=(this||self,a("6d")),e=d({bubbled:null,captured:null}),f=d({topBlur:null,topChange:null,topClick:null,topCompositionEnd:null,topCompositionStart:null,topCompositionUpdate:null,topContextMenu:null,topCopy:null,topCut:null,topDoubleClick:null,topDrag:null,topDragEnd:null,topDragEnter:null,topDragExit:null,topDragLeave:null,topDragOver:null,topDragStart:null,topDrop:null,topError:null,topFocus:null,topInput:null,topKeyDown:null,topKeyPress:null,topKeyUp:null,topLoad:null,topMouseDown:null,topMouseMove:null,topMouseOut:null,topMouseOver:null,topMouseUp:null,topPaste:null,topReset:null,topScroll:null,topSelectionChange:null,topSubmit:null,topTextInput:null,topTouchCancel:null,topTouchEnd:null,topTouchMove:null,topTouchStart:null,topWheel:null}),g={topLevelTypes:f,PropagationPhases:e};c.exports=g}),c.registerDynamic("bf",["55","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){return a===q.topMouseUp||a===q.topTouchEnd||a===q.topTouchCancel}function e(a){return a===q.topMouseMove||a===q.topTouchMove}function f(a){return a===q.topMouseDown||a===q.topTouchStart}function g(a,b){var c=a._dispatchListeners,d=a._dispatchIDs;if(Array.isArray(c))for(var e=0;e<c.length&&!a.isPropagationStopped();e++)b(a,c[e],d[e]);else c&&b(a,c,d)}function h(a,b,c){a.currentTarget=p.Mount.getNode(c);var d=b(a,c);return a.currentTarget=null,d}function i(a,b){g(a,b),a._dispatchListeners=null,a._dispatchIDs=null}function j(a){var b=a._dispatchListeners,c=a._dispatchIDs;if(Array.isArray(b)){for(var d=0;d<b.length&&!a.isPropagationStopped();d++)if(b[d](a,c[d]))return c[d]}else if(b&&b(a,c))return c;return null}function k(a){var b=j(a);return a._dispatchIDs=null,a._dispatchListeners=null,b}function l(a){var b=a._dispatchListeners,c=a._dispatchIDs;o(!Array.isArray(b));var d=b?b(a,c):null;return a._dispatchListeners=null,a._dispatchIDs=null,d}function m(a){return!!a._dispatchListeners}var n=a("55"),o=a("74"),p={Mount:null,injectMount:function(a){p.Mount=a}},q=n.topLevelTypes,r={isEndish:d,isMoveish:e,isStartish:f,executeDirectDispatch:l,executeDispatch:h,executeDispatchesInOrder:i,executeDispatchesInOrderStopAtTrue:k,hasDispatches:m,injection:p,useTouchEvents:!1};c.exports=r}(a("49"))}),c.registerDynamic("72",["74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b){if(e(null!=b),null==a)return b;var c=Array.isArray(a),d=Array.isArray(b);return c&&d?(a.push.apply(a,b),a):c?(a.push(b),a):d?[a].concat(b):[a,b]}var e=a("74");c.exports=d}(a("49"))}),c.registerDynamic("73",[],!0,function(a,b,c){"use strict";var d=(this||self,function(a,b,c){Array.isArray(a)?a.forEach(b,c):a&&b.call(c,a)});c.exports=d}),c.registerDynamic("5a",["d3","bf","72","73","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("d3"),e=a("bf"),f=a("72"),g=a("73"),h=a("74"),i={},j=null,k=function(a){if(a){var b=e.executeDispatch,c=d.getPluginModuleForEvent(a);c&&c.executeDispatch&&(b=c.executeDispatch),e.executeDispatchesInOrder(a,b),a.isPersistent()||a.constructor.release(a)}},l=null,m={injection:{injectMount:e.injection.injectMount,injectInstanceHandle:function(a){l=a},getInstanceHandle:function(){return l},injectEventPluginOrder:d.injectEventPluginOrder,injectEventPluginsByName:d.injectEventPluginsByName},eventNameDispatchConfigs:d.eventNameDispatchConfigs,registrationNameModules:d.registrationNameModules,putListener:function(a,b,c){h(!c||"function"==typeof c);var d=i[b]||(i[b]={});d[a]=c},getListener:function(a,b){var c=i[b];return c&&c[a]},deleteListener:function(a,b){var c=i[b];c&&delete c[a]},deleteAllListeners:function(a){for(var b in i)delete i[b][a]},extractEvents:function(a,b,c,e){for(var g,h=d.plugins,i=0,j=h.length;i<j;i++){var k=h[i];if(k){var l=k.extractEvents(a,b,c,e);l&&(g=f(g,l))}}return g},enqueueEvents:function(a){a&&(j=f(j,a))},processEventQueue:function(){var a=j;j=null,g(a,k),h(!j)},__purge:function(){i={}},__getListenerBank:function(){return i}};c.exports=m}(a("49"))}),c.registerDynamic("d4",["5a"],!0,function(a,b,c){"use strict";function d(a){e.enqueueEvents(a),e.processEventQueue()}var e=(this||self,a("5a")),f={handleTopLevel:function(a,b,c,f){var g=e.extractEvents(a,b,c,f);d(g)}};c.exports=f}),c.registerDynamic("bc",[],!0,function(a,b,c){"use strict";var d=(this||self,{currentScrollLeft:0,currentScrollTop:0,refreshScrollValues:function(a){d.currentScrollLeft=a.x,d.currentScrollTop=a.y}});c.exports=d}),c.registerDynamic("5c",["57"],!0,function(a,b,c){"use strict";function d(a,b){if(!f.canUseDOM||b&&!("addEventListener"in document))return!1;var c="on"+a,d=c in document;if(!d){var g=document.createElement("div");g.setAttribute(c,"return;"),d="function"==typeof g[c]}return!d&&e&&"wheel"===a&&(d=document.implementation.hasFeature("Events.wheel","3.0")),d}var e,f=(this||self,a("57"));f.canUseDOM&&(e=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0),c.exports=d}),c.registerDynamic("71",["55","5a","d3","d4","bc","4f","5c","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){return Object.prototype.hasOwnProperty.call(a,p)||(a[p]=n++,l[a[p]]={}),l[a[p]]}var e=a("55"),f=a("5a"),g=a("d3"),h=a("d4"),i=a("bc"),j=a("4f"),k=a("5c"),l={},m=!1,n=0,o={topBlur:"blur",topChange:"change",topClick:"click",topCompositionEnd:"compositionend",topCompositionStart:"compositionstart",topCompositionUpdate:"compositionupdate",topContextMenu:"contextmenu",topCopy:"copy",topCut:"cut",topDoubleClick:"dblclick",topDrag:"drag",topDragEnd:"dragend",topDragEnter:"dragenter",topDragExit:"dragexit",topDragLeave:"dragleave",topDragOver:"dragover",topDragStart:"dragstart",topDrop:"drop",topFocus:"focus",topInput:"input",topKeyDown:"keydown",topKeyPress:"keypress",topKeyUp:"keyup",topMouseDown:"mousedown",topMouseMove:"mousemove",topMouseOut:"mouseout",topMouseOver:"mouseover",topMouseUp:"mouseup",topPaste:"paste",topScroll:"scroll",topSelectionChange:"selectionchange",topTextInput:"textInput",topTouchCancel:"touchcancel",topTouchEnd:"touchend",topTouchMove:"touchmove",topTouchStart:"touchstart",topWheel:"wheel"},p="_reactListenersID"+String(Math.random()).slice(2),q=j({},h,{ReactEventListener:null,injection:{injectReactEventListener:function(a){a.setHandleTopLevel(q.handleTopLevel),q.ReactEventListener=a}},setEnabled:function(a){q.ReactEventListener&&q.ReactEventListener.setEnabled(a)},isEnabled:function(){return!(!q.ReactEventListener||!q.ReactEventListener.isEnabled())},listenTo:function(a,b){for(var c=b,f=d(c),h=g.registrationNameDependencies[a],i=e.topLevelTypes,j=0,l=h.length;j<l;j++){var m=h[j];f.hasOwnProperty(m)&&f[m]||(m===i.topWheel?k("wheel")?q.ReactEventListener.trapBubbledEvent(i.topWheel,"wheel",c):k("mousewheel")?q.ReactEventListener.trapBubbledEvent(i.topWheel,"mousewheel",c):q.ReactEventListener.trapBubbledEvent(i.topWheel,"DOMMouseScroll",c):m===i.topScroll?k("scroll",!0)?q.ReactEventListener.trapCapturedEvent(i.topScroll,"scroll",c):q.ReactEventListener.trapBubbledEvent(i.topScroll,"scroll",q.ReactEventListener.WINDOW_HANDLE):m===i.topFocus||m===i.topBlur?(k("focus",!0)?(q.ReactEventListener.trapCapturedEvent(i.topFocus,"focus",c),q.ReactEventListener.trapCapturedEvent(i.topBlur,"blur",c)):k("focusin")&&(q.ReactEventListener.trapBubbledEvent(i.topFocus,"focusin",c),q.ReactEventListener.trapBubbledEvent(i.topBlur,"focusout",c)),f[i.topBlur]=!0,f[i.topFocus]=!0):o.hasOwnProperty(m)&&q.ReactEventListener.trapBubbledEvent(m,o[m],c),f[m]=!0)}},trapBubbledEvent:function(a,b,c){return q.ReactEventListener.trapBubbledEvent(a,b,c)},trapCapturedEvent:function(a,b,c){return q.ReactEventListener.trapCapturedEvent(a,b,c)},ensureScrollValueMonitoring:function(){if(!m){var a=i.refreshScrollValues;q.ReactEventListener.monitorScrollValue(a),m=!0}},eventNameDispatchConfigs:f.eventNameDispatchConfigs,registrationNameModules:f.registrationNameModules,putListener:f.putListener,getListener:f.getListener,deleteListener:f.deleteListener,deleteAllListeners:f.deleteAllListeners});c.exports=q}(a("49"))}),c.registerDynamic("a7",[],!0,function(a,b,c){"use strict";var d=(this||self,{injectCreateReactRootIndex:function(a){e.createReactRootIndex=a}}),e={createReactRootIndex:null,injection:d};c.exports=e}),c.registerDynamic("86",["a7","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){return n+a.toString(36)}function e(a,b){return a.charAt(b)===n||b===a.length}function f(a){return""===a||a.charAt(0)===n&&a.charAt(a.length-1)!==n}function g(a,b){return 0===b.indexOf(a)&&e(b,a.length)}function h(a){return a?a.substr(0,a.lastIndexOf(n)):""}function i(a,b){if(m(f(a)&&f(b)),m(g(a,b)),a===b)return a;var c,d=a.length+o;for(c=d;c<b.length&&!e(b,c);c++);return b.substr(0,c)}function j(a,b){var c=Math.min(a.length,b.length);if(0===c)return"";for(var d=0,g=0;g<=c;g++)if(e(a,g)&&e(b,g))d=g;else if(a.charAt(g)!==b.charAt(g))break;var h=a.substr(0,d);return m(f(h)),h}function k(a,b,c,d,e,f){a=a||"",b=b||"",m(a!==b);var j=g(b,a);m(j||g(a,b));for(var k=0,l=j?h:i,n=a;;n=l(n,b)){var o;if(e&&n===a||f&&n===b||(o=c(n,j,d)),o===!1||n===b)break;m(k++<p)}}var l=a("a7"),m=a("74"),n=".",o=n.length,p=100,q={createReactRootID:function(){return d(l.createReactRootIndex())},createReactID:function(a,b){return a+b},getReactRootIDFromNodeID:function(a){if(a&&a.charAt(0)===n&&a.length>1){var b=a.indexOf(n,1);return b>-1?a.substr(0,b):a}return null},traverseEnterLeave:function(a,b,c,d,e){var f=j(a,b);f!==a&&k(a,f,c,d,!1,!0),f!==b&&k(f,b,c,e,!0,!1)},traverseTwoPhase:function(a,b,c){a&&(k("",a,b,c,!0,!1),k(a,"",b,c,!1,!0))},traverseAncestors:function(a,b,c){k("",a,b,c,!0,!1)},_getFirstCommonAncestorID:j,_getNextDescendantID:i,isAncestorIDOf:g,SEPARATOR:n};c.exports=q}(a("49"))}),c.registerDynamic("d5",[],!0,function(a,b,c){"use strict";function d(a){for(var b=1,c=0,d=0;d<a.length;d++)b=(b+a.charCodeAt(d))%e,c=(c+b)%e;return b|c<<16}var e=(this||self,65521);c.exports=d}),c.registerDynamic("d1",["d5"],!0,function(a,b,c){"use strict";var d=(this||self,a("d5")),e={CHECKSUM_ATTR_NAME:"data-react-checksum",addChecksumToMarkup:function(a){var b=d(a);return a.replace(">"," "+e.CHECKSUM_ATTR_NAME+'="'+b+'">')},canReuseMarkup:function(a,b){var c=b.getAttribute(e.CHECKSUM_ATTR_NAME);c=c&&parseInt(c,10);var f=d(a);return f===c}};c.exports=e}),c.registerDynamic("c2",["c6","c4","4c","c5","5b","4f","74","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){a!==f.currentlyMountingInstance&&j.enqueueUpdate(a)}function e(a,b){l(null==g.current);var c=i.get(a);return c?c===f.currentlyUnmountingInstance?null:c:null}var f=a("c6"),g=a("c4"),h=a("4c"),i=a("c5"),j=a("5b"),k=a("4f"),l=a("74"),m=(a("48"),{enqueueCallback:function(a,b){l("function"==typeof b);var c=e(a);return c&&c!==f.currentlyMountingInstance?(c._pendingCallbacks?c._pendingCallbacks.push(b):c._pendingCallbacks=[b],void d(c)):null},enqueueCallbackInternal:function(a,b){l("function"==typeof b),a._pendingCallbacks?a._pendingCallbacks.push(b):a._pendingCallbacks=[b],d(a)},enqueueForceUpdate:function(a){var b=e(a,"forceUpdate");b&&(b._pendingForceUpdate=!0,d(b))},enqueueReplaceState:function(a,b){var c=e(a,"replaceState");c&&(c._pendingStateQueue=[b],c._pendingReplaceState=!0,d(c))},enqueueSetState:function(a,b){var c=e(a,"setState");if(c){var f=c._pendingStateQueue||(c._pendingStateQueue=[]);f.push(b),d(c)}},enqueueSetProps:function(a,b){var c=e(a,"setProps");if(c){l(c._isTopLevel);var f=c._pendingElement||c._currentElement,g=k({},f.props,b);c._pendingElement=h.cloneAndReplaceProps(f,g),d(c)}},enqueueReplaceProps:function(a,b){var c=e(a,"replaceProps");if(c){l(c._isTopLevel);var f=c._pendingElement||c._currentElement;c._pendingElement=h.cloneAndReplaceProps(f,b),d(c)}},enqueueElementInternal:function(a,b){a._pendingElement=b,d(a)}});c.exports=m}(a("49"))}),c.registerDynamic("d6",["d7"],!0,function(a,b,c){function d(a){return e(a)&&3==a.nodeType}var e=(this||self,a("d7"));c.exports=d}),c.registerDynamic("ae",["d6"],!0,function(a,b,c){function d(a,b){return!(!a||!b)&&(a===b||!e(a)&&(e(b)?d(a,b.parentNode):a.contains?a.contains(b):!!a.compareDocumentPosition&&!!(16&a.compareDocumentPosition(b))))}var e=(this||self,a("d6"));c.exports=d}),c.registerDynamic("d8",[],!0,function(a,b,c){"use strict";function d(a){return a?a.nodeType===e?a.documentElement:a.firstChild:null}var e=(this||self,9);c.exports=d}),c.registerDynamic("a3",["74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("74"),e=!1,f={unmountIDFromEnvironment:null,replaceNodeWithMarkupByID:null,processChildrenUpdates:null,injection:{injectEnvironment:function(a){d(!e),f.unmountIDFromEnvironment=a.unmountIDFromEnvironment,f.replaceNodeWithMarkupByID=a.replaceNodeWithMarkupByID,f.processChildrenUpdates=a.processChildrenUpdates,e=!0}}};c.exports=f}(a("49"))}),c.registerDynamic("c6",["49"],!0,function(a,b,c){this||self;!function(a){"use strict";var b={currentlyMountingInstance:null,currentlyUnmountingInstance:null};c.exports=b}(a("49"))}),c.registerDynamic("a9",["45","4f","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(){this._callbacks=null,this._contexts=null}var e=a("45"),f=a("4f"),g=a("74");f(d.prototype,{enqueue:function(a,b){this._callbacks=this._callbacks||[],this._contexts=this._contexts||[],this._callbacks.push(a),this._contexts.push(b)},notifyAll:function(){var a=this._callbacks,b=this._contexts;if(a){g(a.length===b.length),this._callbacks=null,this._contexts=null;for(var c=0,d=a.length;c<d;c++)a[c].call(b[c]);a.length=0,b.length=0}},reset:function(){this._callbacks=null,this._contexts=null},destructor:function(){this.reset()}}),e.addPoolingTo(d),c.exports=d}(a("49"))}),c.registerDynamic("45",["74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("74"),e=function(a){var b=this;if(b.instancePool.length){var c=b.instancePool.pop();return b.call(c,a),c}return new b(a)},f=function(a,b){var c=this;if(c.instancePool.length){var d=c.instancePool.pop();return c.call(d,a,b),d}return new c(a,b)},g=function(a,b,c){var d=this;if(d.instancePool.length){var e=d.instancePool.pop();return d.call(e,a,b,c),e}return new d(a,b,c)},h=function(a,b,c,d,e){var f=this;if(f.instancePool.length){var g=f.instancePool.pop();return f.call(g,a,b,c,d,e),g}return new f(a,b,c,d,e)},i=function(a){var b=this;d(a instanceof b),a.destructor&&a.destructor(),b.instancePool.length<b.poolSize&&b.instancePool.push(a)},j=10,k=e,l=function(a,b){var c=a;return c.instancePool=[],c.getPooled=b||k,c.poolSize||(c.poolSize=j),c.release=i,c},m={addPoolingTo:l,oneArgumentPooler:e,twoArgumentPooler:f,threeArgumentPooler:g,fiveArgumentPooler:h};c.exports=m}(a("49"))}),c.registerDynamic("9b",["49"],!0,function(a,b,c){this||self;!function(a){"use strict";function b(a,b,c){return c}var d={enableMeasure:!1,storedMeasure:b,measureMethods:function(a,b,c){},measure:function(a,b,c){return c},injection:{injectMeasure:function(a){d.storedMeasure=a}}};c.exports=d}(a("49"))}),c.registerDynamic("d9",["74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("74"),e={isValidOwner:function(a){return!(!a||"function"!=typeof a.attachRef||"function"!=typeof a.detachRef)},addComponentAsRefTo:function(a,b,c){d(e.isValidOwner(c)),c.attachRef(b,a)},removeComponentAsRefFrom:function(a,b,c){d(e.isValidOwner(c)),c.getPublicInstance().refs[b]===a.getPublicInstance()&&c.detachRef(b)}};c.exports=e}(a("49"))}),c.registerDynamic("da",["d9","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b,c){"function"==typeof a?a(b.getPublicInstance()):f.addComponentAsRefTo(b,a,c)}function e(a,b,c){"function"==typeof a?a(null):f.removeComponentAsRefFrom(b,a,c)}var f=a("d9"),g={};g.attachRefs=function(a,b){var c=b.ref;null!=c&&d(c,a,b._owner)},g.shouldUpdateRefs=function(a,b){return b._owner!==a._owner||b.ref!==a.ref},g.detachRefs=function(a,b){var c=b.ref;null!=c&&e(c,a,b._owner)},c.exports=g}(a("49"))}),c.registerDynamic("46",["4c","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=(a("4c"),a("48"),{create:function(a){return a},extract:function(a){return a},extractIfFragment:function(a){return a}});c.exports=d}(a("49"))}),c.registerDynamic("6d",["74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("74"),e=function(a){var b,c={};d(a instanceof Object&&!Array.isArray(a));for(b in a)a.hasOwnProperty(b)&&(c[b]=b);return c};c.exports=e}(a("49"))}),c.registerDynamic("c7",["6d"],!0,function(a,b,c){"use strict";var d=(this||self,a("6d")),e=d({prop:null,context:null,childContext:null});c.exports=e}),c.registerDynamic("c8",["49"],!0,function(a,b,c){this||self;!function(a){"use strict";var b={};c.exports=b}(a("49"))}),c.registerDynamic("9c",[],!0,function(a,b,c){"use strict";function d(a){var b=a&&(e&&a[e]||a[f]);if("function"==typeof b)return b}var e=(this||self,"function"==typeof Symbol&&Symbol.iterator),f="@@iterator";c.exports=d}),c.registerDynamic("4d",["4c","46","c7","c8","c4","a6","9c","74","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(){if(s.current){var a=s.current.getName();if(a)return" Check the render method of `"+a+"`."}return""}function e(a){var b=a&&a.getPublicInstance();if(b){var c=b.constructor;if(c)return c.displayName||c.name||void 0}}function f(){var a=s.current;return a&&e(a)||void 0}function g(a,b){a._store.validated||null!=a.key||(a._store.validated=!0,i('Each child in an array or iterator should have a unique "key" prop.',a,b))}function h(a,b,c){y.test(a)&&i("Child objects should have non-numeric keys so ordering is preserved.",b,c)}function i(a,b,c){var d=f(),g="string"==typeof c?c:c.displayName||c.name,h=d||g,i=w[a]||(w[a]={});if(!i.hasOwnProperty(h)){i[h]=!0;var j="";if(b&&b._owner&&b._owner!==s.current){var k=e(b._owner);j=" It was passed a child from "+k+"."}}}function j(a,b){if(Array.isArray(a))for(var c=0;c<a.length;c++){var d=a[c];p.isValidElement(d)&&g(d,b)}else if(p.isValidElement(a))a._store.validated=!0;else if(a){var e=u(a);if(e){if(e!==a.entries)for(var f,i=e.call(a);!(f=i.next()).done;)p.isValidElement(f.value)&&g(f.value,b)}else if("object"==typeof a){var j=q.extractIfFragment(a);for(var k in j)j.hasOwnProperty(k)&&h(k,j[k],b)}}}function k(a,b,c,e){for(var f in b)if(b.hasOwnProperty(f)){var g;try{v("function"==typeof b[f]),g=b[f](c,f,a,e)}catch(a){g=a}if(g instanceof Error&&!(g.message in x)){x[g.message]=!0;d(this)}}}function l(a,b){var c=b.type,d="string"==typeof c?c:c.displayName,e=b._owner?b._owner.getPublicInstance().constructor.displayName:null,f=a+"|"+d+"|"+e;if(!z.hasOwnProperty(f)){z[f]=!0;var g="";d&&(g=" <"+d+" />");var h="";e&&(h=" The element was created by "+e+".")}}function m(a,b){return a!==a?b!==b:0===a&&0===b?1/a===1/b:a===b}function n(a){if(a._store){var b=a._store.originalProps,c=a.props;for(var d in c)c.hasOwnProperty(d)&&(b.hasOwnProperty(d)&&m(b[d],c[d])||(l(d,a),b[d]=c[d]))}}function o(a){if(null!=a.type){var b=t.getComponentClassForElement(a),c=b.displayName||b.name;b.propTypes&&k(c,b.propTypes,a.props,r.prop),"function"==typeof b.getDefaultProps}}var p=a("4c"),q=a("46"),r=a("c7"),s=(a("c8"),a("c4")),t=a("a6"),u=a("9c"),v=a("74"),w=(a("48"),{}),x={},y=/^\d+$/,z={},A={checkAndWarnForMutatedProps:n,createElement:function(a,b,c){var d=p.createElement.apply(this,arguments);if(null==d)return d;for(var e=2;e<arguments.length;e++)j(arguments[e],a);return o(d),d},createFactory:function(a){var b=A.createElement.bind(null,a);return b.type=a,b},cloneElement:function(a,b,c){for(var d=p.cloneElement.apply(this,arguments),e=2;e<arguments.length;e++)j(arguments[e],d.type);return o(d),d}};c.exports=A}(a("49"))}),c.registerDynamic("9f",["da","4d","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(){e.attachRefs(this,this._currentElement)}var e=a("da"),f=(a("4d"),{mountComponent:function(a,b,c,e){var f=a.mountComponent(b,c,e);return c.getReactMountReady().enqueue(d,a),f},unmountComponent:function(a){e.detachRefs(a,a._currentElement),a.unmountComponent()},receiveComponent:function(a,b,c,f){var g=a._currentElement;if(b!==g||null==b._owner){var h=e.shouldUpdateRefs(g,b);h&&e.detachRefs(a,g),a.receiveComponent(b,c,f),h&&c.getReactMountReady().enqueue(d,a)}},performUpdateIfNecessary:function(a,b){a.performUpdateIfNecessary(b)}});c.exports=f}(a("49"))}),c.registerDynamic("68",["74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("74"),e={reinitializeTransaction:function(){this.transactionWrappers=this.getTransactionWrappers(),this.wrapperInitData?this.wrapperInitData.length=0:this.wrapperInitData=[],this._isInTransaction=!1},_isInTransaction:!1,getTransactionWrappers:null,isInTransaction:function(){return!!this._isInTransaction},perform:function(a,b,c,e,f,g,h,i){d(!this.isInTransaction());var j,k;try{this._isInTransaction=!0,j=!0,this.initializeAll(0),k=a.call(b,c,e,f,g,h,i),j=!1}finally{try{if(j)try{this.closeAll(0)}catch(a){}else this.closeAll(0)}finally{this._isInTransaction=!1}}return k},initializeAll:function(a){for(var b=this.transactionWrappers,c=a;c<b.length;c++){var d=b[c];try{this.wrapperInitData[c]=f.OBSERVED_ERROR,this.wrapperInitData[c]=d.initialize?d.initialize.call(this):null}finally{if(this.wrapperInitData[c]===f.OBSERVED_ERROR)try{this.initializeAll(c+1)}catch(a){}}}},closeAll:function(a){d(this.isInTransaction());for(var b=this.transactionWrappers,c=a;c<b.length;c++){var e,g=b[c],h=this.wrapperInitData[c];try{e=!0,h!==f.OBSERVED_ERROR&&g.close&&g.close.call(this,h),e=!1}finally{if(e)try{this.closeAll(c+1)}catch(a){}}}this.wrapperInitData.length=0}},f={Mixin:e,OBSERVED_ERROR:{}};c.exports=f}(a("49"))}),c.registerDynamic("5b",["a9","45","c4","9b","9f","68","4f","74","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(){q(A.ReactReconcileTransaction&&u)}function e(){this.reinitializeTransaction(),this.dirtyComponentsLength=null,this.callbackQueue=k.getPooled(),this.reconcileTransaction=A.ReactReconcileTransaction.getPooled()}function f(a,b,c,e,f){d(),u.batchedUpdates(a,b,c,e,f)}function g(a,b){return a._mountOrder-b._mountOrder}function h(a){var b=a.dirtyComponentsLength;q(b===r.length),r.sort(g);for(var c=0;c<b;c++){var d=r[c],e=d._pendingCallbacks;if(d._pendingCallbacks=null,n.performUpdateIfNecessary(d,a.reconcileTransaction),e)for(var f=0;f<e.length;f++)a.callbackQueue.enqueue(e[f],d.getPublicInstance())}}function i(a){return d(),u.isBatchingUpdates?void r.push(a):void u.batchedUpdates(i,a)}function j(a,b){q(u.isBatchingUpdates),s.enqueue(a,b),t=!0}var k=a("a9"),l=a("45"),m=(a("c4"),a("9b")),n=a("9f"),o=a("68"),p=a("4f"),q=a("74"),r=(a("48"),[]),s=k.getPooled(),t=!1,u=null,v={initialize:function(){this.dirtyComponentsLength=r.length},close:function(){this.dirtyComponentsLength!==r.length?(r.splice(0,this.dirtyComponentsLength),y()):r.length=0}},w={initialize:function(){this.callbackQueue.reset()},close:function(){this.callbackQueue.notifyAll()}},x=[v,w];p(e.prototype,o.Mixin,{getTransactionWrappers:function(){return x},destructor:function(){this.dirtyComponentsLength=null,k.release(this.callbackQueue),this.callbackQueue=null,A.ReactReconcileTransaction.release(this.reconcileTransaction),this.reconcileTransaction=null},perform:function(a,b,c){return o.Mixin.perform.call(this,this.reconcileTransaction.perform,this.reconcileTransaction,a,b,c)}}),l.addPoolingTo(e);var y=function(){for(;r.length||t;){if(r.length){var a=e.getPooled();a.perform(h,null,a),e.release(a)}if(t){t=!1;var b=s;s=k.getPooled(),b.notifyAll(),k.release(b)}}};y=m.measure("ReactUpdates","flushBatchedUpdates",y);var z={injectReconcileTransaction:function(a){q(a),A.ReactReconcileTransaction=a},injectBatchingStrategy:function(a){q(a),q("function"==typeof a.batchedUpdates),q("boolean"==typeof a.isBatchingUpdates),u=a}},A={ReactReconcileTransaction:null,batchedUpdates:f,enqueueUpdate:i,flushBatchedUpdates:y,injection:z,asap:j};c.exports=A}(a("49"))});c.registerDynamic("db",["a3","dc","c4","4c","4d","c5","c6","a6","9b","c7","c8","9f","5b","4f","d2","74","a1","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){var b=a._currentElement._owner||null;if(b){var c=b.getName();if(c)return" Check the render method of `"+c+"`."}return""}var e=a("a3"),f=a("dc"),g=a("c4"),h=a("4c"),i=(a("4d"),
18
- a("c5")),j=a("c6"),k=a("a6"),l=a("9b"),m=a("c7"),n=(a("c8"),a("9f")),o=a("5b"),p=a("4f"),q=a("d2"),r=a("74"),s=a("a1"),t=(a("48"),1),u={construct:function(a){this._currentElement=a,this._rootNodeID=null,this._instance=null,this._pendingElement=null,this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1,this._renderedComponent=null,this._context=null,this._mountOrder=0,this._isTopLevel=!1,this._pendingCallbacks=null},mountComponent:function(a,b,c){this._context=c,this._mountOrder=t++,this._rootNodeID=a;var d=this._processProps(this._currentElement.props),e=this._processContext(this._currentElement._context),f=k.getComponentClassForElement(this._currentElement),g=new f(d,e);g.props=d,g.context=e,g.refs=q,this._instance=g,i.set(g,this);var h=g.state;void 0===h&&(g.state=h=null),r("object"==typeof h&&!Array.isArray(h)),this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1;var l,m,o=j.currentlyMountingInstance;j.currentlyMountingInstance=this;try{g.componentWillMount&&(g.componentWillMount(),this._pendingStateQueue&&(g.state=this._processPendingState(g.props,g.context))),l=this._getValidatedChildContext(c),m=this._renderValidatedComponent(l)}finally{j.currentlyMountingInstance=o}this._renderedComponent=this._instantiateReactComponent(m,this._currentElement.type);var p=n.mountComponent(this._renderedComponent,a,b,this._mergeChildContext(c,l));return g.componentDidMount&&b.getReactMountReady().enqueue(g.componentDidMount,g),p},unmountComponent:function(){var a=this._instance;if(a.componentWillUnmount){var b=j.currentlyUnmountingInstance;j.currentlyUnmountingInstance=this;try{a.componentWillUnmount()}finally{j.currentlyUnmountingInstance=b}}n.unmountComponent(this._renderedComponent),this._renderedComponent=null,this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1,this._pendingCallbacks=null,this._pendingElement=null,this._context=null,this._rootNodeID=null,i.remove(a)},_setPropsInternal:function(a,b){var c=this._pendingElement||this._currentElement;this._pendingElement=h.cloneAndReplaceProps(c,p({},c.props,a)),o.enqueueUpdate(this,b)},_maskContext:function(a){var b=null;if("string"==typeof this._currentElement.type)return q;var c=this._currentElement.type.contextTypes;if(!c)return q;b={};for(var d in c)b[d]=a[d];return b},_processContext:function(a){var b=this._maskContext(a);return b},_getValidatedChildContext:function(a){var b=this._instance,c=b.getChildContext&&b.getChildContext();if(c){r("object"==typeof b.constructor.childContextTypes);for(var d in c)r(d in b.constructor.childContextTypes);return c}return null},_mergeChildContext:function(a,b){return b?p({},a,b):a},_processProps:function(a){return a},_checkPropTypes:function(a,b,c){var e=this.getName();for(var f in a)if(a.hasOwnProperty(f)){var g;try{r("function"==typeof a[f]),g=a[f](b,f,e,c)}catch(a){g=a}if(g instanceof Error){d(this);c===m.prop}}},receiveComponent:function(a,b,c){var d=this._currentElement,e=this._context;this._pendingElement=null,this.updateComponent(b,d,a,e,c)},performUpdateIfNecessary:function(a){null!=this._pendingElement&&n.receiveComponent(this,this._pendingElement||this._currentElement,a,this._context),(null!==this._pendingStateQueue||this._pendingForceUpdate)&&this.updateComponent(a,this._currentElement,this._currentElement,this._context,this._context)},_warnIfContextsDiffer:function(a,b){a=this._maskContext(a),b=this._maskContext(b);for(var c=Object.keys(b).sort(),d=(this.getName()||"ReactCompositeComponent",0);d<c.length;d++){c[d]}},updateComponent:function(a,b,c,d,e){var f=this._instance,g=f.context,h=f.props;b!==c&&(g=this._processContext(c._context),h=this._processProps(c.props),f.componentWillReceiveProps&&f.componentWillReceiveProps(h,g));var i=this._processPendingState(h,g),j=this._pendingForceUpdate||!f.shouldComponentUpdate||f.shouldComponentUpdate(h,i,g);j?(this._pendingForceUpdate=!1,this._performComponentUpdate(c,h,i,g,a,e)):(this._currentElement=c,this._context=e,f.props=h,f.state=i,f.context=g)},_processPendingState:function(a,b){var c=this._instance,d=this._pendingStateQueue,e=this._pendingReplaceState;if(this._pendingReplaceState=!1,this._pendingStateQueue=null,!d)return c.state;if(e&&1===d.length)return d[0];for(var f=p({},e?d[0]:c.state),g=e?1:0;g<d.length;g++){var h=d[g];p(f,"function"==typeof h?h.call(c,f,a,b):h)}return f},_performComponentUpdate:function(a,b,c,d,e,f){var g=this._instance,h=g.props,i=g.state,j=g.context;g.componentWillUpdate&&g.componentWillUpdate(b,c,d),this._currentElement=a,this._context=f,g.props=b,g.state=c,g.context=d,this._updateRenderedComponent(e,f),g.componentDidUpdate&&e.getReactMountReady().enqueue(g.componentDidUpdate.bind(g,h,i,j),g)},_updateRenderedComponent:function(a,b){var c=this._renderedComponent,d=c._currentElement,e=this._getValidatedChildContext(),f=this._renderValidatedComponent(e);if(s(d,f))n.receiveComponent(c,f,a,this._mergeChildContext(b,e));else{var g=this._rootNodeID,h=c._rootNodeID;n.unmountComponent(c),this._renderedComponent=this._instantiateReactComponent(f,this._currentElement.type);var i=n.mountComponent(this._renderedComponent,g,a,this._mergeChildContext(b,e));this._replaceNodeWithMarkupByID(h,i)}},_replaceNodeWithMarkupByID:function(a,b){e.replaceNodeWithMarkupByID(a,b)},_renderValidatedComponentWithoutOwnerOrContext:function(){var a=this._instance,b=a.render();return b},_renderValidatedComponent:function(a){var b,c=f.current;f.current=this._mergeChildContext(this._currentElement._context,a),g.current=this;try{b=this._renderValidatedComponentWithoutOwnerOrContext()}finally{f.current=c,g.current=null}return r(null===b||b===!1||h.isValidElement(b)),b},attachRef:function(a,b){var c=this.getPublicInstance(),d=c.refs===q?c.refs={}:c.refs;d[a]=b.getPublicInstance()},detachRef:function(a){var b=this.getPublicInstance().refs;delete b[a]},getName:function(){var a=this._currentElement.type,b=this._instance&&this._instance.constructor;return a.displayName||b&&b.displayName||a.name||b&&b.name||null},getPublicInstance:function(){return this._instance},_instantiateReactComponent:null};l.measureMethods(u,"ReactCompositeComponent",{mountComponent:"mountComponent",updateComponent:"updateComponent",_renderValidatedComponent:"_renderValidatedComponent"});var v={Mixin:u};c.exports=v}(a("49"))});c.registerDynamic("c5",[],!0,function(a,b,c){"use strict";var d=(this||self,{remove:function(a){a._reactInternalInstance=void 0},get:function(a){return a._reactInternalInstance},has:function(a){return void 0!==a._reactInternalInstance},set:function(a,b){a._reactInternalInstance=b}});c.exports=d}),c.registerDynamic("a5",["4c","c5","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){k[a]=!0}function e(a){delete k[a]}function f(a){return!!k[a]}var g,h=a("4c"),i=a("c5"),j=a("74"),k={},l={injectEmptyComponent:function(a){g=h.createFactory(a)}},m=function(){};m.prototype.componentDidMount=function(){var a=i.get(this);a&&d(a._rootNodeID)},m.prototype.componentWillUnmount=function(){var a=i.get(this);a&&e(a._rootNodeID)},m.prototype.render=function(){return j(g),g()};var n=h.createElement(m),o={emptyElement:n,injection:l,isNullComponentID:f};c.exports=o}(a("49"))}),c.registerDynamic("a6",["4f","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){if("function"==typeof a.type)return a.type;var b=a.type,c=l[b];return null==c&&(l[b]=c=j(b)),c}function e(a){return i(k),new k(a.type,a.props)}function f(a){return new m(a)}function g(a){return a instanceof m}var h=a("4f"),i=a("74"),j=null,k=null,l={},m=null,n={injectGenericComponentClass:function(a){k=a},injectTextComponentClass:function(a){m=a},injectComponentClasses:function(a){h(l,a)},injectAutoWrapper:function(a){j=a}},o={getComponentClassForElement:d,createInternalComponent:e,createInstanceForText:f,isTextComponent:g,injection:n};c.exports=o}(a("49"))}),c.registerDynamic("a0",["db","a5","a6","4f","74","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){return"function"==typeof a&&"undefined"!=typeof a.prototype&&"function"==typeof a.prototype.mountComponent&&"function"==typeof a.prototype.receiveComponent}function e(a,b){var c;if(null!==a&&a!==!1||(a=g.emptyElement),"object"==typeof a){var e=a;c=b===e.type&&"string"==typeof e.type?h.createInternalComponent(e):d(e.type)?new e.type(e):new k}else"string"==typeof a||"number"==typeof a?c=h.createInstanceForText(a):j(!1);return c.construct(a),c._mountIndex=0,c._mountImage=null,c}var f=a("db"),g=a("a5"),h=a("a6"),i=a("4f"),j=a("74"),k=(a("48"),function(){});i(k.prototype,f.Mixin,{_instantiateReactComponent:e}),c.exports=e}(a("49"))}),c.registerDynamic("96",["57","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("57"),e=/^[ \r\n\t\f]/,f=/<(!--|link|noscript|meta|script|style)[ \r\n\t\f\/>]/,g=function(a,b){a.innerHTML=b};if("undefined"!=typeof MSApp&&MSApp.execUnsafeLocalFunction&&(g=function(a,b){MSApp.execUnsafeLocalFunction(function(){a.innerHTML=b})}),d.canUseDOM){var h=document.createElement("div");h.innerHTML=" ",""===h.innerHTML&&(g=function(a,b){if(a.parentNode&&a.parentNode.replaceChild(a,a),e.test(b)||"<"===b[0]&&f.test(b)){a.innerHTML="\ufeff"+b;var c=a.firstChild;1===c.data.length?a.removeChild(c):c.deleteData(0,1)}else a.innerHTML=b})}c.exports=g}(a("49"))}),c.registerDynamic("a1",["48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b){if(null!=a&&null!=b){var c=typeof a,d=typeof b;if("string"===c||"number"===c)return"string"===d||"number"===d;if("object"===d&&a.type===b.type&&a.key===b.key){var e=a._owner===b._owner;return e}}return!1}a("48");c.exports=d}(a("49"))}),c.registerDynamic("62",["64","71","c4","4c","4d","a5","86","c5","d1","9b","9f","c2","5b","d2","ae","d8","a0","74","96","a1","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b){for(var c=Math.min(a.length,b.length),d=0;d<c;d++)if(a.charAt(d)!==b.charAt(d))return d;return a.length===b.length?-1:c}function e(a){var b=D(a);return b&&R.getID(b)}function f(a){var b=g(a);if(b)if(K.hasOwnProperty(b)){var c=K[b];c!==a&&(F(!k(c,b)),K[b]=a)}else K[b]=a;return b}function g(a){return a&&a.getAttribute&&a.getAttribute(J)||""}function h(a,b){var c=g(a);c!==b&&delete K[c],a.setAttribute(J,b),K[b]=a}function i(a){return K.hasOwnProperty(a)&&k(K[a],a)||(K[a]=R.findReactNodeByID(a)),K[a]}function j(a){var b=v.get(a)._rootNodeID;return t.isNullComponentID(b)?null:(K.hasOwnProperty(b)&&k(K[b],b)||(K[b]=R.findReactNodeByID(b)),K[b])}function k(a,b){if(a){F(g(a)===b);var c=R.findReactContainerForID(b);if(c&&C(c,a))return!0}return!1}function l(a){delete K[a]}function m(a){var b=K[a];return!(!b||!k(b,a))&&void(Q=b)}function n(a){Q=null,u.traverseAncestors(a,m);var b=Q;return Q=null,b}function o(a,b,c,d,e){var f=y.mountComponent(a,b,d,B);a._isTopLevel=!0,R._mountImageIntoNode(f,c,e)}function p(a,b,c,d){var e=A.ReactReconcileTransaction.getPooled();e.perform(o,null,a,b,c,e,d),A.ReactReconcileTransaction.release(e)}var q=a("64"),r=a("71"),s=(a("c4"),a("4c")),t=(a("4d"),a("a5")),u=a("86"),v=a("c5"),w=a("d1"),x=a("9b"),y=a("9f"),z=a("c2"),A=a("5b"),B=a("d2"),C=a("ae"),D=a("d8"),E=a("a0"),F=a("74"),G=a("96"),H=a("a1"),I=(a("48"),u.SEPARATOR),J=q.ID_ATTRIBUTE_NAME,K={},L=1,M=9,N={},O={},P=[],Q=null,R={_instancesByReactRootID:N,scrollMonitor:function(a,b){b()},_updateRootComponent:function(a,b,c,d){return R.scrollMonitor(c,function(){z.enqueueElementInternal(a,b),d&&z.enqueueCallbackInternal(a,d)}),a},_registerComponent:function(a,b){F(b&&(b.nodeType===L||b.nodeType===M)),r.ensureScrollValueMonitoring();var c=R.registerContainer(b);return N[c]=a,c},_renderNewRootComponent:function(a,b,c){var d=E(a,null),e=R._registerComponent(d,b);return A.batchedUpdates(p,d,e,b,c),d},render:function(a,b,c){F(s.isValidElement(a));var d=N[e(b)];if(d){var f=d._currentElement;if(H(f,a))return R._updateRootComponent(d,a,b,c).getPublicInstance();R.unmountComponentAtNode(b)}var g=D(b),h=g&&R.isRenderedByReact(g),i=h&&!d,j=R._renderNewRootComponent(a,b,i).getPublicInstance();return c&&c.call(j),j},constructAndRenderComponent:function(a,b,c){var d=s.createElement(a,b);return R.render(d,c)},constructAndRenderComponentByID:function(a,b,c){var d=document.getElementById(c);return F(d),R.constructAndRenderComponent(a,b,d)},registerContainer:function(a){var b=e(a);return b&&(b=u.getReactRootIDFromNodeID(b)),b||(b=u.createReactRootID()),O[b]=a,b},unmountComponentAtNode:function(a){F(a&&(a.nodeType===L||a.nodeType===M));var b=e(a),c=N[b];return!!c&&(R.unmountComponentFromNode(c,a),delete N[b],delete O[b],!0)},unmountComponentFromNode:function(a,b){for(y.unmountComponent(a),b.nodeType===M&&(b=b.documentElement);b.lastChild;)b.removeChild(b.lastChild)},findReactContainerForID:function(a){var b=u.getReactRootIDFromNodeID(a),c=O[b];return c},findReactNodeByID:function(a){var b=R.findReactContainerForID(a);return R.findComponentRoot(b,a)},isRenderedByReact:function(a){if(1!==a.nodeType)return!1;var b=R.getID(a);return!!b&&b.charAt(0)===I},getFirstReactDOM:function(a){for(var b=a;b&&b.parentNode!==b;){if(R.isRenderedByReact(b))return b;b=b.parentNode}return null},findComponentRoot:function(a,b){var c=P,d=0,e=n(b)||a;for(c[0]=e.firstChild,c.length=1;d<c.length;){for(var f,g=c[d++];g;){var h=R.getID(g);h?b===h?f=g:u.isAncestorIDOf(h,b)&&(c.length=d=0,c.push(g.firstChild)):c.push(g.firstChild),g=g.nextSibling}if(f)return c.length=0,f}c.length=0,F(!1)},_mountImageIntoNode:function(a,b,c){if(F(b&&(b.nodeType===L||b.nodeType===M)),c){var e=D(b);if(w.canReuseMarkup(a,e))return;var f=e.getAttribute(w.CHECKSUM_ATTR_NAME);e.removeAttribute(w.CHECKSUM_ATTR_NAME);var g=e.outerHTML;e.setAttribute(w.CHECKSUM_ATTR_NAME,f);var h=d(a,g);" (client) "+a.substring(h-20,h+20)+"\n (server) "+g.substring(h-20,h+20);F(b.nodeType!==M)}F(b.nodeType!==M),G(b,a)},getReactRootID:e,getID:f,setID:h,getNode:i,getNodeFromInstance:j,purgeID:l};x.measureMethods(R,"ReactMount",{_renderNewRootComponent:"_renderNewRootComponent",_mountImageIntoNode:"_mountImageIntoNode"}),c.exports=R}(a("49"))}),c.registerDynamic("d7",[],!0,function(a,b,c){function d(a){return!(!a||!("function"==typeof Node?a instanceof Node:"object"==typeof a&&"number"==typeof a.nodeType&&"string"==typeof a.nodeName))}this||self;c.exports=d}),c.registerDynamic("7d",["c4","c5","62","74","d7","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){return null==a?null:h(a)?a:e.has(a)?f.getNodeFromInstance(a):(g(null==a.render||"function"!=typeof a.render),void g(!1))}var e=(a("c4"),a("c5")),f=a("62"),g=a("74"),h=a("d7");a("48");c.exports=d}(a("49"))}),c.registerDynamic("d2",["49"],!0,function(a,b,c){this||self;!function(a){"use strict";var b={};c.exports=b}(a("49"))}),c.registerDynamic("dc",["4f","d2","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("4f"),e=a("d2"),f=(a("48"),{current:e,withContext:function(a,b){var c,e=f.current;f.current=d({},e,a);try{c=b()}finally{f.current=e}return c}});c.exports=f}(a("49"))}),c.registerDynamic("c4",[],!0,function(a,b,c){"use strict";var d=(this||self,{current:null});c.exports=d}),c.registerDynamic("4f",[],!0,function(a,b,c){"use strict";function d(a,b){if(null==a)throw new TypeError("Object.assign target cannot be null or undefined");for(var c=Object(a),d=Object.prototype.hasOwnProperty,e=1;e<arguments.length;e++){var f=arguments[e];if(null!=f){var g=Object(f);for(var h in g)d.call(g,h)&&(c[h]=g[h])}}return c}this||self;c.exports=d}),c.registerDynamic("66",[],!0,function(a,b,c){function d(a){return function(){return a}}function e(){}this||self;e.thatReturns=d,e.thatReturnsFalse=d(!1),e.thatReturnsTrue=d(!0),e.thatReturnsNull=d(null),e.thatReturnsThis=function(){return this},e.thatReturnsArgument=function(a){return a},c.exports=e}),c.registerDynamic("48",["66","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("66"),e=d;c.exports=e}(a("49"))}),c.registerDynamic("4c",["dc","c4","4f","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("dc"),e=a("c4"),f=a("4f"),g=(a("48"),{key:!0,ref:!0}),h=function(a,b,c,d,e,f){this.type=a,this.key=b,this.ref=c,this._owner=d,this._context=e,this.props=f};h.prototype={_isReactElement:!0},h.createElement=function(a,b,c){var f,i={},j=null,k=null;if(null!=b){k=void 0===b.ref?null:b.ref,j=void 0===b.key?null:""+b.key;for(f in b)b.hasOwnProperty(f)&&!g.hasOwnProperty(f)&&(i[f]=b[f])}var l=arguments.length-2;if(1===l)i.children=c;else if(l>1){for(var m=Array(l),n=0;n<l;n++)m[n]=arguments[n+2];i.children=m}if(a&&a.defaultProps){var o=a.defaultProps;for(f in o)"undefined"==typeof i[f]&&(i[f]=o[f])}return new h(a,j,k,e.current,d.current,i)},h.createFactory=function(a){var b=h.createElement.bind(null,a);return b.type=a,b},h.cloneAndReplaceProps=function(a,b){var c=new h(a.type,a.key,a.ref,a._owner,a._context,b);return c},h.cloneElement=function(a,b,c){var d,i=f({},a.props),j=a.key,k=a.ref,l=a._owner;if(null!=b){void 0!==b.ref&&(k=b.ref,l=e.current),void 0!==b.key&&(j=""+b.key);for(d in b)b.hasOwnProperty(d)&&!g.hasOwnProperty(d)&&(i[d]=b[d])}var m=arguments.length-2;if(1===m)i.children=c;else if(m>1){for(var n=Array(m),o=0;o<m;o++)n[o]=arguments[o+2];i.children=n}return new h(a.type,j,k,l,a._context,i)},h.isValidElement=function(a){var b=!(!a||!a._isReactElement);return b},c.exports=h}(a("49"))}),c.registerDynamic("74",["49"],!0,function(a,b,c){this||self;!function(a){"use strict";var b=function(a,b,c,d,e,f,g,h){if(!a){var i;if(void 0===b)i=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var j=[c,d,e,f,g,h],k=0;i=new Error("Invariant Violation: "+b.replace(/%s/g,function(){return j[k++]}))}throw i.framesToPop=1,i}};c.exports=b}(a("49"))}),c.registerDynamic("dd",["4c","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){return f(e.isValidElement(a)),a}var e=a("4c"),f=a("74");c.exports=d}(a("49"))}),c.registerDynamic("57",[],!0,function(a,b,c){"use strict";var d=(this||self,!("undefined"==typeof window||!window.document||!window.document.createElement)),e={canUseDOM:d,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:d&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:d&&!!window.screen,isInWorker:!d};c.exports=e}),c.registerDynamic("de",[],!0,function(a,b,c){function d(){if(!h){h=!0;for(var a,b=g.length;b;){a=g,g=[];for(var c=-1;++c<b;)a[c]();b=g.length}h=!1}}function e(){}var f=(this||self,c.exports={}),g=[],h=!1;f.nextTick=function(a){g.push(a),h||setTimeout(d,0)},f.title="browser",f.browser=!0,f.env={},f.argv=[],f.version="",f.versions={},f.on=e,f.addListener=e,f.once=e,f.off=e,f.removeListener=e,f.removeAllListeners=e,f.emit=e,f.binding=function(a){throw new Error("process.binding is not supported")},f.cwd=function(){return"/"},f.chdir=function(a){throw new Error("process.chdir is not supported")},f.umask=function(){return 0}}),c.registerDynamic("df",["de"],!0,function(a,b,c){this||self;c.exports=a("de")}),c.registerDynamic("e0",["df"],!0,function(a,b,d){this||self;d.exports=c._nodeRequire?process:a("df")}),c.registerDynamic("49",["e0"],!0,function(a,b,c){this||self;c.exports=a("e0")}),c.registerDynamic("e1",["bf","44","c1","6c","dc","c4","4c","4d","4b","7f","ce","86","62","9b","7c","9f","d0","4f","7d","dd","57","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("bf"),e=a("44"),f=a("c1"),g=a("6c"),h=a("dc"),i=a("c4"),j=a("4c"),k=(a("4d"),a("4b")),l=a("7f"),m=a("ce"),n=a("86"),o=a("62"),p=a("9b"),q=a("7c"),r=a("9f"),s=a("d0"),t=a("4f"),u=a("7d"),v=a("dd");m.inject();var w=j.createElement,x=j.createFactory,y=j.cloneElement,z=p.measure("React","render",o.render),A={Children:{map:e.map,forEach:e.forEach,count:e.count,only:v},Component:f,DOM:k,PropTypes:q,initializeTouchEvents:function(a){d.useTouchEvents=a},createClass:g.createClass,createElement:w,cloneElement:y,createFactory:x,createMixin:function(a){return a},constructAndRenderComponent:o.constructAndRenderComponent,constructAndRenderComponentByID:o.constructAndRenderComponentByID,findDOMNode:u,render:z,renderToString:s.renderToString,renderToStaticMarkup:s.renderToStaticMarkup,unmountComponentAtNode:o.unmountComponentAtNode,isValidElement:j.isValidElement,withContext:h.withContext,__spread:t};"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.inject&&__REACT_DEVTOOLS_GLOBAL_HOOK__.inject({CurrentOwner:i,InstanceHandles:n,Mount:o,Reconciler:r,TextComponent:l});A.version="0.13.3",c.exports=A}(a("49"))}),c.registerDynamic("e2",["e1"],!0,function(a,b,c){this||self;c.exports=a("e1")}),c.registerDynamic("19",["e2"],!0,function(a,b,c){this||self;c.exports=a("e2")}),c.register("e3",["12","13","19","1a","1b"],function(a){function b(a,b){e.render(e.createElement(h,{errorData:a,beforeShow:b}),document.getElementById("view"))}var c,d,e,f,g,h;return{setters:[function(a){c=a.default},function(a){d=a.default},function(a){e=a.default},function(a){f=a.default},function(a){g=a.default}],execute:function(){a("default",b),h=function(a){function b(a){d(this,b),f(Object.getPrototypeOf(b.prototype),"constructor",this).call(this,a)}return g(b,a),c(b,[{key:"render",value:function(){return e.createElement("div",{id:"error",ref:"errorModal",className:"modal fade","data-keyboard":"false","data-backdrop":"static"},e.createElement("div",{className:"modal-dialog modal-lg"},e.createElement("div",{className:"modal-content"},e.createElement("div",{className:"modal-header"},e.createElement("h3",null,this.props.errorData.title)),e.createElement("div",{className:"modal-body"},e.createElement("p",{dangerouslySetInnerHTML:{__html:this.props.errorData.message}}),this.props.errorData.more_info&&e.createElement("pre",{className:"pre-scrollable"},this.props.errorData.more_info)))))}},{key:"componentDidMount",value:function(){setTimeout(function(){$(e.findDOMNode(this.refs.errorModal)).modal("show")}.bind(this),this.props.beforeShow||0)}}]),b}(e.Component)}}}),c.register("1",["11","14","15","19","20","a","f","d","1c","1e","1f","2e","e3"],function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t;return{setters:[function(a){b=a},function(a){c=a.default},function(a){d=a.default},function(a){e=a.default},function(a){f=a.default},function(a){},function(a){g=a.default},function(a){h=a.default},function(a){i=a.default},function(a){j=a.default},function(a){k=a.default},function(a){},function(a){l=a.default}],execute:function(){m=function(a,b){function c(a,b){d.append($("<input>").attr("type","hidden").attr("name",a).val(b))}var d=$("<form/>").attr("method","post").attr("action","get_sequence");c("sequence_ids",a),c("database_ids",b),d.appendTo("body").submit().remove()},n=e.createClass({displayName:"Page",render:function(){return e.createElement("div",null,e.createElement("div",{className:"container"},e.createElement(o,{ref:"report"})),e.createElement("canvas",{id:"png-exporter",hidden:!0}))}}),o=e.createClass({displayName:"Report",getInitialState:function(){return this.fetchResults(),this.updateCycle=0,{search_id:"",program:"",program_version:"",submitted_at:"",num_queries:0,queries:[],querydb:[],params:[],stats:[]}},fetchResults:function(){function a(){$.getJSON(location.pathname+".json").complete(function(d){switch(d.status){case 202:var e;e=1===b.length?b[0]:b.shift(),setTimeout(a,e);break;case 200:c.updateState(d.responseJSON);break;case 404:case 400:case 500:l(d.responseJSON)}})}var b=[200,400,800,1200,2e3,3e3,5e3],c=this;a()},updateState:function(a){var b=a.queries;a.veryBig=b.length>250,a.queries=b.splice(0,50),a.num_queries=b.length,this.setState(a);var c=function a(){b.length>0?(this.setState({queries:this.state.queries.concat(b.splice(0,50))}),setTimeout(a.bind(this),500)):this.componentFinishedUpdating()};setTimeout(c.bind(this),500)},render:function(){return this.isResultAvailable()?this.resultsJSX():this.loadingJSX()},loadingJSX:function(){return e.createElement("div",{className:"row"},e.createElement("div",{className:"col-md-6 col-md-offset-3 text-center"},e.createElement("h1",null,e.createElement("i",{className:"fa fa-cog fa-spin"}),"  BLAST-ing"),e.createElement("p",null,e.createElement("br",null),"This can take some time depending on the size of your query and database(s). The page will update automatically when BLAST is done.",e.createElement("br",null),e.createElement("br",null),"You can bookmark the page and come back to it later or share the link with someone.")))},resultsJSX:function(){return e.createElement("div",{className:"row"},this.shouldShowSidebar()&&e.createElement("div",{className:"col-md-3 hidden-sm hidden-xs"},e.createElement(t,{data:this.state,shouldShowIndex:this.shouldShowIndex()})),e.createElement("div",{className:this.shouldShowSidebar()?"col-md-9":"col-md-12"},this.overviewJSX(),this.isHitsAvailable()?e.createElement(h,{queries:this.state.queries,program:this.state.program,collapsed:"true"}):e.createElement("span",null),g.map(this.state.queries,g.bind(function(a){return e.createElement(p,{key:"Query_"+a.id,program:this.state.program,querydb:this.state.querydb,query:a,num_queries:this.state.num_queries,veryBig:this.state.veryBig,selectHit:this.selectHit,imported_xml:this.state.imported_xml})},this))))},overviewJSX:function(){return e.createElement("div",{className:"overview"},e.createElement("pre",{className:"pre-reset"},this.state.program_version,this.state.submitted_at&&"; query submitted on "+this.state.submitted_at,e.createElement("br",null),"Databases (",this.state.stats.nsequences," sequences, ",this.state.stats.ncharacters," characters): ",this.state.querydb.map(function(a){return a.title}).join(", "),e.createElement("br",null),"Parameters: ",g.map(this.state.params,function(a,b){return b+" "+a}).join(", ")))},isResultAvailable:function(){return this.state.queries.length>=1},isHitsAvailable:function(){var a=0;return g.each(this.state.queries,function(b){0==b.hits.length&&a++}),!(a==this.state.queries.length)},shouldShowSidebar:function(){return!(1==this.state.queries.length&&0==this.state.queries[0].hits.length)},shouldShowIndex:function(){return this.state.queries.length<=8},componentDidMount:function(){this.preventCollapseOnSelection()},componentDidUpdate:function(){this.updateCycle+=1,1===this.updateCycle&&this.affixSidebar()},componentFinishedUpdating:function(){this.shouldShowIndex()&&this.setupScrollSpy()},preventCollapseOnSelection:function(){$("body").on("mousedown",".hit > .section-header > h4",function(a){var b=$(this);b.on("mouseup mousemove",function a(c){if("mouseup"===c.type){b.attr("data-toggle","collapse");var d=$("#"+b.attr("data-target"));d.toggleClass("in"),b.find(".fa-chevron-down").toggleClass("fa-rotate-270")}else b.attr("data-toggle","");b.off("mouseup mousemove",a)})})},affixSidebar:function(){var a=$(".sidebar");a.affix({offset:{top:a.offset().top}})},setupScrollSpy:function(){$("body").scrollspy({target:".sidebar"})},selectHit:function(a){var b=$("#"+a),c=$(".hit-links :checkbox:checked").length;if(b&&b.val()){var d=$(b.data("target"));if(b.is(":checked")?(d.find(".section-content").addClass("glow"),$(".download-alignment-of-selected").enable(),$(".download-fasta-of-selected").enable()):d.find(".section-content").removeClass("glow"),c>=1){var e=$(".download-fasta-of-selected"),f=$(".download-alignment-of-selected");e.find(".text-bold").html(c),f.find(".text-bold").html(c)}if(0==c){var e=$(".download-fasta-of-selected"),f=$(".download-alignment-of-selected");e.addClass("disabled").find(".text-bold").html(""),f.addClass("disabled").find(".text-bold").html("")}}}}),p=e.createClass({displayName:"Query",domID:function(){return"Query_"+this.props.query.number},numhits:function(){return this.props.query.hits.length},render:function(){return e.createElement("div",{className:"resultn",id:this.domID(),"data-query-len":this.props.query.length,"data-algorithm":this.props.program},e.createElement("div",{className:"section-header"},e.createElement("h3",null,"Query= ",this.props.query.id," ",e.createElement("small",null,this.props.query.title)),e.createElement("span",{className:"label label-reset pos-label",title:"Query"+this.props.query.number+".","data-toggle":"tooltip"},this.props.query.number+"/"+this.props.num_queries)),this.numhits()&&e.createElement("div",{className:"section-content"},e.createElement(c,{key:"GO_"+this.props.query.number,query:this.props.query,program:this.props.program,collapsed:this.props.veryBig}),e.createElement(d,{key:"LD_"+this.props.query.id,query:this.props.query,algorithm:this.props.program,collapsed:"true"}),e.createElement(q,{key:"HT_"+this.props.query.number,query:this.props.query,imported_xml:this.props.imported_xml}),e.createElement("div",{id:"hits"},g.map(this.props.query.hits,g.bind(function(a){return e.createElement(r,{hit:a,key:"HIT_"+a.number,algorithm:this.props.program,querydb:this.props.querydb,query:this.props.query,imported_xml:this.props.imported_xml,selectHit:this.props.selectHit})},this))))||e.createElement("div",{className:"section-content"},e.createElement("p",null,"Query length: ",this.props.query.length),e.createElement("br",null),e.createElement("br",null),e.createElement("p",null,e.createElement("strong",null," ****** No hits found ****** "))))},shouldComponentUpdate:function(a,b){if(!this.props.query)return!0}}),q=e.createClass({displayName:"HitsTable",mixins:[f],render:function(){var a=g.every(this.props.query.hits,function(a){return""!==a.sciname});return e.createElement("table",{className:"table table-hover table-condensed tabular-view"},e.createElement("thead",null,e.createElement("th",{className:"text-left"},"#"),e.createElement("th",null,"Similar sequences"),a&&e.createElement("th",{className:"text-left"},"Species"),!this.props.imported_xml&&e.createElement("th",{className:"text-right"},"Query coverage (%)"),e.createElement("th",{className:"text-right"},"Total score"),e.createElement("th",{className:"text-right"},"E value"),e.createElement("th",{className:"text-right","data-toggle":"tooltip","data-placement":"left",title:"Total identity of all hsps / total length of all hsps"},"Identity (%)")),e.createElement("tbody",null,g.map(this.props.query.hits,g.bind(function(b){return e.createElement("tr",{key:b.number},e.createElement("td",{className:"text-left"},b.number+"."),e.createElement("td",null,e.createElement("a",{href:"#Query_"+this.props.query.number+"_hit_"+b.number},b.id)),a&&e.createElement("td",{className:"text-left"},b.sciname),!this.props.imported_xml&&e.createElement("td",{className:"text-right"},b.qcovs),e.createElement("td",{className:"text-right"},b.score),e.createElement("td",{className:"text-right"},this.inExponential(b.hsps[0].evalue)),e.createElement("td",{className:"text-right"},b.identity))},this))))}}),r=e.createClass({displayName:"Hit",mixins:[f],accession:function(){return this.props.hit.accession},length:function(){return this.props.hit.length},domID:function(){return"Query_"+this.props.query.number+"_hit_"+this.props.hit.number},databaseIDs:function(){return g.map(this.props.querydb,g.iteratee("id"))},showSequenceViewer:function(a){this.setState({showSequenceViewer:!0}),a&&a.preventDefault()},hideSequenceViewer:function(){this.setState({showSequenceViewer:!1})},viewSequenceLink:function(){return encodeURI("get_sequence/?sequence_ids="+this.accession()+"&database_ids="+this.databaseIDs())},downloadFASTA:function(a){var b=[this.accession()];m(b,this.databaseIDs())},downloadAlignment:function(a){var b=g.map(this.props.hit.hsps,g.bind(function(a){return a.query_id=this.props.query.id,a.hit_id=this.props.hit.id,a},this)),c=new j;c.export_alignments(b,this.props.query.id+"_"+this.props.hit.id)},getInitialState:function(){return{showSequenceViewer:!1}},viewSequenceButton:function(){return this.length()>1e4?e.createElement("button",{className:"btn btn-link view-sequence disabled",title:"Sequence too long",disabled:"true"},e.createElement("i",{className:"fa fa-eye"})," Sequence"):e.createElement("button",{
19
- className:"btn btn-link view-sequence",onClick:this.showSequenceViewer},e.createElement("i",{className:"fa fa-eye"})," Sequence")},render:function(){return e.createElement("div",{className:"hit",id:this.domID(),"data-hit-def":this.props.hit.id,"data-hit-evalue":this.props.hit.evalue,"data-hit-len":this.props.hit.length},e.createElement("div",{className:"section-header"},e.createElement("h4",{"data-toggle":"collapse","data-target":this.domID()+"_content"},e.createElement("i",{className:"fa fa-chevron-down"})," ",e.createElement("span",null,this.props.hit.id," ",e.createElement("small",null,this.props.hit.title))),e.createElement("span",{className:"label label-reset pos-label",title:"Query "+this.props.query.number+". Hit "+this.props.hit.number+" of "+this.props.query.hits.length+".","data-toggle":"tooltip"},this.props.hit.number+"/"+this.props.query.hits.length)),e.createElement("div",{id:this.domID()+"_content",className:"section-content collapse in"},this.hitLinks(),e.createElement(i,{key:"kablammo"+this.props.query.id,query:this.props.query,hit:this.props.hit,algorithm:this.props.algorithm}),this.hspListJSX()))},hitLinks:function(){return e.createElement("div",{className:"hit-links"},e.createElement("label",null,e.createElement("input",{type:"checkbox",id:this.domID()+"_checkbox",value:this.accession(),onChange:function(){this.props.selectHit(this.domID()+"_checkbox")}.bind(this),"data-target":"#"+this.domID()})," Select"),!this.props.imported_xml&&[e.createElement("span",null," | "),this.viewSequenceButton(),this.state.showSequenceViewer&&e.createElement(s,{url:this.viewSequenceLink(),onHide:this.hideSequenceViewer})],!this.props.imported_xml&&[e.createElement("span",null," | "),e.createElement("button",{className:"btn btn-link download-fa",onClick:this.downloadFASTA},e.createElement("i",{className:"fa fa-download"})," FASTA")],e.createElement("span",null," | "),e.createElement("button",{className:"btn btn-link download-aln",onClick:this.downloadAlignment},e.createElement("i",{className:"fa fa-download"})," Alignment"),g.map(this.props.hit.links,g.bind(function(a){return[e.createElement("span",null," | "),this.a(a)]},this)))},hspListJSX:function(){var a=this;return e.createElement("div",{className:"hsps"},this.props.hit.hsps.map(function(b){return e.createElement(k,{key:b.number,algorithm:a.props.algorithm,queryNumber:a.props.query.number,hitNumber:a.props.hit.number,hsp:b})},this))}}),s=function(){var a=e.createClass({displayName:"Viewer",widgetClass:"biojs-vis-sequence",render:function(){return this.widgetID=this.widgetClass+"-"+(new Date).getUTCMilliseconds(),e.createElement("div",{className:"fastan"},e.createElement("div",{className:"section-header"},e.createElement("h4",null,this.props.sequence.id,e.createElement("small",null,"  ",this.props.sequence.title))),e.createElement("div",{className:"section-content"},e.createElement("div",{className:this.widgetClass,id:this.widgetID})))},componentDidMount:function(){var a=new Sequence({sequence:this.props.sequence.value,target:this.widgetID,format:"PRIDE",columns:{size:40,spacedEach:0},formatOptions:{title:!1,footer:!1}});a.hideFormatSelector()}});return e.createClass({show:function(){this.modal().modal("show")},modal:function(){return $(e.findDOMNode(this.refs.modal))},resultsJSX:function(){return e.createElement("div",{className:"modal-body"},g.map(this.state.error_msgs,g.bind(function(a){return e.createElement("div",{className:"fastan"},e.createElement("div",{className:"section-header"},e.createElement("h4",null,a[0])),e.createElement("div",{className:"section-content"},e.createElement("pre",{className:"pre-reset"},a[1])))},this)),g.map(this.state.sequences,g.bind(function(b){return e.createElement(a,{sequence:b})},this)))},loadingJSX:function(){return e.createElement("div",{className:"modal-body text-center"},e.createElement("i",{className:"fa fa-spinner fa-3x fa-spin"}))},getInitialState:function(){return{error_msgs:[],sequences:[],requestCompleted:!1}},render:function(){return e.createElement("div",{className:"modal sequence-viewer",ref:"modal",tabIndex:"-1"},e.createElement("div",{className:"modal-dialog"},e.createElement("div",{className:"modal-content"},e.createElement("div",{className:"modal-header"},e.createElement("h3",null,"View sequence")),this.state.requestCompleted&&this.resultsJSX()||this.loadingJSX())))},componentDidMount:function(){this.show(),$.getJSON(this.props.url).done(g.bind(function(a){this.setState({sequences:a.sequences,error_msgs:a.error_msgs,requestCompleted:!0})},this)).fail(function(a,b,c){l(a,function(){this.hide()})}),this.modal().on("hidden.bs.modal",this.props.onHide)}})}(),t=e.createClass({displayName:"SideBar",downloadFastaOfAll:function(){var a=$(".hit-links :checkbox").map(function(){return this.value}).get(),b=g.map(this.props.data.querydb,g.iteratee("id"));m(a,b)},downloadFastaOfSelected:function(){var a=$(".hit-links :checkbox:checked").map(function(){return this.value}).get(),b=g.map(this.props.data.querydb,g.iteratee("id"));m(a,b)},downloadAlignmentOfAll:function(){var a=$(".hit-links :checkbox").map(function(){return this.value}).get(),b=[],c=new j;g.each(this.props.data.queries,g.bind(function(a){g.each(a.hits,function(c){g.each(c.hsps,function(d){d.hit_id=c.id,d.query_id=a.id,b.push(d)})})},this)),console.log("len "+b.length),c.export_alignments(b,"alignment-"+a.length+"_hits")},downloadAlignmentOfSelected:function(){var a=$(".hit-links :checkbox:checked").map(function(){return this.value}).get(),b=[],c=new j;console.log("check "+a.toString()),g.each(this.props.data.queries,g.bind(function(c){g.each(c.hits,function(d){g.indexOf(a,d.accession)!=-1&&g.each(d.hsps,function(a){a.hit_id=d.id,a.query_id=c.id,b.push(a)})})},this)),c.export_alignments(b,"alignment-"+a.length+"_hits")},render:function(){return e.createElement("div",{className:"sidebar"},this.props.shouldShowIndex&&this.index(),this.downloads())},index:function(){return e.createElement("div",{className:"index"},e.createElement("div",{className:"section-header"},e.createElement("h4",null,this.summary())),e.createElement("ul",{className:"nav hover-reset active-bold"},g.map(this.props.data.queries,g.bind(function(a){return e.createElement("li",{key:"Side_bar_"+a.id},e.createElement("a",{className:"nowrap-ellipsis hover-bold",href:"#Query_"+a.number,title:"Query= "+a.id+" "+a.title},"Query= "+a.id))},this))))},summary:function(){var a=this.props.data.program,b=this.props.data.queries.length,c=this.props.data.querydb.length;return a.toUpperCase()+": "+b+" "+(b>1?"queries":"query")+", "+c+" "+(c>1?"databases":"database")},downloads:function(){return e.createElement("div",{className:"downloads"},e.createElement("div",{className:"section-header"},e.createElement("h4",null,"Download FASTA, XML, TSV")),e.createElement("ul",{className:"nav"},!this.props.data.imported_xml&&e.createElement("li",null,e.createElement("a",{className:"download-fasta-of-all",onClick:this.downloadFastaOfAll},"FASTA of all hits")),!this.props.data.imported_xml&&e.createElement("li",null,e.createElement("a",{className:"download-fasta-of-selected disabled",onClick:this.downloadFastaOfSelected},"FASTA of ",e.createElement("span",{className:"text-bold"})," selected hit(s)")),e.createElement("li",null,e.createElement("a",{className:"download-alignment-of-all",onClick:this.downloadAlignmentOfAll},"Alignment of all hits")),e.createElement("li",null,e.createElement("a",{className:"download-alignment-of-selected disabled",onClick:this.downloadAlignmentOfSelected},"Alignment of ",e.createElement("span",{className:"text-bold"})," selected hit(s)")),!this.props.data.imported_xml&&e.createElement("li",null,e.createElement("a",{className:"download","data-toggle":"tooltip",title:"15 columns: query and subject ID; scientific name, alignment length, mismatches, gaps, identity, start and end coordinates, e value, bitscore, query coverage per subject and per HSP.",href:"download/"+this.props.data.search_id+".std_tsv"},"Standard tabular report")),!this.props.data.imported_xml&&e.createElement("li",null,e.createElement("a",{className:"download","data-toggle":"tooltip",title:"44 columns: query and subject ID, GI, accessions, and length; alignment details; taxonomy details of subject sequence(s) and query coverage per subject and per HSP.",href:"download/"+this.props.data.search_id+".full_tsv"},"Full tabular report")),!this.props.data.imported_xml&&e.createElement("li",null,e.createElement("a",{className:"download","data-toggle":"tooltip",title:"Results in XML format.",href:"download/"+this.props.data.search_id+".xml"},"Full XML report"))))}}),e.render(e.createElement(n,null),document.getElementById("view"))}}})})(function(a){a()});
18
+ a("c5")),j=a("c6"),k=a("a6"),l=a("9b"),m=a("c7"),n=(a("c8"),a("9f")),o=a("5b"),p=a("4f"),q=a("d2"),r=a("74"),s=a("a1"),t=(a("48"),1),u={construct:function(a){this._currentElement=a,this._rootNodeID=null,this._instance=null,this._pendingElement=null,this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1,this._renderedComponent=null,this._context=null,this._mountOrder=0,this._isTopLevel=!1,this._pendingCallbacks=null},mountComponent:function(a,b,c){this._context=c,this._mountOrder=t++,this._rootNodeID=a;var d=this._processProps(this._currentElement.props),e=this._processContext(this._currentElement._context),f=k.getComponentClassForElement(this._currentElement),g=new f(d,e);g.props=d,g.context=e,g.refs=q,this._instance=g,i.set(g,this);var h=g.state;void 0===h&&(g.state=h=null),r("object"==typeof h&&!Array.isArray(h)),this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1;var l,m,o=j.currentlyMountingInstance;j.currentlyMountingInstance=this;try{g.componentWillMount&&(g.componentWillMount(),this._pendingStateQueue&&(g.state=this._processPendingState(g.props,g.context))),l=this._getValidatedChildContext(c),m=this._renderValidatedComponent(l)}finally{j.currentlyMountingInstance=o}this._renderedComponent=this._instantiateReactComponent(m,this._currentElement.type);var p=n.mountComponent(this._renderedComponent,a,b,this._mergeChildContext(c,l));return g.componentDidMount&&b.getReactMountReady().enqueue(g.componentDidMount,g),p},unmountComponent:function(){var a=this._instance;if(a.componentWillUnmount){var b=j.currentlyUnmountingInstance;j.currentlyUnmountingInstance=this;try{a.componentWillUnmount()}finally{j.currentlyUnmountingInstance=b}}n.unmountComponent(this._renderedComponent),this._renderedComponent=null,this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1,this._pendingCallbacks=null,this._pendingElement=null,this._context=null,this._rootNodeID=null,i.remove(a)},_setPropsInternal:function(a,b){var c=this._pendingElement||this._currentElement;this._pendingElement=h.cloneAndReplaceProps(c,p({},c.props,a)),o.enqueueUpdate(this,b)},_maskContext:function(a){var b=null;if("string"==typeof this._currentElement.type)return q;var c=this._currentElement.type.contextTypes;if(!c)return q;b={};for(var d in c)b[d]=a[d];return b},_processContext:function(a){var b=this._maskContext(a);return b},_getValidatedChildContext:function(a){var b=this._instance,c=b.getChildContext&&b.getChildContext();if(c){r("object"==typeof b.constructor.childContextTypes);for(var d in c)r(d in b.constructor.childContextTypes);return c}return null},_mergeChildContext:function(a,b){return b?p({},a,b):a},_processProps:function(a){return a},_checkPropTypes:function(a,b,c){var e=this.getName();for(var f in a)if(a.hasOwnProperty(f)){var g;try{r("function"==typeof a[f]),g=a[f](b,f,e,c)}catch(a){g=a}if(g instanceof Error){d(this);c===m.prop}}},receiveComponent:function(a,b,c){var d=this._currentElement,e=this._context;this._pendingElement=null,this.updateComponent(b,d,a,e,c)},performUpdateIfNecessary:function(a){null!=this._pendingElement&&n.receiveComponent(this,this._pendingElement||this._currentElement,a,this._context),(null!==this._pendingStateQueue||this._pendingForceUpdate)&&this.updateComponent(a,this._currentElement,this._currentElement,this._context,this._context)},_warnIfContextsDiffer:function(a,b){a=this._maskContext(a),b=this._maskContext(b);for(var c=Object.keys(b).sort(),d=(this.getName()||"ReactCompositeComponent",0);d<c.length;d++){c[d]}},updateComponent:function(a,b,c,d,e){var f=this._instance,g=f.context,h=f.props;b!==c&&(g=this._processContext(c._context),h=this._processProps(c.props),f.componentWillReceiveProps&&f.componentWillReceiveProps(h,g));var i=this._processPendingState(h,g),j=this._pendingForceUpdate||!f.shouldComponentUpdate||f.shouldComponentUpdate(h,i,g);j?(this._pendingForceUpdate=!1,this._performComponentUpdate(c,h,i,g,a,e)):(this._currentElement=c,this._context=e,f.props=h,f.state=i,f.context=g)},_processPendingState:function(a,b){var c=this._instance,d=this._pendingStateQueue,e=this._pendingReplaceState;if(this._pendingReplaceState=!1,this._pendingStateQueue=null,!d)return c.state;if(e&&1===d.length)return d[0];for(var f=p({},e?d[0]:c.state),g=e?1:0;g<d.length;g++){var h=d[g];p(f,"function"==typeof h?h.call(c,f,a,b):h)}return f},_performComponentUpdate:function(a,b,c,d,e,f){var g=this._instance,h=g.props,i=g.state,j=g.context;g.componentWillUpdate&&g.componentWillUpdate(b,c,d),this._currentElement=a,this._context=f,g.props=b,g.state=c,g.context=d,this._updateRenderedComponent(e,f),g.componentDidUpdate&&e.getReactMountReady().enqueue(g.componentDidUpdate.bind(g,h,i,j),g)},_updateRenderedComponent:function(a,b){var c=this._renderedComponent,d=c._currentElement,e=this._getValidatedChildContext(),f=this._renderValidatedComponent(e);if(s(d,f))n.receiveComponent(c,f,a,this._mergeChildContext(b,e));else{var g=this._rootNodeID,h=c._rootNodeID;n.unmountComponent(c),this._renderedComponent=this._instantiateReactComponent(f,this._currentElement.type);var i=n.mountComponent(this._renderedComponent,g,a,this._mergeChildContext(b,e));this._replaceNodeWithMarkupByID(h,i)}},_replaceNodeWithMarkupByID:function(a,b){e.replaceNodeWithMarkupByID(a,b)},_renderValidatedComponentWithoutOwnerOrContext:function(){var a=this._instance,b=a.render();return b},_renderValidatedComponent:function(a){var b,c=f.current;f.current=this._mergeChildContext(this._currentElement._context,a),g.current=this;try{b=this._renderValidatedComponentWithoutOwnerOrContext()}finally{f.current=c,g.current=null}return r(null===b||b===!1||h.isValidElement(b)),b},attachRef:function(a,b){var c=this.getPublicInstance(),d=c.refs===q?c.refs={}:c.refs;d[a]=b.getPublicInstance()},detachRef:function(a){var b=this.getPublicInstance().refs;delete b[a]},getName:function(){var a=this._currentElement.type,b=this._instance&&this._instance.constructor;return a.displayName||b&&b.displayName||a.name||b&&b.name||null},getPublicInstance:function(){return this._instance},_instantiateReactComponent:null};l.measureMethods(u,"ReactCompositeComponent",{mountComponent:"mountComponent",updateComponent:"updateComponent",_renderValidatedComponent:"_renderValidatedComponent"});var v={Mixin:u};c.exports=v}(a("49"))});c.registerDynamic("c5",[],!0,function(a,b,c){"use strict";var d=(this||self,{remove:function(a){a._reactInternalInstance=void 0},get:function(a){return a._reactInternalInstance},has:function(a){return void 0!==a._reactInternalInstance},set:function(a,b){a._reactInternalInstance=b}});c.exports=d}),c.registerDynamic("a5",["4c","c5","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){k[a]=!0}function e(a){delete k[a]}function f(a){return!!k[a]}var g,h=a("4c"),i=a("c5"),j=a("74"),k={},l={injectEmptyComponent:function(a){g=h.createFactory(a)}},m=function(){};m.prototype.componentDidMount=function(){var a=i.get(this);a&&d(a._rootNodeID)},m.prototype.componentWillUnmount=function(){var a=i.get(this);a&&e(a._rootNodeID)},m.prototype.render=function(){return j(g),g()};var n=h.createElement(m),o={emptyElement:n,injection:l,isNullComponentID:f};c.exports=o}(a("49"))}),c.registerDynamic("a6",["4f","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){if("function"==typeof a.type)return a.type;var b=a.type,c=l[b];return null==c&&(l[b]=c=j(b)),c}function e(a){return i(k),new k(a.type,a.props)}function f(a){return new m(a)}function g(a){return a instanceof m}var h=a("4f"),i=a("74"),j=null,k=null,l={},m=null,n={injectGenericComponentClass:function(a){k=a},injectTextComponentClass:function(a){m=a},injectComponentClasses:function(a){h(l,a)},injectAutoWrapper:function(a){j=a}},o={getComponentClassForElement:d,createInternalComponent:e,createInstanceForText:f,isTextComponent:g,injection:n};c.exports=o}(a("49"))}),c.registerDynamic("a0",["db","a5","a6","4f","74","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){return"function"==typeof a&&"undefined"!=typeof a.prototype&&"function"==typeof a.prototype.mountComponent&&"function"==typeof a.prototype.receiveComponent}function e(a,b){var c;if(null!==a&&a!==!1||(a=g.emptyElement),"object"==typeof a){var e=a;c=b===e.type&&"string"==typeof e.type?h.createInternalComponent(e):d(e.type)?new e.type(e):new k}else"string"==typeof a||"number"==typeof a?c=h.createInstanceForText(a):j(!1);return c.construct(a),c._mountIndex=0,c._mountImage=null,c}var f=a("db"),g=a("a5"),h=a("a6"),i=a("4f"),j=a("74"),k=(a("48"),function(){});i(k.prototype,f.Mixin,{_instantiateReactComponent:e}),c.exports=e}(a("49"))}),c.registerDynamic("96",["57","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("57"),e=/^[ \r\n\t\f]/,f=/<(!--|link|noscript|meta|script|style)[ \r\n\t\f\/>]/,g=function(a,b){a.innerHTML=b};if("undefined"!=typeof MSApp&&MSApp.execUnsafeLocalFunction&&(g=function(a,b){MSApp.execUnsafeLocalFunction(function(){a.innerHTML=b})}),d.canUseDOM){var h=document.createElement("div");h.innerHTML=" ",""===h.innerHTML&&(g=function(a,b){if(a.parentNode&&a.parentNode.replaceChild(a,a),e.test(b)||"<"===b[0]&&f.test(b)){a.innerHTML="\ufeff"+b;var c=a.firstChild;1===c.data.length?a.removeChild(c):c.deleteData(0,1)}else a.innerHTML=b})}c.exports=g}(a("49"))}),c.registerDynamic("a1",["48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b){if(null!=a&&null!=b){var c=typeof a,d=typeof b;if("string"===c||"number"===c)return"string"===d||"number"===d;if("object"===d&&a.type===b.type&&a.key===b.key){var e=a._owner===b._owner;return e}}return!1}a("48");c.exports=d}(a("49"))}),c.registerDynamic("62",["64","71","c4","4c","4d","a5","86","c5","d1","9b","9f","c2","5b","d2","ae","d8","a0","74","96","a1","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a,b){for(var c=Math.min(a.length,b.length),d=0;d<c;d++)if(a.charAt(d)!==b.charAt(d))return d;return a.length===b.length?-1:c}function e(a){var b=D(a);return b&&R.getID(b)}function f(a){var b=g(a);if(b)if(K.hasOwnProperty(b)){var c=K[b];c!==a&&(F(!k(c,b)),K[b]=a)}else K[b]=a;return b}function g(a){return a&&a.getAttribute&&a.getAttribute(J)||""}function h(a,b){var c=g(a);c!==b&&delete K[c],a.setAttribute(J,b),K[b]=a}function i(a){return K.hasOwnProperty(a)&&k(K[a],a)||(K[a]=R.findReactNodeByID(a)),K[a]}function j(a){var b=v.get(a)._rootNodeID;return t.isNullComponentID(b)?null:(K.hasOwnProperty(b)&&k(K[b],b)||(K[b]=R.findReactNodeByID(b)),K[b])}function k(a,b){if(a){F(g(a)===b);var c=R.findReactContainerForID(b);if(c&&C(c,a))return!0}return!1}function l(a){delete K[a]}function m(a){var b=K[a];return!(!b||!k(b,a))&&void(Q=b)}function n(a){Q=null,u.traverseAncestors(a,m);var b=Q;return Q=null,b}function o(a,b,c,d,e){var f=y.mountComponent(a,b,d,B);a._isTopLevel=!0,R._mountImageIntoNode(f,c,e)}function p(a,b,c,d){var e=A.ReactReconcileTransaction.getPooled();e.perform(o,null,a,b,c,e,d),A.ReactReconcileTransaction.release(e)}var q=a("64"),r=a("71"),s=(a("c4"),a("4c")),t=(a("4d"),a("a5")),u=a("86"),v=a("c5"),w=a("d1"),x=a("9b"),y=a("9f"),z=a("c2"),A=a("5b"),B=a("d2"),C=a("ae"),D=a("d8"),E=a("a0"),F=a("74"),G=a("96"),H=a("a1"),I=(a("48"),u.SEPARATOR),J=q.ID_ATTRIBUTE_NAME,K={},L=1,M=9,N={},O={},P=[],Q=null,R={_instancesByReactRootID:N,scrollMonitor:function(a,b){b()},_updateRootComponent:function(a,b,c,d){return R.scrollMonitor(c,function(){z.enqueueElementInternal(a,b),d&&z.enqueueCallbackInternal(a,d)}),a},_registerComponent:function(a,b){F(b&&(b.nodeType===L||b.nodeType===M)),r.ensureScrollValueMonitoring();var c=R.registerContainer(b);return N[c]=a,c},_renderNewRootComponent:function(a,b,c){var d=E(a,null),e=R._registerComponent(d,b);return A.batchedUpdates(p,d,e,b,c),d},render:function(a,b,c){F(s.isValidElement(a));var d=N[e(b)];if(d){var f=d._currentElement;if(H(f,a))return R._updateRootComponent(d,a,b,c).getPublicInstance();R.unmountComponentAtNode(b)}var g=D(b),h=g&&R.isRenderedByReact(g),i=h&&!d,j=R._renderNewRootComponent(a,b,i).getPublicInstance();return c&&c.call(j),j},constructAndRenderComponent:function(a,b,c){var d=s.createElement(a,b);return R.render(d,c)},constructAndRenderComponentByID:function(a,b,c){var d=document.getElementById(c);return F(d),R.constructAndRenderComponent(a,b,d)},registerContainer:function(a){var b=e(a);return b&&(b=u.getReactRootIDFromNodeID(b)),b||(b=u.createReactRootID()),O[b]=a,b},unmountComponentAtNode:function(a){F(a&&(a.nodeType===L||a.nodeType===M));var b=e(a),c=N[b];return!!c&&(R.unmountComponentFromNode(c,a),delete N[b],delete O[b],!0)},unmountComponentFromNode:function(a,b){for(y.unmountComponent(a),b.nodeType===M&&(b=b.documentElement);b.lastChild;)b.removeChild(b.lastChild)},findReactContainerForID:function(a){var b=u.getReactRootIDFromNodeID(a),c=O[b];return c},findReactNodeByID:function(a){var b=R.findReactContainerForID(a);return R.findComponentRoot(b,a)},isRenderedByReact:function(a){if(1!==a.nodeType)return!1;var b=R.getID(a);return!!b&&b.charAt(0)===I},getFirstReactDOM:function(a){for(var b=a;b&&b.parentNode!==b;){if(R.isRenderedByReact(b))return b;b=b.parentNode}return null},findComponentRoot:function(a,b){var c=P,d=0,e=n(b)||a;for(c[0]=e.firstChild,c.length=1;d<c.length;){for(var f,g=c[d++];g;){var h=R.getID(g);h?b===h?f=g:u.isAncestorIDOf(h,b)&&(c.length=d=0,c.push(g.firstChild)):c.push(g.firstChild),g=g.nextSibling}if(f)return c.length=0,f}c.length=0,F(!1)},_mountImageIntoNode:function(a,b,c){if(F(b&&(b.nodeType===L||b.nodeType===M)),c){var e=D(b);if(w.canReuseMarkup(a,e))return;var f=e.getAttribute(w.CHECKSUM_ATTR_NAME);e.removeAttribute(w.CHECKSUM_ATTR_NAME);var g=e.outerHTML;e.setAttribute(w.CHECKSUM_ATTR_NAME,f);var h=d(a,g);" (client) "+a.substring(h-20,h+20)+"\n (server) "+g.substring(h-20,h+20);F(b.nodeType!==M)}F(b.nodeType!==M),G(b,a)},getReactRootID:e,getID:f,setID:h,getNode:i,getNodeFromInstance:j,purgeID:l};x.measureMethods(R,"ReactMount",{_renderNewRootComponent:"_renderNewRootComponent",_mountImageIntoNode:"_mountImageIntoNode"}),c.exports=R}(a("49"))}),c.registerDynamic("d7",[],!0,function(a,b,c){function d(a){return!(!a||!("function"==typeof Node?a instanceof Node:"object"==typeof a&&"number"==typeof a.nodeType&&"string"==typeof a.nodeName))}this||self;c.exports=d}),c.registerDynamic("7d",["c4","c5","62","74","d7","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){return null==a?null:h(a)?a:e.has(a)?f.getNodeFromInstance(a):(g(null==a.render||"function"!=typeof a.render),void g(!1))}var e=(a("c4"),a("c5")),f=a("62"),g=a("74"),h=a("d7");a("48");c.exports=d}(a("49"))}),c.registerDynamic("d2",["49"],!0,function(a,b,c){this||self;!function(a){"use strict";var b={};c.exports=b}(a("49"))}),c.registerDynamic("dc",["4f","d2","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("4f"),e=a("d2"),f=(a("48"),{current:e,withContext:function(a,b){var c,e=f.current;f.current=d({},e,a);try{c=b()}finally{f.current=e}return c}});c.exports=f}(a("49"))}),c.registerDynamic("c4",[],!0,function(a,b,c){"use strict";var d=(this||self,{current:null});c.exports=d}),c.registerDynamic("4f",[],!0,function(a,b,c){"use strict";function d(a,b){if(null==a)throw new TypeError("Object.assign target cannot be null or undefined");for(var c=Object(a),d=Object.prototype.hasOwnProperty,e=1;e<arguments.length;e++){var f=arguments[e];if(null!=f){var g=Object(f);for(var h in g)d.call(g,h)&&(c[h]=g[h])}}return c}this||self;c.exports=d}),c.registerDynamic("66",[],!0,function(a,b,c){function d(a){return function(){return a}}function e(){}this||self;e.thatReturns=d,e.thatReturnsFalse=d(!1),e.thatReturnsTrue=d(!0),e.thatReturnsNull=d(null),e.thatReturnsThis=function(){return this},e.thatReturnsArgument=function(a){return a},c.exports=e}),c.registerDynamic("48",["66","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("66"),e=d;c.exports=e}(a("49"))}),c.registerDynamic("4c",["dc","c4","4f","48","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("dc"),e=a("c4"),f=a("4f"),g=(a("48"),{key:!0,ref:!0}),h=function(a,b,c,d,e,f){this.type=a,this.key=b,this.ref=c,this._owner=d,this._context=e,this.props=f};h.prototype={_isReactElement:!0},h.createElement=function(a,b,c){var f,i={},j=null,k=null;if(null!=b){k=void 0===b.ref?null:b.ref,j=void 0===b.key?null:""+b.key;for(f in b)b.hasOwnProperty(f)&&!g.hasOwnProperty(f)&&(i[f]=b[f])}var l=arguments.length-2;if(1===l)i.children=c;else if(l>1){for(var m=Array(l),n=0;n<l;n++)m[n]=arguments[n+2];i.children=m}if(a&&a.defaultProps){var o=a.defaultProps;for(f in o)"undefined"==typeof i[f]&&(i[f]=o[f])}return new h(a,j,k,e.current,d.current,i)},h.createFactory=function(a){var b=h.createElement.bind(null,a);return b.type=a,b},h.cloneAndReplaceProps=function(a,b){var c=new h(a.type,a.key,a.ref,a._owner,a._context,b);return c},h.cloneElement=function(a,b,c){var d,i=f({},a.props),j=a.key,k=a.ref,l=a._owner;if(null!=b){void 0!==b.ref&&(k=b.ref,l=e.current),void 0!==b.key&&(j=""+b.key);for(d in b)b.hasOwnProperty(d)&&!g.hasOwnProperty(d)&&(i[d]=b[d])}var m=arguments.length-2;if(1===m)i.children=c;else if(m>1){for(var n=Array(m),o=0;o<m;o++)n[o]=arguments[o+2];i.children=n}return new h(a.type,j,k,l,a._context,i)},h.isValidElement=function(a){var b=!(!a||!a._isReactElement);return b},c.exports=h}(a("49"))}),c.registerDynamic("74",["49"],!0,function(a,b,c){this||self;!function(a){"use strict";var b=function(a,b,c,d,e,f,g,h){if(!a){var i;if(void 0===b)i=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var j=[c,d,e,f,g,h],k=0;i=new Error("Invariant Violation: "+b.replace(/%s/g,function(){return j[k++]}))}throw i.framesToPop=1,i}};c.exports=b}(a("49"))}),c.registerDynamic("dd",["4c","74","49"],!0,function(a,b,c){this||self;!function(b){"use strict";function d(a){return f(e.isValidElement(a)),a}var e=a("4c"),f=a("74");c.exports=d}(a("49"))}),c.registerDynamic("57",[],!0,function(a,b,c){"use strict";var d=(this||self,!("undefined"==typeof window||!window.document||!window.document.createElement)),e={canUseDOM:d,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:d&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:d&&!!window.screen,isInWorker:!d};c.exports=e}),c.registerDynamic("de",[],!0,function(a,b,c){function d(){if(!h){h=!0;for(var a,b=g.length;b;){a=g,g=[];for(var c=-1;++c<b;)a[c]();b=g.length}h=!1}}function e(){}var f=(this||self,c.exports={}),g=[],h=!1;f.nextTick=function(a){g.push(a),h||setTimeout(d,0)},f.title="browser",f.browser=!0,f.env={},f.argv=[],f.version="",f.versions={},f.on=e,f.addListener=e,f.once=e,f.off=e,f.removeListener=e,f.removeAllListeners=e,f.emit=e,f.binding=function(a){throw new Error("process.binding is not supported")},f.cwd=function(){return"/"},f.chdir=function(a){throw new Error("process.chdir is not supported")},f.umask=function(){return 0}}),c.registerDynamic("df",["de"],!0,function(a,b,c){this||self;c.exports=a("de")}),c.registerDynamic("e0",["df"],!0,function(a,b,d){this||self;d.exports=c._nodeRequire?process:a("df")}),c.registerDynamic("49",["e0"],!0,function(a,b,c){this||self;c.exports=a("e0")}),c.registerDynamic("e1",["bf","44","c1","6c","dc","c4","4c","4d","4b","7f","ce","86","62","9b","7c","9f","d0","4f","7d","dd","57","49"],!0,function(a,b,c){this||self;!function(b){"use strict";var d=a("bf"),e=a("44"),f=a("c1"),g=a("6c"),h=a("dc"),i=a("c4"),j=a("4c"),k=(a("4d"),a("4b")),l=a("7f"),m=a("ce"),n=a("86"),o=a("62"),p=a("9b"),q=a("7c"),r=a("9f"),s=a("d0"),t=a("4f"),u=a("7d"),v=a("dd");m.inject();var w=j.createElement,x=j.createFactory,y=j.cloneElement,z=p.measure("React","render",o.render),A={Children:{map:e.map,forEach:e.forEach,count:e.count,only:v},Component:f,DOM:k,PropTypes:q,initializeTouchEvents:function(a){d.useTouchEvents=a},createClass:g.createClass,createElement:w,cloneElement:y,createFactory:x,createMixin:function(a){return a},constructAndRenderComponent:o.constructAndRenderComponent,constructAndRenderComponentByID:o.constructAndRenderComponentByID,findDOMNode:u,render:z,renderToString:s.renderToString,renderToStaticMarkup:s.renderToStaticMarkup,unmountComponentAtNode:o.unmountComponentAtNode,isValidElement:j.isValidElement,withContext:h.withContext,__spread:t};"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.inject&&__REACT_DEVTOOLS_GLOBAL_HOOK__.inject({CurrentOwner:i,InstanceHandles:n,Mount:o,Reconciler:r,TextComponent:l});A.version="0.13.3",c.exports=A}(a("49"))}),c.registerDynamic("e2",["e1"],!0,function(a,b,c){this||self;c.exports=a("e1")}),c.registerDynamic("19",["e2"],!0,function(a,b,c){this||self;c.exports=a("e2")}),c.register("e3",["12","13","19","1a","1b"],function(a){function b(a,b){e.render(e.createElement(h,{errorData:a,beforeShow:b}),document.getElementById("view"))}var c,d,e,f,g,h;return{setters:[function(a){c=a.default},function(a){d=a.default},function(a){e=a.default},function(a){f=a.default},function(a){g=a.default}],execute:function(){a("default",b),h=function(a){function b(a){d(this,b),f(Object.getPrototypeOf(b.prototype),"constructor",this).call(this,a)}return g(b,a),c(b,[{key:"render",value:function(){return e.createElement("div",{id:"error",ref:"errorModal",className:"modal fade","data-keyboard":"false","data-backdrop":"static"},e.createElement("div",{className:"modal-dialog modal-lg"},e.createElement("div",{className:"modal-content"},e.createElement("div",{className:"modal-header"},e.createElement("h3",null,this.props.errorData.title)),e.createElement("div",{className:"modal-body"},e.createElement("p",{dangerouslySetInnerHTML:{__html:this.props.errorData.message}}),this.props.errorData.more_info&&e.createElement("pre",{className:"pre-scrollable"},this.props.errorData.more_info)))))}},{key:"componentDidMount",value:function(){setTimeout(function(){$(e.findDOMNode(this.refs.errorModal)).modal("show")}.bind(this),this.props.beforeShow||0)}}]),b}(e.Component)}}}),c.register("1",["11","14","15","19","20","a","f","d","1c","1e","1f","2e","e3"],function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t;return{setters:[function(a){b=a},function(a){c=a.default},function(a){d=a.default},function(a){e=a.default},function(a){f=a.default},function(a){},function(a){g=a.default},function(a){h=a.default},function(a){i=a.default},function(a){j=a.default},function(a){k=a.default},function(a){},function(a){l=a.default}],execute:function(){m=function(a,b){function c(a,b){d.append($("<input>").attr("type","hidden").attr("name",a).val(b))}var d=$("<form/>").attr("method","post").attr("action","get_sequence");c("sequence_ids",a),c("database_ids",b),d.appendTo("body").submit().remove()},n=e.createClass({displayName:"Page",render:function(){return e.createElement("div",null,e.createElement("div",{className:"container"},e.createElement(o,{ref:"report"})),e.createElement("canvas",{id:"png-exporter",hidden:!0}))}}),o=e.createClass({displayName:"Report",getInitialState:function(){return this.fetchResults(),this.updateCycle=0,{search_id:"",program:"",program_version:"",submitted_at:"",num_queries:0,queries:[],querydb:[],params:[],stats:[]}},fetchResults:function(){function a(){$.getJSON(location.pathname+".json").complete(function(d){switch(d.status){case 202:var e;e=1===b.length?b[0]:b.shift(),setTimeout(a,e);break;case 200:c.updateState(d.responseJSON);break;case 404:case 400:case 500:l(d.responseJSON)}})}var b=[200,400,800,1200,2e3,3e3,5e3],c=this;a()},updateState:function(a){var b=a.queries;a.num_queries=b.length,a.veryBig=b.length>250,a.queries=b.splice(0,50),this.setState(a);var c=function a(){b.length>0?(this.setState({queries:this.state.queries.concat(b.splice(0,50))}),setTimeout(a.bind(this),500)):this.componentFinishedUpdating()};setTimeout(c.bind(this),500)},render:function(){return this.isResultAvailable()?this.resultsJSX():this.loadingJSX()},loadingJSX:function(){return e.createElement("div",{className:"row"},e.createElement("div",{className:"col-md-6 col-md-offset-3 text-center"},e.createElement("h1",null,e.createElement("i",{className:"fa fa-cog fa-spin"}),"  BLAST-ing"),e.createElement("p",null,e.createElement("br",null),"This can take some time depending on the size of your query and database(s). The page will update automatically when BLAST is done.",e.createElement("br",null),e.createElement("br",null),"You can bookmark the page and come back to it later or share the link with someone.")))},resultsJSX:function(){return e.createElement("div",{className:"row"},this.shouldShowSidebar()&&e.createElement("div",{className:"col-md-3 hidden-sm hidden-xs"},e.createElement(t,{data:this.state,shouldShowIndex:this.shouldShowIndex()})),e.createElement("div",{className:this.shouldShowSidebar()?"col-md-9":"col-md-12"},this.overviewJSX(),this.isHitsAvailable()?e.createElement(h,{queries:this.state.queries,program:this.state.program,collapsed:"true"}):e.createElement("span",null),g.map(this.state.queries,g.bind(function(a){return e.createElement(p,{key:"Query_"+a.id,program:this.state.program,querydb:this.state.querydb,query:a,num_queries:this.state.num_queries,veryBig:this.state.veryBig,selectHit:this.selectHit,imported_xml:this.state.imported_xml})},this))))},overviewJSX:function(){return e.createElement("div",{className:"overview"},e.createElement("pre",{className:"pre-reset"},this.state.program_version,this.state.submitted_at&&"; query submitted on "+this.state.submitted_at,e.createElement("br",null),"Databases (",this.state.stats.nsequences," sequences, ",this.state.stats.ncharacters," characters): ",this.state.querydb.map(function(a){return a.title}).join(", "),e.createElement("br",null),"Parameters: ",g.map(this.state.params,function(a,b){return b+" "+a}).join(", ")))},isResultAvailable:function(){return this.state.queries.length>=1},isHitsAvailable:function(){var a=0;return g.each(this.state.queries,function(b){0==b.hits.length&&a++}),!(a==this.state.queries.length)},shouldShowSidebar:function(){return!(1==this.state.queries.length&&0==this.state.queries[0].hits.length)},shouldShowIndex:function(){return this.state.queries.length<=8},componentDidMount:function(){this.preventCollapseOnSelection()},componentDidUpdate:function(){this.updateCycle+=1,1===this.updateCycle&&this.affixSidebar()},componentFinishedUpdating:function(){this.shouldShowIndex()&&this.setupScrollSpy()},preventCollapseOnSelection:function(){$("body").on("mousedown",".hit > .section-header > h4",function(a){var b=$(this);b.on("mouseup mousemove",function a(c){if("mouseup"===c.type){b.attr("data-toggle","collapse");var d=$("#"+b.attr("data-target"));d.toggleClass("in"),b.find(".fa-chevron-down").toggleClass("fa-rotate-270")}else b.attr("data-toggle","");b.off("mouseup mousemove",a)})})},affixSidebar:function(){var a=$(".sidebar");a.affix({offset:{top:a.offset().top}})},setupScrollSpy:function(){$("body").scrollspy({target:".sidebar"})},selectHit:function(a){var b=$("#"+a),c=$(".hit-links :checkbox:checked").length;if(b&&b.val()){var d=$(b.data("target"));if(b.is(":checked")?(d.find(".section-content").addClass("glow"),$(".download-alignment-of-selected").enable(),$(".download-fasta-of-selected").enable()):d.find(".section-content").removeClass("glow"),c>=1){var e=$(".download-fasta-of-selected"),f=$(".download-alignment-of-selected");e.find(".text-bold").html(c),f.find(".text-bold").html(c)}if(0==c){var e=$(".download-fasta-of-selected"),f=$(".download-alignment-of-selected");e.addClass("disabled").find(".text-bold").html(""),f.addClass("disabled").find(".text-bold").html("")}}}}),p=e.createClass({displayName:"Query",domID:function(){return"Query_"+this.props.query.number},numhits:function(){return this.props.query.hits.length},render:function(){return e.createElement("div",{className:"resultn",id:this.domID(),"data-query-len":this.props.query.length,"data-algorithm":this.props.program},e.createElement("div",{className:"section-header"},e.createElement("h3",null,"Query= ",this.props.query.id," ",e.createElement("small",null,this.props.query.title)),e.createElement("span",{className:"label label-reset pos-label",title:"Query"+this.props.query.number+".","data-toggle":"tooltip"},this.props.query.number+"/"+this.props.num_queries)),this.numhits()&&e.createElement("div",{className:"section-content"},e.createElement(c,{key:"GO_"+this.props.query.number,query:this.props.query,program:this.props.program,collapsed:this.props.veryBig}),e.createElement(d,{key:"LD_"+this.props.query.id,query:this.props.query,algorithm:this.props.program,collapsed:"true"}),e.createElement(q,{key:"HT_"+this.props.query.number,query:this.props.query,imported_xml:this.props.imported_xml}),e.createElement("div",{id:"hits"},g.map(this.props.query.hits,g.bind(function(a){return e.createElement(r,{hit:a,key:"HIT_"+a.number,algorithm:this.props.program,querydb:this.props.querydb,query:this.props.query,imported_xml:this.props.imported_xml,selectHit:this.props.selectHit})},this))))||e.createElement("div",{className:"section-content"},e.createElement("p",null,"Query length: ",this.props.query.length),e.createElement("br",null),e.createElement("br",null),e.createElement("p",null,e.createElement("strong",null," ****** No hits found ****** "))))},shouldComponentUpdate:function(a,b){if(!this.props.query)return!0}}),q=e.createClass({displayName:"HitsTable",mixins:[f],render:function(){var a=g.every(this.props.query.hits,function(a){return""!==a.sciname});return e.createElement("table",{className:"table table-hover table-condensed tabular-view"},e.createElement("thead",null,e.createElement("th",{className:"text-left"},"#"),e.createElement("th",null,"Similar sequences"),a&&e.createElement("th",{className:"text-left"},"Species"),!this.props.imported_xml&&e.createElement("th",{className:"text-right"},"Query coverage (%)"),e.createElement("th",{className:"text-right"},"Total score"),e.createElement("th",{className:"text-right"},"E value"),e.createElement("th",{className:"text-right","data-toggle":"tooltip","data-placement":"left",title:"Total identity of all hsps / total length of all hsps"},"Identity (%)")),e.createElement("tbody",null,g.map(this.props.query.hits,g.bind(function(b){return e.createElement("tr",{key:b.number},e.createElement("td",{className:"text-left"},b.number+"."),e.createElement("td",null,e.createElement("a",{href:"#Query_"+this.props.query.number+"_hit_"+b.number},b.id)),a&&e.createElement("td",{className:"text-left"},b.sciname),!this.props.imported_xml&&e.createElement("td",{className:"text-right"},b.qcovs),e.createElement("td",{className:"text-right"},b.score),e.createElement("td",{className:"text-right"},this.inExponential(b.hsps[0].evalue)),e.createElement("td",{className:"text-right"},b.identity))},this))))}}),r=e.createClass({displayName:"Hit",mixins:[f],accession:function(){return this.props.hit.accession},length:function(){return this.props.hit.length},domID:function(){return"Query_"+this.props.query.number+"_hit_"+this.props.hit.number},databaseIDs:function(){return g.map(this.props.querydb,g.iteratee("id"))},showSequenceViewer:function(a){this.setState({showSequenceViewer:!0}),a&&a.preventDefault()},hideSequenceViewer:function(){this.setState({showSequenceViewer:!1})},viewSequenceLink:function(){return encodeURI("get_sequence/?sequence_ids="+this.accession()+"&database_ids="+this.databaseIDs())},downloadFASTA:function(a){var b=[this.accession()];m(b,this.databaseIDs())},downloadAlignment:function(a){var b=g.map(this.props.hit.hsps,g.bind(function(a){return a.query_id=this.props.query.id,a.hit_id=this.props.hit.id,a},this)),c=new j;c.export_alignments(b,this.props.query.id+"_"+this.props.hit.id)},getInitialState:function(){return{showSequenceViewer:!1}},viewSequenceButton:function(){return this.length()>1e4?e.createElement("button",{className:"btn btn-link view-sequence disabled",title:"Sequence too long",disabled:"true"},e.createElement("i",{className:"fa fa-eye"})," Sequence"):e.createElement("button",{
19
+ className:"btn btn-link view-sequence",onClick:this.showSequenceViewer},e.createElement("i",{className:"fa fa-eye"})," Sequence")},render:function(){return e.createElement("div",{className:"hit",id:this.domID(),"data-hit-def":this.props.hit.id,"data-hit-evalue":this.props.hit.evalue,"data-hit-len":this.props.hit.length},e.createElement("div",{className:"section-header"},e.createElement("h4",{"data-toggle":"collapse","data-target":this.domID()+"_content"},e.createElement("i",{className:"fa fa-chevron-down"})," ",e.createElement("span",null,this.props.hit.id," ",e.createElement("small",null,this.props.hit.title))),e.createElement("span",{className:"label label-reset pos-label",title:"Query "+this.props.query.number+". Hit "+this.props.hit.number+" of "+this.props.query.hits.length+".","data-toggle":"tooltip"},this.props.hit.number+"/"+this.props.query.hits.length)),e.createElement("div",{id:this.domID()+"_content",className:"section-content collapse in"},this.hitLinks(),e.createElement(i,{key:"kablammo"+this.props.query.id,query:this.props.query,hit:this.props.hit,algorithm:this.props.algorithm}),this.hspListJSX()))},hitLinks:function(){return e.createElement("div",{className:"hit-links"},e.createElement("label",null,e.createElement("input",{type:"checkbox",id:this.domID()+"_checkbox",value:this.accession(),onChange:function(){this.props.selectHit(this.domID()+"_checkbox")}.bind(this),"data-target":"#"+this.domID()})," Select"),!this.props.imported_xml&&[e.createElement("span",null," | "),this.viewSequenceButton(),this.state.showSequenceViewer&&e.createElement(s,{url:this.viewSequenceLink(),onHide:this.hideSequenceViewer})],!this.props.imported_xml&&[e.createElement("span",null," | "),e.createElement("button",{className:"btn btn-link download-fa",onClick:this.downloadFASTA},e.createElement("i",{className:"fa fa-download"})," FASTA")],e.createElement("span",null," | "),e.createElement("button",{className:"btn btn-link download-aln",onClick:this.downloadAlignment},e.createElement("i",{className:"fa fa-download"})," Alignment"),g.map(this.props.hit.links,g.bind(function(a){return[e.createElement("span",null," | "),this.a(a)]},this)))},hspListJSX:function(){var a=this;return e.createElement("div",{className:"hsps"},this.props.hit.hsps.map(function(b){return e.createElement(k,{key:b.number,algorithm:a.props.algorithm,queryNumber:a.props.query.number,hitNumber:a.props.hit.number,hsp:b})},this))}}),s=function(){var a=e.createClass({displayName:"Viewer",widgetClass:"biojs-vis-sequence",render:function(){return this.widgetID=this.widgetClass+"-"+(new Date).getUTCMilliseconds(),e.createElement("div",{className:"fastan"},e.createElement("div",{className:"section-header"},e.createElement("h4",null,this.props.sequence.id,e.createElement("small",null,"  ",this.props.sequence.title))),e.createElement("div",{className:"section-content"},e.createElement("div",{className:this.widgetClass,id:this.widgetID})))},componentDidMount:function(){var a=new Sequence({sequence:this.props.sequence.value,target:this.widgetID,format:"PRIDE",columns:{size:40,spacedEach:0},formatOptions:{title:!1,footer:!1}});a.hideFormatSelector()}});return e.createClass({show:function(){this.modal().modal("show")},modal:function(){return $(e.findDOMNode(this.refs.modal))},resultsJSX:function(){return e.createElement("div",{className:"modal-body"},g.map(this.state.error_msgs,g.bind(function(a){return e.createElement("div",{className:"fastan"},e.createElement("div",{className:"section-header"},e.createElement("h4",null,a[0])),e.createElement("div",{className:"section-content"},e.createElement("pre",{className:"pre-reset"},a[1])))},this)),g.map(this.state.sequences,g.bind(function(b){return e.createElement(a,{sequence:b})},this)))},loadingJSX:function(){return e.createElement("div",{className:"modal-body text-center"},e.createElement("i",{className:"fa fa-spinner fa-3x fa-spin"}))},getInitialState:function(){return{error_msgs:[],sequences:[],requestCompleted:!1}},render:function(){return e.createElement("div",{className:"modal sequence-viewer",ref:"modal",tabIndex:"-1"},e.createElement("div",{className:"modal-dialog"},e.createElement("div",{className:"modal-content"},e.createElement("div",{className:"modal-header"},e.createElement("h3",null,"View sequence")),this.state.requestCompleted&&this.resultsJSX()||this.loadingJSX())))},componentDidMount:function(){this.show(),$.getJSON(this.props.url).done(g.bind(function(a){this.setState({sequences:a.sequences,error_msgs:a.error_msgs,requestCompleted:!0})},this)).fail(function(a,b,c){l(a,function(){this.hide()})}),this.modal().on("hidden.bs.modal",this.props.onHide)}})}(),t=e.createClass({displayName:"SideBar",downloadFastaOfAll:function(){var a=$(".hit-links :checkbox").map(function(){return this.value}).get(),b=g.map(this.props.data.querydb,g.iteratee("id"));return m(a,b),!1},downloadFastaOfSelected:function(){var a=$(".hit-links :checkbox:checked").map(function(){return this.value}).get(),b=g.map(this.props.data.querydb,g.iteratee("id"));return m(a,b),!1},downloadAlignmentOfAll:function(){var a=$(".hit-links :checkbox").map(function(){return this.value}).get(),b=[],c=new j;return g.each(this.props.data.queries,g.bind(function(a){g.each(a.hits,function(c){g.each(c.hsps,function(d){d.hit_id=c.id,d.query_id=a.id,b.push(d)})})},this)),console.log("len "+b.length),c.export_alignments(b,"alignment-"+a.length+"_hits"),!1},downloadAlignmentOfSelected:function(){var a=$(".hit-links :checkbox:checked").map(function(){return this.value}).get(),b=[],c=new j;return console.log("check "+a.toString()),g.each(this.props.data.queries,g.bind(function(c){g.each(c.hits,function(d){g.indexOf(a,d.accession)!=-1&&g.each(d.hsps,function(a){a.hit_id=d.id,a.query_id=c.id,b.push(a)})})},this)),c.export_alignments(b,"alignment-"+a.length+"_hits"),!1},render:function(){return e.createElement("div",{className:"sidebar"},this.props.shouldShowIndex&&this.index(),this.downloads())},index:function(){return e.createElement("div",{className:"index"},e.createElement("div",{className:"section-header"},e.createElement("h4",null,this.summary())),e.createElement("ul",{className:"nav hover-reset active-bold"},g.map(this.props.data.queries,g.bind(function(a){return e.createElement("li",{key:"Side_bar_"+a.id},e.createElement("a",{className:"nowrap-ellipsis hover-bold",href:"#Query_"+a.number,title:"Query= "+a.id+" "+a.title},"Query= "+a.id))},this))))},summary:function(){var a=this.props.data.program,b=this.props.data.queries.length,c=this.props.data.querydb.length;return a.toUpperCase()+": "+b+" "+(b>1?"queries":"query")+", "+c+" "+(c>1?"databases":"database")},downloads:function(){return e.createElement("div",{className:"downloads"},e.createElement("div",{className:"section-header"},e.createElement("h4",null,"Download FASTA, XML, TSV")),e.createElement("ul",{className:"nav"},!this.props.data.imported_xml&&e.createElement("li",null,e.createElement("a",{href:"#",className:"btn-link download-fasta-of-all",onClick:this.downloadFastaOfAll},"FASTA of all hits")),!this.props.data.imported_xml&&e.createElement("li",null,e.createElement("a",{href:"#",className:"btn-link download-fasta-of-selected disabled",onClick:this.downloadFastaOfSelected},"FASTA of ",e.createElement("span",{className:"text-bold"})," selected hit(s)")),e.createElement("li",null,e.createElement("a",{href:"#",className:"btn-link download-alignment-of-all",onClick:this.downloadAlignmentOfAll},"Alignment of all hits")),e.createElement("li",null,e.createElement("a",{href:"#",className:"btn-link download-alignment-of-selected disabled",onClick:this.downloadAlignmentOfSelected},"Alignment of ",e.createElement("span",{className:"text-bold"})," selected hit(s)")),!this.props.data.imported_xml&&e.createElement("li",null,e.createElement("a",{className:"download","data-toggle":"tooltip",title:"15 columns: query and subject ID; scientific name, alignment length, mismatches, gaps, identity, start and end coordinates, e value, bitscore, query coverage per subject and per HSP.",href:"download/"+this.props.data.search_id+".std_tsv"},"Standard tabular report")),!this.props.data.imported_xml&&e.createElement("li",null,e.createElement("a",{className:"download","data-toggle":"tooltip",title:"44 columns: query and subject ID, GI, accessions, and length; alignment details; taxonomy details of subject sequence(s) and query coverage per subject and per HSP.",href:"download/"+this.props.data.search_id+".full_tsv"},"Full tabular report")),!this.props.data.imported_xml&&e.createElement("li",null,e.createElement("a",{className:"download","data-toggle":"tooltip",title:"Results in XML format.",href:"download/"+this.props.data.search_id+".xml"},"Full XML report"))))}}),e.render(e.createElement(n,null),document.getElementById("view"))}}})})(function(a){a()});
@@ -24,15 +24,14 @@ Gem::Specification.new do |s|
24
24
  s.add_dependency('sinatra', '~> 2.0', '>= 2.0.0')
25
25
  s.add_dependency('slop', '~> 3.6', '>= 3.6.0')
26
26
 
27
- s.add_development_dependency('capybara', '~> 3.12', '>= 3.12.0')
27
+ s.add_development_dependency('capybara', '~> 3.15', '>= 3.15.1')
28
28
  s.add_development_dependency('capybara-screenshot', '~> 1.0', '>= 1.0.23')
29
- s.add_development_dependency('codeclimate-test-reporter',
30
- '~> 1.0', '>= 1.0.8')
31
29
  s.add_development_dependency('rack-test', '~> 1.0', '>= 1.0.0')
32
30
  s.add_development_dependency('rake', '~> 10.3', '>= 10.3.2')
33
31
  s.add_development_dependency('rspec', '~> 3.7', '>= 3.7.0')
34
32
  s.add_development_dependency('sauce_whisk', '~> 0.0', '>= 0.0.19')
35
- s.add_development_dependency('selenium-webdriver', '~> 3.141', '>= 3.141.0')
33
+ s.add_development_dependency('selenium-webdriver', '~> 3.142', '>= 3.142.3')
34
+ s.add_development_dependency('simplecov', '~> 0.17.0', '>= 0.17.0')
36
35
 
37
36
  # gem
38
37
  s.files = `git ls-files`.split("\n") - ['Gemfile', 'Gemfile.lock']
@@ -1,49 +1,4 @@
1
- require 'spec_helper'
2
- require 'sauce_whisk'
3
- require 'capybara/rspec'
4
- require 'selenium-webdriver'
5
-
6
- RSpec.configure do |config|
7
- config.include Capybara::DSL
8
- end
9
-
10
- describe 'a browser', :js => true do
11
- before do |scenario|
12
- Capybara.app = SequenceServer.init
13
- Capybara.server = :webrick
14
- Capybara.javascript_driver = :selenium
15
- Capybara.default_max_wait_time = 30
16
-
17
- Capybara.register_driver :selenium do |app|
18
- capabilities = {
19
- name: scenario.full_description,
20
- platform: ENV['platform'],
21
- browserName: ENV['browserName'],
22
- browserVersion: ENV['browserVersion'],
23
- build: ENV['TRAVIS_BUILD_NUMBER'],
24
- 'tunnel-identifier': ENV['TRAVIS_JOB_NUMBER']
25
- }
26
- url = "https://#{ENV['SAUCE_USERNAME']}:#{ENV['SAUCE_ACCESS_KEY']}" \
27
- "@ondemand.saucelabs.com:443/wd/hub".strip
28
-
29
- Capybara::Selenium::Driver.new(app, browser: :remote, url: url,
30
- desired_capabilities: capabilities)
31
- end
32
- end
33
-
34
- before :each do |scenario|
35
- jobname = scenario.full_description
36
- Capybara.session_name = "#{jobname} - #{ENV['platform']} - " \
37
- "#{ENV['browserName']} - #{ENV['browserVersion']}"
38
-
39
- @driver = Capybara.current_session.driver
40
-
41
- # Output sessionId and jobname to std out for Sauce OnDemand Plugin to
42
- # display embeded results
43
- @session_id = @driver.browser.session_id
44
- puts "SauceOnDemandSessionID=#{@session_id} job-name=#{jobname}"
45
- end
46
-
1
+ describe 'a browser', type: :feature, js: true do
47
2
  it 'properly controls blast button' do
48
3
  visit '/'
49
4
 
@@ -73,39 +28,268 @@ describe 'a browser', :js => true do
73
28
  it 'can run a simple blastn search' do
74
29
  perform_search query: nucleotide_query,
75
30
  databases: nucleotide_databases
31
+ page.should have_content('BLASTN')
76
32
  end
77
33
 
78
34
  it 'can run a simple blastp search' do
79
35
  perform_search query: protein_query,
80
36
  databases: protein_databases
37
+ page.should have_content('BLASTP')
81
38
  end
82
39
 
83
40
  it 'can run a simple blastx search' do
84
41
  perform_search query: nucleotide_query,
85
42
  databases: protein_databases
43
+ page.should have_content('BLASTX')
86
44
  end
87
45
 
88
46
  it 'can run a simple tblastx search' do
89
47
  perform_search query: nucleotide_query,
90
48
  databases: nucleotide_databases,
91
49
  method: 'tblastx'
50
+ page.should have_content('TBLASTX')
92
51
  end
93
52
 
94
53
  it 'can run a simple tblastn search' do
95
54
  perform_search query: protein_query,
96
55
  databases: nucleotide_databases
56
+ page.should have_content('TBLASTN')
57
+ end
58
+
59
+ ### Test aspects of the generated report.
60
+
61
+ it "can download FASTA of each hit" do
62
+ # Do a BLASTP search. protein_query refers to the first two sequence in
63
+ # protein_databases[0], so the top hits are the query sequences themselves.
64
+ perform_search(query: protein_query,
65
+ databases: protein_databases.values_at(0))
66
+
67
+ # Click on the first FASTA download button on the page and wait for the
68
+ # download to finish.
69
+ page.execute_script("$('.download-fa:eq(0)').click()")
70
+ wait_for_download
71
+
72
+ # Test name and content of the downloaded file.
73
+ expect(File.basename(downloaded_file)).
74
+ to eq('sequenceserver-SI2.2.0_06267.fa')
75
+ expect(File.read(downloaded_file)).
76
+ to eq(File.read("#{__dir__}/sequences/sequenceserver-SI2.2.0_06267.fa"))
97
77
  end
98
78
 
99
- after :each do |scenario|
100
- @driver.quit
101
- Capybara.use_default_driver
102
- if scenario.exception
103
- SauceWhisk::Jobs.fail_job @session_id
104
- else
105
- SauceWhisk::Jobs.pass_job @session_id
79
+ it "can download FASTA of selected hits" do
80
+ # Do a BLASTP search. protein_query refers to the first two sequence in
81
+ # protein_databases[0], so the top hits are the query sequences themselves.
82
+ perform_search(query: protein_query,
83
+ databases: protein_databases.values_at(0))
84
+
85
+ # Select first hit for each query and click 'FASTA of 2 selected hits'.
86
+ page.check('Query_1_hit_1_checkbox')
87
+ page.check('Query_2_hit_1_checkbox')
88
+ page.click_link('FASTA of 2 selected hit(s)')
89
+ wait_for_download
90
+
91
+ expect(File.basename(downloaded_file)).to eq('sequenceserver-2_hits.fa')
92
+ expect(File.read(downloaded_file)).to eq(File.read("spec/sequences/sequenceserver-2_hits.fa"))
93
+ end
94
+
95
+ it "can download FASTA of all hits" do
96
+ # Do a BLASTP search. protein_query refers to the first two sequence in
97
+ # protein_databases[0], so the top hits are the query sequences themselves.
98
+ perform_search(query: protein_query,
99
+ databases: protein_databases.values_at(0))
100
+
101
+ # Click 'FASTA of all hits'.
102
+ page.click_link('FASTA of all hits')
103
+ wait_for_download
104
+
105
+ expect(File.basename(downloaded_file)).to eq('sequenceserver-2_hits.fa')
106
+ expect(File.read(downloaded_file)).to eq(File.read("spec/sequences/sequenceserver-2_hits.fa"))
107
+ end
108
+
109
+ it "can download alignment for each hit" do
110
+ # Do a BLASTP search. protein_query refers to the first two sequence in
111
+ # protein_databases[0], so the top hits are the query sequences themselves.
112
+ perform_search(query: protein_query,
113
+ databases: protein_databases.values_at(0))
114
+
115
+ # Click on the first Alignment download button on the page and wait for the
116
+ # download to finish.
117
+ page.execute_script("$('.download-aln:eq(0)').click()")
118
+ wait_for_download
119
+
120
+ # Test name and content of the downloaded file.
121
+ expect(File.basename(downloaded_file)).to eq('Query_1_SI2_2_0_06267.txt')
122
+ expect(File.read(downloaded_file)).
123
+ to eq(File.read("#{__dir__}/sequences/Query_1_SI2_2_0_06267.txt"))
124
+ end
125
+
126
+ it "can download Alignment of selected hits" do
127
+ # Do a BLASTP search. protein_query refers to the first two sequence in
128
+ # protein_databases[0], so the top hits are the query sequences themselves.
129
+ perform_search(query: protein_query,
130
+ databases: protein_databases.values_at(0))
131
+
132
+ # Select first hit for each query and click 'Alignment of 2 selected hits'.
133
+ page.check('Query_1_hit_1_checkbox')
134
+ page.check('Query_2_hit_1_checkbox')
135
+ page.click_link('Alignment of 2 selected hit(s)')
136
+ wait_for_download
137
+
138
+ expect(File.basename(downloaded_file)).to eq('alignment-2_hits.txt')
139
+ expect(File.read(downloaded_file)).to eq(File.read("spec/sequences/alignment-2_hits.txt"))
140
+ end
141
+
142
+ it "can download Alignment of all hits" do
143
+ # Do a BLASTP search. protein_query refers to the first two sequence in
144
+ # protein_databases[0], so the top hits are the query sequences themselves.
145
+ perform_search(query: protein_query,
146
+ databases: protein_databases.values_at(0))
147
+
148
+ # Click 'Alignment of all hits'.
149
+ page.click_link('Alignment of all hits')
150
+ wait_for_download
151
+
152
+ expect(File.basename(downloaded_file)).to eq('alignment-2_hits.txt')
153
+ expect(File.read(downloaded_file)).to eq(File.read("spec/sequences/alignment-2_hits.txt"))
154
+ end
155
+
156
+ it 'can download BLAST results in XML and tabular formats' do
157
+ # Do a BLASTP search. protein_query refers to the first two sequence in
158
+ # protein_databases[0], so the top hits are the query sequences themselves.
159
+ perform_search(query: protein_query,
160
+ databases: protein_databases.values_at(0))
161
+
162
+ page.click_link('Standard tabular report')
163
+ wait_for_download
164
+ expect(File.basename(downloaded_file)).to eq('sequenceserver-std_tsv_report.tsv')
165
+ clear_downloads
166
+
167
+ page.click_link('Full tabular report')
168
+ wait_for_download
169
+ expect(File.basename(downloaded_file)).to eq('sequenceserver-full_tsv_report.tsv')
170
+ clear_downloads
171
+
172
+ page.click_link('Full XML report')
173
+ wait_for_download
174
+ expect(File.basename(downloaded_file)).to eq('sequenceserver-xml_report.xml')
175
+ clear_downloads
176
+ end
177
+
178
+ it 'can show hit sequences in a modal' do
179
+ # Do a BLASTP search. protein_query refers to the first two sequence in
180
+ # protein_databases[0], so the top hits are the query sequences themselves.
181
+ perform_search(query: protein_query,
182
+ databases: protein_databases.values_at(0))
183
+
184
+ # Click on the first sequence viewer link in the report.
185
+ page.execute_script("$('.view-sequence:eq(0)').click()")
186
+
187
+ within('.sequence-viewer') do
188
+ page.should have_content('SI2.2.0_06267')
189
+ page.should have_content(<<~SEQ.chomp)
190
+ MNTLWLSLWDYPGKLPLNFMVFDTKDDLQAAYWRDPYSIP
191
+ LAVIFEDPQPISQRLIYEIRTNPSYTLPPPPTKLYSAPIS
192
+ CRKNKTGHWMDDILSIKTGESCPVNNYLHSGFLALQMITD
193
+ ITKIKLENSDVTIPDIKLIMFPKEPYTADWMLAFRVVIPL
194
+ YMVLALSQFITYLLILIVGEKENKIKEGMKMMGLNDSVF
195
+ SEQ
196
+ end
197
+
198
+ # Dismiss the first modal.
199
+ page.execute_script("$('.sequence-viewer').modal('hide')")
200
+
201
+ # Click on the second sequence viewer link in the report.
202
+ page.execute_script("$('.view-sequence:eq(1)').click()")
203
+
204
+ within('.sequence-viewer') do
205
+ page.should have_content('SI2.2.0_13722')
206
+ page.should have_content(<<~SEQ.chomp)
207
+ MSANRLNVLVTLMLAVALLVTESGNAQVDGYLQFNPKRSA
208
+ VSSPQKYCGKKLSNALQIICDGVYNSMFKKSGQDFPPQNK
209
+ RHIAHRINGNEEESFTTLKSNFLNWCVEVYHRHYRFVFVS
210
+ EMEMADYPLAYDISPYLPPFLSRARARGMLDGRFAGRRYR
211
+ RESRGIHEECCINGCTINELTSYCGP
212
+ SEQ
106
213
  end
107
214
  end
108
215
 
216
+ it 'disables sequence viewer links if hits are longer than 10kb' do
217
+ # BLASTN transcripts against genome. nucleotide_query refers to two fire
218
+ # ant transcripts and nucleotide_databases[0] is subset of the fire ant
219
+ # genome (few longest scaffolds). We expect sequence viewer links to be
220
+ # disabled for all hits of this search.
221
+ perform_search(query: nucleotide_query,
222
+ databases: nucleotide_databases.values_at(0))
223
+
224
+ # Check that the sequence viewer links are disabled.
225
+ page.evaluate_script("$('.view-sequence').is(':disabled')").should eq(true)
226
+ end
227
+
228
+ it 'can download visualisations in svg and png format' do
229
+ # Do a BLASTP search. protein_query refers to the first two sequence in
230
+ # protein_databases[0], so the top hits are the query sequences themselves.
231
+ perform_search(query: protein_query,
232
+ databases: protein_databases.values_at(0))
233
+
234
+ ## Check that there is a circos vis and unfold it.
235
+ page.should have_content('Circos')
236
+ page.execute_script("$('.circos > .grapher-header > h5').click()")
237
+ sleep 1
238
+
239
+ page.execute_script("$('.export-to-svg:eq(0)').click()")
240
+ wait_for_download
241
+ expect(File.basename(downloaded_file)).to eq('Circos-visualisation.svg')
242
+ clear_downloads
243
+
244
+ page.execute_script("$('.export-to-png:eq(0)').click()")
245
+ wait_for_download
246
+ expect(File.basename(downloaded_file)).to eq('Circos-visualisation.png')
247
+ clear_downloads
248
+
249
+
250
+ ## Check that there is a graphical overview of hits.
251
+ page.should have_content('Graphical overview of hits')
252
+
253
+ page.execute_script("$('.export-to-svg:eq(1)').click()")
254
+ wait_for_download
255
+ expect(File.basename(downloaded_file)).to eq('Alignment-Overview-Query_1.svg')
256
+ clear_downloads
257
+
258
+ page.execute_script("$('.export-to-png:eq(1)').click()")
259
+ wait_for_download
260
+ expect(File.basename(downloaded_file)).to eq('Alignment-Overview-Query_1.png')
261
+ clear_downloads
262
+
263
+
264
+ ## Check that there is a length distribution of hits.
265
+ page.should have_content('Length distribution of hits')
266
+ page.execute_script("$('.length-distribution > .grapher-header > h5').click()")
267
+ sleep 1
268
+
269
+ page.execute_script("$('.export-to-svg:eq(2)').click()")
270
+ wait_for_download
271
+ expect(File.basename(downloaded_file)).to eq('length-distribution-Query_1.svg')
272
+ clear_downloads
273
+
274
+ page.execute_script("$('.export-to-png:eq(2)').click()")
275
+ wait_for_download
276
+ expect(File.basename(downloaded_file)).to eq('length-distribution-Query_1.png')
277
+ clear_downloads
278
+
279
+ ## Check that there is a kablammo vis of query vs hit.
280
+ page.should have_content('Graphical overview of aligning region(s)')
281
+
282
+ page.execute_script("$('.export-to-svg:eq(3)').click()")
283
+ wait_for_download
284
+ expect(File.basename(downloaded_file)).to eq('Kablammo-Query_1-SI2_2_0_06267.svg')
285
+ clear_downloads
286
+
287
+ page.execute_script("$('.export-to-png:eq(3)').click()")
288
+ wait_for_download
289
+ expect(File.basename(downloaded_file)).to eq('Kablammo-Query_1-SI2_2_0_06267.png')
290
+ clear_downloads
291
+ end
292
+
109
293
  ## Helpers ##
110
294
 
111
295
  def perform_search(query: , databases: , method: nil)
@@ -121,19 +305,20 @@ describe 'a browser', :js => true do
121
305
  end
122
306
  click_button('method')
123
307
 
124
- # switch to new window because link opens in new window
308
+ # Switch to new window because link opens in new window
125
309
  page.driver.browser.switch_to.window(page.driver.browser.window_handles.last)
126
310
 
127
- # Check that results loaded.
311
+ # It is important to have this line or the examples end prematurely with a
312
+ # failure.
128
313
  page.should have_content('Query')
129
314
  end
130
315
 
131
316
  def nucleotide_query
132
- File.read File.join __dir__, 'nucleotide_query.fa'
317
+ File.read File.join(__dir__, 'sequences', 'nucleotide_query.fa')
133
318
  end
134
319
 
135
320
  def protein_query
136
- File.read File.join __dir__, 'protein_query.fa'
321
+ File.read File.join(__dir__, 'sequences', 'protein_query.fa')
137
322
  end
138
323
 
139
324
  def nucleotide_databases