text: /*
   almond 0.3.3 Copyright jQuery Foundation and other contributors.
   Released under MIT license, http://github.com/requirejs/almond/LICENSE
   Select2 4.0.13
   https://select2.github.io
  
   Released under the MIT license
   https://github.com/select2/select2/blob/master/LICENSE.md
  */
  (function(t){"function"===typeof define&&define.amd?define(["jquery"],t):"object"===typeof module&&module.exports?module.exports=function(x,v){void 0===v&&(v="undefined"!==typeof window?require("jquery"):require("jquery")(x));t(v);return v}:t(jQuery)})(function(t){var x=function(){if(t&&t.fn&&t.fn.select2&&t.fn.select2.amd)var h=t.fn.select2.amd;(function(){if(!h||!h.requirejs){h?f=h:h={};var e,f,d;(function(c){function b(a,b){var c,g;b=b&&b.split("/");var d=u.map,n=d&&d["*"]||{};if(a){a=a.split("/");
  var m=a.length-1;u.nodeIdCompat&&x.test(a[m])&&(a[m]=a[m].replace(x,""));"."===a[0].charAt(0)&&b&&(m=b.slice(0,b.length-1),a=m.concat(a));for(m=0;m<a.length;m++){var e=a[m];"."===e?(a.splice(m,1),--m):".."===e&&0!==m&&(1!==m||".."!==a[2])&&".."!==a[m-1]&&0<m&&(a.splice(m-1,2),m-=2)}a=a.join("/")}if((b||n)&&d){e=a.split("/");for(m=e.length;0<m;--m){var f=e.slice(0,m).join("/");if(b)for(g=b.length;0<g;--g)if(c=d[b.slice(0,g).join("/")])if(c=c[f]){var q=c;var B=m;break}if(q)break;if(!p&&n&&n[f]){var p=
  n[f];var h=m}}!q&&p&&(q=p,B=h);q&&(e.splice(0,B,q),a=e.join("/"))}return a}function a(a,b){return function(){var g=v.call(arguments,0);"string"!==typeof g[0]&&1===g.length&&g.push(null);return l.apply(c,g.concat([a,b]))}}function g(a){return function(g){return b(g,a)}}function n(a){return function(b){h[a]=b}}function m(a){if(w.call(z,a)){var b=z[a];delete z[a];t[a]=!0;A.apply(c,b)}if(!w.call(h,a)&&!w.call(t,a))throw Error("No "+a);return h[a]}function q(a){var b=a?a.indexOf("!"):-1;if(-1<b){var g=
  a.substring(0,b);a=a.substring(b+1,a.length)}return[g,a]}function p(a){return function(){return u&&u.config&&u.config[a]||{}}}var l,h={},z={},u={},t={},w=Object.prototype.hasOwnProperty,v=[].slice,x=/\.js$/;var D=function(a,c){a=q(a);var d=a[0];c=c[1];a=a[1];if(d){d=b(d,c);var n=m(d)}d?a=n&&n.normalize?n.normalize(a,g(c)):b(a,c):(a=b(a,c),a=q(a),d=a[0],a=a[1],d&&(n=m(d)));return{f:d?d+"!"+a:a,n:a,pr:d,p:n}};var y={require:function(b){return a(b)},exports:function(a){var b=h[a];return"undefined"!==
  typeof b?b:h[a]={}},module:function(a){return{id:a,uri:"",exports:h[a],config:p(a)}}};var A=function(b,g,d,e){var f,p=[];var l=typeof d;var r=(e=e||b)?q(e):[];if("undefined"===l||"function"===l){g=!g.length&&d.length?["require","exports","module"]:g;for(f=0;f<g.length;f+=1){var k=D(g[f],r);l=k.f;if("require"===l)p[f]=y.require(b);else if("exports"===l){p[f]=y.exports(b);var K=!0}else if("module"===l)var C=p[f]=y.module(b);else if(w.call(h,l)||w.call(z,l)||w.call(t,l))p[f]=m(l);else if(k.p)k.p.load(k.n,
  a(e,!0),n(l),{}),p[f]=h[l];else throw Error(b+" missing "+l);}g=d?d.apply(h[b],p):void 0;b&&(C&&C.exports!==c&&C.exports!==h[b]?h[b]=C.exports:g===c&&K||(h[b]=g))}else b&&(h[b]=d)};e=f=l=function(a,b,g,d,n){if("string"===typeof a)return y[a]?y[a](b):m(D(a,b?q(b):[]).f);if(!a.splice){u=a;u.deps&&l(u.deps,u.callback);if(!b)return;b.splice?(a=b,b=g,g=null):a=c}b=b||function(){};"function"===typeof g&&(g=d,d=n);d?A(c,a,b,g):setTimeout(function(){A(c,a,b,g)},4);return l};l.config=function(a){return l(a)};
  e._defined=h;d=function(a,b,g){if("string"!==typeof a)throw Error("See almond README: incorrect module build, no module name");b.splice||(g=b,b=[]);w.call(h,a)||w.call(z,a)||(z[a]=[a,b,g])};d.amd={jQuery:!0}})();h.requirejs=e;h.require=f;h.define=d}})();h.define("almond",function(){});h.define("jquery",[],function(){var e=t||$;null==e&&console&&console.error&&console.error("Select2: An instance of jQuery or a jQuery-compatible library was not found. Make sure that you are including jQuery before Select2 on your web page.");
  return e});h.define("select2/utils",["jquery"],function(e){function f(a){a=a.prototype;var b=[],c;for(c in a)"function"===typeof a[c]&&"constructor"!==c&&b.push(c);return b}var d={Extend:function(a,b){function g(){this.constructor=a}var c={}.hasOwnProperty,d;for(d in b)c.call(b,d)&&(a[d]=b[d]);g.prototype=b.prototype;a.prototype=new g;a.__super__=b.prototype;return a},Decorate:function(a,b){function c(){var c=Array.prototype.unshift,g=a.prototype.constructor;0<b.prototype.constructor.length&&(c.call(arguments,
  a.prototype.constructor),g=b.prototype.constructor);g.apply(this,arguments)}var g=f(b),d=f(a);b.displayName=a.displayName;c.prototype=new function(){this.constructor=c};for(var e=0;e<d.length;e++){var l=d[e];c.prototype[l]=a.prototype[l]}d=function(a){var g=function(){};a in c.prototype&&(g=c.prototype[a]);var d=b.prototype[a];return function(){Array.prototype.unshift.call(arguments,g);return d.apply(this,arguments)}};for(e=0;e<g.length;e++)l=g[e],c.prototype[l]=d(l);return c}},c=function(){this.listeners=
  {}};c.prototype.on=function(a,b){this.listeners=this.listeners||{};a in this.listeners?this.listeners[a].push(b):this.listeners[a]=[b]};c.prototype.trigger=function(a){var b=Array.prototype.slice,c=b.call(arguments,1);this.listeners=this.listeners||{};null==c&&(c=[]);0===c.length&&c.push({});c[0]._type=a;a in this.listeners&&this.invoke(this.listeners[a],b.call(arguments,1));"*"in this.listeners&&this.invoke(this.listeners["*"],arguments)};c.prototype.invoke=function(a,b){for(var c=0,g=a.length;c<
  g;c++)a[c].apply(this,b)};d.Observable=c;d.generateChars=function(a){for(var b="",c=0;c<a;c++)b+=Math.floor(36*Math.random()).toString(36);return b};d.bind=function(a,b){return function(){a.apply(b,arguments)}};d._convertData=function(a){for(var b in a){var c=b.split("-"),d=a;if(1!==c.length){for(var e=0;e<c.length;e++){var f=c[e];f=f.substring(0,1).toLowerCase()+f.substring(1);f in d||(d[f]={});e==c.length-1&&(d[f]=a[b]);d=d[f]}delete a[b]}}return a};d.hasScroll=function(a,b){a=e(b);var c=b.style.overflowX,
  g=b.style.overflowY;return c!==g||"hidden"!==g&&"visible"!==g?"scroll"===c||"scroll"===g?!0:a.innerHeight()<b.scrollHeight||a.innerWidth()<b.scrollWidth:!1};d.escapeMarkup=function(a){var b={"\\":"&#92;","&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#47;"};return"string"!==typeof a?a:String(a).replace(/[&<>"'\/\\]/g,function(a){return b[a]})};d.appendMany=function(a,b){if("1.7"===e.fn.jquery.substr(0,3)){var c=e();e.map(b,function(a){c=c.add(a)});b=c}a.append(b)};d.__cache={};var b=
  0;d.GetUniqueElementId=function(a){var c=a.getAttribute("data-select2-id");null==c&&(a.id?(c=a.id,a.setAttribute("data-select2-id",c)):(a.setAttribute("data-select2-id",++b),c=b.toString()));return c};d.StoreData=function(a,b,c){a=d.GetUniqueElementId(a);d.__cache[a]||(d.__cache[a]={});d.__cache[a][b]=c};d.GetData=function(a,b){var c=d.GetUniqueElementId(a);return b?d.__cache[c]&&null!=d.__cache[c][b]?d.__cache[c][b]:e(a).data(b):d.__cache[c]};d.RemoveData=function(a){var b=d.GetUniqueElementId(a);
  null!=d.__cache[b]&&delete d.__cache[b];a.removeAttribute("data-select2-id")};return d});h.define("select2/results",["jquery","./utils"],function(e,f){function d(c,b,a){this.$element=c;this.data=a;this.options=b;d.__super__.constructor.call(this)}f.Extend(d,f.Observable);d.prototype.render=function(){var c=e('<ul class="select2-results__options" role="listbox"></ul>');this.options.get("multiple")&&c.attr("aria-multiselectable","true");return this.$results=c};d.prototype.clear=function(){this.$results.empty()};
  d.prototype.displayMessage=function(c){var b=this.options.get("escapeMarkup");this.clear();this.hideLoading();var a=e('<li role="alert" aria-live="assertive" class="select2-results__option"></li>'),g=this.options.get("translations").get(c.message);a.append(b(g(c.args)));a[0].className+=" select2-results__message";this.$results.append(a)};d.prototype.hideMessages=function(){this.$results.find(".select2-results__message").remove()};d.prototype.append=function(c){this.hideLoading();var b=[];if(null==
  c.results||0===c.results.length)0===this.$results.children().length&&this.trigger("results:message",{message:"noResults"});else{c.results=this.sort(c.results);for(var a=0;a<c.results.length;a++){var g=this.option(c.results[a]);b.push(g)}this.$results.append(b)}};d.prototype.position=function(c,b){b.find(".select2-results").append(c)};d.prototype.sort=function(c){return this.options.get("sorter")(c)};d.prototype.highlightFirstItem=function(){var c=this.$results.find(".select2-results__option[aria-selected]"),
  b=c.filter("[aria-selected=true]");0<b.length?b.first().trigger("mouseenter"):c.first().trigger("mouseenter");this.ensureHighlightVisible()};d.prototype.setClasses=function(){var c=this;this.data.current(function(b){var a=e.map(b,function(a){return a.id.toString()});c.$results.find(".select2-results__option[aria-selected]").each(function(){var b=e(this),c=f.GetData(this,"data"),d=""+c.id;null!=c.element&&c.element.selected||null==c.element&&-1<e.inArray(d,a)?b.attr("aria-selected","true"):b.attr("aria-selected",
  "false")})})};d.prototype.showLoading=function(c){this.hideLoading();c={disabled:!0,loading:!0,text:this.options.get("translations").get("searching")(c)};c=this.option(c);c.className+=" loading-results";this.$results.prepend(c)};d.prototype.hideLoading=function(){this.$results.find(".loading-results").remove()};d.prototype.option=function(c){var b=document.createElement("li");b.className="select2-results__option";var a={role:"option","aria-selected":"false"},g=window.Element.prototype.matches||window.Element.prototype.msMatchesSelector||
  window.Element.prototype.webkitMatchesSelector;if(null!=c.element&&g.call(c.element,":disabled")||null==c.element&&c.disabled)delete a["aria-selected"],a["aria-disabled"]="true";null==c.id&&delete a["aria-selected"];null!=c._resultId&&(b.id=c._resultId);c.title&&(b.title=c.title);c.children&&(a.role="group",a["aria-label"]=c.text,delete a["aria-selected"]);for(var d in a)b.setAttribute(d,a[d]);if(c.children){a=e(b);g=document.createElement("strong");g.className="select2-results__group";e(g);this.template(c,
  g);d=[];for(var m=0;m<c.children.length;m++){var q=this.option(c.children[m]);d.push(q)}m=e("<ul></ul>",{"class":"select2-results__options select2-results__options--nested"});m.append(d);a.append(g);a.append(m)}else this.template(c,b);f.StoreData(b,"data",c);return b};d.prototype.bind=function(c,b){var a=this;this.$results.attr("id",c.id+"-results");c.on("results:all",function(b){a.clear();a.append(b.data);c.isOpen()&&(a.setClasses(),a.highlightFirstItem())});c.on("results:append",function(b){a.append(b.data);
  c.isOpen()&&a.setClasses()});c.on("query",function(b){a.hideMessages();a.showLoading(b)});c.on("select",function(){c.isOpen()&&(a.setClasses(),a.options.get("scrollAfterSelect")&&a.highlightFirstItem())});c.on("unselect",function(){c.isOpen()&&(a.setClasses(),a.options.get("scrollAfterSelect")&&a.highlightFirstItem())});c.on("open",function(){a.$results.attr("aria-expanded","true");a.$results.attr("aria-hidden","false");a.setClasses();a.ensureHighlightVisible()});c.on("close",function(){a.$results.attr("aria-expanded",
  "false");a.$results.attr("aria-hidden","true");a.$results.removeAttr("aria-activedescendant")});c.on("results:toggle",function(){var b=a.getHighlightedResults();0!==b.length&&b.trigger("mouseup")});c.on("results:select",function(){var b=a.getHighlightedResults();if(0!==b.length){var c=f.GetData(b[0],"data");"true"==b.attr("aria-selected")?a.trigger("close",{}):a.trigger("select",{data:c})}});c.on("results:previous",function(){var b=a.getHighlightedResults(),c=a.$results.find("[aria-selected]"),d=
  c.index(b);if(!(0>=d)){--d;0===b.length&&(d=0);c=c.eq(d);c.trigger("mouseenter");b=a.$results.offset().top;c=c.offset().top;var e=a.$results.scrollTop()+(c-b);0===d?a.$results.scrollTop(0):0>c-b&&a.$results.scrollTop(e)}});c.on("results:next",function(){var b=a.getHighlightedResults(),c=a.$results.find("[aria-selected]");b=c.index(b)+1;if(!(b>=c.length)){var d=c.eq(b);d.trigger("mouseenter");c=a.$results.offset().top+a.$results.outerHeight(!1);d=d.offset().top+d.outerHeight(!1);var e=a.$results.scrollTop()+
  d-c;0===b?a.$results.scrollTop(0):d>c&&a.$results.scrollTop(e)}});c.on("results:focus",function(a){a.element.addClass("select2-results__option--highlighted")});c.on("results:message",function(b){a.displayMessage(b)});if(e.fn.mousewheel)this.$results.on("mousewheel",function(b){var c=a.$results.scrollTop(),d=a.$results.get(0).scrollHeight-c+b.deltaY;c=0<b.deltaY&&0>=c-b.deltaY;d=0>b.deltaY&&d<=a.$results.height();c?(a.$results.scrollTop(0),b.preventDefault(),b.stopPropagation()):d&&(a.$results.scrollTop(a.$results.get(0).scrollHeight-
  a.$results.height()),b.preventDefault(),b.stopPropagation())});this.$results.on("mouseup",".select2-results__option[aria-selected]",function(b){var c=e(this),d=f.GetData(this,"data");"true"===c.attr("aria-selected")?a.options.get("multiple")?a.trigger("unselect",{originalEvent:b,data:d}):a.trigger("close",{}):a.trigger("select",{originalEvent:b,data:d})});this.$results.on("mouseenter",".select2-results__option[aria-selected]",function(b){b=f.GetData(this,"data");a.getHighlightedResults().removeClass("select2-results__option--highlighted");
  a.trigger("results:focus",{data:b,element:e(this)})})};d.prototype.getHighlightedResults=function(){return this.$results.find(".select2-results__option--highlighted")};d.prototype.destroy=function(){this.$results.remove()};d.prototype.ensureHighlightVisible=function(){var c=this.getHighlightedResults();if(0!==c.length){var b=this.$results.find("[aria-selected]").index(c),a=this.$results.offset().top,d=c.offset().top,n=this.$results.scrollTop()+(d-a);a=d-a;n-=2*c.outerHeight(!1);2>=b?this.$results.scrollTop(0):
  (a>this.$results.outerHeight()||0>a)&&this.$results.scrollTop(n)}};d.prototype.template=function(c,b){var a=this.options.get("templateResult"),d=this.options.get("escapeMarkup");c=a(c,b);null==c?b.style.display="none":"string"===typeof c?b.innerHTML=d(c):e(b).append(c)};return d});h.define("select2/keys",[],function(){return{BACKSPACE:8,TAB:9,ENTER:13,SHIFT:16,CTRL:17,ALT:18,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46}});h.define("select2/selection/base",
  ["jquery","../utils","../keys"],function(e,f,d){function c(b,a){this.$element=b;this.options=a;c.__super__.constructor.call(this)}f.Extend(c,f.Observable);c.prototype.render=function(){var b=e('<span class="select2-selection" role="combobox"  aria-haspopup="true" aria-expanded="false"></span>');this._tabindex=0;null!=f.GetData(this.$element[0],"old-tabindex")?this._tabindex=f.GetData(this.$element[0],"old-tabindex"):null!=this.$element.attr("tabindex")&&(this._tabindex=this.$element.attr("tabindex"));
  b.attr("title",this.$element.attr("title"));b.attr("tabindex",this._tabindex);b.attr("aria-disabled","false");return this.$selection=b};c.prototype.bind=function(b,a){var c=this,n=b.id+"-results";this.container=b;this.$selection.on("focus",function(a){c.trigger("focus",a)});this.$selection.on("blur",function(a){c._handleBlur(a)});this.$selection.on("keydown",function(a){c.trigger("keypress",a);a.which===d.SPACE&&a.preventDefault()});b.on("results:focus",function(a){c.$selection.attr("aria-activedescendant",
  a.data._resultId)});b.on("selection:update",function(a){c.update(a.data)});b.on("open",function(){c.$selection.attr("aria-expanded","true");c.$selection.attr("aria-owns",n);c._attachCloseHandler(b)});b.on("close",function(){c.$selection.attr("aria-expanded","false");c.$selection.removeAttr("aria-activedescendant");c.$selection.removeAttr("aria-owns");c.$selection.trigger("focus");c._detachCloseHandler(b)});b.on("enable",function(){c.$selection.attr("tabindex",c._tabindex);c.$selection.attr("aria-disabled",
  "false")});b.on("disable",function(){c.$selection.attr("tabindex","-1");c.$selection.attr("aria-disabled","true")})};c.prototype._handleBlur=function(b){var a=this;window.setTimeout(function(){document.activeElement==a.$selection[0]||e.contains(a.$selection[0],document.activeElement)||a.trigger("blur",b)},1)};c.prototype._attachCloseHandler=function(b){e(document.body).on("mousedown.select2."+b.id,function(a){var b=e(a.target).closest(".select2");e(".select2.select2-container--open").each(function(){this!=
  b[0]&&f.GetData(this,"element").select2("close")})})};c.prototype._detachCloseHandler=function(b){e(document.body).off("mousedown.select2."+b.id)};c.prototype.position=function(b,a){a.find(".selection").append(b)};c.prototype.destroy=function(){this._detachCloseHandler(this.container)};c.prototype.update=function(b){throw Error("The `update` method must be defined in child classes.");};c.prototype.isEnabled=function(){return!this.isDisabled()};c.prototype.isDisabled=function(){return this.options.get("disabled")};
  return c});h.define("select2/selection/single",["jquery","./base","../utils","../keys"],function(e,f,d,c){function b(){b.__super__.constructor.apply(this,arguments)}d.Extend(b,f);b.prototype.render=function(){var a=b.__super__.render.call(this);a.addClass("select2-selection--single");a.html('<span class="select2-selection__rendered"></span><span class="select2-selection__arrow" role="presentation"><b role="presentation"></b></span>');return a};b.prototype.bind=function(a,c){var d=this;b.__super__.bind.apply(this,
  arguments);var g=a.id+"-container";this.$selection.find(".select2-selection__rendered").attr("id",g).attr("role","textbox").attr("aria-readonly","true");this.$selection.attr("aria-labelledby",g);this.$selection.on("mousedown",function(a){1===a.which&&d.trigger("toggle",{originalEvent:a})});this.$selection.on("focus",function(a){});this.$selection.on("blur",function(a){});a.on("focus",function(b){a.isOpen()||d.$selection.trigger("focus")})};b.prototype.clear=function(){var a=this.$selection.find(".select2-selection__rendered");
  a.empty();a.removeAttr("title")};b.prototype.display=function(a,b){var c=this.options.get("templateSelection");return this.options.get("escapeMarkup")(c(a,b))};b.prototype.selectionContainer=function(){return e("<span></span>")};b.prototype.update=function(a){if(0===a.length)this.clear();else{var b=a[0];a=this.$selection.find(".select2-selection__rendered");var c=this.display(b,a);a.empty().append(c);(b=b.title||b.text)?a.attr("title",b):a.removeAttr("title")}};return b});h.define("select2/selection/multiple",
  ["jquery","./base","../utils"],function(e,f,d){function c(b,a){c.__super__.constructor.apply(this,arguments)}d.Extend(c,f);c.prototype.render=function(){var b=c.__super__.render.call(this);b.addClass("select2-selection--multiple");b.html('<ul class="select2-selection__rendered"></ul>');return b};c.prototype.bind=function(b,a){var g=this;c.__super__.bind.apply(this,arguments);this.$selection.on("click",function(a){g.trigger("toggle",{originalEvent:a})});this.$selection.on("click",".select2-selection__choice__remove",
  function(a){if(!g.isDisabled()){var b=e(this).parent();b=d.GetData(b[0],"data");g.trigger("unselect",{originalEvent:a,data:b})}})};c.prototype.clear=function(){var b=this.$selection.find(".select2-selection__rendered");b.empty();b.removeAttr("title")};c.prototype.display=function(b,a){var c=this.options.get("templateSelection");return this.options.get("escapeMarkup")(c(b,a))};c.prototype.selectionContainer=function(){return e('<li class="select2-selection__choice"><span class="select2-selection__choice__remove" role="presentation">&times;</span></li>')};
  c.prototype.update=function(b){this.clear();if(0!==b.length){for(var a=[],c=0;c<b.length;c++){var n=b[c],e=this.selectionContainer(),f=this.display(n,e);e.append(f);(f=n.title||n.text)&&e.attr("title",f);d.StoreData(e[0],"data",n);a.push(e)}b=this.$selection.find(".select2-selection__rendered");d.appendMany(b,a)}};return c});h.define("select2/selection/placeholder",["../utils"],function(e){function f(d,c,b){this.placeholder=this.normalizePlaceholder(b.get("placeholder"));d.call(this,c,b)}f.prototype.normalizePlaceholder=
  function(d,c){"string"===typeof c&&(c={id:"",text:c});return c};f.prototype.createPlaceholder=function(d,c){d=this.selectionContainer();d.html(this.display(c));d.addClass("select2-selection__placeholder").removeClass("select2-selection__choice");return d};f.prototype.update=function(d,c){var b=1==c.length&&c[0].id!=this.placeholder.id;if(1<c.length||b)return d.call(this,c);this.clear();d=this.createPlaceholder(this.placeholder);this.$selection.find(".select2-selection__rendered").append(d)};return f});
  h.define("select2/selection/allowClear",["jquery","../keys","../utils"],function(e,f,d){function c(){}c.prototype.bind=function(b,a,c){var d=this;b.call(this,a,c);null==this.placeholder&&this.options.get("debug")&&window.console&&console.error&&console.error("Select2: The `allowClear` option should be used in combination with the `placeholder` option.");this.$selection.on("mousedown",".select2-selection__clear",function(a){d._handleClear(a)});a.on("keypress",function(b){d._handleKeyboardClear(b,a)})};
  c.prototype._handleClear=function(b,a){if(!this.isDisabled()&&(b=this.$selection.find(".select2-selection__clear"),0!==b.length)){a.stopPropagation();a=d.GetData(b[0],"data");b=this.$element.val();this.$element.val(this.placeholder.id);var c={data:a};this.trigger("clear",c);if(c.prevented)this.$element.val(b);else{for(var e=0;e<a.length;e++)if(c={data:a[e]},this.trigger("unselect",c),c.prevented){this.$element.val(b);return}this.$element.trigger("input").trigger("change");this.trigger("toggle",{})}}};
  c.prototype._handleKeyboardClear=function(b,a,c){c.isOpen()||a.which!=f.DELETE&&a.which!=f.BACKSPACE||this._handleClear(a)};c.prototype.update=function(b,a){b.call(this,a);0<this.$selection.find(".select2-selection__placeholder").length||0===a.length||(b=this.options.get("translations").get("removeAllItems"),b=e('<span class="select2-selection__clear" title="'+b()+'">&times;</span>'),d.StoreData(b[0],"data",a),this.$selection.find(".select2-selection__rendered").prepend(b))};return c});h.define("select2/selection/search",
  ["jquery","../utils","../keys"],function(e,f,d){function c(b,a,c){b.call(this,a,c)}c.prototype.render=function(b){var a=e('<li class="select2-search select2-search--inline"><input class="select2-search__field" type="search" tabindex="-1" autocomplete="off" autocorrect="off" autocapitalize="none" spellcheck="false" role="searchbox" aria-autocomplete="list" /></li>');this.$searchContainer=a;this.$search=a.find("input");b=b.call(this);this._transferTabIndex();return b};c.prototype.bind=function(b,a,
  c){var g=this,e=a.id+"-results";b.call(this,a,c);a.on("open",function(){g.$search.attr("aria-controls",e);g.$search.trigger("focus")});a.on("close",function(){g.$search.val("");g.$search.removeAttr("aria-controls");g.$search.removeAttr("aria-activedescendant");g.$search.trigger("focus")});a.on("enable",function(){g.$search.prop("disabled",!1);g._transferTabIndex()});a.on("disable",function(){g.$search.prop("disabled",!0)});a.on("focus",function(a){g.$search.trigger("focus")});a.on("results:focus",
  function(a){a.data._resultId?g.$search.attr("aria-activedescendant",a.data._resultId):g.$search.removeAttr("aria-activedescendant")});this.$selection.on("focusin",".select2-search--inline",function(a){g.trigger("focus",a)});this.$selection.on("focusout",".select2-search--inline",function(a){g._handleBlur(a)});this.$selection.on("keydown",".select2-search--inline",function(a){a.stopPropagation();g.trigger("keypress",a);g._keyUpPrevented=a.isDefaultPrevented();if(a.which===d.BACKSPACE&&""===g.$search.val()){var b=
  g.$searchContainer.prev(".select2-selection__choice");0<b.length&&(b=f.GetData(b[0],"data"),g.searchRemoveChoice(b),a.preventDefault())}});this.$selection.on("click",".select2-search--inline",function(a){g.$search.val()&&a.stopPropagation()});var q=(b=document.documentMode)&&11>=b;this.$selection.on("input.searchcheck",".select2-search--inline",function(a){q?g.$selection.off("input.search input.searchcheck"):g.$selection.off("keyup.search")});this.$selection.on("keyup.search input.search",".select2-search--inline",
  function(a){if(q&&"input"===a.type)g.$selection.off("input.search input.searchcheck");else{var b=a.which;b!=d.SHIFT&&b!=d.CTRL&&b!=d.ALT&&b!=d.TAB&&g.handleSearch(a)}})};c.prototype._transferTabIndex=function(b){this.$search.attr("tabindex",this.$selection.attr("tabindex"));this.$selection.attr("tabindex","-1")};c.prototype.createPlaceholder=function(b,a){this.$search.attr("placeholder",a.text)};c.prototype.update=function(b,a){var c=this.$search[0]==document.activeElement;this.$search.attr("placeholder",
  "");b.call(this,a);this.$selection.find(".select2-selection__rendered").append(this.$searchContainer);this.resizeSearch();c&&this.$search.trigger("focus")};c.prototype.handleSearch=function(){this.resizeSearch();if(!this._keyUpPrevented){var b=this.$search.val();this.trigger("query",{term:b})}this._keyUpPrevented=!1};c.prototype.searchRemoveChoice=function(b,a){this.trigger("unselect",{data:a});this.$search.val(a.text);this.handleSearch()};c.prototype.resizeSearch=function(){this.$search.css("width",
  "25px");var b=""!==this.$search.attr("placeholder")?this.$selection.find(".select2-selection__rendered").width():.75*(this.$search.val().length+1)+"em";this.$search.css("width",b)};return c});h.define("select2/selection/eventRelay",["jquery"],function(e){function f(){}f.prototype.bind=function(d,c,b){var a=this,g="open opening close closing select selecting unselect unselecting clear clearing".split(" "),f=["opening","closing","selecting","unselecting","clearing"];d.call(this,c,b);c.on("*",function(b,
  c){if(-1!==e.inArray(b,g)){c=c||{};var d=e.Event("select2:"+b,{params:c});a.$element.trigger(d);-1!==e.inArray(b,f)&&(c.prevented=d.isDefaultPrevented())}})};return f});h.define("select2/translation",["jquery","require"],function(e,f){function d(c){this.dict=c||{}}d.prototype.all=function(){return this.dict};d.prototype.get=function(c){return this.dict[c]};d.prototype.extend=function(c){this.dict=e.extend({},c.all(),this.dict)};d._cache={};d.loadPath=function(c){if(!(c in d._cache)){var b=f(c);d._cache[c]=
  b}return new d(d._cache[c])};return d});h.define("select2/diacritics",[],function(){return{"Ⓐ":"A","Ａ":"A","À":"A","Á":"A","Â":"A","Ầ":"A","Ấ":"A","Ẫ":"A","Ẩ":"A","Ã":"A","Ā":"A","Ă":"A","Ằ":"A","Ắ":"A","Ẵ":"A","Ẳ":"A","Ȧ":"A","Ǡ":"A","Ä":"A","Ǟ":"A","Ả":"A","Å":"A","Ǻ":"A","Ǎ":"A","Ȁ":"A","Ȃ":"A","Ạ":"A","Ậ":"A","Ặ":"A","Ḁ":"A","Ą":"A","Ⱥ":"A","Ɐ":"A","Ꜳ":"AA","Æ":"AE","Ǽ":"AE","Ǣ":"AE","Ꜵ":"AO","Ꜷ":"AU","Ꜹ":"AV","Ꜻ":"AV","Ꜽ":"AY","Ⓑ":"B","Ｂ":"B","Ḃ":"B","Ḅ":"B","Ḇ":"B","Ƀ":"B","Ƃ":"B","Ɓ":"B","Ⓒ":"C",
  "Ｃ":"C","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","Ç":"C","Ḉ":"C","Ƈ":"C","Ȼ":"C","Ꜿ":"C","Ⓓ":"D","Ｄ":"D","Ḋ":"D","Ď":"D","Ḍ":"D","Ḑ":"D","Ḓ":"D","Ḏ":"D","Đ":"D","Ƌ":"D","Ɗ":"D","Ɖ":"D","Ꝺ":"D","Ǳ":"DZ","Ǆ":"DZ","ǲ":"Dz","ǅ":"Dz","Ⓔ":"E","Ｅ":"E","È":"E","É":"E","Ê":"E","Ề":"E","Ế":"E","Ễ":"E","Ể":"E","Ẽ":"E","Ē":"E","Ḕ":"E","Ḗ":"E","Ĕ":"E","Ė":"E","Ë":"E","Ẻ":"E","Ě":"E","Ȅ":"E","Ȇ":"E","Ẹ":"E","Ệ":"E","Ȩ":"E","Ḝ":"E","Ę":"E","Ḙ":"E","Ḛ":"E","Ɛ":"E","Ǝ":"E","Ⓕ":"F","Ｆ":"F","Ḟ":"F","Ƒ":"F","Ꝼ":"F","Ⓖ":"G","Ｇ":"G",
  "Ǵ":"G","Ĝ":"G","Ḡ":"G","Ğ":"G","Ġ":"G","Ǧ":"G","Ģ":"G","Ǥ":"G","Ɠ":"G","Ꞡ":"G","Ᵹ":"G","Ꝿ":"G","Ⓗ":"H","Ｈ":"H","Ĥ":"H","Ḣ":"H","Ḧ":"H","Ȟ":"H","Ḥ":"H","Ḩ":"H","Ḫ":"H","Ħ":"H","Ⱨ":"H","Ⱶ":"H","Ɥ":"H","Ⓘ":"I","Ｉ":"I","Ì":"I","Í":"I","Î":"I","Ĩ":"I","Ī":"I","Ĭ":"I","İ":"I","Ï":"I","Ḯ":"I","Ỉ":"I","Ǐ":"I","Ȉ":"I","Ȋ":"I","Ị":"I","Į":"I","Ḭ":"I","Ɨ":"I","Ⓙ":"J","Ｊ":"J","Ĵ":"J","Ɉ":"J","Ⓚ":"K","Ｋ":"K","Ḱ":"K","Ǩ":"K","Ḳ":"K","Ķ":"K","Ḵ":"K","Ƙ":"K","Ⱪ":"K","Ꝁ":"K","Ꝃ":"K","Ꝅ":"K","Ꞣ":"K","Ⓛ":"L","Ｌ":"L",
  "Ŀ":"L","Ĺ":"L","Ľ":"L","Ḷ":"L","Ḹ":"L","Ļ":"L","Ḽ":"L","Ḻ":"L","Ł":"L","Ƚ":"L","Ɫ":"L","Ⱡ":"L","Ꝉ":"L","Ꝇ":"L","Ꞁ":"L","Ǉ":"LJ","ǈ":"Lj","Ⓜ":"M","Ｍ":"M","Ḿ":"M","Ṁ":"M","Ṃ":"M","Ɱ":"M","Ɯ":"M","Ⓝ":"N","Ｎ":"N","Ǹ":"N","Ń":"N","Ñ":"N","Ṅ":"N","Ň":"N","Ṇ":"N","Ņ":"N","Ṋ":"N","Ṉ":"N","Ƞ":"N","Ɲ":"N","Ꞑ":"N","Ꞥ":"N","Ǌ":"NJ","ǋ":"Nj","Ⓞ":"O","Ｏ":"O","Ò":"O","Ó":"O","Ô":"O","Ồ":"O","Ố":"O","Ỗ":"O","Ổ":"O","Õ":"O","Ṍ":"O","Ȭ":"O","Ṏ":"O","Ō":"O","Ṑ":"O","Ṓ":"O","Ŏ":"O","Ȯ":"O","Ȱ":"O","Ö":"O","Ȫ":"O","Ỏ":"O",
  "Ő":"O","Ǒ":"O","Ȍ":"O","Ȏ":"O","Ơ":"O","Ờ":"O","Ớ":"O","Ỡ":"O","Ở":"O","Ợ":"O","Ọ":"O","Ộ":"O","Ǫ":"O","Ǭ":"O","Ø":"O","Ǿ":"O","Ɔ":"O","Ɵ":"O","Ꝋ":"O","Ꝍ":"O","Œ":"OE","Ƣ":"OI","Ꝏ":"OO","Ȣ":"OU","Ⓟ":"P","Ｐ":"P","Ṕ":"P","Ṗ":"P","Ƥ":"P","Ᵽ":"P","Ꝑ":"P","Ꝓ":"P","Ꝕ":"P","Ⓠ":"Q","Ｑ":"Q","Ꝗ":"Q","Ꝙ":"Q","Ɋ":"Q","Ⓡ":"R","Ｒ":"R","Ŕ":"R","Ṙ":"R","Ř":"R","Ȑ":"R","Ȓ":"R","Ṛ":"R","Ṝ":"R","Ŗ":"R","Ṟ":"R","Ɍ":"R","Ɽ":"R","Ꝛ":"R","Ꞧ":"R","Ꞃ":"R","Ⓢ":"S","Ｓ":"S","ẞ":"S","Ś":"S","Ṥ":"S","Ŝ":"S","Ṡ":"S","Š":"S","Ṧ":"S",
  "Ṣ":"S","Ṩ":"S","Ș":"S","Ş":"S","Ȿ":"S","Ꞩ":"S","Ꞅ":"S","Ⓣ":"T","Ｔ":"T","Ṫ":"T","Ť":"T","Ṭ":"T","Ț":"T","Ţ":"T","Ṱ":"T","Ṯ":"T","Ŧ":"T","Ƭ":"T","Ʈ":"T","Ⱦ":"T","Ꞇ":"T","Ꜩ":"TZ","Ⓤ":"U","Ｕ":"U","Ù":"U","Ú":"U","Û":"U","Ũ":"U","Ṹ":"U","Ū":"U","Ṻ":"U","Ŭ":"U","Ü":"U","Ǜ":"U","Ǘ":"U","Ǖ":"U","Ǚ":"U","Ủ":"U","Ů":"U","Ű":"U","Ǔ":"U","Ȕ":"U","Ȗ":"U","Ư":"U","Ừ":"U","Ứ":"U","Ữ":"U","Ử":"U","Ự":"U","Ụ":"U","Ṳ":"U","Ų":"U","Ṷ":"U","Ṵ":"U","Ʉ":"U","Ⓥ":"V","Ｖ":"V","Ṽ":"V","Ṿ":"V","Ʋ":"V","Ꝟ":"V","Ʌ":"V","Ꝡ":"VY",
  "Ⓦ":"W","Ｗ":"W","Ẁ":"W","Ẃ":"W","Ŵ":"W","Ẇ":"W","Ẅ":"W","Ẉ":"W","Ⱳ":"W","Ⓧ":"X","Ｘ":"X","Ẋ":"X","Ẍ":"X","Ⓨ":"Y","Ｙ":"Y","Ỳ":"Y","Ý":"Y","Ŷ":"Y","Ỹ":"Y","Ȳ":"Y","Ẏ":"Y","Ÿ":"Y","Ỷ":"Y","Ỵ":"Y","Ƴ":"Y","Ɏ":"Y","Ỿ":"Y","Ⓩ":"Z","Ｚ":"Z","Ź":"Z","Ẑ":"Z","Ż":"Z","Ž":"Z","Ẓ":"Z","Ẕ":"Z","Ƶ":"Z","Ȥ":"Z","Ɀ":"Z","Ⱬ":"Z","Ꝣ":"Z","ⓐ":"a","ａ":"a","ẚ":"a","à":"a","á":"a","â":"a","ầ":"a","ấ":"a","ẫ":"a","ẩ":"a","ã":"a","ā":"a","ă":"a","ằ":"a","ắ":"a","ẵ":"a","ẳ":"a","ȧ":"a","ǡ":"a","ä":"a","ǟ":"a","ả":"a","å":"a",
  "ǻ":"a","ǎ":"a","ȁ":"a","ȃ":"a","ạ":"a","ậ":"a","ặ":"a","ḁ":"a","ą":"a","ⱥ":"a","ɐ":"a","ꜳ":"aa","æ":"ae","ǽ":"ae","ǣ":"ae","ꜵ":"ao","ꜷ":"au","ꜹ":"av","ꜻ":"av","ꜽ":"ay","ⓑ":"b","ｂ":"b","ḃ":"b","ḅ":"b","ḇ":"b","ƀ":"b","ƃ":"b","ɓ":"b","ⓒ":"c","ｃ":"c","ć":"c","ĉ":"c","ċ":"c","č":"c","ç":"c","ḉ":"c","ƈ":"c","ȼ":"c","ꜿ":"c","ↄ":"c","ⓓ":"d","ｄ":"d","ḋ":"d","ď":"d","ḍ":"d","ḑ":"d","ḓ":"d","ḏ":"d","đ":"d","ƌ":"d","ɖ":"d","ɗ":"d","ꝺ":"d","ǳ":"dz","ǆ":"dz","ⓔ":"e","ｅ":"e","è":"e","é":"e","ê":"e","ề":"e","ế":"e",
  "ễ":"e","ể":"e","ẽ":"e","ē":"e","ḕ":"e","ḗ":"e","ĕ":"e","ė":"e","ë":"e","ẻ":"e","ě":"e","ȅ":"e","ȇ":"e","ẹ":"e","ệ":"e","ȩ":"e","ḝ":"e","ę":"e","ḙ":"e","ḛ":"e","ɇ":"e","ɛ":"e","ǝ":"e","ⓕ":"f","ｆ":"f","ḟ":"f","ƒ":"f","ꝼ":"f","ⓖ":"g","ｇ":"g","ǵ":"g","ĝ":"g","ḡ":"g","ğ":"g","ġ":"g","ǧ":"g","ģ":"g","ǥ":"g","ɠ":"g","ꞡ":"g","ᵹ":"g","ꝿ":"g","ⓗ":"h","ｈ":"h","ĥ":"h","ḣ":"h","ḧ":"h","ȟ":"h","ḥ":"h","ḩ":"h","ḫ":"h","ẖ":"h","ħ":"h","ⱨ":"h","ⱶ":"h","ɥ":"h","ƕ":"hv","ⓘ":"i","ｉ":"i","ì":"i","í":"i","î":"i","ĩ":"i",
  "ī":"i","ĭ":"i","ï":"i","ḯ":"i","ỉ":"i","ǐ":"i","ȉ":"i","ȋ":"i","ị":"i","į":"i","ḭ":"i","ɨ":"i","ı":"i","ⓙ":"j","ｊ":"j","ĵ":"j","ǰ":"j","ɉ":"j","ⓚ":"k","ｋ":"k","ḱ":"k","ǩ":"k","ḳ":"k","ķ":"k","ḵ":"k","ƙ":"k","ⱪ":"k","ꝁ":"k","ꝃ":"k","ꝅ":"k","ꞣ":"k","ⓛ":"l","ｌ":"l","ŀ":"l","ĺ":"l","ľ":"l","ḷ":"l","ḹ":"l","ļ":"l","ḽ":"l","ḻ":"l","ſ":"l","ł":"l","ƚ":"l","ɫ":"l","ⱡ":"l","ꝉ":"l","ꞁ":"l","ꝇ":"l","ǉ":"lj","ⓜ":"m","ｍ":"m","ḿ":"m","ṁ":"m","ṃ":"m","ɱ":"m","ɯ":"m","ⓝ":"n","ｎ":"n","ǹ":"n","ń":"n","ñ":"n","ṅ":"n",
  "ň":"n","ṇ":"n","ņ":"n","ṋ":"n","ṉ":"n","ƞ":"n","ɲ":"n","ŉ":"n","ꞑ":"n","ꞥ":"n","ǌ":"nj","ⓞ":"o","ｏ":"o","ò":"o","ó":"o","ô":"o","ồ":"o","ố":"o","ỗ":"o","ổ":"o","õ":"o","ṍ":"o","ȭ":"o","ṏ":"o","ō":"o","ṑ":"o","ṓ":"o","ŏ":"o","ȯ":"o","ȱ":"o","ö":"o","ȫ":"o","ỏ":"o","ő":"o","ǒ":"o","ȍ":"o","ȏ":"o","ơ":"o","ờ":"o","ớ":"o","ỡ":"o","ở":"o","ợ":"o","ọ":"o","ộ":"o","ǫ":"o","ǭ":"o","ø":"o","ǿ":"o","ɔ":"o","ꝋ":"o","ꝍ":"o","ɵ":"o","œ":"oe","ƣ":"oi","ȣ":"ou","ꝏ":"oo","ⓟ":"p","ｐ":"p","ṕ":"p","ṗ":"p","ƥ":"p",
  "ᵽ":"p","ꝑ":"p","ꝓ":"p","ꝕ":"p","ⓠ":"q","ｑ":"q","ɋ":"q","ꝗ":"q","ꝙ":"q","ⓡ":"r","ｒ":"r","ŕ":"r","ṙ":"r","ř":"r","ȑ":"r","ȓ":"r","ṛ":"r","ṝ":"r","ŗ":"r","ṟ":"r","ɍ":"r","ɽ":"r","ꝛ":"r","ꞧ":"r","ꞃ":"r","ⓢ":"s","ｓ":"s","ß":"s","ś":"s","ṥ":"s","ŝ":"s","ṡ":"s","š":"s","ṧ":"s","ṣ":"s","ṩ":"s","ș":"s","ş":"s","ȿ":"s","ꞩ":"s","ꞅ":"s","ẛ":"s","ⓣ":"t","ｔ":"t","ṫ":"t","ẗ":"t","ť":"t","ṭ":"t","ț":"t","ţ":"t","ṱ":"t","ṯ":"t","ŧ":"t","ƭ":"t","ʈ":"t","ⱦ":"t","ꞇ":"t","ꜩ":"tz","ⓤ":"u","ｕ":"u","ù":"u","ú":"u","û":"u",
  "ũ":"u","ṹ":"u","ū":"u","ṻ":"u","ŭ":"u","ü":"u","ǜ":"u","ǘ":"u","ǖ":"u","ǚ":"u","ủ":"u","ů":"u","ű":"u","ǔ":"u","ȕ":"u","ȗ":"u","ư":"u","ừ":"u","ứ":"u","ữ":"u","ử":"u","ự":"u","ụ":"u","ṳ":"u","ų":"u","ṷ":"u","ṵ":"u","ʉ":"u","ⓥ":"v","ｖ":"v","ṽ":"v","ṿ":"v","ʋ":"v","ꝟ":"v","ʌ":"v","ꝡ":"vy","ⓦ":"w","ｗ":"w","ẁ":"w","ẃ":"w","ŵ":"w","ẇ":"w","ẅ":"w","ẘ":"w","ẉ":"w","ⱳ":"w","ⓧ":"x","ｘ":"x","ẋ":"x","ẍ":"x","ⓨ":"y","ｙ":"y","ỳ":"y","ý":"y","ŷ":"y","ỹ":"y","ȳ":"y","ẏ":"y","ÿ":"y","ỷ":"y","ẙ":"y","ỵ":"y","ƴ":"y",
  "ɏ":"y","ỿ":"y","ⓩ":"z","ｚ":"z","ź":"z","ẑ":"z","ż":"z","ž":"z","ẓ":"z","ẕ":"z","ƶ":"z","ȥ":"z","ɀ":"z","ⱬ":"z","ꝣ":"z","Ά":"Α","Έ":"Ε","Ή":"Η","Ί":"Ι","Ϊ":"Ι","Ό":"Ο","Ύ":"Υ","Ϋ":"Υ","Ώ":"Ω","ά":"α","έ":"ε","ή":"η","ί":"ι","ϊ":"ι","ΐ":"ι","ό":"ο","ύ":"υ","ϋ":"υ","ΰ":"υ","ώ":"ω","ς":"σ","’":"'"}});h.define("select2/data/base",["../utils"],function(e){function f(d,c){f.__super__.constructor.call(this)}e.Extend(f,e.Observable);f.prototype.current=function(d){throw Error("The `current` method must be defined in child classes.");
  };f.prototype.query=function(d,c){throw Error("The `query` method must be defined in child classes.");};f.prototype.bind=function(d,c){};f.prototype.destroy=function(){};f.prototype.generateResultId=function(d,c){d=d.id+"-result-";d+=e.generateChars(4);return d=null!=c.id?d+("-"+c.id.toString()):d+("-"+e.generateChars(4))};return f});h.define("select2/data/select",["./base","../utils","jquery"],function(e,f,d){function c(b,a){this.$element=b;this.options=a;c.__super__.constructor.call(this)}f.Extend(c,
  e);c.prototype.current=function(b){var a=[],c=this;this.$element.find(":selected").each(function(){var b=d(this);b=c.item(b);a.push(b)});b(a)};c.prototype.select=function(b){var a=this;b.selected=!0;d(b.element).is("option")?(b.element.selected=!0,this.$element.trigger("input").trigger("change")):this.$element.prop("multiple")?this.current(function(c){var g=[];b=[b];b.push.apply(b,c);for(c=0;c<b.length;c++){var e=b[c].id;-1===d.inArray(e,g)&&g.push(e)}a.$element.val(g);a.$element.trigger("input").trigger("change")}):
  (this.$element.val(b.id),this.$element.trigger("input").trigger("change"))};c.prototype.unselect=function(b){var a=this;this.$element.prop("multiple")&&(b.selected=!1,d(b.element).is("option")?(b.element.selected=!1,this.$element.trigger("input").trigger("change")):this.current(function(c){for(var g=[],e=0;e<c.length;e++){var f=c[e].id;f!==b.id&&-1===d.inArray(f,g)&&g.push(f)}a.$element.val(g);a.$element.trigger("input").trigger("change")}))};c.prototype.bind=function(b,a){var c=this;this.container=
  b;b.on("select",function(a){c.select(a.data)});b.on("unselect",function(a){c.unselect(a.data)})};c.prototype.destroy=function(){this.$element.find("*").each(function(){f.RemoveData(this)})};c.prototype.query=function(b,a){var c=[],e=this;this.$element.children().each(function(){var a=d(this);if(a.is("option")||a.is("optgroup"))a=e.item(a),a=e.matches(b,a),null!==a&&c.push(a)});a({results:c})};c.prototype.addOptions=function(b){f.appendMany(this.$element,b)};c.prototype.option=function(b){if(b.children){var a=
  document.createElement("optgroup");a.label=b.text}else a=document.createElement("option"),void 0!==a.textContent?a.textContent=b.text:a.innerText=b.text;void 0!==b.id&&(a.value=b.id);b.disabled&&(a.disabled=!0);b.selected&&(a.selected=!0);b.title&&(a.title=b.title);var c=d(a);b=this._normalizeItem(b);b.element=a;f.StoreData(a,"data",b);return c};c.prototype.item=function(b){var a=f.GetData(b[0],"data");if(null!=a)return a;if(b.is("option"))a={id:b.val(),text:b.text(),disabled:b.prop("disabled"),selected:b.prop("selected"),
  title:b.prop("title")};else if(b.is("optgroup")){a={text:b.prop("label"),children:[],title:b.prop("title")};for(var c=b.children("option"),e=[],m=0;m<c.length;m++){var q=d(c[m]);q=this.item(q);e.push(q)}a.children=e}a=this._normalizeItem(a);a.element=b[0];f.StoreData(b[0],"data",a);return a};c.prototype._normalizeItem=function(b){b!==Object(b)&&(b={id:b,text:b});b=d.extend({},{text:""},b);null!=b.id&&(b.id=b.id.toString());null!=b.text&&(b.text=b.text.toString());null==b._resultId&&b.id&&null!=this.container&&
  (b._resultId=this.generateResultId(this.container,b));return d.extend({},{selected:!1,disabled:!1},b)};c.prototype.matches=function(b,a){return this.options.get("matcher")(b,a)};return c});h.define("select2/data/array",["./select","../utils","jquery"],function(e,f,d){function c(b,a){this._dataToConvert=a.get("data")||[];c.__super__.constructor.call(this,b,a)}f.Extend(c,e);c.prototype.bind=function(b,a){c.__super__.bind.call(this,b,a);this.addOptions(this.convertToOptions(this._dataToConvert))};c.prototype.select=
  function(b){var a=this.$element.find("option").filter(function(a,c){return c.value==b.id.toString()});0===a.length&&(a=this.option(b),this.addOptions(a));c.__super__.select.call(this,b)};c.prototype.convertToOptions=function(b){function a(a){return function(){return d(this).val()==a.id}}for(var c=this,e=this.$element.find("option"),m=e.map(function(){return c.item(d(this)).id}).get(),q=[],h=0;h<b.length;h++){var l=this._normalizeItem(b[h]);if(0<=d.inArray(l.id,m)){var r=e.filter(a(l)),t=this.item(r);
  l=d.extend(!0,{},l,t);l=this.option(l);r.replaceWith(l)}else r=this.option(l),l.children&&(l=this.convertToOptions(l.children),f.appendMany(r,l)),q.push(r)}return q};return c});h.define("select2/data/ajax",["./array","../utils","jquery"],function(e,f,d){function c(b,a){this.ajaxOptions=this._applyDefaults(a.get("ajax"));null!=this.ajaxOptions.processResults&&(this.processResults=this.ajaxOptions.processResults);c.__super__.constructor.call(this,b,a)}f.Extend(c,e);c.prototype._applyDefaults=function(b){return d.extend({},
  {data:function(a){return d.extend({},a,{q:a.term})},transport:function(a,b,c){a=d.ajax(a);a.then(b);a.fail(c);return a}},b,!0)};c.prototype.processResults=function(b){return b};c.prototype.query=function(b,a){function c(){var c=f.transport(f,function(c){c=e.processResults(c,b);e.options.get("debug")&&window.console&&console.error&&(c&&c.results&&d.isArray(c.results)||console.error("Select2: The AJAX results did not return an array in the `results` key of the response."));a(c)},function(){"status"in
  c&&(0===c.status||"0"===c.status)||e.trigger("results:message",{message:"errorLoading"})});e._request=c}var e=this;null!=this._request&&(d.isFunction(this._request.abort)&&this._request.abort(),this._request=null);var f=d.extend({type:"GET"},this.ajaxOptions);"function"===typeof f.url&&(f.url=f.url.call(this.$element,b));"function"===typeof f.data&&(f.data=f.data.call(this.$element,b));this.ajaxOptions.delay&&null!=b.term?(this._queryTimeout&&window.clearTimeout(this._queryTimeout),this._queryTimeout=
  window.setTimeout(c,this.ajaxOptions.delay)):c()};return c});h.define("select2/data/tags",["jquery"],function(e){function f(d,c,b){var a=b.get("tags"),g=b.get("createTag");void 0!==g&&(this.createTag=g);g=b.get("insertTag");void 0!==g&&(this.insertTag=g);d.call(this,c,b);if(e.isArray(a))for(d=0;d<a.length;d++)c=this._normalizeItem(a[d]),c=this.option(c),this.$element.append(c)}f.prototype.query=function(d,c,b){function a(d,e){for(var f=d.results,n=0;n<f.length;n++){var m=f[n],h=null!=m.children&&
  !a({results:m.children},!0);m=(m.text||"").toUpperCase();var t=(c.term||"").toUpperCase();if(m===t||h){if(e)return!1;d.data=f;b(d);return}}if(e)return!0;e=g.createTag(c);null!=e&&(n=g.option(e),n.attr("data-select2-tag",!0),g.addOptions([n]),g.insertTag(f,e));d.results=f;b(d)}var g=this;this._removeOldTags();null==c.term||null!=c.page?d.call(this,c,b):d.call(this,c,a)};f.prototype.createTag=function(d,c){d=e.trim(c.term);return""===d?null:{id:d,text:d}};f.prototype.insertTag=function(d,c,b){c.unshift(b)};
  f.prototype._removeOldTags=function(d){this.$element.find("option[data-select2-tag]").each(function(){this.selected||e(this).remove()})};return f});h.define("select2/data/tokenizer",["jquery"],function(e){function f(d,c,b){var a=b.get("tokenizer");void 0!==a&&(this.tokenizer=a);d.call(this,c,b)}f.prototype.bind=function(d,c,b){d.call(this,c,b);this.$search=c.dropdown.$search||c.selection.$search||b.find(".select2-search__field")};f.prototype.query=function(d,c,b){var a=this;c.term=c.term||"";var g=
  this.tokenizer(c,this.options,function(b){var c=a._normalizeItem(b);a.$element.find("option").filter(function(){return e(this).val()===c.id}).length||(b=a.option(c),b.attr("data-select2-tag",!0),a._removeOldTags(),a.addOptions([b]));a.trigger("select",{data:c})});g.term!==c.term&&(this.$search.length&&(this.$search.val(g.term),this.$search.trigger("focus")),c.term=g.term);d.call(this,c,b)};f.prototype.tokenizer=function(d,c,b,a){d=b.get("tokenSeparators")||[];b=c.term;for(var g=0,f=this.createTag||
  function(a){return{id:a.term,text:a.term}};g<b.length;)if(-1===e.inArray(b[g],d))g++;else{var m=b.substr(0,g);m=e.extend({},c,{term:m});m=f(m);null==m?g++:(a(m),b=b.substr(g+1)||"",g=0)}return{term:b}};return f});h.define("select2/data/minimumInputLength",[],function(){function e(e,d,c){this.minimumInputLength=c.get("minimumInputLength");e.call(this,d,c)}e.prototype.query=function(e,d,c){d.term=d.term||"";d.term.length<this.minimumInputLength?this.trigger("results:message",{message:"inputTooShort",
  args:{minimum:this.minimumInputLength,input:d.term,params:d}}):e.call(this,d,c)};return e});h.define("select2/data/maximumInputLength",[],function(){function e(e,d,c){this.maximumInputLength=c.get("maximumInputLength");e.call(this,d,c)}e.prototype.query=function(e,d,c){d.term=d.term||"";0<this.maximumInputLength&&d.term.length>this.maximumInputLength?this.trigger("results:message",{message:"inputTooLong",args:{maximum:this.maximumInputLength,input:d.term,params:d}}):e.call(this,d,c)};return e});h.define("select2/data/maximumSelectionLength",
  [],function(){function e(e,d,c){this.maximumSelectionLength=c.get("maximumSelectionLength");e.call(this,d,c)}e.prototype.bind=function(e,d,c){var b=this;e.call(this,d,c);d.on("select",function(){b._checkIfMaximumSelected()})};e.prototype.query=function(e,d,c){var b=this;this._checkIfMaximumSelected(function(){e.call(b,d,c)})};e.prototype._checkIfMaximumSelected=function(e,d){var c=this;this.current(function(b){b=null!=b?b.length:0;0<c.maximumSelectionLength&&b>=c.maximumSelectionLength?c.trigger("results:message",
  {message:"maximumSelected",args:{maximum:c.maximumSelectionLength}}):d&&d()})};return e});h.define("select2/dropdown",["jquery","./utils"],function(e,f){function d(c,b){this.$element=c;this.options=b;d.__super__.constructor.call(this)}f.Extend(d,f.Observable);d.prototype.render=function(){var c=e('<span class="select2-dropdown"><span class="select2-results"></span></span>');c.attr("dir",this.options.get("dir"));return this.$dropdown=c};d.prototype.bind=function(){};d.prototype.position=function(c,
  b){};d.prototype.destroy=function(){this.$dropdown.remove()};return d});h.define("select2/dropdown/search",["jquery","../utils"],function(e,f){function d(){}d.prototype.render=function(c){c=c.call(this);var b=e('<span class="select2-search select2-search--dropdown"><input class="select2-search__field" type="search" tabindex="-1" autocomplete="off" autocorrect="off" autocapitalize="none" spellcheck="false" role="searchbox" aria-autocomplete="list" /></span>');this.$searchContainer=b;this.$search=b.find("input");
  c.prepend(b);return c};d.prototype.bind=function(c,b,a){var d=this,f=b.id+"-results";c.call(this,b,a);this.$search.on("keydown",function(a){d.trigger("keypress",a);d._keyUpPrevented=a.isDefaultPrevented()});this.$search.on("input",function(a){e(this).off("keyup")});this.$search.on("keyup input",function(a){d.handleSearch(a)});b.on("open",function(){d.$search.attr("tabindex",0);d.$search.attr("aria-controls",f);d.$search.trigger("focus");window.setTimeout(function(){d.$search.trigger("focus")},0)});
  b.on("close",function(){d.$search.attr("tabindex",-1);d.$search.removeAttr("aria-controls");d.$search.removeAttr("aria-activedescendant");d.$search.val("");d.$search.trigger("blur")});b.on("focus",function(){b.isOpen()||d.$search.trigger("focus")});b.on("results:all",function(a){if(null==a.query.term||""===a.query.term)d.showSearch(a)?d.$searchContainer.removeClass("select2-search--hide"):d.$searchContainer.addClass("select2-search--hide")});b.on("results:focus",function(a){a.data._resultId?d.$search.attr("aria-activedescendant",
  a.data._resultId):d.$search.removeAttr("aria-activedescendant")})};d.prototype.handleSearch=function(c){this._keyUpPrevented||(c=this.$search.val(),this.trigger("query",{term:c}));this._keyUpPrevented=!1};d.prototype.showSearch=function(c,b){return!0};return d});h.define("select2/dropdown/hidePlaceholder",[],function(){function e(e,d,c,b){this.placeholder=this.normalizePlaceholder(c.get("placeholder"));e.call(this,d,c,b)}e.prototype.append=function(e,d){d.results=this.removePlaceholder(d.results);
  e.call(this,d)};e.prototype.normalizePlaceholder=function(e,d){"string"===typeof d&&(d={id:"",text:d});return d};e.prototype.removePlaceholder=function(e,d){e=d.slice(0);for(var c=d.length-1;0<=c;c--)this.placeholder.id===d[c].id&&e.splice(c,1);return e};return e});h.define("select2/dropdown/infiniteScroll",["jquery"],function(e){function f(d,c,b,a){this.lastParams={};d.call(this,c,b,a);this.$loadingMore=this.createLoadingMore();this.loading=!1}f.prototype.append=function(d,c){this.$loadingMore.remove();
  this.loading=!1;d.call(this,c);this.showLoadingMore(c)&&(this.$results.append(this.$loadingMore),this.loadMoreIfNeeded())};f.prototype.bind=function(d,c,b){var a=this;d.call(this,c,b);c.on("query",function(b){a.lastParams=b;a.loading=!0});c.on("query:append",function(b){a.lastParams=b;a.loading=!0});this.$results.on("scroll",this.loadMoreIfNeeded.bind(this))};f.prototype.loadMoreIfNeeded=function(){var d=e.contains(document.documentElement,this.$loadingMore[0]);if(!this.loading&&d){d=this.$results.offset().top+
  this.$results.outerHeight(!1);var c=this.$loadingMore.offset().top+this.$loadingMore.outerHeight(!1);d+50>=c&&this.loadMore()}};f.prototype.loadMore=function(){this.loading=!0;var d=e.extend({},{page:1},this.lastParams);d.page++;this.trigger("query:append",d)};f.prototype.showLoadingMore=function(d,c){return c.pagination&&c.pagination.more};f.prototype.createLoadingMore=function(){var d=e('<li class="select2-results__option select2-results__option--load-more"role="option" aria-disabled="true"></li>'),
  c=this.options.get("translations").get("loadingMore");d.html(c(this.lastParams));return d};return f});h.define("select2/dropdown/attachBody",["jquery","../utils"],function(e,f){function d(c,b,a){this.$dropdownParent=e(a.get("dropdownParent")||document.body);c.call(this,b,a)}d.prototype.bind=function(c,b,a){var d=this;c.call(this,b,a);b.on("open",function(){d._showDropdown();d._attachPositioningHandler(b);d._bindContainerResultHandlers(b)});b.on("close",function(){d._hideDropdown();d._detachPositioningHandler(b)});
  this.$dropdownContainer.on("mousedown",function(a){a.stopPropagation()})};d.prototype.destroy=function(c){c.call(this);this.$dropdownContainer.remove()};d.prototype.position=function(c,b,a){b.attr("class",a.attr("class"));b.removeClass("select2");b.addClass("select2-container--open");b.css({position:"absolute",top:-999999});this.$container=a};d.prototype.render=function(c){var b=e("<span></span>");c=c.call(this);b.append(c);return this.$dropdownContainer=b};d.prototype._hideDropdown=function(c){this.$dropdownContainer.detach()};
  d.prototype._bindContainerResultHandlers=function(c,b){if(!this._containerResultsHandlersBound){var a=this;b.on("results:all",function(){a._positionDropdown();a._resizeDropdown()});b.on("results:append",function(){a._positionDropdown();a._resizeDropdown()});b.on("results:message",function(){a._positionDropdown();a._resizeDropdown()});b.on("select",function(){a._positionDropdown();a._resizeDropdown()});b.on("unselect",function(){a._positionDropdown();a._resizeDropdown()});this._containerResultsHandlersBound=
  !0}};d.prototype._attachPositioningHandler=function(c,b){var a=this;c="scroll.select2."+b.id;var d="resize.select2."+b.id;b="orientationchange.select2."+b.id;var n=this.$container.parents().filter(f.hasScroll);n.each(function(){f.StoreData(this,"select2-scroll-position",{x:e(this).scrollLeft(),y:e(this).scrollTop()})});n.on(c,function(a){a=f.GetData(this,"select2-scroll-position");e(this).scrollTop(a.y)});e(window).on(c+" "+d+" "+b,function(b){a._positionDropdown();a._resizeDropdown()})};d.prototype._detachPositioningHandler=
  function(c,b){c="scroll.select2."+b.id;var a="resize.select2."+b.id;b="orientationchange.select2."+b.id;this.$container.parents().filter(f.hasScroll).off(c);e(window).off(c+" "+a+" "+b)};d.prototype._positionDropdown=function(){var c=e(window),b=this.$dropdown.hasClass("select2-dropdown--above"),a=this.$dropdown.hasClass("select2-dropdown--below"),d=null,f=this.$container.offset();f.bottom=f.top+this.$container.outerHeight(!1);var m=this.$container.outerHeight(!1);var h=f.top;var p=f.top+m;m=this.$dropdown.outerHeight(!1);
  var l=c.scrollTop(),r=c.scrollTop()+c.height();c=l<f.top-m;l=r>f.bottom+m;f={left:f.left,top:p};p=this.$dropdownParent;"static"===p.css("position")&&(p=p.offsetParent());r={top:0,left:0};if(e.contains(document.body,p[0])||p[0].isConnected)r=p.offset();f.top-=r.top;f.left-=r.left;b||a||(d="below");l||!c||b?!c&&l&&b&&(d="below"):d="above";if("above"==d||b&&"below"!==d)f.top=h-r.top-m;null!=d&&(this.$dropdown.removeClass("select2-dropdown--below select2-dropdown--above").addClass("select2-dropdown--"+
  d),this.$container.removeClass("select2-container--below select2-container--above").addClass("select2-container--"+d));this.$dropdownContainer.css(f)};d.prototype._resizeDropdown=function(){var c={width:this.$container.outerWidth(!1)+"px"};this.options.get("dropdownAutoWidth")&&(c.minWidth=c.width,c.position="relative",c.width="auto");this.$dropdown.css(c)};d.prototype._showDropdown=function(c){this.$dropdownContainer.appendTo(this.$dropdownParent);this._positionDropdown();this._resizeDropdown()};
  return d});h.define("select2/dropdown/minimumResultsForSearch",[],function(){function e(d){for(var c=0,b=0;b<d.length;b++){var a=d[b];a.children?c+=e(a.children):c++}return c}function f(d,c,b,a){this.minimumResultsForSearch=b.get("minimumResultsForSearch");0>this.minimumResultsForSearch&&(this.minimumResultsForSearch=Infinity);d.call(this,c,b,a)}f.prototype.showSearch=function(d,c){return e(c.data.results)<this.minimumResultsForSearch?!1:d.call(this,c)};return f});h.define("select2/dropdown/selectOnClose",
  ["../utils"],function(e){function f(){}f.prototype.bind=function(d,c,b){var a=this;d.call(this,c,b);c.on("close",function(b){a._handleSelectOnClose(b)})};f.prototype._handleSelectOnClose=function(d,c){if(c&&null!=c.originalSelect2Event&&(d=c.originalSelect2Event,"select"===d._type||"unselect"===d._type))return;d=this.getHighlightedResults();1>d.length||(d=e.GetData(d[0],"data"),null!=d.element&&d.element.selected||null==d.element&&d.selected||this.trigger("select",{data:d}))};return f});h.define("select2/dropdown/closeOnSelect",
  [],function(){function e(){}e.prototype.bind=function(e,d,c){var b=this;e.call(this,d,c);d.on("select",function(a){b._selectTriggered(a)});d.on("unselect",function(a){b._selectTriggered(a)})};e.prototype._selectTriggered=function(e,d){(e=d.originalEvent)&&(e.ctrlKey||e.metaKey)||this.trigger("close",{originalEvent:e,originalSelect2Event:d})};return e});h.define("select2/i18n/en",[],function(){return{errorLoading:function(){return"The results could not be loaded."},inputTooLong:function(e){e=e.input.length-
  e.maximum;var f="Please delete "+e+" character";1!=e&&(f+="s");return f},inputTooShort:function(e){return"Please enter "+(e.minimum-e.input.length)+" or more characters"},loadingMore:function(){return"Loading more results…"},maximumSelected:function(e){var f="You can only select "+e.maximum+" item";1!=e.maximum&&(f+="s");return f},noResults:function(){return"No results found"},searching:function(){return"Searching…"},removeAllItems:function(){return"Remove all items"}}});h.define("select2/defaults",
  "jquery require ./results ./selection/single ./selection/multiple ./selection/placeholder ./selection/allowClear ./selection/search ./selection/eventRelay ./utils ./translation ./diacritics ./data/select ./data/array ./data/ajax ./data/tags ./data/tokenizer ./data/minimumInputLength ./data/maximumInputLength ./data/maximumSelectionLength ./dropdown ./dropdown/search ./dropdown/hidePlaceholder ./dropdown/infiniteScroll ./dropdown/attachBody ./dropdown/minimumResultsForSearch ./dropdown/selectOnClose ./dropdown/closeOnSelect ./i18n/en".split(" "),
  function(e,f,d,c,b,a,g,n,m,h,p,l,r,t,u,v,w,x,J,D,y,A,B,E,F,G,H,I,L){function q(){this.reset()}q.prototype.apply=function(k){k=e.extend(!0,{},this.defaults,k);if(null==k.dataAdapter){k.dataAdapter=null!=k.ajax?u:null!=k.data?t:r;0<k.minimumInputLength&&(k.dataAdapter=h.Decorate(k.dataAdapter,x));0<k.maximumInputLength&&(k.dataAdapter=h.Decorate(k.dataAdapter,J));0<k.maximumSelectionLength&&(k.dataAdapter=h.Decorate(k.dataAdapter,D));k.tags&&(k.dataAdapter=h.Decorate(k.dataAdapter,v));if(null!=k.tokenSeparators||
  null!=k.tokenizer)k.dataAdapter=h.Decorate(k.dataAdapter,w);if(null!=k.query){var l=f(k.amdBase+"compat/query");k.dataAdapter=h.Decorate(k.dataAdapter,l)}null!=k.initSelection&&(l=f(k.amdBase+"compat/initSelection"),k.dataAdapter=h.Decorate(k.dataAdapter,l))}null==k.resultsAdapter&&(k.resultsAdapter=d,null!=k.ajax&&(k.resultsAdapter=h.Decorate(k.resultsAdapter,E)),null!=k.placeholder&&(k.resultsAdapter=h.Decorate(k.resultsAdapter,B)),k.selectOnClose&&(k.resultsAdapter=h.Decorate(k.resultsAdapter,
  H)));if(null==k.dropdownAdapter){k.multiple?k.dropdownAdapter=y:(l=h.Decorate(y,A),k.dropdownAdapter=l);0!==k.minimumResultsForSearch&&(k.dropdownAdapter=h.Decorate(k.dropdownAdapter,G));k.closeOnSelect&&(k.dropdownAdapter=h.Decorate(k.dropdownAdapter,I));if(null!=k.dropdownCssClass||null!=k.dropdownCss||null!=k.adaptDropdownCssClass)l=f(k.amdBase+"compat/dropdownCss"),k.dropdownAdapter=h.Decorate(k.dropdownAdapter,l);k.dropdownAdapter=h.Decorate(k.dropdownAdapter,F)}if(null==k.selectionAdapter){k.selectionAdapter=
  k.multiple?b:c;null!=k.placeholder&&(k.selectionAdapter=h.Decorate(k.selectionAdapter,a));k.allowClear&&(k.selectionAdapter=h.Decorate(k.selectionAdapter,g));k.multiple&&(k.selectionAdapter=h.Decorate(k.selectionAdapter,n));if(null!=k.containerCssClass||null!=k.containerCss||null!=k.adaptContainerCssClass)l=f(k.amdBase+"compat/containerCss"),k.selectionAdapter=h.Decorate(k.selectionAdapter,l);k.selectionAdapter=h.Decorate(k.selectionAdapter,m)}k.language=this._resolveLanguage(k.language);k.language.push("en");
  l=[];for(var q=0;q<k.language.length;q++){var p=k.language[q];-1===l.indexOf(p)&&l.push(p)}k.language=l;k.translations=this._processTranslations(k.language,k.debug);return k};q.prototype.reset=function(){function a(a){return a.replace(/[^\u0000-\u007E]/g,function(a){return l[a]||a})}function b(c,d){if(""===e.trim(c.term))return d;if(d.children&&0<d.children.length){for(var g=e.extend(!0,{},d),f=d.children.length-1;0<=f;f--)null==b(c,d.children[f])&&g.children.splice(f,1);return 0<g.children.length?
  g:b(c,g)}g=a(d.text).toUpperCase();c=a(c.term).toUpperCase();return-1<g.indexOf(c)?d:null}this.defaults={amdBase:"./",amdLanguageBase:"./i18n/",closeOnSelect:!0,debug:!1,dropdownAutoWidth:!1,escapeMarkup:h.escapeMarkup,language:{},matcher:b,minimumInputLength:0,maximumInputLength:0,maximumSelectionLength:0,minimumResultsForSearch:0,selectOnClose:!1,scrollAfterSelect:!1,sorter:function(a){return a},templateResult:function(a){return a.text},templateSelection:function(a){return a.text},theme:"default",
  width:"resolve"}};q.prototype.applyFromElement=function(a,b){var c=a.language,d=this.defaults.language,e=b.prop("lang");b=b.closest("[lang]").prop("lang");c=Array.prototype.concat.call(this._resolveLanguage(e),this._resolveLanguage(c),this._resolveLanguage(d),this._resolveLanguage(b));a.language=c;return a};q.prototype._resolveLanguage=function(a){if(!a||e.isEmptyObject(a))return[];if(e.isPlainObject(a))return[a];a=e.isArray(a)?a:[a];for(var b=[],c=0;c<a.length;c++)if(b.push(a[c]),"string"===typeof a[c]&&
  0<a[c].indexOf("-")){var d=a[c].split("-")[0];b.push(d)}return b};q.prototype._processTranslations=function(a,b){for(var c=new p,d=0;d<a.length;d++){var g=new p,f=a[d];if("string"===typeof f)try{g=p.loadPath(f)}catch(M){try{f=this.defaults.amdLanguageBase+f,g=p.loadPath(f)}catch(N){b&&window.console&&console.warn&&console.warn('Select2: The language file for "'+f+'" could not be automatically loaded. A fallback will be used instead.')}}else g=e.isPlainObject(f)?new p(f):f;c.extend(g)}return c};q.prototype.set=
  function(a,b){a=e.camelCase(a);var c={};c[a]=b;b=h._convertData(c);e.extend(!0,this.defaults,b)};return new q});h.define("select2/options",["require","jquery","./defaults","./utils"],function(e,f,d,c){function b(a,b){this.options=a;null!=b&&this.fromElement(b);null!=b&&(this.options=d.applyFromElement(this.options,b));this.options=d.apply(this.options);b&&b.is("input")&&(a=e(this.get("amdBase")+"compat/inputData"),this.options.dataAdapter=c.Decorate(this.options.dataAdapter,a))}b.prototype.fromElement=
  function(a){function b(a,b){return b.toUpperCase()}var d=["select2"];null==this.options.multiple&&(this.options.multiple=a.prop("multiple"));null==this.options.disabled&&(this.options.disabled=a.prop("disabled"));null==this.options.dir&&(a.prop("dir")?this.options.dir=a.prop("dir"):a.closest("[dir]").prop("dir")?this.options.dir=a.closest("[dir]").prop("dir"):this.options.dir="ltr");a.prop("disabled",this.options.disabled);a.prop("multiple",this.options.multiple);c.GetData(a[0],"select2Tags")&&(this.options.debug&&
  window.console&&console.warn&&console.warn('Select2: The `data-select2-tags` attribute has been changed to use the `data-data` and `data-tags="true"` attributes and will be removed in future versions of Select2.'),c.StoreData(a[0],"data",c.GetData(a[0],"select2Tags")),c.StoreData(a[0],"tags",!0));c.GetData(a[0],"ajaxUrl")&&(this.options.debug&&window.console&&console.warn&&console.warn("Select2: The `data-ajax-url` attribute has been changed to `data-ajax--url` and support for the old attribute will be removed in future versions of Select2."),
  a.attr("ajax--url",c.GetData(a[0],"ajaxUrl")),c.StoreData(a[0],"ajax-Url",c.GetData(a[0],"ajaxUrl")));for(var e={},h=0;h<a[0].attributes.length;h++){var p=a[0].attributes[h].name;if("data-"==p.substr(0,5)){var l=p.substring(5);p=c.GetData(a[0],l);l=l.replace(/-([a-z])/g,b);e[l]=p}}f.fn.jquery&&"1."==f.fn.jquery.substr(0,2)&&a[0].dataset&&(e=f.extend(!0,{},a[0].dataset,e));a=f.extend(!0,{},c.GetData(a[0]),e);a=c._convertData(a);for(var r in a)-1<f.inArray(r,d)||(f.isPlainObject(this.options[r])?f.extend(this.options[r],
  a[r]):this.options[r]=a[r]);return this};b.prototype.get=function(a){return this.options[a]};b.prototype.set=function(a,b){this.options[a]=b};return b});h.define("select2/core",["jquery","./options","./utils","./keys"],function(e,f,d,c){var b=function(a,c){null!=d.GetData(a[0],"select2")&&d.GetData(a[0],"select2").destroy();this.$element=a;this.id=this._generateId(a);c=c||{};this.options=new f(c,a);b.__super__.constructor.call(this);c=a.attr("tabindex")||0;d.StoreData(a[0],"old-tabindex",c);a.attr("tabindex",
  "-1");this.dataAdapter=new (this.options.get("dataAdapter"))(a,this.options);c=this.render();this._placeContainer(c);this.selection=new (this.options.get("selectionAdapter"))(a,this.options);this.$selection=this.selection.render();this.selection.position(this.$selection,c);this.dropdown=new (this.options.get("dropdownAdapter"))(a,this.options);this.$dropdown=this.dropdown.render();this.dropdown.position(this.$dropdown,c);this.results=new (this.options.get("resultsAdapter"))(a,this.options,this.dataAdapter);
  this.$results=this.results.render();this.results.position(this.$results,this.$dropdown);var e=this;this._bindAdapters();this._registerDomEvents();this._registerDataEvents();this._registerSelectionEvents();this._registerDropdownEvents();this._registerResultsEvents();this._registerEvents();this.dataAdapter.current(function(a){e.trigger("selection:update",{data:a})});a.addClass("select2-hidden-accessible");a.attr("aria-hidden","true");this._syncAttributes();d.StoreData(a[0],"select2",this);a.data("select2",
  this)};d.Extend(b,d.Observable);b.prototype._generateId=function(a){a=null!=a.attr("id")?a.attr("id"):null!=a.attr("name")?a.attr("name")+"-"+d.generateChars(2):d.generateChars(4);a=a.replace(/(:|\.|\[|\]|,)/g,"");return"select2-"+a};b.prototype._placeContainer=function(a){a.insertAfter(this.$element);var b=this._resolveWidth(this.$element,this.options.get("width"));null!=b&&a.css("width",b)};b.prototype._resolveWidth=function(a,b){var c=/^width:(([-+]?([0-9]*\.)?[0-9]+)(px|em|ex|%|in|cm|mm|pt|pc))/i;
  if("resolve"==b)return c=this._resolveWidth(a,"style"),null!=c?c:this._resolveWidth(a,"element");if("element"==b)return c=a.outerWidth(!1),0>=c?"auto":c+"px";if("style"==b){a=a.attr("style");if("string"!==typeof a)return null;a=a.split(";");b=0;for(var d=a.length;b<d;b+=1){var e=a[b].replace(/\s/g,"").match(c);if(null!==e&&1<=e.length)return e[1]}return null}return"computedstyle"==b?window.getComputedStyle(a[0]).width:b};b.prototype._bindAdapters=function(){this.dataAdapter.bind(this,this.$container);
  this.selection.bind(this,this.$container);this.dropdown.bind(this,this.$container);this.results.bind(this,this.$container)};b.prototype._registerDomEvents=function(){var a=this;this.$element.on("change.select2",function(){a.dataAdapter.current(function(b){a.trigger("selection:update",{data:b})})});this.$element.on("focus.select2",function(b){a.trigger("focus",b)});this._syncA=d.bind(this._syncAttributes,this);this._syncS=d.bind(this._syncSubtree,this);this.$element[0].attachEvent&&this.$element[0].attachEvent("onpropertychange",
  this._syncA);var b=window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver;null!=b?(this._observer=new b(function(b){a._syncA();a._syncS(null,b)}),this._observer.observe(this.$element[0],{attributes:!0,childList:!0,subtree:!1})):this.$element[0].addEventListener&&(this.$element[0].addEventListener("DOMAttrModified",a._syncA,!1),this.$element[0].addEventListener("DOMNodeInserted",a._syncS,!1),this.$element[0].addEventListener("DOMNodeRemoved",a._syncS,!1))};b.prototype._registerDataEvents=
  function(){var a=this;this.dataAdapter.on("*",function(b,c){a.trigger(b,c)})};b.prototype._registerSelectionEvents=function(){var a=this,b=["toggle","focus"];this.selection.on("toggle",function(){a.toggleDropdown()});this.selection.on("focus",function(b){a.focus(b)});this.selection.on("*",function(c,d){-1===e.inArray(c,b)&&a.trigger(c,d)})};b.prototype._registerDropdownEvents=function(){var a=this;this.dropdown.on("*",function(b,c){a.trigger(b,c)})};b.prototype._registerResultsEvents=function(){var a=
  this;this.results.on("*",function(b,c){a.trigger(b,c)})};b.prototype._registerEvents=function(){var a=this;this.on("open",function(){a.$container.addClass("select2-container--open")});this.on("close",function(){a.$container.removeClass("select2-container--open")});this.on("enable",function(){a.$container.removeClass("select2-container--disabled")});this.on("disable",function(){a.$container.addClass("select2-container--disabled")});this.on("blur",function(){a.$container.removeClass("select2-container--focus")});
  this.on("query",function(b){a.isOpen()||a.trigger("open",{});this.dataAdapter.query(b,function(c){a.trigger("results:all",{data:c,query:b})})});this.on("query:append",function(b){this.dataAdapter.query(b,function(c){a.trigger("results:append",{data:c,query:b})})});this.on("keypress",function(b){var d=b.which;if(a.isOpen())d===c.ESC||d===c.TAB||d===c.UP&&b.altKey?(a.close(b),b.preventDefault()):d===c.ENTER?(a.trigger("results:select",{}),b.preventDefault()):d===c.SPACE&&b.ctrlKey?(a.trigger("results:toggle",
  {}),b.preventDefault()):d===c.UP?(a.trigger("results:previous",{}),b.preventDefault()):d===c.DOWN&&(a.trigger("results:next",{}),b.preventDefault());else if(d===c.ENTER||d===c.SPACE||d===c.DOWN&&b.altKey)a.open(),b.preventDefault()})};b.prototype._syncAttributes=function(){this.options.set("disabled",this.$element.prop("disabled"));this.isDisabled()?(this.isOpen()&&this.close(),this.trigger("disable",{})):this.trigger("enable",{})};b.prototype._isChangeMutation=function(a,b){var c=!1,d=this;if(!a||
  !a.target||"OPTION"===a.target.nodeName||"OPTGROUP"===a.target.nodeName){if(b)if(b.addedNodes&&0<b.addedNodes.length)for(a=0;a<b.addedNodes.length;a++)b.addedNodes[a].selected&&(c=!0);else b.removedNodes&&0<b.removedNodes.length?c=!0:e.isArray(b)&&e.each(b,function(a,b){if(d._isChangeMutation(a,b))return c=!0,!1});else c=!0;return c}};b.prototype._syncSubtree=function(a,b){var c=this;this._isChangeMutation(a,b)&&this.dataAdapter.current(function(a){c.trigger("selection:update",{data:a})})};b.prototype.trigger=
  function(a,c){var d=b.__super__.trigger,e={open:"opening",close:"closing",select:"selecting",unselect:"unselecting",clear:"clearing"};void 0===c&&(c={});if(a in e){var f={prevented:!1,name:a,args:c};d.call(this,e[a],f);if(f.prevented){c.prevented=!0;return}}d.call(this,a,c)};b.prototype.toggleDropdown=function(){this.isDisabled()||(this.isOpen()?this.close():this.open())};b.prototype.open=function(){this.isOpen()||this.isDisabled()||this.trigger("query",{})};b.prototype.close=function(a){this.isOpen()&&
  this.trigger("close",{originalEvent:a})};b.prototype.isEnabled=function(){return!this.isDisabled()};b.prototype.isDisabled=function(){return this.options.get("disabled")};b.prototype.isOpen=function(){return this.$container.hasClass("select2-container--open")};b.prototype.hasFocus=function(){return this.$container.hasClass("select2-container--focus")};b.prototype.focus=function(a){this.hasFocus()||(this.$container.addClass("select2-container--focus"),this.trigger("focus",{}))};b.prototype.enable=
  function(a){this.options.get("debug")&&window.console&&console.warn&&console.warn('Select2: The `select2("enable")` method has been deprecated and will be removed in later Select2 versions. Use $element.prop("disabled") instead.');if(null==a||0===a.length)a=[!0];this.$element.prop("disabled",!a[0])};b.prototype.data=function(){this.options.get("debug")&&0<arguments.length&&window.console&&console.warn&&console.warn('Select2: Data can no longer be set using `select2("data")`. You should consider setting the value instead using `$element.val()`.');
  var a=[];this.dataAdapter.current(function(b){a=b});return a};b.prototype.val=function(a){this.options.get("debug")&&window.console&&console.warn&&console.warn('Select2: The `select2("val")` method has been deprecated and will be removed in later Select2 versions. Use $element.val() instead.');if(null==a||0===a.length)return this.$element.val();a=a[0];e.isArray(a)&&(a=e.map(a,function(a){return a.toString()}));this.$element.val(a).trigger("input").trigger("change")};b.prototype.destroy=function(){this.$container.remove();
  this.$element[0].detachEvent&&this.$element[0].detachEvent("onpropertychange",this._syncA);null!=this._observer?(this._observer.disconnect(),this._observer=null):this.$element[0].removeEventListener&&(this.$element[0].removeEventListener("DOMAttrModified",this._syncA,!1),this.$element[0].removeEventListener("DOMNodeInserted",this._syncS,!1),this.$element[0].removeEventListener("DOMNodeRemoved",this._syncS,!1));this._syncS=this._syncA=null;this.$element.off(".select2");this.$element.attr("tabindex",
  d.GetData(this.$element[0],"old-tabindex"));this.$element.removeClass("select2-hidden-accessible");this.$element.attr("aria-hidden","false");d.RemoveData(this.$element[0]);this.$element.removeData("select2");this.dataAdapter.destroy();this.selection.destroy();this.dropdown.destroy();this.results.destroy();this.results=this.dropdown=this.selection=this.dataAdapter=null};b.prototype.render=function(){var a=e('<span class="select2 select2-container"><span class="selection"></span><span class="dropdown-wrapper" aria-hidden="true"></span></span>');
  a.attr("dir",this.options.get("dir"));this.$container=a;this.$container.addClass("select2-container--"+this.options.get("theme"));d.StoreData(a[0],"element",this.$element);return a};return b});h.define("jquery-mousewheel",["jquery"],function(e){return e});h.define("jquery.select2",["jquery","jquery-mousewheel","./select2/core","./select2/defaults","./select2/utils"],function(e,f,d,c,b){if(null==e.fn.select2){var a=["open","close","destroy"];e.fn.select2=function(c){c=c||{};if("object"===typeof c)return this.each(function(){var a=
  e.extend(!0,{},c);new d(e(this),a)}),this;if("string"===typeof c){var f,g=Array.prototype.slice.call(arguments,1);this.each(function(){var a=b.GetData(this,"select2");null==a&&window.console&&console.error&&console.error("The select2('"+c+"') method was called on an element that is not using Select2.");f=a[c].apply(a,g)});return-1<e.inArray(c,a)?this:f}throw Error("Invalid arguments for Select2: "+c);}}null==e.fn.select2.defaults&&(e.fn.select2.defaults=c);return d});return{define:h.define,require:h.require}}(),
  v=x.require("jquery.select2");t.fn.select2.amd=x;return v});
  