From 1a8e6e6d8e5d5a949c70938f2c7ffe35a465512f Mon Sep 17 00:00:00 2001 From: Chandra Lash Date: Thu, 3 Nov 2016 02:05:10 -0500 Subject: [PATCH] Updated help link, embedded player per site (#892) space to trick timeout exception Removed switch statement Add myplayer var via Ansible template Update default myplayer for local dev environment --- cadasta/core/static/css/main.css | 82 +++++++++---------- cadasta/core/static/css/main.scss | 4 +- .../core/static/js/inline-manual-player.js | 30 +++---- cadasta/templates/core/base.html | 14 +--- .../roles/cadasta/production/tasks/main.yml | 6 ++ .../production/templates/inline-manual-player | 17 ++++ 6 files changed, 83 insertions(+), 70 deletions(-) create mode 100644 provision/roles/cadasta/production/templates/inline-manual-player diff --git a/cadasta/core/static/css/main.css b/cadasta/core/static/css/main.css index 8dde3ba3d..d6bb280f7 100644 --- a/cadasta/core/static/css/main.css +++ b/cadasta/core/static/css/main.css @@ -4694,7 +4694,7 @@ header { color: #fff; text-decoration: none; background: #0e305e; } - header .btn-info { + header .btn-help { border-radius: 0; padding-top: 28px; min-width: 70px; @@ -4705,84 +4705,84 @@ header { background-color: transparent; border-color: #2e51a3; border-left: solid 1px #345bb7; } - header .btn-info:focus, header .btn-info.focus { + header .btn-help:focus, header .btn-help.focus { color: #eeeeee; background-color: transparent; border-color: #122040; } - header .btn-info:hover { + header .btn-help:hover { color: #eeeeee; background-color: transparent; border-color: #213973; } - header .btn-info:active, header .btn-info.active, - .open > header .btn-info.dropdown-toggle { + header .btn-help:active, header .btn-help.active, + .open > header .btn-help.dropdown-toggle { color: #eeeeee; background-color: transparent; border-color: #213973; } - header .btn-info:active:hover, header .btn-info:active:focus, header .btn-info:active.focus, header .btn-info.active:hover, header .btn-info.active:focus, header .btn-info.active.focus, - .open > header .btn-info.dropdown-toggle:hover, - .open > header .btn-info.dropdown-toggle:focus, - .open > header .btn-info.dropdown-toggle.focus { + header .btn-help:active:hover, header .btn-help:active:focus, header .btn-help:active.focus, header .btn-help.active:hover, header .btn-help.active:focus, header .btn-help.active.focus, + .open > header .btn-help.dropdown-toggle:hover, + .open > header .btn-help.dropdown-toggle:focus, + .open > header .btn-help.dropdown-toggle.focus { color: #eeeeee; background-color: transparent; border-color: #122040; } - header .btn-info:active, header .btn-info.active, - .open > header .btn-info.dropdown-toggle { + header .btn-help:active, header .btn-help.active, + .open > header .btn-help.dropdown-toggle { background-image: none; } - header .btn-info.disabled:hover, header .btn-info.disabled:focus, header .btn-info.disabled.focus, header .btn-info[disabled]:hover, header .btn-info[disabled]:focus, header .btn-info[disabled].focus, - fieldset[disabled] header .btn-info:hover, - fieldset[disabled] header .btn-info:focus, - fieldset[disabled] header .btn-info.focus { + header .btn-help.disabled:hover, header .btn-help.disabled:focus, header .btn-help.disabled.focus, header .btn-help[disabled]:hover, header .btn-help[disabled]:focus, header .btn-help[disabled].focus, + fieldset[disabled] header .btn-help:hover, + fieldset[disabled] header .btn-help:focus, + fieldset[disabled] header .btn-help.focus { background-color: transparent; border-color: #2e51a3; } - header .btn-info .badge { + header .btn-help .badge { color: transparent; background-color: #eeeeee; } - header .btn-info:hover, header .btn-info:focus { + header .btn-help:hover, header .btn-help:focus { color: #fff; background-color: #28478f; border-color: #2e51a3; transition: all 0.3s ease 0s; } - header .btn-info:hover:focus, header .btn-info:hover.focus, header .btn-info:focus:focus, header .btn-info:focus.focus { + header .btn-help:hover:focus, header .btn-help:hover.focus, header .btn-help:focus:focus, header .btn-help:focus.focus { color: #fff; background-color: #1d3367; border-color: #122040; } - header .btn-info:hover:hover, header .btn-info:focus:hover { + header .btn-help:hover:hover, header .btn-help:focus:hover { color: #fff; background-color: #1d3367; border-color: #213973; } - header .btn-info:hover:active, header .btn-info:hover.active, - .open > header .btn-info:hover.dropdown-toggle, header .btn-info:focus:active, header .btn-info:focus.active, - .open > header .btn-info:focus.dropdown-toggle { + header .btn-help:hover:active, header .btn-help:hover.active, + .open > header .btn-help:hover.dropdown-toggle, header .btn-help:focus:active, header .btn-help:focus.active, + .open > header .btn-help:focus.dropdown-toggle { color: #fff; background-color: #1d3367; border-color: #213973; } - header .btn-info:hover:active:hover, header .btn-info:hover:active:focus, header .btn-info:hover:active.focus, header .btn-info:hover.active:hover, header .btn-info:hover.active:focus, header .btn-info:hover.active.focus, - .open > header .btn-info:hover.dropdown-toggle:hover, - .open > header .btn-info:hover.dropdown-toggle:focus, - .open > header .btn-info:hover.dropdown-toggle.focus, header .btn-info:focus:active:hover, header .btn-info:focus:active:focus, header .btn-info:focus:active.focus, header .btn-info:focus.active:hover, header .btn-info:focus.active:focus, header .btn-info:focus.active.focus, - .open > header .btn-info:focus.dropdown-toggle:hover, - .open > header .btn-info:focus.dropdown-toggle:focus, - .open > header .btn-info:focus.dropdown-toggle.focus { + header .btn-help:hover:active:hover, header .btn-help:hover:active:focus, header .btn-help:hover:active.focus, header .btn-help:hover.active:hover, header .btn-help:hover.active:focus, header .btn-help:hover.active.focus, + .open > header .btn-help:hover.dropdown-toggle:hover, + .open > header .btn-help:hover.dropdown-toggle:focus, + .open > header .btn-help:hover.dropdown-toggle.focus, header .btn-help:focus:active:hover, header .btn-help:focus:active:focus, header .btn-help:focus:active.focus, header .btn-help:focus.active:hover, header .btn-help:focus.active:focus, header .btn-help:focus.active.focus, + .open > header .btn-help:focus.dropdown-toggle:hover, + .open > header .btn-help:focus.dropdown-toggle:focus, + .open > header .btn-help:focus.dropdown-toggle.focus { color: #fff; background-color: #15264b; border-color: #122040; } - header .btn-info:hover:active, header .btn-info:hover.active, - .open > header .btn-info:hover.dropdown-toggle, header .btn-info:focus:active, header .btn-info:focus.active, - .open > header .btn-info:focus.dropdown-toggle { + header .btn-help:hover:active, header .btn-help:hover.active, + .open > header .btn-help:hover.dropdown-toggle, header .btn-help:focus:active, header .btn-help:focus.active, + .open > header .btn-help:focus.dropdown-toggle { background-image: none; } - header .btn-info:hover.disabled:hover, header .btn-info:hover.disabled:focus, header .btn-info:hover.disabled.focus, header .btn-info:hover[disabled]:hover, header .btn-info:hover[disabled]:focus, header .btn-info:hover[disabled].focus, - fieldset[disabled] header .btn-info:hover:hover, - fieldset[disabled] header .btn-info:hover:focus, - fieldset[disabled] header .btn-info:hover.focus, header .btn-info:focus.disabled:hover, header .btn-info:focus.disabled:focus, header .btn-info:focus.disabled.focus, header .btn-info:focus[disabled]:hover, header .btn-info:focus[disabled]:focus, header .btn-info:focus[disabled].focus, - fieldset[disabled] header .btn-info:focus:hover, - fieldset[disabled] header .btn-info:focus:focus, - fieldset[disabled] header .btn-info:focus.focus { + header .btn-help:hover.disabled:hover, header .btn-help:hover.disabled:focus, header .btn-help:hover.disabled.focus, header .btn-help:hover[disabled]:hover, header .btn-help:hover[disabled]:focus, header .btn-help:hover[disabled].focus, + fieldset[disabled] header .btn-help:hover:hover, + fieldset[disabled] header .btn-help:hover:focus, + fieldset[disabled] header .btn-help:hover.focus, header .btn-help:focus.disabled:hover, header .btn-help:focus.disabled:focus, header .btn-help:focus.disabled.focus, header .btn-help:focus[disabled]:hover, header .btn-help:focus[disabled]:focus, header .btn-help:focus[disabled].focus, + fieldset[disabled] header .btn-help:focus:hover, + fieldset[disabled] header .btn-help:focus:focus, + fieldset[disabled] header .btn-help:focus.focus { background-color: #28478f; border-color: #2e51a3; } - header .btn-info:hover .badge, header .btn-info:focus .badge { + header .btn-help:hover .badge, header .btn-help:focus .badge { color: #28478f; background-color: #fff; } - header .btn-info .glyphicon-info-sign { + header .btn-help .glyphicon-question-sign { font-size: 18px; width: 48px; height: 32px; } diff --git a/cadasta/core/static/css/main.scss b/cadasta/core/static/css/main.scss index 808fef751..adbcefd83 100644 --- a/cadasta/core/static/css/main.scss +++ b/cadasta/core/static/css/main.scss @@ -180,7 +180,7 @@ header { } } } - .btn-info { // info button + .btn-help { // help button border-radius: 0; padding-top: 28px; min-width: $header-height; @@ -194,7 +194,7 @@ header { @include button-variant(#fff, darken($btn-blue-bg, 5%), $btn-blue-bg); transition: all 0.3s ease 0s; } - .glyphicon-info-sign { + .glyphicon-question-sign { font-size: 18px; width: 48px; height: 32px; diff --git a/cadasta/core/static/js/inline-manual-player.js b/cadasta/core/static/js/inline-manual-player.js index d4d4f0108..7530aac8b 100644 --- a/cadasta/core/static/js/inline-manual-player.js +++ b/cadasta/core/static/js/inline-manual-player.js @@ -1,21 +1,17 @@ -// Last update at: 2016-09-02 01:35:33 UTC -// /* Inline Manual Player, v2.34.1 http://inlinemanual.com/ */ -!function(){"use strict";var expose;(expose=function(lib,lib_name){var noConflict;noConflict=function(root){var original_lib;return original_lib=root[lib_name],lib.noConflict=function(){return root[lib_name]=original_lib,lib},root[lib_name]=lib},("undefined"!=typeof module&&null!==module?module.exports:void 0)&&(module.exports=lib),("undefined"!=typeof define&&null!==define?define.amd:void 0)&&define(lib_name,[],function(){return lib}),"object"==typeof window?noConflict(window,lib,lib_name):"object"==typeof global&&noConflict(global,lib,lib_name)})(expose,"expose")}(),function(){var EventBridge,root;null==Array.isArray&&(Array.isArray=function(argument){return"[object Array]"===Object.prototype.toString.call(argument)}),EventBridge={add:function(object,event,callback){var i,len,single_event;if(null==callback&&(callback=function(){}),Array.isArray(event))for(i=0,len=event.length;i_ref1;x=_ref<=_ref1?++_i:--_i)for(y=_j=_ref2=block.y1,_ref3=block.y2;_ref2<=_ref3?_j<_ref3:_j>_ref3;y=_ref2<=_ref3?++_j:--_j)matrix[y][x]=1;return matrix},GapGrid.prototype.getAllMatrixBlocks=function(matrix){var block,result,x,y,_i,_j,_ref,_ref1;for(result=[],y=_i=0,_ref=matrix.length;0<=_ref?_i<_ref:_i>_ref;y=0<=_ref?++_i:--_i)for(x=_j=0,_ref1=matrix[0].length;0<=_ref1?_j<_ref1:_j>_ref1;x=0<=_ref1?++_j:--_j)0===matrix[y][x]&&(block=this.getMatrixBlock(matrix,x,y),matrix=this.markMatrixBlock(matrix,block),result.push(block));return result},GapGrid.prototype.generate=function(){var block,blocks,matrix,points,result,_i,_len;for(result=[],points=this.getGridPoints(),matrix=this.getGridMatrix(points),blocks=this.getAllMatrixBlocks(matrix),_i=0,_len=blocks.length;_i<_len;_i++)block=blocks[_i],result.push({left:points.horizontal[block.x1],width:points.horizontal[block.x2]-points.horizontal[block.x1],top:points.vertical[block.y1],height:points.vertical[block.y2]-points.vertical[block.y1]});return result},GapGrid}(),"undefined"!=typeof expose&&null!==expose?expose(GapGrid,"GapGrid"):(root="object"==typeof exports?exports:this,root.GapGrid=GapGrid)}.call(this),function(){var Backdrop,root;Backdrop=function(){function Backdrop(options){var _this=this;null==options&&(options={}),this.checkDependencies(),this.backdrops=[],this.covers=[],this.is_active=!1,this.options={},this.setOptions(this.default_options),this.setOptions(options),this.element_monitor=new ElementMonitor(null,{interval:this.options.watch_interval,onChange:function(){return _this.draw()}}),EventBridge.add(window,"resize",function(){return _this.redraw()})}return Backdrop.prototype.default_options={backdrop_class:"backdrop",z_index:1e3,padding:5,color:"#000000",opacity:.5,hide_on_click:!0,cover:!1,watch:!1,watch_interval:500,onShow:function(){},onHide:function(){}},Backdrop.prototype.checkDependencies=function(){var dependencies,label,obj,_i,_len,_results;for(dependencies={DomBox:DomBox,EventBridge:EventBridge,GapGrid:GapGrid,ElementMonitor:ElementMonitor,ElementCollector:ElementCollector},_results=[],obj=_i=0,_len=dependencies.length;_i<_len;obj=++_i){if(label=dependencies[obj],null==obj)throw new Error("Backdrop requires "+label+" library to operate.");_results.push(void 0)}return _results},Backdrop.prototype.setOptions=function(options){var key,val,_results;null==options&&(options={}),_results=[];for(key in options)val=options[key],null!=this.default_options[key]?_results.push(this.options[key]=val):_results.push(void 0);return _results},Backdrop.prototype.add=function(element){return this.element_monitor.addElement(element),this.redraw()},Backdrop.prototype.remove=function(element){return this.element_monitor.removeElement(element),this.redraw()},Backdrop.prototype.set=function(element){return this.element_monitor.setElement(element),this.redraw()},Backdrop.prototype.sanitizeEmptySpace=function(empty_space){var key,val;for(key in empty_space)val=empty_space[key],empty_space[key]=Math.round(val);return empty_space},Backdrop.prototype.removeBackdrops=function(){var backdrop,_i,_len,_ref;for(_ref=this.backdrops,_i=0,_len=_ref.length;_i<_len;_i++)backdrop=_ref[_i],backdrop.parentNode.removeChild(backdrop);return this.backdrops=[]},Backdrop.prototype.addBackdrops=function(gaps){var canvas,empty_space,gap_grid,_i,_len,_ref;for(canvas={left:0,top:0,width:DomBox.Document.getWidth(),height:DomBox.Document.getHeight()},gap_grid=new GapGrid(canvas,gaps),_ref=gap_grid.generate(),_i=0,_len=_ref.length;_i<_len;_i++)empty_space=_ref[_i],this.backdrops.push(this.createBackdrop(this.sanitizeEmptySpace(empty_space)));return this.backdrops},Backdrop.prototype.createBackdrop=function(box){var elm,ieOpacity,key,properties,val,_this=this;elm=document.createElement("div"),elm.className=this.options.backdrop_class,ieOpacity=100*this.options.opacity,properties={position:"absolute",left:""+box.left+"px",top:""+box.top+"px",width:""+box.width+"px",height:""+box.height+"px",zIndex:this.options.z_index,backgroundColor:this.options.color,opacity:this.options.opacity,MsFilter:"progid:DXImageTransform.Microsoft.Alpha(Opacity="+ieOpacity+")",filter:"alpha(opacity="+ieOpacity+")"};for(key in properties)val=properties[key],elm.style[key]=val;return this.options.hide_on_click&&EventBridge.add(elm,"click",function(){return _this.hide()}),document.body.appendChild(elm)},Backdrop.prototype.addCover=function(box){var cover,key,properties,val,_this=this;cover=document.createElement("div"),properties={position:"absolute",left:""+box.left+"px",top:""+box.top+"px",width:""+box.width+"px",height:""+box.height+"px",zIndex:this.options.z_index};for(key in properties)val=properties[key],cover.style[key]=val;return this.options.hide_on_click&&EventBridge.add(cover,"click",function(){return _this.hide()}),document.body.appendChild(cover),this.covers.push(cover)},Backdrop.prototype.addCovers=function(boxes){var box,_i,_len,_results;for(this.removeCovers(),_results=[],_i=0,_len=boxes.length;_i<_len;_i++)box=boxes[_i],_results.push(this.addCover(box));return _results},Backdrop.prototype.removeCovers=function(){var cover,_i,_len,_ref;for(_ref=this.covers,_i=0,_len=_ref.length;_i<_len;_i++)cover=_ref[_i],cover.parentNode.removeChild(cover);return this.covers=[]},Backdrop.prototype.draw=function(){var element,target_box,target_boxes,_i,_len,_ref;for(this.removeBackdrops(),this.removeCovers(),target_boxes=[],_ref=this.element_monitor.getElements(),_i=0,_len=_ref.length;_i<_len;_i++)element=_ref[_i],target_box=DomBox.getBox(element),null!=target_box&&(target_box.setPadding(this.options.padding),target_boxes.push(target_box));if(this.addBackdrops(target_boxes),this.options.cover)return this.addCovers(target_boxes)},Backdrop.prototype.show=function(element){return null!=element&&this.set(element),this.element_monitor.stop(),this.draw(),this.options.watch===!0&&this.element_monitor.start(),this.is_active=!0,this.options.onShow(this)},Backdrop.prototype.hide=function(){return this.element_monitor.stop(),this.removeBackdrops(),this.removeCovers(),this.is_active=!1,this.options.onHide(this)},Backdrop.prototype.redraw=function(){if(this.is_active)return this.draw()},Backdrop.prototype.destroy=function(){return this.hide()},Backdrop}(),"undefined"!=typeof expose&&null!==expose?expose(Backdrop,"Backdrop"):(root="object"==typeof exports?exports:this,root.Backdrop=Backdrop)}.call(this),function(){var Angle,root;Angle=function(){function Angle(options){null==options&&(options={}),this.setOptions(options)}return Angle.prototype.default_options={directions_start:0,directions:"right topRight top topLeft left bottomLeft bottom bottomRight".split(" ")},Angle.prototype.setOptions=function(options){var key,val,_ref;null==options&&(options={}),this.options={},_ref=this.default_options;for(key in _ref)val=_ref[key],this.options[key]=options[key]||this.default_options[key];return this.options},Angle.prototype.fromRad=function(angle){return angle*(180/Math.PI)},Angle.prototype.toRad=function(angle){return angle*(Math.PI/180)},Angle.prototype.normalize=function(angle){var result;return null==angle&&(angle=0),result=isNaN(angle)?0:angle,result%=360,result<0&&(result+=360),result},Angle.prototype.toDirection=function(angle){var index;return angle=this.normalize(angle),angle-=this.options.directions_start,angle=this.normalize(angle),index=Math.round(angle/(360/this.options.directions.length)),this.options.directions[index]||this.options.directions[0]},Angle.prototype.fromDirection=function(direction){var angle,d,i,index,_i,_len,_ref;for(index=-1,_ref=this.options.directions,i=_i=0,_len=_ref.length;_i<_len;i=++_i)d=_ref[i],d===direction&&(index=i);return index===-1?null:(angle=index*(360/this.options.directions.length),angle=this.options.directions_start+angle)},Angle}(),"undefined"!=typeof expose&&null!==expose?expose(Angle,"Angle"):(root="object"==typeof exports?exports:this,root.Angle=Angle)}.call(this),function(){var checkVisibility,getStyle,isVisible;getStyle=function(element,property){return element.currentStyle?element.currentStyle[property]:window.getComputedStyle?document.defaultView.getComputedStyle(element,null).getPropertyValue(property):null},checkVisibility=function(element){var is_displayed,is_visible;return is_displayed="none"!==getStyle(element,"display"),is_visible="hidden"!==getStyle(element,"visibility"),is_displayed&&is_visible},isVisible=function(element){var _ref;if(!(null!=(_ref=document.body)?_ref.contains(element):void 0))return!1;for(;null!=element&&element!==document.body;){if(!checkVisibility(element))return!1;element=element.parentNode}return!0},isVisible.all=function(list){var item,_i,_len;for(_i=0,_len=list.length;_i<_len;_i++)if(item=list[_i],!this(item))return!1;return!0},isVisible.any=function(list){var item,_i,_len;for(_i=0,_len=list.length;_i<_len;_i++)if(item=list[_i],this(item))return!0;return!1},"undefined"!=typeof expose&&null!==expose?expose(isVisible,"isVisible"):window.isVisible=isVisible}.call(this),function(){var DomBox,dependencies,getExtremes,isElement,label,obj,root,_i,_len,__hasProp={}.hasOwnProperty,__extends=function(child,parent){function ctor(){this.constructor=child}for(var key in parent)__hasProp.call(parent,key)&&(child[key]=parent[key]);return ctor.prototype=parent.prototype,child.prototype=new ctor,child.__super__=parent.prototype,child};for(getExtremes=function(boxes){var all_properties,box,data,key,max_properties,min_properties,property,result,_i,_j,_k,_l,_len,_len1,_len2,_len3;for(null==boxes&&(boxes=[]),result={},min_properties=["left","top","view_left","view_top"],max_properties=["right","bottom","view_right","view_bottom"],all_properties=[].concat(min_properties,max_properties),data={},_i=0,_len=all_properties.length;_i<_len;_i++)for(key=all_properties[_i],data[key]=[],_j=0,_len1=boxes.length;_j<_len1;_j++)box=boxes[_j],data[key].push(box[key]);for(_k=0,_len2=min_properties.length;_k<_len2;_k++)property=min_properties[_k],result[property]=Math.min.apply(null,data[property]);for(_l=0,_len3=max_properties.length;_l<_len3;_l++)property=max_properties[_l],result[property]=Math.max.apply(null,data[property]);return result.width=result.right-result.left,result.height=result.bottom-result.top,result},isElement=function(obj){return null!=obj&&"object"==typeof obj&&1===obj.nodeType&&"object"==typeof obj.style&&"object"==typeof obj.ownerDocument},dependencies={isVisible:isVisible,Angle:Angle},obj=_i=0,_len=dependencies.length;_i<_len;obj=++_i)if(label=dependencies[obj],null==obj)throw new Error("DomBox requires "+label+" library to operate.");DomBox={angle:new Angle,getBox:function(input){return"string"==typeof input?new this.CollectionBox(input):isElement(input)?new this.ElementBox(input):input instanceof DomBox.Box?input:null},getDistance:function(box1,box2){var bounding_box,result;return box1=DomBox.getBox(box1),box2=DomBox.getBox(box2),bounding_box=getExtremes([box1,box2]),result={horizontal:bounding_box.width-(box1.width+box2.width),vertical:bounding_box.height-(box1.height+box2.height)},result.horizontal<0&&(result.horizontal=0),result.vertical<0&&(result.vertical=0),result},detectOverlap:function(box1,box2){var bounding_box,overlap;return box1=DomBox.getBox(box1),box2=DomBox.getBox(box2),bounding_box=getExtremes([box1,box2]),overlap={horizontal:bounding_box.width-(box1.width+box2.width),vertical:bounding_box.height-(box1.height+box2.height)},overlap.horizontal<0&&overlap.vertical<0},getPivotDistance:function(box1,box2){var pivot1,pivot2,x,y;return box1=DomBox.getBox(box1),box2=DomBox.getBox(box2),pivot1=box1.getPivot(),pivot2=box2.getPivot(),x=pivot1.left-pivot2.left,y=pivot1.top-pivot2.top,Math.sqrt(Math.pow(x,2)+Math.pow(y,2))},getPivotAngle:function(box1,box2){var angle_deg,angle_rad,pivot1,pivot2;return box1=DomBox.getBox(box1),box2=DomBox.getBox(box2),pivot1=box1.getPivot(),pivot2=box2.getPivot(),angle_rad=Math.atan2(pivot2.top-pivot1.top,pivot2.left-pivot1.left),angle_deg=DomBox.angle.fromRad(angle_rad),DomBox.angle.normalize(angle_deg)}},root="object"==typeof exports?exports:this,root.DomBox=DomBox,DomBox.Box=function(){function Box(){var property,_j,_len1,_ref;for(_ref=this._properties,_j=0,_len1=_ref.length;_j<_len1;_j++)property=_ref[_j],this[property]=0;this.padding=0,this.update()}return Box.prototype._properties=["width","height","left","top","right","bottom","view_left","view_top","view_right","view_bottom"],Box.prototype.update=function(){return this.pad(this.padding)},Box.prototype.setPadding=function(padding){return this.padding=padding,this.update()},Box.prototype.pad=function(padding){return null==padding&&(padding=0),this.width+=2*padding,this.height+=2*padding,this.left-=padding,this.top-=padding,this.right+=padding,this.bottom+=padding,this.view_left-=padding,this.view_top-=padding,this.view_right+=padding,this.view_bottom+=padding},Box.prototype.getPivot=function(){return{left:this.left+this.width/2,top:this.top+this.height/2}},Box.prototype.moveTo=function(left,top){var diff_horizontal,diff_vertical;if(null==left&&(left=this.left),null==top&&(top=this.top),isNaN(left)||(diff_horizontal=this.left-left,this.left=left,this.right=this.left+this.width,this.view_left-=diff_horizontal,this.view_right-=diff_horizontal),!isNaN(top))return diff_vertical=this.top-top,this.top=top,this.bottom=this.top+this.height,this.view_top-=diff_vertical,this.view_bottom-=diff_vertical},Box.prototype.moveBy=function(left,top){if(null==left&&(left=0),null==top&&(top=0),isNaN(left)||(this.left=this.left+left,this.right=this.left+this.width,this.view_left=this.view_left+left,this.view_right=this.view_right+left),!isNaN(top))return this.top+=top,this.bottom=this.top+this.height,this.view_top+=top,this.view_bottom+=top},Box.prototype.resizeTo=function(width,height){if(null==width&&(width=this.width),null==height&&(height=this.height),isNaN(width)||(this.width=width<0?0:width,this.right=this.left+this.width,this.view_right=this.view_left+this.width),!isNaN(height))return this.height=height<0?0:height,this.bottom=this.top+this.height,this.view_bottom=this.view_top+this.height},Box.prototype.setSize=function(width,height){return this.resizeTo(width,height)},Box.prototype.resizeBy=function(width,height){if(null==width&&(width=0),null==height&&(height=0),isNaN(width)||(this.width=this.width+width,this.width<0&&(this.width=0),this.right=this.left+this.width,this.view_right=this.view_left+this.width),!isNaN(height))return this.height=this.height+height,this.height<0&&(this.height=0),this.bottom=this.top+this.height,this.view_bottom=this.view_top+this.height},Box.prototype.setLeft=function(position){var diff;return diff=position-this.left,this.left=position,this.width=this.right-this.left,this.view_left+=diff},Box.prototype.setRight=function(position){var diff;return diff=position-this.right,this.right=position,this.width=this.right-this.left,this.view_right+=diff},Box.prototype.setTop=function(position){var diff;return diff=position-this.top,this.top=position,this.height=this.bottom-this.top,this.view_top+=diff},Box.prototype.setBottom=function(position){var diff;return diff=position-this.bottom,this.bottom=position,this.height=this.bottom-this.top,this.view_bottom+=diff},Box.prototype.toString=function(){var property,result,_j,_len1,_ref;for(result={},_ref=this._properties,_j=0,_len1=_ref.length;_j<_len1;_j++)property=_ref[_j],result[property]=this[property];return JSON.stringify(result)},Box}(),DomBox.ElementBox=function(_super){function ElementBox(element){this.element=element,ElementBox.__super__.constructor.call(this)}return __extends(ElementBox,_super),ElementBox.prototype.update=function(){var box_data,properties,property,viewport_position,_j,_len1,_ref,_ref1;if(document.body.contains(this.element))box_data=this.element.getBoundingClientRect(),viewport_position=DomBox.Viewport.getPosition(),this.width=null!=(_ref=box_data.width)?_ref:this.element.offsetWidth,this.height=null!=(_ref1=box_data.height)?_ref1:this.element.offsetHeight,this.view_left=box_data.left,this.view_top=box_data.top,this.view_right=box_data.right,this.view_bottom=box_data.bottom,this.left=box_data.left+viewport_position.left,this.top=box_data.top+viewport_position.top,this.right=this.left+this.width,this.bottom=this.top+this.height;else for(properties=["width","height","left","top","right","bottom","view_left","view_top","view_right","view_bottom"],_j=0,_len1=properties.length;_j<_len1;_j++)property=properties[_j],this[property]=0;return ElementBox.__super__.update.call(this)},ElementBox.prototype.getCssProperty=function(elm,property){var style;return null!=window.getComputedStyle?(style=window.getComputedStyle(elm,null),style.getPropertyValue(property)):null!=elm.currentStyle?(property=property.replace(/-(.)/g,function(match,group1){return group1.toUpperCase()}),elm.currentStyle[property]):null},ElementBox}(DomBox.Box),DomBox.CollectionBox=function(_super){function CollectionBox(selector){this.selector=selector,CollectionBox.__super__.constructor.call(this)}return __extends(CollectionBox,_super),CollectionBox.prototype.update=function(){var boxes,element,property,value,_j,_len1,_ref,_ref1;if(boxes=[],this.selector)for(_ref=document.querySelectorAll(this.selector),_j=0,_len1=_ref.length;_j<_len1;_j++)element=_ref[_j],isVisible(element)&&boxes.push(new DomBox.ElementBox(element));0===boxes.length&&boxes.push(new DomBox.Box),_ref1=getExtremes(boxes);for(property in _ref1)value=_ref1[property],this[property]=value;return CollectionBox.__super__.update.call(this)},CollectionBox}(DomBox.Box),DomBox.Document={getWidth:function(){var _ref,_ref1;return Math.max(null!=(_ref=document.body)?_ref.scrollWidth:void 0,null!=(_ref1=document.body)?_ref1.offsetWidth:void 0,document.documentElement.clientWidth,document.documentElement.scrollWidth,document.documentElement.offsetWidth,0)},getHeight:function(){return Math.max(document.body.scrollHeight,document.body.offsetHeight,document.documentElement.clientHeight,document.documentElement.scrollHeight,document.documentElement.offsetHeight,0)},getSize:function(){return{width:DomBox.Document.getWidth(),height:DomBox.Document.getHeight()}}},DomBox.Viewport={getWidth:function(){return window.innerWidth||document.documentElement.clientWidth||0},getHeight:function(){return window.innerHeight||document.documentElement.clientHeight||0},getSize:function(){return{width:DomBox.Viewport.getWidth(),height:DomBox.Viewport.getHeight()}},getLeft:function(){return(window.pageXOffset||document.documentElement.scrollLeft)-(document.documentElement.clientLeft||0)},getTop:function(){return(window.pageYOffset||document.documentElement.scrollTop)-(document.documentElement.clientTop||0)},getPosition:function(){return{left:DomBox.Viewport.getLeft(),top:DomBox.Viewport.getTop()}},getBox:function(){var position,size;return position=DomBox.Viewport.getPosition(),size=DomBox.Viewport.getSize(),{width:size.width,height:size.height,left:position.left,top:position.top,right:position.left+size.width,bottom:position.top+size.height}},moveInside:function(box){var position,viewport;return box=DomBox.getBox(box),viewport=DomBox.Viewport.getBox(),position={left:null,top:null},box.right>viewport.right&&(position.left=viewport.right-box.width),box.bottom>viewport.bottom&&(position.top=viewport.bottom-box.height),box.left=box.right&&viewport.bottom>=box.bottom)},partialyContains:function(box){var intersection_height,intersection_width,max_left,max_top,min_bottom,min_right,viewport;return box=DomBox.getBox(box),null!=box&&(viewport=this.getBox(),max_left=Math.max(box.left,viewport.left),max_top=Math.max(box.top,viewport.top),min_right=Math.min(box.right,viewport.right),min_bottom=Math.min(box.bottom,viewport.bottom),intersection_width=min_right-max_left,intersection_height=min_bottom-max_top,intersection_width>0&&intersection_height>0)},canContain:function(box){return box=DomBox.getBox(box),null!=box&&(box.width<=this.getWidth()&&box.height<=this.getHeight())},canCoexist:function(box1,box2){var bounding_box;return box1=DomBox.getBox(box1),box2=DomBox.getBox(box2),null!=box1&&null!=box2&&(bounding_box=getExtremes([box1,box2]),bounding_box.width<=this.getWidth()&&bounding_box.height<=this.getHeight())},canFitAround:function(box1,box2){var gaps,viewport;return box1=DomBox.getBox(box1),box2=DomBox.getBox(box2),null!=box1&&null!=box2&&(viewport=DomBox.Viewport.getBox(),!(box2.width>viewport.width||box2.height>viewport.height)&&(gaps=DomBox.Viewport.getGaps(box1),box2.width<=gaps.horizontal.before||box2.width<=gaps.horizontal.after||box2.height<=gaps.vertical.before||box2.height<=gaps.vertical.after))},fitAround:function(box1,box2){var gaps;if(box1=DomBox.getBox(box1),box2=DomBox.getBox(box2),DomBox.Viewport.canFitAround(box1,box2)){if(gaps=DomBox.Viewport.getGaps(box1),DomBox.Viewport.moveInside(box2),!DomBox.detectOverlap(box1,box2))return;if(box2.width<=gaps.horizontal.before&&box2.moveTo(box1.left-box2.width,null),!DomBox.detectOverlap(box1,box2))return;if(box2.height<=gaps.vertical.before&&box2.moveTo(null,box1.top-box2.height),!DomBox.detectOverlap(box1,box2))return;if(box2.width<=gaps.horizontal.after&&box2.moveTo(box1.right,null),!DomBox.detectOverlap(box1,box2))return;if(box2.height<=gaps.vertical.after)return box2.moveTo(null,box1.bottom)}},getGaps:function(box){var viewport;return box=DomBox.getBox(box),viewport=DomBox.Viewport.getBox(),{horizontal:{before:Math.max(0,box.left-viewport.left),after:Math.max(0,viewport.right-box.right)},vertical:{before:Math.max(0,box.top-viewport.top),after:Math.max(0,viewport.bottom-box.bottom)}}},toString:function(){return JSON.stringify(DomBox.Viewport.getBox())}}}.call(this);var ElementCollector=function(modules){function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:!1};return modules[moduleId].call(module.exports,module,module.exports,__webpack_require__),module.loaded=!0,module.exports}var installedModules={};return __webpack_require__.m=modules,__webpack_require__.c=installedModules,__webpack_require__.p="",__webpack_require__(0)}([function(module,exports){"use strict";var ElementCollector,indexOf=[].indexOf||function(item){for(var i=0,l=this.length;i%content%',InlineManualPlayer.prototype.valid_positions=["right","right_bottom","bottom_right","bottom","bottom_left","left_bottom","left","left_top","top_left","top","top_right","right_top"],InlineManualPlayer.prototype.activateInstance=function(options){return null==options&&(options={}),this.deactivateByUrlParams(document.location),this.initUi(),this.tick(),this.activateByUrlParams(document.location),EventBridge.addFirstSupported(window,["popstate","hashchange"],function(_this){return function(){return _this.reinit()}}(this)),null!=this.options.enable_mirroring&&EventBridge.add(window,"storage",function(_this){return function(event){return _this.handleStorageChange(event)}}(this)),EventBridge.add(window,"resize",function(_this){return function(event){return _this.handleWindowResize(event)}}(this)),this.handleQueue(this.options.queue),this.executeCallback("onInit",this),this.emitter.fire("onInit",[this]),this.tracking.track({event:"player_init"})},InlineManualPlayer.prototype.createInternals=function(options){return null==options&&(options={}),this.options={},this.topics={},this.metadata={},this.rules={},this.launchers=[],this.reinit_observer_enabled=!1,this.backdrop=null,this.panel_backdrop=null,this.current_step=null,this.is_suspended=!1,this.currentStepStorage=new StorageInterface((null!=options?options.storage_prefix:void 0)+"InmPlayerCurrent"),this.continuationStorage=new AttemptsCount((null!=options?options.storage_prefix:void 0)+"InmPlayerContinuation"),this.callbacks=_extends({},default_callbacks),this.autolaunch_enabled=!1,this.persistent_topic_data=new StorageInterface((null!=options?options.storage_prefix:void 0)+"InmPlayerTopicData"),this.persistent_topic_data=new StorageInterface("InmPlayerTopicData"),this.emitter=new Emitter},InlineManualPlayer.prototype.setupPopover=function(){return this.popover=new Popover({class_name:"inmplayer-popover",pointer_length:20}),this.popover.angle_utils.directions=["right","rightBottom","bottomRight","bottom","bottomLeft","leftBottom","left","leftTop","topLeft","top","topRight","rightTop"]},InlineManualPlayer.prototype.setupStatisticsModule=function(options){return null==options&&(options={}),null==options.tracking&&(options.tracking={}),options.tracking.api_key=options.api_key,options.tracking.version=this.version,this.tracking=new Statistics(options.tracking)},InlineManualPlayer.prototype.checkDependencies=function(){var dependencies,j,label,len,msg,obj,results;for(dependencies={Backdrop:Backdrop,Popover:Popover,ClassBridge:ClassBridge,EventBridge:EventBridge,isVisible:isVisible,ElementMonitor:ElementMonitor},results=[],obj=j=0,len=dependencies.length;j=steps_count?this.deactivate():this._activateStep(this.current_topic.id,parsed_step_id))},InlineManualPlayer.prototype.deactivate=function(keep_current_step_storage){var current_topic_id;if(null==keep_current_step_storage&&(keep_current_step_storage=!1),current_topic_id=this.getCurrentTopic(),null!=current_topic_id&&(this.debug.info("deactivate.topic",{topic_id:current_topic_id}),this._endTopic()),this.unsaveCurrentStep(),this.unsaveCurrentTopic(),this.deactivateStep(),this.removeObserver(),keep_current_step_storage||this.currentStepStorage.forget(),this.tick(),null!=current_topic_id)return this.executeCallback("onAfterTopicEnd",this),this.emitter.fire("onAfterTopicEnd",[this])},InlineManualPlayer.prototype.destroy=function(){return this.deactivate(),this.destroyUi(),this.destroyLaunchers(),this.executeCallback("onDestroy",this),this.emitter.fire("onDestroy",[this])},InlineManualPlayer.prototype.destroyLaunchers=function(){var j,launcher,len,ref5,results;for(ref5=this.launchers,results=[],j=0,len=ref5.length;j0){for(results=[],j=0,len=data.length;j=ref5;i=0<=ref5?++j:--j)results.push(this.unhighlightItem(i));return results},InlineManualPlayer.prototype.destroyUi=function(){var key,ref5,ref6,ref7,ref8,ref9,val;ref5=this.ui_elements;for(key in ref5)val=ref5[key],val.remove();return null!=(ref6=this.ui)&&null!=(ref7=ref6.parentNode)&&ref7.removeChild(this.ui),this.ui=null,null!=(ref8=this.comment_element)&&null!=(ref9=ref8.parentNode)&&ref9.removeChild(this.comment_element),removeCustomStyle(this),this.removeCustomTrigger()},InlineManualPlayer.prototype.initUi=function(){var comment_content;return this.removeObserver(),this.destroyUi(),this.addCustomTrigger(),this.createUiElements(),this.ui=document.body.appendChild(document.createElement("div")),comment_content=["","Inline Manual Player","Easily create walkthroughs, onboarding guides, tooltips and product documentation.","http://inlinemanual.com/",""],this.comment_element=document.createComment(comment_content.join("\n")),this.ui.parentNode.insertBefore(this.comment_element,this.ui),this.setUiClassNames(),addCustomStyle(this,this.options.style),this.observer||this.addObserver(),this.tick(!0)},InlineManualPlayer.prototype.setUiClassNames=function(){var class_names;if(null!=this.ui)return this.ui.className="",class_names=this.getNsClasses(["general","position-"+this.options.position,"skin-"+this.options.skin]),ClassBridge.add(this.ui,class_names),this.setLangDirectionClass(this.ui),this.setSkinClass()},InlineManualPlayer.prototype.custom_trigger_collection=new ElementCollector,InlineManualPlayer.prototype.setCustomTrigger=function(selector){return null==selector&&(selector=this.options.custom_trigger),this.removeCustomTrigger(),this.custom_trigger_collection.reset(),this.custom_trigger_collection.add(selector),this.addCustomTrigger()},InlineManualPlayer.prototype.removeCustomTrigger=function(){var element,j,len,ref5,results;for(ref5=this.custom_trigger_collection.get(),results=[],j=0,len=ref5.length;j
%title%
%body%
',attributes:{class:item_class},data:{title:this.applyVariables(step_data.title),title_class:this.getNsClasses(["article-item-title"]),body:this.applyVariables(step_data.content),body_class:this.getNsClasses(["article-item-body"])}})},InlineManualPlayer.prototype.displayTopics=function(topics,options){var default_topic_options,highlighted_items,j,len,ref5,regular_items,topic,topic_id,topics_items;for(null==topics&&(topics=this.topics),null==options&&(options={}),default_topic_options={search:null},options=merge(default_topic_options,options),highlighted_items=[],regular_items=[],ref5=this.sortTopics(this.getValidTopics()),j=0,len=ref5.length;j0?(delay_callback=new DelayCallback,new Prerequisite({check:function(){return delay_callback.check()},interval:1e3*data.delay,onStart:function(_this){return function(){return _this.debug.info("step.delay",{title:data.title,delay:data.delay})}}(this),onFinish:callback})):null},InlineManualPlayer.prototype.setPrerequisites=function(step_data,topic_id,step_id,force){var condition_prerequisite,delay_prerequisite,prerequisite_callback;return prerequisite_callback=function(_this){return function(){return _this.setState("step_displayed",!0),_this.tick()}}(this),condition_prerequisite=this.constructConditionPrerequisite(step_data,prerequisite_callback),delay_prerequisite=this.constructDelayPrerequisite(step_data,prerequisite_callback),null!=condition_prerequisite&&null!=delay_prerequisite?(this.condition_prerequisite=this.constructConditionPrerequisite(step_data,function(){return delay_prerequisite.start()}),this.delay_prerequisite=null):(this.condition_prerequisite=condition_prerequisite,this.delay_prerequisite=delay_prerequisite)},InlineManualPlayer.prototype.unsetPrerequisites=function(){var ref5,ref6;return null!=(ref5=this.condition_prerequisite)&&ref5.stop(),null!=(ref6=this.delay_prerequisite)?ref6.stop():void 0},InlineManualPlayer.prototype.activateBackdrop=function(element,cover,options){var backdrop_options,j,key,len,property,property_value,ref5,val;for(null==cover&&(cover=!1),null==options&&(options={}),this.deactivateBackdrop(),backdrop_options={z_index:this.getZIndex("backdrop"),hide_on_click:!1,cover:cover,watch:!0,backdrop_class:this.getBackdropClassNames("step")},ref5=["color","opacity","padding"],j=0,len=ref5.length;jb.val.title?1:-1:0}),results=[],j=0,len=topics_array.length;j=0&&(value=this.getZIndex(value,topic_id,step_id)),null!=element&&!isNaN(value))return element.style.zIndex=value},InlineManualPlayer.prototype.getZIndex=function(layer_name,topic_id,step_id){var base,i,j,layer,layer_index,len,ref5,ref6,ref7;for(null==topic_id&&(topic_id=this.current_topic.id),null==step_id&&(step_id=this.current_step),base=(null!=(ref5=this.getStepData(topic_id,step_id))?ref5.z_index:void 0)||(null!=(ref6=this.topics[topic_id])?ref6.z_index:void 0)||this.options.z_index||0,layer_index=0,ref7=this.layer_stack,i=j=0,len=ref7.length;j=0&&results.push(event);return results}()},Trigger.prototype.sanitizeScope=function(scope){var allowed_scopes;return allowed_scopes=["current","any"],indexOf.call(allowed_scopes,scope)<0&&(scope=null),scope},Trigger.prototype.sanitizeActivate=function(activate){var allowed_activates;return allowed_activates=["current","next","previous","none"],"number"==typeof activate||indexOf.call(allowed_activates,activate)>=0?activate:allowed_activates[0]},Trigger.prototype.sanitizeElement=function(element){var ref5;return validateCssSelector(element)?element:(null!=(ref5=this.parent)&&ref5.debug.warn("invalid.selector",{selector:element}),null)},Trigger.prototype.execute=function(){if(null!=this.tour&&this.tour.current_topic.id===this.topic_id&&("any"===this.options.scope||"current"===this.options.scope&&this.tour.current_step===this.step_id))return"current"===this.options.activate?this.tour._activateStep(this.topic_id,this.step_id,!0):"none"===this.options.activate?this.tour.deactivate():this.tour._goToStep(this.options.activate)},Trigger.prototype.add=function(element_selector,events){var element,elements,event,j,len,results;for(null==element_selector&&(element_selector=this.options.element),null==events&&(events=this.options.events),this.options.element=this.sanitizeElement(element_selector),this.options.events=this.sanitizeEvents(events),this.monitor.elements.set(this.options.element),results=[],j=0,len=events.length;j=0?[window]:safeQueryAll(element_selector),results.push(function(){var k,len1,results1;for(results1=[],k=0,len1=elements.length;k=0?[window]:safeQueryAll(element_selector),results.push(function(){var k,len1,results1;for(results1=[],k=0,len1=elements.length;k'),null==after&&(after=""),re=RegExp("("+needle+")","gi"),replacement=before+"$1"+after,haystack.replace(re,replacement)}};for(key in search)val=search[key],InlineManualPlayer.prototype[key]=val;InlineManualPlayer.prototype.createUiElements=function(){return this.ui_elements={panel_trigger:new this.UiElement({attributes:{class:this.getNsClasses("trigger")},data:{content:this.translate("trigger_title")||this.translate("title")},events:{click:function(_this){return function(){return _this.showPanel()}}(this)},callbacks:{onAdd:function(_this){return function(obj){return _this.setZIndex(obj.getNode(),"panel")}}(this),onStateCheck:function(_this){return function(){return!_this.options.hide_trigger}}(this)}}),panel_header:new this.UiElement({attributes:{class:this.getNsClasses("panel-header")},data:{content:this.translate("panel_title")||this.translate("title")},events:{click:function(_this){return function(){return _this.hidePanel()}}(this)}}),panel_search:new this.UiElement({attributes:{class:this.getNsClasses("panel-search")},data:{content:" "+this.translate("search_clear")+""},callbacks:{onAdd:function(_this){return function(obj){return _this.initSearch(obj)}}(this)}}),panel_list:new this.UiElement({attributes:{class:this.getNsClasses("panel-body")},data:{content:""}}),list_empty:new this.UiElement({attributes:{class:this.getNsClasses("list-empty")},data:{content:""}}),panel_close_button:new this.UiElement({attributes:{class:this.getNsClasses("panel-close-button")},data:{content:"×"},events:{click:function(_this){return function(){return _this.hidePanel()}}(this)}}),article_close_button:new this.UiElement({attributes:{class:this.getNsClasses("panel-close-button")},data:{content:"×"},events:{click:function(_this){return function(){return _this.deactivate(),_this.hidePanel()}}(this)}}),article_back_button:new this.UiElement({attributes:{class:this.getNsClasses("panel-back-button")},data:{content:"←"},events:{click:function(_this){return function(){return _this.deactivate(),_this.showPanel()}}(this)}}),panel_custom_footer:new this.UiElement({attributes:{class:this.getNsClasses("panel-custom-footer")},data:{content:this.translate("footer")},events:{click:function(_this){return function(event){var target;for(target=EventBridge.target(event);"a"!==target.tagName.toLowerCase();)target=target.parentNode;return _this.tracking.track({event:"footer_click",link_url:target.href})}}(this)}}),panel_branding:new this.UiElement({template:' %content% Inline Manual ',attributes:{class:this.getNsClasses(["branding","panel-footer-branding"])},data:{content:this.translate("branding"),branding_link:this.translate("branding_link")}}),panel_footer:new this.UiElement({attributes:{class:this.getNsClasses("panel-footer")},data:{content:""},callbacks:{onAdd:function(_this){return function(obj){if(_this.ui_elements.panel_custom_footer.add(obj.getNode()),!_this.options.hide_branding)return _this.ui_elements.panel_branding.add(obj.getNode())}}(this)}}),panel:new this.UiElement({attributes:{class:this.getNsClasses("panel")},data:{content:""},callbacks:{onAdd:function(_this){return function(obj){return _this.onAddTopicsPanel(obj.getNode())}}(this),onRemove:function(_this){return function(obj){return _this.onRemovePanel()}}(this)}}),article_panel:new this.UiElement({attributes:{class:this.getNsClasses("panel")},data:{content:""},callbacks:{onAdd:function(_this){return function(obj){return _this.onAddArticlePanel(obj.getNode())}}(this),onRemove:function(_this){return function(obj){return _this.onRemovePanel()}}(this)}}),popover_progress:new this.UiElement({template:"
%current_step% / %total_steps%
",attributes:{class:this.getNsClasses("popover-progress")},data:{current_step:"0",total_steps:"0"}}),popover_title:new this.UiElement({attributes:{class:this.getNsClasses("popover-title")}}),popover_content:new this.UiElement({attributes:{class:this.getNsClasses("popover-inner-content")}}),popover_close_button:new this.UiElement({attributes:{class:this.getNsClasses("popover-close-button")},data:{content:"×"},events:{click:function(_this){return function(){return _this.endTopic()}}(this)}}),popover_controls:new this.UiElement({attributes:{class:this.getNsClasses("popover-buttons")},data:{content:""},callbacks:{onAdd:function(_this){return function(obj){return obj.insert([_this.ui_elements.popover_button_prev,_this.ui_elements.popover_button_next,_this.ui_elements.popover_button_end,_this.ui_elements.popover_progress])}}(this)}}),popover_button_prev:new this.UiElement({attributes:{class:this.getNsClasses(["popover-button-previous","button"])},data:{content:translate(this.l10n.previous,this.options.language)},events:{click:function(_this){return function(){return _this._goToStep("previous")}}(this)}}),popover_button_next:new this.UiElement({attributes:{class:this.getNsClasses(["popover-button-next","button"])},data:{content:translate(this.l10n.next,this.options.language)},events:{click:function(_this){return function(){return _this._goToStep("next")}}(this)}}),popover_button_end:new this.UiElement({attributes:{class:this.getNsClasses(["popover-button-end","button"])},data:{content:translate(this.l10n.end,this.options.language)},events:{click:function(_this){return function(){return _this.endTopic()}}(this)}}),popover_branding:new this.UiElement({template:' %content% Inline Manual ',attributes:{class:this.getNsClasses(["branding","popover-branding"])},data:{content:this.translate("branding"),branding_link:this.translate("branding_link")}})}},Template=__webpack_require__(13).default,UiElement=function(){function UiElement(options){var ref5;if(null==options&&(options={}),this.changed=!1,this.data={},this.setData(options.data),this.setTemplate(options.template),this.events={},null!=options.events){ref5=options.events;for(key in ref5)val=ref5[key],this.addEvent(key,val)}this.attributes={},null!=options.attributes&&this.setAttributes(options.attributes),this.callbacks={},this.setCallbacks(this.default_callbacks),this.setCallbacks(options.callbacks),this.createNode()}return UiElement.prototype.default_template="
%content%
",UiElement.prototype.default_callbacks={onCreate:function(){},onAdd:function(){},onRemove:function(){},onStateCheck:function(){return!0}},UiElement.prototype.setData=function(data){null==data&&(data={});for(key in data)val=data[key],this.data[key]!==val&&(this.changed=!0),this.data[key]=val;return this.data},UiElement.prototype.setTemplate=function(template){return null==template&&(template=this.default_template),template!==this.template&&(this.changed=!0),this.template=template},UiElement.prototype.setAttributes=function(attributes){return null==attributes&&(attributes={}), -attributes!=={}&&(this.changed=!0),this.attributes=merge(this.attributes,attributes)},UiElement.prototype.addEvent=function(type,callback){return null==callback&&(callback=noop),this.changed=!0,this.events[type]=callback},UiElement.prototype.setCallbacks=function(callbacks){var results;null==callbacks&&(callbacks={}),results=[];for(key in callbacks)val=callbacks[key],results.push(this.callbacks[key]=val);return results},UiElement.prototype.createNode=function(){var ref5,ref6,template;if(this.changed=!1,this.remove(),template=new Template(this.template,this.data),this.node=template.getDom(),null!=this.node.setAttribute){ref5=this.attributes;for(key in ref5)val=ref5[key],this.node.setAttribute(key,val)}ref6=this.events;for(key in ref6)val=ref6[key],EventBridge.add(this.node,key,val);return this.callbacks.onCreate(this),this.node},UiElement.prototype.getNode=function(){return(this.changed||null==this.node)&&this.createNode(),this.node},UiElement.prototype.add=function(parent_node,ref_node){return null==parent_node&&(parent_node=document.body),null==ref_node&&(ref_node=null),parent_node.insertBefore(this.getNode(),ref_node),this.callbacks.onAdd(this)},UiElement.prototype.insert=function(objects,ref_node){var item,j,len;if(null!=objects)for(isArray(objects)||(objects=[objects]),j=0,len=objects.length;j1?(0,_utilities.getChildrenAsFragment)(elm):elm.childNodes[0]}}]),Template}();exports.default=Template},function(module,exports){"use strict";function escapeForRegExp(content){return content.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}function getChildrenAsFragment(element){for(var fragment=document.createDocumentFragment(),child_element=void 0;child_element=element.firstChild;)fragment.appendChild(child_element);return fragment}function getPlaceholders(content,_ref){var start=_ref.delimiter_start,end=_ref.delimiter_end,match_re_content=start+"[^"+end+"]+"+end,match_re=new RegExp(match_re_content,"g");return content.match(match_re)||[]}function getPlaceholderData(placeholder,_ref2){var start=_ref2.delimiter_start,end=_ref2.delimiter_end,separator=_ref2.delimiter_separator,item_re_content=[start,"([^"+separator+"]+)","("+separator+")*","(.+)*",end].join(""),item_re=new RegExp(item_re_content),item_matches=placeholder.match(item_re);return{key:item_matches[1],value:item_matches[3]}}Object.defineProperty(exports,"__esModule",{value:!0}),exports.escapeForRegExp=escapeForRegExp,exports.getChildrenAsFragment=getChildrenAsFragment,exports.getPlaceholders=getPlaceholders,exports.getPlaceholderData=getPlaceholderData},function(module,exports){"use strict";function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function validateId(id){return validateInput(id,"string","Invalid ID.")}function validateFunction(fn){return validateInput(fn,"function","Invalid function.")}function validateInput(input,expected_type,message){if(("undefined"==typeof input?"undefined":_typeof(input))!==expected_type)throw new Error("Emitter: "+message);return!0}var _typeof2="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(obj){return typeof obj}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol?"symbol":typeof obj};Object.defineProperty(exports,"__esModule",{value:!0});var _typeof="function"==typeof Symbol&&"symbol"===_typeof2(Symbol.iterator)?function(obj){return"undefined"==typeof obj?"undefined":_typeof2(obj)}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol?"symbol":"undefined"==typeof obj?"undefined":_typeof2(obj)},_createClass=function(){function defineProperties(target,props){for(var i=0;ib},gte:function(a,b){return a>=b},lt:function(a,b){return a=sanitizeTime(b,1)}},url:{match:function(a,b){return new _urlMatch2.default(b).test(a)},match_current:function(a,b){var current_url=document.location.toString();return new _urlMatch2.default(b).test(current_url)}},element:{is_equal:function(a,b){return getFormFieldValue(b)===a},gt:function(a,b){var val=getFormFieldValue(b);return val&&Number(a)>Number(val)},gte:function(a,b){var val=getFormFieldValue(b);return val&&Number(a)>=Number(val)},lt:function(a,b){var val=getFormFieldValue(b);return val&&Number(a)val},gte:function(a,b){var val=(0,_getNestedProperty2.default)(window,b);return"undefined"!=typeof val&&a>=val},lt:function(a,b){var val=(0,_getNestedProperty2.default)(window,b);return"undefined"!=typeof val&&a"!==pattern||(pattern="*://*/*?*#*"),this.original_pattern=pattern,this.pattern=this.sanitize(pattern),this.url_parts=this.getUrlParts(this.pattern)}return _class.prototype.split=function(){var pattern=arguments.length<=0||void 0===arguments[0]?"":arguments[0],empty_value=arguments.length<=1||void 0===arguments[1]?null:arguments[1],result={},parts=pattern.match(split_re);for(var key in parts_map){var val=parts_map[key];result[key]=(0,_exists2.default)(parts)&&(0,_exists2.default)(parts[val])?parts[val]:empty_value}return result},_class.prototype.getUrlParts=function(){var pattern=arguments.length<=0||void 0===arguments[0]?this.pattern:arguments[0],splits=this.split(pattern);return{scheme:new _scheme2.default(splits.scheme),host:new _host2.default(splits.host),path:new _path2.default(splits.path),params:new _params2.default(splits.params),fragment:new _fragment2.default(splits.fragment)}},_class.prototype.sanitize=function(){var pattern=arguments.length<=0||void 0===arguments[0]?this.original_pattern:arguments[0],universal_pattern="*://*/*?*#*";return"*"!==pattern&&""!==pattern||(pattern=universal_pattern),pattern},_class.prototype.validate=function(){var url_parts=arguments.length<=0||void 0===arguments[0]?this.url_parts:arguments[0],result=!0;for(var key in url_parts){var val=url_parts[key];val.validate()||(result=!1)}return result},_class.prototype.test=function(url){var _this=this,result=!1;return(0,_exists2.default)(url)&&!function(){result=!0;var splits=_this.split(url);["scheme","host","path","params","fragment"].forEach(function(part){_this.url_parts[part].test(splits[part])||(result=!1)})}(),result},_class}();exports.default=_class},function(module,exports,__webpack_require__){"use strict";function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _possibleConstructorReturn(self,call){if(!self)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!call||"object"!==("undefined"==typeof call?"undefined":_typeof(call))&&"function"!=typeof call?self:call}function _inherits(subClass,superClass){if("function"!=typeof superClass&&null!==superClass)throw new TypeError("Super expression must either be null or a function, not "+("undefined"==typeof superClass?"undefined":_typeof(superClass)));subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,enumerable:!1,writable:!0,configurable:!0}}),superClass&&(Object.setPrototypeOf?Object.setPrototypeOf(subClass,superClass):subClass.__proto__=superClass)}var _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(obj){return typeof obj}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol?"symbol":typeof obj};Object.defineProperty(exports,"__esModule",{value:!0});var _createClass=function(){function defineProperties(target,props){for(var i=0;i1?_len-1:0),_key=1;_key<_len;_key++)params[_key-1]=arguments[_key];return arrayReduce.apply(array,params)}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=arrayReduce;var _getNestedProperty=__webpack_require__(31),_getNestedProperty2=_interopRequireDefault(_getNestedProperty),_arrayReducePolyfill=__webpack_require__(32),_arrayReducePolyfill2=_interopRequireDefault(_arrayReducePolyfill)},function(module,exports){"use strict";function getNestedProperty(){var data=arguments.length<=0||void 0===arguments[0]?window:arguments[0],path=arguments.length<=1||void 0===arguments[1]?"":arguments[1],default_value=arguments[2];if(Array.isArray(path)&&(path=path.join(".")),"string"!=typeof path)throw new TypeError('getNestedProperty: Provided path must be String or Array (is "'+path+'").');var _ret=function(){var result=data;return""!==path&&path.split(".").forEach(function(segment){result="undefined"!=typeof result&&"undefined"!=typeof result[segment]?result[segment]:void 0}),{v:"undefined"==typeof result?default_value:result}}();if("object"===("undefined"==typeof _ret?"undefined":_typeof(_ret)))return _ret.v}Object.defineProperty(exports,"__esModule",{value:!0});var _typeof2="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(obj){return typeof obj}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol?"symbol":typeof obj};exports.default=getNestedProperty;var _typeof="function"==typeof Symbol&&"symbol"===_typeof2(Symbol.iterator)?function(obj){return"undefined"==typeof obj?"undefined":_typeof2(obj)}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol?"symbol":"undefined"==typeof obj?"undefined":_typeof2(obj)}},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(callback){if(null==this)throw new TypeError("Array.prototype.reduce called on null or undefined");if("function"!=typeof callback)throw new TypeError(callback+" is not a function");var value,t=Object(this),len=t.length>>>0,k=0;if(2==arguments.length)value=arguments[1];else{for(;k=len)throw new TypeError("Reduce of empty array with no initial value");value=t[k++]}for(;k1?_len-1:0),_key=1;_key<_len;_key++)params[_key-1]=arguments[_key];return arrayReduce.apply(array,params)}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=arrayReduce;var _getNestedProperty=__webpack_require__(31),_getNestedProperty2=_interopRequireDefault(_getNestedProperty),_arrayReducePolyfill=__webpack_require__(40),_arrayReducePolyfill2=_interopRequireDefault(_arrayReducePolyfill)},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(callback){if(null==this)throw new TypeError("Array.prototype.reduce called on null or undefined");if("function"!=typeof callback)throw new TypeError(callback+" is not a function");var value,t=Object(this),len=t.length>>>0,k=0;if(2==arguments.length)value=arguments[1];else{for(;k=len)throw new TypeError("Reduce of empty array with no initial value");value=t[k++]}for(;kextremes.right&&(extremes.right=box.right),box.bottom>extremes.bottom&&(extremes.bottom=box.bottom)}),new _generic2.default({left:extremes.left,top:extremes.top,width:extremes.right-extremes.left,height:extremes.bottom-extremes.top})};var _generic=__webpack_require__(53),_generic2=_interopRequireDefault(_generic)},function(module,exports,__webpack_require__){"use strict";function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _possibleConstructorReturn(self,call){if(!self)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!call||"object"!==("undefined"==typeof call?"undefined":_typeof(call))&&"function"!=typeof call?self:call}function _inherits(subClass,superClass){if("function"!=typeof superClass&&null!==superClass)throw new TypeError("Super expression must either be null or a function, not "+("undefined"==typeof superClass?"undefined":_typeof(superClass)));subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,enumerable:!1,writable:!0,configurable:!0}}),superClass&&(Object.setPrototypeOf?Object.setPrototypeOf(subClass,superClass):subClass.__proto__=superClass)}Object.defineProperty(exports,"__esModule",{value:!0});var _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(obj){return typeof obj}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol?"symbol":typeof obj},_generic=__webpack_require__(53),_generic2=_interopRequireDefault(_generic),_createClass=function(){function defineProperties(target,props){for(var i=0;ia.right&&(b.left=a.right-b.width),b.bottom>a.bottom&&(b.top=a.bottom-b.height),b.left=b.right&&a.bottom>=b.bottom}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=contains},function(module,exports){"use strict";function canContain(a,b){return a.width>=b.width&&a.height>=b.height}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=canContain},function(module,exports,__webpack_require__){"use strict";function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function canCoexist(a,b,c){return(0,_canContain2.default)(a,(0,_getBoundingBox2.default)([b,c]))}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=canCoexist;var _canContain=__webpack_require__(68),_canContain2=_interopRequireDefault(_canContain),_getBoundingBox=__webpack_require__(57),_getBoundingBox2=_interopRequireDefault(_getBoundingBox)},function(module,exports,__webpack_require__){"use strict";function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function canFitAround(a,b,c){if(!(0,_canContain2.default)(a,c))return!1;var result=!1;return(0,_getBoxesAround2.default)(a,b).forEach(function(item){(0,_canContain2.default)(item,c)&&(result=!0)}),result}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=canFitAround;var _canContain=__webpack_require__(68),_canContain2=_interopRequireDefault(_canContain),_getBoxesAround=__webpack_require__(71),_getBoxesAround2=_interopRequireDefault(_getBoxesAround)},function(module,exports,__webpack_require__){"use strict";function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function getBoxesAround(a,b){var result=[],gaps=(0,_getGaps2.default)(a,b);return gaps.horizontal.before>0&&result.push({left:a.left,top:a.top,width:gaps.horizontal.before,height:a.height}),gaps.horizontal.after>0&&result.push({left:b.right,top:a.top,width:gaps.horizontal.after,height:a.height}),gaps.vertical.before>0&&result.push({left:a.left,top:a.top,width:a.width,height:gaps.vertical.before}),gaps.vertical.after>0&&result.push({left:a.left,top:b.bottom,width:a.width,height:gaps.vertical.after}),result=result.map(function(item){return(0,_getBox2.default)(item)}),result=makeUnique(result)}function makeUnique(){var boxes=arguments.length<=0||void 0===arguments[0]?[]:arguments[0],ref=[],result=[];return boxes.forEach(function(item){var item_string=item.toString();ref.indexOf(item_string)===-1&&(ref.push(item_string),result.push(item))}),result}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=getBoxesAround;var _getGaps=__webpack_require__(72),_getGaps2=_interopRequireDefault(_getGaps),_getBox=__webpack_require__(51),_getBox2=_interopRequireDefault(_getBox)},function(module,exports){"use strict";function getGaps(a,b){var result={horizontal:{before:Math.max(0,b.left-a.left),after:Math.max(0,a.right-b.right) -},vertical:{before:Math.max(0,b.top-a.top),after:Math.max(0,a.bottom-b.bottom)}};return result.horizontal.before>a.width&&(result.horizontal.before=a.width),result.horizontal.after>a.width&&(result.horizontal.after=a.width),result.vertical.before>a.height&&(result.vertical.before=a.height),result.vertical.after>a.height&&(result.vertical.after=a.height),result}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=getGaps},function(module,exports,__webpack_require__){"use strict";function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function findClosest(a){var boxes=arguments.length<=1||void 0===arguments[1]?[]:arguments[1],property=arguments.length<=2||void 0===arguments[2]?"direct":arguments[2],lowest_distance=Number.MAX_VALUE,result=null;return boxes.forEach(function(box){var distance=(0,_getDistance2.default)(a,box)[property];distance0?(1===target.length&&(target=target[0]),TheBox.getBox(target)):null},Popover.prototype.detach=function(){return this.element_monitor.stop(),this.attach(null)},Popover.prototype.setPosition=function(position){return null==position&&(position={left:0,top:0}),this.ui.wrapper.style.left=position.left+"px",this.ui.wrapper.style.top=position.top+"px"},Popover.prototype.positionOrphan=function(){var viewport_box,wrapper_box;return wrapper_box=TheBox.getBox(this.ui.wrapper),viewport_box=TheBox.getBox("viewport"),this.setPosition({left:(viewport_box.width-wrapper_box.width)/2,top:(viewport_box.height-wrapper_box.height)/2})},Popover.prototype.positionRegular=function(){var destination,distance,target_box,target_pivot,viewport_box,wrapper_box;return wrapper_box=TheBox.getBox(this.ui.wrapper),target_box=TheBox.getBox(this.getTarget()),viewport_box=TheBox.getBox("viewport"),viewport_box.pad(0-this.pointer_length),TheBox.canFitAround(viewport_box,target_box,wrapper_box)?(target_pivot=target_box.pivot,distance=this.getOptimalDistance(wrapper_box,target_box),destination=this.moveVector(target_pivot,distance),wrapper_box.movePivotTo(destination.left,destination.top),this.disable_smart_position||(TheBox.moveInside(viewport_box,wrapper_box),TheBox.detectOverlap(target_box,wrapper_box)&&TheBox.fitAround(viewport_box,target_box,wrapper_box)),this.setPosition(wrapper_box),this.drawPointer()):this.positionOrphan()},Popover.prototype.drawPointer=function(){var distance,end_point,pointer_angle,pointer_width,popover_box,popover_hypotenuse,popover_pivot,start_point,target_box,target_hypotenuse,viewport_box,visible_box;if(popover_box=TheBox.getBox(this.ui.wrapper),target_box=TheBox.getBox(this.getTarget()),viewport_box=TheBox.getBox("viewport"),visible_box=TheBox.getOverlap(target_box,viewport_box),null!=visible_box&&(target_box=visible_box),this.debug&&(this.clearDebugPoints(),this.drawDebugPoint({left:target_box.left,top:target_box.top},"#0c0"),this.drawDebugPoint({left:target_box.right,top:target_box.top},"#0c0"),this.drawDebugPoint({left:target_box.right,top:target_box.bottom},"#0c0"),this.drawDebugPoint({left:target_box.left,top:target_box.bottom},"#0c0"),this.drawDebugPoint(target_box.pivot,"yellow")),pointer_angle=TheBox.getPivotAngle(popover_box,target_box),this.setDirectionClass(this.angle_utils.toDirection(pointer_angle)),this.use_svg)return distance=TheBox.getDistance(target_box,popover_box).pivot,popover_hypotenuse=this.getHypotenuse(popover_box,pointer_angle),target_hypotenuse=this.getHypotenuse(target_box,pointer_angle),pointer_width=distance-popover_hypotenuse-target_hypotenuse,pointer_widthextremes.right&&(extremes.right=box.right),box.bottom>extremes.bottom&&(extremes.bottom=box.bottom)}),new _generic2.default({left:extremes.left,top:extremes.top,width:extremes.right-extremes.left,height:extremes.bottom-extremes.top})};var _generic=__webpack_require__(5),_generic2=_interopRequireDefault(_generic)},function(module,exports,__webpack_require__){function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _possibleConstructorReturn(self,call){if(!self)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!call||"object"!==("undefined"==typeof call?"undefined":_typeof(call))&&"function"!=typeof call?self:call}function _inherits(subClass,superClass){if("function"!=typeof superClass&&null!==superClass)throw new TypeError("Super expression must either be null or a function, not "+("undefined"==typeof superClass?"undefined":_typeof(superClass)));subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,enumerable:!1,writable:!0,configurable:!0}}),superClass&&(Object.setPrototypeOf?Object.setPrototypeOf(subClass,superClass):subClass.__proto__=superClass)}var _typeof="function"==typeof Symbol&&"symbol"===_typeof3(Symbol.iterator)?function(obj){return"undefined"==typeof obj?"undefined":_typeof3(obj)}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol?"symbol":"undefined"==typeof obj?"undefined":_typeof3(obj)};Object.defineProperty(exports,"__esModule",{value:!0});var _generic=__webpack_require__(5),_generic2=_interopRequireDefault(_generic),_class=function(_Box){function _class(){return _classCallCheck(this,_class),_possibleConstructorReturn(this,_Box.apply(this,arguments))}return _inherits(_class,_Box),_class.prototype.update=function(){return this.set({left:0,top:0,width:Math.max(document.body.scrollWidth,document.body.offsetWidth,document.documentElement.clientWidth,document.documentElement.scrollWidth,document.documentElement.offsetWidth,0),height:Math.max(document.body.scrollHeight,document.body.offsetHeight,document.documentElement.clientHeight,document.documentElement.scrollHeight,document.documentElement.offsetHeight,0)})},_class}(_generic2.default);exports.default=_class},function(module,exports,__webpack_require__){function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _possibleConstructorReturn(self,call){if(!self)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!call||"object"!==("undefined"==typeof call?"undefined":_typeof(call))&&"function"!=typeof call?self:call}function _inherits(subClass,superClass){if("function"!=typeof superClass&&null!==superClass)throw new TypeError("Super expression must either be null or a function, not "+("undefined"==typeof superClass?"undefined":_typeof(superClass)));subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,enumerable:!1,writable:!0,configurable:!0}}),superClass&&(Object.setPrototypeOf?Object.setPrototypeOf(subClass,superClass):subClass.__proto__=superClass)}var _typeof="function"==typeof Symbol&&"symbol"===_typeof3(Symbol.iterator)?function(obj){return"undefined"==typeof obj?"undefined":_typeof3(obj)}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol?"symbol":"undefined"==typeof obj?"undefined":_typeof3(obj)};Object.defineProperty(exports,"__esModule",{value:!0});var _generic=__webpack_require__(5),_generic2=_interopRequireDefault(_generic),_getScrollPosition=__webpack_require__(7),_getScrollPosition2=_interopRequireDefault(_getScrollPosition),_class=function(_Box){function _class(){return _classCallCheck(this,_class),_possibleConstructorReturn(this,_Box.apply(this,arguments))}return _inherits(_class,_Box),_class.prototype.update=function(){var scroll_position=(0,_getScrollPosition2.default)();return this.set({left:scroll_position.left,top:scroll_position.top,width:window.innerWidth||document.documentElement.clientWidth||0,height:window.innerHeight||document.documentElement.clientHeight||0})},_class}(_generic2.default);exports.default=_class},function(module,exports,__webpack_require__){function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(a,b){var difference=(0,_getDifference2.default)(a,b),result={horizontal:Math.max(0,difference.horizontal),vertical:Math.max(0,difference.vertical),pivot:(0,_getHypotenuse2.default)(a.pivot.left-b.pivot.left,a.pivot.top-b.pivot.top)};return result.direct=(0,_getHypotenuse2.default)(result.horizontal,result.vertical),result};var _getDifference=__webpack_require__(13),_getDifference2=_interopRequireDefault(_getDifference),_getHypotenuse=__webpack_require__(14),_getHypotenuse2=_interopRequireDefault(_getHypotenuse)},function(module,exports,__webpack_require__){function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(a,b){var bounding_box=(0,_getBoundingBox2.default)([a,b]);return{horizontal:bounding_box.width-a.width-b.width,vertical:bounding_box.height-a.height-b.height}};var _getBoundingBox=__webpack_require__(9),_getBoundingBox2=_interopRequireDefault(_getBoundingBox)},function(module,exports){Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(x,y){return Math.sqrt(Math.pow(x,2)+Math.pow(y,2))}},function(module,exports,__webpack_require__){function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(a,b){return(0,_detectOverlap2.default)(a,b)?new _generic2.default({left:Math.max(a.left,b.left),top:Math.max(a.top,b.top),width:Math.min(a.right,b.right)-Math.max(a.left,b.left),height:Math.min(a.bottom,b.bottom)-Math.max(a.top,b.top)}):null};var _detectOverlap=__webpack_require__(16),_detectOverlap2=_interopRequireDefault(_detectOverlap),_generic=__webpack_require__(5),_generic2=_interopRequireDefault(_generic)},function(module,exports,__webpack_require__){function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(a,b){var difference=(0,_getDifference2.default)(a,b);return difference.horizontal<0&&difference.vertical<0};var _getDifference=__webpack_require__(13),_getDifference2=_interopRequireDefault(_getDifference)},function(module,exports){Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(a,b,use_radian){var result=Math.atan2(b.pivot.top-a.pivot.top,b.pivot.left-a.pivot.left);return use_radian?result:result*(180/Math.PI)}},function(module,exports){Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(a,b){b.right>a.right&&(b.left=a.right-b.width),b.bottom>a.bottom&&(b.top=a.bottom-b.height),b.left=b.right&&a.bottom>=b.bottom}},function(module,exports){Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(a,b){return a.width>=b.width&&a.height>=b.height}},function(module,exports,__webpack_require__){function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(a,b,c){return(0,_canContain2.default)(a,(0,_getBoundingBox2.default)([b,c]))};var _canContain=__webpack_require__(20),_canContain2=_interopRequireDefault(_canContain),_getBoundingBox=__webpack_require__(9),_getBoundingBox2=_interopRequireDefault(_getBoundingBox)},function(module,exports,__webpack_require__){function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(a,b,c){if(!(0,_canContain2.default)(a,c))return!1;var result=!1;return(0,_getBoxesAround2.default)(a,b).forEach(function(item){(0,_canContain2.default)(item,c)&&(result=!0)}),result};var _canContain=__webpack_require__(20),_canContain2=_interopRequireDefault(_canContain),_getBoxesAround=__webpack_require__(23),_getBoxesAround2=_interopRequireDefault(_getBoxesAround)},function(module,exports,__webpack_require__){function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function makeUnique(boxes){var ref=[],result=[];return boxes.forEach(function(item){var item_string=item.toString();ref.indexOf(item_string)===-1&&(ref.push(item_string),result.push(item))}),result}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(a,b){var result=[],gaps=(0,_getGaps2.default)(a,b);return gaps.horizontal.before>0&&result.push({left:a.left,top:a.top,width:gaps.horizontal.before,height:a.height}),gaps.horizontal.after>0&&result.push({left:b.right,top:a.top,width:gaps.horizontal.after,height:a.height}),gaps.vertical.before>0&&result.push({left:a.left,top:a.top,width:a.width,height:gaps.vertical.before}),gaps.vertical.after>0&&result.push({left:a.left,top:b.bottom,width:a.width,height:gaps.vertical.after}),result=result.map(function(item){return(0,_getBox2.default)(item)}),result=makeUnique(result)};var _getGaps=__webpack_require__(24),_getGaps2=_interopRequireDefault(_getGaps),_getBox=__webpack_require__(3),_getBox2=_interopRequireDefault(_getBox)},function(module,exports){Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(a,b){var result={horizontal:{before:Math.max(0,b.left-a.left),after:Math.max(0,a.right-b.right)},vertical:{before:Math.max(0,b.top-a.top),after:Math.max(0,a.bottom-b.bottom)}};return result.horizontal.before>a.width&&(result.horizontal.before=a.width),result.horizontal.after>a.width&&(result.horizontal.after=a.width),result.vertical.before>a.height&&(result.vertical.before=a.height),result.vertical.after>a.height&&(result.vertical.after=a.height),result}},function(module,exports,__webpack_require__){function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(a){var boxes=arguments.length<=1||void 0===arguments[1]?[]:arguments[1],property=arguments.length<=2||void 0===arguments[2]?"direct":arguments[2],lowest_distance=Number.MAX_VALUE,result=null;return boxes.forEach(function(box){var distance=(0,_getDistance2.default)(a,box)[property];distance1?_len-1:0),_key=1;_key<_len;_key++)params[_key-1]=arguments[_key];return arrayReduce.apply(array,params)}Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=arrayReduce;var _getNestedProperty=__webpack_require__(36),_getNestedProperty2=_interopRequireDefault(_getNestedProperty),_arrayReducePolyfill=__webpack_require__(37),_arrayReducePolyfill2=_interopRequireDefault(_arrayReducePolyfill)},function(module,exports){function getNestedProperty(){var data=arguments.length<=0||void 0===arguments[0]?window:arguments[0],path=arguments.length<=1||void 0===arguments[1]?"":arguments[1],default_value=arguments[2];if("string"!=typeof path)throw new TypeError('getNestedProperty: Provided path must be String (is "'+path+'").');var _ret=function(){var result=data;return""!==path&&path.split(".").forEach(function(segment){result="undefined"!=typeof result&&"undefined"!=typeof result[segment]?result[segment]:void 0}),{v:"undefined"==typeof result?default_value:result}}();if("object"===("undefined"==typeof _ret?"undefined":_typeof(_ret)))return _ret.v}var _typeof2="function"==typeof Symbol&&"symbol"===_typeof3(Symbol.iterator)?function(obj){return"undefined"==typeof obj?"undefined":_typeof3(obj)}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol?"symbol":"undefined"==typeof obj?"undefined":_typeof3(obj)};Object.defineProperty(exports,"__esModule",{value:!0});var _typeof="function"==typeof Symbol&&"symbol"===_typeof2(Symbol.iterator)?function(obj){return"undefined"==typeof obj?"undefined":_typeof2(obj)}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol?"symbol":"undefined"==typeof obj?"undefined":_typeof2(obj)};exports.default=getNestedProperty},function(module,exports){Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(callback){if(null==this)throw new TypeError("Array.prototype.reduce called on null or undefined");if("function"!=typeof callback)throw new TypeError(callback+" is not a function");var value,t=Object(this),len=t.length>>>0,k=0;if(2==arguments.length)value=arguments[1];else{for(;k=len)throw new TypeError("Reduce of empty array with no initial value");value=t[k++]}for(;k=0&&styleElementsInsertedAtTop.splice(idx,1)}function createStyleElement(options){var styleElement=document.createElement("style");return styleElement.type="text/css",insertStyleElement(options,styleElement),styleElement}function createLinkElement(options){var linkElement=document.createElement("link");return linkElement.rel="stylesheet",insertStyleElement(options,linkElement),linkElement}function addStyle(obj,options){var styleElement,update,remove;if(options.singleton){var styleIndex=singletonCounter++;styleElement=singletonElement||(singletonElement=createStyleElement(options)),update=applyToSingletonTag.bind(null,styleElement,styleIndex,!1),remove=applyToSingletonTag.bind(null,styleElement,styleIndex,!0)}else obj.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(styleElement=createLinkElement(options),update=updateLink.bind(null,styleElement),remove=function(){removeStyleElement(styleElement),styleElement.href&&URL.revokeObjectURL(styleElement.href)}):(styleElement=createStyleElement(options),update=applyToTag.bind(null,styleElement),remove=function(){removeStyleElement(styleElement)});return update(obj),function(newObj){if(newObj){if(newObj.css===obj.css&&newObj.media===obj.media&&newObj.sourceMap===obj.sourceMap)return;update(obj=newObj)}else remove()}}function applyToSingletonTag(styleElement,index,remove,obj){var css=remove?"":obj.css;if(styleElement.styleSheet)styleElement.styleSheet.cssText=replaceText(index,css);else{var cssNode=document.createTextNode(css),childNodes=styleElement.childNodes;childNodes[index]&&styleElement.removeChild(childNodes[index]),childNodes.length?styleElement.insertBefore(cssNode,childNodes[index]):styleElement.appendChild(cssNode)}}function applyToTag(styleElement,obj){var css=obj.css,media=obj.media;if(media&&styleElement.setAttribute("media",media),styleElement.styleSheet)styleElement.styleSheet.cssText=css;else{for(;styleElement.firstChild;)styleElement.removeChild(styleElement.firstChild);styleElement.appendChild(document.createTextNode(css))}}function updateLink(linkElement,obj){var css=obj.css,sourceMap=obj.sourceMap;sourceMap&&(css+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap))))+" */");var blob=new Blob([css],{type:"text/css"}),oldSrc=linkElement.href;linkElement.href=URL.createObjectURL(blob),oldSrc&&URL.revokeObjectURL(oldSrc)}var stylesInDom={},memoize=function(fn){var memo;return function(){return"undefined"==typeof memo&&(memo=fn.apply(this,arguments)),memo}},isOldIE=memoize(function(){return/msie [6-9]\b/.test(window.navigator.userAgent.toLowerCase())}),getHeadElement=memoize(function(){return document.head||document.getElementsByTagName("head")[0]}),singletonElement=null,singletonCounter=0,styleElementsInsertedAtTop=[];module.exports=function(list,options){options=options||{},"undefined"==typeof options.singleton&&(options.singleton=isOldIE()),"undefined"==typeof options.insertAt&&(options.insertAt="bottom");var styles=listToStyles(list);return addStylesToDom(styles,options),function(newList){for(var mayRemove=[],i=0;i%content%',events:{},events_toggle:[],events_on:[],events_off:[],callback_on:noop,callback_off:noop,z_index:1e3,appear_animation_duration:500,move_animation_duration:500,on_before_activate:noop_confirm,on_add:noop,on_before_deactivate:noop_confirm,on_remove:noop,on_activate:noop,on_deactivate:noop,on_animation_start:noop,on_animation_end:noop,on_destroy:noop},Launcher=function(){function Launcher(options){_classCallCheck(this,Launcher),this._state=!1,this._is_active=!1,this.attachments={},this.attachment_events={},this.options={},this._createEventHandlerReferences(),this.monitor=new _elementMonitor2.default(null,{onAppear:this._handleElementAppear.bind(this),onShow:this._handleElementAppear.bind(this),onVanish:this._handleElementVanish.bind(this),onHide:this._handleElementVanish.bind(this),onMove:this._handleElementChange.bind(this),onResize:this._handleElementChange.bind(this)}),this.setOptions(_extends({},default_options,options))}return _createClass(Launcher,[{key:"_createEventHandlerReferences",value:function(){this._handleToggleEvent=function(event,element){this._toggleState(event,element)}.bind(this),this._handleActivateEvent=function(event,element){this._setState(!0,event,element)}.bind(this),this._handleDeactivateEvent=function(event,element){this._setState(!1,event,element)}.bind(this)}},{key:"setOptions",value:function(){var options=arguments.length<=0||void 0===arguments[0]?{}:arguments[0];return this._setAllEventListeners(!1),_extends(this.options,options),this._setAllEventListeners(!0),this.template=(0,_utilities.constructTemplate)(this.options),this.monitor.elements.set(this.options.element),this}},{key:"_handleElementChange",value:function(element,prev_props,next_props,element_id){var attachment=this.attachments[element_id];if(attachment){var animation=attachment.move_animation,target_position=(0,_utilities.calculateAttachmentPosition)(attachment.element,element,this.options);animation.setOptions({target:{left:target_position.left,top:target_position.top}}),animation.start()}}},{key:"_handleElementAppear",value:function(element,prev_props,next_props,element_id){this._addAttachment(element)}},{key:"_handleElementVanish",value:function(element,prev_props,next_props,element_id){this._removeAttachment(element_id)}},{key:"activate",value:function(){!this._is_active&&this.options.on_before_activate()&&this._activate()}},{key:"_activate",value:function(){var _this=this;this.monitor.start(),this.monitor.elements.get().forEach(function(element){(0,_isVisible2.default)(element)&&_this._addAttachment(element)}),this._is_active=!0,this.options.on_activate()}},{key:"deactivate",value:function(){this._is_active&&this.options.on_before_deactivate()&&this._deactivate()}},{key:"_deactivate",value:function(){var _this2=this;this.monitor.stop(),Object.keys(this.attachments).forEach(function(element_id){_this2._removeAttachment(element_id)}),this._is_active=!1,this.options.on_deactivate()}},{key:"_addAttachment",value:function(element){var element_id=(0,_identifyElement.identifyElement)(element);if("undefined"==typeof this.attachments[element_id]){var attachment_element=(0,_utilities.createAttachmentElement)(this.template,this.options),attachment_object=(0,_utilities.createAttachmentObject)(attachment_element,this.options);this._setAttachmentEventListeners(attachment_element,!0),this.attachments[element_id]=attachment_object}var current_data=this.attachments[element_id];(0,_utilities.setupAttachmentElement)(current_data.element,element,this.options),current_data.appear_animation.setOptions({target:{opacity:1}}),current_data.appear_animation.start(),this.options.on_add(element)}},{key:"_removeAttachment",value:function(element_id){var _this3=this,attachment=this.attachments[element_id];if(attachment){var animation=attachment.appear_animation,animation_options={target:{opacity:0},onEnd:function(){_this3._destroyAttachment(element_id)}};animation.setOptions(animation_options),animation.start(),this.options.on_remove(element_id)}}},{key:"_destroyAttachment",value:function(element_id){var attachment=this.attachments[element_id];if(attachment){var element=attachment.element,parent=element.parentNode;parent&&element.parentNode.removeChild(element)}delete this.attachments[element_id]}},{key:"_setState",value:function(new_state,event,element){new_state=!!new_state,this._state!==new_state&&(new_state?this.options.callback_on(event,this,element):this.options.callback_off(event,this,element)),this._state=new_state}},{key:"_toggleState",value:function(event,element){this._setState(!this._state,event,element)}},{key:"_setAttachmentEventListeners",value:function(element,do_add){var _this4=this,element_id=(0,_identifyElement.identifyElement)(element),method=do_add?EventBridge.add:EventBridge.remove;do_add&&(this.attachment_events[element_id]={toggle:function(event){return _this4._handleToggleEvent(event,element)},on:function(event){return _this4._handleActivateEvent(event,element)},off:function(event){return _this4._handleDeactivateEvent(event,element)}}),method(element,this.options.events_toggle,this.attachment_events[element_id].toggle),method(element,this.options.events_on,this.attachment_events[element_id].on),method(element,this.options.events_off,this.attachment_events[element_id].off),Object.keys(this.options.events).forEach(function(event_type){do_add&&(_this4.attachment_events[element_id][event_type]=function(event){return _this4.options.events[event_type](event,_this4,element)}),method(element,event_type,_this4.attachment_events[element_id][event_type])})}},{key:"_setAllEventListeners",value:function(do_add){var _this5=this;Object.keys(this.attachments).forEach(function(element_id){var element=_this5.attachments[element_id].element;_this5._setAttachmentEventListeners(element,do_add)})}},{key:"destroy",value:function(){var _this6=this;this.deactivate(),this.options.on_destroy(),Object.keys(this.attachments).forEach(function(element_id){_this6._destroyAttachment(element_id)})}}]),Launcher}();exports.default=Launcher},function(module,exports,__webpack_require__){"use strict";function _interopRequireWildcard(obj){if(obj&&obj.__esModule)return obj;var newObj={};if(null!=obj)for(var key in obj)Object.prototype.hasOwnProperty.call(obj,key)&&(newObj[key]=obj[key]);return newObj.default=obj,newObj}function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function shouldCallbackFire(callback_id,prev,next){return callback_checks[callback_id](prev,next)}function filterProperties(){var input=arguments.length<=0||void 0===arguments[0]?{}:arguments[0],properties=arguments.length<=1||void 0===arguments[1]?[]:arguments[1],result={};return properties.forEach(function(key){result[key]=input[key]}),result}Object.defineProperty(exports,"__esModule",{value:!0});var _elementCollector=__webpack_require__(88),_elementCollector2=_interopRequireDefault(_elementCollector),_identifyElement=__webpack_require__(91),_getCurrentState2=__webpack_require__(93),_getCurrentState3=_interopRequireDefault(_getCurrentState2),_getUniqueKeys=__webpack_require__(95),_getUniqueKeys2=_interopRequireDefault(_getUniqueKeys),_callbackChecks=__webpack_require__(96),callback_checks=_interopRequireWildcard(_callbackChecks),_extends=Object.assign||function(target){for(var i=1;i=end?1:easePosition((now-start)/duration);return position}function calculatePositionValue(origin,target,position){return origin+(target-origin)*position}function getPropertyOrigins(element,properties){var box_properties=["left","top","width","height"],element_box=TheBox.getBox(element),result=(0,_styleProperties.getStyleProperties)(element,properties);if("fixed"===(0,_styleProperties.getStyleProperty)(element,"position")){var viewport_box=TheBox.getBox("viewport");element_box.moveBy(0-viewport_box.left,0-viewport_box.top)}return properties.forEach(function(property){box_properties.indexOf(property)!==-1&&(result[property]={unit:"px",value:element_box[property],output:element_box[property]+"px"})}),result}var _createClass=function(){function defineProperties(target,props){for(var i=0;i=0&&styleElementsInsertedAtTop.splice(idx,1)}function createStyleElement(options){var styleElement=document.createElement("style");return styleElement.type="text/css",insertStyleElement(options,styleElement),styleElement}function createLinkElement(options){var linkElement=document.createElement("link");return linkElement.rel="stylesheet",insertStyleElement(options,linkElement),linkElement}function addStyle(obj,options){var styleElement,update,remove;if(options.singleton){var styleIndex=singletonCounter++;styleElement=singletonElement||(singletonElement=createStyleElement(options)),update=applyToSingletonTag.bind(null,styleElement,styleIndex,!1),remove=applyToSingletonTag.bind(null,styleElement,styleIndex,!0)}else obj.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(styleElement=createLinkElement(options),update=updateLink.bind(null,styleElement),remove=function(){removeStyleElement(styleElement),styleElement.href&&URL.revokeObjectURL(styleElement.href)}):(styleElement=createStyleElement(options),update=applyToTag.bind(null,styleElement),remove=function(){removeStyleElement(styleElement)});return update(obj),function(newObj){if(newObj){if(newObj.css===obj.css&&newObj.media===obj.media&&newObj.sourceMap===obj.sourceMap)return;update(obj=newObj)}else remove()}}function applyToSingletonTag(styleElement,index,remove,obj){var css=remove?"":obj.css;if(styleElement.styleSheet)styleElement.styleSheet.cssText=replaceText(index,css);else{var cssNode=document.createTextNode(css),childNodes=styleElement.childNodes;childNodes[index]&&styleElement.removeChild(childNodes[index]),childNodes.length?styleElement.insertBefore(cssNode,childNodes[index]):styleElement.appendChild(cssNode)}}function applyToTag(styleElement,obj){var css=obj.css,media=obj.media;if(media&&styleElement.setAttribute("media",media),styleElement.styleSheet)styleElement.styleSheet.cssText=css;else{for(;styleElement.firstChild;)styleElement.removeChild(styleElement.firstChild);styleElement.appendChild(document.createTextNode(css))}}function updateLink(linkElement,obj){var css=obj.css,sourceMap=obj.sourceMap;sourceMap&&(css+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap))))+" */");var blob=new Blob([css],{type:"text/css"}),oldSrc=linkElement.href;linkElement.href=URL.createObjectURL(blob),oldSrc&&URL.revokeObjectURL(oldSrc)}var stylesInDom={},memoize=function(fn){var memo;return function(){return"undefined"==typeof memo&&(memo=fn.apply(this,arguments)),memo}},isOldIE=memoize(function(){return/msie [6-9]\b/.test(window.navigator.userAgent.toLowerCase())}),getHeadElement=memoize(function(){return document.head||document.getElementsByTagName("head")[0]}),singletonElement=null,singletonCounter=0,styleElementsInsertedAtTop=[];module.exports=function(list,options){options=options||{},"undefined"==typeof options.singleton&&(options.singleton=isOldIE()),"undefined"==typeof options.insertAt&&(options.insertAt="bottom");var styles=listToStyles(list);return addStylesToDom(styles,options),function(newList){for(var mayRemove=[],i=0;i=0?(console_args=[item.message,data],null!=this.options.prefix&&console_args.unshift(this.options.prefix),console[type].apply(console,console_args),this.options.onRecord(type,code,data,item.message)):void 0},Boogie.prototype.log=function(code,data){return this.record("log",code,data)},Boogie.prototype.info=function(code,data){return this.record("info",code,data)},Boogie.prototype.warn=function(code,data){return this.record("warn",code,data)},Boogie.prototype.error=function(code,data){return this.record("error",code,data)},Boogie.prototype.activate=function(){return this.is_active=!0,this.options.onActivate()},Boogie.prototype.deactivate=function(){return this.is_active=!1,this.options.onDeactivate()},Boogie.prototype.parseLocation=function(location){var ref,result;return result={},null!=(ref=location.search)&&ref.replace(/^\?/,"").split("&").map(function(item){var key,ref1,val;return ref1=item.split("="),key=ref1[0],val=ref1[1],result[key]=val}),result},Boogie.prototype.evalLocation=function(location){var found_filter,params;if(null==location&&(location=document.location),params=this.parseLocation(location),null!=params[this.options.url_prefix+"activate"]&&this.activate(),found_filter=params[this.options.url_prefix+"filter"],null!=found_filter)return this.setOptions({filter:found_filter.split(",")})},Boogie.prototype.evalStorage=function(){var found_filter;if(null!=localStorage.getItem(this.options.url_prefix+"activate")&&this.activate(),found_filter=localStorage.getItem(this.options.url_prefix+"filter"),null!=found_filter)return this.setOptions({filter:found_filter.split(",")})},Boogie}()},function(module,exports){"use strict";function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(exports,"__esModule",{value:!0});var noop=function(){},_class=function(){function _class(){var timeout=arguments.length<=0||void 0===arguments[0]?1e3:arguments[0];_classCallCheck(this,_class),this.timeout=timeout,this.timer=null}return _class.prototype.delayedAction=function(){var action=arguments.length<=0||void 0===arguments[0]?noop:arguments[0];clearTimeout(this.timer),this.timer=setTimeout(action,this.timeout)},_class}();exports.default=_class}]);(function(){ - createInlineManualPlayer({"base_path":"/","api_key":"b4b392a6f77d7d0d6e04cee62b835187","skin":"sidebar","position":"right_bottom","z_index":100000,"search_enabled":true,"context_topics_only":false,"filter_topics_by_language":false,"splash_mode":false,"splash_backdrop":true,"enable_mirroring":false,"hide_branding":true,"hide_trigger":true,"custom_trigger":null,"backdrop_color":"#000000","backdrop_opacity":"0.5","backdrop_padding":10,"variables":{},"tracking":{"enabled":true},"l10n":{"title":"Help","trigger_title":"","panel_title":"","footer":"","branding":"Powered by","branding_link":"https://inlinemanual.com/","previous":"← Previous","next":"Next →","end":"End","back":"Back","empty_topics_list":"No Help topics available for this page.","lang_direction":"ltr","search_submit":"Search","search_clear":"Clear","scroll_message":"Scroll into view"},"topics":{"19928":{"id":19928,"parent_id":null,"title":"Sign in as guest user","description":"Shows a user how to login as a guest on demo","type":"tour","language":"en","privacy":"public","published":true,"archived":false,"published_at":"2016-08-28T12:24:30.239Z","archived_at":null,"created_at":"2016-08-28T12:24:30.239Z","updated_at":"2016-08-31T15:34:09.662Z","tags":[],"context_paths":[],"context":null,"steps":[{"title":{"en":"Sign in as guest user"},"content":{"en":"To view the full demo site we recommend signing in as a guest user.  Let's get started..."},"path":null,"element":".reg-links.pull-right > .btn-group > :nth-child(1)","position":"bottom_right","delay":null,"width":300,"z_index":null,"backdrop":false,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","hide_prev","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":{"type":"inherit"},"launcher":null,"url_trigger":null,"backdrop_options":null,"triggers":[]},{"title":{"en":"Username"},"content":{"en":"Enter the username: demo"},"path":"account/login/","element":":nth-child(3) > .form-control.input-lg","position":"right","delay":null,"width":300,"z_index":null,"backdrop":false,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_title","hide_end","hide_progress","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":["condition"],"condition":{"type":"inherit"},"launcher":null,"url_trigger":{"url":"account/login/","scope":"current"},"backdrop_options":null,"triggers":[]},{"title":{"en":"Password"},"content":{"en":"Enter password: password"},"path":"account/login/","element":":nth-child(4) > .form-control.input-lg","position":"right","delay":null,"width":300,"z_index":null,"backdrop":false,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_title","hide_end","hide_progress","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":["condition"],"condition":{"type":"inherit"},"launcher":null,"url_trigger":null,"backdrop_options":null,"triggers":[]},{"title":{"en":"Submit form"},"content":{"en":"\"SelectSelect the SIGN IN button
\nto continue"},"path":"account/login/","element":".btn.btn-primary.btn-lg.btn-block.text-uppercase","position":"right","delay":null,"width":300,"z_index":null,"backdrop":false,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_title","hide_progress","hide_next","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":["condition"],"condition":{"type":"inherit"},"launcher":null,"url_trigger":null,"backdrop_options":null,"triggers":[{"element":null,"scope":"current","activate":"next","events":["click"]}]}],"trigger_element":null,"languages":["en"],"version":"HEAD","order":0,"hidden":false,"language_agnostic":false,"visibility":["segment_2673"],"launcher":{"visibility":"always","element":".reg-links.pull-right > .btn-group > :nth-child(1)","position":"left","offset_vertical":1,"offset_horizontal":-12,"z_index":null,"class_name":null,"content":null,"title":null,"template":null,"point_at":"self","context_paths":["https://demo.cadasta.org/*"],"toggle_events":null,"activate_events":null,"deactivate_events":null,"context":null},"owner":{"id":580,"type":"organization","name":"Cadasta","namespace":"cadasta"}},"19903":{"id":19903,"parent_id":19367,"title":"Quick start tour for dashboard","description":"Welcome registered users to Cadasta Demo Platform","type":"tour","language":"en","privacy":"public","published":true,"archived":false,"published_at":"2016-08-28T01:03:25.736Z","archived_at":null,"created_at":"2016-08-28T01:03:25.738Z","updated_at":"2016-09-02T01:24:57.305Z","tags":[],"context_paths":[],"context":null,"steps":[{"title":{"en":"Welcome to the Cadasta DEMO Platform","es":"","fr":""},"content":{"en":"
\n

Use this demo site to test, train, and provide feedback on our Platform.

\n\n

Collect, manage, and store data
\nregarding land and resource rights.

\n\n

Let's show you around a little first.

\n\n
Get Started >
\n\n

No thanks, just show me the map

\n
\n","es":"","fr":""},"path":"dashboard/","element":null,"position":"bottom_right","delay":null,"width":600,"z_index":null,"backdrop":true,"backdrop_cover":false,"final_step":false,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","hide_navigation","hide_next","hide_prev","splash","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":null,"launcher":null,"url_trigger":{"url":"dashboard/","scope":"current"},"backdrop_options":null,"triggers":[]},{"title":{"en":"Dashboard Map","es":"","fr":""},"content":{"en":"This map displays all public projects currently in the Cadasta DEMO Platform.","es":"","fr":""},"path":"dashboard/","element":null,"position":"top","delay":null,"width":300,"z_index":null,"backdrop":true,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","splash-sm","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":null,"launcher":null,"url_trigger":{"url":"dashboard/","scope":"current"},"backdrop_options":null,"triggers":[{"element":null,"scope":"current","activate":"next","events":["next"]}]},{"title":{"en":"Map controls","es":"","fr":""},"content":{"en":"Use the map controls to zoom, search, or find your current location. ","es":"","fr":""},"path":null,"element":".leaflet-control-zoom-in,.leaflet-control-zoom-out,.leaflet-pelias-search-icon,.leaflet-control-geolocate","position":"right","delay":null,"width":300,"z_index":null,"backdrop":true,"backdrop_cover":true,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","splash-sm","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":null,"launcher":null,"url_trigger":{"url":"dashboard/","scope":"current"},"backdrop_options":null,"triggers":[{"element":null,"scope":"current","activate":"next","events":["next"]}]},{"title":{"en":"Map markers","es":"","fr":""},"content":{"en":"A map marker indicates an active public project.\n
\"ClickClick on a map marker to continue","es":"","fr":""},"path":null,"element":".leaflet-marker-pane > :nth-child(1)","position":"bottom_right","delay":null,"width":300,"z_index":null,"backdrop":true,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","hide_next","hide_prev","splash-sm","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":null,"launcher":null,"url_trigger":{"url":"dashboard/","scope":"current"},"backdrop_options":null,"triggers":[{"element":null,"scope":"current","activate":"next","events":["click"]}]},{"title":{"en":"Map popover","es":"","fr":""},"content":{"en":"You can view the project name and supporting organization.  To open the project, select the open project button from here or...","es":"","fr":""},"path":null,"element":".leaflet-popup-content-wrapper","position":"right","delay":null,"width":300,"z_index":null,"backdrop":true,"backdrop_cover":true,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","splash-sm","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":null,"launcher":null,"url_trigger":{"url":"dashboard/","scope":"current"},"backdrop_options":null,"triggers":[{"element":null,"scope":"current","activate":"next","events":["next"]}]},{"title":{"en":"Projects tab","es":"","fr":""},"content":{"en":"You can also select Projects from the top navigation to view a list of all public projects.","es":"","fr":""},"path":null,"element":".list-inline.visible-md-block.visible-lg-block > .projects > a","position":"top","delay":null,"width":300,"z_index":null,"backdrop":true,"backdrop_cover":true,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","splash-sm","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":null,"launcher":null,"url_trigger":{"url":"dashboard/","scope":"current"},"backdrop_options":null,"triggers":[{"element":null,"scope":"current","activate":"next","events":["next"]}]},{"title":{"en":"What do you want to do next?","es":"","fr":""},"content":{"en":"
\n

Start exploring...

\n\n
\n\n\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t\t\n\t\t\t\n\t\t\n\t\n
\"Browse\n\t\t\t

Browse the map

\n\t\t\t
\n\t\t\t

Explore public land right projects across the globe to see how people are using the Cadasta platform.

\n\t\t\t
\n
\n\n
\n
What's next
\n\n

Ready to graduate to full production use of the Cadasta platform? Visit our Production Site.

\n
\n
\n\n
\n

Let us show you around a bit more...

\n\n
\n\n\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t\t\n\t\t\t\n\t\t\n\t\n
\"Tour\n\t\t\t

Tour a sample project

\n\t\t\t
\n\t\t\t

See how one community is using Cadasta to collect data and manage their land and resource rights.

\n\t\t\t
\n
\n\n
\n
Need more assistance?
\n\n

Additional user guides are always available or request a demo of the platform.

\n
\n
\n\n\n","es":"","fr":""},"path":"dashboard/","element":null,"position":"top","delay":null,"width":800,"z_index":null,"backdrop":true,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_controls","hide_end","hide_progress","hide_navigation","hide_next","hide_prev","splash","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":null,"launcher":null,"url_trigger":{"url":"dashboard/","scope":"current"},"backdrop_options":null,"triggers":[]}],"trigger_element":null,"languages":["en"],"version":"HEAD","order":1,"hidden":false,"language_agnostic":false,"visibility":null,"launcher":{"visibility":"always","element":".dashboard-map","position":"top_left","offset_vertical":170,"offset_horizontal":-20,"z_index":null,"class_name":null,"content":null,"title":null,"template":null,"point_at":"self","context_paths":["https://demo.cadasta.org/dashboard/"],"toggle_events":null,"activate_events":null,"deactivate_events":null,"context":null},"owner":{"id":580,"type":"organization","name":"Cadasta","namespace":"cadasta"}},"19889":{"id":19889,"parent_id":null,"title":"Sample project walkthrough","description":"Sample project walkthrough for splash screen final options page (no login required)","type":"tour","language":"en","privacy":"public","published":true,"archived":false,"published_at":"2016-08-26T21:08:56.409Z","archived_at":null,"created_at":"2016-08-26T21:08:56.409Z","updated_at":"2016-08-31T15:56:26.464Z","tags":[],"context_paths":[],"context":null,"steps":[{"title":{"en":"Tour a sample project"},"content":{"en":"Take a quick tour around a sample project on the Cadasta DEMO platform."},"path":null,"element":null,"position":"top","delay":null,"width":300,"z_index":null,"backdrop":true,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","hide_prev","splash-sm","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":null,"launcher":null,"url_trigger":null,"backdrop_options":null,"triggers":[{"element":null,"scope":"current","activate":"next","events":["next"]}]},{"title":{"en":"Project name"},"content":{"en":"Project name and supporting organization are shown here."},"path":"organizations/demo-org/projects/demonstration-of-customary-rights/","element":"h1","position":"bottom_right","delay":null,"width":300,"z_index":null,"backdrop":true,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":{"type":"inherit"},"launcher":null,"url_trigger":null,"backdrop_options":null,"triggers":[]},{"title":{"en":"Project navigation"},"content":{"en":"These tabs link to the main sections within the project. "},"path":"organizations/demo-org/projects/demonstration-of-customary-rights/","element":".nav.nav-sidebar","position":"right","delay":null,"width":300,"z_index":null,"backdrop":true,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":{"type":"inherit"},"launcher":null,"url_trigger":null,"backdrop_options":null,"triggers":[]},{"title":{"en":"Project overview"},"content":{"en":"This area show details such as project description and summary statistics."},"path":"organizations/demo-org/projects/demonstration-of-customary-rights/","element":".col-md-4.detail","position":"left","delay":null,"width":300,"z_index":null,"backdrop":true,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":{"type":"inherit"},"launcher":null,"url_trigger":null,"backdrop_options":null,"triggers":[]},{"title":{"en":"Project map"},"content":{"en":"The project map provides an aerial view of the project boundaries and locations."},"path":"organizations/demo-org/projects/demonstration-of-customary-rights/","element":".leaflet-container-default.leaflet-container.leaflet-retina.leaflet-fade-anim","position":"right","delay":null,"width":300,"z_index":null,"backdrop":true,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":null,"launcher":null,"url_trigger":null,"backdrop_options":null,"triggers":[{"element":null,"scope":"current","activate":"next","events":["click"]}]},{"title":{"en":"Project locations"},"content":{"en":"Each map marker displays a location. By selecting a clickable area on the map, you can view location data, relationships, and resources in the right detail area."},"path":"organizations/demo-org/projects/demonstration-of-customary-rights/","element":".leaflet-marker-icon.leaflet-zoom-animated.leaflet-clickable","position":"right","delay":null,"width":300,"z_index":null,"backdrop":true,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_end","hide_progress","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":[],"condition":null,"launcher":null,"url_trigger":null,"backdrop_options":null,"triggers":[{"element":null,"scope":"current","activate":"next","events":["next"]}]},{"title":{"en":"What's next?"},"content":{"en":"That's a quick overview of a project.
\n
\nTo view the full demo site we recommend signing in as a guest user. 
\n \n
Sign in as demo user
\n
\nIf you need additional assistance refer to our user guides or contact us at info@cadasta.org."},"path":"organizations/demo-org/projects/demonstration-of-customary-rights/","element":null,"position":"top","delay":null,"width":300,"z_index":null,"backdrop":false,"backdrop_cover":false,"final_step":null,"max_continuation_attempts":3,"class_names":["hide_progress","hide_next","splash-sm","inmplayer_tpl_step_default"],"custom_data":{},"on_before_activate":"","on_activate":"","on_deactivate":"","on_show":"","author_changes":["condition"],"condition":null,"launcher":null,"url_trigger":null,"backdrop_options":null,"triggers":[]}],"trigger_element":null,"languages":["en"],"version":"HEAD","order":2,"hidden":false,"language_agnostic":false,"visibility":null,"launcher":{"visibility":"always","element":null,"position":"left","offset_vertical":0,"offset_horizontal":0,"z_index":null,"class_name":null,"content":null,"title":null,"template":null,"point_at":"self","context_paths":["https://demo.cadasta.org/*"],"toggle_events":null,"activate_events":null,"deactivate_events":null,"context":null},"owner":{"id":580,"type":"organization","name":"Cadasta","namespace":"cadasta"}}},"rules":{"4d4771d723af0e40e47e1a41ef5dd60f":{"type":"rule","field":"username","kind":"text","condition":"not_empty"},"segment_2674":{"type":"ruleset","operation":"and","description":"Cadasta registered users","rules":["4d4771d723af0e40e47e1a41ef5dd60f"]},"c42f992f199227725672c2c0006991db":{"type":"rule","field":"username","kind":"text","condition":"empty"},"segment_2673":{"type":"ruleset","operation":"and","description":"Cadasta public users","rules":["c42f992f199227725672c2c0006991db"]},"1550d793301486e33832936f3e1636b4":{"type":"rule","field":"created","kind":"date","condition":"less_than","value":"24 hours"},"segment_2638":{"type":"ruleset","operation":"and","description":"Everyone but new users","rules":["1550d793301486e33832936f3e1636b4"]},"c8e4ec34a5d21312b9f8c9471321f2be":{"type":"rule","field":"created","kind":"date","condition":"within","value":"30 minutes"},"segment_2637":{"type":"ruleset","operation":"and","description":"New users","rules":["c8e4ec34a5d21312b9f8c9471321f2be"]},"9c3500a3c40e31e36d11d1f55b9c106d":{"type":"rule","field":"autolaunchers.2769","kind":"number","condition":"empty"},"1cfa42b7f2441052c86fbbe55e018b5c":{"type":"rule","field":null,"kind":"url","condition":"match_current","value":"https://demo.cadasta.org/dashboard/"},"autolauncher_2769":{"type":"ruleset","operation":"and","rules":["9c3500a3c40e31e36d11d1f55b9c106d","1cfa42b7f2441052c86fbbe55e018b5c"]}},"actions":{"autolaunch":[{"id":2769,"rule":"autolauncher_2769","topic":19903}]},"style":".inmplayer-popover-wrapper { background-color: #ffffff; color: #595a5c; border-style: solid; border-color: #2e51a3; border-width: 2px; -webkit-border-radius: 20px; -moz-border-radius: 20px; border-radius: 20px; font-size: 15px; font-weight: 500; line-height: 20px; font-family: Roboto, Helvetica Neue, Helvetica, Arial, sans-serif;}.inmplayer-button, .inmplayer-popover-button-previous, .inmplayer-popover-button-next, .inmplayer-popover-button-end { background-color: #00b288; color: #ffffff; border-style: solid; border-color: #009975; border-width: 1px; -webkit-border-radius: 4px; -moz-border-radius: 4px; border-radius: 4px;}.inmplayer-popover-pointer-shape { fill: #2e51a3; stroke: #333333; stroke-width: 1px;}.inmplayer-launcher { background-color: #00b288; color: #ffffff; border-style: solid; border-color: #009975; border-width: 1%; -webkit-border-radius: 50%; -moz-border-radius: 50%; border-radius: 50%;}.inmplayer-panel-header, .inmplayer-trigger { background-color: #2e51a3; color: #ffffff;}.inmplayer-panel-close-button { background-color: transparent;}.inmplayer-article-item-title { display: none;}.inmplayer-trigger { display: none;}.inmplayer-popover-content { font-family: 'Roboto', sans-serif;}.inmplayer-popover-inner-content { padding-bottom: 8px;}.inmplayer-popover-buttons { clear: both; padding: 8px;}.inmplayer-popover-button-previous { background-color: #f2f4f7; border-color: #ccc; color: #333;}.inmplayer-popover-button-next { float: right; }.inmplayer-popover-progress { clear: both;}.inmplayer-popover-wrapper { -webkit-background-clip: padding-box; background-clip: padding-box; -webkit-box-shadow: 0 0 0 5px rgba(255, 255, 255, 0.3); -moz-box-shadow: 0 0 0 5px rgba(255, 255, 255, 0.3); box-shadow: 0 0 0 5px rgba(255, 255, 255, 0.3);}.inmplayer-popover-pointer-holder { z-index: 1000000022;}.inmplayer-popover-content { padding: 0;}.inmplayer-popover-title { font-family: 'Roboto Condensed', sans-serif; border-radius: 15px 15px 0 0; -moz-border-radius: 15px 15px 0 0; -webkit-border-radius: 15px 15px 0 0; background: #2e51a3; margin: 0; padding: 15px; font-size: 24px; line-height: 24px; text-align: center; color: #fff; text-transform: none; letter-spacing: 0;}.splash .inmplayer-popover-title { padding: 30px 15px; font-size: 30px; line-height: 30px; } .inmplayer-popover-inner-content { border-radius: 15px; -moz-border-radius: 15px; -webkit-border-radius: 15px; background: #fff; padding: 20px;}.splash .inmplayer-popover-inner-content { padding: 20px 0 0 0; text-align: center;}.splash .inmplayer-popover-inner-content h1 { font-family: 'Roboto Condensed', sans-serif; letter-spacing: -0.3px; color: #0e305e; font-weight: 600; margin-bottom: 20px;}.splash .inmplayer-popover-inner-content h3 { font-family: 'Roboto Condensed', sans-serif; font-weight: 500; font-size: 28px; margin: 30px 0 20px; color: #595a5c;}.splash .inmplayer-popover-inner-content h3 span { display: block; margin-top: 6px; font-weight: 300; font-size: 24px;}.splash #get-started.inmplayer-button { font-family: 'Roboto Condensed', sans-serif; font-size: 24px !important; text-transform: uppercase; letter-spacing: 0.5px; text-shadow: 1px 1px rgba(31, 54, 79, 0.2); -webkit-box-shadow: 0 1px 4px rgba(31, 54, 79, 0.2); -moz-box-shadow: 0 1px 4px rgba(31, 54, 79, 0.2); box-shadow: 0 1px 4px rgba(31, 54, 79, 0.2); clear: both; width: 50%; min-width: 200px; margin: 30px auto; padding: 10px 16px; border-radius: 6px;}.splash a.btn-link { color: #595a5c;}.splash .col-md-6 { text-align: left; margin-bottom: 20px; padding: 0 24px 12px 24px;}.splash .col-md-6:first-of-type { border-right: solid 1px #e7e8ea;}.splash .splash-option { padding: 0 0 0 10px; border-radius: 12px; -moz-border-radius: 12px; -webkit-border-radius: 12px; border: solid 1px #00b288; background: #00b288; margin-bottom: 20px;}.splash .splash-option:hover { cursor: pointer; border-color: #009975; background: #009975;}.splash h4, .splash h5 { font-family: 'Roboto Condensed', sans-serif; font-weight: 600; font-size: 16px;}.splash h4 { font-size: 20px; color: #2e51a3;}.splash td { vertical-align: top;}.splash .right-arrow { color: #fff; border-radius: 0 8px 8px 0; -moz-border-radius: 0 8px 8px 0; -webkit-border-radius: 0 8px 8px 0; vertical-align: middle; text-align: center; font-size: 20px;}.splash .button-row { background: #f2f4f7; clear: both; border-radius: 0 0 15px 15px; -moz-border-radius: 0 0 15px 15px; -webkit-border-radius: 0 0 15px 15px; padding: 15px; font-size: 24px; line-height: 24px;}.splash .button-row .btn { color: #2e51a3; font-family: 'Roboto Condensed', sans-serif; font-weight: 600; font-size: 14px; width: 96%; background: transparent;}.splash .button-row .btn img { height: 24px; width: 24px;}.inmplayer-popover-buttons { padding-bottom: 12px;}.splash .inmplayer-popover-buttons { margin-top: 0; padding: 0;}.inmplayer-popover-close-button { font-weight: 600; font-size: 22px; color: #fff; opacity: 0.3;}.inmplayer-launcher:after { content: \" \"; margin: 0 auto; border-radius: 100px; position: absolute; right: -14px; top: -14px; z-index: 10; background-color: transparent; opacity: 0.1; width: 48px; height: 48px; border: 2px solid rgba(0,128,64,1); -webkit-border-radius: 100px; -moz-border-radius: 100px; -o-border-radius: 100px; -ms-border-radius: 100px; border-radius: 100px; -webkit-animation: pulse 2s linear infinite; -moz-animation: pulse 2s linear infinite; border-image: initial;}@-webkit-keyframes pulse { 0% {-webkit-transform: scale(0); opacity: 0;} 8% {-webkit-transform: scale(0); opacity: 0;} 15% {-webkit-transform: scale(0.1); opacity: 1;} 30% {-webkit-transform: scale(0.5); opacity: 1;} 100% {opacity: 0; -webkit-transform: scale(1);}} @-moz-keyframes pulse { 0% {-moz-transform: scale(0); opacity: 0;} 8% {-moz-transform: scale(0); opacity: 0;} 15% {-moz-transform: scale(0.1); opacity: 1;} 30% {-moz-transform: scale(0.5); opacity: 1;} 100% {opacity: 0; -moz-transform: scale(1);}}@media (max-width:720px){ .inmplayer-general { display: none; }}"}); -}).call(this); + +// User tracking + +window.inlineManualTracking = { + uid: "{{ user.id }}", + username: "{{ user.username }}" +} + +// Embed correct player for site; default is dev version + +var myplayer = "c384a8ce835342a913859b2a50d1f6a9"; + +!function(){var e=document.createElement("script"),t=document.getElementsByTagName("script")[0];e.async=1,e.src="https://inlinemanual.com/embed/player." + myplayer + ".js",e.charset="UTF-8",t.parentNode.insertBefore(e,t)}(); diff --git a/cadasta/templates/core/base.html b/cadasta/templates/core/base.html index f5b709953..34cc871aa 100644 --- a/cadasta/templates/core/base.html +++ b/cadasta/templates/core/base.html @@ -66,9 +66,9 @@ {% endif %} - - - + + + @@ -236,12 +236,6 @@ $(".alert-success").fadeTo(500, 0).slideUp(500, function(){ $(this).hide(); }); }, 5000); - diff --git a/provision/roles/cadasta/production/tasks/main.yml b/provision/roles/cadasta/production/tasks/main.yml index 9fa9b4eee..3c3b31ec5 100644 --- a/provision/roles/cadasta/production/tasks/main.yml +++ b/provision/roles/cadasta/production/tasks/main.yml @@ -5,3 +5,9 @@ requirements="{{ application_path }}requirements/production.txt" extra_args="--find-links https://s3.amazonaws.com:443/cadasta-wheelhouse/index.html" +- name: Write Inline Manual template to core files + become: yes + become_user: root + template: src=inline-manual-player + dest="{{ application_path }}cadasta/core/static/js/inline-manual-player.js" + diff --git a/provision/roles/cadasta/production/templates/inline-manual-player b/provision/roles/cadasta/production/templates/inline-manual-player new file mode 100644 index 000000000..3b65c30d8 --- /dev/null +++ b/provision/roles/cadasta/production/templates/inline-manual-player @@ -0,0 +1,17 @@ +/* +Inline Manual Player, v2.34.1 +http://inlinemanual.com/ +*/ + +// User tracking + +window.inlineManualTracking = { + uid: "{{ user.id }}", + username: "{{ user.username }}" +} + +// Embed correct player for site - myplayer variable + +var myplayer = "{{ myplayer }}"; + +!function(){var e=document.createElement("script"),t=document.getElementsByTagName("script")[0];e.async=1,e.src="https://inlinemanual.com/embed/player." + myplayer + ".js",e.charset="UTF-8",t.parentNode.insertBefore(e,t)}();