Commit b935e3bcb2cac3f2feeecc0e52d7671cf3be335a

Authored by Fabio Teixeira
1 parent ebd761e2

Add step for mention text

features/step_definitions/custom_web_steps.rb
... ... @@ -53,3 +53,19 @@ When /^I type in "([^\"]*)" into autocomplete list "([^\"]*)" and I choose "([^\
53 53 page.execute_script ("jQuery('.token-input-dropdown li:contains(\"#{result}\")').trigger('mousedown');")
54 54 page.should have_selector('li.token-input-token')
55 55 end
  56 +
  57 +When /^I type "([^\"]*)" into mention textarea "([^\"]*)" and I choose "([^\"]*)"$/ do |term, textarea, result|
  58 + # We seem to have to wait for the page to load js
  59 + sleep 1
  60 +
  61 + page.execute_script("setInputBuffer('#{term}')")
  62 +
  63 + page.execute_script("jQuery('##{input}').trigger('focus').val('#{term}').trigger('input')")
  64 +
  65 + # We use this to wait for the search
  66 + page.should have_selector('.mentions-autocomplete-list li')
  67 +
  68 + page.execute_script ("jQuery('.mentions-autocomplete-list li:contains(\"#{result}\")').trigger('mousedown');")
  69 +
  70 + page.should have_selector('li.token-input-token')
  71 +end
... ...
features/user_mention.feature 0 → 100644
... ... @@ -0,0 +1,33 @@
  1 +Feature: user mention
  2 +As a user
  3 + I want to mention my friends and community members
  4 + So that they get notified about what I wrote
  5 +
  6 + Background:
  7 + Given the following users
  8 + | login |
  9 + | fulano |
  10 + | ciclano |
  11 + | deltrano |
  12 + And "ciclano" is friend of "fulano"
  13 + And the following communities
  14 + | identifier | name | owner |
  15 + | test-community | test community | fulano |
  16 + And "deltrano" is a member of "test community"
  17 + And the following articles
  18 + | owner | name |
  19 + | fulano | fulano article |
  20 + | test-community | comunity article |
  21 + And I am logged in as "fulano"
  22 +
  23 +
  24 + @selenium
  25 + Scenario: mention a friend
  26 + Given I am on /fulano/fulano-article
  27 + And I follow "Post a comment"
  28 + And I fill in "Title" with "Hey ho, let's go!"
  29 + And I type "@cic" into mention textarea "#comment_body" and I choose "ciclano"
  30 + And I should see "@ciclano"
  31 + When I press "Post comment"
  32 + Then I should see "Hey ho, let"
  33 +
... ...
public/javascripts/vendor/jquery.mentionsInput.mod.js
... ... @@ -176,6 +176,16 @@
176 176 inputBuffer = [];
177 177 }
178 178  
  179 + // selenium tests purposes only
  180 + function setInputBuffer(value) {
  181 + if (_.isArray(value)) {
  182 + inputBuffer = value;
  183 + } else if (_.isString(value)) {
  184 + inputBuffer = value.split("");
  185 + }
  186 + }
  187 + window.setInputBuffer = setInputBuffer;
  188 +
