"use strict";var e=function(e){return e&&e.__esModule?e["default"]:e},t=e(require("react")),s=require("atom").CompositeDisposable,n=e(require("../../common/directory-tree-view")),a=e(require("path")),i=e(require("normalize-path")),o=e(require("../../common/get-asset-packs"));module.exports=t.createClass({displayName:"choose-rule-modal",onChoose:function(){var e=this.state.currentAssetPack,t=a.join(e.root,"rules"),s=a.relative(t,this.state.currentRule);s=i(s),"project"!==this.state.currentAssetPack.id&&(s=e.id+"://"+s),this.props.onChoose(s),this.props.onClose()},onCancel:function(){this.props.onClose()},getLength:function(){return Object.keys(this.behaviorToIndexMap).length},getInitialState:function(){return{currentAssetPack:{id:"project"},currentRule:"",filter:""}},onAssetPackSelected:function(e){this.setState({currentAssetPack:e})},onSelected:function(e){this.setState({currentRule:e})},getPanelHeading:function(e){return t.createElement("div",{className:"panel-heading",style:{padding:"0px",width:"100%",height:30}},t.createElement("p",{style:{textAlign:"center",marginTop:"4px",marginBottom:"4px"}},e))},render:function(){for(var e=this,s=o(this.props.root),i=void 0,r=[],c=0;c