text: /**
   * Copyright (c) 2014, 2017, Oracle and/or its affiliates.
   * The Universal Permissive License (UPL), Version 1.0
   */
  "use strict";
  /*
   Copyright 2012 Igor Vaynberg
  
   This software is licensed under the Apache License, Version 2.0 (the "Apache License") or the GNU
   General Public License version 2 (the "GPL License"). You may choose either license to govern your
   use of this software only upon the condition that you accept all of the terms of either the Apache
   License or the GPL License.
  
   You may obtain a copy of the Apache License and the GPL License at:
  
   http://www.apache.org/licenses/LICENSE-2.0
   http://www.gnu.org/licenses/gpl-2.0.html
  
   Unless required by applicable law or agreed to in writing, software distributed under the
   Apache License or the GPL Licesnse is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
   CONDITIONS OF ANY KIND, either express or implied. See the Apache License and the GPL License for
   the specific language governing permissions and limitations under the Apache License and the GPL License.
   Copyright 2012 Igor Vaynberg
  
   This software is licensed under the Apache License, Version 2.0 (the "Apache License") or the GNU
   General Public License version 2 (the "GPL License"). You may choose either license to govern your
   use of this software only upon the condition that you accept all of the terms of either the Apache
   License or the GPL License.
  
   You may obtain a copy of the Apache License and the GPL License at:
  
   http://www.apache.org/licenses/LICENSE-2.0
   http://www.gnu.org/licenses/gpl-2.0.html
  
   Unless required by applicable law or agreed to in writing, software distributed under the
   Apache License or the GPL Licesnse is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
   CONDITIONS OF ANY KIND, either express or implied. See the Apache License and the GPL License for
   the specific language governing permissions and limitations under the Apache License and the GPL License.
   Copyright 2012 Igor Vaynberg
  
   This software is licensed under the Apache License, Version 2.0 (the "Apache License") or the GNU
   General Public License version 2 (the "GPL License"). You may choose either license to govern your
   use of this software only upon the condition that you accept all of the terms of either the Apache
   License or the GPL License.
  
   You may obtain a copy of the Apache License and the GPL License at:
  
   http://www.apache.org/licenses/LICENSE-2.0
   http://www.gnu.org/licenses/gpl-2.0.html
  
   Unless required by applicable law or agreed to in writing, software distributed under the
   Apache License or the GPL Licesnse is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
   CONDITIONS OF ANY KIND, either express or implied. See the Apache License and the GPL License for
   the specific language governing permissions and limitations under the Apache License and the GPL License.
   Copyright 2012 Igor Vaynberg
  
   This software is licensed under the Apache License, Version 2.0 (the "Apache License") or the GNU
   General Public License version 2 (the "GPL License"). You may choose either license to govern your
   use of this software only upon the condition that you accept all of the terms of either the Apache
   License or the GPL License.
  
   You may obtain a copy of the Apache License and the GPL License at:
  
   http://www.apache.org/licenses/LICENSE-2.0
   http://www.gnu.org/licenses/gpl-2.0.html
  
   Unless required by applicable law or agreed to in writing, software distributed under the
   Apache License or the GPL Licesnse is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
   CONDITIONS OF ANY KIND, either express or implied. See the Apache License and the GPL License for
   the specific language governing permissions and limitations under the Apache License and the GPL License.
   Copyright 2012 Igor Vaynberg
  
   This software is licensed under the Apache License, Version 2.0 (the "Apache License") or the GNU
   General Public License version 2 (the "GPL License"). You may choose either license to govern your
   use of this software only upon the condition that you accept all of the terms of either the Apache
   License or the GPL License.
  
   You may obtain a copy of the Apache License and the GPL License at:
  
   http://www.apache.org/licenses/LICENSE-2.0
   http://www.gnu.org/licenses/gpl-2.0.html
  
   Unless required by applicable law or agreed to in writing, software distributed under the
   Apache License or the GPL Licesnse is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
   CONDITIONS OF ANY KIND, either express or implied. See the Apache License and the GPL License for
   the specific language governing permissions and limitations under the Apache License and the GPL License.
   Copyright 2012 Igor Vaynberg
  
   This software is licensed under the Apache License, Version 2.0 (the "Apache License") or the GNU
   General Public License version 2 (the "GPL License"). You may choose either license to govern your
   use of this software only upon the condition that you accept all of the terms of either the Apache
   License or the GPL License.
  
   You may obtain a copy of the Apache License and the GPL License at:
  
   http://www.apache.org/licenses/LICENSE-2.0
   http://www.gnu.org/licenses/gpl-2.0.html
  
   Unless required by applicable law or agreed to in writing, software distributed under the
   Apache License or the GPL Licesnse is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
   CONDITIONS OF ANY KIND, either express or implied. See the Apache License and the GPL License for
   the specific language governing permissions and limitations under the Apache License and the GPL License.
   Copyright 2012 Igor Vaynberg
  
   This software is licensed under the Apache License, Version 2.0 (the "Apache License") or the GNU
   General Public License version 2 (the "GPL License"). You may choose either license to govern your
   use of this software only upon the condition that you accept all of the terms of either the Apache
   License or the GPL License.
  
   You may obtain a copy of the Apache License and the GPL License at:
  
   http://www.apache.org/licenses/LICENSE-2.0
   http://www.gnu.org/licenses/gpl-2.0.html
  
   Unless required by applicable law or agreed to in writing, software distributed under the
   Apache License or the GPL Licesnse is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
   CONDITIONS OF ANY KIND, either express or implied. See the Apache License and the GPL License for
   the specific language governing permissions and limitations under the Apache License and the GPL License.
  */
  define(["ojs/ojcore","jquery","ojs/ojeditablevalue"],function(a,g){var c={hE:"oj-select-options-generated",Qb:{TAB:9,ENTER:13,RS:27,SPACE:32,LEFT:37,UP:38,RIGHT:39,DOWN:40,zT:16,Vra:17,Ora:18,PAGE_UP:33,PAGE_DOWN:34,HOME:36,END:35,KS:8,W5:46,X3:function(a){switch(a.which){case c.Qb.zT:case c.Qb.Vra:case c.Qb.Ora:return!0}return a.metaKey||a.ctrlKey?!0:!1},a4:function(a){a=a.which?a.which:a;return 112<=a&&123>=a}},asa:70,oA:{Z5:"enter_pressed",Nsa:"option_selected",P5:"blur",Usa:"search_icon_clicked"},
  i4:{x:0,y:0},ID:function(){var a=1;return function(){return a++}}(),Gqa:null,bt:function(a,b){for(var c=g.isFunction(a[0])?g(a[0]()):g(a[0]),d=-1,e=a.length;++d<e&&(c.context=c[0]=g.isFunction(a[0])?a[d]():a[d])&&!1!==b.call(c[0],d,c););return a},QSa:function(){var a=g("\x3cdiv class\x3d'oj-listbox-measure-scrollbar'\x3e\x3c/div\x3e");a.appendTo("body");var b={width:a.width()-a[0].clientWidth,height:a.height()-a[0].clientHeight};a.remove();return b},Ft:function(a,b){var c,d,e;if(null===a||1>a.length)return[];
  c=a.split(b);d=0;for(e=c.length;d<e;d+=1)c[d]=g.trim(c[d]);return c},Jna:function(a){return a.outerWidth(!1)-a.width()},jSa:function(a){a.on("keydown",function(){void 0===g.data(a,"keyup-change-value")&&g.data(a,"keyup-change-value",a.val())});a.on("keyup",function(b){b.which===c.Qb.ENTER?b.preventDefault():(b=g.data(a,"keyup-change-value"),void 0!==b&&a.val()!==b&&(g.removeData(a,"keyup-change-value"),a.trigger("keyup-change")))})},A3:function(a){var b,c=a.which||a.keyCode;a&&"keydown"==a.type&&
  (32==c||47<c&&58>c||64<c&&91>c||95<c&&112>c||185<c&&193>c||218<c&&223>c)&&(b=String.fromCharCode(a.which),a.shiftKey||(b=b.toLowerCase()),a.preventDefault());return b},iSa:function(a){a.on("mousemove",function(a){var b=c.i4;if(void 0===b||b.x!==a.pageX||b.y!==a.pageY)g(a.target).trigger("mousemove-filtered",a),c.i4.x=a.pageX,c.i4.y=a.pageY})},NUa:function(a){var b=!1,c;return function(){!1===b&&(c=a(),b=!0);return c}},Ni:function(a,b){if(b[0]!==document.activeElement){var c=a.vk("focus");window.setTimeout(function(){var a=
  b[0],d=b.val().length;b.focus();b.is(":visible")&&a===document.activeElement&&(a.setSelectionRange?a.setSelectionRange(d,d):a.createTextRange&&(a=a.createTextRange(),a.collapse(!1),a.select()));c()},40)}},ana:function(a){a=g(a)[0];var b=0,c=0;"selectionStart"in a?(b=a.selectionStart,c=a.selectionEnd-b):"selection"in document&&(a.focus(),b=document.selection.createRange(),c=document.selection.createRange().text.length,b.moveStart("character",-a.value.length),b=b.text.length-c);return{offset:b,length:c}},
  oz:function(a){a.preventDefault()},CSa:function(a){a.preventDefault();a.stopImmediatePropagation()},MWa:function(a){var b={"\\":"\x26#92;","\x26":"\x26amp;","\x3c":"\x26lt;","\x3e":"\x26gt;",'"':"\x26quot;","'":"\x26#39;"};return String(a).replace(/[&<>"'\\]/g,function(a){return b[a]})},GSa:function(a,b){function d(a){return""+a.label}var e=a,f,h;g.isArray(e)&&(h=e,e={ac:h});!1===g.isFunction(e)&&(h=e,e=function(){return h});var k=e();k&&k.text&&(d=k.text,g.isFunction(d)||(f=k.text,d=function(a){return a[f]}));
  return function(a){var f={ac:[]};""!==a.mw||b?(e()&&c.bt(g(e().ac),function(e,g){c.Z_(a,g,f.ac,b,!0,d)}),a.gd(f)):a.gd(e())}},O2:function(a,b,d,e){var f=g("\x3coption\x3e");f.addClass("oj-listbox-result oj-listbox-result-selectable oj-listbox-results-depth-"+a);f.attr("role","option");f.attr("id","oj-listbox-result-label-"+c.ID());f.text(e(d));f.attr("value",b);return f},lma:function(a,b,c){var d=g("\x3coptgroup\x3e");d.addClass("oj-listbox-results-sub");d.attr("label",c(b));a.addClass("oj-listbox-result-with-children");
  return d},ESa:function(a,b,d){function e(a,b,f){var h,k,l,t;b.each(function(){k=g(this);k.is("li")&&(0<k.children("ul").length?(l=k.contents().filter(function(){return 1!==this.nodeType||"ul"!==this.tagName.toLowerCase()}).text(),h=c.lma(a,l,d),t=k.children("ul"),e(h,t.children(),f+1)):h=c.O2(f,k.attr("oj-data-value"),k.text(),d),h.appendTo(a))})}e(a,b,0)},l4:function(a,b,c){c=b[c]||c;return a[c]},Ela:function(a,b,d,e){function f(a,b,e,g){for(var h,k,l,t=0,m=b.length;t<m;t++)h=b[t],l=c.l4(h,g,"children"),
  k=c.l4(h,g,"label"),l&&0<l.length?(k=c.lma(a,k,d),f(k,l,e+1,g.childKeys||{})):(l=c.l4(h,g,"value"),k=c.O2(e,l,k,d)),k.appendTo(a)}f(a,b,0,e||{})},Tla:function(a){a.children().remove();a.removeClass("oj-listbox-result-with-children")},ATa:function(a,b){return function(d){var e={component:this.ea};d.value?e.value=d.value:e.term=d.mw||"";a(e).then(function(a){var e={ac:[]};a&&c.bt(g(a),function(a,f){c.Z_(d,f,e.ac,b,!1)});d.gd(e)})}},Z_:function(a,b,d,e,f,h){var k,l;b=b[0];!b.label&&e&&e.label&&(b.label=
  b[e.label]);!b.value&&e&&e.value&&(b.value=b[e.value]);!b.children&&e&&e.children&&(b.children=b[e.children],delete b[e.children]);if(b.children){k={};for(l in b)b.hasOwnProperty(l)&&(k[l]=b[l]);k.children=[];c.bt(g(b.children),function(b,d){c.Z_(a,d,k.children,e&&e.childKeys?e.childKeys:null,f,h)});(!f||k.children.length||a.dw(a.mw,h(k),b))&&d.push(k)}else f&&!a.dw(a.mw,h(b),b)||d.push(b)},YOa:function(a,b,c){if(g.isFunction(b))return!0;if(!b)return!1;throw Error(c+" must be a function or a false value");
  },zv:function(b,c){function d(){}a.f.xa(d,b,"");d.prototype=g.extend(d.prototype,c);return d},z6:"last-query-result",pna:function(a){return g.data(a.Ta,a.cb+"-"+c.z6)},dUa:function(a,b){g.data(a.Ta,a.cb+"-"+c.z6,b)}},b=c.zv(Object,{De:function(a){var b=this;return function(){a.apply(b,arguments)}},_init:function(a){var b,d,e=this.cb;b=this.xc;this.ea=a.ea;this.ma=a=this.bv(a);this.id=a.id;this.roa=!1;void 0!==a.element.data(b)&&null!==a.element.data(b)&&a.element.data(b)._destroy();this.Ta=this.CF();
  var f=a.rootAttributes;this.Vs=f&&f.id?f.id:"ojChoiceId_"+(a.element.attr("id")||"autogen"+c.ID());this.Vs.replace(/([;&,\.\+\*\~':"\!\^#$%@\[\]\(\)=>\|])/g,"\\$1");this.Ta.attr("id",this.Vs);this.body=c.NUa(function(){return a.element.closest("body")});this.Ta.attr("style",a.element.attr("style"));this.U2=this.ma.element.attr("tabindex");this.ma.element.data(b,this).attr("tabindex","-1").before(this.Ta);this.Ta.data(b,this);this.Dd=this.Ta.find(".oj-listbox-drop");this.Dd.data("ojlistbox",this);
  this.pMa(a.pickerAttributes);this.Dd.attr("data-oj-containerid",this.Vs);this.ac=b=this.Ta.find(".oj-listbox-results");this.ac.on("click",c.oz);if(f=this.ea.VK()){var h=f.attr("id");h?b.attr("aria-labelledby",h):b.attr("aria-label",f.text())}else(f=this.ea.element.attr("aria-label"))&&b.attr("aria-label",f);a.list&&g("#"+a.list).is("ul")&&(b=g("#"+a.list),this.xma=b.parent(),b.addClass("oj-listbox-results").attr("role","listbox"),this.ac.replaceWith(b),this.ac=b=this.Ta.find(".oj-listbox-results"),
  this.ac.css("display",""));this.search=d="oj-select"==e?this.Ta.find("input.oj-listbox-input"):this.Ta.find("input."+e+"-input");this.c5=this.oqa=0;this.context=null;this.eO();this.Ta.on("click",c.oz);c.iSa(this.ac);this.Dd.on("mousemove-filtered touchstart touchmove touchend",".oj-listbox-results",this.De(this.Bfa));g(this.Ta).on("change","."+e+"-input",function(a){a.stopPropagation()});g(this.Dd).on("change","."+e+"-input",function(a){a.stopPropagation()});var k=this;c.jSa(d);d.on("keyup-change input paste",
  this.De(this.pv));d.on("focus",function(){d.addClass(e+"-focused");"oj-select"!==e&&k.Ta.addClass("oj-focus")});d.on("blur",function(){d.removeClass(e+"-focused");"oj-select"!==e&&k.Ta.removeClass("oj-focus")});this.Dd.on("mouseup",".oj-listbox-results",this.De(function(a){0<g(a.target).closest(".oj-listbox-result-selectable").length&&(this.Bfa(a),this.H0(null,a))}));this.Dd.on("click mouseup mousedown",function(a){a.stopPropagation()});g.isFunction(this.ma.lz)&&this.em();b=a.element.prop("disabled");
  void 0===b&&(b=!1);this.Ao(!b);b=a.element.prop("readonly");void 0===b&&(b=!1);this.sH(b);c.Gqa=c.Gqa||c.QSa();this.autofocus=a.element.prop("autofocus");a.element.prop("autofocus",!1);this.autofocus&&this.Ni()},vW:function(a){var b=this.Dd;!g(a.target).closest(b).length&&!g(a.target).closest("#"+b.attr("data-oj-containerid")).length&&0<b.length&&(b=b.data("ojlistbox"),b.close(a))},Ny:function(){this.Dd&&this.Dd.remove()},_destroy:function(){var a=this.nu;isNaN(a)||(delete this.nu,window.clearTimeout(a));
  var a=this.ma.element,b=a.data(this.xc);this.close();this.lqa&&(delete this.lqa,this.lqa=null);this.ma.list&&this.ac&&(this.pW(this.ac),this.xma&&this.xma.append(this.ac));void 0!==b&&(b.Ta.after(a),b.Ta.remove(),b.Dd.remove(),a.removeAttr("aria-hidden").removeData(this.xc).off("."+this.cb).prop("autofocus",this.autofocus||!1),this.U2?a.attr({uXa:this.U2}):a.removeAttr("tabindex"),a.show())},pW:function(a){if(a&&a.is("ul")){a.removeClass("oj-listbox-results oj-listbox-result-sub");a.removeAttr("role");
  for(var b=a.children().length-1;0<=b;b--)this.pW(g(a.children()[b]))}else a.is("li")&&((a.hasClass("oj-listbox-placeholder")||a.hasClass("oj-listbox-no-results"))&&a.remove(),a.attr("class")&&a.attr("class",a.attr("class").replace(/\oj-listbox-\S+/g,"")),(b=a.children(".oj-listbox-result-label"))&&b.contents().unwrap(),"none"==a.css("display")&&a.css("display",""),this.pW(a.children("ul")))},py:function(a){if(a.is("option"))return{value:a.prop("value"),label:a.text(),element:a.get(),css:a.attr("class"),
  disabled:a.prop("disabled"),locked:"locked"===a.attr("locked")||!0===a.data("locked")};if(a.is("optgroup"))return{label:a.attr("label"),children:[],element:a.get(),css:a.attr("class")};if(a.is("li")){var b,c=null;(b=a.children())&&0<b.length&&b.is("ul")?(b=a.attr("oj-data-label")?a.attr("oj-data-label"):a.clone().children().remove().end().text().trim(),c=[]):b=a.attr("oj-data-label")?a.attr("oj-data-label"):a.text().trim();return{value:a.attr("oj-data-value"),label:b,element:a.get(),css:a.attr("class"),
  children:c}}},bv:function(a){var b,e,f=this;a.options&&Array.isArray(a.options)&&a.optionsKeys&&(a.options=g.extend(!0,[],a.options));b=a.element;var h=b.get(0).tagName.toLowerCase();"input"===h&&b.attr("list")?this.Rq=e=g("#"+b.attr("list")):"select"===h&&0<b.children().length?this.Rq=e=b:a.list&&(this.Rq=e=g("#"+a.list));a=g.extend({},{kTa:function(b,d,e,k){var l,m=this.ma.id,s=this.ma.optionRenderer;"function"!==typeof s&&(s=null);l=function(b,d,k,u,n){function v(c,d){if(s){var f={index:N,depth:u,
  leaf:!d.children,parent:b,data:d,component:a.ea,parentElement:c.get(0)},f=s.call(a.ea,f);null!==f&&(null===f.parentNode||f.parentNode instanceof DocumentFragment)&&c.get(0).appendChild(f)}else Y=a.Lma(d),void 0!==Y&&(c.text(Y),c.attr("aria-label",Y));!0!==e.bR&&(f=c.find(".oj-listbox-highlighter-section"),f.length||(f=c),p(f,e.mw))}function p(a,b){function c(a,b){var d=0;if(3===a.nodeType){var e=a.data.toUpperCase().indexOf(b);if(0<=e){d=document.createElement("span");d.className="oj-listbox-highlighter";
  e=a.splitText(Math.min(e,a.data.length));e.splitText(Math.min(b.length,e.data.length));var f=e.cloneNode(!0);d.appendChild(f);e.parentNode.replaceChild(d,e);d=1}}else if(1===a.nodeType&&a.childNodes&&!/(script|style)/i.test(a.tagName))for(e=0;e<a.childNodes.length;++e)e+=c(a.childNodes[e],b);return d}a.length&&b&&b.length&&a.each(function(){c(this,b.toUpperCase())})}function y(a,b){if(b.children&&0<b.children.length){var c=b.element&&g(b.element[0]).is("li")&&g(b.element[0]).children("ul"),d=c?g(b.element[0]).children("ul"):
  g("\x3cul\x3e\x3c/ul\x3e");d.hasClass("oj-listbox-result-sub")||d.addClass("oj-listbox-result-sub");l(b,b.children,d,u+1,!1);c||a.append(d)}}var N,L,P,R,O,Y;L=f.vs();n&&null!==L&&!e.mw&&0>=k.find(".oj-listbox-placeholder").length&&("select"!==h||!f.ea.gi())&&(L={value:"",label:L},O=g("\x3cli\x3e\x3c/li\x3e"),O.addClass("oj-listbox-placeholder oj-listbox-results-depth-0 oj-listbox-result oj-listbox-result-selectable"),O.attr("role","presentation"),P=g(document.createElement("div")),P.addClass("oj-listbox-result-label"),
  P.attr("id","oj-listbox-result-label-"+c.ID()),P.attr("role","option"),Y=a.Lma(L),void 0!==Y&&P.text(Y),P.attr("aria-label",Y),O.append(P),O.data(f.xc,L),k.prepend(O));N=0;for(n=d.length;N<n;N+=1){L=d[N];R=!0===L.disabled;P=!R&&void 0!==m(L);var Z=L.element&&g(L.element[0]).is("li");O=Z?g(L.element[0]):g("\x3cli\x3e\x3c/li\x3e");O.hasClass("oj-listbox-result")?(L.children&&0<L.children.length&&y(O,L),g(L.element[0]).css("display","")):(O.addClass("oj-listbox-results-depth-"+u),O.addClass("oj-listbox-result"),
  O.addClass(P?"oj-listbox-result-selectable":"oj-listbox-result-unselectable"),R&&O.addClass("oj-disabled"),L.children&&O.addClass("oj-listbox-result-with-children"),O.attr("role","presentation"),P=g(document.createElement("div")),P.addClass("oj-listbox-result-label"),P.attr("id","oj-listbox-result-label-"+c.ID()),P.attr("role","option"),R&&P.attr("aria-disabled","true"),Z||(v(P,L),O.append(P)),L.children&&0<L.children.length&&y(O,L),O.data(f.xc,L),Z?(g(L.element[0]).contents().filter(function(){return"UL"!==
  this.tagName}).wrapAll(P),g(L.element[0]).css("display","")):k.append(O))}};l(null,d,b,0,k)}},d,a);a.id=function(a){return a.value};a.Lma=function(a){return isNaN(a.label)?a.label:this.ea.Ix(a.label)};a.g3=function(a){return a&&a.label?isNaN(a.label)?a.label:this.ea.Ix(a.label):void 0};"select"!==h&&null!==a.manageNewEntry&&(a.manageNewEntry=function(a){var b={};b.value=b.label=g.trim(a);return b});e?a.Fz=this.De(function(a){var b={ac:[],iXa:!1},d=a.mw,g,h;h=function(b,e){var g,k=b.children()&&0<
  b.children().length&&b.children().is("ul");if(b.is("option")||b.is("li")&&!k)a.dw(d,b.text(),b)&&e.push(f.py(b));else if(b.is("optgroup")||b.is("li")&&k)g=f.py(b),c.bt(b.is("optgroup")?b.children():b.children("ul").children(),function(a,b){h(b,g.children)}),0<g.children.length&&e.push(g)};g=e.children();void 0!==this.vs()&&0<g.length&&""==g.first().attr("value")&&(g=g.slice(1));c.bt(g,function(a,c){h(c,b.ac)});a.gd(b)}):"options"in a&&(a.Fz=g.isFunction(a.options)?c.ATa(a.options,a.optionsKeys?a.optionsKeys:
  null):c.GSa(a.options,a.optionsKeys?a.optionsKeys:null));return a},mza:function(){var a=this.ma.element.find(".oj-listbox-header");if(a.length){this.header=g("\x3cli\x3e",{"class":"oj-listbox-result-header oj-listbox-result-unselectable",role:"presentation"});this.header.append(a.children());this.QGa();a=g("\x3cul\x3e",{"class":"oj-listbox-results-with-header",role:"listbox"});a.append(this.header);a.appendTo(this.ac.parent());var b=g("\x3cli\x3e",{role:"presentation"});a.append(b);this.ac.attr("role",
  "presentation");this.ac.appendTo(b)}this.roa=!0},QGa:function(){this.tm=this.header.find("li[role\x3d'option'], li:not([role])");this.tm.uniqueId();this.header.find("ul").attr("role","presentation");this.header.find("li:not([role])").attr("role","option");this.header.find("a, input, select, textarea, button, object, .oj-component-initnode").each(function(){g(this).attr("tabIndex",-1)})},pga:function(a){var b=!1;this.tm.each(function(){if(g(this).attr("id")===a)return b=!0,!1});return b},YCa:function(a){if(!this.tm)return null;
  if(!a)return this.tm.first();var b=!1,c=null;this.tm.each(function(){if(b)return c=g(this),!1;b=g(this).attr("id")===a});return c},nDa:function(a){if(!this.tm)return null;var b=null;this.tm.each(function(){if(g(this).attr("id")===a)return!1;b=g(this)});return b},WLa:function(a){var b=a.find(".oj-component .oj-enabled").first();0===b.length&&(b=a.find("a, input, select, textarea, button, object, .oj-component-initnode").first(),0===b.length&&(b=a.children().first()));b&&b.addClass("oj-focus oj-focus-highlight oj-focus-only")},
  wKa:function(){this.tm&&this.tm.find(".oj-focus").removeClass("oj-focus oj-focus-highlight oj-focus-only")},ala:function(a){a=g.Event(this.xc+"-selecting",{val:this.id(a),object:a});this.ma.element.trigger(a);return!a.isDefaultPrevented()},uq:function(){return!0===this.yma},gB:function(){var a=this.hB&&!this.sH;if(a===this.yma)return!1;this.Ta.toggleClass("oj-disabled",!a);this.close();this.yma=a;return!0},Ao:function(a){void 0===a&&(a=!0);this.hB!==a&&(this.hB=a,this.ma.element.prop("disabled",!a),
  this.Ta.toggleClass("oj-enabled",a),this.gB())},bX:function(){this.Ao(!1)},sH:function(a){void 0===a&&(a=!1);if(this.sH===a)return!1;this.sH=a;this.ma.element.prop("readonly",a);this.gB();return!0},vf:function(){return this.Ta.hasClass("oj-listbox-dropdown-open")},mCa:function(){return this.Ta.children().first()},mI:function(b,c){if(a.Ga.W3(c)){var d=this.vk("close popup");this.nu=window.setTimeout(function(){g.proxy(this.close,this);d()},1)}else{var e=this.Ta,f=c.element.element;f.css(b);"bottom"===
  c.vertical?(e.addClass("oj-listbox-drop-above"),f.addClass("oj-listbox-drop-above")):(e.removeClass("oj-listbox-drop-above"),f.removeClass("oj-listbox-drop-above"))}},fda:function(){var b={my:"start top",at:"start bottom",of:this.mCa(),collision:"flip",using:g.proxy(this.mI,this)},c="rtl"===a.Q.Qj();return a.Ga.rp(b,c)},W_:function(){var a=this.Dd,b=this.fda();a.css("width",this.Ta.outerWidth());a.position(b)},NMa:function(a){return this.vf()||!1===this.hB||!0===this.sH?!1:this.ea._trigger("beforeExpand",
  a,{component:this.ma.element})},Baa:function(){this.Ta.removeClass("oj-listbox-drop-above");this.Dd.removeClass("oj-listbox-drop-above")},open:function(a,b){if(!this.NMa(a))return!1;this.Es(a,b);return!0},Es:function(){this.roa||this.mza();this.Ta.addClass("oj-listbox-dropdown-open")},tP:function(){if(this.vf()&&"true"!==this.Co().attr("aria-expanded")){this.Baa();var b=this.Dd.parent();if("oj-select"===this.cb&&!0!==this.ma.multiple&&b&&b.hasClass("oj-listbox-drop-layer"))a.Y.lc().vS(b,a.Y.jc.Er);
  else{this.Dd[0]!==this.body().children().last()[0]&&this.Dd.detach().appendTo(this.body());this.Dd.appendTo(this.body());this.header&&(this.Dd.find(".oj-listbox-results-with-header").prepend(this.header),this.header.show());b={};b[a.Y.jc.gA]=g.proxy(this.close,this);b[a.Y.jc.hA]=g.proxy(this.Ny,this);b[a.Y.jc.fA]=g.proxy(this.vW,this);b[a.Y.jc.Er]=g.proxy(this.W_,this);var c={};c[a.Y.Ma.Be]=this.Dd;c[a.Y.Ma.eA]=this.ma.element;c[a.Y.Ma.Ar]=b;c[a.Y.Ma.Fr]=this.fda();c[a.Y.Ma.Pt]="oj-listbox-drop-layer";
  a.Y.lc().open(c);g("#oj-listbox-drop").removeAttr("id");this.Dd.attr("id","oj-listbox-drop");this.Dd.attr("data-oj-containerid",this.Vs)}this.W_();this.Co().attr("aria-expanded",!0)}},close:function(){if(this.vf()){this.Ta.removeClass("oj-listbox-dropdown-open");var b=this.Co().attr("aria-expanded");if(b&&"false"!==b){var b=this.Vs,c="scroll."+b,d="resize."+b,e="orientationchange."+b;this.Ta.parents().add(window).each(function(){g(this).off(c).off(d).off(e)});this.Baa();b={};b[a.Y.Ma.Be]=this.Dd;
  a.Y.lc().close(b);this.header&&(this.header.hide(),this.header.appendTo(this.Ta));this.Dd.removeAttr("data-oj-containerid");this.Dd.removeAttr("id");this.ma.list?this.EH():(this.Dd.detach(),this.ac.empty());this.Co().attr("aria-expanded",!1);"ojcombobox"===this.xc&&this.Co().removeAttr("aria-activedescendant");g.removeData(this.Ta,this.cb+"-last-term")}}},pMa:function(b){a.pa.k5(this.Dd,b)},as:function(){},ZAa:function(){var a=this.ac,b,c,d,e;c=this.Zx();0>c||(0==c?a.scrollTop(0):(b=this.Ex().find(".oj-listbox-result-label"),
  d=g(b[c]),e=d.offset().top+d.outerHeight(!0),c===b.length-1&&(b=a.find("li.oj-listbox-more-results"),0<b.length&&(e=b.offset().top+b.outerHeight(!0))),b=a.offset().top+a.outerHeight(!0),e>b&&a.scrollTop(a.scrollTop()+(e-b)),e=d.offset().top-a.offset().top,0>e&&"none"!=d.css("display")&&a.scrollTop(a.scrollTop()+e)))},Ex:function(){return this.ac.find(".oj-listbox-result-selectable:not(.oj-disabled, .oj-selected)").filter(function(){return"none"!=g(this).css("display")})},pha:function(a){var b=this.Ex(),
  c=this.Zx();if(this.header&&(0>=c||c===b.length-1)){var d=this.Co().attr("aria-activedescendant"),e=this.pga(d);e||(d=null);var f=null;0<a&&(0>c||c===b.length-1)?f=this.YCa(d):0>a&&(e&&0>c||0===c)&&(f=this.nDa(d));if(f){this.EH();this.WLa(f);this.Co().attr("aria-activedescendant",f.attr("id"));return}e&&0>a&&(c=0)}for(;-1<=c&&c<b.length;)if(c+=a,c==b.length?c=0:-1==c&&(c=b.length-1),d=g(b[c]),d.hasClass("oj-listbox-result-selectable")&&!d.hasClass("oj-disabled")&&!d.hasClass("oj-selected")){this.Zx(c);
  break}},Zx:function(a){var b=this.Ex(),c=this.Dd.find(".oj-listbox-search"),c=c&&!c.attr("aria-hidden");if(0===arguments.length){var d=b.filter(".oj-hover");d.length||(d=b.children(".oj-hover").closest(".oj-listbox-result"));c&&this.lI(d.text());return b.get().indexOf(d[0])}a>=b.length&&(a=b.length-1);0>a&&(a=0);this.EH();b=g(b[a]);b.hasClass("oj-listbox-result-with-children")?(d=b.children(".oj-listbox-result-label"),d.addClass("oj-hover"),c&&this.lI(d.text())):(b.addClass("oj-hover"),c&&this.lI(b.text()));
  this.Co().attr("aria-activedescendant",b.find(".oj-listbox-result-label").attr("id"));this.ZAa()},EH:function(){this.ac.find(".oj-hover").removeClass("oj-hover");this.wKa();"ojcombobox"===this.xc&&this.Co().removeAttr("aria-activedescendant")},Bfa:function(a){a=g(a.target).closest(".oj-listbox-result-selectable");if(0<a.length&&!a.is(".oj-hover")){var b=this.Ex();this.Zx(b.index(a))}else 0==a.length&&this.EH()},lI:function(a){var b=this.Ta.find(".oj-listbox-liveregion");b.length&&b.text(a)},pv:function(a){var b=
  this,d=this.search.val(),e=g.data(this.Ta,this.cb+"-last-term");if(!0===a||!e||d!==e||!0===this.ma.multiple)if(e||d||!a||"input"!==a.type)g.data(this.Ta,this.cb+"-last-term",d),d.length>=(this.ma.minLength||0)?(isNaN(this.QO)||(clearTimeout(this.QO),this.QO=Number.NaN,this.cC&&(this.cC(),this.cC=null)),a&&!0!==a?(this.cC=this.vk("query results"),this.QO=setTimeout(function(){b.dia(a);b.cC&&b.cC();b.cC=null;b.QO=Number.NaN},c.asa)):this.dia(a)):this.close()},dia:function(a){function b(){h.W_();if(h.header&&
  h.tm.length){var a=h.Ex(),c=h.tm.length+a.length;h.tm.attr("aria-setsize",c);a.length&&(a=a.children("[role\x3d'option']"),a.attr("aria-setsize",c),a.first().attr("aria-posinset",h.tm.length+1))}}var d=this.search,e=this.ac,f=this.ma,h=this,k;k=d.val();var l;(f.minLength||0)>k.length?this.close():(this.open(null,!0),l=++this.oqa,this.EH(),k=this.search.val(),k=void 0!==k&&null!==k&&(!0!==a||f.nd||0<f.minLength)?k:"",this.c5=1,f.Fz({element:f.element,mw:k,page:this.c5,context:null,dw:f.dw,gd:this.De(function(k){if(l===
  this.oqa&&this.vf())if(this.context=k&&void 0!==k.context?k.context:null,k&&0!==k.ac.length&&!this.jga(k)||!c.YOa(h.ea,f.Kma,"formatNoMatches"))c.dUa(this,k.ac),this.tP(),this.Sha(e),h.ma.kTa.call(this,e,k.ac,{mw:d.val(),page:this.c5,context:null,bR:a},this.ika()),this.mH(k,a),b(),this.lI(f.fQa(h.ea,this.Ex().length));else{k=f.Kma(h.ea,d.val());if("oj-select"===this.cb||this.header){var m=g("\x3cli\x3e");m.addClass("oj-listbox-no-results");m.text(k);this.tP();this.Sha(e);e.append(m);b()}else this.close();
  this.lI(k)}})}))},Sha:function(a){this.ma.list?(a=a.children(),this.xfa(a)):a.empty()},xfa:function(a){for(var b=0;b<a.length;b++){g(a[b]).is("LI")&&((g(a[b]).hasClass("oj-listbox-no-results")||g(a[b]).hasClass("oj-listbox-placeholder"))&&g(a[b]).remove(),g(a[b]).css("display","none"),g(a[b]).hasClass("oj-selected")&&g(a[b]).removeClass("oj-selected"));var c=g(a[b]).children("ul");c&&c.children()&&this.xfa(c.children())}},hW:function(a){this.close(a)},pB:function(){c.Ni(this,this.search)},H0:function(a,
  b){if(this.header){var d=this.Co().attr("aria-activedescendant");if(this.pga(d)){var d=g("#"+d),e=d.find("a, input, select, textarea, button, object").first();0===e.length&&(e=d.children());e.length&&e[0].click();this.close(b);return}}d=this.Zx();(e=this.ac.find(".oj-hover").closest(".oj-listbox-result").data(this.xc))?(this.Zx(d),a=a||{},a.trigger=c.oA.Nsa,this.fH(e,a,b),this.jI(e,a,b),b&&"keydown"===b.type&&(this.Ama=!0)):a&&a.XSa&&this.close(b)},vs:function(){return this.ma.element.attr("placeholder")||
  this.ma.element.attr("data-placeholder")||this.ma.element.data("placeholder")||this.ma.placeholder},Bq:function(){var a=this.vs();a&&(this.search.attr("placeholder",a),this.Ta.removeClass(this.cb+"-allowclear"))},Ifa:function(){var a;a:{var b,c,d;a=this.ma.element.attr("style");if(void 0!==a)for(a=a.split(";"),c=0,d=a.length;c<d;c+=1)if(b=a[c].replace(/\s/g,""),b=b.match(/^width:(([-+]?([0-9]*\.)?[0-9]+)(px|em|ex|%|in|cm|mm|pt|pc))/i),null!==b&&1<=b.length){a=b[1];break a}a=void 0}null!==a&&this.Ta.css("width",
  a)},Gc:function(){return this.ea.option("value")},Lz:function(a,b,c){var d={Av:!1};c&&(d._context=c);"string"===typeof a?this.ea.dc([a],b,d):this.ea.dc(a,b,d);this.ma.element.val(a)},jI:function(){},ika:function(){return!1},Co:function(){return this.search},g1:function(a){var b=!1,d=this.Dd.find(".oj-listbox-search");d&&(this.GZ()?(this.Dd.find(".oj-listbox-search-wrapper").removeClass("oj-helper-hidden-accessible"),g(d).removeAttr("aria-hidden"),this.search.val(a),b=!0):(this.Dd.find(".oj-listbox-search-wrapper").addClass("oj-helper-hidden-accessible"),
  g(d).attr("aria-hidden","true")));c.Ni(this,b?this.search:this.selection);if(b){var e=this;d.find(".oj-listbox-spyglass-box").on("mouseup click",function(a){e.search.focus();a.preventDefault()})}},GZ:function(){var a=this.ma.minimumResultsForSearch;return(this.ma.list?g("#"+this.ma.list).find("li").length:this.Rq?this.Rq[0].length:this.ma.options?this.ma.options.length:0)>a||this.Uk},vk:function(b){b={description:b};return a.Context.getContext(this.Ta[0]).Ne().Ld(b)},jga:function(){return!1},Zg:function(a,
  b){for(var c=0;c<a.length;c++)if(g(a[c]).data(this.xc).value===b)return a[c];return null}}),d={I2:!0,mXa:!0,Kma:function(a){return a.R("noMatchesFound")},fQa:function(a,b){return 1===b?a.R("oneMatchesFound"):a.R("moreMatchesFound",{num:""+b})},id:function(a){return a.id},dw:function(a,b){return 0<=(""+b).toUpperCase().indexOf((""+a).toUpperCase())},separator:","},e=c.zv(b,{gB:function(){e.O.gB.apply(this,arguments)&&this.search.prop("disabled",!this.uq())},Ni:function(){this.vf()&&this.close()},_destroy:function(){g("label[for\x3d'"+
  this.search.attr("id")+"']").attr("for",this.ma.element.attr("id"));e.O._destroy.apply(this,arguments)},wx:function(b){this.selection.data(this.xc)&&(b||a.C.warn("Event should not be null when user modified the value in UI"),"oj-select"===this.cb&&this.ea.gi()||this.Lz([],b),this.search.val(""),this.selection.removeData(this.xc));this.Bq()},em:function(){this.ma.lz.call(null,this.Rq?this.Rq:this.ma.element,this.De(this.lla))},wo:function(a){if(this.uq())if(a.which===c.Qb.PAGE_UP||a.which===c.Qb.PAGE_DOWN)a.preventDefault();
  else{switch(a.which){case c.Qb.UP:case c.Qb.DOWN:this.vf()?this.pha(a.which===c.Qb.UP?-1:1):this.open(a);a.preventDefault();return;case c.Qb.ENTER:this.H0(null,a);a.preventDefault();this.vf()||(this.Uk=!1);return;case c.Qb.TAB:this.close(a);this.Uk=!1;return;case c.Qb.RS:this.vf()&&(this.hW(a),a.preventDefault());this.Uk=!1;return}this.Uk=!0}},Vya:function(a){this.uq()&&!this.vf()&&this.open(a)},eO:function(){var a,b=this.Ta,d,e=(d=this.ma.rootAttributes)&&d.id?d.id:this.ma.element.attr("id")||c.ID();
  this.selection=a=b.find("."+this.cb+"-choice");a.attr("id",this.cb+"-choice-"+e);d=g("label[for\x3d'"+this.ma.element.attr("id")+"']");d.attr("id")||d.attr("id",this.cb+"-label-"+e);a.find("."+this.cb+"-input").attr("id",this.cb+"-input-"+e);this.ac.attr("id")||this.ac.attr("id","oj-listbox-results-"+e);b=b.find(".oj-listbox-liveregion");b.length&&b.attr("id","oj-listbox-live-"+e);"oj-select"!==this.cb&&this.search.attr("aria-owns",this.ac.attr("id"));this.search.attr("aria-labelledby",d.attr("id"));
  this.ma.element.attr("aria-labelledby",d.attr("id"));this.search.attr("id")&&d.attr("for",this.search.attr("id"));this.ma.element.attr("aria-label")&&this.search.attr("aria-label",this.ma.element.attr("aria-label"));this.ma.element.attr("aria-controls")&&this.search.attr("aria-controls",this.ma.element.attr("aria-controls"));a.on("keydown",this.De(this.wo));a.on("mousedown","abbr",this.De(function(a){this.uq()&&(this.wx(a),c.CSa(a),this.close(a),this.selection.focus())}));a.on("mousedown",this.De(function(b){this.ma.element.prop("disabled")&&
  c.oz(b);a.removeClass("oj-focus-highlight");this.vf()?this.close(b):this.uq()&&this.open(b);var d=this.search.parent().attr("aria-hidden");d&&"true"==d?this.selection.focus():this.search.focus();g(b.target).hasClass("oj-combobox-open-icon")&&c.oz(b);this.Ta.addClass("oj-active")}));a.on("mouseup",this.De(function(){this.Ta.removeClass("oj-active")}));a.on("focus",this.De(function(a){c.oz(a)}));this.search.on("input",this.De(function(a){this.ea.Sl(this.search.val(),a)}));this.search.on("focus",this.De(function(){this.Uha=
  this.search.val()}));this.search.on("blur keyup",this.De(function(a){if("keyup"!==a.type||10===a.keyCode||13===a.keyCode){if(void 0!==this.search.val()&&0>=this.ac.find(".oj-hover").length&&("keyup"!==a.type||!this.Ama))if(this.ma.manageNewEntry){var b=this.search.val(),d=this.ma.manageNewEntry(b),e={trigger:"blur"===a.type?c.oA.P5:c.oA.Z5},f=this.selection.data(this.xc);!f&&""!==b||f&&f.label!==b||!this.ea.isValid()&&b!==this.Uha?(this.fH(d,e,a),"blur"!==a.type&&this.jI(d,e,a)):this.ma.nd&&"keyup"===
  a.type&&(f&&f.label===b&&(d=f),this.jI(d,e,a))}else null==this.ma.manageNewEntry&&((d=this.selection.data(this.xc),""==this.search.val())?this.wx(a):d||""===this.search.val()?"oj-select"!==this.cb&&(a=this.ma.g3(d),void 0!==a&&this.search.val(a)):this.as());this.search.removeClass(this.cb+"-focused");this.Ta.removeClass("oj-focus");this.Ama=!1}}));this.Ifa();this.ma.element.hide().attr("aria-hidden",!0);this.Ta.append(this.ma.element);this.Bq()},bv:function(){var a=e.O.bv.apply(this,arguments),b=
  this,d=a.element.get(0).tagName.toLowerCase();if("input"===d&&a.element.attr("list")||"select"===d&&0<a.element.children().length||a.list){var f=a.list?"li":"option";a.lz=function(a,c){var e,g=b.Gc();Array.isArray(g)&&(g=g[0]);void 0!==g&&null!==g&&(e=b.py(a.find(f).filter(function(){if("li"==f)return this.getAttribute("oj-data-value")===g;if("option"==f)return this.value===g})),"select"===d&&void 0===e&&(g=null));if(void 0===g||null===g)e=b.py(a.find(f).filter(function(){if("li"==f)return!0===this.getAttribute("oj-data-selected");
  if("option"==f)return this.selected}));c(e)};a.validate=function(a,c){var d;void 0!==c&&null!==c&&(d=b.py(a.find(f).filter(function(){if("li"==f)return this.getAttribute("oj-data-value")===c;if("option"==f)return this.value===c})));return!!d}}else if("options"in a||this.Gc()&&0<this.Gc().length)g.isFunction(a.options)?a.lz=function(d,e){function f(b,c){for(var d=0,e=b.length;d<e;d++){var g=b[d];if(c===a.id(g)||g.children&&(g=f(g.children,c)))return g}return null}var h="";b.Gc()&&b.Gc().length&&(h=
  b.Gc()[0]);var k=null;if(h){var l=c.pna(b);l&&(k=f(l,h));k||(l=b.currentItem)&&l.length&&h===a.id(l[0])&&(k=l[0]);k||b.G5?e(k):a.Fz({value:[h],gd:g.isFunction(e)?function(a){a&&a.ac&&(k=f(a.ac,h));e(k)}:g.noop})}else e(k)}:(a.lz=function(c,e){var f="";b.Gc()&&b.Gc().length&&(f=b.Gc()[0]);var h="select"==d&&b.ea.Zt()&&!b.ea.gi()?b.vs():null,k=null;a.Fz({dw:function(b,c,d){(b=f===a.id(d))&&(k=d);null==h&&(h=d);return b},gd:g.isFunction(e)?function(){k||"select"!==d||(k=h);e(k)}:g.noop})},a.validate=
  function(b,c){var d=null;a.Fz({dw:function(b,e,f){(b=c===a.id(f))&&(d=f);return b},gd:g.noop});return!!d});return a},mH:function(a,b,d){var e=-1,f=this;a=this.Ex();c.bt(a,function(a,b){if(f.Gc()&&f.Gc()[0]===f.id(b.data(f.xc)))return e=a,!1});!1!==d&&!0===b&&0<=e&&this.Zx(e)},fH:function(a,b,c){if(this.ala(a)){var d;b&&b.trigger&&(d={ew:{trigger:b.trigger}});this.close(c);this.Lz(0===this.id(a).length?[]:this.id(a),c,d);"blur"!==c.type&&this.pB()}},as:function(){this.search.val("")}}),f=c.zv(e,{xc:"ojcombobox",
  cb:"oj-combobox",CF:function(){return g(document.createElement("div")).attr({"class":"oj-combobox oj-component"}).html("\x3cdiv class\x3d'oj-combobox-choice' tabindex\x3d'-1' role\x3d'presentation'\x3e   \x3cinput type\x3d'text' autocomplete\x3d'off' autocorrect\x3d'off' autocapitalize\x3d'off'       spellcheck\x3d'false' class\x3d'oj-combobox-input' role\x3d'combobox' aria-expanded\x3d'false' aria-autocomplete\x3d'list' /\x3e   \x3cabbr class\x3d'oj-combobox-clear-entry' role\x3d'presentation'\x3e\x3c/abbr\x3e   \x3cspan class\x3d'oj-combobox-divider' role\x3d'presentation'\x3e\x3c/span\x3e   \x3ca class\x3d'oj-combobox-arrow oj-combobox-icon oj-component-icon oj-clickable-icon-nocontext oj-combobox-open-icon'       role\x3d'button' aria-label\x3d'expand'\x3e\x3c/a\x3e\x3c/div\x3e\x3cdiv class\x3d'oj-listbox-drop' style\x3d'display:none' role\x3d'presentation'\x3e   \x3cul class\x3d'oj-listbox-results' role\x3d'listbox'\x3e   \x3c/ul\x3e\x3c/div\x3e")},
  Ao:function(a){f.O.Ao.apply(this,arguments);this.hB?this.Ta.find(".oj-combobox-arrow").removeClass("oj-disabled"):this.Ta.find(".oj-combobox-arrow").addClass("oj-disabled")},close:function(a){this.vf()&&f.O.close.apply(this,arguments)},Es:function(a,b){f.O.Es.apply(this,arguments);b||this.pv(!0)},wo:function(a){c.Qb.X3(a)||c.Qb.a4(a)||f.O.wo.apply(this,arguments)},Jq:function(a){var b,c=[];this.selection.data(this.xc,a);null!==a&&0!=a.length?(b=this.ma.g3(a),void 0!==b&&this.search.val()!==b&&this.search.val(b),
  this.search.removeClass(this.cb+"-default"),c.push(a)):(this.search.val(""),this.Bq());this.currentItem=c;this.ma.tOa&&this.Ta.addClass(this.cb+"-allowclear")},lla:function(a){if(void 0===a||null===a)a=(a=this.Gc())?Array.isArray(a)?Array.isArray(a)&&a.length?{label:a[0]}:null:{label:a}:null;this.Jq(a)}}),h=c.zv(e,{xc:"ojselect",cb:"oj-select",Uk:!1,CF:function(){return g(document.createElement("div")).attr({"class":"oj-select oj-component"}).html("\x3cdiv class\x3d'oj-select-choice' tabindex\x3d'0' role\x3d'combobox'      aria-autocomplete\x3d'none' aria-expanded\x3d'false'\x3e  \x3cspan class\x3d'oj-select-chosen'\x3e\x3c/span\x3e  \x3cabbr class\x3d'oj-select-search-choice-close' role\x3d'presentation'\x3e\x3c/abbr\x3e  \x3ca class\x3d'oj-select-arrow oj-component-icon oj-clickable-icon-nocontext oj-select-open-icon' role\x3d'presentation'\x3e\x3c/a\x3e\x3c/div\x3e\x3cdiv class\x3d'oj-listbox-drop' style\x3d'display:none' role\x3d'dialog'\x3e  \x3cdiv class\x3d'oj-listbox-search-wrapper'\x3e  \x3cdiv class\x3d'oj-listbox-search'\x3e    \x3cinput type\x3d'text' autocomplete\x3d'off' autocorrect\x3d'off' autocapitalize\x3d'off'           spellcheck\x3d'false' class\x3d'oj-listbox-input' title\x3d'Search field'            role\x3d'combobox' aria-expanded\x3d'false' aria-autocomplete\x3d'list' /\x3e    \x3cspan class\x3d'oj-listbox-spyglass-box'\x3e      \x3cspan class\x3d'oj-component-icon oj-clickable-icon-nocontext oj-listbox-search-icon' role\x3d'presentation'\x3e       \x3cb role\x3d'presentation'\x3e\x3c/b\x3e\x3c/span\x3e    \x3c/span\x3e  \x3c/div\x3e  \x3c/div\x3e   \x3cul class\x3d'oj-listbox-results' role\x3d'listbox'\x3e   \x3c/ul\x3e\x3c/div\x3e\x3cdiv role\x3d'region' class\x3d'oj-helper-hidden-accessible oj-listbox-liveregion' aria-live\x3d'polite'\x3e\x3c/div\x3e")},
  Ao:function(a){h.O.Ao.apply(this,arguments);this.hB?(this.selection.attr("tabindex","0"),this.Ta.find(".oj-select-arrow").removeClass("oj-disabled")):(this.selection.attr("tabindex","-1"),this.Ta.find(".oj-select-arrow").addClass("oj-disabled"))},close:function(a){this.vf()&&(h.O.close.apply(this,arguments),this.selection.attr("aria-expanded",!1).removeAttr("aria-haspopup").removeAttr("aria-owns"),this.search.attr("aria-expanded",!1).removeAttr("aria-controls"),this.u1(a)||this.as(),a instanceof MouseEvent&&
  a.target!=this.selection&&a.target!=this.search||c.Ni(this,this.selection),this.Ta.find(".oj-listbox-spyglass-box").off("mouseup click"))},Es:function(a,b){h.O.Es.apply(this,arguments);var d=c.A3(a);this.g1(d);b||(d?this.pv():this.pv(!0))},tP:function(){if(this.vf()){var a="true"!==this.selection.attr("aria-expanded");h.O.tP.apply(this,arguments);a&&(this.selection.attr("aria-expanded",!0).attr("aria-haspopup","dialog").attr("aria-owns",this.ac.attr("id")),this.search.attr("aria-expanded",!0).attr("aria-controls",
  this.ac.attr("id")+" "+this.Ta.find(".oj-listbox-liveregion").attr("id")))}},eO:function(){var a=this.Vs+"_selected";this.text=this.Ta.find(".oj-select-chosen").attr("id",a);h.O.eO.apply(this,arguments);this.selection.attr({"aria-labelledby":this.search.attr("aria-labelledby"),"aria-describedby":a});(a=this.ma.element.attr("aria-label"))&&this.selection.attr("aria-label",a);this.search.on("keydown",this.De(this.wo));this.search.on("keyup-change input",this.De(this.Vya));this.search.attr("title",this.ea.R("searchField"));
  var b=this;this.selection.on("blur",function(a){b.u1(a)})},em:function(){this.Bga()?(this.Jq(null),this.close(),this.Bq()):h.O.em.apply(this,arguments)},lla:function(a){if(void 0!==a&&null!==a){var b,c=this.Gc(),c=Array.isArray(c)?c[0]:c;b=this.ma.id(a);c!==b&&this.ea.Dja(b);this.Jq(a);this.close()}},Jq:function(a){this.selection.data(this.xc,a);null!==a&&this.text.text(a.label);a&&""!=a.id&&this.text.removeClass(this.cb+"-default");this.ma.tOa&&this.Ta.addClass(this.cb+"-allowclear")},Co:function(){return this.search.attr("aria-expanded")&&
  this.GZ()?this.search:this.selection},Bga:function(){if(null===this.vs())return!1;var a=this.Gc(),a=Array.isArray(a)?a[0]:a;return""===a||void 0===a||null===a},vs:function(){return this.ma.placeholder},ika:function(){return!0},Bq:function(){var a=this.vs();this.Bga()&&void 0!==a&&(void 0===a&&(a=""),this.text.text(a).addClass(this.cb+"-default"),this.Ta.removeClass(this.cb+"-allowclear"))},Lz:function(a,b,c){h.O.Lz.call(this,a,b,c);this.selection.data("selectVal",a)},wo:function(a){if(!(c.Qb.X3(a)&&
  a.which!=c.Qb.zT||a.which==c.Qb.zT||c.Qb.a4(a))){switch(a.which){case c.Qb.TAB:this.close(a);this.selection.focus();this.u1(a);return;case c.Qb.ENTER:if(a.target===this.selection[0]&&!this.vf()){this.open(a);a.preventDefault();return}}h.O.wo.apply(this,arguments);if(this.Uk)if(this.vf()){var b=this.Dd.find(".oj-listbox-search");"true"===g(b).attr("aria-hidden")&&(b=c.A3(a))&&(this.g1(b),this.pv())}else this.open(a)}},u1:function(a){return""==this.text.text()?(this.wx(a),!0):!1}}),k=c.zv(b,{bv:function(){var a=
  k.O.bv.apply(this,arguments),b=this,d=a.element.get(0).tagName.toLowerCase();if("input"===d&&a.element.attr("list")||"select"===d&&0<a.element.children().length||a.list){var e=a.list?"li":"option";a.lz=function(a,f){var g=[];if(b.Gc())for(var h,k=b.Gc(),l=0;l<k.length;l++){var m=k[l];(h=a.find(e).filter(function(){if("option"===e)return this.value===m;if("li"===e)return this.getAttribute("oj-data-value")===m}))&&h.length?g.push(b.py(h)):"ojcombobox"===b.xc&&g.push({value:m,label:m})}else"select"!==
  d&&(h=a.find(e).filter(function(){if("option"===e)return this.selected;if("li"===e)return!0===this.getAttribute("oj-data-selected")}),c.bt(h,function(a,c){g.push(b.py(c))}));f(g)}}else"options"in a&&(a.lz=g.isFunction(a.options)?function(d,e){function f(){for(var c=[],d=0;d<k.length;d++){for(var g=k[d],h=!1,q=0;q<l.length;q++){var m=l[q];if(g===a.id(m)){c.push(m);l.splice(q,1);h=!0;break}}if(!h){if((q=b.currentItem)&&q.length)for(m=0;m<q.length;m++)if(g===a.id(q[m])){c.push(q[m]);h=!0;break}h||"ojcombobox"!==
  b.xc||c.push({value:g,label:g})}}e(c)}function h(b,c){for(var d=[],e=0,f=b.length;e<f;e++){var k=b[e];0<=c.indexOf(a.id(k))&&d.push(k);k.children&&(k=h(k.children,c))&&k.length&&g.merge(d,k)}return d}var k=b.Gc(),l=[],m=c.pna(b);m&&(l=h(m,k));b.G5?f():a.Fz({value:k,gd:function(a){a&&a.ac&&(a=h(a.ac,k))&&a.length&&g.merge(l,a);f()}})}:function(c,d){var e=b.Gc(),f=[];a.Fz({dw:function(b,c,d){(b=g.grep(e,function(b){return b===a.id(d)}).length)&&f.push(d);return b},gd:g.isFunction(d)?function(){for(var c=
  [],g=0;g<e.length;g++){for(var h=e[g],k=!1,q=0;q<f.length;q++){var l=f[q];if(h===a.id(l)){c.push(l);f.splice(q,1);k=!0;break}}k||"ojcombobox"!==b.xc||c.push({value:h,label:h})}d(c)}:g.noop})});return a},iC:function(a){var b=this.Ta.find("."+this.cb+"-selected-choice.oj-focus");b.length&&a&&a[0]==b[0]||(b.length&&this.ma.element.trigger("choice-deselected",b),b.removeClass("oj-focus"),a&&a.length&&("ojcombobox"===this.xc&&this.close(),a.addClass("oj-focus"),this.Ta.find("."+this.cb+"-description").text(a.attr("valueText")+
  ". Press back space to delete.").attr("aria-live","assertive"),this.ma.element.trigger("choice-selected",a)))},_destroy:function(){g("label[for\x3d'"+this.search.attr("id")+"']").attr("for",this.ma.element.attr("id"));k.O._destroy.apply(this,arguments)},eO:function(){var a="."+this.cb+"-choices",b,d=c.ID(),e;this.f5=this.Ta.find("."+this.cb+"-search-field");this.selection=b=this.Ta.find(a);var f=this;this.selection.on("click","."+this.cb+"-selected-choice:not(."+this.cb+"-locked)",function(){"ojcombobox"===
  this.xc&&f.search[0].focus();f.iC(g(this))});e=g("label[for\x3d'"+this.ma.element.attr("id")+"']");e.attr("id")||e.attr("id",this.cb+"-label-"+d);this.tu="ojcombobox"===this.xc?this.search:this.selection;b.find("."+this.cb+"-input").attr("id",this.cb+"-input-"+d);this.ac.attr("id")||this.ac.attr("id","oj-listbox-results-"+d);this.tu.attr("aria-owns",this.ac.attr("id"));this.tu.attr("aria-labelledby",e.attr("id"));this.ma.element.attr("aria-labelledby",e.attr("id"));this.search.attr("id")&&e.attr("for",
  this.search.attr("id"));this.ma.element.attr("aria-label")&&this.tu.attr("aria-label",this.ma.element.attr("aria-label"));this.ma.element.attr("aria-controls")&&this.tu.attr("aria-controls",this.ma.element.attr("aria-controls"));this.tu.attr("tabindex",this.U2);this.mR=0;"ojselect"===this.xc&&(this.selection.on("keydown",this.De(this.wo)),this.selection.on("keyup",this.De(function(){this.mR=0})));this.search.on("keydown",this.De(this.wo));this.search.on("keyup",this.De(function(){this.mR=0}));this.search.on("input",
  this.De(function(a){this.ea.Sl(this.search.val(),a)}));this.search.on("blur keyup",this.De(function(a){if("keyup"!==a.type||10===a.keyCode||13===a.keyCode){if(this.ma.manageNewEntry&&this.search.val()&&0>=this.ac.find(".oj-hover").length){var b=this.ma.manageNewEntry(this.search.val());this.fH(b,{trigger:"blur"===a.type?c.oA.P5:c.oA.Z5},a)}this.search.removeClass(this.cb+"-focused");this.Ta.removeClass("oj-focus");this.iC(null);this.vf()||this.as();a.stopImmediatePropagation()}}));this.Ta.on("click touchstart",
  a,this.De(function(a){!this.uq()||0<g(a.target).closest("."+this.cb+"-selected-choice").length||(this.iC(null),this.vf()?this.close(a):(this.open(a),("ojcombobox"===this.xc||this.GZ())&&this.pB()),a.preventDefault())}));this.Ta.on("focus",a,this.De(function(){}));this.Ifa();this.ma.element.hide().attr("aria-hidden",!0);this.Ta.append(this.ma.element);this.as()},wo:function(a){if(this.uq()){++this.mR;var b=this.selection.find("."+this.cb+"-selected-choice.oj-focus"),d=b.prev("."+this.cb+"-selected-choice:not(."+
  this.cb+"-locked)"),e=b.next("."+this.cb+"-selected-choice:not(."+this.cb+"-locked)"),f="ojselect"!==this.xc||this.Uk?c.ana(this.search):c.ana(this.selection);if(!b.length||a.which!=c.Qb.LEFT&&a.which!=c.Qb.RIGHT&&a.which!=c.Qb.KS&&a.which!=c.Qb.W5&&a.which!=c.Qb.ENTER)if((a.which!==c.Qb.KS||1!=this.mR)&&a.which!=c.Qb.LEFT||0!=f.offset||f.length){this.iC(null);if(this.vf()){switch(a.which){case c.Qb.UP:case c.Qb.DOWN:this.pha(a.which===c.Qb.UP?-1:1);a.preventDefault();return;case c.Qb.ENTER:this.H0(null,
  a);a.preventDefault();return;case c.Qb.TAB:this.close(a);return;case c.Qb.RS:this.hW(a);a.preventDefault();return}!1===this.Uk&&(this.Uk=!0,this.close())}if(!(a.which===c.Qb.TAB||c.Qb.X3(a)||c.Qb.a4(a)||a.which===c.Qb.RS||a.which===c.Qb.ENTER&&this.search.val()&&"ojcombobox"===this.xc)){switch(a.which){case c.Qb.UP:case c.Qb.DOWN:this.open(a);a.preventDefault();return;case c.Qb.PAGE_UP:case c.Qb.PAGE_DOWN:a.preventDefault();return;case c.Qb.ENTER:a.preventDefault();return}this.Uk=!0}}else this.iC(this.selection.find("."+
  this.cb+"-selected-choice:not(."+this.cb+"-locked)").last()),a.preventDefault();else f=b,a.which==c.Qb.LEFT&&d.length?f=d:a.which==c.Qb.RIGHT?f=e.length?e:null:a.which===c.Qb.KS?(this.V1(b.first(),a),this.dP(),f=d.length?d:e):a.which==c.Qb.W5?(this.V1(b.first(),a),this.dP(),f=e.length?e:null):a.which==c.Qb.ENTER&&(f=null),this.iC(f),a.preventDefault(),f&&f.length||this.open(a)}},gB:function(){k.O.gB.apply(this,arguments)&&this.search.prop("disabled",!this.uq())},em:function(){null!==this.Gc()&&0!==
  this.Gc().length||"oj-select"!==this.cb&&""!==this.ma.element.text()||(this.Jq([]),this.close(),this.as());if(this.Rq||null!==this.Gc()&&this.Gc().length){var a=this;this.ma.lz.call(null,this.Rq?this.Rq:this.ma.element,function(b){void 0!==b&&null!==b&&0!==b.length&&(a.Jq(b),a.close(),a.as())})}},close:function(a){this.vf()&&k.O.close.apply(this,arguments)},Ni:function(){this.close();this.search.focus()},Jq:function(a){var b=[],c=[],d=this;g(a).each(function(){0>b.indexOf(d.id(this))&&(b.push(d.id(this)),
  c.push(this))});a=c;this.selection.find("."+this.cb+"-selected-choice").remove();this.selection.find(".oj-select-default").remove();g(a).each(function(){d.Twa(this)});this.currentItem=a;this.ma.element.val(0===b.length?"":b.join(this.ma.separator));d.mH()},fH:function(a,b,d){if(this.ala(a)){var e;b&&b.trigger&&(e={ew:{trigger:b.trigger}});var f=this.id(a),h=this.Gc()?this.Gc().slice(0):[];this.ea.isValid()||(h=c.Ft(this.ma.element.val(),this.ma.separator));g(a).each(function(){0>h.indexOf(f)&&""!==
  f&&h.push(f)});this.Lz(h,d,e);!this.select&&this.ma.I2||this.mH(a,!1,!0===this.ma.I2);this.ma.I2&&(this.close(d),this.dP());b&&b.XSa||"ojcombobox"!==this.xc||this.pB()}},hW:function(a){this.close(a);"ojcombobox"===this.xc&&this.pB()},Twa:function(a){var b=!a.locked,d=g("\x3cli class\x3d'"+this.cb+"-selected-choice'\x3e    \x3cdiv\x3e\x3c/div\x3e    \x3ca href\x3d'#' onclick\x3d'return false;' role\x3d'button' aria-label\x3d'remove' class\x3d'"+this.cb+"-clear-entry       oj-component-icon oj-clickable-icon-nocontext "+
  this.cb+"-clear-entry-icon' tabindex\x3d'-1'\x3e    \x3c/a\x3e\x3c/li\x3e"),e=g("\x3cli class\x3d'"+this.cb+"-selected-choice "+this.cb+"-locked'\x3e\x3cdiv\x3e\x3c/div\x3e\x3c/li\x3e"),d=b?d:e;this.id(a);e=this.ma.g3(a);void 0!==e&&(d.find("div").addClass(this.cb+"-selected-choice-label").text(e),d.find("."+this.cb+"-clear-entry").attr("aria-label",e+" remove"),d.attr("valueText",e));if(b)d.find("."+this.cb+"-clear-entry").on("mousedown",c.oz).on("click dblclick",this.De(function(a){this.uq()&&(g(a.target).closest("."+
  this.cb+"-selected-choice").fadeOut("fast",this.De(function(){this.V1(g(a.target),a);this.selection.find("."+this.cb+"-selected-choice.oj-focus").removeClass("oj-focus");this.close(a);"ojcombobox"===this.xc&&this.pB()})).dequeue(),c.oz(a))}));d.data(this.xc,a);"ojcombobox"===this.xc?d.insertBefore(this.f5):this.selection.append(d)},V1:function(a,b){var d=this.Gc()?this.Gc().slice(0):[],e,f;a=a.closest("."+this.cb+"-selected-choice");if(0===a.length)throw"Invalid argument: "+a+". Must be ."+this.cb+
  "-selected-choice";if(e=a.data(this.xc)){for(this.ea.isValid()||(d=c.Ft(this.ma.element.val(),this.ma.separator));0<=(f=d.indexOf(this.id(e)));)d.splice(f,1),this.Lz(d,b),this.select&&this.mH();a.remove()}},mH:function(){var a=this.Gc()&&(this.ma.element.val()||this.ea.isValid())?this.Gc():[],b=this.ac.find(".oj-listbox-result"),d=this.ac.find(".oj-listbox-result-with-children"),e=this;c.bt(b,function(b,c){var d=e.id(c.data(e.xc));a&&0<=a.indexOf(d)&&(c.addClass("oj-selected"),c.find(".oj-listbox-result-selectable").addClass("oj-selected"))});
  c.bt(d,function(a,b){b.is(".oj-listbox-result-selectable")||0!==b.find(".oj-listbox-result-selectable:not(.oj-selected)").length||b.addClass("oj-selected")});0< !b.filter(".oj-listbox-result:not(.oj-selected)").length&&"oj-select"!==this.cb&&this.close()},jga:function(a){var b=this.Gc();if(!b||0==b.length)return!1;a=a.ac;for(var c=0;c<a.length;c++)if(-1==b.indexOf(this.id(a[c])))return!1;return!0},dP:function(){},Lz:function(a,b,d){var e;e=[];"string"===typeof a&&(a=c.Ft(a,this.ma.separator));for(var f=
  0;f<a.length;f++)0>e.indexOf(a[f])&&e.push(a[f]);a={Av:!1};d&&(a._context=d);this.ea.dc(e,b,a);(this.ea.isValid()||0===e.length)&&this.ma.element.val(0===e.length?"":e.join(this.ma.separator));this.search.attr("aria-activedescendant",this.ma.element.attr("id"))}}),l=c.zv(k,{xc:"ojcombobox",cb:"oj-combobox",CF:function(){return g(document.createElement("div")).attr({"class":"oj-combobox oj-combobox-multi oj-component"}).html("\x3cul class\x3d'oj-combobox-choices'\x3e  \x3cli class\x3d'oj-combobox-search-field'\x3e\x3cspan style\x3d'display:none'\x3e\x26nbsp;\x3c/span\x3e    \x3cinput type\x3d'text' role\x3d'combobox' aria-expanded\x3d'false' aria-autocomplete\x3d'list' autocomplete\x3d'off' autocorrect\x3d'off' autocapitalize\x3d'off' spellcheck\x3d'false' class\x3d'oj-combobox-input'\x3e  \x3c/li\x3e\x3c/ul\x3e\x3cdiv class\x3d'oj-combobox-description oj-helper-hidden-accessible'/\x3e\x3cdiv class\x3d'oj-listbox-drop oj-listbox-drop-multi' style\x3d'display:none'\x3e   \x3cul class\x3d'oj-listbox-results' role\x3d'listbox'\x3e   \x3c/ul\x3e\x3c/div\x3e")},
  Es:function(a,b){this.$Ka();l.O.Es.apply(this,arguments);this.pB();b||this.pv(!0);this.search.focus()},as:function(){var a=this.vs(),b=this.SCa();void 0===a||this.Gc()&&0!==this.Gc().length?(this.search.attr("placeholder",""),this.search.val("").width(10),this.f5.width("auto")):(this.search.attr("placeholder",a),this.search.val("").width(0<b?b:this.Ta.css("width")),this.f5.width("100%"))},dP:function(){this.search.width(10)},SCa:function(){return this.selection.width()-c.Jna(this.search)},mNa:function(a){var b=
  document.createElement("span");a=document.createTextNode(a);b.style.display="none";b.appendChild(a);g("body").append(b);b=g("body").find("span:last").width();g("body").find("span:last").remove();return b},$Ka:function(){var a,b,d,e,f=c.Jna(this.search);a=this.mNa(this.search.val())+10;b=this.search.offset().left;d=this.selection.width();e=this.selection.offset().left;b=d-(b-e)-f;b<a&&(b=d-f);40>b&&(b=d-f);0>=b&&(b=a);this.search.width(Math.floor(b))}}),m=c.zv(k,{xc:"ojselect",cb:"oj-select",Uk:!1,
  CF:function(){return g(document.createElement("div")).attr({"class":"oj-select oj-select-multi oj-component"}).html("\x3cul class\x3d'oj-select-choices' tabindex\x3d'0' role\x3d'combobox'   aria-autocomplete\x3d'none' aria-expanded\x3d'false'\x3e\x3c/ul\x3e\x3cdiv class\x3d'oj-listbox-drop' style\x3d'display:none' role\x3d'dialog'\x3e  \x3cdiv class\x3d'oj-listbox-search-wrapper'\x3e  \x3cdiv class\x3d'oj-listbox-search'\x3e    \x3cinput type\x3d'text' autocomplete\x3d'off' autocorrect\x3d'off' autocapitalize\x3d'off'           spellcheck\x3d'false' class\x3d'oj-listbox-input' title\x3d'Search field'            role\x3d'combobox' aria-expanded\x3d'false' aria-autocomplete\x3d'list' /\x3e    \x3cspan class\x3d'oj-listbox-spyglass-box'\x3e      \x3cspan class\x3d'oj-component-icon oj-clickable-icon-nocontext oj-listbox-search-icon' role\x3d'presentation'\x3e       \x3cb role\x3d'presentation'\x3e\x3c/b\x3e\x3c/span\x3e    \x3c/span\x3e  \x3c/div\x3e  \x3c/div\x3e   \x3cul class\x3d'oj-listbox-results' role\x3d'listbox'\x3e   \x3c/ul\x3e\x3c/div\x3e\x3cdiv role\x3d'region' class\x3d'oj-helper-hidden-accessible oj-listbox-liveregion' aria-live\x3d'polite'\x3e\x3c/div\x3e")},
  wo:function(a){m.O.wo.apply(this,arguments);this.Uk&&!this.vf()&&this.open(a)},Es:function(a,b){m.O.Es.apply(this,arguments);var d=c.A3(a);this.g1(d);b||(d?this.pv():this.pv(!0))},close:function(a){!0===this.Uk&&(this.Uk=!1);m.O.close.apply(this,arguments);!a||a instanceof MouseEvent&&a.target!=this.selection&&a.target!=this.search||c.Ni(this,this.selection)},as:function(){var a=this.vs();!a||this.Gc()&&0!==this.Gc().length||this.selection.append("\x3cli class\x3d'oj-select-default'\x3e"+a+"\x3c/li\x3e")}});
  a.ab("oj.ojCombobox",g.oj.editableValue,{defaultElement:"\x3cinput\x3e",widgetEventPrefix:"oj",options:{converter:void 0,placeholder:"",list:void 0,multiple:!1,options:null,optionsKeys:null,pickerAttributes:null,optionRenderer:null,minLength:0,beforeExpand:null,rawValue:void 0,required:!1,validators:void 0},widget:function(){return this.we.Ta},_ComponentCreate:function(){this._super();this.hb()},Sg:function(b,d){this._super(b,d);a.pa.br([{ra:"disabled",Te:!0},{ra:"placeholder"},{ra:"required",$i:!0,
  Te:!0},{ra:"title"}],d,this);if(void 0===this.options.value)this.options.value=void 0!==this.element.attr("value")?c.Ft(this.element.val(),","):null;else{var e=this.options.value;Array.isArray(e)?e=e.slice(0):"string"===typeof e&&(e=!0===this.options.multiple?c.Ft(e,","):[e]);this.options.value=e}},gi:function(){return this.options.required},Zf:a.pa.Zf,ci:a.pa.ci,Ir:a.pa.Ir,hx:a.pa.hx,sc:a.pa.sc,Lp:a.pa.Lp,hb:function(){var a={},b=this.options.multiple;a.element=this.element;a.ea=this;a=g.extend(this.options,
  a);this.we=b?new l:new f;this.we._init(a);this.ue(this.options.required)},ue:a.pa.ue,Sw:function(){return!1},_destroy:function(){this.we._destroy();this._super()},refresh:function(){this._super();this.we._destroy();this.hb();this.uL()},_setOption:function(a,b,d){"value"===a&&(Array.isArray(b)?b=b.slice(0):"string"===typeof b&&(b=!0===this.options.multiple?c.Ft(b,","):[b]),this.we.G5=d&&d._context&&d._context.ew?d._context.ew.trigger:null);this._super(a,b,d);"options"===a&&(this.we.ma.options=b,this.we.ma=
  this.we.bv(this.we.ma));"disabled"===a&&(b?this.we.bX():this.we.Ao())},Hr:function(a,b,c){this._superApply(arguments);switch(a){case "required":this.Zf(a);break;case "validators":this.ci(a);break;case "converter":this.Ir(a)}},rk:function(){this._superApply(arguments);this.we.close()},po:function(){this._superApply(arguments);this.we.close()},uk:function(){this.we.em()},du:function(a){this.we&&(this.we.ma.placeholder=a,this.we.Bq&&this.we.Bq())},validate:function(){var a=this.we.search.val(),b=null;
  !0!==this.options.multiple?b=void 0===a||null===a||""===a?[]:[a]:(b=[],this.isValid()&&(b=this.we.Gc()),void 0!==a&&null!==a&&""!==a&&b.push(a));return this.dc(b,null,this.VE)},KO:function(a){var b=[];"string"===typeof a&&(a=!0===this.options.multiple?c.Ft(a,","):[a]);if(Array.isArray(a))for(var d=0;d<a.length;d++){var e=this._super(a[d]);b.push(e.toString())}return b},_GetMessagingLauncherElement:function(){return this.we.search},hi:function(a,b,c){a=this._GetMessagingLauncherElement();this.ji(b,
  c,{launcher:a})},ag:function(){return this.we.search},_GetDefaultStyleClass:function(){return"oj-combobox"},eG:function(){if(this.we&&this.we.vf())for(var a=g(".oj-listbox-drop"),b=0;b<a.length;b++)if("oj-listbox-drop"==g(a[b]).attr("id")&&g(a[b]).attr("data-oj-containerid")==this.we.Vs)return g(a[b]);return null},Zg:function(a,b){for(var c=0;c<a.length;c++)if(g(a[c]).data("ojcombobox").value===b)return a[c];return null},getNodeBySubId:function(a){var b=null,c;if(null==a)return this.we.Ta?this.we.Ta[0]:
  null;b=this._super(a);if(!b){c=a.subId;"oj-combobox-drop"===c&&(c="oj-listbox-drop");"oj-combobox-results"===c&&(c="oj-listbox-results");"oj-combobox-selection"===c&&(c="oj-combobox-selected-choice");var d=this.eG();switch(c){case "oj-combobox-input":case "oj-combobox-arrow":b=this.widget().find("."+c)[0];break;case "oj-listitem":d&&(b=d.find(".oj-listbox-result"),b=this.Zg(b,a.value));break;case "oj-combobox-remove":b=this.widget().find(".oj-combobox-selected-choice");b=(a=this.Zg(b,a.value))?g(a).find(".oj-combobox-clear-entry-icon")[0]:
  null;break;case "oj-listbox-drop":d&&(b=d[0]);break;case "oj-listbox-results":d&&(b=d.find("."+c)[0]);break;case "oj-combobox-selected-choice":b=this.widget().find("."+c).toArray()}}return b||null},getSubIdByNode:function(a){var b=null;null!=a&&(a=g(a),a.hasClass("oj-combobox-input")?b={subId:"oj-combobox-input"}:a.hasClass("oj-combobox-arrow")?b={subId:"oj-combobox-arrow"}:a.hasClass("oj-listbox-result")?b={subId:"oj-listitem",value:a.data("ojcombobox").value}:a.hasClass("oj-combobox-clear-entry-icon")&&
  (b={subId:"oj-combobox-remove",value:a.closest(".oj-combobox-selected-choice").data("ojcombobox").value}));return b}});a.ab("oj.ojSelect",g.oj.editableValue,{defaultElement:"\x3cselect\x3e",widgetEventPrefix:"oj",options:{minimumResultsForSearch:15,placeholder:null,list:void 0,multiple:!1,options:null,optionsKeys:null,pickerAttributes:null,required:!1,beforeExpand:null,renderMode:"jet"},widget:function(){return this.select?this.select.Ta:this.element.parent()},_ComponentCreate:function(){this._super();
  this.hb()},Hr:function(a,b,c){this._superApply(arguments);switch(a){case "required":this.Zf(a)}},gi:function(){return this.options.required},Zf:a.pa.Zf,rha:function(a){a?(this.element.attr("disabled",""),this.element.parent().addClass("oj-disabled").removeClass("oj-enabled")):(this.element.removeAttr("disabled"),this.element.parent().removeClass("oj-disabled").addClass("oj-enabled"))},BIa:function(a){var b=[],c=!this.gi()&&this.Zt();g(a.target).find("option").each(function(){this.selected&&(this.value||
  c&&""===this.value)&&b.push(this.value)});this.dc(b,a,{Av:!1,_context:{kb:!0}})},DIa:function(){var a=this.element;a.wrap("\x3cdiv\x3e").parent().addClass("oj-select-native oj-component oj-select oj-form-control");a.addClass("oj-select-select oj-component-initnode");this.options.multiple?(a[0].multiple||(a[0].multiple=!0),a.parent().prepend("\x3ca class\x3d'oj-select-arrow oj-component-icon oj-clickable-icon-nocontext oj-select-multiple-open-icon' role\x3d'presentation'\x3e\x3c/a\x3e")):a.parent().prepend("\x3ca class\x3d'oj-select-arrow oj-component-icon oj-clickable-icon-nocontext oj-select-open-icon' role\x3d'presentation'\x3e\x3c/a\x3e");
  this.rha(this.options.disabled);this.options.list?(c.ESa(a,g("#"+this.options.list).children(),this.Ix.bind(this)),a.addClass(c.hE)):this.options.options&&(c.Ela(a,this.options.options,this.Ix.bind(this),this.options.optionsKeys),a.addClass(c.hE));this._focusable({element:a,applyHighlight:!0});this.options.value||this.Zt()||this.Dja(this.C_());a.change(this.BIa.bind(this))},LHa:function(){var a={},b=this.options.multiple;a.element=this.element;a.ea=this;a=g.extend(this.options,a);this.select=b?new m:
  new h;this.select._init(a);this.select.Ta.addClass("oj-select-jet oj-form-control");this._focusable({element:this.select.selection,applyHighlight:!0})},Dja:function(a){this.dc(Array.isArray(a)?a:[a],null,{Av:!1,_context:{kb:!0,yd:!0},changed:!0})},hb:function(){this.cy()?this.DIa():this.LHa();this.ue(this.options.required)},refresh:function(){this._super();this.vo();this.hb();this.uL()},ue:a.pa.ue,Sw:function(){return!1},_destroy:function(){this.vo();this._super()},rk:function(){this._superApply(arguments);
  this.select&&this.select.close()},po:function(){this._superApply(arguments);this.select&&this.select.close()},du:function(a){if(this.cy()&&null!=a){var b=g(this.element.children("option:first-child"));b&&""===b.attr("value")?(b.text(this.options.placeholder),b.attr("value","")):(b=c.O2(0,"",a,this.Ix.bind(this)),b.addClass("oj-listbox-placeholder"),this.wfa(b,this.gi()),b.prependTo(this.element))}},Zt:function(){return"string"===typeof this.options.placeholder},Q7:function(){this.q9(null);this.du(null)},
  Sg:function(b,d){this._super(b,d);a.pa.br([{ra:"disabled",Te:!0},{ra:"placeholder"},{ra:"required",$i:!0,Te:!0},{ra:"title"}],d,this);if(void 0===this.options.value)this.options.value=void 0!==this.element.attr("value")?c.Ft(this.element.val(),","):null;else{var e=this.options.value;Array.isArray(e)&&(e=e.slice(0));this.options.value=e}},validate:function(){if(!0===this.options.multiple){var a=this.select.search.val(),b=[];this.isValid()&&(b=this.select.Gc());void 0!==a&&null!==a&&""!==a&&b.push(a);
  return this.dc(b,null,this.VE)}return this.select?this.dc(this.select.Gc(),null,this.VE):!0},uk:function(a){this.select?this.select.em():null==a?this.Zt()&&(this.element[0].selectedIndex=0,this.element.addClass("oj-select-default")):this.element.val(a)},C_:function(){var a=this.element.children("option:not(:disabled)");return 0<a.length?[g(a[0]).attr("value")]:null},CIa:function(a){var b=this.options.value,d=this.element;if(d.hasClass(c.hE))c.Tla(d);else{var e=d.children();0<e.length&&e.remove()}c.Ela(d,
  a,this.Ix.bind(this),this.options.optionsKeys);d.addClass(c.hE);a=null;this.Zt()&&(this.options.required&&(a=this.C_()),this.du());null===a&&(a=this.C_());this.options.value=a;this._setOption("value",b)},DKa:function(a){for(var b,c=[],d=0;d<a.length;d++)b=a[d],null!=b&&(0<b.length?(1==c.length&&""===c[0]&&c.pop(),c.push(b)):0==c.length&&c.push(b));return c},_setOption:function(a,b,c){if("value"===a)if(this.Zt()&&b&&0==b.length)this._super(a,b,c);else{var d;this.select&&(d=this.select.Rq,d||(d=this.select.ma.element));
  Array.isArray(b)||(b=[b]);this.cy()&&(b=this.DKa(b),1==b.length&&""==b[0]?this.element.addClass("oj-select-default"):this.element.removeClass("oj-select-default"));for(var e=[],f=0;f<b.length;f++)this.select?this.select.ma.validate&&!this.select.ma.validate(d,b[f])||e.push(b[f]):0<this.element.find("option[value\x3d'"+b[f]+"']").length&&e.push(b[f]);(0<e.length||this.options.multiple)&&this._super(a,e,c)}else"placeholder"===a?this.select?(this.select.ma.placeholder=b,this.select.Bq()):(d=this.options.value,
  d&&0!==d.length&&d[0]||(this.element[0].selectedIndex=0)):"minimumResultsForSearch"===a?this.select&&(this.select.ma.minimumResultsForSearch=b):"renderMode"===a&&(this.vo(),this.options.renderMode=b,this.refresh()),this._super(a,b,c),"disabled"===a?this.select?b?this.select.bX():this.select.Ao():this.rha(b):"options"===a?this.select?(this.select.ma.options=b,this.select.ma=this.select.bv(this.select.ma),this._super("value",this.select.Gc())):this.CIa(b):"required"===a&&this.cy()&&(a=g(this.element.find(".oj-listbox-placeholder")))&&
  ""===a.attr("value")&&this.wfa(a,b)},eG:function(){if(this.select&&this.select.vf()){var a=this.select.Dd;if(a&&a.attr("data-oj-containerid")===this.select.Vs)return a}return null},wfa:function(a,b){b?(a.attr("disabled",""),a.attr("hidden","")):(a.removeAttr("disabled"),a.removeAttr("hidden"))},cy:function(){return"native"===this.options.renderMode},vo:function(){var a=this.cy();a&&this.element.parent().hasClass("oj-select-native")?(this.element.off("change"),this.element.hasClass(c.hE)&&c.Tla(this.element),
  this.element.parent().hasClass("oj-select-native")&&(this.element.parent().children(".oj-select-arrow").remove(),this.element.unwrap()),this.element.removeClass("oj-select-select oj-component-initnode"),this.element.attr({"aria-labelledby":""})):!a&&this.select&&(this.select._destroy(),this.select=void 0)},getNodeBySubId:function(a){var b=null,c;if(null==a)return(a=this.widget())?a[0]:null;if(this.cy())return null;b=this._super(a);if(!b){var d=this.eG();c=a.subId;switch(c){case "oj-select-drop":d&&
  (b=d[0]);break;case "oj-select-results":d&&(b=d.find(".oj-listbox-results")[0]);break;case "oj-select-search":d&&(b=d.find(".oj-listbox-search")[0]);break;case "oj-select-input":case "oj-listbox-input":d&&(b=d.find(".oj-listbox-input")[0]);break;case "oj-select-choice":case "oj-select-chosen":case "oj-select-arrow":b=this.widget().find("."+c)[0];break;case "oj-listitem":d&&(b=d.find(".oj-listbox-result"),b=this.select.Zg(b,a.value));break;case "oj-select-remove":b=this.widget().find(".oj-select-selected-choice");
  b=(a=this.select.Zg(b,a.value))?g(a).find(".oj-select-clear-entry-icon")[0]:null;break;case "oj-listbox-result-label":d&&(d=g("#"+this.select.ac.attr("id")).children(),a=a.index,d.length&&a<d.length&&(b=d.eq(a).find("."+c)[0]))}}return b||null},getSubIdByNode:function(a){if(this.cy())return this._super(a);var b=null;null!=a&&(a=g(a),a.hasClass("oj-listbox-input")?b={subId:"oj-select-input"}:a.hasClass("oj-select-arrow")?b={subId:"oj-select-arrow"}:a.hasClass("oj-listbox-result")?b={subId:"oj-listitem",
  value:a.data("ojselect").value}:a.hasClass("oj-select-clear-entry-icon")&&(b={subId:"oj-select-remove",value:a.closest(".oj-select-selected-choice").data("ojselect").value}));return b},_GetDefaultStyleClass:function(){return"oj-select"},_GetMessagingLauncherElement:function(){return this.select?this.select.selection:this.element},ag:function(){return this.select?this.select.selection:this.element}});a.Components.wp({ojSelect:{displayOptions:{converterHint:["none"]},renderMode:a.Components.ef(function(){return(a.vc.Hd("oj-select-option-defaults")||
  {}).renderMode})}});var p=c.zv(f,{xc:"ojinputsearch",cb:"oj-inputsearch",CF:function(){var a=g(document.createElement("div")).attr({"class":"oj-inputsearch oj-component"}).html("\x3cdiv class\x3d'oj-inputsearch-choice' tabindex\x3d'-1' role\x3d'presentation'\x3e   \x3cinput type\x3d'text' autocomplete\x3d'off' autocorrect\x3d'off' autocapitalize\x3d'off'       spellcheck\x3d'false' class\x3d'oj-inputsearch-input' role\x3d'combobox' aria-expanded\x3d'false' aria-autocomplete\x3d'list' /\x3e   \x3ca class\x3d'oj-inputsearch-search-button oj-inputsearch-search-icon oj-component-icon oj-clickable-icon-nocontext'       role\x3d'button' aria-label\x3d'search'\x3e\x3c/a\x3e\x3c/div\x3e\x3cdiv class\x3d'oj-listbox-drop' style\x3d'display:none' role\x3d'presentation'\x3e   \x3cul class\x3d'oj-listbox-results' role\x3d'listbox'\x3e   \x3c/ul\x3e\x3c/div\x3e\x3cdiv role\x3d'region' class\x3d'oj-helper-hidden-accessible oj-listbox-liveregion' aria-live\x3d'polite'\x3e\x3c/div\x3e"),
  b=a.find(".oj-inputsearch-search-button");this.wxa(b);return a},wxa:function(a){var b=this;a.on("click",function(a){if(b.uq()){if(b.ma.manageNewEntry){var d=b.search.val(),e=b.ma.manageNewEntry(d),f={trigger:c.oA.Usa},g=b.selection.data(b.xc);!g&&""!==d||g&&g.label!==d||!b.ea.isValid()&&d!==b.Uha?b.fH(e,f,a):g&&g.label===d&&(e=g);b.jI(e,f,a)}return!1}}).on("mousedown",function(a){a.stopPropagation();return!1})},Ao:function(a){p.O.Ao.apply(this,arguments);this.hB?this.Ta.find(".oj-inputsearch-search-button").removeClass("oj-disabled"):
  this.Ta.find(".oj-inputsearch-search-button").addClass("oj-disabled")},jI:function(a,b,c){var d;b&&(d=b.trigger);b={_context:{ew:{trigger:d}}};var e=this.id(a);e&&0!==e.length||(e=a.label?a.label:[]);void 0!==this.ea.oV(e,c,b)&&this.ea.isValid()&&("string"===typeof e&&(e=[e]),this.ea._trigger("update",c,{value:e,optionMetadata:{trigger:d}}))}});a.ab("oj.ojInputSearch",g.oj.editableValue,{defaultElement:"\x3cinput\x3e",widgetEventPrefix:"oj",options:{placeholder:void 0,required:!1,list:void 0,options:null,
  optionsKeys:null,pickerAttributes:null,optionRenderer:null,minLength:0,beforeExpand:null,rawValue:void 0,optionChange:null,update:null,validators:void 0},widget:function(){return this.nd.Ta},_ComponentCreate:function(){this._super();this.hb()},Sg:function(b,d){this._super(b,d);a.pa.br([{ra:"disabled",Te:!0},{ra:"placeholder"},{ra:"required",$i:!0,Te:!0},{ra:"title"}],d,this);if(void 0===this.options.value)this.options.value=void 0!==this.element.attr("value")?c.Ft(this.element.val(),","):null;else{var e=
  this.options.value;Array.isArray(e)?e=e.slice(0):"string"===typeof e&&(e=[e]);this.options.value=e}},Hr:function(a,b,c){this._superApply(arguments);switch(a){case "required":this.Zf(a);break;case "validators":this.ci(a)}},gi:function(){return this.options.required},Zf:a.pa.Zf,ci:a.pa.ci,ue:a.pa.ue,Lp:a.pa.Lp,Sw:function(){return!1},hb:function(){var a={};a.element=this.element;a.ea=this;a.nd=!0;a=g.extend(this.options,a);this.nd=new p;this.nd._init(a);this.ue(this.options.required)},_destroy:function(){this.nd._destroy();
  this._super()},refresh:function(){this._super();this.nd._destroy();this.hb();this.uL()},_setOption:function(b,c,d){"value"===b&&(null!=c&&(Array.isArray(c)?c=c.slice(0):"string"===typeof c?c=[c]:a.C.error("ojInputSearch value has to be an array of string or a string.")),this.nd.G5=d&&d._context&&d._context.ew?d._context.ew.trigger:null);this._super(b,c,d);"options"===b&&(this.nd.ma.options=c,this.nd.ma=this.nd.bv(this.nd.ma));"disabled"===b&&(c?this.nd.bX():this.nd.Ao())},rk:function(){this._superApply(arguments);
  this.nd.close()},po:function(){this._superApply(arguments);this.nd.close()},uk:function(){this.nd.em()},du:function(a){this.nd&&(this.nd.ma.placeholder=a,this.nd.Bq&&this.nd.Bq())},validate:function(){var a=this.nd.search.val(),b=null,b=[];this.isValid()&&(b=this.nd.Gc());b=void 0===a||null===a||""===a?b:[a];return this.dc(b,null,this.VE)},KO:function(b){var c=[];if(null==b)return c;if(Array.isArray(b))for(var d=0;d<b.length;d++){var e=this._super(b[d]);c.push(e.toString())}else"string"===typeof b?
  (e=this._super(b),c.push(e.toString())):a.C.error("ojInputSearch value has to be an array of string or a string.");return c},_GetMessagingLauncherElement:function(){return this.nd.search},ag:function(){return this.nd.search},_GetDefaultStyleClass:function(){return"oj-inputsearch"},eG:function(){if(this.nd&&this.nd.vf())for(var a=g(".oj-listbox-drop"),b=0;b<a.length;b++)if("oj-listbox-drop"==g(a[b]).attr("id")&&g(a[b]).attr("data-oj-containerid")==this.nd.Vs)return g(a[b]);return null},expand:function(){this.nd.open()},
  collapse:function(){this.nd.close()},getNodeBySubId:function(a){var b=null,c;if(null===a)return this.nd.Ta?this.nd.Ta[0]:null;b=this._super(a);if(!b)switch(c=a.subId,"oj-inputsearch-search"===c&&(c="oj-inputsearch-search-button"),c){case "oj-inputsearch-input":case "oj-inputsearch-search-button":b=this.widget().find("."+c)[0];break;case "oj-listitem":if(c=this.eG())b=c.find(".oj-listbox-result"),b=this.nd.Zg(b,a.value)}return b||null},getSubIdByNode:function(a){var b=null;null!=a&&(a=g(a),a.hasClass("oj-inputsearch-input")?
  b={subId:"oj-inputsearch-input"}:a.hasClass("oj-inputsearch-search-button")?b={subId:"oj-inputsearch-search"}:a.hasClass("oj-listbox-result")&&(b={subId:"oj-listitem",value:a.data("ojinputsearch").value}));return b}});a.U.qb("oj-combobox","editableValue",{properties:{converter:{type:"Object"},list:{type:"string"},minLength:{type:"number"},multiple:{type:"boolean"},optionRenderer:{},options:{type:"Array"},optionsKeys:{type:"Object"},pickerAttributes:{type:"Object"},placeholder:{type:"string"},rawValue:{type:"string",
  readOnly:!0,writeback:!0},required:{type:"boolean"},value:{type:"string|Array",writeback:!0},validators:{type:"Array"}},methods:{getNodeBySubId:{},getSubIdByNode:{},refresh:{},validate:{},widget:{}},extension:{Rg:"input",nb:"ojCombobox"}});a.U.register("oj-combobox",{metadata:a.U.getMetadata("oj-combobox")});a.U.qb("oj-input-search","editableValue",{properties:{list:{type:"string"},minLength:{type:"number"},optionRenderer:{},options:{type:"Array"},optionsKeys:{type:"Object"},pickerAttributes:{type:"Object"},
  placeholder:{type:"string"},rawValue:{type:"string",readOnly:!0,writeback:!0},required:{type:"boolean"},value:{type:"string|Array",writeback:!0},validators:{type:"Array"}},methods:{getNodeBySubId:{},collapse:{},expand:{},getSubIdByNode:{},refresh:{},validate:{},widget:{}},extension:{Rg:"input",nb:"ojInputSearch"}});a.U.register("oj-input-search",{metadata:a.U.getMetadata("oj-input-search")});a.U.qb("oj-select","editableValue",{properties:{list:{type:"string"},minimumResultsForSearch:{type:"number"},
  multiple:{type:"boolean"},options:{type:"Array"},optionsKeys:{type:"Object"},pickerAttributes:{type:"Object"},placeholder:{type:"string"},renderMode:{type:"string"},required:{type:"boolean"},value:{type:"Array",writeback:!0}},methods:{getNodeBySubId:{},getSubIdByNode:{},refresh:{},validate:{},widget:{}},extension:{Rg:"select",nb:"ojSelect"}});a.U.register("oj-select",{metadata:a.U.getMetadata("oj-select")})});