179 189 //Updates the mentions collection
180 190 function updateMentionsCollection() {
181 191 var inputText = getInputBoxValue(); //Get the actual value of text area
... ...
public/javascripts/vendor/jquery.mentionsInput.mod.min.js
1   -!function(e,t,n){t.templateSettings={interpolate:/<%=([\s\S]+?)%>/g};var i={BACKSPACE:8,TAB:9,RETURN:13,ESC:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,COMMA:188,SPACE:32,HOME:36,END:35},a={triggerChar:"@",onDataRequest:e.noop,minChars:2,allowRepeat:!1,showAvatars:!0,elastic:!0,defaultValue:"",onCaret:!1,keepTriggerCharacter:!1,classes:{autoCompleteItemActive:"active"},templates:{wrapper:t.template('<div class="mentions-input-box"></div>'),autocompleteList:t.template('<div class="mentions-autocomplete-list"></div>'),autocompleteListItem:t.template('<li data-ref-id="<%= id %>" data-ref-type="<%= type %>" data-display="<%= display %>"><%= content %> <small><%= fullName %></small></li>'),autocompleteListItemAvatar:t.template('<img src="<%= avatar %>" />'),autocompleteListItemIcon:t.template('<div class="icon <%= icon %>"></div>'),mentionsOverlay:t.template('<div class="mentions"><div></div></div>'),mentionItemSyntax:t.template("@[<%= value %>](<%= type %>:<%= id %>)"),mentionItemHighlight:t.template("<strong><span><%= value %></span></strong>")}},o={htmlEncode:function(e){return t.escape(e)},regexpEncode:function(e){return e.replace(/([.*+?^=!:${}()|\[\]\/\\])/g,"\\$1")},highlightTerm:function(e,t){return t||t.length?e.replace(new RegExp("(?![^&;]+;)(?!<[^<>]*)("+t+")(?![^<>]*>)(?![^&;]+;)","gi"),"<b>$1</b>"):e},setCaratPosition:function(e,t){if(e.createTextRange){var n=e.createTextRange();n.move("character",t),n.select()}else e.selectionStart?(e.focus(),e.setSelectionRange(t,t)):e.focus()},rtrim:function(e){return e.replace(/\s+$/,"")}},r=function(n){function r(){M=e(k),"true"!==M.attr("data-mentions-input")&&(L=M.parent(),O=e(n.templates.wrapper()),M.wrapAll(O),O=L.find("> div.mentions-input-box"),M.attr("data-mentions-input","true"),M.bind("keydown",b),M.bind("keypress",E),M.bind("click",x),M.bind("blur",C),navigator.userAgent.indexOf("MSIE 8")>-1?M.bind("propertychange",w):M.bind("input",w),n.elastic&&M.elastic())}function l(){N=e(n.templates.autocompleteList()),N.appendTo(O),N.delegate("li","mousedown",v)}function s(){H=e(n.templates.mentionsOverlay()),H.prependTo(O)}function c(){var e=f();t.each(P,function(t){var i=n.templates.mentionItemSyntax(t);e=e.replace(new RegExp(o.regexpEncode(t.value),"g"),i)});var i=o.htmlEncode(e);t.each(P,function(e){var a=t.extend({},e,{value:o.htmlEncode(e.value)}),r=n.templates.mentionItemSyntax(a),l=n.templates.mentionItemHighlight(a);i=i.replace(new RegExp(o.regexpEncode(r),"g"),l)}),i=i.replace(/\n/g,"<br />"),i=i.replace(/ {2}/g,"&nbsp; "),M.data("messageText",e),M.trigger("updated"),H.find("div").html(i)}function d(){F=[]}function p(){var e=f();P=t.reject(P,function(t,n){return!t.value||e.indexOf(t.value)==-1}),P=t.compact(P)}function u(e){for(var i,a=f(),r=M[0].selectionStart,l=!1,s=!1,p=new RegExp("\\"+n.triggerChar+W,"gi");i=p.exec(a);)(l===!1||Math.abs(p.lastIndex-r)<l)&&(l=Math.abs(p.lastIndex-r),s=p.lastIndex);var u=s-W.length-1,m=s,g=a.substr(0,u),h=a.substr(m,a.length),v=(g+e.value).length+1;t.find(P,function(t){return t.id==e.id})||P.push(e),d(),W="",y();var x=g;n.keepTriggerCharacter&&(x+=n.triggerChar),x+=e.value+" "+h,M.val(x),M.trigger("mention"),c(),M.focus(),o.setCaratPosition(M[0],v)}function f(){return e.trim(M.val())}function m(t){var n,i,a,o,r,l,s,c,d,p,u;if((d=t[0])&&e(d).is("textarea")&&null!=d.selectionEnd){for(s={position:"absolute",overflow:"auto",whiteSpace:"pre-wrap",wordWrap:"break-word",boxSizing:"content-box",top:0,left:-9999},c=["boxSizing","fontFamily","fontSize","fontStyle","fontVariant","fontWeight","height","letterSpacing","lineHeight","paddingBottom","paddingLeft","paddingRight","paddingTop","textDecoration","textIndent","textTransform","width","word-spacing"],p=0,u=c.length;p<u;p++)r=c[p],s[r]=e(d).css(r);return a=document.createElement("div"),e(a).css(s),e(d).after(a),i=document.createTextNode(d.value.substring(0,d.selectionEnd)),n=document.createTextNode(d.value.substring(d.selectionEnd)),o=document.createElement("span"),o.innerHTML="&nbsp;",a.appendChild(i),a.appendChild(o),a.appendChild(n),a.scrollTop=d.scrollTop,l=e(o).position(),e(a).remove(),l}}function g(t){var n,i,a,o,r,l,s,c,d,p,u;if((d=t[0])&&e(d).is("textarea")&&null!=d.selectionEnd){for(s={position:"absolute",overflow:"auto",whiteSpace:"pre-wrap",wordWrap:"break-word",boxSizing:"content-box",top:0,left:-9999},c=["boxSizing","fontFamily","fontSize","fontStyle","fontVariant","fontWeight","height","letterSpacing","lineHeight","paddingBottom","paddingLeft","paddingRight","paddingTop","textDecoration","textIndent","textTransform","width","word-spacing"],p=0,u=c.length;p<u;p++)r=c[p],s[r]=e(d).css(r);return a=document.createElement("div"),e(a).css(s),e(d).after(a),i=document.createTextNode(d.value.substring(0,d.selectionEnd)),n=document.createTextNode(d.value.substring(d.selectionEnd)),o=document.createElement("span"),o.innerHTML="&nbsp;",a.appendChild(i),a.appendChild(o),a.appendChild(n),a.scrollTop=d.scrollTop,l=e(o).offset(),e(a).remove(),l}}function h(){var t=e(M).offset().top,n=e("body").offset().top,i=e(window).scrollTop();i>t&&e(window).scrollTop(t-n)}function v(t){var n=e(this),i=B[n.attr("data-uid")];return u(i),h(),!1}function x(e){d()}function C(e){y()}function w(e){c(),p();var i=t.lastIndexOf(F,n.triggerChar);i>-1&&(W=F.slice(i+1).join(""),W=o.rtrim(W),t.defer(t.bind(S,this,W)))}function E(e){if(e.keyCode!==i.BACKSPACE){var t=String.fromCharCode(e.which||e.keyCode);F.push(t)}}function b(n){if(n.keyCode===i.LEFT||n.keyCode===i.RIGHT||n.keyCode===i.HOME||n.keyCode===i.END)return t.defer(d),void(navigator.userAgent.indexOf("MSIE 9")>-1&&t.defer(c));if(n.keyCode===i.BACKSPACE)return void(F=F.slice(0,-1+F.length));if(!N.is(":visible"))return!0;switch(n.keyCode){case i.UP:case i.DOWN:var a=null;return a=n.keyCode===i.DOWN?D&&D.length?D.next():N.find("li").first():e(D).prev(),a.length&&T(a),!1;case i.RETURN:case i.TAB:if(D&&D.length)return D.trigger("mousedown"),!1}return!0}function y(){D=null,N.empty().hide()}function T(e){e.addClass(n.classes.autoCompleteItemActive),e.siblings().removeClass(n.classes.autoCompleteItemActive),D=e}function I(i,a){if(N.show(),!n.allowRepeat){var r=t.pluck(P,"value");a=t.reject(a,function(e){return t.include(r,e.name)})}if(!a.length)return void y();N.empty();var l=e("<ul>").appendTo(N).hide();t.each(a,function(a,r){var s=t.uniqueId("mention_");B[s]=t.extend({},a,{value:a.name});var c=e(n.templates.autocompleteListItem({id:o.htmlEncode(a.id),display:o.htmlEncode(a.name),type:o.htmlEncode(a.type),fullName:o.htmlEncode(a.fullName),content:o.highlightTerm(o.htmlEncode(a.display?a.display:a.name),i)})).attr("data-uid",s);if(0===r&&T(c),n.showAvatars){var d;d=e(a.avatar?n.templates.autocompleteListItemAvatar({avatar:a.avatar}):n.templates.autocompleteListItemIcon({icon:a.icon})),d.prependTo(c)}c=c.appendTo(l)}),N.show(),n.onCaret&&A(N,M),l.show()}function S(e){e&&e.length&&e.length>=n.minChars?n.onDataRequest.call(this,"search",e,function(t){I(e,t)}):y()}function A(e,t){var n=e.css("position");if("absolute"==n){var i=m(t),a=parseInt(t.css("line-height"),10)||18;e.css("width","15em"),e.css("left",i.left),e.css("top",a+i.top);var o=t.offset().left+t.width(),r=e.offset().left+e.width();o<=r&&e.css("left",Math.abs(e.position().left-(r-o)))}else if("fixed"==n){var l=g(t),a=parseInt(t.css("line-height"),10)||18;e.css("width","15em"),e.css("left",l.left+1e4),e.css("top",a+l.top)}}function R(e){P=[];for(var t,i=o.htmlEncode(e),a=new RegExp("("+n.triggerChar+")\\[(.*?)\\]\\((.*?):(.*?)\\)","gi"),r=i;null!=(t=a.exec(i));)r=r.replace(t[0],t[1]+t[2]),P.push({id:t[4],type:t[3],value:t[2],trigger:t[1]});M.val(r),c()}var k,M,L,N,O,H,D,P=[],B={},F=[],W="";return n=e.extend(!0,{},a,n),{init:function(e){k=e,r(),l(),s(),R(n.defaultValue),n.prefillMention&&u(n.prefillMention)},val:function(e){t.isFunction(e)&&e.call(this,P.length?M.data("messageText"):f())},reset:function(){R()},reinit:function(){R(!1)},getMentions:function(e){t.isFunction(e)&&e.call(this,P)}}};e.fn.mentionsInput=function(n,i){var a=arguments;return"object"!=typeof n&&n||(i=n),this.each(function(){var o=e.data(this,"mentionsInput")||e.data(this,"mentionsInput",new r(i));return t.isFunction(o[n])?o[n].apply(this,Array.prototype.slice.call(a,1)):"object"!=typeof n&&n?void e.error("Method "+n+" does not exist"):o.init.call(this,this)})}}(jQuery,_.runInContext());
  1 +!function(e,t){t.templateSettings={interpolate:/<%=([\s\S]+?)%>/g};var n={BACKSPACE:8,TAB:9,RETURN:13,ESC:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,COMMA:188,SPACE:32,HOME:36,END:35},i={triggerChar:"@",onDataRequest:e.noop,minChars:2,allowRepeat:!1,showAvatars:!0,elastic:!0,defaultValue:"",onCaret:!1,keepTriggerCharacter:!1,classes:{autoCompleteItemActive:"active"},templates:{wrapper:t.template('<div class="mentions-input-box"></div>'),autocompleteList:t.template('<div class="mentions-autocomplete-list"></div>'),autocompleteListItem:t.template('<li data-ref-id="<%= id %>" data-ref-type="<%= type %>" data-display="<%= display %>"><%= content %> <small><%= fullName %></small></li>'),autocompleteListItemAvatar:t.template('<img src="<%= avatar %>" />'),autocompleteListItemIcon:t.template('<div class="icon <%= icon %>"></div>'),mentionsOverlay:t.template('<div class="mentions"><div></div></div>'),mentionItemSyntax:t.template("@[<%= value %>](<%= type %>:<%= id %>)"),mentionItemHighlight:t.template("<strong><span><%= value %></span></strong>")}},a={htmlEncode:function(e){return t.escape(e)},regexpEncode:function(e){return e.replace(/([.*+?^=!:${}()|\[\]\/\\])/g,"\\$1")},highlightTerm:function(e,t){return t||t.length?e.replace(new RegExp("(?![^&;]+;)(?!<[^<>]*)("+t+")(?![^<>]*>)(?![^&;]+;)","gi"),"<b>$1</b>"):e},setCaratPosition:function(e,t){if(e.createTextRange){var n=e.createTextRange();n.move("character",t),n.select()}else e.selectionStart?(e.focus(),e.setSelectionRange(t,t)):e.focus()},rtrim:function(e){return e.replace(/\s+$/,"")}},o=function(o){function r(){L=e(M),"true"!==L.attr("data-mentions-input")&&(N=L.parent(),H=e(o.templates.wrapper()),L.wrapAll(H),H=N.find("> div.mentions-input-box"),L.attr("data-mentions-input","true"),L.bind("keydown",b),L.bind("keypress",E),L.bind("click",w),L.bind("blur",C),navigator.userAgent.indexOf("MSIE 8")>-1?L.bind("propertychange",y):L.bind("input",y),o.elastic&&L.elastic())}function l(){O=e(o.templates.autocompleteList()),O.appendTo(H),O.delegate("li","mousedown",x)}function s(){D=e(o.templates.mentionsOverlay()),D.prependTo(H)}function c(){var e=m();t.each(P,function(t){var n=o.templates.mentionItemSyntax(t);e=e.replace(new RegExp(a.regexpEncode(t.value),"g"),n)});var n=a.htmlEncode(e);t.each(P,function(e){var i=t.extend({},e,{value:a.htmlEncode(e.value)}),r=o.templates.mentionItemSyntax(i),l=o.templates.mentionItemHighlight(i);n=n.replace(new RegExp(a.regexpEncode(r),"g"),l)}),n=n.replace(/\n/g,"<br />"),n=n.replace(/ {2}/g,"&nbsp; "),L.data("messageText",e),L.trigger("updated"),D.find("div").html(n)}function d(){W=[]}function p(e){t.isArray(e)?W=e:t.isString(e)&&(W=e.split(""))}function u(){var e=m();P=t.reject(P,function(t){return!t.value||-1==e.indexOf(t.value)}),P=t.compact(P)}function f(e){for(var n,i=m(),r=L[0].selectionStart,l=!1,s=!1,p=new RegExp("\\"+o.triggerChar+j,"gi");n=p.exec(i);)(l===!1||Math.abs(p.lastIndex-r)<l)&&(l=Math.abs(p.lastIndex-r),s=p.lastIndex);var u=s-j.length-1,f=s,g=i.substr(0,u),h=i.substr(f,i.length),v=(g+e.value).length+1;t.find(P,function(t){return t.id==e.id})||P.push(e),d(),j="",T();var x=g;o.keepTriggerCharacter&&(x+=o.triggerChar),x+=e.value+" "+h,L.val(x),L.trigger("mention"),c(),L.focus(),a.setCaratPosition(L[0],v)}function m(){return e.trim(L.val())}function g(t){var n,i,a,o,r,l,s,c,d,p,u;if((d=t[0])&&e(d).is("textarea")&&null!=d.selectionEnd){for(s={position:"absolute",overflow:"auto",whiteSpace:"pre-wrap",wordWrap:"break-word",boxSizing:"content-box",top:0,left:-9999},c=["boxSizing","fontFamily","fontSize","fontStyle","fontVariant","fontWeight","height","letterSpacing","lineHeight","paddingBottom","paddingLeft","paddingRight","paddingTop","textDecoration","textIndent","textTransform","width","word-spacing"],p=0,u=c.length;u>p;p++)r=c[p],s[r]=e(d).css(r);return a=document.createElement("div"),e(a).css(s),e(d).after(a),i=document.createTextNode(d.value.substring(0,d.selectionEnd)),n=document.createTextNode(d.value.substring(d.selectionEnd)),o=document.createElement("span"),o.innerHTML="&nbsp;",a.appendChild(i),a.appendChild(o),a.appendChild(n),a.scrollTop=d.scrollTop,l=e(o).position(),e(a).remove(),l}}function h(t){var n,i,a,o,r,l,s,c,d,p,u;if((d=t[0])&&e(d).is("textarea")&&null!=d.selectionEnd){for(s={position:"absolute",overflow:"auto",whiteSpace:"pre-wrap",wordWrap:"break-word",boxSizing:"content-box",top:0,left:-9999},c=["boxSizing","fontFamily","fontSize","fontStyle","fontVariant","fontWeight","height","letterSpacing","lineHeight","paddingBottom","paddingLeft","paddingRight","paddingTop","textDecoration","textIndent","textTransform","width","word-spacing"],p=0,u=c.length;u>p;p++)r=c[p],s[r]=e(d).css(r);return a=document.createElement("div"),e(a).css(s),e(d).after(a),i=document.createTextNode(d.value.substring(0,d.selectionEnd)),n=document.createTextNode(d.value.substring(d.selectionEnd)),o=document.createElement("span"),o.innerHTML="&nbsp;",a.appendChild(i),a.appendChild(o),a.appendChild(n),a.scrollTop=d.scrollTop,l=e(o).offset(),e(a).remove(),l}}function v(){var t=e(L).offset().top,n=e("body").offset().top,i=e(window).scrollTop();i>t&&e(window).scrollTop(t-n)}function x(){var t=e(this),n=F[t.attr("data-uid")];return f(n),v(),!1}function w(){d()}function C(){T()}function y(){c(),u();var e=t.lastIndexOf(W,o.triggerChar);e>-1&&(j=W.slice(e+1).join(""),j=a.rtrim(j),t.defer(t.bind(A,this,j)))}function E(e){if(e.keyCode!==n.BACKSPACE){var t=String.fromCharCode(e.which||e.keyCode);W.push(t)}}function b(i){if(i.keyCode===n.LEFT||i.keyCode===n.RIGHT||i.keyCode===n.HOME||i.keyCode===n.END)return t.defer(d),void(navigator.userAgent.indexOf("MSIE 9")>-1&&t.defer(c));if(i.keyCode===n.BACKSPACE)return void(W=W.slice(0,-1+W.length));if(!O.is(":visible"))return!0;switch(i.keyCode){case n.UP:case n.DOWN:var a=null;return a=i.keyCode===n.DOWN?B&&B.length?B.next():O.find("li").first():e(B).prev(),a.length&&I(a),!1;case n.RETURN:case n.TAB:if(B&&B.length)return B.trigger("mousedown"),!1}return!0}function T(){B=null,O.empty().hide()}function I(e){e.addClass(o.classes.autoCompleteItemActive),e.siblings().removeClass(o.classes.autoCompleteItemActive),B=e}function S(n,i){if(O.show(),!o.allowRepeat){var r=t.pluck(P,"value");i=t.reject(i,function(e){return t.include(r,e.name)})}if(!i.length)return void T();O.empty();var l=e("<ul>").appendTo(O).hide();t.each(i,function(i,r){var s=t.uniqueId("mention_");F[s]=t.extend({},i,{value:i.name});var c=e(o.templates.autocompleteListItem({id:a.htmlEncode(i.id),display:a.htmlEncode(i.name),type:a.htmlEncode(i.type),fullName:a.htmlEncode(i.fullName),content:a.highlightTerm(a.htmlEncode(i.display?i.display:i.name),n)})).attr("data-uid",s);if(0===r&&I(c),o.showAvatars){var d;d=e(i.avatar?o.templates.autocompleteListItemAvatar({avatar:i.avatar}):o.templates.autocompleteListItemIcon({icon:i.icon})),d.prependTo(c)}c=c.appendTo(l)}),O.show(),o.onCaret&&R(O,L),l.show()}function A(e){e&&e.length&&e.length>=o.minChars?o.onDataRequest.call(this,"search",e,function(t){S(e,t)}):T()}function R(e,t){var n=e.css("position");if("absolute"==n){var i=g(t),a=parseInt(t.css("line-height"),10)||18;e.css("width","15em"),e.css("left",i.left),e.css("top",a+i.top);var o=t.offset().left+t.width(),r=e.offset().left+e.width();r>=o&&e.css("left",Math.abs(e.position().left-(r-o)))}else if("fixed"==n){var l=h(t),a=parseInt(t.css("line-height"),10)||18;e.css("width","15em"),e.css("left",l.left+1e4),e.css("top",a+l.top)}}function k(e){P=[];for(var t,n=a.htmlEncode(e),i=new RegExp("("+o.triggerChar+")\\[(.*?)\\]\\((.*?):(.*?)\\)","gi"),r=n;null!=(t=i.exec(n));)r=r.replace(t[0],t[1]+t[2]),P.push({id:t[4],type:t[3],value:t[2],trigger:t[1]});L.val(r),c()}var M,L,N,O,H,D,B,P=[],F={},W=[],j="";return o=e.extend(!0,{},i,o),window.setInputBuffer=p,{init:function(e){M=e,r(),l(),s(),k(o.defaultValue),o.prefillMention&&f(o.prefillMention)},val:function(e){t.isFunction(e)&&e.call(this,P.length?L.data("messageText"):m())},reset:function(){k()},reinit:function(){k(!1)},getMentions:function(e){t.isFunction(e)&&e.call(this,P)}}};e.fn.mentionsInput=function(n,i){var a=arguments;return"object"!=typeof n&&n||(i=n),this.each(function(){var r=e.data(this,"mentionsInput")||e.data(this,"mentionsInput",new o(i));return t.isFunction(r[n])?r[n].apply(this,Array.prototype.slice.call(a,1)):"object"!=typeof n&&n?void e.error("Method "+n+" does not exist"):r.init.call(this,this)})}}(jQuery,_.runInContext());
2 2 \ No newline at end of file
... ...