From 0dd206d8f6851eeeb4fa513c42f053f801c6b757 Mon Sep 17 00:00:00 2001 From: guerler Date: Fri, 22 Jul 2016 11:38:42 -0400 Subject: [PATCH 1/9] Add optional progress bar to default buttons --- .../scripts/mvc/tool/tool-form-composite.js | 5 ++-- client/galaxy/scripts/mvc/ui/ui-buttons.js | 28 ++++++++++++------- client/galaxy/style/less/ui.less | 16 +++++++---- .../maps/mvc/tool/tool-form-composite.js.map | 2 +- static/maps/mvc/ui/ui-buttons.js.map | 2 +- static/scripts/bundled/analysis.bundled.js | 4 +-- .../scripts/bundled/analysis.bundled.js.map | 2 +- static/scripts/bundled/libs.bundled.js.map | 2 +- .../scripts/mvc/tool/tool-form-composite.js | 2 +- static/scripts/mvc/ui/ui-buttons.js | 2 +- static/style/blue/base.css | 4 +-- 11 files changed, 41 insertions(+), 28 deletions(-) diff --git a/client/galaxy/scripts/mvc/tool/tool-form-composite.js b/client/galaxy/scripts/mvc/tool/tool-form-composite.js index bc0a1b181d83..e0e77307f7a8 100644 --- a/client/galaxy/scripts/mvc/tool/tool-form-composite.js +++ b/client/galaxy/scripts/mvc/tool/tool-form-composite.js @@ -155,7 +155,7 @@ define([ 'utils/utils', 'utils/deferred', 'mvc/ui/ui-misc', 'mvc/form/form-view' this._renderHistory(); _.each ( this.steps, function( step, i ) { self._renderStep( step, i ) } ); this.deferred.execute( function() { self.execute_btn.unwait(); - self.execute_btn.model.set( 'wait_text', 'Sending...' ) } ); + self.execute_btn.model.set( { wait_text: 'Sending...', percentage: -1 } ) } ); }, /** Render header */ @@ -231,8 +231,9 @@ define([ 'utils/utils', 'utils/deferred', 'mvc/ui/ui-misc', 'mvc/form/form-view' } self.forms[ i ] = form; self._refreshStep( step ); - Galaxy.emit.debug( 'tool-form-composite::initialize()', i + ' : Workflow step state ready.', step ); self._resolve( form.deferred, promise ); + self.execute_btn.model.set( 'percentage', ( i + 1 ) * 100.0 / self.steps.length ); + Galaxy.emit.debug( 'tool-form-composite::initialize()', i + ' : Workflow step state ready.', step ); } ); }, diff --git a/client/galaxy/scripts/mvc/ui/ui-buttons.js b/client/galaxy/scripts/mvc/ui/ui-buttons.js index d6672c7379c5..75441339b836 100644 --- a/client/galaxy/scripts/mvc/ui/ui-buttons.js +++ b/client/galaxy/scripts/mvc/ui/ui-buttons.js @@ -8,15 +8,17 @@ define( [ 'utils/utils' ], function( Utils ) { title : '', floating : 'right', icon : '', - cls : 'ui-button btn btn-default', + cls : 'btn btn-default', wait : false, wait_text : 'Sending...', wait_cls : 'btn btn-info', - disabled : false + disabled : false, + percentage : -1 }).set( options ); this.setElement( $( '"].join("")),select:function(t){this.$el.toggleClass("selected",t),this.trigger("select",{source:this,selected:this.$el.hasClass("selected")})},discard:function(){var t=this,e=this.$el.parent().width();this.$el.animate({"margin-right":e},"fast",function(){t.trigger("discard",{source:t}),t.destroy()})},destroy:function(){this.off(),this.$el.remove()},events:{click:"_click","click .name":"_clickName","click .discard":"_clickDiscard",dragstart:"_dragstart",dragend:"_dragend",dragover:"_sendToParent",drop:"_sendToParent"},_click:function(t){t.stopPropagation(),this.select(t)},_clickName:function(t){t.stopPropagation(),t.preventDefault();var e=([c("Enter a new name for the element"),":\n(",c("Note that changing the name here will not rename the dataset"),")"].join(""),prompt(c("Enter a new name for the element")+":",this.element.name));e&&(this.element.name=e,this.render())},_clickDiscard:function(t){t.stopPropagation(),this.discard()},_dragstart:function(t){t.originalEvent&&(t=t.originalEvent),t.dataTransfer.effectAllowed="move",t.dataTransfer.setData("text/plain",JSON.stringify(this.element)),this.$el.addClass("dragging"),this.$el.parent().trigger("collection-element.dragstart",[this])},_dragend:function(t){this.$el.removeClass("dragging"),this.$el.parent().trigger("collection-element.dragend",[this])},_sendToParent:function(t){this.$el.parent().trigger(t)},toString:function(){return"DatasetCollectionElementView()"}}),p=a.View.extend(i.LoggableMixin).extend({_logNamespace:h,elementViewClass:u,collectionClass:t.HistoryListDatasetCollection,className:"list-collection-creator collection-creator flex-row-container",minElements:1,defaultAttributes:{creationFn:function(){throw new TypeError("no creation fn for creator")},oncreate:function(){},oncancel:function(){},autoscrollDist:24,highlightClr:"rgba( 64, 255, 255, 1.0 )"},initialize:function(t){this.metric("ListCollectionCreator.initialize",t);var e=this;o.each(this.defaultAttributes,function(i,n){i=t[n]||i,e[n]=i}),e.initialElements=t.elements||[],this._instanceSetUp(),this._elementsSetUp(),this._setUpBehaviors()},_instanceSetUp:function(){this.selectedIds={},this.$dragging=null,this.blocking=!1},_elementsSetUp:function(){this.invalidElements=[],this.workingElements=[],this.elementViews=[],this.workingElements=this.initialElements.slice(0),this._ensureElementIds(),this._validateElements(),this._mangleDuplicateNames(),this._sortElements()},_ensureElementIds:function(){return this.workingElements.forEach(function(t){t.hasOwnProperty("id")||(t.id=o.uniqueId())}),this.workingElements},_validateElements:function(){var t=this;return t.invalidElements=[],this.workingElements=this.workingElements.filter(function(e){var i=t._isElementInvalid(e);return i&&t.invalidElements.push({element:e,text:i}),!i}),this.workingElements},_isElementInvalid:function(t){return"dataset"!==t.history_content_type?c("is not a dataset"):t.state!==e.OK?c(o.contains(e.NOT_READY_STATES,t.state)?"hasn't finished running yet":"has errored, is paused, or is not accessible"):t.deleted||t.purged?c("has been deleted or purged"):null},_mangleDuplicateNames:function(){var t=900,e=1,i={};this.workingElements.forEach(function(n){for(var s=n.name;i.hasOwnProperty(s);)if(s=n.name+" ("+e+")",e+=1,e>=t)throw new Error("Safety hit in while loop - thats impressive");n.name=s,i[n.name]=!0})},_sortElements:function(t){},render:function(t,e){return this.workingElements.length .clear-selected").show():this.$(".collection-elements-controls > .clear-selected").hide()},_renderList:function(t,e){var i=this,n=r("
"),s=i.$list();o.each(this.elementViews,function(t){t.destroy(),i.removeElementView(t)}),i.workingElements.forEach(function(t){var e=i._createElementView(t);n.append(e.$el)}),i._renderClearSelected(),s.empty().append(n.children()),o.invoke(i.elementViews,"render"),s.height()>s.css("max-height")?s.css("border-width","1px 0px 1px 0px"):s.css("border-width","0px")},_createElementView:function(t){var e=new this.elementViewClass({element:t,selected:o.has(this.selectedIds,t.id)});return this.elementViews.push(e),this._listenToElementView(e),e},_listenToElementView:function(t){var e=this;e.listenTo(t,{select:function(t){var i=t.source.element;t.selected?e.selectedIds[i.id]=!0:delete e.selectedIds[i.id],e.trigger("elements:select",t)},discard:function(t){e.trigger("elements:discard",t)}})},addElementView:function(t){},removeElementView:function(t){delete this.selectedIds[t.element.id],this._renderClearSelected(),this.elementViews=o.without(this.elementViews,t),this.stopListening(t)},_renderNoElementsLeft:function(){this._disableNameAndCreate(!0),this.$(".collection-elements").append(this.templates.noElementsLeft())},_elementToJSON:function(t){return t},createList:function(t){if(!this.workingElements.length){var e=c("No valid elements for final list")+". ";return e+=''+c("Cancel")+" ",e+=c("or"),e+=' '+c("start over")+".",void this._showAlert(e)}var i=this,n=this.workingElements.map(function(t){return i._elementToJSON(t)});return i.blocking=!0,i.creationFn(n,t).always(function(){i.blocking=!1}).fail(function(t,e,n){i.trigger("error",{xhr:t,status:e,message:c("An error occurred while creating this collection")})}).done(function(t,e,n){i.trigger("collection:created",t,e,n),i.metric("collection:created",t),"function"==typeof i.oncreate&&i.oncreate.call(this,t,e,n)})},_setUpBehaviors:function(){return this.on("error",this._errorHandler),this.once("rendered",function(){this.trigger("rendered:initial",this)}),this.on("elements:select",function(t){this._renderClearSelected()}),this.on("elements:discard",function(t){var e=t.source.element;this.removeElementView(t.source),this.workingElements=o.without(this.workingElements,e),this.workingElements.length||this._renderNoElementsLeft()}),this},_errorHandler:function(t){this.error(t);var e=this;if(content=t.message||c("An error occurred"),t.xhr){var i=t.xhr,n=t.message;0===i.readyState&&0===i.status?content+=": "+c("Galaxy could not be reached and may be updating.")+c(" Try again in a few minutes."):i.responseJSON?content+=":
"+JSON.stringify(i.responseJSON)+"
":content+=": "+n}e._showAlert(content,"alert-danger")},events:{"click .more-help":"_clickMoreHelp","click .less-help":"_clickLessHelp","click .main-help":"_toggleHelp","click .header .alert button":"_hideAlert","click .reset":"reset","click .clear-selected":"clearSelectedElements","click .collection-elements":"clearSelectedElements","dragover .collection-elements":"_dragoverElements","drop .collection-elements":"_dropElements","collection-element.dragstart .collection-elements":"_elementDragstart","collection-element.dragend .collection-elements":"_elementDragend","change .collection-name":"_changeName","keydown .collection-name":"_nameCheckForEnter","click .cancel-create":function(t){"function"==typeof this.oncancel&&this.oncancel.call(this)},"click .create-collection":"_clickCreate"},_clickMoreHelp:function(t){t.stopPropagation(),this.$(".main-help").addClass("expanded"),this.$(".more-help").hide()},_clickLessHelp:function(t){t.stopPropagation(),this.$(".main-help").removeClass("expanded"),this.$(".more-help").show()},_toggleHelp:function(t){t.stopPropagation(),this.$(".main-help").toggleClass("expanded"),this.$(".more-help").toggle()},_showAlert:function(t,e){e=e||"alert-danger",this.$(".main-help").hide(),this.$(".header .alert").attr("class","alert alert-dismissable").addClass(e).show().find(".alert-message").html(t)},_hideAlert:function(t){this.$(".main-help").show(),this.$(".header .alert").hide()},reset:function(){this._instanceSetUp(),this._elementsSetUp(),this.render()},clearSelectedElements:function(t){this.$(".collection-elements .collection-element").removeClass("selected"),this.$(".collection-elements-controls > .clear-selected").hide()},_dragoverElements:function(t){t.preventDefault();var e=this.$list();this._checkForAutoscroll(e,t.originalEvent.clientY);var i=this._getNearestElement(t.originalEvent.clientY);this.$(".element-drop-placeholder").remove();var n=l('
');i.length?i.before(n):e.append(n)},_checkForAutoscroll:function(t,e){var i=2,n=t.offset(),s=t.scrollTop(),a=e-n.top,o=n.top+t.outerHeight()-e;a>=0&&a=0&&ot&&t>a-o)return s}return l()},_dropElements:function(t){t.originalEvent&&(t=t.originalEvent),t.preventDefault(),t.dataTransfer.dropEffect="move";var e=this._getNearestElement(t.clientY);return e.length?this.$dragging.insertBefore(e):this.$dragging.insertAfter(this.$(".collection-elements .collection-element").last()),this._syncOrderToDom(),!1},_syncOrderToDom:function(){var t=this,e=[];this.$(".collection-elements .collection-element").each(function(){var i=l(this).attr("data-element-id"),n=o.findWhere(t.workingElements,{id:i});n?e.push(n):console.error("missing element: ",i)}),this.workingElements=e,this._renderList()},_elementDragstart:function(t,e){e.select(!0),this.$dragging=this.$(".collection-elements .collection-element.selected")},_elementDragend:function(t,e){l(".element-drop-placeholder").remove(),this.$dragging=null},_changeName:function(t){this._validationWarning("name",!!this._getName())},_nameCheckForEnter:function(t){13!==t.keyCode||this.blocking||this._clickCreate()},_getName:function(){return o.escape(this.$(".collection-name").val())},_clickCreate:function(t){var e=this._getName();e?this.blocking||this.createList(e):this._validationWarning("name")},templates:{main:o.template(['
','
',''].join("")),header:o.template(['",'
','','',"
"].join("")),middle:o.template(['",'
',"
"].join("")),footer:o.template(['
','
','','
',c("Name"),":
","
","
",'
','
','",'
','",'","
","
",'
','","
","
"].join("")),helpContent:o.template(["

",c(["Collections of datasets are permanent, ordered lists of datasets that can be passed to tools and ","workflows in order to have analyses done on each member of the entire group. This interface allows ","you to create a collection and re-order the final collection."].join("")),"

","
    ","
  • ",c(["Rename elements in the list by clicking on ",'the existing name.'].join("")),"
  • ","
  • ",c(["Discard elements from the final created list by clicking on the ",'"Discard" button.'].join("")),"
  • ","
  • ",c(["Reorder the list by clicking and dragging elements. Select multiple elements by clicking on ",'them and you can then move those selected by dragging the ',"entire group. Deselect them by clicking them again or by clicking the ",'the "Clear selected" link.'].join("")),"
  • ","
  • ",c(['Click the "Start over" link to begin again as if you had just opened ',"the interface."].join("")),"
  • ","
  • ",c(['Click the "Cancel" button to exit the interface.'].join("")),"
  • ","

","

",c(['Once your collection is complete, enter a name and ','click "Create list".'].join("")),"

"].join("")),invalidElements:o.template([c("The following selections could not be included due to problems:"),"
    <% _.each( problems, function( problem ){ %>","
  • <%- problem.element.name %>: <%- problem.text %>
  • ","<% }); %>
"].join("")),noElementsLeft:o.template(['
  • ',c("No elements left! "),c("Would you like to "),'',c("start over"),"?","
  • "].join("")),invalidInitial:o.template(['
    ','
    ','',"<% if( _.size( problems ) ){ %>",c("The following selections could not be included due to problems"),":","
      <% _.each( problems, function( problem ){ %>","
    • <%- problem.element.name %>: <%- problem.text %>
    • ","<% }); %>
    ","<% } else if( _.size( elements ) < 1 ){ %>",c("No datasets were selected"),".","<% } %>","
    ",c("At least one element is needed for the collection"),". ",c("You may need to "),'',c("cancel")," ",c("and reselect new elements"),".","
    ","
    ","
    ",'"].join(""))},toString:function(){return"ListCollectionCreator"}}),g=function(t,e,i){var s,a=r.Deferred(),l=Galaxy.modal||new n.View;return e=o.defaults(e||{},{elements:t,oncancel:function(){l.hide(),a.reject("cancelled"); },oncreate:function(t,e){l.hide(),a.resolve(e)}}),s=new i(e),l.show({title:e.title||c("Create a collection"),body:s.$el,width:"80%",height:"100%",closing_events:!0}),s.render(),window._collectionCreator=s,a},f=function(t,e){return e=e||{},e.title=c("Create a collection from a list of datasets"),g(t,e,p)};return{DatasetCollectionElementView:u,ListCollectionCreator:p,collectionCreatorModal:g,listCollectionCreatorModal:f,createListCollection:d}}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(3),i(2),i(1),i(1))},function(t,e,i){var n,s;(function(a,o,l,r){n=[i(42),i(10),i(23),i(6),i(5)],s=function(t,e,i,n,s){"use strict";var c="dataset",d=t.ListItemView,h=d.extend({_logNamespace:c,className:d.prototype.className+" dataset",id:function(){return["dataset",this.model.get("id")].join("-")},initialize:function(t){t.logger&&(this.logger=this.model.logger=t.logger),this.log(this+".initialize:",t),d.prototype.initialize.call(this,t),this.linkTarget=t.linkTarget||"_blank"},_setUpListeners:function(){d.prototype._setUpListeners.call(this),this.listenTo(this.model,"change",function(t,e){this.model.changedAttributes().state&&this.model.inReadyState()&&this.expanded&&!this.model.hasDetails()?this.model.fetch():this.render()})},_fetchModelDetails:function(){var t=this;return t.model.inReadyState()&&!t.model.hasDetails()?t.model.fetch({silent:!0}):a.when()},remove:function(t,e){var i=this;t=t||this.fxSpeed,this.$el.fadeOut(t,function(){o.View.prototype.remove.call(i),e&&e.call(i)})},render:function(t){return d.prototype.render.call(this,t)},_swapNewRender:function(t){return d.prototype._swapNewRender.call(this,t),this.model.has("state")&&this.$el.addClass("state-"+this.model.get("state")),this.$el},_renderPrimaryActions:function(){return[this._renderDisplayButton()]},_renderDisplayButton:function(){var t=this.model.get("state");if(t===e.NOT_VIEWABLE||t===e.DISCARDED||!this.model.get("accessible"))return null;var n={target:this.linkTarget,classes:"display-btn"};if(this.model.get("purged"))n.disabled=!0,n.title=s("Cannot display datasets removed from disk");else if(t===e.UPLOAD)n.disabled=!0,n.title=s("This dataset must finish uploading before it can be viewed");else if(t===e.NEW)n.disabled=!0,n.title=s("This dataset is not yet viewable");else{n.title=s("View data"),n.href=this.model.urls.display;var a=this;n.onclick=function(t){Galaxy.frame&&Galaxy.frame.active&&(Galaxy.frame.addDataset(a.model.get("id")),t.preventDefault())}}return n.faIcon="fa-eye",i(n)},_renderDetails:function(){if(this.model.get("state")===e.NOT_VIEWABLE)return l(this.templates.noAccess(this.model.toJSON(),this));var t=d.prototype._renderDetails.call(this);return t.find(".actions .left").empty().append(this._renderSecondaryActions()),t.find(".summary").html(this._renderSummary()).prepend(this._renderDetailMessages()),t.find(".display-applications").html(this._renderDisplayApplications()),this._setUpBehaviors(t),t},_renderSummary:function(){var t=this.model.toJSON(),e=this.templates.summaries[t.state];return(e=e||this.templates.summaries.unknown)(t,this)},_renderDetailMessages:function(){var t=this,e=l('
    '),i=t.model.toJSON();return r.each(t.templates.detailMessages,function(n){e.append(l(n(i,t)))}),e},_renderDisplayApplications:function(){return this.model.isDeletedOrPurged()?"":[this.templates.displayApplications(this.model.get("display_apps"),this),this.templates.displayApplications(this.model.get("display_types"),this)].join("")},_renderSecondaryActions:function(){switch(this.debug("_renderSecondaryActions"),this.model.get("state")){case e.NOT_VIEWABLE:return[];case e.OK:case e.FAILED_METADATA:case e.ERROR:return[this._renderDownloadButton(),this._renderShowParamsButton()]}return[this._renderShowParamsButton()]},_renderShowParamsButton:function(){return i({title:s("View details"),classes:"params-btn",href:this.model.urls.show_params,target:this.linkTarget,faIcon:"fa-info-circle"})},_renderDownloadButton:function(){return this.model.get("purged")||!this.model.hasData()?null:r.isEmpty(this.model.get("meta_files"))?l(['','',""].join("")):this._renderMetaFileDownloadButton()},_renderMetaFileDownloadButton:function(){var t=this.model.urls;return l(['"].join("\n"))},events:r.extend(r.clone(d.prototype.events),{"click .display-btn":function(t){this.trigger("display",this,t)},"click .params-btn":function(t){this.trigger("params",this,t)},"click .download-btn":function(t){this.trigger("download",this,t)}}),toString:function(){var t=this.model?this.model+"":"(no model)";return"DatasetListItemView("+t+")"}});return h.prototype.templates=function(){var t=r.extend({},d.prototype.templates.warnings,{failed_metadata:n.wrapTemplate(['<% if( model.state === "failed_metadata" ){ %>','
    ',s("An error occurred setting the metadata for this dataset"),"
    ","<% } %>"]),error:n.wrapTemplate(["<% if( model.error ){ %>",'
    ',s("There was an error getting the data for this dataset"),": <%- model.error %>","
    ","<% } %>"]),purged:n.wrapTemplate(["<% if( model.purged ){ %>",'
    ',s("This dataset has been deleted and removed from disk"),"
    ","<% } %>"]),deleted:n.wrapTemplate(["<% if( model.deleted && !model.purged ){ %>",'
    ',s("This dataset has been deleted"),"
    ","<% } %>"])}),i=n.wrapTemplate(['
    ','
    ','
    ','
    ','
    ',"
    ","<% if( !dataset.deleted && !dataset.purged ){ %>",'
    ','
    ','
    ',"<% if( dataset.peek ){ %>",'
    <%= dataset.peek %>
    ',"<% } %>","<% } %>","
    "],"dataset"),a=n.wrapTemplate(['
    ','
    ',s("You do not have permission to view this dataset"),"
    ","
    "],"dataset"),o={};o[e.OK]=o[e.FAILED_METADATA]=n.wrapTemplate(["<% if( dataset.misc_blurb ){ %>",'
    ','<%- dataset.misc_blurb %>',"
    ","<% } %>","<% if( dataset.file_ext ){ %>",'
    ','",'<%- dataset.file_ext %>',"
    ","<% } %>","<% if( dataset.metadata_dbkey ){ %>",'
    ','",'',"<%- dataset.metadata_dbkey %>","","
    ","<% } %>","<% if( dataset.misc_info ){ %>",'
    ','<%- dataset.misc_info %>',"
    ","<% } %>"],"dataset"),o[e.NEW]=n.wrapTemplate(["
    ",s("This is a new dataset and not all of its data are available yet"),"
    "],"dataset"),o[e.NOT_VIEWABLE]=n.wrapTemplate(["
    ",s("You do not have permission to view this dataset"),"
    "],"dataset"),o[e.DISCARDED]=n.wrapTemplate(["
    ",s("The job creating this dataset was cancelled before completion"),"
    "],"dataset"),o[e.QUEUED]=n.wrapTemplate(["
    ",s("This job is waiting to run"),"
    "],"dataset"),o[e.RUNNING]=n.wrapTemplate(["
    ",s("This job is currently running"),"
    "],"dataset"),o[e.UPLOAD]=n.wrapTemplate(["
    ",s("This dataset is currently uploading"),"
    "],"dataset"),o[e.SETTING_METADATA]=n.wrapTemplate(["
    ",s("Metadata is being auto-detected"),"
    "],"dataset"),o[e.PAUSED]=n.wrapTemplate(["
    ",s('This job is paused. Use the "Resume Paused Jobs" in the history menu to resume'),"
    "],"dataset"),o[e.ERROR]=n.wrapTemplate(["<% if( !dataset.purged ){ %>","
    <%- dataset.misc_blurb %>
    ","<% } %>",'',s("An error occurred with this dataset"),":",'
    <%- dataset.misc_info %>
    '],"dataset"),o[e.EMPTY]=n.wrapTemplate(["
    ",s("No data"),": <%- dataset.misc_blurb %>
    "],"dataset"),o.unknown=n.wrapTemplate(['
    Error: unknown dataset state: "<%- dataset.state %>"
    '],"dataset");var l={resubmitted:n.wrapTemplate(["<% if( model.resubmitted ){ %>",'
    ',s("The job creating this dataset has been resubmitted"),"
    ","<% } %>"])},c=n.wrapTemplate(["<% _.each( apps, function( app ){ %>",'
    ','<%- app.label %> ','',"<% _.each( app.links, function( link ){ %>",'',"<% print( _l( link.text ) ); %>"," ","<% }); %>","","
    ","<% }); %>"],"apps");return r.extend({},d.prototype.templates,{warnings:t,details:i,noAccess:a,summaries:o,detailMessages:l,displayApplications:c})}(),{DatasetListItemView:h}}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(1),i(3),i(1),i(2))},function(t,e,i){var n,s;(function(a,o,l){n=[i(4)],s=function(t){var e=a.Model.extend({initialize:function(t){this.app=t},checksum:function(){var t="",e=this;return this.app.section.$el.find(".section-row").each(function(){var i=o(this).attr("id"),n=e.app.field_list[i];n&&(t+=i+":"+JSON.stringify(n.value&&n.value())+":"+n.collapsed+";")}),t},set:function(t){for(var e in t.attributes){var i=this.match(e);i&&this.app.field_list[i].value(t.get(e))}},create:function(){function t(t,e,i){n.flat_dict[t]=e,a[t]=i,n.app.element_list[e]&&n.app.element_list[e].$el.attr("tour_id",t)}function e(s,a){for(var o in a){var l=a[o];if(l.input){var r=l.input,c=s;switch(""!=s&&(c+="|"),c+=r.name,r.type){case"repeat":var d="section-",h=[],u=null;for(var p in l){var g=p.indexOf(d);-1!=g&&(g+=d.length,h.push(parseInt(p.substr(g))),u||(u=p.substr(0,g)))}h.sort(function(t,e){return t-e});var o=0;for(var f in h)e(c+"_"+o++,l[u+h[f]]);break;case"conditional":var m=n.app.field_list[r.id].value();t(c+"|"+r.test_param.name,r.id,m);var v=i(r,m);-1!=v&&e(c,a[r.id+"-section-"+v]);break;case"section":e(!r.flat&&c||"",l);break;default:var _=n.app.field_list[r.id];if(_&&_.value){var m=_.value();if((void 0===r.ignore||r.ignore!=m)&&(_.collapsed&&r.collapsible_value&&(m=r.collapsible_value),t(c,r.id,m),r.payload))for(var y in r.payload)t(y,r.id,r.payload[y])}}}}}var n=this,s={};this._iterate(this.app.section.$el,s);var a={};return this.flat_dict={},e("",s),a},match:function(t){return this.flat_dict&&this.flat_dict[t]},matchCase:function(t,e){return i(t,e)},matchModel:function(t,e){var i=this;n(t.inputs,function(t,n){i.flat_dict[n]&&e(t,i.flat_dict[n])})},matchResponse:function(t){function e(t,s){if("string"==typeof s){var a=n.flat_dict[t];a&&(i[a]=s)}else for(var o in s){var l=o;if(""!==t){var r="|";s instanceof Array&&(r="_"),l=t+r+l}e(l,s[o])}}var i={},n=this;return e("",t),i},_iterate:function(t,e){var i=this,n=o(t).children();n.each(function(){var t=this,n=o(t).attr("id");if(o(t).hasClass("section-row")){var s=i.app.input_list[n];e[n]=s&&{input:s}||{},i._iterate(t,e[n])}else i._iterate(t,e)})}}),i=function(t,e){"boolean"==t.test_param.type&&(e="true"==e?t.test_param.truevalue||"true":t.test_param.falsevalue||"false");for(var i in t.cases)if(t.cases[i].value==e)return i;return-1},n=function(t,e,s,a){a=o.extend(!0,{},a),l.each(t,function(t){t&&t.type&&t.name&&(a[t.name]=t)});for(var r in t){var c=t[r],d=s?s+"|"+c.name:c.name;switch(c.type){case"repeat":l.each(c.cache,function(t,i){n(t,e,d+"_"+i,a)});break;case"conditional":if(c.test_param){e(c.test_param,d+"|"+c.test_param.name,a);var h=i(c,c.test_param.value);-1!=h?n(c.cases[h].inputs,e,d,a):Galaxy.emit.debug("form-data::visitInputs() - Invalid case for "+d+".")}else Galaxy.emit.debug("form-data::visitInputs() - Conditional test parameter missing for "+d+".");break;case"section":n(c.inputs,e,d,a);break;default:e(c,d,a)}}};return{Manager:e,visitInputs:n}}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(3),i(1),i(2))},function(t,e,i){var n,s;(function(i,a,o){n=[],s=function(){return i.View.extend({initialize:function(t,e){this.app=t,this.app_options=t.options||{},this.field=e&&e.field||new i.View,this.model=e&&e.model||new i.Model({text_enable:this.app_options.text_enable||"Enable",text_disable:this.app_options.text_disable||"Disable",cls_enable:this.app_options.cls_enable||"fa fa-caret-square-o-down",cls_disable:this.app_options.cls_disable||"fa fa-caret-square-o-up"}).set(e),this.setElement(this._template()),this.$field=this.$(".ui-form-field"),this.$info=this.$(".ui-form-info"),this.$preview=this.$(".ui-form-preview"),this.$collapsible=this.$(".ui-form-collapsible"),this.$collapsible_text=this.$(".ui-form-collapsible-text"),this.$collapsible_icon=this.$(".ui-form-collapsible-icon"),this.$title=this.$(".ui-form-title"),this.$title_text=this.$(".ui-form-title-text"),this.$error_text=this.$(".ui-form-error-text"),this.$error=this.$(".ui-form-error"),this.$backdrop=this.$(".ui-form-backdrop"),this.$field.prepend(this.field.$el);var n=this.model.get("collapsible_value");this.field.collapsed=void 0!==n&&JSON.stringify(this.model.get("value"))==JSON.stringify(n),this.listenTo(this.model,"change",this.render,this),this.render();var s=this;this.$collapsible.on("click",function(){s.field.collapsed=!s.field.collapsed,t.trigger&&t.trigger("change"),s.render()})},backdrop:function(){this.model.set("backdrop",!0)},error:function(t){this.model.set("error_text",t)},reset:function(){this.model.set("error_text",null)},render:function(){a(".tooltip").hide();var t=this.model.get("help",""),e=this.model.get("argument");e&&-1==t.indexOf("("+e+")")&&(t+=" ("+e+")"),this.$info.html(t),this.$preview[this.field.collapsed&&this.model.get("collapsible_preview")||this.model.get("disabled")?"show":"hide"]().html(o.escape(this.model.get("text_value")));var i=this.model.get("error_text");if(this.$error[i?"show":"hide"](),this.$el[i?"addClass":"removeClass"]("ui-error"),this.$error_text.html(i),this.$backdrop[this.model.get("backdrop")?"show":"hide"](),this.field.collapsed||this.model.get("disabled")?this.$field.hide():this.$field.fadeIn("fast"),this.field.model&&this.field.model.set({color:this.model.get("color"),style:this.model.get("style")}),this.model.get("disabled")||void 0===this.model.get("collapsible_value"))this.$title_text.show().text(this.model.get("label")),this.$collapsible.hide();else{var n=this.field.collapsed?"enable":"disable";this.$title_text.hide(),this.$collapsible.show(),this.$collapsible_text.text(this.model.get("label")),this.$collapsible_icon.removeClass().addClass("icon").addClass(this.model.get("cls_"+n)).attr("data-original-title",this.model.get("text_"+n)).tooltip({placement:"bottom"})}},_template:function(){return a("
    ").addClass("ui-form-element").append(a("
    ").addClass("ui-form-error ui-error").append(a("").addClass("fa fa-arrow-down")).append(a("").addClass("ui-form-error-text"))).append(a("
    ").addClass("ui-form-title").append(a("
    ").addClass("ui-form-collapsible").append(a("").addClass("ui-form-collapsible-icon")).append(a("").addClass("ui-form-collapsible-text"))).append(a("").addClass("ui-form-title-text"))).append(a("
    ").addClass("ui-form-field").append(a("").addClass("ui-form-info")).append(a("
    ").addClass("ui-form-backdrop"))).append(a("
    ").addClass("ui-form-preview"))}})}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(3),i(1),i(2))},function(t,e,i){var n,s;(function(a,o,l){n=[i(4),i(7),i(49),i(51),i(50),i(47)],s=function(t,e,i,n,s,r){return a.Model.extend({types:{text:"_fieldText",select:"_fieldSelect",data_column:"_fieldSelect",genomebuild:"_fieldSelect",data:"_fieldData",data_collection:"_fieldData",integer:"_fieldSlider","float":"_fieldSlider","boolean":"_fieldBoolean",drill_down:"_fieldDrilldown",color:"_fieldColor",hidden:"_fieldHidden",hidden_data:"_fieldHidden",baseurl:"_fieldHidden",library_data:"_fieldLibrary",ftpfile:"_fieldFtp"},create:function(t){var e=this.types[t.type],i="function"==typeof this[e]?this[e].call(this,t):null;return i||(i=t.options?this._fieldSelect(t):this._fieldText(t),Galaxy.emit.debug("form-parameters::_addRow()","Auto matched field type ("+t.type+").")),void 0===t.value&&(t.value=null),i.value(t.value),i},_fieldData:function(t){return new i.View({id:"field-"+t.id,extensions:t.extensions,optional:t.optional,multiple:t.multiple,type:t.type,flavor:t.flavor,data:t.options,onchange:t.onchange})},_fieldSelect:function(t){if(t.is_workflow)return this._fieldText(t);"data_column"==t.type&&(t.error_text="Missing columns in referenced dataset.");var i=t.data;i||(i=[],o.each(t.options,function(t){i.push({label:t[0],value:t[1]})}));var n=e.Select;switch(t.display){case"checkboxes":n=e.Checkbox;break;case"radio":n=e.Radio;break;case"radiobutton":n=e.RadioButton}return new n.View({id:"field-"+t.id,data:i,error_text:t.error_text||"No options available",multiple:t.multiple,optional:t.optional,onchange:t.onchange})},_fieldDrilldown:function(t){return t.is_workflow?this._fieldText(t):new e.Drilldown.View({id:"field-"+t.id,data:t.options,display:t.display,optional:t.optional,onchange:t.onchange})},_fieldText:function(i){if(i.options&&i.data)if(i.area=i.multiple,t.isEmpty(i.value))i.value=null;else if(l.isArray(i.value)){var n="";for(var s in i.value){if(n+=String(i.value[s]),!i.multiple)break;n+="\n"}i.value=n}return new e.Input({id:"field-"+i.id,area:i.area,placeholder:i.placeholder,onchange:i.onchange})},_fieldSlider:function(t){return new e.Slider.View({id:"field-"+t.id,precise:"float"==t.type,is_workflow:t.is_workflow,min:t.min,max:t.max,onchange:t.onchange})},_fieldHidden:function(t){return new e.Hidden({id:"field-"+t.id,info:t.info})},_fieldBoolean:function(t){return new e.RadioButton.View({id:"field-"+t.id,data:[{label:"Yes",value:"true"},{label:"No",value:"false"}],onchange:t.onchange})},_fieldColor:function(t){return new r({id:"field-"+t.id,onchange:t.onchange})},_fieldLibrary:function(t){return new n.View({id:"field-"+t.id,optional:t.optional,multiple:t.multiple,onchange:t.onchange})},_fieldFtp:function(t){return new s.View({id:"field-"+t.id,optional:t.optional,multiple:t.multiple,onchange:t.onchange})}})}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(3),i(2),i(1))},function(t,e,i){var n,s;(function(a,o,l){n=[i(4),i(14),i(9),i(7)],s=function(t,e,i,n){var s=a.View.extend({initialize:function(i){this.options=t.merge(i,{title:"Section",empty_text:"Not available.",max:null,min:null}),this.setElement("
    "),this.button_new=new n.ButtonIcon({icon:"fa-plus",title:"Insert "+this.options.title_new,tooltip:"Add new "+this.options.title_new+" block",floating:"clear",onclick:function(){i.onnew&&i.onnew()}}),this.table=new e.View({cls:"ui-table-plain",content:""}),this.$el.append(this.table.$el),this.$el.append(o("
    ").append(this.button_new.$el)),this.list={},this.n=0},size:function(){return this.n},add:function(t){if(!t.id||this.list[t.id])return void Galaxy.emit.debug("form-repeat::add()","Duplicate repeat block id.");this.n++;var e=new n.ButtonIcon({icon:"fa-trash-o",tooltip:"Delete this repeat block",cls:"ui-button-icon-plain",onclick:function(){t.ondel&&t.ondel()}}),s=new i.View({id:t.id,title:"placeholder",cls:t.cls||"ui-portlet-repeat",operations:{button_delete:e}});s.append(t.$el),s.$el.addClass("section-row"),this.list[t.id]=s,this.table.add(s.$el),this.table.append("row_"+t.id,!0),this.options.max>0&&this.n>=this.options.max&&this.button_new.disable(),this._refresh()},del:function(t){if(!this.list[t])return void Galaxy.emit.debug("form-repeat::del()","Invalid repeat block id.");this.n--;var e=this.table.get("row_"+t);e.remove(),delete this.list[t],this.button_new.enable(),this._refresh()},delAll:function(){for(var t in this.list)this.del(t)},hideOptions:function(){this.button_new.$el.hide(),l.each(this.list,function(t){t.hideOperation("button_delete")}),l.isEmpty(this.list)&&this.$el.append(o("
    ").addClass("ui-form-info").html(this.options.empty_text))},_refresh:function(){var t=0;for(var e in this.list){var i=this.list[e];i.title(++t+": "+this.options.title),this.n>this.options.min?i.showOperation("button_delete"):i.hideOperation("button_delete")}}});return{View:s}}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(3),i(1),i(2))},function(t,e,i){var n,s;(function(a,o,l,r){n=[i(4),i(14),i(7),i(9),i(36),i(34),i(35)],s=function(t,e,i,n,s,c,d){var h=a.View.extend({initialize:function(t,i){this.app=t,this.inputs=i.inputs,i.cls="ui-table-plain",i.cls_tr="section-row",this.table=new e.View(i),this.parameters=new d,this.setElement(this.table.$el),this.render()},render:function(){this.table.delAll();for(var t in this.inputs)this.add(this.inputs[t])},add:function(e){var i=o.extend(!0,{},e);i.id=e.id=t.uid(),this.app.input_list[i.id]=i;var n=i.type;switch(n){case"conditional":this._addConditional(i);break;case"repeat":this._addRepeat(i);break;case"section":this._addSection(i);break;default:this._addRow(i)}},_addConditional:function(t){var e=this;t.test_param.id=t.id,this.app.options.sustain_conditionals&&(t.test_param.disabled=!0);var i=this._addRow(t.test_param);i.model&&i.model.set("onchange",function(i){var n=e.app.data.matchCase(t,i);for(var s in t.cases){var a=t.cases[s],o=t.id+"-section-"+s,l=e.table.get(o),r=!1;for(var c in a.inputs)if(!a.inputs[c].hidden){r=!0;break}s==n&&r?l.fadeIn("fast"):l.hide()}e.app.trigger("change")});for(var n in t.cases){var s=t.id+"-section-"+n,a=new h(this.app,{inputs:t.cases[n].inputs});a.$el.addClass("ui-table-section"),this.table.add(a.$el),this.table.append(s)}i.trigger("change")},_addRepeat:function(t){function e(e){var s=t.id+"-section-"+n++,o=new h(i.app,{inputs:e});a.add({id:s,$el:o.$el,ondel:function(){a.del(s),i.app.trigger("change")}})}for(var i=this,n=0,a=new s.View({title:t.title||"Repeat",title_new:t.title||"",min:t.min,max:t.max,onnew:function(){e(t.inputs),i.app.trigger("change")}}),o=l.size(t.cache),r=0;rr?t.cache[r]:t.inputs);this.app.options.sustain_repeats&&a.hideOptions();var d=new c(this.app,{label:t.title||t.name,help:t.help,field:a});this.table.add(d.$el),this.table.append(t.id)},_addSection:function(t){var e=new n.View({title:t.title||t.name,cls:"ui-portlet-section",collapsible:!0,collapsible_button:!0,collapsed:!t.expanded});e.append(new h(this.app,{inputs:t.inputs}).$el),e.append(r("
    ").addClass("ui-form-info").html(t.help)),this.app.on("expand",function(t){e.$("#"+t).length>0&&e.expand()}),this.table.add(e.$el),this.table.append(t.id)},_addRow:function(t){var e=this,i=t.id;t.onchange=function(){e.app.trigger("change")};var n=this.parameters.create(t);this.app.field_list[i]=n;var s=new c(this.app,{name:t.name,label:t.label||t.name,value:t.value,text_value:t.text_value,collapsible_value:t.collapsible_value,collapsible_preview:t.collapsible_preview,help:t.help,argument:t.argument,disabled:t.disabled,color:t.color,style:t.style,backdrop:t.backdrop,field:n});return this.app.element_list[i]=s,this.table.add(s.$el),this.table.append(i),t.hidden&&this.table.get(i).hide(),n}});return{View:h}}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(3),i(1),i(2),i(1))},function(t,e,i){var n,s;(function(a,o,l){n=[i(4),i(9),i(7),i(37),i(33)],s=function(t,e,i,n,s){return a.View.extend({initialize:function(e){this.options=t.merge(e,{initial_errors:!1,cls:"ui-portlet-limited",icon:null}),this.setElement("
    "),this.render()},update:function(t){var e=this;this.data.matchModel(t,function(t,i){var n=e.input_list[i];if(n&&n.options&&!o.isEqual(n.options,t.options)){n.options=t.options;var s=e.field_list[i];if(s.update){var a=[];if(-1!=["data","data_collection","drill_down"].indexOf(n.type))a=n.options;else for(var l in t.options){var r=t.options[l];r.length>2&&a.push({label:r[0],value:r[1]})}s.update(a),s.trigger("change"),Galaxy.emit.debug("form-view::update()","Updating options for "+i)}}})},wait:function(t){for(var e in this.input_list){var i=this.field_list[e],n=this.input_list[e];n.is_dynamic&&i.wait&&i.unwait&&(t?i.wait():i.unwait())}},highlight:function(t,e,i){var n=this.element_list[t];if(n&&(n.error(e||"Please verify this parameter."),this.portlet.expand(),this.trigger("expand",t),!i))if(self==top){var s=this.$el.parents().filter(function(){return"auto"==l(this).css("overflow")}).first();s.animate({scrollTop:s.scrollTop()+n.$el.offset().top-50},500)}else l("html, body").animate({scrollTop:n.$el.offset().top-20},500)},errors:function(t){if(this.trigger("reset"),t&&t.errors){var e=this.data.matchResponse(t.errors);for(var i in this.element_list){this.element_list[i];e[i]&&this.highlight(i,e[i],!0)}}},setOnChange:function(t){this.options.onchange=t},render:function(){var t=this;this.off("change"),this.off("reset"),this.field_list={},this.input_list={},this.element_list={},this.data=new s.Manager(this),this._renderForm(),this.data.create(),this.options.initial_errors&&this.errors(this.options);var e=this.data.checksum();return this.on("change",function(i){var n=t.data.checksum();(n!=e||i)&&(e=n,t.options.onchange&&t.options.onchange())}),this.on("reset",function(){for(var t in this.element_list)this.element_list[t].reset()}),this},_renderForm:function(){this.message=new i.Message,this.section=new n.View(this,{inputs:this.options.inputs}),l(".tooltip").remove(),this.portlet=new e.View({icon:this.options.icon,title:this.options.title,cls:this.options.cls,operations:this.options.operations,buttons:this.options.buttons,collapsible:this.options.collapsible,collapsed:this.options.collapsed}),this.portlet.append(this.message.$el),this.portlet.append(this.section.$el),this.$el.empty(),this.$el.append(this.portlet.$el),this.options.message&&this.message.update({persistent:!0,status:"warning",message:this.options.message}),Galaxy.emit.debug("form-view::initialize()","Completed")}})}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(3),i(2),i(1))},function(t,e,i){var n,s;(function(a){n=[i(30),i(40),i(5)],s=function(t,e,i){"use strict";function n(t){return function(e,i){return this.isNew()&&(i=i||{},i.url=this.urlRoot+this.get("history_id")+"/contents",e=e||{},e.type="dataset_collection"),t.call(this,e,i)}}var s=e.HistoryContentMixin,o=t.ListDatasetCollection,l=t.PairDatasetCollection,r=t.ListPairedDatasetCollection,c=t.ListOfListsDatasetCollection,d=o.extend(s).extend({defaults:a.extend(a.clone(o.prototype.defaults),{history_content_type:"dataset_collection",collection_type:"list",model_class:"HistoryDatasetCollectionAssociation"}),initialize:function(t,e){o.prototype.initialize.call(this,t,e),s.initialize.call(this,t,e)},save:n(o.prototype.save),toString:function(){return["HistoryListDatasetCollection(",this.get("name"),")"].join("")}}),h=l.extend(s).extend({defaults:a.extend(a.clone(l.prototype.defaults),{history_content_type:"dataset_collection",collection_type:"paired",model_class:"HistoryDatasetCollectionAssociation"}),initialize:function(t,e){l.prototype.initialize.call(this,t,e),s.initialize.call(this,t,e)},save:n(l.prototype.save),toString:function(){return["HistoryPairDatasetCollection(",this.get("name"),")"].join("")}}),u=r.extend(s).extend({defaults:a.extend(a.clone(r.prototype.defaults),{history_content_type:"dataset_collection",collection_type:"list:paired",model_class:"HistoryDatasetCollectionAssociation"}),initialize:function(t,e){r.prototype.initialize.call(this,t,e),s.initialize.call(this,t,e)},save:n(r.prototype.save),toString:function(){return["HistoryListPairedDatasetCollection(",this.get("name"),")"].join("")}}),p=c.extend(s).extend({defaults:a.extend(a.clone(c.prototype.defaults),{history_content_type:"dataset_collection",collection_type:"list:list",model_class:"HistoryDatasetCollectionAssociation"}),initialize:function(t,e){c.prototype.initialize.call(this,t,e),s.initialize.call(this,t,e)},save:n(c.prototype.save),toString:function(){return["HistoryListOfListsDatasetCollection(",this.get("name"),")"].join("")}});return{HistoryListDatasetCollection:d,HistoryPairDatasetCollection:h,HistoryListPairedDatasetCollection:u,HistoryListOfListsDatasetCollection:p}}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(2))},function(t,e,i){var n,s;(function(a,o){n=[i(10),i(6),i(5)],s=function(t,e,i){"use strict";var n="history",s=function(t,e){return[t,e].join("-")},l={defaults:{history_id:null,history_content_type:null,hid:null,visible:!0},idAttribute:"type_id",constructor:function(t,e){t.type_id=s(t.history_content_type,t.id),this.debug("HistoryContentMixin.constructor:",t.type_id),a.Model.apply(this,arguments)},_typeIdStr:function(){return s(this.get("history_content_type"),this.get("id"))},initialize:function(t,e){this.on("change:id",this._createTypeId)},_createTypeId:function(){this.set("type_id",this._typeIdStr())},isNew:function(){return!this.get("id")},hidden:function(){return!this.get("visible")},isVisible:function(t,e){var i=!0;return t||!this.get("deleted")&&!this.get("purged")||(i=!1),e||this.get("visible")||(i=!1),i},urlRoot:Galaxy.root+"api/histories/",url:function(){var t=this.urlRoot+this.get("history_id")+"/contents/"+this.get("history_content_type")+"s/"+this.get("id");return t},hide:function(t){return this.get("visible")?this.save({visible:!1},t):o.when()},unhide:function(t){return this.get("visible")?o.when():this.save({visible:!0},t)},toString:function(){var t=this.get("id")||"";return this.get("name")&&(t=this.get("hid")+' :"'+this.get("name")+'",'+t),"HistoryContent("+t+")"}},r=a.Model.extend(e.LoggableMixin).extend(l).extend({_logNamespace:n});return{typeIdStr:s,HistoryContentMixin:l,HistoryContent:r}}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(3),i(1))},function(t,e,i){var n,s;(function(a,o,l){n=[i(40),i(72),i(39),i(10),i(6),i(5)],s=function(t,e,i,n,s,r){"use strict";var c="history",d=a.Collection.extend(s.LoggableMixin).extend({_logNamespace:c,model:function(t,n){if("dataset"===t.history_content_type)return new e.HistoryDatasetAssociation(t,n);if("dataset_collection"===t.history_content_type){switch(t.collection_type){case"list":return new i.HistoryListDatasetCollection(t,n);case"paired":return new i.HistoryPairDatasetCollection(t,n);case"list:paired":return new i.HistoryListPairedDatasetCollection(t,n);case"list:list":return new i.HistoryListOfListsDatasetCollection(t,n)}var s="Unknown collection_type: "+t.collection_type;return console.warn(s,t),{validationError:s}}return{validationError:"Unknown history_content_type: "+t.history_content_type}},initialize:function(t,e){e=e||{},this.historyId=e.historyId,this.model.prototype.idAttribute="type_id",this.on("all",function(){this.debug(this+".event:",arguments)})},urlRoot:Galaxy.root+"api/histories",url:function(){return this.urlRoot+"/"+this.historyId+"/contents"},ids:function(){return this.map(function(t){return t.get("id")})},notReady:function(){return this.filter(function(t){return!t.inReadyState()})},running:function(){function t(t){return!t.inReadyState()}return new d(this.filter(t))},getByHid:function(t){return o.first(this.filter(function(e){return e.get("hid")===t}))},getVisible:function(t,e,i){i=i||[],this.debug("checking isVisible");var n=new d(this.filter(function(i){return i.isVisible(t,e)}));return o.each(i,function(t){o.isFunction(t)&&(n=new d(n.filter(t)))}),n},hidden:function(){function t(t){return t.hidden()}return new d(this.filter(t))},deleted:function(){function t(t){return t.get("deleted")}return new d(this.filter(t))},visibleAndUndeleted:function(){function t(t){return t.get("visible")&&!t.get("deleted"); }return new d(this.filter(t))},haveDetails:function(){return this.all(function(t){return t.hasDetails()})},fetch:function(t){return t=t||{},t.data=o.defaults(t.data||{},{v:"dev"}),a.Collection.prototype.fetch.call(this,t)},fetchUpdated:function(t,e){return e=e||{},e.traditional=!0,e.data=[{name:"v",value:"dev"}],t&&(e.data=e.data.concat(this._filtersFromMap({"update_time-ge":t.toISOString()}))),e.merge=!0,e.remove=!1,this.fetch(e)},_filtersFromMap:function(t){var e=[];return o.each(t,function(t,i){e.push({name:"q",value:i}),e.push({name:"qv",value:t})}),e},fetchAllDetails:function(t){t=t||{};var e={details:"all"};return t.data=t.data?o.extend(t.data,e):e,this.fetch(t)},fetchCollectionCounts:function(t){return t=t||{},t.data=o.defaults({keys:["type_id","element_count"].join(","),q:"history_content_type",qv:"dataset_collection"},t.data||{}),t.merge=!0,t.remove=!1,this.fetch(t)},ajaxQueue:function(t,e){var i=l.Deferred(),n=this.length,s=[];if(!n)return i.resolve([]),i;var a=this.chain().reverse().map(function(o,l){return function(){var r=t.call(o,e);r.done(function(t){i.notify({curr:l,total:n,response:t,model:o})}),r.always(function(t){s.push(t),a.length?a.shift()():i.resolve(s)})}}).value();return a.shift()(),i},isCopyable:function(t){var e=["HistoryDatasetAssociation","HistoryDatasetCollectionAssociation"];return o.isObject(t)&&t.id&&o.contains(e,t.model_class)},copy:function(t){var e,i,n;o.isString(t)?(e=t,n="hda",i="dataset"):(e=t.id,n={HistoryDatasetAssociation:"hda",LibraryDatasetDatasetAssociation:"ldda",HistoryDatasetCollectionAssociation:"hdca"}[t.model_class]||"hda",i="hdca"===n?"dataset_collection":"dataset");var s=this,a=l.ajax(this.url(),{method:"POST",contentType:"application/json",data:JSON.stringify({content:e,source:n,type:i})}).done(function(t){s.add([t])}).fail(function(t,o,l){s.trigger("error",s,a,{},"Error copying contents",{type:i,id:e,source:n})});return a},matches:function(t){return this.filter(function(e){return e.matches(t)})},createHDCA:function(t,e,n,s){var a=this,o={list:i.HistoryListDatasetCollection,paired:i.HistoryPairDatasetCollection},l=new o[e]({history_id:this.historyId,name:n,element_identifiers:t});return l.save().done(function(t){a.add(l)}).fail(function(t,e,i){a.trigger("error",t,e,i)})},clone:function(){var t=a.Collection.prototype.clone.call(this);return t.historyId=this.historyId,t},print:function(){var t=this;t.each(function(e){t.debug(e),e.elements&&t.debug(" elements:",e.elements)})},toString:function(){return["HistoryContents(",[this.historyId,this.length].join(),")"].join("")}});return{HistoryContents:d}}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(3),i(2),i(1))},function(t,e,i){var n,s;(function(a,o,l,r){n=[i(6),i(5)],s=function(t,e){"use strict";var i="list",n=a.View.extend(t.LoggableMixin).extend({_logNamespace:i,initialize:function(t){this.expanded=t.expanded||!1,this.log(" expanded:",this.expanded),this.fxSpeed=void 0!==t.fxSpeed?t.fxSpeed:this.fxSpeed},fxSpeed:"fast",render:function(t){var e=this._buildNewRender();return this._setUpBehaviors(e),this._queueNewRender(e,t),this},_buildNewRender:function(){var t=o(this.templates.el(this.model.toJSON(),this));return this.expanded&&this.$details(t).replaceWith(this._renderDetails().show()),t},_queueNewRender:function(t,e){e=void 0===e?this.fxSpeed:e;var i=this;o(i).queue("fx",[function(t){this.$el.fadeOut(e,t)},function(e){i._swapNewRender(t),e()},function(t){this.$el.fadeIn(e,t)},function(t){this.trigger("rendered",i),t()}])},_swapNewRender:function(t){return this.$el.empty().attr("class",l.isFunction(this.className)?this.className():this.className).append(t.children())},_setUpBehaviors:function(t){t=t||this.$el,t.find("[title]").tooltip({placement:"bottom"})},$details:function(t){return t=t||this.$el,t.find("> .details")},_renderDetails:function(){var t=o(this.templates.details(this.model.toJSON(),this));return this._setUpBehaviors(t),t},toggleExpanded:function(t){return t=void 0===t?!this.expanded:t,t?this.expand():this.collapse(),this},expand:function(){var t=this;return t._fetchModelDetails().always(function(){t._expand()})},_fetchModelDetails:function(){return this.model.hasDetails()?r.when():this.model.fetch()},_expand:function(){var t=this,e=t._renderDetails();t.$details().replaceWith(e),t.expanded=!0,t.$details().slideDown({duration:t.fxSpeed,step:function(){t.trigger("expanding",t)},complete:function(){t.trigger("expanded",t)}})},collapse:function(){this.debug(this+"(ExpandableView).collapse");var t=this;t.expanded=!1,this.$details().slideUp({duration:t.fxSpeed,step:function(){t.trigger("collapsing",t)},complete:function(){t.trigger("collapsed",t)}})}}),s=n.extend(t.mixin(t.SelectableViewMixin,t.DraggableViewMixin,{tagName:"div",className:"list-item",initialize:function(e){n.prototype.initialize.call(this,e),t.SelectableViewMixin.initialize.call(this,e),t.DraggableViewMixin.initialize.call(this,e),this._setUpListeners()},_setUpListeners:function(){return this.on("selectable",function(t){t?this.$(".primary-actions").hide():this.$(".primary-actions").show()},this),this},_buildNewRender:function(){var t=n.prototype._buildNewRender.call(this);return t.children(".warnings").replaceWith(this._renderWarnings()),t.children(".title-bar").replaceWith(this._renderTitleBar()),t.children(".primary-actions").append(this._renderPrimaryActions()),t.find("> .title-bar .subtitle").replaceWith(this._renderSubtitle()),t},_swapNewRender:function(t){return n.prototype._swapNewRender.call(this,t),this.selectable&&this.showSelector(0),this.draggable&&this.draggableOn(),this.$el},_renderWarnings:function(){var t=this,e=o('
    '),i=t.model.toJSON();return l.each(t.templates.warnings,function(n){e.append(o(n(i,t)))}),e},_renderTitleBar:function(){return o(this.templates.titleBar(this.model.toJSON(),this))},_renderPrimaryActions:function(){return[]},_renderSubtitle:function(){return o(this.templates.subtitle(this.model.toJSON(),this))},events:{"click .title-bar":"_clickTitleBar","keydown .title-bar":"_keyDownTitleBar","click .selector":"toggleSelect"},_clickTitleBar:function(t){t.stopPropagation(),t.altKey?(this.toggleSelect(t),this.selectable||this.showSelector()):this.toggleExpanded()},_keyDownTitleBar:function(t){var e=32,i=13;return!t||"keydown"!==t.type||t.keyCode!==e&&t.keyCode!==i?!0:(this.toggleExpanded(),t.stopPropagation(),!1)},toString:function(){var t=this.model?this.model+"":"(no model)";return"ListItemView("+t+")"}}));s.prototype.templates=function(){var e=t.wrapTemplate(['
    ','
    ','
    ','',"
    ",'
    ','
    ','
    ',"
    "]),i={},n=t.wrapTemplate(['
    ','','
    ','<%- element.name %>',"
    ",'
    ',"
    "],"element"),s=t.wrapTemplate(['
    ']),a=t.wrapTemplate(['
    ']);return{el:e,warnings:i,titleBar:n,subtitle:s,details:a}}();var c=s.extend({foldoutStyle:"foldout",foldoutPanelClass:null,initialize:function(t){"drilldown"===this.foldoutStyle&&(this.expanded=!1),this.foldoutStyle=t.foldoutStyle||this.foldoutStyle,this.foldoutPanelClass=t.foldoutPanelClass||this.foldoutPanelClass,s.prototype.initialize.call(this,t),this.foldout=this._createFoldoutPanel()},_renderDetails:function(){if("drilldown"===this.foldoutStyle)return o();var t=s.prototype._renderDetails.call(this);return this._attachFoldout(this.foldout,t)},_createFoldoutPanel:function(){var t=this.model,e=this._getFoldoutPanelClass(t),i=this._getFoldoutPanelOptions(t),n=new e(l.extend(i,{model:t}));return n},_getFoldoutPanelClass:function(){return this.foldoutPanelClass},_getFoldoutPanelOptions:function(){return{foldoutStyle:this.foldoutStyle,fxSpeed:this.fxSpeed}},_attachFoldout:function(t,e){return e=e||this.$("> .details"),this.foldout=t.render(0),t.$("> .controls").hide(),e.append(t.$el)},expand:function(){var t=this;return t._fetchModelDetails().always(function(){"foldout"===t.foldoutStyle?t._expand():"drilldown"===t.foldoutStyle&&t._expandByDrilldown()})},_expandByDrilldown:function(){var t=this;t.listenTo(t.foldout,"close",function(){t.trigger("collapsed:drilldown",t,t.foldout)}),t.trigger("expanded:drilldown",t,t.foldout)}});return c.prototype.templates=function(){var e=t.wrapTemplate(['
    ',"
    "],"collection");return l.extend({},s.prototype.templates,{details:e})}(),{ExpandableView:n,ListItemView:s,FoldoutListItemView:c}}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(3),i(1),i(2),i(1))},function(t,e,i){var n,s;(function(a,o){n=[i(4),i(55),i(7),i(38),i(18),i(28)],s=function(t,e,i,n,s,l){return n.extend({initialize:function(t){var i=this;n.prototype.initialize.call(this,t),this.deferred=new e,t.inputs?this._buildForm(t):this.deferred.execute(function(e){i._buildModel(e,t,!0)})},remove:function(){var t=this;this.$el.hide(),this.deferred.execute(function(){n.prototype.remove.call(t),Galaxy.emit.debug("tool-form-base::remove()","Destroy view.")})},_buildForm:function(e){var i=this;this.options=t.merge(e,this.options),this.options=t.merge({icon:e.icon,title:""+e.name+" "+e.description+" (Galaxy Version "+e.version+")",operations:this._operations(),onchange:function(){i.deferred.reset(),i.deferred.execute(function(t){i._updateModel(t)})}},this.options),this.options.customize&&this.options.customize(this.options),this.render(),this.options.collapsible||this.$el.append(a("
    ").addClass("ui-margin-top-large").append(this._footer()))},_buildModel:function(e,n,s){var o=this;this.options.id=n.id,this.options.version=n.version;var l="",r={};n.job_id?l=Galaxy.root+"api/jobs/"+n.job_id+"/build_for_rerun":(l=Galaxy.root+"api/tools/"+n.id+"/build",Galaxy.params&&Galaxy.params.tool_id==n.id&&(r=a.extend({},Galaxy.params),n.version&&(r.tool_version=n.version))),t.get({url:l,data:r,success:function(t){return t=t.tool_model||t,t.display?(o._buildForm(t),!s&&o.message.update({status:"success",message:"Now you are using '"+o.options.name+"' version "+o.options.version+", id '"+o.options.id+"'.",persistent:!1}),Galaxy.emit.debug("tool-form-base::initialize()","Initial tool model ready.",t),void e.resolve()):void(window.location=Galaxy.root)},error:function(t,n){var s=t&&t.err_msg||"Uncaught error.";401==n.status?window.location=Galaxy.root+"user/login?"+a.param({redirect:Galaxy.root+"?tool_id="+o.options.id}):o.$el.is(":empty")?o.$el.prepend(new i.Message({message:s,status:"danger",persistent:!0,large:!0}).$el):Galaxy.modal&&Galaxy.modal.show({title:"Tool request failed",body:s,buttons:{Close:function(){Galaxy.modal.hide()}}}),Galaxy.emit.debug("tool-form::initialize()","Initial tool model request failed.",t),e.reject()}})},_updateModel:function(e){var i=this,n=this.options.update_url||Galaxy.root+"api/tools/"+this.options.id+"/build",s={tool_id:this.options.id,tool_version:this.options.version,inputs:a.extend(!0,{},i.data.create())};this.wait(!0),Galaxy.emit.debug("tool-form-base::_updateModel()","Sending current state.",s),t.request({type:"POST",url:n,data:s,success:function(t){i.update(t.tool_model||t),i.options.update&&i.options.update(t),i.wait(!1),Galaxy.emit.debug("tool-form-base::_updateModel()","Received new model.",t),e.resolve()},error:function(t){Galaxy.emit.debug("tool-form-base::_updateModel()","Refresh request failed.",t),e.reject()}})},_operations:function(){var t=this,e=this.options,n=new i.ButtonMenu({icon:"fa-cubes",title:!e.narrow&&"Versions"||null,tooltip:"Select another tool version"});if(!e.sustain_version&&e.versions&&e.versions.length>1)for(var s in e.versions){var a=e.versions[s];a!=e.version&&n.addMenu({title:"Switch to "+a,version:a,icon:"fa-cube",onclick:function(){var i=e.id.replace(e.version,this.version),n=this.version;t.deferred.reset(),t.deferred.execute(function(e){t._buildModel(e,{id:i,version:n})})}})}else n.$el.hide();var o=new i.ButtonMenu({icon:"fa-caret-down",title:!e.narrow&&"Options"||null,tooltip:"View available options"});return e.biostar_url&&(o.addMenu({icon:"fa-question-circle",title:"Question?",tooltip:"Ask a question about this tool (Biostar)",onclick:function(){window.open(e.biostar_url+"/p/new/post/")}}),o.addMenu({icon:"fa-search",title:"Search",tooltip:"Search help for this tool (Biostar)",onclick:function(){window.open(e.biostar_url+"/local/search/page/?q="+e.name)}})),o.addMenu({icon:"fa-share",title:"Share",tooltip:"Share this tool",onclick:function(){prompt("Copy to clipboard: Ctrl+C, Enter",window.location.origin+Galaxy.root+"root?tool_id="+e.id)}}),Galaxy.user&&Galaxy.user.get("is_admin")&&o.addMenu({icon:"fa-download",title:"Download",tooltip:"Download this tool",onclick:function(){window.location.href=Galaxy.root+"api/tools/"+e.id+"/download"}}),e.requirements&&e.requirements.length>0&&o.addMenu({icon:"fa-info-circle",title:"Requirements",tooltip:"Display tool requirements",onclick:function(){!this.visible||t.portlet.collapsed?(this.visible=!0,t.portlet.expand(),t.message.update({persistent:!0,message:t._templateRequirements(e),status:"info"})):(this.visible=!1,t.message.update({message:""}))}}),e.sharable_url&&o.addMenu({icon:"fa-external-link",title:"See in Tool Shed",tooltip:"Access the repository",onclick:function(){window.open(e.sharable_url)}}),{menu:o,versions:n}},_footer:function(){var t=this.options,e=a("
    ").append(this._templateHelp(t));if(t.citations){var i=a("
    "),n=new s.ToolCitationCollection;n.tool_id=t.id;var o=new l.CitationListView({el:i,collection:n});o.render(),n.fetch(),e.append(i)}return e},_templateHelp:function(t){var e=a("
    ").addClass("ui-form-help").append(t.help);return e.find("a").attr("target","_blank"),e},_templateRequirements:function(t){var e=t.requirements.length;if(e>0){var i="This tool requires ";o.each(t.requirements,function(t,n){i+=t.name+(t.version?" (Version "+t.version+")":"")+(e-2>n?", ":n==e-2?" and ":"")});var n=a("").attr("target","_blank").attr("href","https://wiki.galaxyproject.org/Tools/Requirements").text("here");return a("").append(i+". Click ").append(n).append(" for more information.")}return"No requirements found."}})}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(1),i(2))},function(t,e,i){var n,s;(function(a,o){n=[i(2),i(17),i(12),i(19)],s=function(t,e,i,n){"use strict";var s={hidden:!1,show:function(){this.set("hidden",!1)},hide:function(){this.set("hidden",!0)},toggle:function(){this.set("hidden",!this.get("hidden"))},is_visible:function(){return!this.attributes.hidden}},l=a.Model.extend({defaults:{name:null,label:null,type:null,value:null,html:null,num_samples:5},initialize:function(t){this.attributes.html=unescape(this.attributes.html)},copy:function(){return new l(this.toJSON())},set_value:function(t){this.set("value",t||"")}}),r=a.Collection.extend({model:l}),c=l.extend({}),d=l.extend({set_value:function(t){this.set("value",parseInt(t,10))},get_samples:function(){return d3.scale.linear().domain([this.get("min"),this.get("max")]).ticks(this.get("num_samples"))}}),h=d.extend({set_value:function(t){this.set("value",parseFloat(t))}}),u=l.extend({get_samples:function(){return t.map(this.get("options"),function(t){return t[0]})}});l.subModelTypes={integer:d,"float":h,data:c,select:u};var p=a.Model.extend({defaults:{id:null,name:null,description:null,target:null,inputs:[],outputs:[]},urlRoot:Galaxy.root+"api/tools",initialize:function(e){this.set("inputs",new r(t.map(e.inputs,function(t){var e=l.subModelTypes[t.type]||l;return new e(t)})))},toJSON:function(){var t=a.Model.prototype.toJSON.call(this);return t.inputs=this.get("inputs").map(function(t){return t.toJSON()}),t},remove_inputs:function(t){var e=this,i=e.get("inputs").filter(function(e){return-1!==t.indexOf(e.get("type"))});e.get("inputs").remove(i)},copy:function(t){var e=new p(this.toJSON());if(t){var i=new a.Collection;e.get("inputs").each(function(t){t.get_samples()&&i.push(t)}),e.set("inputs",i)}return e},apply_search_results:function(e){return-1!==t.indexOf(e,this.attributes.id)?this.show():this.hide(),this.is_visible()},set_input_value:function(t,e){this.get("inputs").find(function(e){return e.get("name")===t}).set("value",e)},set_input_values:function(e){var i=this;t.each(t.keys(e),function(t){i.set_input_value(t,e[t])})},run:function(){return this._run()},rerun:function(t,e){return this._run({action:"rerun",target_dataset_id:t.id,regions:e})},get_inputs_dict:function(){var t={};return this.get("inputs").each(function(e){t[e.get("name")]=e.get("value")}),t},_run:function(n){var s=t.extend({tool_id:this.id,inputs:this.get_inputs_dict()},n),a=o.Deferred(),l=new e.ServerStateDeferred({ajax_settings:{url:this.urlRoot,data:JSON.stringify(s),dataType:"json",contentType:"application/json",type:"POST"},interval:2e3,success_fn:function(t){return"pending"!==t}});return o.when(l.go()).then(function(t){a.resolve(new i.DatasetCollection(t))}),a}});t.extend(p.prototype,s);var g=(a.View.extend({}),a.Collection.extend({model:p})),f=a.Model.extend(s),m=a.Model.extend({defaults:{elems:[],open:!1},clear_search_results:function(){t.each(this.attributes.elems,function(t){t.show()}),this.show(),this.set("open",!1)},apply_search_results:function(e){var i,n=!0;t.each(this.attributes.elems,function(t){t instanceof f?(i=t,i.hide()):t instanceof p&&t.apply_search_results(e)&&(n=!1,i&&i.show())}),n?this.hide():(this.show(),this.set("open",!0))}});t.extend(m.prototype,s);var v=a.Model.extend({defaults:{search_hint_string:"search tools",min_chars_for_search:3,clear_btn_url:"",search_url:"",visible:!0,query:"",results:null,clear_key:27},urlRoot:Galaxy.root+"api/tools",initialize:function(){this.on("change:query",this.do_search)},do_search:function(){var t=this.attributes.query;if(t.length");t.append(S.tool_link(this.model.toJSON()));var e=this.model.get("form_style",null);if("upload1"===this.model.id)t.find("a").on("click",function(t){t.preventDefault(),Galaxy.upload.show()});else if("regular"===e){var i=this;t.find("a").on("click",function(t){t.preventDefault();var e=new n.View({id:i.model.id,version:i.model.get("version")});e.deferred.execute(function(){Galaxy.app.display(e)})})}return this.$el.append(t),this}}),w=y.extend({tagName:"div",className:"toolPanelLabel",render:function(){return this.$el.append(o("").text(this.model.attributes.text)),this}}),x=y.extend({tagName:"div",className:"toolSectionWrapper",initialize:function(){y.prototype.initialize.call(this),this.model.on("change:open",this.update_open,this)},render:function(){this.$el.append(S.panel_section(this.model.toJSON()));var e=this.$el.find(".toolSectionBody");return t.each(this.model.attributes.elems,function(t){if(t instanceof p){var i=new b({model:t,className:"toolTitle"});i.render(),e.append(i.$el)}else if(t instanceof f){var n=new w({model:t});n.render(),e.append(n.$el)}}),this},events:{"click .toolSectionTitle > a":"toggle"},toggle:function(){this.model.set("open",!this.model.attributes.open)},update_open:function(){this.model.attributes.open?this.$el.children(".toolSectionBody").slideDown("fast"):this.$el.children(".toolSectionBody").slideUp("fast")}}),C=a.View.extend({tagName:"div",id:"tool-search",className:"bar",events:{click:"focus_and_select","keyup :input":"query_changed","click #search-clear-btn":"clear"},render:function(){return this.$el.append(S.tool_search(this.model.toJSON())),this.model.is_visible()||this.$el.hide(),this.$el.find("[title]").tooltip(),this},focus_and_select:function(){this.$el.find(":input").focus().select()},clear:function(){return this.model.clear_search(),this.$el.find(":input").val(""),this.focus_and_select(),!1},query_changed:function(t){return this.model.attributes.clear_key&&this.model.attributes.clear_key===t.which?(this.clear(),!1):void this.model.set("query",this.$el.find(":input").val())}}),$=a.View.extend({tagName:"div",className:"toolMenu",initialize:function(){this.model.get("tool_search").on("change:results",this.handle_search_results,this)},render:function(){var t=this,e=new C({model:this.model.get("tool_search")});return e.render(),t.$el.append(e.$el),this.model.get("layout").each(function(e){if(e instanceof m){var i=new x({model:e});i.render(),t.$el.append(i.$el)}else if(e instanceof p){var n=new b({model:e,className:"toolTitleNoSection"});n.render(),t.$el.append(n.$el)}else if(e instanceof f){var s=new w({model:e});s.render(),t.$el.append(s.$el)}}),t.$el.find("a.tool-link").click(function(e){var i=o(this).attr("class").split(/\s+/)[0],n=t.model.get("tools").get(i);t.trigger("tool_link_click",e,n)}),this},handle_search_results:function(){var t=this.model.get("tool_search").get("results");t&&0===t.length?o("#search-no-results").show():o("#search-no-results").hide()}}),E=a.View.extend({className:"toolForm",render:function(){this.$el.children().remove(),this.$el.append(S.tool_form(this.model.toJSON()))}}),S=(a.View.extend({className:"toolMenuAndView",initialize:function(){this.tool_panel_view=new $({collection:this.collection}),this.tool_form_view=new E},render:function(){this.tool_panel_view.render(),this.tool_panel_view.$el.css("float","left"),this.$el.append(this.tool_panel_view.$el),this.tool_form_view.$el.hide(),this.$el.append(this.tool_form_view.$el);var t=this;this.tool_panel_view.on("tool_link_click",function(e,i){e.preventDefault(),t.show_tool(i)})},show_tool:function(t){var e=this;t.fetch().done(function(){e.tool_form_view.model=t,e.tool_form_view.render(),e.tool_form_view.$el.show(),o("#left").width("650px")})}}),{tool_search:t.template(['',' ',''].join("")),panel_section:t.template(['",'