Changeset 3010711
- Timestamp:
- 12/15/2023 11:11:24 PM (2 years ago)
- Location:
- humix/trunk
- Files:
-
- 4 edited
-
humix-block/build/index.asset.php (modified) (1 diff)
-
humix-block/build/index.js (modified) (1 diff)
-
humix-block/src/edit.js (modified) (17 diffs)
-
humix.php (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
humix/trunk/humix-block/build/index.asset.php
r2972825 r3010711 1 <?php return array('dependencies' => array('react', 'wp-api-fetch', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-data', 'wp-element', 'wp-i18n'), 'version' => ' 6c2333e57623ed635cb2');1 <?php return array('dependencies' => array('react', 'wp-api-fetch', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-data', 'wp-element', 'wp-i18n'), 'version' => 'aeb73136a444c7daedfc'); -
humix/trunk/humix-block/build/index.js
r2972825 r3010711 1 !function(){var e,t={5758:function(e,t,r){"use strict";var n=window.wp.blocks,i=window.wp.element;function o(){return o=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},o.apply(this,arguments)}window.wp.i18n;var l=r(9196),a=r(1038),s=r.n(a),c=r(8446),d=r.n(c);class u extends l.Component{constructor(e){super(e),this.state={data:e.data}}componentWillReceiveProps=e=>{d()(e.data,this.state.data)||this.setState({data:e.data})};shouldComponentUpdate=e=>!d()(e.data,this.state.data);render(){const{data:e,...t}=this.props;return(0,i.createElement)(s(),o({data:this.state.data},t))}}var p=window.wp.blockEditor,b=window.wp.components,f=window.wp.data,h=window.wp.apiFetch,y=r.n(h);function m(e,t){return function(){return e.apply(t,arguments)}}const{toString:g}=Object.prototype,{getPrototypeOf:v}=Object,O=(w=Object.create(null),e=>{const t=g.call(e);return w[t]||(w[t]=t.slice(8,-1).toLowerCase())});var w;const S=e=>(e=e.toLowerCase(),t=>O(t)===e),E=e=>t=>typeof t===e,{isArray:P}=Array,C=E("undefined"),x=S("ArrayBuffer"),T=E("string"),k=E("function"),j=E("number"),_=e=>null!==e&&"object"==typeof e,R=e=>{if("object"!==O(e))return!1;const t=v(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)},A=S("Date"),D=S("File"),M=S("Blob"),N=S("FileList"),B=S("URLSearchParams");function F(e,t,{allOwnKeys:r=!1}={}){if(null==e)return;let n,i;if("object"!=typeof e&&(e=[e]),P(e))for(n=0,i=e.length;n<i;n++)t.call(null,e[n],n,e);else{const i=r?Object.getOwnPropertyNames(e):Object.keys(e),o=i.length;let l;for(n=0;n<o;n++)l=i[n],t.call(null,e[l],l,e)}}function I(e,t){t=t.toLowerCase();const r=Object.keys(e);let n,i=r.length;for(;i-- >0;)if(n=r[i],t===n.toLowerCase())return n;return null}const L="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,H=e=>!C(e)&&e!==L,V=(U="undefined"!=typeof Uint8Array&&v(Uint8Array),e=>U&&e instanceof U);var U;const G=S("HTMLFormElement"),q=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),W=S("RegExp"),z=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),n={};F(r,((r,i)=>{!1!==t(r,i,e)&&(n[i]=r)})),Object.defineProperties(e,n)},$="abcdefghijklmnopqrstuvwxyz",K="0123456789",Y={DIGIT:K,ALPHA:$,ALPHA_DIGIT:$+$.toUpperCase()+K},J=S("AsyncFunction");var Q={isArray:P,isArrayBuffer:x,isBuffer:function(e){return null!==e&&!C(e)&&null!==e.constructor&&!C(e.constructor)&&k(e.constructor.isBuffer)&&e.constructor.isBuffer(e)},isFormData:e=>{let t;return e&&("function"==typeof FormData&&e instanceof FormData||k(e.append)&&("formdata"===(t=O(e))||"object"===t&&k(e.toString)&&"[object FormData]"===e.toString()))},isArrayBufferView:function(e){let t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&x(e.buffer),t},isString:T,isNumber:j,isBoolean:e=>!0===e||!1===e,isObject:_,isPlainObject:R,isUndefined:C,isDate:A,isFile:D,isBlob:M,isRegExp:W,isFunction:k,isStream:e=>_(e)&&k(e.pipe),isURLSearchParams:B,isTypedArray:V,isFileList:N,forEach:F,merge:function e(){const{caseless:t}=H(this)&&this||{},r={},n=(n,i)=>{const o=t&&I(r,i)||i;R(r[o])&&R(n)?r[o]=e(r[o],n):R(n)?r[o]=e({},n):P(n)?r[o]=n.slice():r[o]=n};for(let e=0,t=arguments.length;e<t;e++)arguments[e]&&F(arguments[e],n);return r},extend:(e,t,r,{allOwnKeys:n}={})=>(F(t,((t,n)=>{r&&k(t)?e[n]=m(t,r):e[n]=t}),{allOwnKeys:n}),e),trim:e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:e=>(65279===e.charCodeAt(0)&&(e=e.slice(1)),e),inherits:(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},toFlatObject:(e,t,r,n)=>{let i,o,l;const a={};if(t=t||{},null==e)return t;do{for(i=Object.getOwnPropertyNames(e),o=i.length;o-- >0;)l=i[o],n&&!n(l,e,t)||a[l]||(t[l]=e[l],a[l]=!0);e=!1!==r&&v(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},kindOf:O,kindOfTest:S,endsWith:(e,t,r)=>{e=String(e),(void 0===r||r>e.length)&&(r=e.length),r-=t.length;const n=e.indexOf(t,r);return-1!==n&&n===r},toArray:e=>{if(!e)return null;if(P(e))return e;let t=e.length;if(!j(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},forEachEntry:(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let n;for(;(n=r.next())&&!n.done;){const r=n.value;t.call(e,r[0],r[1])}},matchAll:(e,t)=>{let r;const n=[];for(;null!==(r=e.exec(t));)n.push(r);return n},isHTMLForm:G,hasOwnProperty:q,hasOwnProp:q,reduceDescriptors:z,freezeMethods:e=>{z(e,((t,r)=>{if(k(e)&&-1!==["arguments","caller","callee"].indexOf(r))return!1;const n=e[r];k(n)&&(t.enumerable=!1,"writable"in t?t.writable=!1:t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")}))}))},toObjectSet:(e,t)=>{const r={},n=e=>{e.forEach((e=>{r[e]=!0}))};return P(e)?n(e):n(String(e).split(t)),r},toCamelCase:e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,(function(e,t,r){return t.toUpperCase()+r})),noop:()=>{},toFiniteNumber:(e,t)=>(e=+e,Number.isFinite(e)?e:t),findKey:I,global:L,isContextDefined:H,ALPHABET:Y,generateString:(e=16,t=Y.ALPHA_DIGIT)=>{let r="";const{length:n}=t;for(;e--;)r+=t[Math.random()*n|0];return r},isSpecCompliantForm:function(e){return!!(e&&k(e.append)&&"FormData"===e[Symbol.toStringTag]&&e[Symbol.iterator])},toJSONObject:e=>{const t=new Array(10),r=(e,n)=>{if(_(e)){if(t.indexOf(e)>=0)return;if(!("toJSON"in e)){t[n]=e;const i=P(e)?[]:{};return F(e,((e,t)=>{const o=r(e,n+1);!C(o)&&(i[t]=o)})),t[n]=void 0,i}}return e};return r(e,0)},isAsyncFn:J,isThenable:e=>e&&(_(e)||k(e))&&k(e.then)&&k(e.catch)};function X(e,t,r,n,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack,this.message=e,this.name="AxiosError",t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),i&&(this.response=i)}Q.inherits(X,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:Q.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const Z=X.prototype,ee={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach((e=>{ee[e]={value:e}})),Object.defineProperties(X,ee),Object.defineProperty(Z,"isAxiosError",{value:!0}),X.from=(e,t,r,n,i,o)=>{const l=Object.create(Z);return Q.toFlatObject(e,l,(function(e){return e!==Error.prototype}),(e=>"isAxiosError"!==e)),X.call(l,e.message,t,r,n,i),l.cause=e,l.name=e.name,o&&Object.assign(l,o),l};var te=X;function re(e){return Q.isPlainObject(e)||Q.isArray(e)}function ne(e){return Q.endsWith(e,"[]")?e.slice(0,-2):e}function ie(e,t,r){return e?e.concat(t).map((function(e,t){return e=ne(e),!r&&t?"["+e+"]":e})).join(r?".":""):t}const oe=Q.toFlatObject(Q,{},null,(function(e){return/^is[A-Z]/.test(e)}));var le=function(e,t,r){if(!Q.isObject(e))throw new TypeError("target must be an object");t=t||new FormData;const n=(r=Q.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(e,t){return!Q.isUndefined(t[e])}))).metaTokens,i=r.visitor||c,o=r.dots,l=r.indexes,a=(r.Blob||"undefined"!=typeof Blob&&Blob)&&Q.isSpecCompliantForm(t);if(!Q.isFunction(i))throw new TypeError("visitor must be a function");function s(e){if(null===e)return"";if(Q.isDate(e))return e.toISOString();if(!a&&Q.isBlob(e))throw new te("Blob is not supported. Use a Buffer instead.");return Q.isArrayBuffer(e)||Q.isTypedArray(e)?a&&"function"==typeof Blob?new Blob([e]):Buffer.from(e):e}function c(e,r,i){let a=e;if(e&&!i&&"object"==typeof e)if(Q.endsWith(r,"{}"))r=n?r:r.slice(0,-2),e=JSON.stringify(e);else if(Q.isArray(e)&&function(e){return Q.isArray(e)&&!e.some(re)}(e)||(Q.isFileList(e)||Q.endsWith(r,"[]"))&&(a=Q.toArray(e)))return r=ne(r),a.forEach((function(e,n){!Q.isUndefined(e)&&null!==e&&t.append(!0===l?ie([r],n,o):null===l?r:r+"[]",s(e))})),!1;return!!re(e)||(t.append(ie(i,r,o),s(e)),!1)}const d=[],u=Object.assign(oe,{defaultVisitor:c,convertValue:s,isVisitable:re});if(!Q.isObject(e))throw new TypeError("data must be an object");return function e(r,n){if(!Q.isUndefined(r)){if(-1!==d.indexOf(r))throw Error("Circular reference detected in "+n.join("."));d.push(r),Q.forEach(r,(function(r,o){!0===(!(Q.isUndefined(r)||null===r)&&i.call(t,r,Q.isString(o)?o.trim():o,n,u))&&e(r,n?n.concat(o):[o])})),d.pop()}}(e),t};function ae(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,(function(e){return t[e]}))}function se(e,t){this._pairs=[],e&&le(e,this,t)}const ce=se.prototype;ce.append=function(e,t){this._pairs.push([e,t])},ce.toString=function(e){const t=e?function(t){return e.call(this,t,ae)}:ae;return this._pairs.map((function(e){return t(e[0])+"="+t(e[1])}),"").join("&")};var de=se;function ue(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function pe(e,t,r){if(!t)return e;const n=r&&r.encode||ue,i=r&&r.serialize;let o;if(o=i?i(t,r):Q.isURLSearchParams(t)?t.toString():new de(t,r).toString(n),o){const t=e.indexOf("#");-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+o}return e}var be=class{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!r&&r.synchronous,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){Q.forEach(this.handlers,(function(t){null!==t&&e(t)}))}},fe={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},he={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:de,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},isStandardBrowserEnv:(()=>{let e;return("undefined"==typeof navigator||"ReactNative"!==(e=navigator.product)&&"NativeScript"!==e&&"NS"!==e)&&"undefined"!=typeof window&&"undefined"!=typeof document})(),isStandardBrowserWebWorkerEnv:"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,protocols:["http","https","file","blob","url","data"]},ye=function(e){function t(e,r,n,i){let o=e[i++];const l=Number.isFinite(+o),a=i>=e.length;return o=!o&&Q.isArray(n)?n.length:o,a?(Q.hasOwnProp(n,o)?n[o]=[n[o],r]:n[o]=r,!l):(n[o]&&Q.isObject(n[o])||(n[o]=[]),t(e,r,n[o],i)&&Q.isArray(n[o])&&(n[o]=function(e){const t={},r=Object.keys(e);let n;const i=r.length;let o;for(n=0;n<i;n++)o=r[n],t[o]=e[o];return t}(n[o])),!l)}if(Q.isFormData(e)&&Q.isFunction(e.entries)){const r={};return Q.forEachEntry(e,((e,n)=>{t(function(e){return Q.matchAll(/\w+|\[(\w*)]/g,e).map((e=>"[]"===e[0]?"":e[1]||e[0]))}(e),n,r,0)})),r}return null};const me={"Content-Type":void 0},ge={transitional:fe,adapter:["xhr","http"],transformRequest:[function(e,t){const r=t.getContentType()||"",n=r.indexOf("application/json")>-1,i=Q.isObject(e);if(i&&Q.isHTMLForm(e)&&(e=new FormData(e)),Q.isFormData(e))return n&&n?JSON.stringify(ye(e)):e;if(Q.isArrayBuffer(e)||Q.isBuffer(e)||Q.isStream(e)||Q.isFile(e)||Q.isBlob(e))return e;if(Q.isArrayBufferView(e))return e.buffer;if(Q.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let o;if(i){if(r.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return le(e,new he.classes.URLSearchParams,Object.assign({visitor:function(e,t,r,n){return he.isNode&&Q.isBuffer(e)?(this.append(t,e.toString("base64")),!1):n.defaultVisitor.apply(this,arguments)}},t))}(e,this.formSerializer).toString();if((o=Q.isFileList(e))||r.indexOf("multipart/form-data")>-1){const t=this.env&&this.env.FormData;return le(o?{"files[]":e}:e,t&&new t,this.formSerializer)}}return i||n?(t.setContentType("application/json",!1),function(e,t,r){if(Q.isString(e))try{return(0,JSON.parse)(e),Q.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(0,JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){const t=this.transitional||ge.transitional,r=t&&t.forcedJSONParsing,n="json"===this.responseType;if(e&&Q.isString(e)&&(r&&!this.responseType||n)){const r=!(t&&t.silentJSONParsing)&&n;try{return JSON.parse(e)}catch(e){if(r){if("SyntaxError"===e.name)throw te.from(e,te.ERR_BAD_RESPONSE,this,null,this.response);throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:he.classes.FormData,Blob:he.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};Q.forEach(["delete","get","head"],(function(e){ge.headers[e]={}})),Q.forEach(["post","put","patch"],(function(e){ge.headers[e]=Q.merge(me)}));var ve=ge;const Oe=Q.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),we=Symbol("internals");function Se(e){return e&&String(e).trim().toLowerCase()}function Ee(e){return!1===e||null==e?e:Q.isArray(e)?e.map(Ee):String(e)}function Pe(e,t,r,n,i){return Q.isFunction(n)?n.call(this,t,r):(i&&(t=r),Q.isString(t)?Q.isString(n)?-1!==t.indexOf(n):Q.isRegExp(n)?n.test(t):void 0:void 0)}class Ce{constructor(e){e&&this.set(e)}set(e,t,r){const n=this;function i(e,t,r){const i=Se(t);if(!i)throw new Error("header name must be a non-empty string");const o=Q.findKey(n,i);(!o||void 0===n[o]||!0===r||void 0===r&&!1!==n[o])&&(n[o||t]=Ee(e))}const o=(e,t)=>Q.forEach(e,((e,r)=>i(e,r,t)));return Q.isPlainObject(e)||e instanceof this.constructor?o(e,t):Q.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim())?o((e=>{const t={};let r,n,i;return e&&e.split("\n").forEach((function(e){i=e.indexOf(":"),r=e.substring(0,i).trim().toLowerCase(),n=e.substring(i+1).trim(),!r||t[r]&&Oe[r]||("set-cookie"===r?t[r]?t[r].push(n):t[r]=[n]:t[r]=t[r]?t[r]+", "+n:n)})),t})(e),t):null!=e&&i(t,e,r),this}get(e,t){if(e=Se(e)){const r=Q.findKey(this,e);if(r){const e=this[r];if(!t)return e;if(!0===t)return function(e){const t=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(e);)t[n[1]]=n[2];return t}(e);if(Q.isFunction(t))return t.call(this,e,r);if(Q.isRegExp(t))return t.exec(e);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=Se(e)){const r=Q.findKey(this,e);return!(!r||void 0===this[r]||t&&!Pe(0,this[r],r,t))}return!1}delete(e,t){const r=this;let n=!1;function i(e){if(e=Se(e)){const i=Q.findKey(r,e);!i||t&&!Pe(0,r[i],i,t)||(delete r[i],n=!0)}}return Q.isArray(e)?e.forEach(i):i(e),n}clear(e){const t=Object.keys(this);let r=t.length,n=!1;for(;r--;){const i=t[r];e&&!Pe(0,this[i],i,e,!0)||(delete this[i],n=!0)}return n}normalize(e){const t=this,r={};return Q.forEach(this,((n,i)=>{const o=Q.findKey(r,i);if(o)return t[o]=Ee(n),void delete t[i];const l=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,((e,t,r)=>t.toUpperCase()+r))}(i):String(i).trim();l!==i&&delete t[i],t[l]=Ee(n),r[l]=!0})),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return Q.forEach(this,((r,n)=>{null!=r&&!1!==r&&(t[n]=e&&Q.isArray(r)?r.join(", "):r)})),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map((([e,t])=>e+": "+t)).join("\n")}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const r=new this(e);return t.forEach((e=>r.set(e))),r}static accessor(e){const t=(this[we]=this[we]={accessors:{}}).accessors,r=this.prototype;function n(e){const n=Se(e);t[n]||(function(e,t){const r=Q.toCamelCase(" "+t);["get","set","has"].forEach((n=>{Object.defineProperty(e,n+r,{value:function(e,r,i){return this[n].call(this,t,e,r,i)},configurable:!0})}))}(r,e),t[n]=!0)}return Q.isArray(e)?e.forEach(n):n(e),this}}Ce.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),Q.freezeMethods(Ce.prototype),Q.freezeMethods(Ce);var xe=Ce;function Te(e,t){const r=this||ve,n=t||r,i=xe.from(n.headers);let o=n.data;return Q.forEach(e,(function(e){o=e.call(r,o,i.normalize(),t?t.status:void 0)})),i.normalize(),o}function ke(e){return!(!e||!e.__CANCEL__)}function je(e,t,r){te.call(this,null==e?"canceled":e,te.ERR_CANCELED,t,r),this.name="CanceledError"}Q.inherits(je,te,{__CANCEL__:!0});var _e=je,Re=he.isStandardBrowserEnv?{write:function(e,t,r,n,i,o){const l=[];l.push(e+"="+encodeURIComponent(t)),Q.isNumber(r)&&l.push("expires="+new Date(r).toGMTString()),Q.isString(n)&&l.push("path="+n),Q.isString(i)&&l.push("domain="+i),!0===o&&l.push("secure"),document.cookie=l.join("; ")},read:function(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}};function Ae(e,t){return e&&!/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)?function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}(e,t):t}var De=he.isStandardBrowserEnv?function(){const e=/(msie|trident)/i.test(navigator.userAgent),t=document.createElement("a");let r;function n(r){let n=r;return e&&(t.setAttribute("href",n),n=t.href),t.setAttribute("href",n),{href:t.href,protocol:t.protocol?t.protocol.replace(/:$/,""):"",host:t.host,search:t.search?t.search.replace(/^\?/,""):"",hash:t.hash?t.hash.replace(/^#/,""):"",hostname:t.hostname,port:t.port,pathname:"/"===t.pathname.charAt(0)?t.pathname:"/"+t.pathname}}return r=n(window.location.href),function(e){const t=Q.isString(e)?n(e):e;return t.protocol===r.protocol&&t.host===r.host}}():function(){return!0};function Me(e,t){let r=0;const n=function(e,t){e=e||10;const r=new Array(e),n=new Array(e);let i,o=0,l=0;return t=void 0!==t?t:1e3,function(a){const s=Date.now(),c=n[l];i||(i=s),r[o]=a,n[o]=s;let d=l,u=0;for(;d!==o;)u+=r[d++],d%=e;if(o=(o+1)%e,o===l&&(l=(l+1)%e),s-i<t)return;const p=c&&s-c;return p?Math.round(1e3*u/p):void 0}}(50,250);return i=>{const o=i.loaded,l=i.lengthComputable?i.total:void 0,a=o-r,s=n(a);r=o;const c={loaded:o,total:l,progress:l?o/l:void 0,bytes:a,rate:s||void 0,estimated:s&&l&&o<=l?(l-o)/s:void 0,event:i};c[t?"download":"upload"]=!0,e(c)}}const Ne={http:null,xhr:"undefined"!=typeof XMLHttpRequest&&function(e){return new Promise((function(t,r){let n=e.data;const i=xe.from(e.headers).normalize(),o=e.responseType;let l;function a(){e.cancelToken&&e.cancelToken.unsubscribe(l),e.signal&&e.signal.removeEventListener("abort",l)}Q.isFormData(n)&&(he.isStandardBrowserEnv||he.isStandardBrowserWebWorkerEnv?i.setContentType(!1):i.setContentType("multipart/form-data;",!1));let s=new XMLHttpRequest;if(e.auth){const t=e.auth.username||"",r=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";i.set("Authorization","Basic "+btoa(t+":"+r))}const c=Ae(e.baseURL,e.url);function d(){if(!s)return;const n=xe.from("getAllResponseHeaders"in s&&s.getAllResponseHeaders());!function(e,t,r){const n=r.config.validateStatus;r.status&&n&&!n(r.status)?t(new te("Request failed with status code "+r.status,[te.ERR_BAD_REQUEST,te.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r)):e(r)}((function(e){t(e),a()}),(function(e){r(e),a()}),{data:o&&"text"!==o&&"json"!==o?s.response:s.responseText,status:s.status,statusText:s.statusText,headers:n,config:e,request:s}),s=null}if(s.open(e.method.toUpperCase(),pe(c,e.params,e.paramsSerializer),!0),s.timeout=e.timeout,"onloadend"in s?s.onloadend=d:s.onreadystatechange=function(){s&&4===s.readyState&&(0!==s.status||s.responseURL&&0===s.responseURL.indexOf("file:"))&&setTimeout(d)},s.onabort=function(){s&&(r(new te("Request aborted",te.ECONNABORTED,e,s)),s=null)},s.onerror=function(){r(new te("Network Error",te.ERR_NETWORK,e,s)),s=null},s.ontimeout=function(){let t=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const n=e.transitional||fe;e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),r(new te(t,n.clarifyTimeoutError?te.ETIMEDOUT:te.ECONNABORTED,e,s)),s=null},he.isStandardBrowserEnv){const t=(e.withCredentials||De(c))&&e.xsrfCookieName&&Re.read(e.xsrfCookieName);t&&i.set(e.xsrfHeaderName,t)}void 0===n&&i.setContentType(null),"setRequestHeader"in s&&Q.forEach(i.toJSON(),(function(e,t){s.setRequestHeader(t,e)})),Q.isUndefined(e.withCredentials)||(s.withCredentials=!!e.withCredentials),o&&"json"!==o&&(s.responseType=e.responseType),"function"==typeof e.onDownloadProgress&&s.addEventListener("progress",Me(e.onDownloadProgress,!0)),"function"==typeof e.onUploadProgress&&s.upload&&s.upload.addEventListener("progress",Me(e.onUploadProgress)),(e.cancelToken||e.signal)&&(l=t=>{s&&(r(!t||t.type?new _e(null,e,s):t),s.abort(),s=null)},e.cancelToken&&e.cancelToken.subscribe(l),e.signal&&(e.signal.aborted?l():e.signal.addEventListener("abort",l)));const u=function(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}(c);u&&-1===he.protocols.indexOf(u)?r(new te("Unsupported protocol "+u+":",te.ERR_BAD_REQUEST,e)):s.send(n||null)}))}};Q.forEach(Ne,((e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(e){}Object.defineProperty(e,"adapterName",{value:t})}}));function Be(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new _e(null,e)}function Fe(e){return Be(e),e.headers=xe.from(e.headers),e.data=Te.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1),(e=>{e=Q.isArray(e)?e:[e];const{length:t}=e;let r,n;for(let i=0;i<t&&(r=e[i],!(n=Q.isString(r)?Ne[r.toLowerCase()]:r));i++);if(!n){if(!1===n)throw new te(`Adapter ${r} is not supported by the environment`,"ERR_NOT_SUPPORT");throw new Error(Q.hasOwnProp(Ne,r)?`Adapter '${r}' is not available in the build`:`Unknown adapter '${r}'`)}if(!Q.isFunction(n))throw new TypeError("adapter is not a function");return n})(e.adapter||ve.adapter)(e).then((function(t){return Be(e),t.data=Te.call(e,e.transformResponse,t),t.headers=xe.from(t.headers),t}),(function(t){return ke(t)||(Be(e),t&&t.response&&(t.response.data=Te.call(e,e.transformResponse,t.response),t.response.headers=xe.from(t.response.headers))),Promise.reject(t)}))}const Ie=e=>e instanceof xe?e.toJSON():e;function Le(e,t){t=t||{};const r={};function n(e,t,r){return Q.isPlainObject(e)&&Q.isPlainObject(t)?Q.merge.call({caseless:r},e,t):Q.isPlainObject(t)?Q.merge({},t):Q.isArray(t)?t.slice():t}function i(e,t,r){return Q.isUndefined(t)?Q.isUndefined(e)?void 0:n(void 0,e,r):n(e,t,r)}function o(e,t){if(!Q.isUndefined(t))return n(void 0,t)}function l(e,t){return Q.isUndefined(t)?Q.isUndefined(e)?void 0:n(void 0,e):n(void 0,t)}function a(r,i,o){return o in t?n(r,i):o in e?n(void 0,r):void 0}const s={url:o,method:o,data:o,baseURL:l,transformRequest:l,transformResponse:l,paramsSerializer:l,timeout:l,timeoutMessage:l,withCredentials:l,adapter:l,responseType:l,xsrfCookieName:l,xsrfHeaderName:l,onUploadProgress:l,onDownloadProgress:l,decompress:l,maxContentLength:l,maxBodyLength:l,beforeRedirect:l,transport:l,httpAgent:l,httpsAgent:l,cancelToken:l,socketPath:l,responseEncoding:l,validateStatus:a,headers:(e,t)=>i(Ie(e),Ie(t),!0)};return Q.forEach(Object.keys(Object.assign({},e,t)),(function(n){const o=s[n]||i,l=o(e[n],t[n],n);Q.isUndefined(l)&&o!==a||(r[n]=l)})),r}const He={};["object","boolean","number","function","string","symbol"].forEach(((e,t)=>{He[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}}));const Ve={};He.transitional=function(e,t,r){function n(e,t){return"[Axios v1.4.0] Transitional option '"+e+"'"+t+(r?". "+r:"")}return(r,i,o)=>{if(!1===e)throw new te(n(i," has been removed"+(t?" in "+t:"")),te.ERR_DEPRECATED);return t&&!Ve[i]&&(Ve[i]=!0,console.warn(n(i," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(r,i,o)}};var Ue={assertOptions:function(e,t,r){if("object"!=typeof e)throw new te("options must be an object",te.ERR_BAD_OPTION_VALUE);const n=Object.keys(e);let i=n.length;for(;i-- >0;){const o=n[i],l=t[o];if(l){const t=e[o],r=void 0===t||l(t,o,e);if(!0!==r)throw new te("option "+o+" must be "+r,te.ERR_BAD_OPTION_VALUE)}else if(!0!==r)throw new te("Unknown option "+o,te.ERR_BAD_OPTION)}},validators:He};const Ge=Ue.validators;class qe{constructor(e){this.defaults=e,this.interceptors={request:new be,response:new be}}request(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},t=Le(this.defaults,t);const{transitional:r,paramsSerializer:n,headers:i}=t;let o;void 0!==r&&Ue.assertOptions(r,{silentJSONParsing:Ge.transitional(Ge.boolean),forcedJSONParsing:Ge.transitional(Ge.boolean),clarifyTimeoutError:Ge.transitional(Ge.boolean)},!1),null!=n&&(Q.isFunction(n)?t.paramsSerializer={serialize:n}:Ue.assertOptions(n,{encode:Ge.function,serialize:Ge.function},!0)),t.method=(t.method||this.defaults.method||"get").toLowerCase(),o=i&&Q.merge(i.common,i[t.method]),o&&Q.forEach(["delete","get","head","post","put","patch","common"],(e=>{delete i[e]})),t.headers=xe.concat(o,i);const l=[];let a=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(a=a&&e.synchronous,l.unshift(e.fulfilled,e.rejected))}));const s=[];let c;this.interceptors.response.forEach((function(e){s.push(e.fulfilled,e.rejected)}));let d,u=0;if(!a){const e=[Fe.bind(this),void 0];for(e.unshift.apply(e,l),e.push.apply(e,s),d=e.length,c=Promise.resolve(t);u<d;)c=c.then(e[u++],e[u++]);return c}d=l.length;let p=t;for(u=0;u<d;){const e=l[u++],t=l[u++];try{p=e(p)}catch(e){t.call(this,e);break}}try{c=Fe.call(this,p)}catch(e){return Promise.reject(e)}for(u=0,d=s.length;u<d;)c=c.then(s[u++],s[u++]);return c}getUri(e){return pe(Ae((e=Le(this.defaults,e)).baseURL,e.url),e.params,e.paramsSerializer)}}Q.forEach(["delete","get","head","options"],(function(e){qe.prototype[e]=function(t,r){return this.request(Le(r||{},{method:e,url:t,data:(r||{}).data}))}})),Q.forEach(["post","put","patch"],(function(e){function t(t){return function(r,n,i){return this.request(Le(i||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:r,data:n}))}}qe.prototype[e]=t(),qe.prototype[e+"Form"]=t(!0)}));var We=qe;class ze{constructor(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");let t;this.promise=new Promise((function(e){t=e}));const r=this;this.promise.then((e=>{if(!r._listeners)return;let t=r._listeners.length;for(;t-- >0;)r._listeners[t](e);r._listeners=null})),this.promise.then=e=>{let t;const n=new Promise((e=>{r.subscribe(e),t=e})).then(e);return n.cancel=function(){r.unsubscribe(t)},n},e((function(e,n,i){r.reason||(r.reason=new _e(e,n,i),t(r.reason))}))}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}static source(){let e;return{token:new ze((function(t){e=t})),cancel:e}}}var $e=ze;const Ke={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Ke).forEach((([e,t])=>{Ke[t]=e}));var Ye=Ke;const Je=function e(t){const r=new We(t),n=m(We.prototype.request,r);return Q.extend(n,We.prototype,r,{allOwnKeys:!0}),Q.extend(n,r,null,{allOwnKeys:!0}),n.create=function(r){return e(Le(t,r))},n}(ve);Je.Axios=We,Je.CanceledError=_e,Je.CancelToken=$e,Je.isCancel=ke,Je.VERSION="1.4.0",Je.toFormData=le,Je.AxiosError=te,Je.Cancel=Je.CanceledError,Je.all=function(e){return Promise.all(e)},Je.spread=function(e){return function(t){return e.apply(null,t)}},Je.isAxiosError=function(e){return Q.isObject(e)&&!0===e.isAxiosError},Je.mergeConfig=Le,Je.AxiosHeaders=xe,Je.formToJSON=e=>ye(Q.isHTMLForm(e)?new FormData(e):e),Je.HttpStatusCode=Ye,Je.default=Je;var Qe=Je,Xe=(0,f.withSelect)((e=>{const{getEntityRecords:t}=e("core");return{categories:t("taxonomy","category",{per_page:-1})}}))((e=>{let{attributes:t,updateSelectedCategory:r,categories:n,disabled:o}=e,l=[];return Array.isArray(n)&&(l=n.map((e=>{let{id:t,name:r}=e;return{label:(n=r,"Uncategorized"===n?"Posts with no category assigned (Uncategorized)":`Posts assigned the '${n}' category`),value:t};var n})),l.unshift({value:-1,label:"All posts in site"})),(0,i.createElement)(b.SelectControl,{label:"Add this Video to:",disabled:o,value:t.category,onChange:e=>r(e),options:l})})),Ze=r.p+"images/humixlogo.6dc300c9.png",et=r(361),tt=r.n(et);const rt=/^https?:\/\/(www\.)?(humix\.com\/[\w-]{11,}|humix\.com\/([\w-]+\/)?video\/(playlist\/)?[\w-]{11,}|[\w.-]+\/humix\/video\/(playlist\/)?[\w-]{11,})([\?|\&]?[\w]+=[\w-]*)*$/,nt="https://www.humix.com/generate-embed-code?j=",it=[{id:2,label:"Arts & Entertainment",children:[{id:3,label:"Celebrities & Entertainment News"},{id:4,label:"Comics & Animation",children:[{id:5,label:"Anime & Manga"},{id:6,label:"Cartoons"},{id:7,label:"Comics"},{id:622,label:"Other"}]},{id:8,label:"Entertainment Industry",children:[{id:9,label:"Film & TV Industry"},{id:10,label:"Recording Industry"},{id:623,label:"Other"}]},{id:11,label:"Events & Listings",children:[{id:12,label:"Bars, Clubs & Nightlife"},{id:13,label:"Concerts & Music Festivals"},{id:14,label:"Expos & Conventions"},{id:15,label:"Film Festivals"},{id:16,label:"Movie Listings & Theater Showtimes"},{id:624,label:"Event Ticket Sales"},{id:625,label:"Food & Beverage Events"},{id:626,label:"Live Sporting Events"},{id:627,label:"Other"}]},{id:17,label:"Fun & Trivia",children:[{id:18,label:"Flash-Based Entertainment"},{id:19,label:"Fun Tests & Silly Surveys"},{id:628,label:"Other"}]},{id:20,label:"Humor",children:[{id:21,label:"Funny Pictures & Videos"},{id:22,label:"Political Humor"},{id:629,label:"Live Comedy"},{id:630,label:"Spoofs & Satire"},{id:631,label:"Other"}]},{id:23,label:"Movies",children:[{id:632,label:"Action & Adventure Films"},{id:633,label:"Animated Films"},{id:634,label:"Bollywood & South Asian Films"},{id:635,label:"Classic Films"},{id:636,label:"Comedy Films"},{id:637,label:"Cult & Indie Films"},{id:638,label:"Documentary Films"},{id:639,label:"Drama Films"},{id:640,label:"DVD & Video Shopping"},{id:641,label:"Family Films"},{id:642,label:"Horror Films"},{id:643,label:"Movie Memorabilia"},{id:644,label:"Movie Reference"},{id:645,label:"Musical Films"},{id:646,label:"Romance Films"},{id:647,label:"Science Fiction & Fantasy Films"},{id:648,label:"Thriller, Crime & Mystery Films"},{id:649,label:"Other"}]},{id:24,label:"Music & Audio",children:[{id:25,label:"CD & Audio Shopping"},{id:26,label:"Classical Music"},{id:27,label:"Country Music"},{id:28,label:"Dance & Electronic Music"},{id:29,label:"Experimental & Industrial Music"},{id:30,label:"Jazz & Blues"},{id:31,label:"Music Education & Instruction"},{id:32,label:"Music Equipment & Technology"},{id:33,label:"Music Reference"},{id:34,label:"Music Streams & Downloads"},{id:35,label:"Music Videos"},{id:36,label:"Pop Music"},{id:37,label:"Radio"},{id:38,label:"Religious Music"},{id:39,label:"Rock Music"},{id:40,label:"Soundtracks"},{id:41,label:"Urban & Hip-Hop"},{id:42,label:"World Music"},{id:650,label:"Folk & Traditional Music"},{id:651,label:"Music Art & Memorabilia"},{id:652,label:"Podcasts"},{id:653,label:"Vocals & Show Tunes"},{id:654,label:"Other"}]},{id:43,label:"Offbeat",children:[{id:44,label:"Occult & Paranormal"},{id:655,label:"Other"}]},{id:45,label:"Online Media",children:[{id:46,label:"Online Image Galleries"},{id:656,label:"Virtual Tours"},{id:657,label:"Other"}]},{id:47,label:"Performing Arts",children:[{id:48,label:"Acting & Theater"},{id:49,label:"Circus"},{id:50,label:"Dance"},{id:51,label:"Magic"},{id:52,label:"Opera"},{id:658,label:"Broadway & Musical Theater"},{id:659,label:"Other"}]},{id:53,label:"TV & Video",children:[{id:54,label:"Online Video"},{id:55,label:"TV Commercials"},{id:56,label:"TV Shows & Programs"},{id:660,label:"TV Guides & Reference"},{id:661,label:"TV Networks & Stations"},{id:662,label:"Other"}]},{id:57,label:"Visual Art & Design",children:[{id:58,label:"Architecture"},{id:59,label:"Art Museums & Galleries"},{id:60,label:"Design"},{id:61,label:"Painting"},{id:62,label:"Photographic & Digital Arts"},{id:663,label:"Sculpture"},{id:664,label:"Visual Arts & Design Education"},{id:665,label:"Other"}]},{id:621,label:"Other"}]},{id:63,label:"Autos & Vehicles",children:[{id:64,label:"Bicycles & Accessories",children:[{id:65,label:"Bike Parts & Repair"},{id:66,label:"BMX Bikes"},{id:667,label:"Bike Accessories"},{id:668,label:"Bike Frames"},{id:669,label:"Bike Helmets & Protective Gear"},{id:670,label:"Cruiser Bicycles"},{id:671,label:"Electric Bicycles"},{id:672,label:"Kids' Bikes"},{id:673,label:"Mountain Bikes"},{id:674,label:"Road Bikes"},{id:675,label:"Other"}]},{id:67,label:"Boats & Watercraft"},{id:68,label:"Campers & RVs"},{id:69,label:"Classic Vehicles"},{id:70,label:"Cargo Trucks & Trailers"},{id:71,label:"Motor Vehicles (By Type)",children:[{id:72,label:"Hybrid & Alternative Vehicles"},{id:73,label:"Motorcycles"},{id:74,label:"Off-Road Vehicles"},{id:75,label:"Trucks & SUVs"},{id:727,label:"Autonomous Vehicles"},{id:728,label:"Compact Cars"},{id:729,label:"Convertibles"},{id:730,label:"Coupes"},{id:731,label:"Diesel Vehicles"},{id:732,label:"Hatchbacks"},{id:733,label:"Luxury Vehicles"},{id:734,label:"Microcars & Subcompacts"},{id:735,label:"Scooters & Mopeds"},{id:736,label:"Sedans"},{id:737,label:"Sports Cars"},{id:738,label:"Station Wagons"},{id:739,label:"Trucks, Vans & SUVs"},{id:740,label:"Other"}]},{id:76,label:"Vehicle Codes & Driving Laws",children:[{id:77,label:"Vehicle Licensing & Registration"},{id:742,label:"Drunk Driving Law"},{id:743,label:"Other"}]},{id:78,label:"Vehicle Parts & Services",children:[{id:79,label:"Gas Prices & Vehicle Fueling"},{id:80,label:"Vehicle Parts & Accessories"},{id:81,label:"Vehicle Repair & Maintenance"},{id:744,label:"Towing & Roadside Assistance"},{id:745,label:"Vehicle Modification & Tuning"},{id:746,label:"Other"}]},{id:82,label:"Vehicle Shopping",children:[{id:83,label:"Used Vehicles"},{id:747,label:"Vehicle Dealers & Retailers"},{id:748,label:"Vehicle Specs, Reviews & Comparisons"},{id:749,label:"Other"}]},{id:84,label:"Vehicle Shows"},{id:666,label:"Other"},{id:676,label:"Other"},{id:677,label:"Custom & Performance Vehicles"},{id:678,label:"Audi",children:[{id:679,label:"Bentley"},{id:680,label:"BMW"},{id:681,label:"Buick"},{id:682,label:"Cadillac"},{id:683,label:"Chevrolet"},{id:684,label:"Chrysler"},{id:685,label:"Citroën"},{id:686,label:"Daewoo Motors"},{id:687,label:"Dodge"},{id:688,label:"Ferrari"},{id:689,label:"Fiat"},{id:690,label:"Ford"},{id:691,label:"GMC"},{id:692,label:"Honda"},{id:693,label:"Hummer"},{id:694,label:"Hyundai"},{id:695,label:"Isuzu"},{id:696,label:"Jaguar"},{id:697,label:"Jeep"},{id:698,label:"Kia"},{id:699,label:"Lamborghini"},{id:700,label:"Land Rover"},{id:701,label:"Lincoln"},{id:702,label:"Maserati"},{id:703,label:"Mazda"},{id:704,label:"Mercedes-Benz"},{id:705,label:"Mercury"},{id:706,label:"Mini"},{id:707,label:"Mitsubishi"},{id:708,label:"Nissan"},{id:709,label:"Peugeot"},{id:710,label:"Pontiac"},{id:711,label:"Porsche"},{id:712,label:"Ram Trucks"},{id:713,label:"Renault"},{id:714,label:"Rolls-Royce"},{id:715,label:"Saab"},{id:716,label:"Saturn"},{id:717,label:"SEAT"},{id:718,label:"Skoda"},{id:719,label:"Subaru"},{id:720,label:"Suzuki"},{id:721,label:"Tesla Motors"},{id:722,label:"Toyota"},{id:723,label:"Vauxhall-Opel"},{id:724,label:"Volkswagen"},{id:725,label:"Volvo"},{id:726,label:"Other"}]},{id:741,label:"Personal Aircraft"}]},{id:85,label:"Beauty & Fitness",children:[{id:86,label:"Beauty Pageants"},{id:87,label:"Body Art"},{id:88,label:"Cosmetic Procedures",children:[{id:89,label:"Cosmetic Surgery"}]},{id:90,label:"Cosmetology & Beauty Professionals"},{id:91,label:"Face & Body Care",children:[{id:92,label:"Hygiene & Toiletries"},{id:93,label:"Make-Up & Cosmetics"},{id:94,label:"Perfumes & Fragrances"},{id:95,label:"Skin & Nail Care"},{id:96,label:"Unwanted Body & Facial Hair Removal"},{id:755,label:"Clean Beauty"},{id:756,label:"Sun Care & Tanning Products"},{id:757,label:"Other"}]},{id:97,label:"Fashion & Style",children:[{id:98,label:"Fashion Designers & Collections"},{id:758,label:"Other"}]},{id:99,label:"Fitness",children:[{id:759,label:"Bodybuilding"},{id:760,label:"Fitness Equipment & Accessories"},{id:761,label:"Fitness Instruction & Personal Training"},{id:762,label:"Gyms & Health Clubs"},{id:763,label:"High Intensity Interval Training"},{id:764,label:"Yoga & Pilates"},{id:765,label:"Other"}]},{id:100,label:"Hair Care",children:[{id:101,label:"Hair Loss"},{id:766,label:"Shampoos & Conditioners"},{id:767,label:"Other"}]},{id:102,label:"Spas & Beauty Services",children:[{id:103,label:"Massage Therapy"}]},{id:104,label:"Weight Loss"},{id:750,label:"Other"},{id:751,label:"Cosmetic Procedures",children:[{id:752,label:"Manicures & Pedicures"},{id:753,label:"Massage Therapy"},{id:754,label:"Other"}]}]},{id:105,label:"Books & Literature",children:[{id:106,label:"Children's Literature"},{id:107,label:"E-Books"},{id:108,label:"Fan Fiction"},{id:109,label:"Literary Classics"},{id:110,label:"Poetry"},{id:111,label:"Writers Resources"},{id:768,label:"Audiobooks"},{id:769,label:"Book Retailers"},{id:770,label:"Other"}]},{id:112,label:"Business & Industrial",children:[{id:113,label:"Public Relations"},{id:114,label:"Space Technology"},{id:115,label:"Agriculture & Forestry",children:[{id:116,label:"Agricultural Equipment"},{id:117,label:"Forestry"},{id:118,label:"Livestock"},{id:779,label:"Aquaculture"},{id:780,label:"Crops & Seed"},{id:781,label:"Farms & Ranches"},{id:782,label:"Other"}]},{id:119,label:"Automotive Industry"},{id:120,label:"Business Education"},{id:121,label:"Business Finance",children:[{id:122,label:"Venture Capital"},{id:783,label:"Commercial Lending"},{id:784,label:"Investment Banking"},{id:785,label:"Risk Management"},{id:786,label:"Other"}]},{id:123,label:"Business Operations",children:[{id:124,label:"Business Plans & Presentations"},{id:125,label:"Management"},{id:787,label:"Flexible Work Arrangements"},{id:788,label:"Human Resources"},{id:789,label:"Other"}]},{id:126,label:"Business Services",children:[{id:127,label:"Consulting"},{id:128,label:"Corporate Events"},{id:129,label:"E-Commerce Services"},{id:130,label:"Fire & Security Services"},{id:131,label:"Office Services"},{id:132,label:"Office Supplies"},{id:133,label:"Writing & Editing Services"},{id:790,label:"Commercial Distribution"},{id:791,label:"Knowledge Management"},{id:792,label:"Outsourcing"},{id:793,label:"Physical Asset Management"},{id:794,label:"Quality Control & Tracking"},{id:795,label:"Shared Workspaces"},{id:796,label:"Signage"},{id:797,label:"Warehousing"},{id:798,label:"Other"}]},{id:134,label:"Chemicals Industry",children:[{id:135,label:"Cleaning Agents"},{id:136,label:"Plastics & Polymers"},{id:799,label:"Agrochemicals"},{id:800,label:"Coatings & Adhesives"},{id:801,label:"Dyes & Pigments"},{id:802,label:"Other"}]},{id:137,label:"Construction & Maintenance",children:[{id:138,label:"Building Materials & Supplies"},{id:803,label:"Civil Engineering"},{id:804,label:"Other"}]},{id:139,label:"Energy & Utilities",children:[{id:140,label:"Electricity"},{id:141,label:"Oil & Gas"},{id:142,label:"Renewable & Alternative Energy"},{id:805,label:"Nuclear Energy"},{id:806,label:"Waste Management"},{id:807,label:"Other"}]},{id:143,label:"Hospitality Industry",children:[{id:144,label:"Event Planning"},{id:145,label:"Food Service"},{id:808,label:"Event Venue Rentals"},{id:809,label:"Other"}]},{id:146,label:"Industrial Materials & Equipment",children:[{id:147,label:"Heavy Machinery"},{id:810,label:"Fluid Handling"},{id:811,label:"Generators"},{id:812,label:"Industrial Handling & Processing Equipment"},{id:813,label:"Industrial Measurement & Control Equipment"},{id:814,label:"Other"}]},{id:148,label:"Manufacturing",children:[{id:815,label:"Factory Automation"},{id:816,label:"Other"}]},{id:149,label:"Metals & Mining",children:[{id:150,label:"Precious Metals"},{id:817,label:"Other"}]},{id:151,label:"Pharmaceuticals & Biotech"},{id:152,label:"Printing & Publishing",children:[{id:818,label:"Document & Printing Services"},{id:819,label:"Other"}]},{id:153,label:"Retail Trade",children:[{id:154,label:"Retail Equipment & Technology"},{id:820,label:"Other"}]},{id:155,label:"MLM & Business Opportunities"},{id:156,label:"Textiles & Nonwovens"},{id:157,label:"Transportation & Logistics",children:[{id:158,label:"Freight & Trucking"},{id:159,label:"Mail & Package Delivery"},{id:160,label:"Maritime Transport"},{id:161,label:"Moving & Relocation"},{id:162,label:"Packaging"},{id:163,label:"Parking"},{id:164,label:"Rail Transport"},{id:165,label:"Urban Transport"}]},{id:771,label:"Other"},{id:772,label:"Brand Management",children:[{id:773,label:"Marketing"},{id:774,label:"Sales"},{id:775,label:"Telemarketing"},{id:776,label:"Other"}]},{id:777,label:"Aviation Industry",children:[{id:778,label:"Other"}]},{id:821,label:"Other",children:[{id:822,label:"Import & Export"},{id:823,label:"Mail & Package Delivery"},{id:824,label:"Moving & Relocation"},{id:825,label:"Packaging"},{id:826,label:"Self Storage"}]},{id:827,label:"Business Formation",children:[{id:828,label:"Home Office"},{id:829,label:"Other"}]}]},{id:166,label:"Computers & Electronics",children:[{id:167,label:"CAD & CAM"},{id:168,label:"Computer Hardware",children:[{id:169,label:"Computer Components"},{id:170,label:"Computer Drives & Storage"},{id:171,label:"Computer Peripherals"},{id:172,label:"Desktop Computers"},{id:173,label:"Laptops & Notebooks"},{id:831,label:"Computer Servers"},{id:832,label:"Hardware Modding & Tuning"},{id:833,label:"Other"}]},{id:174,label:"Computer Security",children:[{id:175,label:"Hacking & Cracking"},{id:834,label:"Antivirus & Malware"},{id:835,label:"Network Security"},{id:836,label:"Other"}]},{id:176,label:"Consumer Electronics",children:[{id:177,label:"Audio Equipment"},{id:178,label:"Camera & Photo Equipment"},{id:179,label:"Car Electronics"},{id:180,label:"Drones & RC Aircraft"},{id:181,label:"Game Systems & Consoles"},{id:182,label:"GPS & Navigation"},{id:183,label:"TV & Video Equipment"},{id:837,label:"Electronic Accessories"},{id:838,label:"Gadgets & Portable Electronics"},{id:839,label:"Home Automation"},{id:840,label:"Media Streaming Devices"},{id:841,label:"Virtual Reality Devices"},{id:842,label:"Other"}]},{id:184,label:"Electronics & Electrical",children:[{id:185,label:"Electronic Components"},{id:186,label:"Power Supplies"},{id:843,label:"Data Sheets & Electronics Reference"},{id:844,label:"Electrical Test & Measurement"},{id:845,label:"Electromechanical Devices"},{id:846,label:"Optoelectronics & Fiber"},{id:847,label:"Other"}]},{id:187,label:"Enterprise Technology",children:[{id:188,label:"Data Management"},{id:848,label:"Customer Relationship Management (CRM)"},{id:849,label:"Enterprise Resource Planning (ERP)"},{id:850,label:"Helpdesk & Customer Support Systems"},{id:851,label:"Other"}]},{id:189,label:"Networking",children:[{id:190,label:"Data Formats & Protocols"},{id:191,label:"Network Monitoring & Management"},{id:192,label:"VPN & Remote Access"},{id:852,label:"Distributed & Cloud Computing"},{id:853,label:"Networking Equipment"},{id:854,label:"Other"}]},{id:193,label:"Programming",children:[{id:194,label:"Java (Programming Language)"},{id:855,label:"C & C++"},{id:856,label:"Development Tools"},{id:857,label:"Scripting Languages"},{id:858,label:"Windows & .NET"},{id:859,label:"Other"}]},{id:195,label:"Software",children:[{id:196,label:"Business & Productivity Software"},{id:197,label:"Device Drivers"},{id:198,label:"Internet Software"},{id:199,label:"Multimedia Software"},{id:200,label:"Operating Systems"},{id:201,label:"Software Utilities"},{id:860,label:"Educational Software"},{id:861,label:"Freeware & Shareware"},{id:862,label:"Intelligent Personal Assistants"},{id:863,label:"Monitoring Software"},{id:864,label:"Open Source"},{id:865,label:"Other"}]},{id:830,label:"Other"}]},{id:202,label:"Finance",children:[{id:203,label:"Accounting & Auditing",children:[{id:204,label:"Billing & Invoicing"},{id:205,label:"Tax Preparation & Planning"},{id:867,label:"Bookkeeping"},{id:868,label:"Other"}]},{id:206,label:"Banking",children:[{id:869,label:"ATMs & Branch Locations"},{id:870,label:"Debit & Checking Services"},{id:871,label:"Mobile Payments & Digital Wallets"},{id:872,label:"Money Transfer & Wire Services"},{id:873,label:"Savings Accounts"},{id:874,label:"Other"}]},{id:207,label:"Credit & Lending",children:[{id:208,label:"Credit Cards"},{id:209,label:"Credit Reporting & Monitoring"},{id:210,label:"Loans"},{id:875,label:"Debt Collection & Repossession"},{id:876,label:"Debt Management"},{id:877,label:"Other"}]},{id:211,label:"Financial Planning & Management",children:[{id:212,label:"Retirement & Pension"},{id:879,label:"Asset & Portfolio Management"},{id:880,label:"Inheritance & Estate Planning"},{id:881,label:"Other"}]},{id:213,label:"Grants, Scholarships & Financial Aid",children:[{id:214,label:"Study Grants & Scholarships"},{id:882,label:"Government Grants"},{id:883,label:"Other"}]},{id:215,label:"Insurance",children:[{id:216,label:"Health Insurance"},{id:884,label:"Home Insurance"},{id:885,label:"Life Insurance"},{id:886,label:"Travel Insurance"},{id:887,label:"Vehicle Insurance"},{id:888,label:"Other"}]},{id:217,label:"Investing",children:[{id:218,label:"Commodities & Futures Trading"},{id:219,label:"Currencies & Foreign Exchange"},{id:220,label:"Stocks & Bonds"},{id:889,label:"Brokerages & Day Trading"},{id:890,label:"Derivatives"},{id:891,label:"Funds"},{id:892,label:"Real Estate Investment Trusts"},{id:893,label:"Socially Responsible Investing"},{id:894,label:"Other"}]},{id:866,label:"Other"},{id:878,label:"Crowdfunding"}]},{id:221,label:"Food & Drink",children:[{id:222,label:"Beverages",children:[{id:223,label:"Alcoholic Beverages"},{id:224,label:"Coffee & Tea"},{id:225,label:"Juice"},{id:226,label:"Soft Drinks"},{id:896,label:"Alcohol-Free Beverages"},{id:897,label:"Bottled Water"},{id:898,label:"Energy Drinks"},{id:899,label:"Nutrition Drinks & Shakes"},{id:900,label:"Sports Drinks"},{id:901,label:"Other"}]},{id:227,label:"Cooking & Recipes",children:[{id:228,label:"BBQ & Grilling"},{id:229,label:"Desserts"},{id:230,label:"Soups & Stews"},{id:902,label:"Cuisines"},{id:903,label:"Culinary Training"},{id:904,label:"Healthy Eating"},{id:905,label:"Salads"},{id:906,label:"Other"}]},{id:231,label:"Food",children:[{id:233,label:"Baked Goods"},{id:234,label:"Breakfast Foods"},{id:235,label:"Candy & Sweets"},{id:236,label:"Grains & Pasta"},{id:237,label:"Meat & Seafood"},{id:238,label:"Snack Foods"},{id:907,label:"Other"},{id:918,label:"Condiments & Dressings"},{id:919,label:"Cooking Fats & Oils"},{id:920,label:"Dairy & Egg Substitutes"},{id:921,label:"Dairy & Eggs"},{id:922,label:"Fruits & Vegetables"},{id:923,label:"Gourmet & Specialty Foods"},{id:924,label:"Herbs & Spices"},{id:925,label:"Jams, Jellies & Preserves"},{id:926,label:"Meat & Seafood Substitutes"},{id:927,label:"Organic & Natural Foods"}]},{id:232,label:"Food & Grocery Retailers",children:[{id:912,label:"Bakeries"},{id:913,label:"Butchers"},{id:914,label:"Convenience Stores"},{id:915,label:"Delicatessens"},{id:916,label:"Farmers' Markets"},{id:917,label:"Other"}]},{id:239,label:"Restaurants",children:[{id:240,label:"Fast Food"},{id:241,label:"Pizzerias"},{id:242,label:"Restaurant Reviews & Reservations"},{id:928,label:"Catering"},{id:929,label:"Fine Dining"},{id:930,label:"Other"}]},{id:895,label:"Other"},{id:908,label:"Grocery Delivery Services",children:[{id:909,label:"Meal Kits"},{id:910,label:"Restaurant Delivery Services"},{id:911,label:"Other"}]}]},{id:243,label:"Games",children:[{id:244,label:"Arcade & Coin-Op Games"},{id:245,label:"Board Games",children:[{id:246,label:"Chess & Abstract Strategy Games"},{id:247,label:"Miniatures & Wargaming"},{id:932,label:"Other"}]},{id:248,label:"Card Games",children:[{id:249,label:"Collectible Card Games"},{id:250,label:"Poker & Casino Games"},{id:933,label:"Other"}]},{id:251,label:"Computer & Video Games",children:[{id:252,label:"Casual Games"},{id:253,label:"Driving & Racing Games"},{id:254,label:"Fighting Games"},{id:255,label:"Music & Dance Games"},{id:256,label:"Sandbox Games"},{id:257,label:"Shooter Games"},{id:258,label:"Simulation Games"},{id:259,label:"Sports Games"},{id:260,label:"Strategy Games"},{id:261,label:"Video Game Emulation"},{id:934,label:"Action & Platform Games"},{id:935,label:"Adventure Games"},{id:936,label:"Browser Games"},{id:937,label:"Competitive Video Gaming"},{id:938,label:"Gaming Reference & Reviews"},{id:939,label:"Massively Multiplayer Games"},{id:940,label:"Video Game Development"},{id:941,label:"Video Game Mods & Add-Ons"},{id:942,label:"Video Game Retailers"},{id:943,label:"Other"}]},{id:262,label:"Family-Oriented Games & Activities",children:[{id:263,label:"Drawing & Coloring"},{id:264,label:"Dress-Up & Fashion Games"},{id:946,label:"Other"}]},{id:265,label:"Gambling",children:[{id:266,label:"Lottery"},{id:947,label:"Sports Betting"},{id:948,label:"Other"}]},{id:267,label:"Massively Multiplayer Games"},{id:268,label:"Puzzles & Brainteasers"},{id:269,label:"Roleplaying Games"},{id:270,label:"Table Games",children:[{id:271,label:"Billiards"},{id:950,label:"Table Tennis"},{id:951,label:"Other"}]},{id:272,label:"Word Games"},{id:931,label:"Other"},{id:944,label:"Dice Games"},{id:945,label:"Educational Games"},{id:949,label:"Party Games"},{id:952,label:"Tile Games"}]},{id:273,label:"Health",children:[{id:274,label:"Aging & Geriatrics",children:[{id:954,label:"Alzheimer's Disease"},{id:955,label:"Other"}]},{id:275,label:"Health Conditions",children:[{id:276,label:"AIDS & HIV"},{id:277,label:"Allergies"},{id:278,label:"Arthritis"},{id:279,label:"Cancer"},{id:280,label:"Diabetes"},{id:281,label:"Ear Nose & Throat"},{id:282,label:"Eating Disorders"},{id:283,label:"Endocrine Conditions"},{id:284,label:"Genetic Disorders"},{id:285,label:"Heart & Hypertension"},{id:286,label:"Infectious Diseases"},{id:287,label:"Neurological Conditions"},{id:288,label:"Obesity"},{id:289,label:"Pain Management"},{id:290,label:"Respiratory Conditions"},{id:291,label:"Skin Conditions"},{id:292,label:"Sleep Disorders"},{id:959,label:"Other"},{id:960,label:"Blood Sugar & Diabetes"},{id:961,label:"GERD & Digestive Disorders"},{id:962,label:"Injury"}]},{id:293,label:"Health Education & Medical Training"},{id:294,label:"Health Foundations & Medical Research"},{id:295,label:"Medical Devices & Equipment",children:[{id:963,label:"Assistive Technology"},{id:964,label:"Other"}]},{id:296,label:"Medical Facilities & Services",children:[{id:297,label:"Doctors' Offices"},{id:298,label:"Hospitals & Treatment Centers"},{id:299,label:"Medical Procedures"},{id:300,label:"Physical Therapy"},{id:965,label:"Other"}]},{id:301,label:"Men's Health"},{id:302,label:"Mental Health",children:[{id:303,label:"Anxiety & Stress"},{id:304,label:"Depression"},{id:968,label:"Compulsive Gambling"},{id:969,label:"Counseling Services"},{id:970,label:"Other"}]},{id:305,label:"Nursing",children:[{id:306,label:"Assisted Living & Long Term Care"},{id:971,label:"Other"}]},{id:307,label:"Nutrition",children:[{id:308,label:"Special & Restricted Diets"},{id:309,label:"Vitamins & Supplements"},{id:972,label:"Other"}]},{id:310,label:"Oral & Dental Care"},{id:311,label:"Pharmacy",children:[{id:312,label:"Drugs & Medications"},{id:974,label:"Other"}]},{id:313,label:"Public Health",children:[{id:314,label:"Occupational Health & Safety"},{id:975,label:"Health Policy"},{id:976,label:"Toxic Substances & Poisoning"},{id:977,label:"Other"}]},{id:315,label:"Reproductive Health",children:[{id:978,label:"Birth Control"},{id:979,label:"Infertility"},{id:980,label:"Male Impotence"},{id:981,label:"OBGYN"},{id:982,label:"Sex Education & Counseling"},{id:983,label:"Other"}]},{id:316,label:"Substance Abuse",children:[{id:317,label:"Drug & Alcohol Testing"},{id:318,label:"Drug & Alcohol Treatment"},{id:319,label:"Smoking & Smoking Cessation"},{id:320,label:"Steroids & Performance-Enhancing Drugs"},{id:984,label:"Other"}]},{id:321,label:"Vision Care",children:[{id:322,label:"Eyeglasses & Contacts"},{id:985,label:"Eye Exams & Optometry"},{id:986,label:"Laser Vision Correction"},{id:987,label:"Other"}]},{id:323,label:"Women's Health"},{id:953,label:"Other"},{id:956,label:"Acupuncture & Chinese Medicine",children:[{id:957,label:"Cleansing & Detoxification"},{id:958,label:"Other"}]},{id:966,label:"Medical Photos & Illustration",children:[{id:967,label:"Other"}]},{id:973,label:"Pediatrics"}]},{id:324,label:"Hobbies & Leisure",children:[{id:325,label:"Clubs & Organizations",children:[{id:326,label:"Youth Organizations & Resources"},{id:989,label:"Other"}]},{id:327,label:"Crafts",children:[{id:328,label:"Fiber & Textile Arts"},{id:990,label:"Art & Craft Supplies"},{id:991,label:"Ceramics & Pottery"},{id:992,label:"Other"}]},{id:329,label:"Merit Prizes & Contests"},{id:330,label:"Outdoors",children:[{id:331,label:"Fishing"},{id:332,label:"Hiking & Camping"},{id:993,label:"Hunting & Shooting"},{id:994,label:"Other"}]},{id:333,label:"Paintball"},{id:334,label:"Radio Control & Modeling",children:[{id:335,label:"Model Trains & Railroads"},{id:995,label:"Other"}]},{id:336,label:"Special Occasions",children:[{id:337,label:"Holidays & Seasonal Events"},{id:338,label:"Weddings"},{id:997,label:"Anniversaries"},{id:998,label:"Other"}]},{id:339,label:"Water Activities",children:[{id:340,label:"Boating"},{id:341,label:"Surf & Swim"},{id:1e3,label:"Diving & Underwater Activities"},{id:1001,label:"Other"}]},{id:988,label:"Other"},{id:996,label:"Recreational Aviation"},{id:999,label:"Sweepstakes & Promotional Giveaways"}]},{id:342,label:"Home & Garden",children:[{id:343,label:"Bed & Bath",children:[{id:344,label:"Bathroom"},{id:1003,label:"Bedroom"},{id:1004,label:"Other"}]},{id:345,label:"Domestic Services",children:[{id:346,label:"Cleaning Services"},{id:1005,label:"Other"}]},{id:347,label:"Gardening & Landscaping"},{id:348,label:"Home & Interior Decor"},{id:349,label:"Home Appliances",children:[{id:1006,label:"Vacuums & Floor Care"},{id:1007,label:"Water Filters & Purifiers"},{id:1008,label:"Other"}]},{id:350,label:"Home Furnishings",children:[{id:351,label:"Curtains & Window Treatments"},{id:352,label:"Kitchen & Dining Furniture"},{id:353,label:"Lamps & Lighting"},{id:354,label:"Living Room Furniture"},{id:355,label:"Rugs & Carpets"},{id:1009,label:"Clocks"},{id:1010,label:"Countertops"},{id:1011,label:"Outdoor Furniture"},{id:1012,label:"Other"}]},{id:356,label:"Home Improvement",children:[{id:357,label:"Construction & Power Tools"},{id:358,label:"Doors & Windows"},{id:359,label:"Flooring"},{id:360,label:"House Painting & Finishing"},{id:361,label:"Plumbing"},{id:1013,label:"Locks & Locksmiths"},{id:1014,label:"Roofing"},{id:1015,label:"Other"}]},{id:362,label:"Home Safety & Security",children:[{id:1016,label:"Home Alarm & Security Systems"},{id:1017,label:"Other"}]},{id:363,label:"Home Storage & Shelving",children:[{id:1018,label:"Cabinetry"},{id:1019,label:"Other"}]},{id:364,label:"Home Swimming Pools, Saunas & Spas"},{id:365,label:"HVAC & Climate Control",children:[{id:366,label:"Fireplaces & Stoves"},{id:1023,label:"Air Conditioners"},{id:1024,label:"Air Filters & Purifiers"},{id:1025,label:"Heaters"},{id:1026,label:"Household Fans"},{id:1027,label:"Other"}]},{id:367,label:"Kitchen & Dining",children:[{id:368,label:"Cookware & Diningware"},{id:369,label:"Major Kitchen Appliances"},{id:370,label:"Small Kitchen Appliances"},{id:1028,label:"Other"}]},{id:371,label:"Laundry",children:[{id:372,label:"Washers & Dryers"},{id:1029,label:"Other"}]},{id:373,label:"Nursery & Playroom"},{id:374,label:"Pest Control"},{id:375,label:"Yard & Patio",children:[{id:376,label:"Lawn Mowers"}]},{id:1002,label:"Other"},{id:1020,label:"Household Batteries",children:[{id:1021,label:"Household Cleaning Supplies"},{id:1022,label:"Other"}]},{id:1030,label:"Barbecues & Grills",children:[{id:1031,label:"Garden Structures"},{id:1032,label:"Gardening"},{id:1033,label:"Landscape Design"},{id:1034,label:"Other"}]}]},{id:377,label:"Internet & Telecom",children:[{id:378,label:"Communications Equipment",children:[{id:379,label:"Radio Equipment"},{id:1036,label:"Other"}]},{id:380,label:"Email & Messaging",children:[{id:381,label:"Text & Instant Messaging"},{id:382,label:"Voice & Video Chat"},{id:1037,label:"Electronic Spam"},{id:1038,label:"Email"},{id:1039,label:"Other"}]},{id:383,label:"Mobile & Wireless",children:[{id:384,label:"Mobile & Wireless Accessories"},{id:385,label:"Mobile Apps & Add-Ons"},{id:386,label:"Mobile Phones"},{id:1040,label:"Other"}]},{id:387,label:"Service Providers",children:[{id:388,label:"Cable & Satellite Providers"},{id:1043,label:"ISPs"},{id:1044,label:"Phone Service Providers"},{id:1045,label:"Other"}]},{id:389,label:"Web Services",children:[{id:390,label:"Affiliate Programs"},{id:391,label:"Web Design & Development"},{id:1047,label:"Cloud Storage"},{id:1048,label:"Search Engine Optimization & Marketing"},{id:1049,label:"Web Stats & Analytics"},{id:1050,label:"Other"}]},{id:1035,label:"Other"},{id:1041,label:"People Search",children:[{id:1042,label:"Other"}]},{id:1046,label:"Teleconferencing"}]},{id:392,label:"Jobs & Education",children:[{id:393,label:"Education",children:[{id:394,label:"Colleges & Universities"},{id:395,label:"Distance Learning"},{id:396,label:"Homeschooling"},{id:397,label:"Primary & Secondary Schooling (K-12)"},{id:398,label:"Standardized & Admissions Tests"},{id:399,label:"Teaching & Classroom Resources"},{id:400,label:"Training & Certification"},{id:401,label:"Vocational & Continuing Education"},{id:1052,label:"Academic Conferences & Publications"},{id:1053,label:"Alumni & Reunions"},{id:1054,label:"Computer Education"},{id:1055,label:"Early Childhood Education"},{id:1056,label:"Open Online Courses"},{id:1057,label:"Private Tutoring Services"},{id:1058,label:"Special Education"},{id:1059,label:"Study Abroad"},{id:1060,label:"Other"}]},{id:402,label:"Jobs",children:[{id:403,label:"Career Resources & Planning"},{id:404,label:"Job Listings"},{id:405,label:"Resumes & Portfolios"},{id:1062,label:"Other"}]},{id:1051,label:"Other"},{id:1061,label:"Internships"}]},{id:406,label:"Law & Government",children:[{id:407,label:"Government",children:[{id:408,label:"Courts & Judiciary"},{id:409,label:"Visa & Immigration"},{id:1064,label:"Embassies & Consulates"},{id:1065,label:"Executive Branch"},{id:1066,label:"Government Contracting & Procurement"},{id:1067,label:"Intelligence & Counterterrorism"},{id:1068,label:"Legislative Branch"},{id:1069,label:"Lobbying"},{id:1070,label:"Public Policy"},{id:1071,label:"Royalty"},{id:1072,label:"Other"}]},{id:410,label:"Legal",children:[{id:411,label:"Bankruptcy"},{id:412,label:"Legal Education"},{id:413,label:"Legal Services"},{id:1073,label:"Accident & Personal Injury Law"},{id:1074,label:"Business & Corporate Law"},{id:1075,label:"Constitutional Law & Civil Rights"},{id:1076,label:"Family Law"},{id:1077,label:"Intellectual Property"},{id:1078,label:"Labor & Employment Law"},{id:1079,label:"Product Liability"},{id:1080,label:"Real Estate Law"},{id:1081,label:"Other"}]},{id:414,label:"Military",children:[{id:1082,label:"Air Force"},{id:1083,label:"Army"},{id:1084,label:"Marines"},{id:1085,label:"Navy"},{id:1086,label:"Veterans"},{id:1087,label:"Other"}]},{id:415,label:"Public Safety",children:[{id:416,label:"Crime & Justice"},{id:417,label:"Emergency Services"},{id:418,label:"Law Enforcement"},{id:419,label:"Security Products & Services"},{id:1088,label:"Other"}]},{id:420,label:"Social Services",children:[{id:1089,label:"Welfare & Unemployment"},{id:1090,label:"Other"}]},{id:1063,label:"Other"}]},{id:421,label:"News",children:[{id:422,label:"Business News",children:[{id:423,label:"Company News"},{id:424,label:"Financial Markets News"},{id:1092,label:"Economy News"},{id:1093,label:"Fiscal Policy News"},{id:1094,label:"Other"}]},{id:425,label:"Scandals & Investigations"},{id:426,label:"Health News"},{id:427,label:"Politics",children:[{id:1097,label:"Campaigns & Elections"},{id:1098,label:"Media Critics & Watchdogs"},{id:1099,label:"Political Polls & Surveys"},{id:1100,label:"Other"}]},{id:428,label:"Sports News"},{id:429,label:"Weather"},{id:1091,label:"Other"},{id:1095,label:"Other"},{id:1096,label:"Local News"},{id:1101,label:"Technology News"},{id:1102,label:"World News"}]},{id:430,label:"Online Communities",children:[{id:431,label:"Blogging Resources & Services"},{id:432,label:"Dating & Personals",children:[{id:433,label:"Matrimonial Services"},{id:434,label:"Personals"},{id:435,label:"Photo Rating Sites"},{id:1104,label:"Other"}]},{id:436,label:"File Sharing & Hosting"},{id:437,label:"Online Goodies",children:[{id:438,label:"Clip Art & Animated GIFs"},{id:439,label:"Skins, Themes & Wallpapers"},{id:440,label:"Social Network Apps & Add-Ons"},{id:1105,label:"Other"}]},{id:441,label:"Photo & Video Sharing",children:[{id:442,label:"Photo & Image Sharing"},{id:1107,label:"Video Sharing"},{id:1108,label:"Other"}]},{id:443,label:"Social Networks"},{id:444,label:"Virtual Worlds"},{id:1103,label:"Other"},{id:1106,label:"Online Journals & Personal Sites"}]},{id:445,label:"People & Society",children:[{id:446,label:"Family & Relationships",children:[{id:447,label:"Family"},{id:448,label:"Marriage"},{id:449,label:"Troubled Relationships"},{id:1110,label:"Etiquette"},{id:1111,label:"Other"},{id:1112,label:"Romance"}]},{id:450,label:"Kids & Teens",children:[{id:451,label:"Children's Interests"},{id:452,label:"Teen Interests"},{id:1113,label:"Other"}]},{id:453,label:"Religion & Belief"},{id:454,label:"Seniors & Retirement"},{id:455,label:"Social Issues & Advocacy",children:[{id:456,label:"Charity & Philanthropy"},{id:457,label:"Discrimination & Identity Relations"},{id:458,label:"Green Living & Environmental Issues"},{id:459,label:"Human Rights & Liberties"},{id:460,label:"Poverty & Hunger"},{id:461,label:"Work & Labor Issues"},{id:1115,label:"Drug Laws & Policy"},{id:1116,label:"Ethics"},{id:1117,label:"Housing & Development"},{id:1118,label:"Other"}]},{id:462,label:"Social Sciences",children:[{id:463,label:"Economics"},{id:464,label:"Political Science"},{id:465,label:"Psychology"},{id:1119,label:"Anthropology"},{id:1120,label:"Archaeology"},{id:1121,label:"Communications & Media Studies"},{id:1122,label:"Demographics"},{id:1123,label:"Other"}]},{id:466,label:"Subcultures & Niche Interests"},{id:1109,label:"Other"},{id:1114,label:"Self-Help & Motivational"}]},{id:467,label:"Pets & Animals",children:[{id:468,label:"Pet Food & Supplies"},{id:469,label:"Veterinarians"},{id:470,label:"Pets",children:[{id:471,label:"Birds"},{id:472,label:"Cats"},{id:473,label:"Dogs"},{id:474,label:"Exotic Pets"},{id:475,label:"Fish & Aquaria"},{id:476,label:"Horses"},{id:477,label:"Rabbits & Rodents"},{id:478,label:"Reptiles & Amphibians"},{id:1128,label:"Other"}]},{id:479,label:"Wildlife"},{id:1124,label:"Other"},{id:1125,label:"Animal Welfare",children:[{id:1126,label:"Pet Food & Pet Care Supplies"},{id:1127,label:"Other"}]}]},{id:480,label:"Real Estate",children:[{id:481,label:"Real Estate Listings",children:[{id:482,label:"Bank-Owned & Foreclosed Properties"},{id:483,label:"Commercial Properties"},{id:484,label:"Lots & Land"},{id:485,label:"Residential Rentals"},{id:486,label:"Residential Sales"},{id:487,label:"Timeshares & Vacation Properties"},{id:1131,label:"Other"}]},{id:488,label:"Real Estate Services",children:[{id:1132,label:"Property Inspections & Appraisals"},{id:1133,label:"Property Management"},{id:1134,label:"Real Estate Agencies"},{id:1135,label:"Real Estate Title & Escrow"},{id:1136,label:"Other"}]},{id:1129,label:"Property Development"},{id:1130,label:"Other"}]},{id:489,label:"Reference",children:[{id:490,label:"Directories & Listings",children:[{id:491,label:"Business & Personal Listings"},{id:1138,label:"Other"}]},{id:492,label:"General Reference",children:[{id:493,label:"Biographies & Quotations"},{id:494,label:"Calculators & Reference Tools"},{id:495,label:"Dictionaries & Encyclopedias"},{id:496,label:"Forms Guides & Templates"},{id:497,label:"Public Records"},{id:498,label:"Time & Calendars"},{id:1139,label:"Educational Resources"},{id:1140,label:"How-To, DIY & Expert Content"},{id:1141,label:"Other"}]},{id:499,label:"Geographic Reference",children:[{id:500,label:"Maps"},{id:1142,label:"Other"}]},{id:501,label:"Humanities",children:[{id:502,label:"History"},{id:503,label:"Myth & Folklore"},{id:504,label:"Philosophy"},{id:1143,label:"Other"}]},{id:505,label:"Language Resources",children:[{id:506,label:"Foreign Language Resources"},{id:1144,label:"Other"}]},{id:507,label:"Libraries & Museums",children:[{id:508,label:"Museums"},{id:1145,label:"Libraries"},{id:1146,label:"Other"}]},{id:1137,label:"Other"},{id:1147,label:"Technical Reference"}]},{id:509,label:"Science",children:[{id:510,label:"Astronomy"},{id:511,label:"Biological Sciences",children:[{id:512,label:"Neuroscience"},{id:1149,label:"Genetics"},{id:1150,label:"Other"}]},{id:513,label:"Chemistry"},{id:514,label:"Computer Science",children:[{id:1151,label:"Machine Learning & Artificial Intelligence"},{id:1152,label:"Other"}]},{id:515,label:"Earth Sciences",children:[{id:516,label:"Atmospheric Science"},{id:517,label:"Geology"},{id:1153,label:"Paleontology"},{id:1154,label:"Other"}]},{id:518,label:"Ecology & Environment",children:[{id:519,label:"Climate Change & Global Warming"},{id:1155,label:"Other"}]},{id:520,label:"Engineering & Technology",children:[{id:521,label:"Robotics"},{id:1156,label:"Augmented & Virtual Reality"},{id:1157,label:"Other"}]},{id:522,label:"Mathematics",children:[{id:523,label:"Statistics"},{id:1158,label:"Other"}]},{id:524,label:"Physics"},{id:525,label:"Scientific Institutions"},{id:1148,label:"Other"},{id:1159,label:"Scientific Equipment"}]},{id:526,label:"Sensitive Subjects",children:[{id:1160,label:"Accidents & Disasters"},{id:1161,label:"Death & Tragedy"},{id:1162,label:"Firearms & Weapons"},{id:1163,label:"Recreational Drugs"},{id:1164,label:"Self-Harm"},{id:1165,label:"Violence & Abuse"},{id:1166,label:"War & Conflict"},{id:1167,label:"Other"}]},{id:527,label:"Shopping",children:[{id:528,label:"Antiques & Collectibles"},{id:529,label:"Apparel",children:[{id:530,label:"Athletic Apparel"},{id:531,label:"Casual Apparel"},{id:532,label:"Children's Clothing"},{id:533,label:"Clothing Accessories"},{id:534,label:"Costumes"},{id:535,label:"Eyewear"},{id:536,label:"Footwear"},{id:537,label:"Formal Wear"},{id:538,label:"Headwear"},{id:539,label:"Men's Clothing"},{id:540,label:"Swimwear"},{id:541,label:"Undergarments"},{id:542,label:"Women's Clothing"},{id:1169,label:"Apparel Services"},{id:1170,label:"Outerwear"},{id:1171,label:"Pants & Shorts"},{id:1172,label:"Shirts & Tops"},{id:1173,label:"Sleepwear"},{id:1174,label:"Suits & Business Attire"},{id:1175,label:"Uniforms & Workwear"},{id:1176,label:"Other"}]},{id:543,label:"Auctions"},{id:544,label:"Classifieds"},{id:545,label:"Consumer Resources",children:[{id:546,label:"Consumer Advocacy & Protection"},{id:547,label:"Coupons & Discount Offers"},{id:548,label:"Product Reviews & Price Comparisons"},{id:1177,label:"Customer Services"},{id:1178,label:"Identity Theft Protection"},{id:1179,label:"Other"}]},{id:549,label:"Entertainment Media",children:[{id:550,label:"Entertainment Media Rentals"},{id:1181,label:"Other"}]},{id:551,label:"Gifts & Special Event Items",children:[{id:552,label:"Cards & Greetings"},{id:553,label:"Flowers"},{id:554,label:"Gifts"},{id:1182,label:"Custom & Personalized Items"},{id:1183,label:"Greeting Cards"},{id:1184,label:"Party & Holiday Supplies"},{id:1185,label:"Other"}]},{id:555,label:"Luxury Goods"},{id:556,label:"Mass Merchants & Department Stores"},{id:557,label:"Photo & Video Services",children:[{id:1187,label:"Event & Studio Photography"},{id:1188,label:"Photo Printing Services"},{id:1189,label:"Stock Photography"},{id:1190,label:"Other"}]},{id:558,label:"Tobacco Products"},{id:559,label:"Toys",children:[{id:560,label:"Building Toys"},{id:561,label:"Die-cast & Toy Vehicles"},{id:562,label:"Dolls & Accessories"},{id:563,label:"Ride-On Toys & Wagons"},{id:564,label:"Stuffed Toys"},{id:1194,label:"Action Figures"},{id:1195,label:"Educational Toys"},{id:1196,label:"Outdoor Toys & Play Equipment"},{id:1197,label:"Puppets"},{id:1198,label:"Other"}]},{id:1168,label:"Other"},{id:1180,label:"Discount & Outlet Stores"},{id:1186,label:"Green & Eco-Friendly Shopping"},{id:1191,label:"Shopping Portals"},{id:1192,label:"Swap Meets & Outdoor Markets"},{id:1193,label:"Tobacco & Vaping Products"},{id:1199,label:"Wholesalers & Liquidators"}]},{id:565,label:"Sports",children:[{id:566,label:"Animal Sports",children:[{id:1201,label:"Equestrian"},{id:1202,label:"Other"}]},{id:567,label:"College Sports"},{id:568,label:"Combat Sports",children:[{id:569,label:"Boxing"},{id:570,label:"Martial Arts"},{id:571,label:"Wrestling"},{id:1203,label:"Fencing"},{id:1204,label:"Other"}]},{id:572,label:"Extreme Sports",children:[{id:573,label:"Drag & Street Racing"},{id:1205,label:"Climbing & Mountaineering"},{id:1206,label:"Stunts & Dangerous Feats"},{id:1207,label:"Other"}]},{id:574,label:"Fantasy Sports"},{id:575,label:"Individual Sports",children:[{id:576,label:"Cycling"},{id:577,label:"Golf"},{id:578,label:"Gymnastics"},{id:579,label:"Racquet Sports"},{id:580,label:"Skate Sports"},{id:581,label:"Track & Field"},{id:1208,label:"Bowling"},{id:1209,label:"Running & Walking"},{id:1210,label:"Other"}]},{id:582,label:"International Sports Competitions",children:[{id:583,label:"Olympics"},{id:1211,label:"Other"}]},{id:584,label:"Motor Sports",children:[{id:1212,label:"Auto Racing"},{id:1213,label:"Motorcycle Racing"},{id:1214,label:"Other"}]},{id:585,label:"Sporting Goods",children:[{id:586,label:"Sports Memorabilia"},{id:587,label:"Winter Sports Equipment"},{id:1216,label:"American Football Equipment"},{id:1217,label:"Baseball Equipment"},{id:1218,label:"Basketball Equipment"},{id:1219,label:"Bowling Equipment"},{id:1220,label:"Combat Sports Equipment"},{id:1221,label:"Cricket Equipment"},{id:1222,label:"Electric Skateboards & Scooters"},{id:1223,label:"Equestrian Equipment & Tack"},{id:1224,label:"Golf Equipment"},{id:1225,label:"Gymnastics Equipment"},{id:1226,label:"Hockey Equipment"},{id:1227,label:"Ice Skating Equipment"},{id:1228,label:"Roller Skating & Rollerblading Equipment"},{id:1229,label:"Skateboarding Equipment"},{id:1230,label:"Soccer Equipment"},{id:1231,label:"Squash & Racquetball Equipment"},{id:1232,label:"Table Tennis Equipment"},{id:1233,label:"Tennis Equipment"},{id:1234,label:"Volleyball Equipment"},{id:1235,label:"Water Sports Equipment"},{id:1236,label:"Other"}]},{id:588,label:"Sports Coaching & Training"},{id:589,label:"Team Sports",children:[{id:590,label:"American Football"},{id:591,label:"Australian Football"},{id:592,label:"Baseball"},{id:593,label:"Basketball"},{id:594,label:"Cheerleading"},{id:595,label:"Cricket"},{id:596,label:"Hockey"},{id:597,label:"Rugby"},{id:598,label:"Soccer"},{id:599,label:"Volleyball"},{id:1238,label:"Handball"},{id:1239,label:"Other"}]},{id:600,label:"Water Sports",children:[{id:601,label:"Surfing"},{id:602,label:"Swimming"},{id:1240,label:"Other"}]},{id:603,label:"Winter Sports",children:[{id:604,label:"Ice Skating"},{id:605,label:"Skiing & Snowboarding"},{id:1241,label:"Other"}]},{id:1200,label:"Other"},{id:1215,label:"Sport Scores & Statistics"},{id:1237,label:"Sports Fan Gear & Apparel"}]},{id:606,label:"Travel",children:[{id:607,label:"Air Travel",children:[{id:608,label:"Airport Parking & Transportation"}]},{id:609,label:"Bus & Rail"},{id:610,label:"Car Rental & Taxi Services"},{id:611,label:"Cruises & Charters"},{id:612,label:"Hotels & Accommodations",children:[{id:613,label:"Vacation Rentals & Short-Term Stays"}]},{id:614,label:"Specialty Travel"},{id:615,label:"Tourist Destinations",children:[{id:616,label:"Beaches & Islands"},{id:617,label:"Mountain & Ski Resorts"},{id:618,label:"Regional Parks & Gardens"},{id:619,label:"Theme Parks"},{id:620,label:"Zoos-Aquariums-Preserves"}]}]},{id:1242,label:"Other",children:[{id:1243,label:"Vacation Rentals & Short-Term Stays",children:[{id:1244,label:"Other"}]},{id:1245,label:"Backpacks & Utility Bags",children:[{id:1246,label:"Other"}]},{id:1247,label:"Adventure Travel",children:[{id:1248,label:"Agritourism"},{id:1249,label:"Business Travel"},{id:1250,label:"Ecotourism"},{id:1251,label:"Family Travel"},{id:1252,label:"Honeymoons & Romantic Getaways"},{id:1253,label:"Low Cost & Last Minute Travel"},{id:1254,label:"Luxury Travel"},{id:1255,label:"Medical Tourism"},{id:1256,label:"Religious Travel"},{id:1257,label:"Other"}]},{id:1258,label:"Beaches & Islands",children:[{id:1259,label:"Historical Sites & Buildings"},{id:1260,label:"Mountain & Ski Resorts"},{id:1261,label:"Regional Parks & Gardens"},{id:1262,label:"Theme Parks"},{id:1263,label:"Vineyards & Wine Tourism"},{id:1264,label:"Zoos, Aquariums & Preserves"},{id:1265,label:"Other"}]},{id:1266,label:"Air Travel",children:[{id:1267,label:"Car Rentals"},{id:1268,label:"Carpooling"},{id:1269,label:"Chartered Transportation Rentals"},{id:1270,label:"Cruises & Charters"},{id:1271,label:"Long Distance Bus & Rail"},{id:1272,label:"Other"},{id:1273,label:"Scooter & Bike Rentals"},{id:1274,label:"Taxi & Ride Hail Services"},{id:1275,label:"Traffic & Route Planners"},{id:1276,label:"Urban Transit"}]},{id:1277,label:"Guided Tours & Escorted Vacations",children:[{id:1278,label:"Sightseeing Tours"},{id:1279,label:"Vacation Offers"},{id:1280,label:"Other"}]},{id:1281,label:"Travel Guides & Travelogues"}]}];var ot=JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":2,"name":"humix/humix-block","version":"0.1.0","title":"Humix Block","category":"embed","icon":"humix-icon","description":"Humix Block for embedding videos","attributes":{"url":{"type":"string","default":""},"providerNameSlug":{"type":"string","default":""},"allowResponsive":{"type":"boolean","default":true},"responsive":{"type":"boolean","default":false},"previewable":{"type":"boolean","default":true},"floatOption":{"type":"number","default":1},"displayType":{"type":"string","default":"url"},"html":{"type":"string","default":""},"autoplay":{"type":"boolean","default":true},"loop":{"type":"boolean","default":false},"category":{"type":"string","default":""},"alignment":{"type":"string","default":"none"},"matchOption":{"type":"string","default":"MATCH_BY_TOPIC"},"matchCategories":{"type":"array","default":[]},"videoSourceOption":{"type":"string","default":"ANY_SOURCE"}},"supports":{"spacing":{"margin":true}},"textdomain":"humix-block","editorScript":"file:./index.js","editorStyle":"file:./index.css","style":"file:./style-index.css"}');const lt=()=>{const e={};for(const[t,r]of Object.entries(ot.attributes))r.hasOwnProperty("default")&&(e[t]=r.default);return e},at={...ot,edit:function(e){let{clientId:t,attributes:r,setAttributes:o}=e;const l="1",a="edit",s="preview",c="add_to_posts",d="MATCH_BY_TOPIC",h="MATCH_BY_CATEGORY",m=[{label:"Match video by page topic",value:d},{label:"Match video by category",value:h}],g="ANY_SOURCE",v="NETWORK_VIDEOS_SOURCE",O="MY_VIDEOS_SOURCE",w=[{label:"My videos & 3rd party network videos (recommended)",value:g},{label:"3rd party videos from Humix Network only",value:v},{label:"My videos only",value:O}],S={[`${g}-${d}`]:0,[`${g}-${h}`]:1,[`${v}-${d}`]:2,[`${v}-${h}`]:3,[`${O}-${d}`]:4,[`${O}-${h}`]:5},E="skip_if_video_exists",P="replace_all_videos",C=(0,p.useBlockEditContext)(),x=(0,f.select)("core/editor");let T=null;x&&(T=x.getCurrentPost());let k=0,j=0,_=0,R=0;const{url:A,floatOption:D,displayType:M,html:N,autoplay:B,loop:F,category:I,matchOption:L,matchCategories:H,videoSourceOption:V}=r,[U,G]=(0,i.useState)(A),[q,W]=(0,i.useState)(D),[z,$]=(0,i.useState)(M),[K,Y]=(0,i.useState)(N),[J,Q]=(0,i.useState)(B),[X,Z]=(0,i.useState)(F),[ee,te]=(0,i.useState)(I),[re,ne]=(0,i.useState)(l),[ie,oe]=(0,i.useState)(!1),[le,ae]=(0,i.useState)(!1),[se,ce]=(0,i.useState)(E),[de,ue]=(0,i.useState)(0),[pe,be]=(0,i.useState)(!1),[fe,he]=(0,i.useState)(L||d),[ye,me]=(0,i.useState)(H||[]),[ge,ve]=(0,i.useState)(V||g),[Oe,we]=(0,i.useState)(0),[Se,Ee]=(0,i.useState)(0),[Pe,Ce]=(0,i.useState)(0),[xe,Te]=(0,i.useState)(0),[ke,je]=(0,i.useState)(0),_e=()=>"auto"===z?L===d||ye&&ye.length>0&&ye.length<=3:Re(U),Re=e=>rt.test(e),[Ae,De]=(0,i.useState)(_e()?s:a),Me=e=>(e.forEach((e=>{e.checked=ye.includes(e.id),e.children&&(e.children=Me(e.children))})),e);(0,i.useEffect)((()=>{if(!x)return;let e=0;const r=x.getBlocks();r.forEach(((n,i)=>{"core/paragraph"===n.name&&e++,n.clientId===t&&(0===e?ne("0"):1===e?ne(l):2===e?ne("2"):i<r.length/2?ne("3"):ne("4"))}))}),[]),(0,i.useEffect)((()=>{o({url:U}),Re(U)&&Be()}),[U]),(0,i.useEffect)((()=>{o({floatOption:q}),_e()&&Be()}),[q]),(0,i.useEffect)((()=>{o({displayType:z}),"auto"===z&&G(""),Be()}),[z]),(0,i.useEffect)((()=>{o({html:K})}),[K]),(0,i.useEffect)((()=>{o({autoplay:J}),_e()&&Be()}),[J]),(0,i.useEffect)((()=>{o({loop:X}),_e()&&Be()}),[X]),(0,i.useEffect)((()=>{o({category:ee})}),[ee]),(0,i.useEffect)((()=>{o({matchCategories:ye.slice(0,3)}),_e()&&Be()}),[ye]),(0,i.useEffect)((()=>{o({matchOption:fe}),_e()&&Be()}),[fe]),(0,i.useEffect)((()=>{o({videoSourceOption:ge}),_e()&&Be()}),[ge]),(0,i.useEffect)((()=>{je(0!==Oe?Math.floor((de+Se+Pe+xe)/Oe*100):0)}),[de,Se,Pe,xe]);const Ne=function(){let{autoplay:e=!1,floatOption:t=!0,videoId:r="",autoMatch:n=!1,startTime:i=0,width:o=640,height:l=360,preview:a=!1 }=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const s={auto_play:e,float:t,width:o,height:l};if(r&&(s.videoId=r),n){s.auto_match=!0;const e=fe===h;let t=S[`${ge}-${fe}`];void 0===t&&(console.error("Unexpected source-match option combination"),t=e?1:0),s.auto_match_option=S[`${ge}-${fe}`],e&&(s.match_category_ids=ye.map((e=>parseInt(e))))}return i>0&&(s.time_start=i),a&&(s.preview=a),JSON.stringify(s)},Be=async()=>{let e="";if("auto"!==z&&!U)return;if("url"===z&&U&&U.includes("/playlist")){if(e=(e=>{let t=e,r=U.split("/");if(!r)return;if(r=r[r.length-1].split("?"),!r)return;const n=r[0],i=Ne({autoplay:!!J,floatOption:!!q,videoId:n});return i?t+i:void 0})(nt),!e)return}else if("url"===M&&U){if(e=(e=>{let t="https://humix.com/humix/oembed?url=";return t+=U,t+=`&float=${q}`,t+=`&autoplay=${J}`,t+=`&loop=${X}`,t})(),!e)return}else if(e=(e=>{let t=e;const r=Ne({autoplay:!!J,floatOption:!!q,autoMatch:!0});if(r)return t+r})(nt),!e)return;const t=await Qe({method:"get",url:e});if(t&&t.data){const e=t.data;e.html?Y(e.html):Y(e),e.provider_name?o({providerSlug:e.provider_name}):o({providerSlug:"Humix"})}},Fe=()=>{_e()&&De(s)},Ie=()=>{_e()&&De(c)},Le=function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];oe(!1),ae(!e),be(e),Fe(),setTimeout((()=>{ae(!1),be(!1),ue(0)}),15e3)},He=(e,t)=>{e.forEach((e=>{H.includes(e.id)&&t.push(e.label),e.children&&He(e.children,t)}))};return(0,i.createElement)("div",(0,p.useBlockProps)(),(0,i.createElement)(p.BlockControls,null,(0,i.createElement)(p.BlockAlignmentToolbar,{value:r.alignment,onChange:e=>{o({alignment:e})},controls:["left","center","right"]})),Ae===s&&""!=K&&(0,i.createElement)("div",{className:"preview-block"},(0,i.createElement)("div",{class:"preview-btn-group"},(0,i.createElement)("button",{onClick:()=>{De(a)},"aria-label":"Edit Video Settings",style:{marginRight:"15px"}},"Edit"),(0,i.createElement)("button",{onClick:Ie},"Add to Other Posts")),"auto"!==z&&(0,i.createElement)("iframe",{src:(()=>{const e=U.split("/");let t="https://humix.com/embed?contentId="+e[e.length-1].split("?")[0]+"&play_nextvid=0";return J||(t+="&autoplay=0"),X&&(t+="&loop=1"),t})()}),"auto"===z&&(0,i.createElement)("div",{className:"auto-select-preview"},(0,i.createElement)("h3",null,"Auto-Select Video"),(0,i.createElement)("p",null,(()=>{let e="Humix AI will choose an appropriate video to play ";if(ge!==g&&(e+=ge===v?"from the Humix Network ":"from your videos "),L===d)return e+="based on the contents of the page",e;const t=[];return He(it,t),0===t.length?"":(e+="that matches the ",1===t.length?e+`"${t[0]}" category`:2===t.length?e+`"${t[0]}" or "${t[1]}" categories`:e+`"${t[0]}", "${t[1]}", or "${t[2]}" categories`)})())),(le||pe)&&(0,i.createElement)("div",{class:"propagate-notice"},le&&(0,i.createElement)(b.Animate,{type:"slide-in",options:{origin:"top"}},(()=>(0,i.createElement)(b.Notice,{status:de>0?"success":"warning",isDismissible:!1},de>0&&(0,i.createElement)("p",null,(0,i.createElement)(b.Icon,{icon:"saved",className:"ezhx-success"}),"Humix video added to ",(0,i.createElement)("strong",null,de)," other post",1===de?"":"s","!"),0===de&&(0,i.createElement)("p",null,(0,i.createElement)(b.Icon,{icon:"warning",className:"ezhx-warning"}),"No Humix videos were added to other posts"),de!==Oe&&Oe>0&&(0,i.createElement)("ul",null,Se>0&&(0,i.createElement)("li",null,(0,i.createElement)("strong",null,Se)," post",1===Se?" was skipped because it already has":"s were skipped because they already have"," a Humix video"),Pe>0&&(0,i.createElement)("li",null,(0,i.createElement)("strong",null,Pe)," post",1===Pe?"":"s"," did not have an appropriate location to add the video to"),xe>0&&(0,i.createElement)("li",null,(0,i.createElement)("strong",null,xe)," post",1===xe?"":"s"," failed to update due to an internal error, please try again"))))),pe&&(0,i.createElement)(b.Animate,{type:"slide-in",options:{origin:"top"}},(()=>(0,i.createElement)(b.Notice,{status:"error",isDismissible:!1},(0,i.createElement)("p",null,(0,i.createElement)(b.Icon,{icon:"warning",className:"ezhx-error"}),"There was an error adding the Humix video to other pages")))))),Ae===a&&(0,i.createElement)("div",{className:"edit-block"},(0,i.createElement)("div",{style:{height:"35px",maxWidth:"150px",marginBottom:"20px"}},(0,i.createElement)("a",{href:"https://www.humix.com/",target:"_blank"},(0,i.createElement)("img",{src:Ze}))),(0,i.createElement)("div",{className:"humix-display-type-radio-group"},(0,i.createElement)(b.__experimentalRadioGroup,{checked:M,onChange:e=>{$(e)}},(0,i.createElement)(b.Tooltip,{text:"Let Humix AI choose an appropriate video"},(0,i.createElement)(b.__experimentalRadio,{value:"auto"},"Auto Select")),(0,i.createElement)(b.__experimentalRadio,{value:"url"},"Use Humix Link"))),(0,i.createElement)("div",{style:{marginBottom:"18px"}}),"url"===M&&(0,i.createElement)("div",null,(0,i.createElement)("p",{for:"humix-url-input",style:{fontSize:"small",marginBottom:"20px"}},"Please provide a link to the video or playlist you'd like to serve on your website. You can easily copy the links from either ",(0,i.createElement)("a",{href:"https://pubdash.ezoic.com/humix/studio/videos",target:"_blank"},"Humix Studio")," or ",(0,i.createElement)("a",{href:"https://www.humix.com",target:"_blank"},"Humix.com"),". For additional details, please refer to ",(0,i.createElement)("a",{href:"https://support.ezoic.com/scp/article.php?id=595",target:"_blank"},"this article"),"."),(0,i.createElement)(b.TextControl,{id:"humix-url-input",label:"Video or Playlist URL",value:U,placeholder:"Enter URL here",onChange:G})),"auto"===M&&(0,i.createElement)("div",null,(0,i.createElement)("p",null,"Video Match Settings"),(0,i.createElement)(b.RadioControl,{label:"Choose the source(s) that Humix can play videos from",onChange:ve,selected:ge,options:w}),(0,i.createElement)("div",{style:{marginTop:"15px"}},(0,i.createElement)(b.RadioControl,{label:"Choose how Humix selects a match for this video",onChange:he,selected:fe,options:m.map((e=>({...e,label:(0,i.createElement)(i.Fragment,null,e.label,e.value===d&&(0,i.createElement)(b.Tooltip,{text:"Humix will detect your page's content and find a relevant video that matches the page topic"},(0,i.createElement)(b.Icon,{icon:"info",style:{marginLeft:"4px"}})),e.value===h&&(0,i.createElement)(b.Tooltip,{text:"Humix will serve videos that match your chosen categories"},(0,i.createElement)(b.Icon,{icon:"info",style:{marginLeft:"4px"}})))})))})),fe===h&&(0,i.createElement)("div",{style:{marginTop:"15px"}},(0,i.createElement)("label",{for:"match-categories",class:"video-match-categories__label"},"Select up to 3 categories for video matching",ye.length>3&&(0,i.createElement)("span",{style:{color:"red"}}," (only 3 categories are allowed)")),(0,i.createElement)(u,{id:"match-categories",data:Me(tt()(it)),mode:"hierarchical",keepTreeOnSearch:!0,keepChildrenOnSearch:!0,keepOpenOnSelect:!0,texts:{placeholder:"Search..."},currentSelections:ye,onChange:(e,t)=>{me(t.map((e=>e.id)))}}))),(0,i.createElement)("div",{style:{marginBottom:"18px"}}),(0,i.createElement)("hr",null),(0,i.createElement)("p",null,"Video Playback Settings"),(0,i.createElement)(b.CheckboxControl,{label:"Float",style:{marginBottom:"8px"},checked:D,onChange:e=>{W(e)}}),(0,i.createElement)(b.CheckboxControl,{label:"Auto Play",checked:B,onChange:e=>{Q(e)}}),(0,i.createElement)(b.CheckboxControl,{label:"Loop",checked:F,onChange:e=>{Z(e)}}),T&&(0,i.createElement)("span",null),(0,i.createElement)("div",{class:"ezhx-btn-group"},(0,i.createElement)("button",{onClick:Fe,disabled:!_e()},"Done"),(0,i.createElement)("button",{onClick:Ie,disabled:!_e()},"Done & Add to Other Posts")),(0,i.createElement)("div",{class:"share-feedback-container"},(0,i.createElement)("a",{class:"share-feedback-text",onClick:e=>{e.preventDefault(),window.open("https://forms.gle/veiWWjFp1Bya8JEm8","_blank")}},"Share Feedback"))),(0,i.createElement)("div",{className:"edit-block",style:{display:Ae===c?"block":"none"}},(0,i.createElement)("div",{style:{height:"35px",maxWidth:"150px",marginBottom:"20px"}},(0,i.createElement)("a",{href:"https://www.humix.com/",target:"_blank"},(0,i.createElement)("img",{src:Ze}))),(0,i.createElement)("div",{style:{marginBottom:"15px"}},"Add this Humix Video to other posts in your site"),(0,i.createElement)("p",null,(0,i.createElement)(Xe,{disabled:ie,attributes:r,updateSelectedCategory:e=>{te(e)}})),(0,i.createElement)("p",null,(0,i.createElement)(b.SelectControl,{label:"Choose location in post to add this video:",disabled:ie,onChange:e=>{ne(e)},value:re,options:[{label:"Before 1st paragraph",value:"0"},{label:"Under 1st paragraph (recommended)",value:l},{label:"Under 2nd paragraph",value:"2"},{label:"Middle of page",value:"3"},{label:"Bottom of page",value:"4"}]})),(0,i.createElement)("p",null,(0,i.createElement)(b.RadioControl,{label:"If post already has one or more Humix Videos:",disabled:ie,onChange:e=>{ce(e)},selected:se,options:[{label:"Skip adding this video",value:E},{label:"Remove existing videos and add this one",value:P},{label:"Add this video without affecting other videos",value:"add_anyway"}]})),ie&&Oe>0&&(0,i.createElement)(b.Notice,{status:"info",isDismissible:!1,className:"ezhx-notice__loading"},(0,i.createElement)("p",null,(0,i.createElement)(b.Icon,{icon:"update",className:"ezhx-loading ezhx-info"}),(0,i.createElement)("span",null,"Adding video to ",(0,i.createElement)("strong",null,Oe)," posts... (",ke,"%)"))),(0,i.createElement)("div",{class:"ezhx-btn-group"},(0,i.createElement)("button",{disabled:ie,onClick:Fe,style:{backgroundColor:"white"}},"Cancel"),(0,i.createElement)("button",{disabled:ie,onClick:async()=>{if(!K)return;if(ie)return;k=0,j=0,_=0,R=0,Ce(0),Te(0),we(0),ue(0),Ee(0),oe(!0);let e="/wp/v2/posts?context=edit";parseInt(ee)>0&&(e+=`&categories=${ee}`);const t=await y()({path:e,method:"GET"}).catch((e=>{console.error(e),Le(!0)}));if(!Array.isArray(t))return void Le(!0);const i=T.id,o=t.filter((e=>e.id!==i));we(o.length);let a=o.map((e=>{let t=((e,t)=>{const r=e.some((e=>"humix/humix-block"===e.name||!("core/shortcode"!==e.name||"string"!=typeof e.originalContent||!e.originalContent.includes("[humix"))||!("string"!=typeof e.originalContent||!e.originalContent.includes('id="humix-'))));if(se===E&&r)return j++,Ee(j),!1;if(se===P&&r){let t=[];e.forEach((e=>{"humix/humix-block"!==e.name&&("core/shortcode"===e.name&&"string"==typeof e.originalContent&&e.originalContent.includes("[humix")||"string"==typeof e.originalContent&&e.originalContent.includes('id="humix-')||t.push(e))})),e=[...t]}switch(re){case"0":return e.unshift(t),e;case l:let r=[],n=0;return e.forEach((e=>{r.push(e),"core/paragraph"===e.name&&n++,1===n&&r.push(t)})),r.length===e.length?(_++,Ce(_),!1):r;case"2":let i=[],o=0;return e.forEach((e=>{i.push(e),"core/paragraph"===e.name&&o++,2===o&&i.push(t)})),i.length===e.length?(_++,Ce(_),!1):i;case"3":let a=Math.floor(e.length/2);return e.splice(a,0,t),e;case"4":return e.push(t),e;default:return e}})((0,n.parse)(e.content.raw),(0,n.createBlock)(C.name,r));if(!t)return Promise.resolve();const i=(0,n.serialize)(t);return y()({path:`/wp/v2/posts/${e.id}`,method:"POST",data:{content:i}}).then((()=>{k++,ue(k)})).catch((e=>{console.error(e),R++,Te(R)}))}));await Promise.all(a),Le()}},"Add to Posts"))))},save:function(e){let{attributes:t}=e;const r=p.useBlockProps.save(),{html:n,alignment:l}=t;let a={justifyContent:"center"};return"left"===l?a.justifyContent="flex-start":"right"===l&&(a.justifyContent="flex-end"),(0,i.createElement)("div",o({},r,{style:a}),(0,i.createElement)(i.RawHTML,null,n))},transforms:{from:[{type:"block",blocks:["core/embed"],isMatch(e){return rt.test(e.url)},transform(e){const t=lt();return t.url=e.url,t.displayType="url",(0,n.createBlock)("humix/humix-block",t)},priority:2},{type:"raw",isMatch:e=>"P"===e.nodeName&&rt.test(e.textContent),transform:e=>{const t=lt();return t.url=e.textContent.trim(),t.displayType="url",(0,n.createBlock)("humix/humix-block",t)},priority:1}]}};(0,n.registerBlockType)(ot.name,at)},8552:function(e,t,r){var n=r(852)(r(5639),"DataView");e.exports=n},1989:function(e,t,r){var n=r(1789),i=r(401),o=r(7667),l=r(1327),a=r(1866);function s(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}s.prototype.clear=n,s.prototype.delete=i,s.prototype.get=o,s.prototype.has=l,s.prototype.set=a,e.exports=s},8407:function(e,t,r){var n=r(7040),i=r(4125),o=r(2117),l=r(7518),a=r(4705);function s(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}s.prototype.clear=n,s.prototype.delete=i,s.prototype.get=o,s.prototype.has=l,s.prototype.set=a,e.exports=s},7071:function(e,t,r){var n=r(852)(r(5639),"Map");e.exports=n},3369:function(e,t,r){var n=r(4785),i=r(1285),o=r(6e3),l=r(9916),a=r(5265);function s(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}s.prototype.clear=n,s.prototype.delete=i,s.prototype.get=o,s.prototype.has=l,s.prototype.set=a,e.exports=s},3818:function(e,t,r){var n=r(852)(r(5639),"Promise");e.exports=n},8525:function(e,t,r){var n=r(852)(r(5639),"Set");e.exports=n},8668:function(e,t,r){var n=r(3369),i=r(619),o=r(2385);function l(e){var t=-1,r=null==e?0:e.length;for(this.__data__=new n;++t<r;)this.add(e[t])}l.prototype.add=l.prototype.push=i,l.prototype.has=o,e.exports=l},6384:function(e,t,r){var n=r(8407),i=r(7465),o=r(3779),l=r(7599),a=r(4758),s=r(4309);function c(e){var t=this.__data__=new n(e);this.size=t.size}c.prototype.clear=i,c.prototype.delete=o,c.prototype.get=l,c.prototype.has=a,c.prototype.set=s,e.exports=c},2705:function(e,t,r){var n=r(5639).Symbol;e.exports=n},1149:function(e,t,r){var n=r(5639).Uint8Array;e.exports=n},577:function(e,t,r){var n=r(852)(r(5639),"WeakMap");e.exports=n},7412:function(e){e.exports=function(e,t){for(var r=-1,n=null==e?0:e.length;++r<n&&!1!==t(e[r],r,e););return e}},4963:function(e){e.exports=function(e,t){for(var r=-1,n=null==e?0:e.length,i=0,o=[];++r<n;){var l=e[r];t(l,r,e)&&(o[i++]=l)}return o}},4636:function(e,t,r){var n=r(2545),i=r(5694),o=r(1469),l=r(4144),a=r(5776),s=r(6719),c=Object.prototype.hasOwnProperty;e.exports=function(e,t){var r=o(e),d=!r&&i(e),u=!r&&!d&&l(e),p=!r&&!d&&!u&&s(e),b=r||d||u||p,f=b?n(e.length,String):[],h=f.length;for(var y in e)!t&&!c.call(e,y)||b&&("length"==y||u&&("offset"==y||"parent"==y)||p&&("buffer"==y||"byteLength"==y||"byteOffset"==y)||a(y,h))||f.push(y);return f}},2488:function(e){e.exports=function(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}},2908:function(e){e.exports=function(e,t){for(var r=-1,n=null==e?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}},4865:function(e,t,r){var n=r(9465),i=r(7813),o=Object.prototype.hasOwnProperty;e.exports=function(e,t,r){var l=e[t];o.call(e,t)&&i(l,r)&&(void 0!==r||t in e)||n(e,t,r)}},8470:function(e,t,r){var n=r(7813);e.exports=function(e,t){for(var r=e.length;r--;)if(n(e[r][0],t))return r;return-1}},4037:function(e,t,r){var n=r(8363),i=r(3674);e.exports=function(e,t){return e&&n(t,i(t),e)}},3886:function(e,t,r){var n=r(8363),i=r(1704);e.exports=function(e,t){return e&&n(t,i(t),e)}},9465:function(e,t,r){var n=r(8777);e.exports=function(e,t,r){"__proto__"==t&&n?n(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}},5990:function(e,t,r){var n=r(6384),i=r(7412),o=r(4865),l=r(4037),a=r(3886),s=r(4626),c=r(278),d=r(8805),u=r(1911),p=r(8234),b=r(6904),f=r(4160),h=r(3824),y=r(9148),m=r(8517),g=r(1469),v=r(4144),O=r(6688),w=r(3218),S=r(2928),E=r(3674),P=r(1704),C="[object Arguments]",x="[object Function]",T="[object Object]",k={};k[C]=k["[object Array]"]=k["[object ArrayBuffer]"]=k["[object DataView]"]=k["[object Boolean]"]=k["[object Date]"]=k["[object Float32Array]"]=k["[object Float64Array]"]=k["[object Int8Array]"]=k["[object Int16Array]"]=k["[object Int32Array]"]=k["[object Map]"]=k["[object Number]"]=k[T]=k["[object RegExp]"]=k["[object Set]"]=k["[object String]"]=k["[object Symbol]"]=k["[object Uint8Array]"]=k["[object Uint8ClampedArray]"]=k["[object Uint16Array]"]=k["[object Uint32Array]"]=!0,k["[object Error]"]=k[x]=k["[object WeakMap]"]=!1,e.exports=function e(t,r,j,_,R,A){var D,M=1&r,N=2&r,B=4&r;if(j&&(D=R?j(t,_,R,A):j(t)),void 0!==D)return D;if(!w(t))return t;var F=g(t);if(F){if(D=h(t),!M)return c(t,D)}else{var I=f(t),L=I==x||"[object GeneratorFunction]"==I;if(v(t))return s(t,M);if(I==T||I==C||L&&!R){if(D=N||L?{}:m(t),!M)return N?u(t,a(D,t)):d(t,l(D,t))}else{if(!k[I])return R?t:{};D=y(t,I,M)}}A||(A=new n);var H=A.get(t);if(H)return H;A.set(t,D),S(t)?t.forEach((function(n){D.add(e(n,r,j,n,t,A))})):O(t)&&t.forEach((function(n,i){D.set(i,e(n,r,j,i,t,A))}));var V=F?void 0:(B?N?b:p:N?P:E)(t);return i(V||t,(function(n,i){V&&(n=t[i=n]),o(D,i,e(n,r,j,i,t,A))})),D}},3118:function(e,t,r){var n=r(3218),i=Object.create,o=function(){function e(){}return function(t){if(!n(t))return{};if(i)return i(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();e.exports=o},8866:function(e,t,r){var n=r(2488),i=r(1469);e.exports=function(e,t,r){var o=t(e);return i(e)?o:n(o,r(e))}},4239:function(e,t,r){var n=r(2705),i=r(9607),o=r(2333),l=n?n.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":l&&l in Object(e)?i(e):o(e)}},9454:function(e,t,r){var n=r(4239),i=r(7005);e.exports=function(e){return i(e)&&"[object Arguments]"==n(e)}},939:function(e,t,r){var n=r(2492),i=r(7005);e.exports=function e(t,r,o,l,a){return t===r||(null==t||null==r||!i(t)&&!i(r)?t!=t&&r!=r:n(t,r,o,l,e,a))}},2492:function(e,t,r){var n=r(6384),i=r(7114),o=r(8351),l=r(6096),a=r(4160),s=r(1469),c=r(4144),d=r(6719),u="[object Arguments]",p="[object Array]",b="[object Object]",f=Object.prototype.hasOwnProperty;e.exports=function(e,t,r,h,y,m){var g=s(e),v=s(t),O=g?p:a(e),w=v?p:a(t),S=(O=O==u?b:O)==b,E=(w=w==u?b:w)==b,P=O==w;if(P&&c(e)){if(!c(t))return!1;g=!0,S=!1}if(P&&!S)return m||(m=new n),g||d(e)?i(e,t,r,h,y,m):o(e,t,O,r,h,y,m);if(!(1&r)){var C=S&&f.call(e,"__wrapped__"),x=E&&f.call(t,"__wrapped__");if(C||x){var T=C?e.value():e,k=x?t.value():t;return m||(m=new n),y(T,k,r,h,m)}}return!!P&&(m||(m=new n),l(e,t,r,h,y,m))}},5588:function(e,t,r){var n=r(4160),i=r(7005);e.exports=function(e){return i(e)&&"[object Map]"==n(e)}},8458:function(e,t,r){var n=r(3560),i=r(5346),o=r(3218),l=r(346),a=/^\[object .+?Constructor\]$/,s=Function.prototype,c=Object.prototype,d=s.toString,u=c.hasOwnProperty,p=RegExp("^"+d.call(u).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!o(e)||i(e))&&(n(e)?p:a).test(l(e))}},9221:function(e,t,r){var n=r(4160),i=r(7005);e.exports=function(e){return i(e)&&"[object Set]"==n(e)}},8749:function(e,t,r){var n=r(4239),i=r(1780),o=r(7005),l={};l["[object Float32Array]"]=l["[object Float64Array]"]=l["[object Int8Array]"]=l["[object Int16Array]"]=l["[object Int32Array]"]=l["[object Uint8Array]"]=l["[object Uint8ClampedArray]"]=l["[object Uint16Array]"]=l["[object Uint32Array]"]=!0,l["[object Arguments]"]=l["[object Array]"]=l["[object ArrayBuffer]"]=l["[object Boolean]"]=l["[object DataView]"]=l["[object Date]"]=l["[object Error]"]=l["[object Function]"]=l["[object Map]"]=l["[object Number]"]=l["[object Object]"]=l["[object RegExp]"]=l["[object Set]"]=l["[object String]"]=l["[object WeakMap]"]=!1,e.exports=function(e){return o(e)&&i(e.length)&&!!l[n(e)]}},280:function(e,t,r){var n=r(5726),i=r(6916),o=Object.prototype.hasOwnProperty;e.exports=function(e){if(!n(e))return i(e);var t=[];for(var r in Object(e))o.call(e,r)&&"constructor"!=r&&t.push(r);return t}},313:function(e,t,r){var n=r(3218),i=r(5726),o=r(3498),l=Object.prototype.hasOwnProperty;e.exports=function(e){if(!n(e))return o(e);var t=i(e),r=[];for(var a in e)("constructor"!=a||!t&&l.call(e,a))&&r.push(a);return r}},2545:function(e){e.exports=function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}},1717:function(e){e.exports=function(e){return function(t){return e(t)}}},4757:function(e){e.exports=function(e,t){return e.has(t)}},4318:function(e,t,r){var n=r(1149);e.exports=function(e){var t=new e.constructor(e.byteLength);return new n(t).set(new n(e)),t}},4626:function(e,t,r){e=r.nmd(e);var n=r(5639),i=t&&!t.nodeType&&t,o=i&&e&&!e.nodeType&&e,l=o&&o.exports===i?n.Buffer:void 0,a=l?l.allocUnsafe:void 0;e.exports=function(e,t){if(t)return e.slice();var r=e.length,n=a?a(r):new e.constructor(r);return e.copy(n),n}},7157:function(e,t,r){var n=r(4318);e.exports=function(e,t){var r=t?n(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}},3147:function(e){var t=/\w*$/;e.exports=function(e){var r=new e.constructor(e.source,t.exec(e));return r.lastIndex=e.lastIndex,r}},419:function(e,t,r){var n=r(2705),i=n?n.prototype:void 0,o=i?i.valueOf:void 0;e.exports=function(e){return o?Object(o.call(e)):{}}},7133:function(e,t,r){var n=r(4318);e.exports=function(e,t){var r=t?n(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}},278:function(e){e.exports=function(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}},8363:function(e,t,r){var n=r(4865),i=r(9465);e.exports=function(e,t,r,o){var l=!r;r||(r={});for(var a=-1,s=t.length;++a<s;){var c=t[a],d=o?o(r[c],e[c],c,r,e):void 0;void 0===d&&(d=e[c]),l?i(r,c,d):n(r,c,d)}return r}},8805:function(e,t,r){var n=r(8363),i=r(9551);e.exports=function(e,t){return n(e,i(e),t)}},1911:function(e,t,r){var n=r(8363),i=r(1442);e.exports=function(e,t){return n(e,i(e),t)}},4429:function(e,t,r){var n=r(5639)["__core-js_shared__"];e.exports=n},8777:function(e,t,r){var n=r(852),i=function(){try{var e=n(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();e.exports=i},7114:function(e,t,r){var n=r(8668),i=r(2908),o=r(4757);e.exports=function(e,t,r,l,a,s){var c=1&r,d=e.length,u=t.length;if(d!=u&&!(c&&u>d))return!1;var p=s.get(e),b=s.get(t);if(p&&b)return p==t&&b==e;var f=-1,h=!0,y=2&r?new n:void 0;for(s.set(e,t),s.set(t,e);++f<d;){var m=e[f],g=t[f];if(l)var v=c?l(g,m,f,t,e,s):l(m,g,f,e,t,s);if(void 0!==v){if(v)continue;h=!1;break}if(y){if(!i(t,(function(e,t){if(!o(y,t)&&(m===e||a(m,e,r,l,s)))return y.push(t)}))){h=!1;break}}else if(m!==g&&!a(m,g,r,l,s)){h=!1;break}}return s.delete(e),s.delete(t),h}},8351:function(e,t,r){var n=r(2705),i=r(1149),o=r(7813),l=r(7114),a=r(8776),s=r(1814),c=n?n.prototype:void 0,d=c?c.valueOf:void 0;e.exports=function(e,t,r,n,c,u,p){switch(r){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!u(new i(e),new i(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return o(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var b=a;case"[object Set]":var f=1&n;if(b||(b=s),e.size!=t.size&&!f)return!1;var h=p.get(e);if(h)return h==t;n|=2,p.set(e,t);var y=l(b(e),b(t),n,c,u,p);return p.delete(e),y;case"[object Symbol]":if(d)return d.call(e)==d.call(t)}return!1}},6096:function(e,t,r){var n=r(8234),i=Object.prototype.hasOwnProperty;e.exports=function(e,t,r,o,l,a){var s=1&r,c=n(e),d=c.length;if(d!=n(t).length&&!s)return!1;for(var u=d;u--;){var p=c[u];if(!(s?p in t:i.call(t,p)))return!1}var b=a.get(e),f=a.get(t);if(b&&f)return b==t&&f==e;var h=!0;a.set(e,t),a.set(t,e);for(var y=s;++u<d;){var m=e[p=c[u]],g=t[p];if(o)var v=s?o(g,m,p,t,e,a):o(m,g,p,e,t,a);if(!(void 0===v?m===g||l(m,g,r,o,a):v)){h=!1;break}y||(y="constructor"==p)}if(h&&!y){var O=e.constructor,w=t.constructor;O==w||!("constructor"in e)||!("constructor"in t)||"function"==typeof O&&O instanceof O&&"function"==typeof w&&w instanceof w||(h=!1)}return a.delete(e),a.delete(t),h}},1957:function(e,t,r){var n="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g;e.exports=n},8234:function(e,t,r){var n=r(8866),i=r(9551),o=r(3674);e.exports=function(e){return n(e,o,i)}},6904:function(e,t,r){var n=r(8866),i=r(1442),o=r(1704);e.exports=function(e){return n(e,o,i)}},5050:function(e,t,r){var n=r(7019);e.exports=function(e,t){var r=e.__data__;return n(t)?r["string"==typeof t?"string":"hash"]:r.map}},852:function(e,t,r){var n=r(8458),i=r(7801);e.exports=function(e,t){var r=i(e,t);return n(r)?r:void 0}},5924:function(e,t,r){var n=r(5569)(Object.getPrototypeOf,Object);e.exports=n},9607:function(e,t,r){var n=r(2705),i=Object.prototype,o=i.hasOwnProperty,l=i.toString,a=n?n.toStringTag:void 0;e.exports=function(e){var t=o.call(e,a),r=e[a];try{e[a]=void 0;var n=!0}catch(e){}var i=l.call(e);return n&&(t?e[a]=r:delete e[a]),i}},9551:function(e,t,r){var n=r(4963),i=r(479),o=Object.prototype.propertyIsEnumerable,l=Object.getOwnPropertySymbols,a=l?function(e){return null==e?[]:(e=Object(e),n(l(e),(function(t){return o.call(e,t)})))}:i;e.exports=a},1442:function(e,t,r){var n=r(2488),i=r(5924),o=r(9551),l=r(479),a=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)n(t,o(e)),e=i(e);return t}:l;e.exports=a},4160:function(e,t,r){var n=r(8552),i=r(7071),o=r(3818),l=r(8525),a=r(577),s=r(4239),c=r(346),d="[object Map]",u="[object Promise]",p="[object Set]",b="[object WeakMap]",f="[object DataView]",h=c(n),y=c(i),m=c(o),g=c(l),v=c(a),O=s;(n&&O(new n(new ArrayBuffer(1)))!=f||i&&O(new i)!=d||o&&O(o.resolve())!=u||l&&O(new l)!=p||a&&O(new a)!=b)&&(O=function(e){var t=s(e),r="[object Object]"==t?e.constructor:void 0,n=r?c(r):"";if(n)switch(n){case h:return f;case y:return d;case m:return u;case g:return p;case v:return b}return t}),e.exports=O},7801:function(e){e.exports=function(e,t){return null==e?void 0:e[t]}},1789:function(e,t,r){var n=r(4536);e.exports=function(){this.__data__=n?n(null):{},this.size=0}},401:function(e){e.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}},7667:function(e,t,r){var n=r(4536),i=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;if(n){var r=t[e];return"__lodash_hash_undefined__"===r?void 0:r}return i.call(t,e)?t[e]:void 0}},1327:function(e,t,r){var n=r(4536),i=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;return n?void 0!==t[e]:i.call(t,e)}},1866:function(e,t,r){var n=r(4536);e.exports=function(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=n&&void 0===t?"__lodash_hash_undefined__":t,this}},3824:function(e){var t=Object.prototype.hasOwnProperty;e.exports=function(e){var r=e.length,n=new e.constructor(r);return r&&"string"==typeof e[0]&&t.call(e,"index")&&(n.index=e.index,n.input=e.input),n}},9148:function(e,t,r){var n=r(4318),i=r(7157),o=r(3147),l=r(419),a=r(7133);e.exports=function(e,t,r){var s=e.constructor;switch(t){case"[object ArrayBuffer]":return n(e);case"[object Boolean]":case"[object Date]":return new s(+e);case"[object DataView]":return i(e,r);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return a(e,r);case"[object Map]":case"[object Set]":return new s;case"[object Number]":case"[object String]":return new s(e);case"[object RegExp]":return o(e);case"[object Symbol]":return l(e)}}},8517:function(e,t,r){var n=r(3118),i=r(5924),o=r(5726);e.exports=function(e){return"function"!=typeof e.constructor||o(e)?{}:n(i(e))}},5776:function(e){var t=/^(?:0|[1-9]\d*)$/;e.exports=function(e,r){var n=typeof e;return!!(r=null==r?9007199254740991:r)&&("number"==n||"symbol"!=n&&t.test(e))&&e>-1&&e%1==0&&e<r}},7019:function(e){e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},5346:function(e,t,r){var n,i=r(4429),o=(n=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"";e.exports=function(e){return!!o&&o in e}},5726:function(e){var t=Object.prototype;e.exports=function(e){var r=e&&e.constructor;return e===("function"==typeof r&&r.prototype||t)}},7040:function(e){e.exports=function(){this.__data__=[],this.size=0}},4125:function(e,t,r){var n=r(8470),i=Array.prototype.splice;e.exports=function(e){var t=this.__data__,r=n(t,e);return!(r<0||(r==t.length-1?t.pop():i.call(t,r,1),--this.size,0))}},2117:function(e,t,r){var n=r(8470);e.exports=function(e){var t=this.__data__,r=n(t,e);return r<0?void 0:t[r][1]}},7518:function(e,t,r){var n=r(8470);e.exports=function(e){return n(this.__data__,e)>-1}},4705:function(e,t,r){var n=r(8470);e.exports=function(e,t){var r=this.__data__,i=n(r,e);return i<0?(++this.size,r.push([e,t])):r[i][1]=t,this}},4785:function(e,t,r){var n=r(1989),i=r(8407),o=r(7071);e.exports=function(){this.size=0,this.__data__={hash:new n,map:new(o||i),string:new n}}},1285:function(e,t,r){var n=r(5050);e.exports=function(e){var t=n(this,e).delete(e);return this.size-=t?1:0,t}},6e3:function(e,t,r){var n=r(5050);e.exports=function(e){return n(this,e).get(e)}},9916:function(e,t,r){var n=r(5050);e.exports=function(e){return n(this,e).has(e)}},5265:function(e,t,r){var n=r(5050);e.exports=function(e,t){var r=n(this,e),i=r.size;return r.set(e,t),this.size+=r.size==i?0:1,this}},8776:function(e){e.exports=function(e){var t=-1,r=Array(e.size);return e.forEach((function(e,n){r[++t]=[n,e]})),r}},4536:function(e,t,r){var n=r(852)(Object,"create");e.exports=n},6916:function(e,t,r){var n=r(5569)(Object.keys,Object);e.exports=n},3498:function(e){e.exports=function(e){var t=[];if(null!=e)for(var r in Object(e))t.push(r);return t}},1167:function(e,t,r){e=r.nmd(e);var n=r(1957),i=t&&!t.nodeType&&t,o=i&&e&&!e.nodeType&&e,l=o&&o.exports===i&&n.process,a=function(){try{return o&&o.require&&o.require("util").types||l&&l.binding&&l.binding("util")}catch(e){}}();e.exports=a},2333:function(e){var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},5569:function(e){e.exports=function(e,t){return function(r){return e(t(r))}}},5639:function(e,t,r){var n=r(1957),i="object"==typeof self&&self&&self.Object===Object&&self,o=n||i||Function("return this")();e.exports=o},619:function(e){e.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}},2385:function(e){e.exports=function(e){return this.__data__.has(e)}},1814:function(e){e.exports=function(e){var t=-1,r=Array(e.size);return e.forEach((function(e){r[++t]=e})),r}},7465:function(e,t,r){var n=r(8407);e.exports=function(){this.__data__=new n,this.size=0}},3779:function(e){e.exports=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}},7599:function(e){e.exports=function(e){return this.__data__.get(e)}},4758:function(e){e.exports=function(e){return this.__data__.has(e)}},4309:function(e,t,r){var n=r(8407),i=r(7071),o=r(3369);e.exports=function(e,t){var r=this.__data__;if(r instanceof n){var l=r.__data__;if(!i||l.length<199)return l.push([e,t]),this.size=++r.size,this;r=this.__data__=new o(l)}return r.set(e,t),this.size=r.size,this}},346:function(e){var t=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return t.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},361:function(e,t,r){var n=r(5990);e.exports=function(e){return n(e,5)}},7813:function(e){e.exports=function(e,t){return e===t||e!=e&&t!=t}},5694:function(e,t,r){var n=r(9454),i=r(7005),o=Object.prototype,l=o.hasOwnProperty,a=o.propertyIsEnumerable,s=n(function(){return arguments}())?n:function(e){return i(e)&&l.call(e,"callee")&&!a.call(e,"callee")};e.exports=s},1469:function(e){var t=Array.isArray;e.exports=t},8612:function(e,t,r){var n=r(3560),i=r(1780);e.exports=function(e){return null!=e&&i(e.length)&&!n(e)}},4144:function(e,t,r){e=r.nmd(e);var n=r(5639),i=r(5062),o=t&&!t.nodeType&&t,l=o&&e&&!e.nodeType&&e,a=l&&l.exports===o?n.Buffer:void 0,s=(a?a.isBuffer:void 0)||i;e.exports=s},8446:function(e,t,r){var n=r(939);e.exports=function(e,t){return n(e,t)}},3560:function(e,t,r){var n=r(4239),i=r(3218);e.exports=function(e){if(!i(e))return!1;var t=n(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},1780:function(e){e.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}},6688:function(e,t,r){var n=r(5588),i=r(1717),o=r(1167),l=o&&o.isMap,a=l?i(l):n;e.exports=a},3218:function(e){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},7005:function(e){e.exports=function(e){return null!=e&&"object"==typeof e}},2928:function(e,t,r){var n=r(9221),i=r(1717),o=r(1167),l=o&&o.isSet,a=l?i(l):n;e.exports=a},6719:function(e,t,r){var n=r(8749),i=r(1717),o=r(1167),l=o&&o.isTypedArray,a=l?i(l):n;e.exports=a},3674:function(e,t,r){var n=r(4636),i=r(280),o=r(8612);e.exports=function(e){return o(e)?n(e):i(e)}},1704:function(e,t,r){var n=r(4636),i=r(313),o=r(8612);e.exports=function(e){return o(e)?n(e,!0):i(e)}},479:function(e){e.exports=function(){return[]}},5062:function(e){e.exports=function(){return!1}},1038:function(e,t,r){var n;n=e=>(()=>{var t={865:e=>{"use strict";e.exports=function(e,t){var r=e.filter(t);return 0!==r.length&&r.length!==e.length}},703:(e,t,r)=>{"use strict";var n=r(414);function i(){}function o(){}o.resetWarningCache=i,e.exports=function(){function e(e,t,r,i,o,l){if(l!==n){var a=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw a.name="Invariant Violation",a}}function t(){return e}e.isRequired=e;var r={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:i};return r.PropTypes=r,r}},697:(e,t,r)=>{e.exports=r(703)()},414:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},385:function(e,t,r){var n;n=function(e){return function(e){var t={};function r(n){if(t[n])return t[n].exports;var i=t[n]={exports:{},id:n,loaded:!1};return e[n].call(i.exports,i,i.exports,r),i.loaded=!0,i.exports}return r.m=e,r.c=t,r.p="",r(0)}([function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}();function o(e){return e&&e.__esModule?e:{default:e}}var l=r(8),a=o(l),s=o(r(6)),c=o(r(2)),d=r(1),u=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t,r){for(var n=!0;n;){var i=e,o=t,l=r;n=!1,null===i&&(i=Function.prototype);var a=Object.getOwnPropertyDescriptor(i,o);if(void 0!==a){if("value"in a)return a.value;var s=a.get;if(void 0===s)return;return s.call(l)}var c=Object.getPrototypeOf(i);if(null===c)return;e=c,t=o,r=l,n=!0,a=c=void 0}}(Object.getPrototypeOf(t.prototype),"constructor",this).call(this),this.state={showLoader:!1,lastScrollTop:0,actionTriggered:!1,pullToRefreshThresholdBreached:!1},this.startY=0,this.currentY=0,this.dragging=!1,this.maxPullDownDistance=0,this.onScrollListener=this.onScrollListener.bind(this),this.throttledOnScrollListener=(0,c.default)(this.onScrollListener,150).bind(this),this.onStart=this.onStart.bind(this),this.onMove=this.onMove.bind(this),this.onEnd=this.onEnd.bind(this),this.getScrollableTarget=this.getScrollableTarget.bind(this)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"componentDidMount",value:function(){if(this._scrollableNode=this.getScrollableTarget(),this.el=this.props.height?this._infScroll:this._scrollableNode||window,this.el.addEventListener("scroll",this.throttledOnScrollListener),"number"==typeof this.props.initialScrollY&&this.el.scrollHeight>this.props.initialScrollY&&this.el.scrollTo(0,this.props.initialScrollY),this.props.pullDownToRefresh&&(this.el.addEventListener("touchstart",this.onStart),this.el.addEventListener("touchmove",this.onMove),this.el.addEventListener("touchend",this.onEnd),this.el.addEventListener("mousedown",this.onStart),this.el.addEventListener("mousemove",this.onMove),this.el.addEventListener("mouseup",this.onEnd),this.maxPullDownDistance=this._pullDown.firstChild.getBoundingClientRect().height,this.forceUpdate(),"function"!=typeof this.props.refreshFunction))throw new Error('Mandatory prop "refreshFunction" missing.\n Pull Down To Refresh functionality will not work\n as expected. Check README.md for usage\'')}},{key:"componentWillUnmount",value:function(){this.el.removeEventListener("scroll",this.throttledOnScrollListener),this.props.pullDownToRefresh&&(this.el.removeEventListener("touchstart",this.onStart),this.el.removeEventListener("touchmove",this.onMove),this.el.removeEventListener("touchend",this.onEnd),this.el.removeEventListener("mousedown",this.onStart),this.el.removeEventListener("mousemove",this.onMove),this.el.removeEventListener("mouseup",this.onEnd))}},{key:"componentWillReceiveProps",value:function(e){this.props.key===e.key&&this.props.dataLength===e.dataLength||this.setState({showLoader:!1,actionTriggered:!1,pullToRefreshThresholdBreached:!1})}},{key:"getScrollableTarget",value:function(){return this.props.scrollableTarget instanceof HTMLElement?this.props.scrollableTarget:"string"==typeof this.props.scrollableTarget?document.getElementById(this.props.scrollableTarget):(null===this.props.scrollableTarget&&console.warn("You are trying to pass scrollableTarget but it is null. This might\n happen because the element may not have been added to DOM yet.\n See https://github.com/ankeetmaini/react-infinite-scroll-component/issues/59 for more info.\n "),null)}},{key:"onStart",value:function(e){this.state.lastScrollTop||(this.dragging=!0,this.startY=e.pageY||e.touches[0].pageY,this.currentY=this.startY,this._infScroll.style.willChange="transform",this._infScroll.style.transition="transform 0.2s cubic-bezier(0,0,0.31,1)")}},{key:"onMove",value:function(e){this.dragging&&(this.currentY=e.pageY||e.touches[0].pageY,this.currentY<this.startY||(this.currentY-this.startY>=this.props.pullDownToRefreshThreshold&&this.setState({pullToRefreshThresholdBreached:!0}),this.currentY-this.startY>1.5*this.maxPullDownDistance||(this._infScroll.style.overflow="visible",this._infScroll.style.transform="translate3d(0px, "+(this.currentY-this.startY)+"px, 0px)")))}},{key:"onEnd",value:function(e){var t=this;this.startY=0,this.currentY=0,this.dragging=!1,this.state.pullToRefreshThresholdBreached&&this.props.refreshFunction&&this.props.refreshFunction(),requestAnimationFrame((function(){t._infScroll&&(t._infScroll.style.overflow="auto",t._infScroll.style.transform="none",t._infScroll.style.willChange="none")}))}},{key:"isElementAtBottom",value:function(e){var t=arguments.length<=1||void 0===arguments[1]?.8:arguments[1],r=e===document.body||e===document.documentElement?window.screen.availHeight:e.clientHeight,n=(0,d.parseThreshold)(t);return n.unit===d.ThresholdUnits.Pixel?e.scrollTop+r>=e.scrollHeight-n.value:e.scrollTop+r>=n.value/100*e.scrollHeight}},{key:"onScrollListener",value:function(e){var t=this;"function"==typeof this.props.onScroll&&setTimeout((function(){return t.props.onScroll(e)}),0);var r=this.props.height||this._scrollableNode?e.target:document.documentElement.scrollTop?document.documentElement:document.body;this.state.actionTriggered||(this.isElementAtBottom(r,this.props.scrollThreshold)&&this.props.hasMore&&(this.setState({actionTriggered:!0,showLoader:!0}),this.props.next()),this.setState({lastScrollTop:r.scrollTop}))}},{key:"render",value:function(){var e=this,t=n({height:this.props.height||"auto",overflow:"auto",WebkitOverflowScrolling:"touch"},this.props.style),r=this.props.hasChildren||!(!this.props.children||!this.props.children.length),i=this.props.pullDownToRefresh&&this.props.height?{overflow:"auto"}:{};return a.default.createElement("div",{style:i},a.default.createElement("div",{className:"infinite-scroll-component "+(this.props.className||""),ref:function(t){return e._infScroll=t},style:t},this.props.pullDownToRefresh&&a.default.createElement("div",{style:{position:"relative"},ref:function(t){return e._pullDown=t}},a.default.createElement("div",{style:{position:"absolute",left:0,right:0,top:-1*this.maxPullDownDistance}},!this.state.pullToRefreshThresholdBreached&&this.props.pullDownToRefreshContent,this.state.pullToRefreshThresholdBreached&&this.props.releaseToRefreshContent)),this.props.children,!this.state.showLoader&&!r&&this.props.hasMore&&this.props.loader,this.state.showLoader&&this.props.hasMore&&this.props.loader,!this.props.hasMore&&this.props.endMessage))}}]),t}(l.Component);t.default=u,u.defaultProps={pullDownToRefreshContent:a.default.createElement("h3",null,"Pull down to refresh"),releaseToRefreshContent:a.default.createElement("h3",null,"Release to refresh"),pullDownToRefreshThreshold:100,disableBrowserPullToRefresh:!0},u.propTypes={next:s.default.func,hasMore:s.default.bool,children:s.default.node,loader:s.default.node.isRequired,scrollThreshold:s.default.oneOfType([s.default.number,s.default.string]),endMessage:s.default.node,style:s.default.object,height:s.default.number,scrollableTarget:s.default.node,hasChildren:s.default.bool,pullDownToRefresh:s.default.bool,pullDownToRefreshContent:s.default.node,releaseToRefreshContent:s.default.node,pullDownToRefreshThreshold:s.default.number,refreshFunction:s.default.func,onScroll:s.default.func,dataLength:s.default.number.isRequired,key:s.default.string},e.exports=t.default},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseThreshold=function(e){return"number"==typeof e?{unit:r.Percent,value:100*e}:"string"==typeof e?e.match(/^(\d*(\.\d+)?)px$/)?{unit:r.Pixel,value:parseFloat(e)}:e.match(/^(\d*(\.\d+)?)%$/)?{unit:r.Percent,value:parseFloat(e)}:(console.warn('scrollThreshold format is invalid. Valid formats: "120px", "50%"...'),n):(console.warn("scrollThreshold should be string or number"),n)};var r={Pixel:"Pixel",Percent:"Percent"};t.ThresholdUnits=r;var n={unit:r.Percent,value:.8}},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,r){var n,i;return t||(t=250),function(){var o=r||this,l=+new Date,a=arguments;n&&l<n+t?(clearTimeout(i),i=setTimeout((function(){n=l,e.apply(o,a)}),t)):(n=l,e.apply(o,a))}},e.exports=t.default},function(e,t){"use strict";function r(e){return function(){return e}}var n=function(){};n.thatReturns=r,n.thatReturnsFalse=r(!1),n.thatReturnsTrue=r(!0),n.thatReturnsNull=r(null),n.thatReturnsThis=function(){return this},n.thatReturnsArgument=function(e){return e},e.exports=n},function(e,t,r){"use strict";e.exports=function(e,t,r,n,i,o,l,a){if(!e){var s;if(void 0===t)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[r,n,i,o,l,a],d=0;(s=new Error(t.replace(/%s/g,(function(){return c[d++]})))).name="Invariant Violation"}throw s.framesToPop=1,s}}},function(e,t,r){"use strict";var n=r(3),i=r(4),o=r(7);e.exports=function(){function e(e,t,r,n,l,a){a!==o&&i(!1,"Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types")}function t(){return e}e.isRequired=e;var r={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t};return r.checkPropTypes=n,r.PropTypes=r,r}},function(e,t,r){e.exports=r(5)()},function(e,t){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(t,r){t.exports=e}])},e.exports=n(r(787))},787:t=>{"use strict";t.exports=e}},r={};function n(e){var i=r[e];if(void 0!==i)return i.exports;var o=r[e]={exports:{}};return t[e].call(o.exports,o,o.exports,n),o.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};return(()=>{"use strict";n.r(i),n.d(i,{default:()=>Gt});var e=n(697),t=n.n(e),r=n(787),o=n.n(r);const l=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object.keys(e).reduce((function(t,r){return t["data-".concat(function(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}(r))]=e[r],t}),{})},a=function(e){return!e||Array.isArray(e)&&!e.length};var s,c;const d=(s=1,c=new WeakMap,{get:function(e){return c.has(e)||c.set(e,s++),"".concat("rdts").concat(c.get(e))},reset:function(){c=new WeakMap,s=1}}),u=function(e,t,r){if(Array.prototype.findIndex)return e.findIndex(t,r);if(!e)throw new TypeError("findIndex called on null or undefined");if("function"!=typeof t)throw new TypeError("findIndex predicate must be a function");for(var n=0;n<e.length;n++){var i=e[n];if(t.call(r,i,n,e))return n}return-1};function p(e,t){var r=function(e){return e?"#"===e[0]?{"aria-labelledby":e.substring(1).replace(/ #/g," ")}:{"aria-label":e}:{}}(e);return t&&(r["aria-labelledby"]="".concat(r["aria-labelledby"]||""," ").concat(t).trim()),r}function b(e){return b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},b(e)}function f(){return f=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},f.apply(this,arguments)}function h(e,t){return h=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},h(e,t)}function y(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function m(e){return m=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},m(e)}function g(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var v=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&h(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=m(n);if(i){var r=m(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===b(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return y(e)}(this,e)});function a(e){var t,r,n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),g(y(t=l.call(this,e)),"handleInputChange",(function(e){e.persist(),t.delayedCallback(e)})),t.delayedCallback=(r=function(e){return t.props.onInputChange(e.target.value)},function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var o=!n;clearTimeout(n),n=setTimeout((function(){n=null,r.apply(void 0,t)}),300),o&&r.apply(void 0,t)}),t}return t=a,(r=[{key:"render",value:function(){var e=this.props,t=e.inputRef,r=e.texts,n=void 0===r?{}:r,i=e.onFocus,l=e.onBlur,a=e.disabled,s=e.readOnly,c=e.onKeyDown,d=e.activeDescendant,u=e.inlineSearchInput;return o().createElement("input",f({type:"text",disabled:a,ref:t,className:"search",placeholder:u?n.inlineSearchPlaceholder||"Search...":n.placeholder||"Choose...",onKeyDown:c,onChange:this.handleInputChange,onFocus:i,onBlur:l,readOnly:s,"aria-activedescendant":d,"aria-autocomplete":c?"list":void 0},p(n.label)))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);g(v,"propTypes",{tags:t().array,texts:t().object,onInputChange:t().func,onFocus:t().func,onBlur:t().func,onTagRemove:t().func,onKeyDown:t().func,inputRef:t().func,disabled:t().bool,readOnly:t().bool,activeDescendant:t().string,inlineSearchInput:t().bool});const O=v;function w(e){return w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},w(e)}function S(e,t){return S=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},S(e,t)}function E(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function P(e){return P=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},P(e)}function C(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var x=function(e){return"".concat(e,"_tag")},T=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&S(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=P(n);if(i){var r=P(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===w(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return E(e)}(this,e)});function a(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return C(E(e=l.call.apply(l,[this].concat(r))),"handleClick",(function(t){var r=e.props,n=r.id,i=r.onDelete;t.stopPropagation(),t.nativeEvent.stopImmediatePropagation(),i(n,void 0!==(t.key||t.keyCode))})),C(E(e),"onKeyDown",(function(t){"Backspace"===t.key&&(e.handleClick(t),t.preventDefault())})),C(E(e),"onKeyUp",(function(t){(32===t.keyCode||["Delete","Enter"].indexOf(t.key)>-1)&&(e.handleClick(t),t.preventDefault())})),e}return t=a,(r=[{key:"render",value:function(){var e=this.props,t=e.id,r=e.label,n=e.labelRemove,i=void 0===n?"Remove":n,l=e.readOnly,a=e.disabled,s=x(t),c="".concat(t,"_button"),d=["tag-remove",l&&"readOnly",a&&"disabled"].filter(Boolean).join(" "),u=l||a;return o().createElement("span",{className:"tag",id:s,"aria-label":r},r,o().createElement("button",{id:c,onClick:u?void 0:this.handleClick,onKeyDown:u?void 0:this.onKeyDown,onKeyUp:u?void 0:this.onKeyUp,className:d,type:"button","aria-label":i,"aria-labelledby":"".concat(c," ").concat(s),"aria-disabled":u},"x"))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);C(T,"propTypes",{id:t().string.isRequired,label:t().string.isRequired,onDelete:t().func,readOnly:t().bool,disabled:t().bool,labelRemove:t().string});const k=T;function j(e){return j="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},j(e)}function _(e,t){return _=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},_(e,t)}function R(e){return R=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},R(e)}function A(){return A=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},A.apply(this,arguments)}var D,M,N,B=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&_(e,t)}(s,e);var t,r,n,i,a=(n=s,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=R(n);if(i){var r=R(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===j(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function s(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s),a.apply(this,arguments)}return t=s,r=[{key:"render",value:function(){var e=this.props,t=e.tags,r=e.onTagRemove,n=e.texts,i=void 0===n?{}:n,a=e.disabled,s=e.readOnly,c=e.children||o().createElement("span",{className:"placeholder"},i.placeholder||"Choose...");return o().createElement("ul",{className:"tag-list"},function(){var e=arguments.length>1?arguments[1]:void 0,t=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0,n=arguments.length>4?arguments[4]:void 0;return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).map((function(i){var a=i._id,s=i.label,c=i.tagClassName,d=i.dataset,u=i.tagLabel;return o().createElement("li",A({className:["tag-item",c].filter(Boolean).join(" "),key:"tag-item-".concat(a)},l(d)),o().createElement(k,{label:u||s,id:a,onDelete:e,readOnly:t,disabled:r||i.disabled,labelRemove:n}))}))}(t,r,s,a,i.labelRemove),o().createElement("li",{className:"tag-item"},c))}}],r&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),s}(r.PureComponent);D=B,M="propTypes",N={tags:t().array,onTagRemove:t().func,readOnly:t().bool,disabled:t().bool,texts:t().object,children:t().node},M in D?Object.defineProperty(D,M,{value:N,enumerable:!0,configurable:!0,writable:!0}):D[M]=N;const F=B;function I(e){return I="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},I(e)}function L(){return L=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},L.apply(this,arguments)}function H(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function V(e,t){return V=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},V(e,t)}function U(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function G(e){return G=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},G(e)}function q(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var W=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&V(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=G(n);if(i){var r=G(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===I(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return U(e)}(this,e)});function a(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return q(U(e=l.call.apply(l,[this].concat(r))),"getAriaAttributes",(function(){var t=e.props,r=t.mode,n=t.texts,i=void 0===n?{}:n,o=t.showDropdown,l=t.clientId,a=t.tags,s="".concat(l,"_trigger"),c=[],d=p(i.label);return a&&a.length&&(d["aria-label"]&&c.push(s),a.forEach((function(e){c.push(x(e._id))})),d=p(i.label,c.join(" "))),function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?H(Object(r),!0).forEach((function(t){q(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):H(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({id:s,role:"button",tabIndex:e.props.tabIndex,"aria-haspopup":"simpleSelect"===r?"listbox":"tree","aria-expanded":o?"true":"false"},d)})),q(U(e),"handleTrigger",(function(t){t.key&&13!==t.keyCode&&32!==t.keyCode&&40!==t.keyCode||t.key&&e.triggerNode&&e.triggerNode!==document.activeElement||(e.props.showDropdown||32!==t.keyCode||t.preventDefault(),e.props.onTrigger(t))})),e}return t=a,(r=[{key:"render",value:function(){var e=this,t=this.props,r=t.disabled,n=t.readOnly,i=t.showDropdown,l=["dropdown-trigger","arrow",r&&"disabled",n&&"readOnly",i&&"top",!i&&"bottom"].filter(Boolean).join(" ");return o().createElement("a",L({ref:function(t){e.triggerNode=t},className:l,onClick:r?void 0:this.handleTrigger,onKeyDown:r?void 0:this.handleTrigger},this.getAriaAttributes()),this.props.children)}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);q(W,"propTypes",{onTrigger:t().func,disabled:t().bool,readOnly:t().bool,showDropdown:t().bool,mode:t().oneOf(["multiSelect","simpleSelect","radioSelect","hierarchical"]),texts:t().object,clientId:t().string,tags:t().array,tabIndex:t().number});const z=W;var $=n(385),K=n.n($);function Y(e){return Y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Y(e)}function J(e,t){return J=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},J(e,t)}function Q(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function X(e){return X=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},X(e)}function Z(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var ee=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&J(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=X(n);if(i){var r=X(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Y(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Q(e)}(this,e)});function a(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Z(Q(e=l.call.apply(l,[this].concat(r))),"handleClick",(function(){var t=e.props,r=t.onAction,n=t.actionData;r&&r(n.nodeId,n.action)})),e}return t=a,(r=[{key:"render",value:function(){var e=this.props,t=e.title,r=e.className,n=e.text,i=e.readOnly;return o().createElement("i",{title:t,className:r,onClick:i?void 0:this.handleClick},n)}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);Z(ee,"propTypes",{title:t().string,text:t().string,className:t().string,actionData:t().object,onAction:t().func,readOnly:t().bool}),Z(ee,"defaultProps",{onAction:function(){}});const te=ee;function re(e){return re="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},re(e)}var ne=["actions","id"];function ie(){return ie=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ie.apply(this,arguments)}function oe(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function le(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?oe(Object(r),!0).forEach((function(t){ce(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):oe(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function ae(e,t){return ae=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},ae(e,t)}function se(e){return se=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},se(e)}function ce(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var de=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ae(e,t)}(s,e);var t,r,n,i,l=(n=s,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=se(n);if(i){var r=se(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===re(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function s(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s),l.apply(this,arguments)}return t=s,(r=[{key:"render",value:function(){var e=this.props,t=e.actions,r=e.id,n=function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},o=Object.keys(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,ne);return a(t)?null:t.map((function(e,t){var i=e.id||"action-".concat(t);return o().createElement(te,ie({key:i},n,e,{actionData:{action:le(le({},e),{},{id:i}),nodeId:r}}))}))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),s}(r.PureComponent);ce(de,"propTypes",{id:t().string.isRequired,actions:t().array});const ue=de;function pe(e){return pe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},pe(e)}var be=["checked","indeterminate","onChange","disabled","readOnly"];function fe(){return fe=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},fe.apply(this,arguments)}function he(e,t){return he=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},he(e,t)}function ye(e){return ye=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},ye(e)}var me=function(e){var t=e.checked,r=e.indeterminate;return function(e){e&&(e.checked=t,e.indeterminate=r)}},ge=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&he(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=ye(n);if(i){var r=ye(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===pe(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function a(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),l.apply(this,arguments)}return t=a,(r=[{key:"render",value:function(){var e=this.props,t=e.checked,r=e.indeterminate,n=void 0!==r&&r,i=e.onChange,l=e.disabled,a=e.readOnly,s=function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},o=Object.keys(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,be),c=l||a;return o().createElement("input",fe({type:"checkbox",ref:me({checked:t,indeterminate:n}),onChange:i,disabled:c},s))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);!function(e,t,r){t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r}(ge,"propTypes",{checked:t().bool,indeterminate:t().bool,onChange:t().func,disabled:t().bool,readOnly:t().bool});const ve=ge;function Oe(e){return Oe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Oe(e)}var we=["name","checked","onChange","disabled","readOnly"];function Se(){return Se=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Se.apply(this,arguments)}function Ee(e,t){return Ee=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Ee(e,t)}function Pe(e){return Pe=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Pe(e)}var Ce=function(e){var t=e.checked;return function(e){e&&(e.checked=t)}},xe=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Ee(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Pe(n);if(i){var r=Pe(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Oe(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function a(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),l.apply(this,arguments)}return t=a,(r=[{key:"render",value:function(){var e=this.props,t=e.name,r=e.checked,n=e.onChange,i=e.disabled,l=e.readOnly,a=function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},o=Object.keys(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,we),s=i||l;return o().createElement("input",Se({type:"radio",name:t,ref:Ce({checked:r}),onChange:n,disabled:s},a))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);!function(e,t,r){t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r}(xe,"propTypes",{name:t().string.isRequired,checked:t().bool,onChange:t().func,disabled:t().bool,readOnly:t().bool});const Te=xe;function ke(e){return ke="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ke(e)}function je(){return je=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},je.apply(this,arguments)}function _e(e,t){return _e=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},_e(e,t)}function Re(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ae(e){return Ae=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Ae(e)}function De(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Me=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&_e(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Ae(n);if(i){var r=Ae(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===ke(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Re(e)}(this,e)});function a(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return De(Re(e=l.call.apply(l,[this].concat(r))),"handleCheckboxChange",(function(t){var r=e.props,n=r.mode,i=r.id;(0,r.onCheckboxChange)(i,"simpleSelect"===n||"radioSelect"===n||t.target.checked),t.stopPropagation(),t.nativeEvent.stopImmediatePropagation()})),e}return t=a,r=[{key:"render",value:function(){var e=this.props,t=e.mode,r=e.title,n=e.label,i=e.id,l=e.partial,a=e.checked,s=this.props,c=s.value,d=s.disabled,u=s.showPartiallySelected,p=s.readOnly,b=s.clientId,f={className:"node-label"};"simpleSelect"===t&&!p&&!d&&(f.onClick=this.handleCheckboxChange);var h={id:i,value:c,checked:a,disabled:d,readOnly:p,tabIndex:-1},y=["checkbox-item","simpleSelect"===t&&"simple-select"].filter(Boolean).join(" ");return o().createElement("label",{title:r||n,htmlFor:i},"radioSelect"===t?o().createElement(Te,je({name:b,className:"radio-item",onChange:this.handleCheckboxChange},h)):o().createElement(ve,je({name:i,className:y,indeterminate:u&&l,onChange:this.handleCheckboxChange},h)),o().createElement("span",f,n))}}],r&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);De(Me,"propTypes",{id:t().string.isRequired,actions:t().array,title:t().string,label:t().string.isRequired,value:t().string.isRequired,checked:t().bool,partial:t().bool,disabled:t().bool,dataset:t().object,mode:t().oneOf(["multiSelect","simpleSelect","radioSelect","hierarchical"]),showPartiallySelected:t().bool,onCheckboxChange:t().func,readOnly:t().bool,clientId:t().string});const Ne=Me;function Be(e){return Be="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Be(e)}function Fe(e,t){return Fe=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Fe(e,t)}function Ie(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Le(e){return Le=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Le(e)}function He(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Ve=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Fe(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Le(n);if(i){var r=Le(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Be(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Ie(e)}(this,e)});function a(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return He(Ie(e=l.call.apply(l,[this].concat(r))),"onToggle",(function(t){t.stopPropagation(),t.nativeEvent.stopImmediatePropagation(),e.props.onNodeToggle(e.props.id)})),He(Ie(e),"onKeyDown",(function(t){"Enter"!==t.key&&32!==t.keyCode||(e.props.onNodeToggle(e.props.id),t.preventDefault())})),e}return t=a,r=[{key:"render",value:function(){var e=this.props,t=e.expanded,r=e.isLeaf,n=["toggle",t&&"expanded",!t&&"collapsed"].filter(Boolean).join(" ");return r?o().createElement("i",{role:"button",tabIndex:-1,className:n,style:{visibility:"hidden"},"aria-hidden":!0}):o().createElement("i",{role:"button",tabIndex:-1,className:n,onClick:this.onToggle,onKeyDown:this.onKeyDown,"aria-hidden":!0})}}],r&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);He(Ve,"propTypes",{expanded:t().bool,isLeaf:t().bool,onNodeToggle:t().func,id:t().string});const Ue=Ve;function Ge(e){return Ge="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ge(e)}function qe(){return qe=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},qe.apply(this,arguments)}function We(e,t){return We=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},We(e,t)}function ze(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function $e(e){return $e=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},$e(e)}function Ke(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Ye=function(e){return a(e)},Je=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&We(e,t)}(s,e);var t,r,n,i,a=(n=s,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=$e(n);if(i){var r=$e(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Ge(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return ze(e)}(this,e)});function s(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Ke(ze(e=a.call.apply(a,[this].concat(r))),"getAriaAttributes",(function(){var t=e.props,r=t._children,n=t._depth,i=t.checked,o=t.disabled,l=t.expanded,a=t.readOnly,s=t.mode,c=t.partial,d={};return d.role="simpleSelect"===s?"option":"treeitem",d["aria-disabled"]=o||a,d["aria-selected"]=i,"simpleSelect"!==s&&(d["aria-checked"]=c?"mixed":i,d["aria-level"]=(n||0)+1,d["aria-expanded"]=r&&(l?"true":"false")),d})),e}return t=s,r=[{key:"render",value:function(){var e=this.props,t=e.mode,r=e.keepTreeOnSearch,n=e._id,i=e._children,a=e.dataset,s=e._depth,c=e.expanded,d=e.title,u=e.label,p=e.partial,b=e.checked,f=e.value,h=e.disabled,y=e.actions,m=e.onAction,g=e.searchModeOn,v=e.onNodeToggle,O=e.onCheckboxChange,w=e.showPartiallySelected,S=e.readOnly,E=e.clientId,P=function(e){var t=e.keepTreeOnSearch,r=e.keepChildrenOnSearch,n=e._children,i=e.matchInChildren,o=e.matchInParent,l=e.disabled,a=e.partial,s=e.hide,c=e.className,d=e.showPartiallySelected,u=e.readOnly,p=e.checked,b=e._focused;return["node",Ye(n)&&"leaf",!Ye(n)&&"tree",l&&"disabled",s&&"hide",t&&i&&"match-in-children",t&&r&&o&&"match-in-parent",d&&a&&"partial",u&&"readOnly",p&&"checked",b&&"focused",c].filter(Boolean).join(" ")}(this.props),C=r||!g?{paddingLeft:"".concat(20*(s||0),"px")}:{},x="".concat(n,"_li");return o().createElement("li",qe({className:P,style:C,id:x},l(a),this.getAriaAttributes()),o().createElement(Ue,{isLeaf:Ye(i),expanded:c,id:n,onNodeToggle:v}),o().createElement(Ne,{title:d,label:u,id:n,partial:p,checked:b,value:f,disabled:h,mode:t,onCheckboxChange:O,showPartiallySelected:w,readOnly:S,clientId:E}),o().createElement(ue,{actions:y,onAction:m,id:n,readOnly:S}))}}],r&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),s}(r.PureComponent);Ke(Je,"propTypes",{_id:t().string.isRequired,_depth:t().number,_children:t().array,actions:t().array,className:t().string,title:t().string,label:t().string.isRequired,value:t().string.isRequired,checked:t().bool,expanded:t().bool,disabled:t().bool,partial:t().bool,dataset:t().object,keepTreeOnSearch:t().bool,keepChildrenOnSearch:t().bool,searchModeOn:t().bool,onNodeToggle:t().func,onAction:t().func,onCheckboxChange:t().func,mode:t().oneOf(["multiSelect","simpleSelect","radioSelect","hierarchical"]),showPartiallySelected:t().bool,readOnly:t().bool,clientId:t().string});const Qe=Je;function Xe(e){return Xe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Xe(e)}function Ze(){return Ze=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Ze.apply(this,arguments)}function et(e,t){return et=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},et(e,t)}function tt(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function rt(e){return rt=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},rt(e)}function nt(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var it=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&et(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=rt(n);if(i){var r=rt(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Xe(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return tt(e)}(this,e)});function a(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),nt(tt(t=l.call(this,e)),"UNSAFE_componentWillReceiveProps",(function(e){var r=e.activeDescendant===t.props.activeDescendant;t.computeInstanceProps(e,!r),t.setState({items:t.allVisibleNodes.slice(0,t.currentPage*t.props.pageSize)})})),nt(tt(t),"componentDidMount",(function(){t.setState({scrollableTarget:t.node.parentNode})})),nt(tt(t),"computeInstanceProps",(function(e,r){if(t.allVisibleNodes=t.getNodes(e),t.totalPages=Math.ceil(t.allVisibleNodes.length/t.props.pageSize),r&&e.activeDescendant){var n=e.activeDescendant.replace(/_li$/,""),i=u(t.allVisibleNodes,(function(e){return e.key===n}))+1;t.currentPage=i>0?Math.ceil(i/t.props.pageSize):1}})),nt(tt(t),"shouldRenderNode",(function(e,t){var r=t.data,n=t.searchModeOn,i=e.expanded,o=e._parent;if(n||i)return!0;var l=o&&r.get(o);return!l||l.expanded})),nt(tt(t),"getNodes",(function(e){var r=e.data,n=e.keepTreeOnSearch,i=e.keepChildrenOnSearch,l=e.searchModeOn,a=e.mode,s=e.showPartiallySelected,c=e.readOnly,d=e.onAction,u=e.onChange,p=e.onCheckboxChange,b=e.onNodeToggle,f=e.activeDescendant,h=e.clientId,y=[];return r.forEach((function(r){t.shouldRenderNode(r,e)&&y.push(o().createElement(Qe,Ze({keepTreeOnSearch:n,keepChildrenOnSearch:i,key:r._id},r,{searchModeOn:l,onChange:u,onCheckboxChange:p,onNodeToggle:b,onAction:d,mode:a,showPartiallySelected:s,readOnly:c,clientId:h,activeDescendant:f})))})),y})),nt(tt(t),"hasMore",(function(){return t.currentPage<t.totalPages})),nt(tt(t),"loadMore",(function(){t.currentPage=t.currentPage+1;var e=t.allVisibleNodes.slice(0,t.currentPage*t.props.pageSize);t.setState({items:e})})),nt(tt(t),"setNodeRef",(function(e){t.node=e})),nt(tt(t),"getAriaAttributes",(function(){var e=t.props.mode;return{role:"simpleSelect"===e?"listbox":"tree","aria-multiselectable":/multiSelect|hierarchical/.test(e)}})),t.currentPage=1,t.computeInstanceProps(e,!0),t.state={items:t.allVisibleNodes.slice(0,t.props.pageSize)},t}return t=a,(r=[{key:"render",value:function(){var e=this.props.searchModeOn;return o().createElement("ul",Ze({className:"root ".concat(e?"searchModeOn":""),ref:this.setNodeRef},this.getAriaAttributes()),this.state.scrollableTarget&&o().createElement(K(),{dataLength:this.state.items.length,next:this.loadMore,hasMore:this.hasMore(),loader:o().createElement("span",{className:"searchLoader"},"Loading..."),scrollableTarget:this.state.scrollableTarget},this.state.items))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.Component);nt(it,"propTypes",{data:t().object,keepTreeOnSearch:t().bool,keepChildrenOnSearch:t().bool,searchModeOn:t().bool,onChange:t().func,onNodeToggle:t().func,onAction:t().func,onCheckboxChange:t().func,mode:t().oneOf(["multiSelect","simpleSelect","radioSelect","hierarchical"]),showPartiallySelected:t().bool,pageSize:t().number,readOnly:t().bool,clientId:t().string,activeDescendant:t().string}),nt(it,"defaultProps",{pageSize:100});const ot=it;var lt=n(865),at=n.n(lt),st=function(e){return e};const ct=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"children",r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:st;return at()(e[t],(function(e){return r(e).checked}))||e[t].some((function(e){return r(e).partial}))};function dt(e){var t=e.nodes,r=e.parent,n=e.depth,i=void 0===n?0:n,o=e.simple,l=e.radio,s=e.showPartialState,c=e.hierarchical,d=e.rootPrefixId,u=e._rv,p=void 0===u?{list:new Map,defaultValues:[],singleSelectedNode:null}:u,b=o||l;return t.forEach((function(e,t){e._depth=i,r?(e._id=e.id||"".concat(r._id,"-").concat(t),e._parent=r._id,r._children.push(e._id)):e._id=e.id||"".concat(d?"".concat(d,"-").concat(t):t),b&&e.checked&&(p.singleSelectedNode?e.checked=!1:p.singleSelectedNode=e),b&&e.isDefaultValue&&p.singleSelectedNode&&!p.singleSelectedNode.isDefaultValue&&(p.singleSelectedNode.checked=!1,p.singleSelectedNode=null),!e.isDefaultValue||b&&0!==p.defaultValues.length||(p.defaultValues.push(e._id),e.checked=!0,b&&(p.singleSelectedNode=e)),c&&!l||function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]&&!arguments[2]?["disabled"]:["checked","disabled"],n=0;n<r.length;n++){var i=r[n];void 0===e[i]&&void 0!==t[i]&&(e[i]=t[i])}}(e,r,!l),p.list.set(e._id,e),!o&&e.children&&(e._children=[],dt({nodes:e.children,parent:e,depth:i+1,radio:l,showPartialState:s,hierarchical:c,_rv:p}),s&&!e.checked&&(e.partial=ct(e),b||a(e.children)||!e.children.every((function(e){return e.checked}))||(e.checked=!0)),e.children=void 0)})),p}const ut=function(e){var t=e.tree,r=e.simple,n=e.radio,i=e.showPartialState,o=e.hierarchical,l=e.rootPrefixId;return dt({nodes:Array.isArray(t)?t:[t],simple:r,radio:n,showPartialState:i,hierarchical:o,rootPrefixId:l})};var pt=function e(t,r,n){r[t._id]=!0,a(t._children)||t._children.forEach((function(t){return e(n(t),r,n)}))},bt=function(e,t){var r=[],n={};return e.forEach((function(e,i){n[i]||(t(e,i,n)&&r.push(e),n[i]=!0)})),r},ft={getNodesMatching:bt,getVisibleNodes:function(e,t,r){return bt(e,(function(e,n,i){return r&&e._children&&e._children.length&&!0!==e.expanded&&pt(e,i,t),!e.hide}))},markSubTreeVisited:pt};const ht=ft;function yt(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var mt="ArrowUp",gt="ArrowDown",vt="ArrowLeft",Ot="ArrowRight",wt="Enter",St="Home",Et="PageUp",Pt="PageDown",Ct={None:"None",FocusPrevious:"FocusPrevious",FocusNext:"FocusNext",FocusParent:"FocusParent",FocusFirst:"FocusFirst",FocusLast:"FocusLast",ToggleExpanded:"ToggleExpanded",ToggleChecked:"ToggleChecked"},xt=new Set([Ct.FocusPrevious,Ct.FocusNext,Ct.FocusParent,Ct.FocusFirst,Ct.FocusLast]),Tt=[mt,gt,St,Et,"End",Pt],kt=Tt.concat([vt,Ot,wt]),jt=function(e,t,r,n){return t.indexOf(e)>-1||!r&&e===n},_t={isValidKey:function(e,t){return(t?kt:Tt).indexOf(e)>-1},getAction:function(e,t){var r;return r=t===vt?function(e,t){return e&&t===vt?!0===e.expanded?Ct.ToggleExpanded:e._parent?Ct.FocusParent:Ct.None:Ct.None}(e,t):t===Ot?function(e,t){return e&&e._children&&t===Ot?!0!==e.expanded?Ct.ToggleExpanded:Ct.FocusNext:Ct.None}(e,t):function(e,t){return jt(e,[St,Et],t,gt)}(t,e)?Ct.FocusFirst:function(e,t){return jt(e,["End",Pt],t,mt)}(t,e)?Ct.FocusLast:function(e,t){if(!e)return Ct.None;switch(t){case mt:return Ct.FocusPrevious;case gt:return Ct.FocusNext;case wt:return Ct.ToggleChecked;default:return Ct.None}}(e,t),r},getNextFocus:function(e,t,r,n,i){if(r===Ct.FocusParent)return function(e,t){return e&&e._parent?t(e._parent):e}(t,n);if(!xt.has(r))return t;var o=ht.getVisibleNodes(e,n,i);return function(e){return jt(e,[Ct.FocusPrevious,Ct.FocusLast],!0)}(r)&&(o=o.reverse()),function(e,t,r){if(!e||0===e.length)return t;var n,i=t;return function(e){return jt(e,[Ct.FocusFirst,Ct.FocusLast],!0)}(r)?i=(n=e,function(e){if(Array.isArray(e))return e}(n)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,o=[],l=!0,a=!1;try{for(r=r.call(e);!(l=(n=r.next()).done)&&(o.push(n.value),1!==o.length);l=!0);}catch(e){a=!0,i=e}finally{try{l||null==r.return||r.return()}finally{if(a)throw i}}return o}}(n)||function(e,t){if(e){if("string"==typeof e)return yt(e,1);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?yt(e,1):void 0}}(n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0]:[Ct.FocusPrevious,Ct.FocusNext].indexOf(r)>-1&&(i=function(e,t){var r=e.indexOf(t)+1;return r%e.length==0?e[0]:e[r]}(e,t)),i}(o,t,r)},getNextFocusAfterTagDelete:function(e,t,r,n){var i=t?u(t,(function(t){return t._id===e})):-1;if(i<0||!r.length)return n;var o=r[i=r.length>i?i:r.length-1]._id,l=document.getElementById(x(o));return l&&l.firstElementChild||n},handleFocusNavigationkey:function(e,t,r,n,i){var o=_t.getNextFocus(e,r,t,n,i);return _t.adjustFocusedProps(r,o),o?o._id:r&&r._id},handleToggleNavigationkey:function(e,t,r,n,i){return e!==Ct.ToggleChecked||r||t.readOnly||t.disabled?e===Ct.ToggleExpanded&&i(t._id):n(t._id,!0!==t.checked),t&&t._id},adjustFocusedProps:function(e,t){e&&t&&e._id!==t._id&&(e._focused=!1),t&&(t._focused=!0)}};const Rt=_t;var At=function(){function e(t){var r=t.data,n=t.mode,i=t.showPartiallySelected,o=t.rootPrefixId,l=t.searchPredicate;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._src=r,this.simpleSelect="simpleSelect"===n,this.radioSelect="radioSelect"===n,this.hierarchical="hierarchical"===n,this.searchPredicate=l;var a=ut({tree:JSON.parse(JSON.stringify(r)),simple:this.simpleSelect,radio:this.radioSelect,showPartialState:i,hierarchical:this.hierarchical,rootPrefixId:o}),s=a.list,c=a.defaultValues,d=a.singleSelectedNode;this.tree=s,this.defaultValues=c,this.showPartialState=!this.hierarchical&&i,this.searchMaps=new Map,(this.simpleSelect||this.radioSelect)&&d&&(this.currentChecked=d._id)}var t,r;return t=e,r=[{key:"getNodeById",value:function(e){return this.tree.get(e)}},{key:"getMatches",value:function(e){var t=this;if(this.searchMaps.has(e))return this.searchMaps.get(e);var r=-1,n=e;this.searchMaps.forEach((function(t,i){e.startsWith(i)&&i.length>r&&(r=i.length,n=i)}));var i=[],o=this._getAddOnMatch(i,e);return n!==e?this.searchMaps.get(n).forEach((function(e){return o(t.getNodeById(e))})):this.tree.forEach(o),this.searchMaps.set(e,i),i}},{key:"addParentsToTree",value:function(e,t){if(void 0!==e){var r=this.getNodeById(e);this.addParentsToTree(r._parent,t),r.hide=!r._isMatch||r.hide,r.matchInChildren=!0,t.set(e,r)}}},{key:"addChildrenToTree",value:function(e,t,r){var n=this;void 0!==e&&e.forEach((function(e){if(!r||!r.includes(e)){var i=n.getNodeById(e);i.matchInParent=!0,t.set(e,i),n.addChildrenToTree(i._children,t)}}))}},{key:"filterTree",value:function(e,t,r){var n=this,i=this.getMatches(e.toLowerCase()),o=new Map;i.forEach((function(e){var l=n.getNodeById(e);l.hide=!1,l._isMatch=!0,t&&n.addParentsToTree(l._parent,o),o.set(e,l),t&&r&&n.addChildrenToTree(l._children,o,i)}));var l=0===i.length;return this.matchTree=o,{allNodesHidden:l,tree:o}}},{key:"restoreNodes",value:function(){return this.tree.forEach((function(e){e.hide=!1})),this.tree}},{key:"restoreDefaultValues",value:function(){var e=this;return this.defaultValues.forEach((function(t){e.setNodeCheckedState(t,!0)})),this.tree}},{key:"togglePreviousChecked",value:function(e,t){var r=this.currentChecked;if(r&&r!==e){var n=this.getNodeById(r);n.checked=!1,this.radioSelect&&this.showPartialState&&this.partialCheckParents(n)}this.currentChecked=t?e:null}},{key:"setNodeCheckedState",value:function(e,t){this.radioSelect&&this.togglePreviousChecked(e,t);var r=this.getNodeById(e);r.checked=t,this.showPartialState&&(r.partial=!1),this.simpleSelect?this.togglePreviousChecked(e,t):this.radioSelect?(this.showPartialState&&this.partialCheckParents(r),t||this.unCheckParents(r)):(this.hierarchical||this.toggleChildren(e,t),this.showPartialState&&this.partialCheckParents(r),this.hierarchical||t||this.unCheckParents(r))}},{key:"unCheckParents",value:function(e){for(var t=e._parent;t;){var r=this.getNodeById(t);r.checked=!1,r.partial=ct(r,"_children",this.getNodeById.bind(this)),t=r._parent}}},{key:"partialCheckParents",value:function(e){for(var t=this,r=e._parent;r;){var n=this.getNodeById(r);n.checked=n._children.every((function(e){return t.getNodeById(e).checked})),n.partial=ct(n,"_children",this.getNodeById.bind(this)),r=n._parent}}},{key:"toggleChildren",value:function(e,t){var r=this,n=this.getNodeById(e);n.checked=t,this.showPartialState&&(n.partial=!1),a(n._children)||n._children.forEach((function(e){return r.toggleChildren(e,t)}))}},{key:"toggleNodeExpandState",value:function(e){var t=this.getNodeById(e);return t.expanded=!t.expanded,t.expanded||this.collapseChildren(t),this.tree}},{key:"collapseChildren",value:function(e){var t=this;e.expanded=!1,a(e._children)||e._children.forEach((function(e){return t.collapseChildren(t.getNodeById(e))}))}},{key:"tags",get:function(){var e=this;return this.radioSelect||this.simpleSelect?this.currentChecked?[this.getNodeById(this.currentChecked)]:[]:ht.getNodesMatching(this.tree,(function(t,r,n){return t.checked&&!e.hierarchical&&ht.markSubTreeVisited(t,n,(function(t){return e.getNodeById(t)})),t.checked}))}},{key:"getTreeAndTags",value:function(){return{tree:this.tree,tags:this.tags}}},{key:"handleNavigationKey",value:function(e,t,r,n,i,o,l){var a=this,s=e&&this.getNodeById(e),c=Rt.getAction(s,r);return xt.has(c)?Rt.handleFocusNavigationkey(t,c,s,(function(e){return a.getNodeById(e)}),i):s&&t.has(s._id)?Rt.handleToggleNavigationkey(c,s,n,o,l):e}},{key:"_getAddOnMatch",value:function(e,t){var r=function(e,t){return e.label.toLowerCase().indexOf(t)>=0};return"function"==typeof this.searchPredicate&&(r=this.searchPredicate),function(n){r(n,t)&&e.push(n._id)}}}],r&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),e}();const Dt=At;function Mt(e){return Mt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Mt(e)}function Nt(){return Nt=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Nt.apply(this,arguments)}function Bt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Ft(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Bt(Object(r),!0).forEach((function(t){Vt(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Bt(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function It(e,t){return It=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},It(e,t)}function Lt(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ht(e){return Ht=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Ht(e)}function Vt(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Ut=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&It(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Ht(n);if(i){var r=Ht(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Mt(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Lt(e)}(this,e)});function a(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),Vt(Lt(t=l.call(this,e)),"initNewProps",(function(e){var r=e.data,n=e.mode,i=e.showDropdown,o=e.showPartiallySelected,l=e.searchPredicate;t.treeManager=new Dt({data:r,mode:n,showPartiallySelected:o,rootPrefixId:t.clientId,searchPredicate:l}),t.setState((function(e){var r=e.currentFocus&&t.treeManager.getNodeById(e.currentFocus);return r&&(r._focused=!0),Ft({showDropdown:/initial|always/.test(i)||!0===e.showDropdown},t.treeManager.getTreeAndTags())}))})),Vt(Lt(t),"resetSearchState",(function(){return t.searchInput&&(t.searchInput.value=""),{tree:t.treeManager.restoreNodes(),searchModeOn:!1,allNodesHidden:!1}})),Vt(Lt(t),"handleClick",(function(e,r){t.setState((function(e){var r="always"===t.props.showDropdown||t.keepDropdownActive||!e.showDropdown;return r!==e.showDropdown&&(r?document.addEventListener("click",t.handleOutsideClick,!1):document.removeEventListener("click",t.handleOutsideClick,!1)),r?t.props.onFocus():t.props.onBlur(),r?{showDropdown:r}:Ft({showDropdown:r},t.resetSearchState())}),r)})),Vt(Lt(t),"handleOutsideClick",(function(e){"always"!==t.props.showDropdown&&function(e,t){return e instanceof Event&&!function(e){if(e.path)return e.path;for(var t=e.target,r=[t];t.parentElement;)t=t.parentElement,r.unshift(t);return r}(e).some((function(e){return e===t}))}(e,t.node)&&t.handleClick()})),Vt(Lt(t),"onInputChange",(function(e){var r=e.length>0;if(r){var n=t.treeManager.filterTree(e,t.props.keepTreeOnSearch,t.props.keepChildrenOnSearch),i=n.allNodesHidden,o=n.tree;t.setState({tree:o,searchModeOn:r,allNodesHidden:i})}else t.setState(t.resetSearchState())})),Vt(Lt(t),"onTagRemove",(function(e,r){var n=t.state.tags;t.onCheckboxChange(e,!1,(function(i){r&&Rt.getNextFocusAfterTagDelete(e,n,i,t.searchInput).focus()}))})),Vt(Lt(t),"onNodeToggle",(function(e){t.treeManager.toggleNodeExpandState(e);var r=t.state.searchModeOn?t.treeManager.matchTree:t.treeManager.tree;t.setState({tree:r}),"function"==typeof t.props.onNodeToggle&&t.props.onNodeToggle(t.treeManager.getNodeById(e))})),Vt(Lt(t),"onCheckboxChange",(function(e,r,n){var i=t.props,o=i.mode,l=i.keepOpenOnSelect,a=i.clearSearchOnChange,s=t.state,c=s.currentFocus,d=s.searchModeOn;t.treeManager.setNodeCheckedState(e,r);var u=t.treeManager.tags,p=["simpleSelect","radioSelect"].indexOf(o)>-1,b=!(p&&!l)&&t.state.showDropdown,f=c&&t.treeManager.getNodeById(c),h=t.treeManager.getNodeById(e);u.length||(t.treeManager.restoreDefaultValues(),u=t.treeManager.tags);var y={tree:d?t.treeManager.matchTree:t.treeManager.tree,tags:u,showDropdown:b,currentFocus:e};(p&&!b||a)&&Object.assign(y,t.resetSearchState()),p&&!b&&document.removeEventListener("click",t.handleOutsideClick,!1),Rt.adjustFocusedProps(f,h),t.setState(y,(function(){n&&n(u)})),t.props.onChange(h,u)})),Vt(Lt(t),"onAction",(function(e,r){t.props.onAction(t.treeManager.getNodeById(e),r)})),Vt(Lt(t),"onInputFocus",(function(){t.keepDropdownActive=!0})),Vt(Lt(t),"onInputBlur",(function(){t.keepDropdownActive=!1})),Vt(Lt(t),"onTrigger",(function(e){t.handleClick(e,(function(){t.state.showDropdown&&t.searchInput.focus()}))})),Vt(Lt(t),"onKeyboardKeyDown",(function(e){var r=t.props,n=r.readOnly,i=r.mode,o=r.disablePoppingOnBackspace,l=t.state,a=l.showDropdown,s=l.tags,c=l.searchModeOn,d=l.currentFocus,u=t.treeManager,p=c?u.matchTree:u.tree;if(a||!Rt.isValidKey(e.key,!1)&&!/^\w$/i.test(e.key))if(a&&Rt.isValidKey(e.key,!0)){var b=u.handleNavigationKey(d,p,e.key,n,!c,t.onCheckboxChange,t.onNodeToggle);b!==d&&t.setState({currentFocus:b},(function(){var e=document&&document.getElementById("".concat(b,"_li"));e&&e.scrollIntoView()}))}else{if(a&&["Escape","Tab"].indexOf(e.key)>-1)return void("simpleSelect"===i&&p.has(d)?t.onCheckboxChange(d,!0):(t.keepDropdownActive=!1,t.handleClick()));if(o||"Backspace"!==e.key||!s.length||0!==t.searchInput.value.length)return;var f=s.pop();t.onCheckboxChange(f._id,!1)}else if(e.persist(),t.handleClick(null,(function(){return t.onKeyboardKeyDown(e)})),/\w/i.test(e.key))return;e.preventDefault()})),Vt(Lt(t),"getAriaAttributes",(function(){var e=t.props,r=e.mode,n=e.texts;return"radioSelect"!==r?{}:Ft({role:"radiogroup"},p(n.label))})),t.state={searchModeOn:!1,currentFocus:void 0},t.clientId=e.id||d.get(Lt(t)),t}return t=a,(r=[{key:"UNSAFE_componentWillMount",value:function(){this.initNewProps(this.props)}},{key:"componentWillUnmount",value:function(){document.removeEventListener("click",this.handleOutsideClick,!1)}},{key:"UNSAFE_componentWillReceiveProps",value:function(e){this.initNewProps(e)}},{key:"render",value:function(){var e=this,t=this.props,r=t.disabled,n=t.readOnly,i=t.mode,l=t.texts,a=t.inlineSearchInput,s=t.tabIndex,c=this.state,d=c.showDropdown,u=c.currentFocus,p=c.tags,b={disabled:r,readOnly:n,activeDescendant:u?"".concat(u,"_li"):void 0,texts:l,mode:i,clientId:this.clientId},f=o().createElement(O,Nt({inputRef:function(t){e.searchInput=t},onInputChange:this.onInputChange,onFocus:this.onInputFocus,onBlur:this.onInputBlur,onKeyDown:this.onKeyboardKeyDown},b,{inlineSearchInput:a}));return o().createElement("div",{id:this.clientId,className:[this.props.className&&this.props.className,"react-dropdown-tree-select"].filter(Boolean).join(" "),ref:function(t){e.node=t}},o().createElement("div",{className:["dropdown","simpleSelect"===i&&"simple-select","radioSelect"===i&&"radio-select"].filter(Boolean).join(" ")},o().createElement(z,Nt({onTrigger:this.onTrigger,showDropdown:d},b,{tags:p,tabIndex:s}),o().createElement(F,Nt({tags:p,onTagRemove:this.onTagRemove},b),!a&&f)),d&&o().createElement("div",Nt({className:"dropdown-content"},this.getAriaAttributes()),a&&f,this.state.allNodesHidden?o().createElement("span",{className:"no-matches"},l.noMatches||"No matches found"):o().createElement(ot,Nt({data:this.state.tree,keepTreeOnSearch:this.props.keepTreeOnSearch,keepChildrenOnSearch:this.props.keepChildrenOnSearch,searchModeOn:this.state.searchModeOn,onAction:this.onAction,onCheckboxChange:this.onCheckboxChange,onNodeToggle:this.onNodeToggle,mode:i,showPartiallySelected:this.props.showPartiallySelected},b)))))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.Component);Vt(Ut,"propTypes",{data:t().oneOfType([t().object,t().array]).isRequired,clearSearchOnChange:t().bool,keepTreeOnSearch:t().bool,keepChildrenOnSearch:t().bool,keepOpenOnSelect:t().bool,texts:t().shape({placeholder:t().string,inlineSearchPlaceholder:t().string,noMatches:t().string,label:t().string,labelRemove:t().string}),showDropdown:t().oneOf(["default","initial","always"]),className:t().string,onChange:t().func,onAction:t().func,onNodeToggle:t().func,onFocus:t().func,onBlur:t().func,mode:t().oneOf(["multiSelect","simpleSelect","radioSelect","hierarchical"]),showPartiallySelected:t().bool,disabled:t().bool,readOnly:t().bool,id:t().string,searchPredicate:t().func,inlineSearchInput:t().bool,tabIndex:t().number,disablePoppingOnBackspace:t().bool}),Vt(Ut,"defaultProps",{onAction:function(){},onFocus:function(){},onBlur:function(){},onChange:function(){},texts:{},showDropdown:"default",inlineSearchInput:!1,tabIndex:0,disablePoppingOnBackspace:!1});const Gt=Ut})(),i})(),e.exports=n(r(9196))},9196:function(e){"use strict";e.exports=window.React}},r={};function n(e){var i=r[e];if(void 0!==i)return i.exports;var o=r[e]={id:e,loaded:!1,exports:{}};return t[e].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}n.m=t,e=[],n.O=function(t,r,i,o){if(!r){var l=1/0;for(d=0;d<e.length;d++){r=e[d][0],i=e[d][1],o=e[d][2];for(var a=!0,s=0;s<r.length;s++)(!1&o||l>=o)&&Object.keys(n.O).every((function(e){return n.O[e](r[s])}))?r.splice(s--,1):(a=!1,o<l&&(l=o));if(a){e.splice(d--,1);var c=i();void 0!==c&&(t=c)}}return t}o=o||0;for(var d=e.length;d>0&&e[d-1][2]>o;d--)e[d]=e[d-1];e[d]=[r,i,o]},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,{a:t}),t},n.d=function(e,t){for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e},function(){var e;n.g.importScripts&&(e=n.g.location+"");var t=n.g.document;if(!e&&t&&(t.currentScript&&(e=t.currentScript.src),!e)){var r=t.getElementsByTagName("script");if(r.length)for(var i=r.length-1;i>-1&&!e;)e=r[i--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),n.p=e}(),function(){var e={826:0,431:0};n.O.j=function(t){return 0===e[t]};var t=function(t,r){var i,o,l=r[0],a=r[1],s=r[2],c=0;if(l.some((function(t){return 0!==e[t]}))){for(i in a)n.o(a,i)&&(n.m[i]=a[i]);if(s)var d=s(n)}for(t&&t(r);c<l.length;c++)o=l[c],n.o(e,o)&&e[o]&&e[o][0](),e[o]=0;return n.O(d)},r=self.webpackChunkhumix_block=self.webpackChunkhumix_block||[];r.forEach(t.bind(null,0)),r.push=t.bind(null,r.push.bind(r))}();var i=n.O(void 0,[431],(function(){return n(5758)}));i=n.O(i)}();1 !function(){var e,t={5758:function(e,t,r){"use strict";var n=window.wp.blocks,i=window.wp.element;function o(){return o=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},o.apply(this,arguments)}window.wp.i18n;var l=r(9196),a=r(1038),s=r.n(a),c=r(8446),d=r.n(c);class u extends l.Component{constructor(e){super(e),this.state={data:e.data}}componentWillReceiveProps=e=>{d()(e.data,this.state.data)||this.setState({data:e.data})};shouldComponentUpdate=e=>!d()(e.data,this.state.data);render(){const{data:e,...t}=this.props;return(0,i.createElement)(s(),o({data:this.state.data},t))}}var p=window.wp.blockEditor,b=window.wp.components,f=window.wp.data,h=window.wp.apiFetch,y=r.n(h);function m(e,t){return function(){return e.apply(t,arguments)}}const{toString:g}=Object.prototype,{getPrototypeOf:v}=Object,O=(w=Object.create(null),e=>{const t=g.call(e);return w[t]||(w[t]=t.slice(8,-1).toLowerCase())});var w;const S=e=>(e=e.toLowerCase(),t=>O(t)===e),E=e=>t=>typeof t===e,{isArray:P}=Array,C=E("undefined"),x=S("ArrayBuffer"),T=E("string"),k=E("function"),j=E("number"),_=e=>null!==e&&"object"==typeof e,R=e=>{if("object"!==O(e))return!1;const t=v(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)},A=S("Date"),D=S("File"),M=S("Blob"),N=S("FileList"),B=S("URLSearchParams");function F(e,t,{allOwnKeys:r=!1}={}){if(null==e)return;let n,i;if("object"!=typeof e&&(e=[e]),P(e))for(n=0,i=e.length;n<i;n++)t.call(null,e[n],n,e);else{const i=r?Object.getOwnPropertyNames(e):Object.keys(e),o=i.length;let l;for(n=0;n<o;n++)l=i[n],t.call(null,e[l],l,e)}}function I(e,t){t=t.toLowerCase();const r=Object.keys(e);let n,i=r.length;for(;i-- >0;)if(n=r[i],t===n.toLowerCase())return n;return null}const L="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,H=e=>!C(e)&&e!==L,V=(U="undefined"!=typeof Uint8Array&&v(Uint8Array),e=>U&&e instanceof U);var U;const G=S("HTMLFormElement"),q=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),W=S("RegExp"),z=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),n={};F(r,((r,i)=>{!1!==t(r,i,e)&&(n[i]=r)})),Object.defineProperties(e,n)},$="abcdefghijklmnopqrstuvwxyz",K="0123456789",Y={DIGIT:K,ALPHA:$,ALPHA_DIGIT:$+$.toUpperCase()+K},J=S("AsyncFunction");var Q={isArray:P,isArrayBuffer:x,isBuffer:function(e){return null!==e&&!C(e)&&null!==e.constructor&&!C(e.constructor)&&k(e.constructor.isBuffer)&&e.constructor.isBuffer(e)},isFormData:e=>{let t;return e&&("function"==typeof FormData&&e instanceof FormData||k(e.append)&&("formdata"===(t=O(e))||"object"===t&&k(e.toString)&&"[object FormData]"===e.toString()))},isArrayBufferView:function(e){let t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&x(e.buffer),t},isString:T,isNumber:j,isBoolean:e=>!0===e||!1===e,isObject:_,isPlainObject:R,isUndefined:C,isDate:A,isFile:D,isBlob:M,isRegExp:W,isFunction:k,isStream:e=>_(e)&&k(e.pipe),isURLSearchParams:B,isTypedArray:V,isFileList:N,forEach:F,merge:function e(){const{caseless:t}=H(this)&&this||{},r={},n=(n,i)=>{const o=t&&I(r,i)||i;R(r[o])&&R(n)?r[o]=e(r[o],n):R(n)?r[o]=e({},n):P(n)?r[o]=n.slice():r[o]=n};for(let e=0,t=arguments.length;e<t;e++)arguments[e]&&F(arguments[e],n);return r},extend:(e,t,r,{allOwnKeys:n}={})=>(F(t,((t,n)=>{r&&k(t)?e[n]=m(t,r):e[n]=t}),{allOwnKeys:n}),e),trim:e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:e=>(65279===e.charCodeAt(0)&&(e=e.slice(1)),e),inherits:(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},toFlatObject:(e,t,r,n)=>{let i,o,l;const a={};if(t=t||{},null==e)return t;do{for(i=Object.getOwnPropertyNames(e),o=i.length;o-- >0;)l=i[o],n&&!n(l,e,t)||a[l]||(t[l]=e[l],a[l]=!0);e=!1!==r&&v(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},kindOf:O,kindOfTest:S,endsWith:(e,t,r)=>{e=String(e),(void 0===r||r>e.length)&&(r=e.length),r-=t.length;const n=e.indexOf(t,r);return-1!==n&&n===r},toArray:e=>{if(!e)return null;if(P(e))return e;let t=e.length;if(!j(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},forEachEntry:(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let n;for(;(n=r.next())&&!n.done;){const r=n.value;t.call(e,r[0],r[1])}},matchAll:(e,t)=>{let r;const n=[];for(;null!==(r=e.exec(t));)n.push(r);return n},isHTMLForm:G,hasOwnProperty:q,hasOwnProp:q,reduceDescriptors:z,freezeMethods:e=>{z(e,((t,r)=>{if(k(e)&&-1!==["arguments","caller","callee"].indexOf(r))return!1;const n=e[r];k(n)&&(t.enumerable=!1,"writable"in t?t.writable=!1:t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")}))}))},toObjectSet:(e,t)=>{const r={},n=e=>{e.forEach((e=>{r[e]=!0}))};return P(e)?n(e):n(String(e).split(t)),r},toCamelCase:e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,(function(e,t,r){return t.toUpperCase()+r})),noop:()=>{},toFiniteNumber:(e,t)=>(e=+e,Number.isFinite(e)?e:t),findKey:I,global:L,isContextDefined:H,ALPHABET:Y,generateString:(e=16,t=Y.ALPHA_DIGIT)=>{let r="";const{length:n}=t;for(;e--;)r+=t[Math.random()*n|0];return r},isSpecCompliantForm:function(e){return!!(e&&k(e.append)&&"FormData"===e[Symbol.toStringTag]&&e[Symbol.iterator])},toJSONObject:e=>{const t=new Array(10),r=(e,n)=>{if(_(e)){if(t.indexOf(e)>=0)return;if(!("toJSON"in e)){t[n]=e;const i=P(e)?[]:{};return F(e,((e,t)=>{const o=r(e,n+1);!C(o)&&(i[t]=o)})),t[n]=void 0,i}}return e};return r(e,0)},isAsyncFn:J,isThenable:e=>e&&(_(e)||k(e))&&k(e.then)&&k(e.catch)};function X(e,t,r,n,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack,this.message=e,this.name="AxiosError",t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),i&&(this.response=i)}Q.inherits(X,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:Q.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const Z=X.prototype,ee={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach((e=>{ee[e]={value:e}})),Object.defineProperties(X,ee),Object.defineProperty(Z,"isAxiosError",{value:!0}),X.from=(e,t,r,n,i,o)=>{const l=Object.create(Z);return Q.toFlatObject(e,l,(function(e){return e!==Error.prototype}),(e=>"isAxiosError"!==e)),X.call(l,e.message,t,r,n,i),l.cause=e,l.name=e.name,o&&Object.assign(l,o),l};var te=X;function re(e){return Q.isPlainObject(e)||Q.isArray(e)}function ne(e){return Q.endsWith(e,"[]")?e.slice(0,-2):e}function ie(e,t,r){return e?e.concat(t).map((function(e,t){return e=ne(e),!r&&t?"["+e+"]":e})).join(r?".":""):t}const oe=Q.toFlatObject(Q,{},null,(function(e){return/^is[A-Z]/.test(e)}));var le=function(e,t,r){if(!Q.isObject(e))throw new TypeError("target must be an object");t=t||new FormData;const n=(r=Q.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(e,t){return!Q.isUndefined(t[e])}))).metaTokens,i=r.visitor||c,o=r.dots,l=r.indexes,a=(r.Blob||"undefined"!=typeof Blob&&Blob)&&Q.isSpecCompliantForm(t);if(!Q.isFunction(i))throw new TypeError("visitor must be a function");function s(e){if(null===e)return"";if(Q.isDate(e))return e.toISOString();if(!a&&Q.isBlob(e))throw new te("Blob is not supported. Use a Buffer instead.");return Q.isArrayBuffer(e)||Q.isTypedArray(e)?a&&"function"==typeof Blob?new Blob([e]):Buffer.from(e):e}function c(e,r,i){let a=e;if(e&&!i&&"object"==typeof e)if(Q.endsWith(r,"{}"))r=n?r:r.slice(0,-2),e=JSON.stringify(e);else if(Q.isArray(e)&&function(e){return Q.isArray(e)&&!e.some(re)}(e)||(Q.isFileList(e)||Q.endsWith(r,"[]"))&&(a=Q.toArray(e)))return r=ne(r),a.forEach((function(e,n){!Q.isUndefined(e)&&null!==e&&t.append(!0===l?ie([r],n,o):null===l?r:r+"[]",s(e))})),!1;return!!re(e)||(t.append(ie(i,r,o),s(e)),!1)}const d=[],u=Object.assign(oe,{defaultVisitor:c,convertValue:s,isVisitable:re});if(!Q.isObject(e))throw new TypeError("data must be an object");return function e(r,n){if(!Q.isUndefined(r)){if(-1!==d.indexOf(r))throw Error("Circular reference detected in "+n.join("."));d.push(r),Q.forEach(r,(function(r,o){!0===(!(Q.isUndefined(r)||null===r)&&i.call(t,r,Q.isString(o)?o.trim():o,n,u))&&e(r,n?n.concat(o):[o])})),d.pop()}}(e),t};function ae(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,(function(e){return t[e]}))}function se(e,t){this._pairs=[],e&&le(e,this,t)}const ce=se.prototype;ce.append=function(e,t){this._pairs.push([e,t])},ce.toString=function(e){const t=e?function(t){return e.call(this,t,ae)}:ae;return this._pairs.map((function(e){return t(e[0])+"="+t(e[1])}),"").join("&")};var de=se;function ue(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function pe(e,t,r){if(!t)return e;const n=r&&r.encode||ue,i=r&&r.serialize;let o;if(o=i?i(t,r):Q.isURLSearchParams(t)?t.toString():new de(t,r).toString(n),o){const t=e.indexOf("#");-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+o}return e}var be=class{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!r&&r.synchronous,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){Q.forEach(this.handlers,(function(t){null!==t&&e(t)}))}},fe={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},he={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:de,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},isStandardBrowserEnv:(()=>{let e;return("undefined"==typeof navigator||"ReactNative"!==(e=navigator.product)&&"NativeScript"!==e&&"NS"!==e)&&"undefined"!=typeof window&&"undefined"!=typeof document})(),isStandardBrowserWebWorkerEnv:"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,protocols:["http","https","file","blob","url","data"]},ye=function(e){function t(e,r,n,i){let o=e[i++];const l=Number.isFinite(+o),a=i>=e.length;return o=!o&&Q.isArray(n)?n.length:o,a?(Q.hasOwnProp(n,o)?n[o]=[n[o],r]:n[o]=r,!l):(n[o]&&Q.isObject(n[o])||(n[o]=[]),t(e,r,n[o],i)&&Q.isArray(n[o])&&(n[o]=function(e){const t={},r=Object.keys(e);let n;const i=r.length;let o;for(n=0;n<i;n++)o=r[n],t[o]=e[o];return t}(n[o])),!l)}if(Q.isFormData(e)&&Q.isFunction(e.entries)){const r={};return Q.forEachEntry(e,((e,n)=>{t(function(e){return Q.matchAll(/\w+|\[(\w*)]/g,e).map((e=>"[]"===e[0]?"":e[1]||e[0]))}(e),n,r,0)})),r}return null};const me={"Content-Type":void 0},ge={transitional:fe,adapter:["xhr","http"],transformRequest:[function(e,t){const r=t.getContentType()||"",n=r.indexOf("application/json")>-1,i=Q.isObject(e);if(i&&Q.isHTMLForm(e)&&(e=new FormData(e)),Q.isFormData(e))return n&&n?JSON.stringify(ye(e)):e;if(Q.isArrayBuffer(e)||Q.isBuffer(e)||Q.isStream(e)||Q.isFile(e)||Q.isBlob(e))return e;if(Q.isArrayBufferView(e))return e.buffer;if(Q.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let o;if(i){if(r.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return le(e,new he.classes.URLSearchParams,Object.assign({visitor:function(e,t,r,n){return he.isNode&&Q.isBuffer(e)?(this.append(t,e.toString("base64")),!1):n.defaultVisitor.apply(this,arguments)}},t))}(e,this.formSerializer).toString();if((o=Q.isFileList(e))||r.indexOf("multipart/form-data")>-1){const t=this.env&&this.env.FormData;return le(o?{"files[]":e}:e,t&&new t,this.formSerializer)}}return i||n?(t.setContentType("application/json",!1),function(e,t,r){if(Q.isString(e))try{return(0,JSON.parse)(e),Q.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(0,JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){const t=this.transitional||ge.transitional,r=t&&t.forcedJSONParsing,n="json"===this.responseType;if(e&&Q.isString(e)&&(r&&!this.responseType||n)){const r=!(t&&t.silentJSONParsing)&&n;try{return JSON.parse(e)}catch(e){if(r){if("SyntaxError"===e.name)throw te.from(e,te.ERR_BAD_RESPONSE,this,null,this.response);throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:he.classes.FormData,Blob:he.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};Q.forEach(["delete","get","head"],(function(e){ge.headers[e]={}})),Q.forEach(["post","put","patch"],(function(e){ge.headers[e]=Q.merge(me)}));var ve=ge;const Oe=Q.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),we=Symbol("internals");function Se(e){return e&&String(e).trim().toLowerCase()}function Ee(e){return!1===e||null==e?e:Q.isArray(e)?e.map(Ee):String(e)}function Pe(e,t,r,n,i){return Q.isFunction(n)?n.call(this,t,r):(i&&(t=r),Q.isString(t)?Q.isString(n)?-1!==t.indexOf(n):Q.isRegExp(n)?n.test(t):void 0:void 0)}class Ce{constructor(e){e&&this.set(e)}set(e,t,r){const n=this;function i(e,t,r){const i=Se(t);if(!i)throw new Error("header name must be a non-empty string");const o=Q.findKey(n,i);(!o||void 0===n[o]||!0===r||void 0===r&&!1!==n[o])&&(n[o||t]=Ee(e))}const o=(e,t)=>Q.forEach(e,((e,r)=>i(e,r,t)));return Q.isPlainObject(e)||e instanceof this.constructor?o(e,t):Q.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim())?o((e=>{const t={};let r,n,i;return e&&e.split("\n").forEach((function(e){i=e.indexOf(":"),r=e.substring(0,i).trim().toLowerCase(),n=e.substring(i+1).trim(),!r||t[r]&&Oe[r]||("set-cookie"===r?t[r]?t[r].push(n):t[r]=[n]:t[r]=t[r]?t[r]+", "+n:n)})),t})(e),t):null!=e&&i(t,e,r),this}get(e,t){if(e=Se(e)){const r=Q.findKey(this,e);if(r){const e=this[r];if(!t)return e;if(!0===t)return function(e){const t=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(e);)t[n[1]]=n[2];return t}(e);if(Q.isFunction(t))return t.call(this,e,r);if(Q.isRegExp(t))return t.exec(e);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=Se(e)){const r=Q.findKey(this,e);return!(!r||void 0===this[r]||t&&!Pe(0,this[r],r,t))}return!1}delete(e,t){const r=this;let n=!1;function i(e){if(e=Se(e)){const i=Q.findKey(r,e);!i||t&&!Pe(0,r[i],i,t)||(delete r[i],n=!0)}}return Q.isArray(e)?e.forEach(i):i(e),n}clear(e){const t=Object.keys(this);let r=t.length,n=!1;for(;r--;){const i=t[r];e&&!Pe(0,this[i],i,e,!0)||(delete this[i],n=!0)}return n}normalize(e){const t=this,r={};return Q.forEach(this,((n,i)=>{const o=Q.findKey(r,i);if(o)return t[o]=Ee(n),void delete t[i];const l=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,((e,t,r)=>t.toUpperCase()+r))}(i):String(i).trim();l!==i&&delete t[i],t[l]=Ee(n),r[l]=!0})),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return Q.forEach(this,((r,n)=>{null!=r&&!1!==r&&(t[n]=e&&Q.isArray(r)?r.join(", "):r)})),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map((([e,t])=>e+": "+t)).join("\n")}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const r=new this(e);return t.forEach((e=>r.set(e))),r}static accessor(e){const t=(this[we]=this[we]={accessors:{}}).accessors,r=this.prototype;function n(e){const n=Se(e);t[n]||(function(e,t){const r=Q.toCamelCase(" "+t);["get","set","has"].forEach((n=>{Object.defineProperty(e,n+r,{value:function(e,r,i){return this[n].call(this,t,e,r,i)},configurable:!0})}))}(r,e),t[n]=!0)}return Q.isArray(e)?e.forEach(n):n(e),this}}Ce.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),Q.freezeMethods(Ce.prototype),Q.freezeMethods(Ce);var xe=Ce;function Te(e,t){const r=this||ve,n=t||r,i=xe.from(n.headers);let o=n.data;return Q.forEach(e,(function(e){o=e.call(r,o,i.normalize(),t?t.status:void 0)})),i.normalize(),o}function ke(e){return!(!e||!e.__CANCEL__)}function je(e,t,r){te.call(this,null==e?"canceled":e,te.ERR_CANCELED,t,r),this.name="CanceledError"}Q.inherits(je,te,{__CANCEL__:!0});var _e=je,Re=he.isStandardBrowserEnv?{write:function(e,t,r,n,i,o){const l=[];l.push(e+"="+encodeURIComponent(t)),Q.isNumber(r)&&l.push("expires="+new Date(r).toGMTString()),Q.isString(n)&&l.push("path="+n),Q.isString(i)&&l.push("domain="+i),!0===o&&l.push("secure"),document.cookie=l.join("; ")},read:function(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}};function Ae(e,t){return e&&!/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)?function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}(e,t):t}var De=he.isStandardBrowserEnv?function(){const e=/(msie|trident)/i.test(navigator.userAgent),t=document.createElement("a");let r;function n(r){let n=r;return e&&(t.setAttribute("href",n),n=t.href),t.setAttribute("href",n),{href:t.href,protocol:t.protocol?t.protocol.replace(/:$/,""):"",host:t.host,search:t.search?t.search.replace(/^\?/,""):"",hash:t.hash?t.hash.replace(/^#/,""):"",hostname:t.hostname,port:t.port,pathname:"/"===t.pathname.charAt(0)?t.pathname:"/"+t.pathname}}return r=n(window.location.href),function(e){const t=Q.isString(e)?n(e):e;return t.protocol===r.protocol&&t.host===r.host}}():function(){return!0};function Me(e,t){let r=0;const n=function(e,t){e=e||10;const r=new Array(e),n=new Array(e);let i,o=0,l=0;return t=void 0!==t?t:1e3,function(a){const s=Date.now(),c=n[l];i||(i=s),r[o]=a,n[o]=s;let d=l,u=0;for(;d!==o;)u+=r[d++],d%=e;if(o=(o+1)%e,o===l&&(l=(l+1)%e),s-i<t)return;const p=c&&s-c;return p?Math.round(1e3*u/p):void 0}}(50,250);return i=>{const o=i.loaded,l=i.lengthComputable?i.total:void 0,a=o-r,s=n(a);r=o;const c={loaded:o,total:l,progress:l?o/l:void 0,bytes:a,rate:s||void 0,estimated:s&&l&&o<=l?(l-o)/s:void 0,event:i};c[t?"download":"upload"]=!0,e(c)}}const Ne={http:null,xhr:"undefined"!=typeof XMLHttpRequest&&function(e){return new Promise((function(t,r){let n=e.data;const i=xe.from(e.headers).normalize(),o=e.responseType;let l;function a(){e.cancelToken&&e.cancelToken.unsubscribe(l),e.signal&&e.signal.removeEventListener("abort",l)}Q.isFormData(n)&&(he.isStandardBrowserEnv||he.isStandardBrowserWebWorkerEnv?i.setContentType(!1):i.setContentType("multipart/form-data;",!1));let s=new XMLHttpRequest;if(e.auth){const t=e.auth.username||"",r=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";i.set("Authorization","Basic "+btoa(t+":"+r))}const c=Ae(e.baseURL,e.url);function d(){if(!s)return;const n=xe.from("getAllResponseHeaders"in s&&s.getAllResponseHeaders());!function(e,t,r){const n=r.config.validateStatus;r.status&&n&&!n(r.status)?t(new te("Request failed with status code "+r.status,[te.ERR_BAD_REQUEST,te.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r)):e(r)}((function(e){t(e),a()}),(function(e){r(e),a()}),{data:o&&"text"!==o&&"json"!==o?s.response:s.responseText,status:s.status,statusText:s.statusText,headers:n,config:e,request:s}),s=null}if(s.open(e.method.toUpperCase(),pe(c,e.params,e.paramsSerializer),!0),s.timeout=e.timeout,"onloadend"in s?s.onloadend=d:s.onreadystatechange=function(){s&&4===s.readyState&&(0!==s.status||s.responseURL&&0===s.responseURL.indexOf("file:"))&&setTimeout(d)},s.onabort=function(){s&&(r(new te("Request aborted",te.ECONNABORTED,e,s)),s=null)},s.onerror=function(){r(new te("Network Error",te.ERR_NETWORK,e,s)),s=null},s.ontimeout=function(){let t=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const n=e.transitional||fe;e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),r(new te(t,n.clarifyTimeoutError?te.ETIMEDOUT:te.ECONNABORTED,e,s)),s=null},he.isStandardBrowserEnv){const t=(e.withCredentials||De(c))&&e.xsrfCookieName&&Re.read(e.xsrfCookieName);t&&i.set(e.xsrfHeaderName,t)}void 0===n&&i.setContentType(null),"setRequestHeader"in s&&Q.forEach(i.toJSON(),(function(e,t){s.setRequestHeader(t,e)})),Q.isUndefined(e.withCredentials)||(s.withCredentials=!!e.withCredentials),o&&"json"!==o&&(s.responseType=e.responseType),"function"==typeof e.onDownloadProgress&&s.addEventListener("progress",Me(e.onDownloadProgress,!0)),"function"==typeof e.onUploadProgress&&s.upload&&s.upload.addEventListener("progress",Me(e.onUploadProgress)),(e.cancelToken||e.signal)&&(l=t=>{s&&(r(!t||t.type?new _e(null,e,s):t),s.abort(),s=null)},e.cancelToken&&e.cancelToken.subscribe(l),e.signal&&(e.signal.aborted?l():e.signal.addEventListener("abort",l)));const u=function(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}(c);u&&-1===he.protocols.indexOf(u)?r(new te("Unsupported protocol "+u+":",te.ERR_BAD_REQUEST,e)):s.send(n||null)}))}};Q.forEach(Ne,((e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(e){}Object.defineProperty(e,"adapterName",{value:t})}}));function Be(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new _e(null,e)}function Fe(e){return Be(e),e.headers=xe.from(e.headers),e.data=Te.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1),(e=>{e=Q.isArray(e)?e:[e];const{length:t}=e;let r,n;for(let i=0;i<t&&(r=e[i],!(n=Q.isString(r)?Ne[r.toLowerCase()]:r));i++);if(!n){if(!1===n)throw new te(`Adapter ${r} is not supported by the environment`,"ERR_NOT_SUPPORT");throw new Error(Q.hasOwnProp(Ne,r)?`Adapter '${r}' is not available in the build`:`Unknown adapter '${r}'`)}if(!Q.isFunction(n))throw new TypeError("adapter is not a function");return n})(e.adapter||ve.adapter)(e).then((function(t){return Be(e),t.data=Te.call(e,e.transformResponse,t),t.headers=xe.from(t.headers),t}),(function(t){return ke(t)||(Be(e),t&&t.response&&(t.response.data=Te.call(e,e.transformResponse,t.response),t.response.headers=xe.from(t.response.headers))),Promise.reject(t)}))}const Ie=e=>e instanceof xe?e.toJSON():e;function Le(e,t){t=t||{};const r={};function n(e,t,r){return Q.isPlainObject(e)&&Q.isPlainObject(t)?Q.merge.call({caseless:r},e,t):Q.isPlainObject(t)?Q.merge({},t):Q.isArray(t)?t.slice():t}function i(e,t,r){return Q.isUndefined(t)?Q.isUndefined(e)?void 0:n(void 0,e,r):n(e,t,r)}function o(e,t){if(!Q.isUndefined(t))return n(void 0,t)}function l(e,t){return Q.isUndefined(t)?Q.isUndefined(e)?void 0:n(void 0,e):n(void 0,t)}function a(r,i,o){return o in t?n(r,i):o in e?n(void 0,r):void 0}const s={url:o,method:o,data:o,baseURL:l,transformRequest:l,transformResponse:l,paramsSerializer:l,timeout:l,timeoutMessage:l,withCredentials:l,adapter:l,responseType:l,xsrfCookieName:l,xsrfHeaderName:l,onUploadProgress:l,onDownloadProgress:l,decompress:l,maxContentLength:l,maxBodyLength:l,beforeRedirect:l,transport:l,httpAgent:l,httpsAgent:l,cancelToken:l,socketPath:l,responseEncoding:l,validateStatus:a,headers:(e,t)=>i(Ie(e),Ie(t),!0)};return Q.forEach(Object.keys(Object.assign({},e,t)),(function(n){const o=s[n]||i,l=o(e[n],t[n],n);Q.isUndefined(l)&&o!==a||(r[n]=l)})),r}const He={};["object","boolean","number","function","string","symbol"].forEach(((e,t)=>{He[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}}));const Ve={};He.transitional=function(e,t,r){function n(e,t){return"[Axios v1.4.0] Transitional option '"+e+"'"+t+(r?". "+r:"")}return(r,i,o)=>{if(!1===e)throw new te(n(i," has been removed"+(t?" in "+t:"")),te.ERR_DEPRECATED);return t&&!Ve[i]&&(Ve[i]=!0,console.warn(n(i," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(r,i,o)}};var Ue={assertOptions:function(e,t,r){if("object"!=typeof e)throw new te("options must be an object",te.ERR_BAD_OPTION_VALUE);const n=Object.keys(e);let i=n.length;for(;i-- >0;){const o=n[i],l=t[o];if(l){const t=e[o],r=void 0===t||l(t,o,e);if(!0!==r)throw new te("option "+o+" must be "+r,te.ERR_BAD_OPTION_VALUE)}else if(!0!==r)throw new te("Unknown option "+o,te.ERR_BAD_OPTION)}},validators:He};const Ge=Ue.validators;class qe{constructor(e){this.defaults=e,this.interceptors={request:new be,response:new be}}request(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},t=Le(this.defaults,t);const{transitional:r,paramsSerializer:n,headers:i}=t;let o;void 0!==r&&Ue.assertOptions(r,{silentJSONParsing:Ge.transitional(Ge.boolean),forcedJSONParsing:Ge.transitional(Ge.boolean),clarifyTimeoutError:Ge.transitional(Ge.boolean)},!1),null!=n&&(Q.isFunction(n)?t.paramsSerializer={serialize:n}:Ue.assertOptions(n,{encode:Ge.function,serialize:Ge.function},!0)),t.method=(t.method||this.defaults.method||"get").toLowerCase(),o=i&&Q.merge(i.common,i[t.method]),o&&Q.forEach(["delete","get","head","post","put","patch","common"],(e=>{delete i[e]})),t.headers=xe.concat(o,i);const l=[];let a=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(a=a&&e.synchronous,l.unshift(e.fulfilled,e.rejected))}));const s=[];let c;this.interceptors.response.forEach((function(e){s.push(e.fulfilled,e.rejected)}));let d,u=0;if(!a){const e=[Fe.bind(this),void 0];for(e.unshift.apply(e,l),e.push.apply(e,s),d=e.length,c=Promise.resolve(t);u<d;)c=c.then(e[u++],e[u++]);return c}d=l.length;let p=t;for(u=0;u<d;){const e=l[u++],t=l[u++];try{p=e(p)}catch(e){t.call(this,e);break}}try{c=Fe.call(this,p)}catch(e){return Promise.reject(e)}for(u=0,d=s.length;u<d;)c=c.then(s[u++],s[u++]);return c}getUri(e){return pe(Ae((e=Le(this.defaults,e)).baseURL,e.url),e.params,e.paramsSerializer)}}Q.forEach(["delete","get","head","options"],(function(e){qe.prototype[e]=function(t,r){return this.request(Le(r||{},{method:e,url:t,data:(r||{}).data}))}})),Q.forEach(["post","put","patch"],(function(e){function t(t){return function(r,n,i){return this.request(Le(i||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:r,data:n}))}}qe.prototype[e]=t(),qe.prototype[e+"Form"]=t(!0)}));var We=qe;class ze{constructor(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");let t;this.promise=new Promise((function(e){t=e}));const r=this;this.promise.then((e=>{if(!r._listeners)return;let t=r._listeners.length;for(;t-- >0;)r._listeners[t](e);r._listeners=null})),this.promise.then=e=>{let t;const n=new Promise((e=>{r.subscribe(e),t=e})).then(e);return n.cancel=function(){r.unsubscribe(t)},n},e((function(e,n,i){r.reason||(r.reason=new _e(e,n,i),t(r.reason))}))}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}static source(){let e;return{token:new ze((function(t){e=t})),cancel:e}}}var $e=ze;const Ke={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Ke).forEach((([e,t])=>{Ke[t]=e}));var Ye=Ke;const Je=function e(t){const r=new We(t),n=m(We.prototype.request,r);return Q.extend(n,We.prototype,r,{allOwnKeys:!0}),Q.extend(n,r,null,{allOwnKeys:!0}),n.create=function(r){return e(Le(t,r))},n}(ve);Je.Axios=We,Je.CanceledError=_e,Je.CancelToken=$e,Je.isCancel=ke,Je.VERSION="1.4.0",Je.toFormData=le,Je.AxiosError=te,Je.Cancel=Je.CanceledError,Je.all=function(e){return Promise.all(e)},Je.spread=function(e){return function(t){return e.apply(null,t)}},Je.isAxiosError=function(e){return Q.isObject(e)&&!0===e.isAxiosError},Je.mergeConfig=Le,Je.AxiosHeaders=xe,Je.formToJSON=e=>ye(Q.isHTMLForm(e)?new FormData(e):e),Je.HttpStatusCode=Ye,Je.default=Je;var Qe=Je,Xe=(0,f.withSelect)((e=>{const{getEntityRecords:t}=e("core");return{categories:t("taxonomy","category",{per_page:-1})}}))((e=>{let{attributes:t,updateSelectedCategory:r,categories:n,disabled:o}=e,l=[];return Array.isArray(n)&&(l=n.map((e=>{let{id:t,name:r}=e;return{label:(n=r,"Uncategorized"===n?"Posts with no category assigned (Uncategorized)":`Posts assigned the '${n}' category`),value:t};var n})),l.unshift({value:-1,label:"All posts in site"})),(0,i.createElement)(b.SelectControl,{label:"Add this Video to:",disabled:o,value:t.category,onChange:e=>r(e),options:l})})),Ze=r.p+"images/humixlogo.6dc300c9.png",et=r(361),tt=r.n(et);const rt=/^https?:\/\/(www\.)?(humix\.com\/[\w-]{11,}|humix\.com\/([\w-]+\/)?video\/(playlist\/)?[\w-]{11,}|[\w.-]+\/humix\/video\/(playlist\/)?[\w-]{11,})([\?|\&]?[\w]+=[\w-]*)*$/,nt="https://www.humix.com/generate-embed-code?j=",it=[{id:2,label:"Arts & Entertainment",children:[{id:3,label:"Celebrities & Entertainment News"},{id:4,label:"Comics & Animation",children:[{id:5,label:"Anime & Manga"},{id:6,label:"Cartoons"},{id:7,label:"Comics"},{id:622,label:"Other"}]},{id:8,label:"Entertainment Industry",children:[{id:9,label:"Film & TV Industry"},{id:10,label:"Recording Industry"},{id:623,label:"Other"}]},{id:11,label:"Events & Listings",children:[{id:12,label:"Bars, Clubs & Nightlife"},{id:13,label:"Concerts & Music Festivals"},{id:14,label:"Expos & Conventions"},{id:15,label:"Film Festivals"},{id:16,label:"Movie Listings & Theater Showtimes"},{id:624,label:"Event Ticket Sales"},{id:625,label:"Food & Beverage Events"},{id:626,label:"Live Sporting Events"},{id:627,label:"Other"}]},{id:17,label:"Fun & Trivia",children:[{id:18,label:"Flash-Based Entertainment"},{id:19,label:"Fun Tests & Silly Surveys"},{id:628,label:"Other"}]},{id:20,label:"Humor",children:[{id:21,label:"Funny Pictures & Videos"},{id:22,label:"Political Humor"},{id:629,label:"Live Comedy"},{id:630,label:"Spoofs & Satire"},{id:631,label:"Other"}]},{id:23,label:"Movies",children:[{id:632,label:"Action & Adventure Films"},{id:633,label:"Animated Films"},{id:634,label:"Bollywood & South Asian Films"},{id:635,label:"Classic Films"},{id:636,label:"Comedy Films"},{id:637,label:"Cult & Indie Films"},{id:638,label:"Documentary Films"},{id:639,label:"Drama Films"},{id:640,label:"DVD & Video Shopping"},{id:641,label:"Family Films"},{id:642,label:"Horror Films"},{id:643,label:"Movie Memorabilia"},{id:644,label:"Movie Reference"},{id:645,label:"Musical Films"},{id:646,label:"Romance Films"},{id:647,label:"Science Fiction & Fantasy Films"},{id:648,label:"Thriller, Crime & Mystery Films"},{id:649,label:"Other"}]},{id:24,label:"Music & Audio",children:[{id:25,label:"CD & Audio Shopping"},{id:26,label:"Classical Music"},{id:27,label:"Country Music"},{id:28,label:"Dance & Electronic Music"},{id:29,label:"Experimental & Industrial Music"},{id:30,label:"Jazz & Blues"},{id:31,label:"Music Education & Instruction"},{id:32,label:"Music Equipment & Technology"},{id:33,label:"Music Reference"},{id:34,label:"Music Streams & Downloads"},{id:35,label:"Music Videos"},{id:36,label:"Pop Music"},{id:37,label:"Radio"},{id:38,label:"Religious Music"},{id:39,label:"Rock Music"},{id:40,label:"Soundtracks"},{id:41,label:"Urban & Hip-Hop"},{id:42,label:"World Music"},{id:650,label:"Folk & Traditional Music"},{id:651,label:"Music Art & Memorabilia"},{id:652,label:"Podcasts"},{id:653,label:"Vocals & Show Tunes"},{id:654,label:"Other"}]},{id:43,label:"Offbeat",children:[{id:44,label:"Occult & Paranormal"},{id:655,label:"Other"}]},{id:45,label:"Online Media",children:[{id:46,label:"Online Image Galleries"},{id:656,label:"Virtual Tours"},{id:657,label:"Other"}]},{id:47,label:"Performing Arts",children:[{id:48,label:"Acting & Theater"},{id:49,label:"Circus"},{id:50,label:"Dance"},{id:51,label:"Magic"},{id:52,label:"Opera"},{id:658,label:"Broadway & Musical Theater"},{id:659,label:"Other"}]},{id:53,label:"TV & Video",children:[{id:54,label:"Online Video"},{id:55,label:"TV Commercials"},{id:56,label:"TV Shows & Programs"},{id:660,label:"TV Guides & Reference"},{id:661,label:"TV Networks & Stations"},{id:662,label:"Other"}]},{id:57,label:"Visual Art & Design",children:[{id:58,label:"Architecture"},{id:59,label:"Art Museums & Galleries"},{id:60,label:"Design"},{id:61,label:"Painting"},{id:62,label:"Photographic & Digital Arts"},{id:663,label:"Sculpture"},{id:664,label:"Visual Arts & Design Education"},{id:665,label:"Other"}]},{id:621,label:"Other"}]},{id:63,label:"Autos & Vehicles",children:[{id:64,label:"Bicycles & Accessories",children:[{id:65,label:"Bike Parts & Repair"},{id:66,label:"BMX Bikes"},{id:667,label:"Bike Accessories"},{id:668,label:"Bike Frames"},{id:669,label:"Bike Helmets & Protective Gear"},{id:670,label:"Cruiser Bicycles"},{id:671,label:"Electric Bicycles"},{id:672,label:"Kids' Bikes"},{id:673,label:"Mountain Bikes"},{id:674,label:"Road Bikes"},{id:675,label:"Other"}]},{id:67,label:"Boats & Watercraft"},{id:68,label:"Campers & RVs"},{id:69,label:"Classic Vehicles"},{id:70,label:"Cargo Trucks & Trailers"},{id:71,label:"Motor Vehicles (By Type)",children:[{id:72,label:"Hybrid & Alternative Vehicles"},{id:73,label:"Motorcycles"},{id:74,label:"Off-Road Vehicles"},{id:75,label:"Trucks & SUVs"},{id:727,label:"Autonomous Vehicles"},{id:728,label:"Compact Cars"},{id:729,label:"Convertibles"},{id:730,label:"Coupes"},{id:731,label:"Diesel Vehicles"},{id:732,label:"Hatchbacks"},{id:733,label:"Luxury Vehicles"},{id:734,label:"Microcars & Subcompacts"},{id:735,label:"Scooters & Mopeds"},{id:736,label:"Sedans"},{id:737,label:"Sports Cars"},{id:738,label:"Station Wagons"},{id:739,label:"Trucks, Vans & SUVs"},{id:740,label:"Other"}]},{id:76,label:"Vehicle Codes & Driving Laws",children:[{id:77,label:"Vehicle Licensing & Registration"},{id:742,label:"Drunk Driving Law"},{id:743,label:"Other"}]},{id:78,label:"Vehicle Parts & Services",children:[{id:79,label:"Gas Prices & Vehicle Fueling"},{id:80,label:"Vehicle Parts & Accessories"},{id:81,label:"Vehicle Repair & Maintenance"},{id:744,label:"Towing & Roadside Assistance"},{id:745,label:"Vehicle Modification & Tuning"},{id:746,label:"Other"}]},{id:82,label:"Vehicle Shopping",children:[{id:83,label:"Used Vehicles"},{id:747,label:"Vehicle Dealers & Retailers"},{id:748,label:"Vehicle Specs, Reviews & Comparisons"},{id:749,label:"Other"}]},{id:84,label:"Vehicle Shows"},{id:666,label:"Other"},{id:676,label:"Other"},{id:677,label:"Custom & Performance Vehicles"},{id:678,label:"Audi",children:[{id:679,label:"Bentley"},{id:680,label:"BMW"},{id:681,label:"Buick"},{id:682,label:"Cadillac"},{id:683,label:"Chevrolet"},{id:684,label:"Chrysler"},{id:685,label:"Citroën"},{id:686,label:"Daewoo Motors"},{id:687,label:"Dodge"},{id:688,label:"Ferrari"},{id:689,label:"Fiat"},{id:690,label:"Ford"},{id:691,label:"GMC"},{id:692,label:"Honda"},{id:693,label:"Hummer"},{id:694,label:"Hyundai"},{id:695,label:"Isuzu"},{id:696,label:"Jaguar"},{id:697,label:"Jeep"},{id:698,label:"Kia"},{id:699,label:"Lamborghini"},{id:700,label:"Land Rover"},{id:701,label:"Lincoln"},{id:702,label:"Maserati"},{id:703,label:"Mazda"},{id:704,label:"Mercedes-Benz"},{id:705,label:"Mercury"},{id:706,label:"Mini"},{id:707,label:"Mitsubishi"},{id:708,label:"Nissan"},{id:709,label:"Peugeot"},{id:710,label:"Pontiac"},{id:711,label:"Porsche"},{id:712,label:"Ram Trucks"},{id:713,label:"Renault"},{id:714,label:"Rolls-Royce"},{id:715,label:"Saab"},{id:716,label:"Saturn"},{id:717,label:"SEAT"},{id:718,label:"Skoda"},{id:719,label:"Subaru"},{id:720,label:"Suzuki"},{id:721,label:"Tesla Motors"},{id:722,label:"Toyota"},{id:723,label:"Vauxhall-Opel"},{id:724,label:"Volkswagen"},{id:725,label:"Volvo"},{id:726,label:"Other"}]},{id:741,label:"Personal Aircraft"}]},{id:85,label:"Beauty & Fitness",children:[{id:86,label:"Beauty Pageants"},{id:87,label:"Body Art"},{id:88,label:"Cosmetic Procedures",children:[{id:89,label:"Cosmetic Surgery"}]},{id:90,label:"Cosmetology & Beauty Professionals"},{id:91,label:"Face & Body Care",children:[{id:92,label:"Hygiene & Toiletries"},{id:93,label:"Make-Up & Cosmetics"},{id:94,label:"Perfumes & Fragrances"},{id:95,label:"Skin & Nail Care"},{id:96,label:"Unwanted Body & Facial Hair Removal"},{id:755,label:"Clean Beauty"},{id:756,label:"Sun Care & Tanning Products"},{id:757,label:"Other"}]},{id:97,label:"Fashion & Style",children:[{id:98,label:"Fashion Designers & Collections"},{id:758,label:"Other"}]},{id:99,label:"Fitness",children:[{id:759,label:"Bodybuilding"},{id:760,label:"Fitness Equipment & Accessories"},{id:761,label:"Fitness Instruction & Personal Training"},{id:762,label:"Gyms & Health Clubs"},{id:763,label:"High Intensity Interval Training"},{id:764,label:"Yoga & Pilates"},{id:765,label:"Other"}]},{id:100,label:"Hair Care",children:[{id:101,label:"Hair Loss"},{id:766,label:"Shampoos & Conditioners"},{id:767,label:"Other"}]},{id:102,label:"Spas & Beauty Services",children:[{id:103,label:"Massage Therapy"}]},{id:104,label:"Weight Loss"},{id:750,label:"Other"},{id:751,label:"Cosmetic Procedures",children:[{id:752,label:"Manicures & Pedicures"},{id:753,label:"Massage Therapy"},{id:754,label:"Other"}]}]},{id:105,label:"Books & Literature",children:[{id:106,label:"Children's Literature"},{id:107,label:"E-Books"},{id:108,label:"Fan Fiction"},{id:109,label:"Literary Classics"},{id:110,label:"Poetry"},{id:111,label:"Writers Resources"},{id:768,label:"Audiobooks"},{id:769,label:"Book Retailers"},{id:770,label:"Other"}]},{id:112,label:"Business & Industrial",children:[{id:113,label:"Public Relations"},{id:114,label:"Space Technology"},{id:115,label:"Agriculture & Forestry",children:[{id:116,label:"Agricultural Equipment"},{id:117,label:"Forestry"},{id:118,label:"Livestock"},{id:779,label:"Aquaculture"},{id:780,label:"Crops & Seed"},{id:781,label:"Farms & Ranches"},{id:782,label:"Other"}]},{id:119,label:"Automotive Industry"},{id:120,label:"Business Education"},{id:121,label:"Business Finance",children:[{id:122,label:"Venture Capital"},{id:783,label:"Commercial Lending"},{id:784,label:"Investment Banking"},{id:785,label:"Risk Management"},{id:786,label:"Other"}]},{id:123,label:"Business Operations",children:[{id:124,label:"Business Plans & Presentations"},{id:125,label:"Management"},{id:787,label:"Flexible Work Arrangements"},{id:788,label:"Human Resources"},{id:789,label:"Other"}]},{id:126,label:"Business Services",children:[{id:127,label:"Consulting"},{id:128,label:"Corporate Events"},{id:129,label:"E-Commerce Services"},{id:130,label:"Fire & Security Services"},{id:131,label:"Office Services"},{id:132,label:"Office Supplies"},{id:133,label:"Writing & Editing Services"},{id:790,label:"Commercial Distribution"},{id:791,label:"Knowledge Management"},{id:792,label:"Outsourcing"},{id:793,label:"Physical Asset Management"},{id:794,label:"Quality Control & Tracking"},{id:795,label:"Shared Workspaces"},{id:796,label:"Signage"},{id:797,label:"Warehousing"},{id:798,label:"Other"}]},{id:134,label:"Chemicals Industry",children:[{id:135,label:"Cleaning Agents"},{id:136,label:"Plastics & Polymers"},{id:799,label:"Agrochemicals"},{id:800,label:"Coatings & Adhesives"},{id:801,label:"Dyes & Pigments"},{id:802,label:"Other"}]},{id:137,label:"Construction & Maintenance",children:[{id:138,label:"Building Materials & Supplies"},{id:803,label:"Civil Engineering"},{id:804,label:"Other"}]},{id:139,label:"Energy & Utilities",children:[{id:140,label:"Electricity"},{id:141,label:"Oil & Gas"},{id:142,label:"Renewable & Alternative Energy"},{id:805,label:"Nuclear Energy"},{id:806,label:"Waste Management"},{id:807,label:"Other"}]},{id:143,label:"Hospitality Industry",children:[{id:144,label:"Event Planning"},{id:145,label:"Food Service"},{id:808,label:"Event Venue Rentals"},{id:809,label:"Other"}]},{id:146,label:"Industrial Materials & Equipment",children:[{id:147,label:"Heavy Machinery"},{id:810,label:"Fluid Handling"},{id:811,label:"Generators"},{id:812,label:"Industrial Handling & Processing Equipment"},{id:813,label:"Industrial Measurement & Control Equipment"},{id:814,label:"Other"}]},{id:148,label:"Manufacturing",children:[{id:815,label:"Factory Automation"},{id:816,label:"Other"}]},{id:149,label:"Metals & Mining",children:[{id:150,label:"Precious Metals"},{id:817,label:"Other"}]},{id:151,label:"Pharmaceuticals & Biotech"},{id:152,label:"Printing & Publishing",children:[{id:818,label:"Document & Printing Services"},{id:819,label:"Other"}]},{id:153,label:"Retail Trade",children:[{id:154,label:"Retail Equipment & Technology"},{id:820,label:"Other"}]},{id:155,label:"MLM & Business Opportunities"},{id:156,label:"Textiles & Nonwovens"},{id:157,label:"Transportation & Logistics",children:[{id:158,label:"Freight & Trucking"},{id:159,label:"Mail & Package Delivery"},{id:160,label:"Maritime Transport"},{id:161,label:"Moving & Relocation"},{id:162,label:"Packaging"},{id:163,label:"Parking"},{id:164,label:"Rail Transport"},{id:165,label:"Urban Transport"}]},{id:771,label:"Other"},{id:772,label:"Brand Management",children:[{id:773,label:"Marketing"},{id:774,label:"Sales"},{id:775,label:"Telemarketing"},{id:776,label:"Other"}]},{id:777,label:"Aviation Industry",children:[{id:778,label:"Other"}]},{id:821,label:"Other",children:[{id:822,label:"Import & Export"},{id:823,label:"Mail & Package Delivery"},{id:824,label:"Moving & Relocation"},{id:825,label:"Packaging"},{id:826,label:"Self Storage"}]},{id:827,label:"Business Formation",children:[{id:828,label:"Home Office"},{id:829,label:"Other"}]}]},{id:166,label:"Computers & Electronics",children:[{id:167,label:"CAD & CAM"},{id:168,label:"Computer Hardware",children:[{id:169,label:"Computer Components"},{id:170,label:"Computer Drives & Storage"},{id:171,label:"Computer Peripherals"},{id:172,label:"Desktop Computers"},{id:173,label:"Laptops & Notebooks"},{id:831,label:"Computer Servers"},{id:832,label:"Hardware Modding & Tuning"},{id:833,label:"Other"}]},{id:174,label:"Computer Security",children:[{id:175,label:"Hacking & Cracking"},{id:834,label:"Antivirus & Malware"},{id:835,label:"Network Security"},{id:836,label:"Other"}]},{id:176,label:"Consumer Electronics",children:[{id:177,label:"Audio Equipment"},{id:178,label:"Camera & Photo Equipment"},{id:179,label:"Car Electronics"},{id:180,label:"Drones & RC Aircraft"},{id:181,label:"Game Systems & Consoles"},{id:182,label:"GPS & Navigation"},{id:183,label:"TV & Video Equipment"},{id:837,label:"Electronic Accessories"},{id:838,label:"Gadgets & Portable Electronics"},{id:839,label:"Home Automation"},{id:840,label:"Media Streaming Devices"},{id:841,label:"Virtual Reality Devices"},{id:842,label:"Other"}]},{id:184,label:"Electronics & Electrical",children:[{id:185,label:"Electronic Components"},{id:186,label:"Power Supplies"},{id:843,label:"Data Sheets & Electronics Reference"},{id:844,label:"Electrical Test & Measurement"},{id:845,label:"Electromechanical Devices"},{id:846,label:"Optoelectronics & Fiber"},{id:847,label:"Other"}]},{id:187,label:"Enterprise Technology",children:[{id:188,label:"Data Management"},{id:848,label:"Customer Relationship Management (CRM)"},{id:849,label:"Enterprise Resource Planning (ERP)"},{id:850,label:"Helpdesk & Customer Support Systems"},{id:851,label:"Other"}]},{id:189,label:"Networking",children:[{id:190,label:"Data Formats & Protocols"},{id:191,label:"Network Monitoring & Management"},{id:192,label:"VPN & Remote Access"},{id:852,label:"Distributed & Cloud Computing"},{id:853,label:"Networking Equipment"},{id:854,label:"Other"}]},{id:193,label:"Programming",children:[{id:194,label:"Java (Programming Language)"},{id:855,label:"C & C++"},{id:856,label:"Development Tools"},{id:857,label:"Scripting Languages"},{id:858,label:"Windows & .NET"},{id:859,label:"Other"}]},{id:195,label:"Software",children:[{id:196,label:"Business & Productivity Software"},{id:197,label:"Device Drivers"},{id:198,label:"Internet Software"},{id:199,label:"Multimedia Software"},{id:200,label:"Operating Systems"},{id:201,label:"Software Utilities"},{id:860,label:"Educational Software"},{id:861,label:"Freeware & Shareware"},{id:862,label:"Intelligent Personal Assistants"},{id:863,label:"Monitoring Software"},{id:864,label:"Open Source"},{id:865,label:"Other"}]},{id:830,label:"Other"}]},{id:202,label:"Finance",children:[{id:203,label:"Accounting & Auditing",children:[{id:204,label:"Billing & Invoicing"},{id:205,label:"Tax Preparation & Planning"},{id:867,label:"Bookkeeping"},{id:868,label:"Other"}]},{id:206,label:"Banking",children:[{id:869,label:"ATMs & Branch Locations"},{id:870,label:"Debit & Checking Services"},{id:871,label:"Mobile Payments & Digital Wallets"},{id:872,label:"Money Transfer & Wire Services"},{id:873,label:"Savings Accounts"},{id:874,label:"Other"}]},{id:207,label:"Credit & Lending",children:[{id:208,label:"Credit Cards"},{id:209,label:"Credit Reporting & Monitoring"},{id:210,label:"Loans"},{id:875,label:"Debt Collection & Repossession"},{id:876,label:"Debt Management"},{id:877,label:"Other"}]},{id:211,label:"Financial Planning & Management",children:[{id:212,label:"Retirement & Pension"},{id:879,label:"Asset & Portfolio Management"},{id:880,label:"Inheritance & Estate Planning"},{id:881,label:"Other"}]},{id:213,label:"Grants, Scholarships & Financial Aid",children:[{id:214,label:"Study Grants & Scholarships"},{id:882,label:"Government Grants"},{id:883,label:"Other"}]},{id:215,label:"Insurance",children:[{id:216,label:"Health Insurance"},{id:884,label:"Home Insurance"},{id:885,label:"Life Insurance"},{id:886,label:"Travel Insurance"},{id:887,label:"Vehicle Insurance"},{id:888,label:"Other"}]},{id:217,label:"Investing",children:[{id:218,label:"Commodities & Futures Trading"},{id:219,label:"Currencies & Foreign Exchange"},{id:220,label:"Stocks & Bonds"},{id:889,label:"Brokerages & Day Trading"},{id:890,label:"Derivatives"},{id:891,label:"Funds"},{id:892,label:"Real Estate Investment Trusts"},{id:893,label:"Socially Responsible Investing"},{id:894,label:"Other"}]},{id:866,label:"Other"},{id:878,label:"Crowdfunding"}]},{id:221,label:"Food & Drink",children:[{id:222,label:"Beverages",children:[{id:223,label:"Alcoholic Beverages"},{id:224,label:"Coffee & Tea"},{id:225,label:"Juice"},{id:226,label:"Soft Drinks"},{id:896,label:"Alcohol-Free Beverages"},{id:897,label:"Bottled Water"},{id:898,label:"Energy Drinks"},{id:899,label:"Nutrition Drinks & Shakes"},{id:900,label:"Sports Drinks"},{id:901,label:"Other"}]},{id:227,label:"Cooking & Recipes",children:[{id:228,label:"BBQ & Grilling"},{id:229,label:"Desserts"},{id:230,label:"Soups & Stews"},{id:902,label:"Cuisines"},{id:903,label:"Culinary Training"},{id:904,label:"Healthy Eating"},{id:905,label:"Salads"},{id:906,label:"Other"}]},{id:231,label:"Food",children:[{id:233,label:"Baked Goods"},{id:234,label:"Breakfast Foods"},{id:235,label:"Candy & Sweets"},{id:236,label:"Grains & Pasta"},{id:237,label:"Meat & Seafood"},{id:238,label:"Snack Foods"},{id:907,label:"Other"},{id:918,label:"Condiments & Dressings"},{id:919,label:"Cooking Fats & Oils"},{id:920,label:"Dairy & Egg Substitutes"},{id:921,label:"Dairy & Eggs"},{id:922,label:"Fruits & Vegetables"},{id:923,label:"Gourmet & Specialty Foods"},{id:924,label:"Herbs & Spices"},{id:925,label:"Jams, Jellies & Preserves"},{id:926,label:"Meat & Seafood Substitutes"},{id:927,label:"Organic & Natural Foods"}]},{id:232,label:"Food & Grocery Retailers",children:[{id:912,label:"Bakeries"},{id:913,label:"Butchers"},{id:914,label:"Convenience Stores"},{id:915,label:"Delicatessens"},{id:916,label:"Farmers' Markets"},{id:917,label:"Other"}]},{id:239,label:"Restaurants",children:[{id:240,label:"Fast Food"},{id:241,label:"Pizzerias"},{id:242,label:"Restaurant Reviews & Reservations"},{id:928,label:"Catering"},{id:929,label:"Fine Dining"},{id:930,label:"Other"}]},{id:895,label:"Other"},{id:908,label:"Grocery Delivery Services",children:[{id:909,label:"Meal Kits"},{id:910,label:"Restaurant Delivery Services"},{id:911,label:"Other"}]}]},{id:243,label:"Games",children:[{id:244,label:"Arcade & Coin-Op Games"},{id:245,label:"Board Games",children:[{id:246,label:"Chess & Abstract Strategy Games"},{id:247,label:"Miniatures & Wargaming"},{id:932,label:"Other"}]},{id:248,label:"Card Games",children:[{id:249,label:"Collectible Card Games"},{id:250,label:"Poker & Casino Games"},{id:933,label:"Other"}]},{id:251,label:"Computer & Video Games",children:[{id:252,label:"Casual Games"},{id:253,label:"Driving & Racing Games"},{id:254,label:"Fighting Games"},{id:255,label:"Music & Dance Games"},{id:256,label:"Sandbox Games"},{id:257,label:"Shooter Games"},{id:258,label:"Simulation Games"},{id:259,label:"Sports Games"},{id:260,label:"Strategy Games"},{id:261,label:"Video Game Emulation"},{id:934,label:"Action & Platform Games"},{id:935,label:"Adventure Games"},{id:936,label:"Browser Games"},{id:937,label:"Competitive Video Gaming"},{id:938,label:"Gaming Reference & Reviews"},{id:939,label:"Massively Multiplayer Games"},{id:940,label:"Video Game Development"},{id:941,label:"Video Game Mods & Add-Ons"},{id:942,label:"Video Game Retailers"},{id:943,label:"Other"}]},{id:262,label:"Family-Oriented Games & Activities",children:[{id:263,label:"Drawing & Coloring"},{id:264,label:"Dress-Up & Fashion Games"},{id:946,label:"Other"}]},{id:265,label:"Gambling",children:[{id:266,label:"Lottery"},{id:947,label:"Sports Betting"},{id:948,label:"Other"}]},{id:267,label:"Massively Multiplayer Games"},{id:268,label:"Puzzles & Brainteasers"},{id:269,label:"Roleplaying Games"},{id:270,label:"Table Games",children:[{id:271,label:"Billiards"},{id:950,label:"Table Tennis"},{id:951,label:"Other"}]},{id:272,label:"Word Games"},{id:931,label:"Other"},{id:944,label:"Dice Games"},{id:945,label:"Educational Games"},{id:949,label:"Party Games"},{id:952,label:"Tile Games"}]},{id:273,label:"Health",children:[{id:274,label:"Aging & Geriatrics",children:[{id:954,label:"Alzheimer's Disease"},{id:955,label:"Other"}]},{id:275,label:"Health Conditions",children:[{id:276,label:"AIDS & HIV"},{id:277,label:"Allergies"},{id:278,label:"Arthritis"},{id:279,label:"Cancer"},{id:280,label:"Diabetes"},{id:281,label:"Ear Nose & Throat"},{id:282,label:"Eating Disorders"},{id:283,label:"Endocrine Conditions"},{id:284,label:"Genetic Disorders"},{id:285,label:"Heart & Hypertension"},{id:286,label:"Infectious Diseases"},{id:287,label:"Neurological Conditions"},{id:288,label:"Obesity"},{id:289,label:"Pain Management"},{id:290,label:"Respiratory Conditions"},{id:291,label:"Skin Conditions"},{id:292,label:"Sleep Disorders"},{id:959,label:"Other"},{id:960,label:"Blood Sugar & Diabetes"},{id:961,label:"GERD & Digestive Disorders"},{id:962,label:"Injury"}]},{id:293,label:"Health Education & Medical Training"},{id:294,label:"Health Foundations & Medical Research"},{id:295,label:"Medical Devices & Equipment",children:[{id:963,label:"Assistive Technology"},{id:964,label:"Other"}]},{id:296,label:"Medical Facilities & Services",children:[{id:297,label:"Doctors' Offices"},{id:298,label:"Hospitals & Treatment Centers"},{id:299,label:"Medical Procedures"},{id:300,label:"Physical Therapy"},{id:965,label:"Other"}]},{id:301,label:"Men's Health"},{id:302,label:"Mental Health",children:[{id:303,label:"Anxiety & Stress"},{id:304,label:"Depression"},{id:968,label:"Compulsive Gambling"},{id:969,label:"Counseling Services"},{id:970,label:"Other"}]},{id:305,label:"Nursing",children:[{id:306,label:"Assisted Living & Long Term Care"},{id:971,label:"Other"}]},{id:307,label:"Nutrition",children:[{id:308,label:"Special & Restricted Diets"},{id:309,label:"Vitamins & Supplements"},{id:972,label:"Other"}]},{id:310,label:"Oral & Dental Care"},{id:311,label:"Pharmacy",children:[{id:312,label:"Drugs & Medications"},{id:974,label:"Other"}]},{id:313,label:"Public Health",children:[{id:314,label:"Occupational Health & Safety"},{id:975,label:"Health Policy"},{id:976,label:"Toxic Substances & Poisoning"},{id:977,label:"Other"}]},{id:315,label:"Reproductive Health",children:[{id:978,label:"Birth Control"},{id:979,label:"Infertility"},{id:980,label:"Male Impotence"},{id:981,label:"OBGYN"},{id:982,label:"Sex Education & Counseling"},{id:983,label:"Other"}]},{id:316,label:"Substance Abuse",children:[{id:317,label:"Drug & Alcohol Testing"},{id:318,label:"Drug & Alcohol Treatment"},{id:319,label:"Smoking & Smoking Cessation"},{id:320,label:"Steroids & Performance-Enhancing Drugs"},{id:984,label:"Other"}]},{id:321,label:"Vision Care",children:[{id:322,label:"Eyeglasses & Contacts"},{id:985,label:"Eye Exams & Optometry"},{id:986,label:"Laser Vision Correction"},{id:987,label:"Other"}]},{id:323,label:"Women's Health"},{id:953,label:"Other"},{id:956,label:"Acupuncture & Chinese Medicine",children:[{id:957,label:"Cleansing & Detoxification"},{id:958,label:"Other"}]},{id:966,label:"Medical Photos & Illustration",children:[{id:967,label:"Other"}]},{id:973,label:"Pediatrics"}]},{id:324,label:"Hobbies & Leisure",children:[{id:325,label:"Clubs & Organizations",children:[{id:326,label:"Youth Organizations & Resources"},{id:989,label:"Other"}]},{id:327,label:"Crafts",children:[{id:328,label:"Fiber & Textile Arts"},{id:990,label:"Art & Craft Supplies"},{id:991,label:"Ceramics & Pottery"},{id:992,label:"Other"}]},{id:329,label:"Merit Prizes & Contests"},{id:330,label:"Outdoors",children:[{id:331,label:"Fishing"},{id:332,label:"Hiking & Camping"},{id:993,label:"Hunting & Shooting"},{id:994,label:"Other"}]},{id:333,label:"Paintball"},{id:334,label:"Radio Control & Modeling",children:[{id:335,label:"Model Trains & Railroads"},{id:995,label:"Other"}]},{id:336,label:"Special Occasions",children:[{id:337,label:"Holidays & Seasonal Events"},{id:338,label:"Weddings"},{id:997,label:"Anniversaries"},{id:998,label:"Other"}]},{id:339,label:"Water Activities",children:[{id:340,label:"Boating"},{id:341,label:"Surf & Swim"},{id:1e3,label:"Diving & Underwater Activities"},{id:1001,label:"Other"}]},{id:988,label:"Other"},{id:996,label:"Recreational Aviation"},{id:999,label:"Sweepstakes & Promotional Giveaways"}]},{id:342,label:"Home & Garden",children:[{id:343,label:"Bed & Bath",children:[{id:344,label:"Bathroom"},{id:1003,label:"Bedroom"},{id:1004,label:"Other"}]},{id:345,label:"Domestic Services",children:[{id:346,label:"Cleaning Services"},{id:1005,label:"Other"}]},{id:347,label:"Gardening & Landscaping"},{id:348,label:"Home & Interior Decor"},{id:349,label:"Home Appliances",children:[{id:1006,label:"Vacuums & Floor Care"},{id:1007,label:"Water Filters & Purifiers"},{id:1008,label:"Other"}]},{id:350,label:"Home Furnishings",children:[{id:351,label:"Curtains & Window Treatments"},{id:352,label:"Kitchen & Dining Furniture"},{id:353,label:"Lamps & Lighting"},{id:354,label:"Living Room Furniture"},{id:355,label:"Rugs & Carpets"},{id:1009,label:"Clocks"},{id:1010,label:"Countertops"},{id:1011,label:"Outdoor Furniture"},{id:1012,label:"Other"}]},{id:356,label:"Home Improvement",children:[{id:357,label:"Construction & Power Tools"},{id:358,label:"Doors & Windows"},{id:359,label:"Flooring"},{id:360,label:"House Painting & Finishing"},{id:361,label:"Plumbing"},{id:1013,label:"Locks & Locksmiths"},{id:1014,label:"Roofing"},{id:1015,label:"Other"}]},{id:362,label:"Home Safety & Security",children:[{id:1016,label:"Home Alarm & Security Systems"},{id:1017,label:"Other"}]},{id:363,label:"Home Storage & Shelving",children:[{id:1018,label:"Cabinetry"},{id:1019,label:"Other"}]},{id:364,label:"Home Swimming Pools, Saunas & Spas"},{id:365,label:"HVAC & Climate Control",children:[{id:366,label:"Fireplaces & Stoves"},{id:1023,label:"Air Conditioners"},{id:1024,label:"Air Filters & Purifiers"},{id:1025,label:"Heaters"},{id:1026,label:"Household Fans"},{id:1027,label:"Other"}]},{id:367,label:"Kitchen & Dining",children:[{id:368,label:"Cookware & Diningware"},{id:369,label:"Major Kitchen Appliances"},{id:370,label:"Small Kitchen Appliances"},{id:1028,label:"Other"}]},{id:371,label:"Laundry",children:[{id:372,label:"Washers & Dryers"},{id:1029,label:"Other"}]},{id:373,label:"Nursery & Playroom"},{id:374,label:"Pest Control"},{id:375,label:"Yard & Patio",children:[{id:376,label:"Lawn Mowers"}]},{id:1002,label:"Other"},{id:1020,label:"Household Batteries",children:[{id:1021,label:"Household Cleaning Supplies"},{id:1022,label:"Other"}]},{id:1030,label:"Barbecues & Grills",children:[{id:1031,label:"Garden Structures"},{id:1032,label:"Gardening"},{id:1033,label:"Landscape Design"},{id:1034,label:"Other"}]}]},{id:377,label:"Internet & Telecom",children:[{id:378,label:"Communications Equipment",children:[{id:379,label:"Radio Equipment"},{id:1036,label:"Other"}]},{id:380,label:"Email & Messaging",children:[{id:381,label:"Text & Instant Messaging"},{id:382,label:"Voice & Video Chat"},{id:1037,label:"Electronic Spam"},{id:1038,label:"Email"},{id:1039,label:"Other"}]},{id:383,label:"Mobile & Wireless",children:[{id:384,label:"Mobile & Wireless Accessories"},{id:385,label:"Mobile Apps & Add-Ons"},{id:386,label:"Mobile Phones"},{id:1040,label:"Other"}]},{id:387,label:"Service Providers",children:[{id:388,label:"Cable & Satellite Providers"},{id:1043,label:"ISPs"},{id:1044,label:"Phone Service Providers"},{id:1045,label:"Other"}]},{id:389,label:"Web Services",children:[{id:390,label:"Affiliate Programs"},{id:391,label:"Web Design & Development"},{id:1047,label:"Cloud Storage"},{id:1048,label:"Search Engine Optimization & Marketing"},{id:1049,label:"Web Stats & Analytics"},{id:1050,label:"Other"}]},{id:1035,label:"Other"},{id:1041,label:"People Search",children:[{id:1042,label:"Other"}]},{id:1046,label:"Teleconferencing"}]},{id:392,label:"Jobs & Education",children:[{id:393,label:"Education",children:[{id:394,label:"Colleges & Universities"},{id:395,label:"Distance Learning"},{id:396,label:"Homeschooling"},{id:397,label:"Primary & Secondary Schooling (K-12)"},{id:398,label:"Standardized & Admissions Tests"},{id:399,label:"Teaching & Classroom Resources"},{id:400,label:"Training & Certification"},{id:401,label:"Vocational & Continuing Education"},{id:1052,label:"Academic Conferences & Publications"},{id:1053,label:"Alumni & Reunions"},{id:1054,label:"Computer Education"},{id:1055,label:"Early Childhood Education"},{id:1056,label:"Open Online Courses"},{id:1057,label:"Private Tutoring Services"},{id:1058,label:"Special Education"},{id:1059,label:"Study Abroad"},{id:1060,label:"Other"}]},{id:402,label:"Jobs",children:[{id:403,label:"Career Resources & Planning"},{id:404,label:"Job Listings"},{id:405,label:"Resumes & Portfolios"},{id:1062,label:"Other"}]},{id:1051,label:"Other"},{id:1061,label:"Internships"}]},{id:406,label:"Law & Government",children:[{id:407,label:"Government",children:[{id:408,label:"Courts & Judiciary"},{id:409,label:"Visa & Immigration"},{id:1064,label:"Embassies & Consulates"},{id:1065,label:"Executive Branch"},{id:1066,label:"Government Contracting & Procurement"},{id:1067,label:"Intelligence & Counterterrorism"},{id:1068,label:"Legislative Branch"},{id:1069,label:"Lobbying"},{id:1070,label:"Public Policy"},{id:1071,label:"Royalty"},{id:1072,label:"Other"}]},{id:410,label:"Legal",children:[{id:411,label:"Bankruptcy"},{id:412,label:"Legal Education"},{id:413,label:"Legal Services"},{id:1073,label:"Accident & Personal Injury Law"},{id:1074,label:"Business & Corporate Law"},{id:1075,label:"Constitutional Law & Civil Rights"},{id:1076,label:"Family Law"},{id:1077,label:"Intellectual Property"},{id:1078,label:"Labor & Employment Law"},{id:1079,label:"Product Liability"},{id:1080,label:"Real Estate Law"},{id:1081,label:"Other"}]},{id:414,label:"Military",children:[{id:1082,label:"Air Force"},{id:1083,label:"Army"},{id:1084,label:"Marines"},{id:1085,label:"Navy"},{id:1086,label:"Veterans"},{id:1087,label:"Other"}]},{id:415,label:"Public Safety",children:[{id:416,label:"Crime & Justice"},{id:417,label:"Emergency Services"},{id:418,label:"Law Enforcement"},{id:419,label:"Security Products & Services"},{id:1088,label:"Other"}]},{id:420,label:"Social Services",children:[{id:1089,label:"Welfare & Unemployment"},{id:1090,label:"Other"}]},{id:1063,label:"Other"}]},{id:421,label:"News",children:[{id:422,label:"Business News",children:[{id:423,label:"Company News"},{id:424,label:"Financial Markets News"},{id:1092,label:"Economy News"},{id:1093,label:"Fiscal Policy News"},{id:1094,label:"Other"}]},{id:425,label:"Scandals & Investigations"},{id:426,label:"Health News"},{id:427,label:"Politics",children:[{id:1097,label:"Campaigns & Elections"},{id:1098,label:"Media Critics & Watchdogs"},{id:1099,label:"Political Polls & Surveys"},{id:1100,label:"Other"}]},{id:428,label:"Sports News"},{id:429,label:"Weather"},{id:1091,label:"Other"},{id:1095,label:"Other"},{id:1096,label:"Local News"},{id:1101,label:"Technology News"},{id:1102,label:"World News"}]},{id:430,label:"Online Communities",children:[{id:431,label:"Blogging Resources & Services"},{id:432,label:"Dating & Personals",children:[{id:433,label:"Matrimonial Services"},{id:434,label:"Personals"},{id:435,label:"Photo Rating Sites"},{id:1104,label:"Other"}]},{id:436,label:"File Sharing & Hosting"},{id:437,label:"Online Goodies",children:[{id:438,label:"Clip Art & Animated GIFs"},{id:439,label:"Skins, Themes & Wallpapers"},{id:440,label:"Social Network Apps & Add-Ons"},{id:1105,label:"Other"}]},{id:441,label:"Photo & Video Sharing",children:[{id:442,label:"Photo & Image Sharing"},{id:1107,label:"Video Sharing"},{id:1108,label:"Other"}]},{id:443,label:"Social Networks"},{id:444,label:"Virtual Worlds"},{id:1103,label:"Other"},{id:1106,label:"Online Journals & Personal Sites"}]},{id:445,label:"People & Society",children:[{id:446,label:"Family & Relationships",children:[{id:447,label:"Family"},{id:448,label:"Marriage"},{id:449,label:"Troubled Relationships"},{id:1110,label:"Etiquette"},{id:1111,label:"Other"},{id:1112,label:"Romance"}]},{id:450,label:"Kids & Teens",children:[{id:451,label:"Children's Interests"},{id:452,label:"Teen Interests"},{id:1113,label:"Other"}]},{id:453,label:"Religion & Belief"},{id:454,label:"Seniors & Retirement"},{id:455,label:"Social Issues & Advocacy",children:[{id:456,label:"Charity & Philanthropy"},{id:457,label:"Discrimination & Identity Relations"},{id:458,label:"Green Living & Environmental Issues"},{id:459,label:"Human Rights & Liberties"},{id:460,label:"Poverty & Hunger"},{id:461,label:"Work & Labor Issues"},{id:1115,label:"Drug Laws & Policy"},{id:1116,label:"Ethics"},{id:1117,label:"Housing & Development"},{id:1118,label:"Other"}]},{id:462,label:"Social Sciences",children:[{id:463,label:"Economics"},{id:464,label:"Political Science"},{id:465,label:"Psychology"},{id:1119,label:"Anthropology"},{id:1120,label:"Archaeology"},{id:1121,label:"Communications & Media Studies"},{id:1122,label:"Demographics"},{id:1123,label:"Other"}]},{id:466,label:"Subcultures & Niche Interests"},{id:1109,label:"Other"},{id:1114,label:"Self-Help & Motivational"}]},{id:467,label:"Pets & Animals",children:[{id:468,label:"Pet Food & Supplies"},{id:469,label:"Veterinarians"},{id:470,label:"Pets",children:[{id:471,label:"Birds"},{id:472,label:"Cats"},{id:473,label:"Dogs"},{id:474,label:"Exotic Pets"},{id:475,label:"Fish & Aquaria"},{id:476,label:"Horses"},{id:477,label:"Rabbits & Rodents"},{id:478,label:"Reptiles & Amphibians"},{id:1128,label:"Other"}]},{id:479,label:"Wildlife"},{id:1124,label:"Other"},{id:1125,label:"Animal Welfare",children:[{id:1126,label:"Pet Food & Pet Care Supplies"},{id:1127,label:"Other"}]}]},{id:480,label:"Real Estate",children:[{id:481,label:"Real Estate Listings",children:[{id:482,label:"Bank-Owned & Foreclosed Properties"},{id:483,label:"Commercial Properties"},{id:484,label:"Lots & Land"},{id:485,label:"Residential Rentals"},{id:486,label:"Residential Sales"},{id:487,label:"Timeshares & Vacation Properties"},{id:1131,label:"Other"}]},{id:488,label:"Real Estate Services",children:[{id:1132,label:"Property Inspections & Appraisals"},{id:1133,label:"Property Management"},{id:1134,label:"Real Estate Agencies"},{id:1135,label:"Real Estate Title & Escrow"},{id:1136,label:"Other"}]},{id:1129,label:"Property Development"},{id:1130,label:"Other"}]},{id:489,label:"Reference",children:[{id:490,label:"Directories & Listings",children:[{id:491,label:"Business & Personal Listings"},{id:1138,label:"Other"}]},{id:492,label:"General Reference",children:[{id:493,label:"Biographies & Quotations"},{id:494,label:"Calculators & Reference Tools"},{id:495,label:"Dictionaries & Encyclopedias"},{id:496,label:"Forms Guides & Templates"},{id:497,label:"Public Records"},{id:498,label:"Time & Calendars"},{id:1139,label:"Educational Resources"},{id:1140,label:"How-To, DIY & Expert Content"},{id:1141,label:"Other"}]},{id:499,label:"Geographic Reference",children:[{id:500,label:"Maps"},{id:1142,label:"Other"}]},{id:501,label:"Humanities",children:[{id:502,label:"History"},{id:503,label:"Myth & Folklore"},{id:504,label:"Philosophy"},{id:1143,label:"Other"}]},{id:505,label:"Language Resources",children:[{id:506,label:"Foreign Language Resources"},{id:1144,label:"Other"}]},{id:507,label:"Libraries & Museums",children:[{id:508,label:"Museums"},{id:1145,label:"Libraries"},{id:1146,label:"Other"}]},{id:1137,label:"Other"},{id:1147,label:"Technical Reference"}]},{id:509,label:"Science",children:[{id:510,label:"Astronomy"},{id:511,label:"Biological Sciences",children:[{id:512,label:"Neuroscience"},{id:1149,label:"Genetics"},{id:1150,label:"Other"}]},{id:513,label:"Chemistry"},{id:514,label:"Computer Science",children:[{id:1151,label:"Machine Learning & Artificial Intelligence"},{id:1152,label:"Other"}]},{id:515,label:"Earth Sciences",children:[{id:516,label:"Atmospheric Science"},{id:517,label:"Geology"},{id:1153,label:"Paleontology"},{id:1154,label:"Other"}]},{id:518,label:"Ecology & Environment",children:[{id:519,label:"Climate Change & Global Warming"},{id:1155,label:"Other"}]},{id:520,label:"Engineering & Technology",children:[{id:521,label:"Robotics"},{id:1156,label:"Augmented & Virtual Reality"},{id:1157,label:"Other"}]},{id:522,label:"Mathematics",children:[{id:523,label:"Statistics"},{id:1158,label:"Other"}]},{id:524,label:"Physics"},{id:525,label:"Scientific Institutions"},{id:1148,label:"Other"},{id:1159,label:"Scientific Equipment"}]},{id:526,label:"Sensitive Subjects",children:[{id:1160,label:"Accidents & Disasters"},{id:1161,label:"Death & Tragedy"},{id:1162,label:"Firearms & Weapons"},{id:1163,label:"Recreational Drugs"},{id:1164,label:"Self-Harm"},{id:1165,label:"Violence & Abuse"},{id:1166,label:"War & Conflict"},{id:1167,label:"Other"}]},{id:527,label:"Shopping",children:[{id:528,label:"Antiques & Collectibles"},{id:529,label:"Apparel",children:[{id:530,label:"Athletic Apparel"},{id:531,label:"Casual Apparel"},{id:532,label:"Children's Clothing"},{id:533,label:"Clothing Accessories"},{id:534,label:"Costumes"},{id:535,label:"Eyewear"},{id:536,label:"Footwear"},{id:537,label:"Formal Wear"},{id:538,label:"Headwear"},{id:539,label:"Men's Clothing"},{id:540,label:"Swimwear"},{id:541,label:"Undergarments"},{id:542,label:"Women's Clothing"},{id:1169,label:"Apparel Services"},{id:1170,label:"Outerwear"},{id:1171,label:"Pants & Shorts"},{id:1172,label:"Shirts & Tops"},{id:1173,label:"Sleepwear"},{id:1174,label:"Suits & Business Attire"},{id:1175,label:"Uniforms & Workwear"},{id:1176,label:"Other"}]},{id:543,label:"Auctions"},{id:544,label:"Classifieds"},{id:545,label:"Consumer Resources",children:[{id:546,label:"Consumer Advocacy & Protection"},{id:547,label:"Coupons & Discount Offers"},{id:548,label:"Product Reviews & Price Comparisons"},{id:1177,label:"Customer Services"},{id:1178,label:"Identity Theft Protection"},{id:1179,label:"Other"}]},{id:549,label:"Entertainment Media",children:[{id:550,label:"Entertainment Media Rentals"},{id:1181,label:"Other"}]},{id:551,label:"Gifts & Special Event Items",children:[{id:552,label:"Cards & Greetings"},{id:553,label:"Flowers"},{id:554,label:"Gifts"},{id:1182,label:"Custom & Personalized Items"},{id:1183,label:"Greeting Cards"},{id:1184,label:"Party & Holiday Supplies"},{id:1185,label:"Other"}]},{id:555,label:"Luxury Goods"},{id:556,label:"Mass Merchants & Department Stores"},{id:557,label:"Photo & Video Services",children:[{id:1187,label:"Event & Studio Photography"},{id:1188,label:"Photo Printing Services"},{id:1189,label:"Stock Photography"},{id:1190,label:"Other"}]},{id:558,label:"Tobacco Products"},{id:559,label:"Toys",children:[{id:560,label:"Building Toys"},{id:561,label:"Die-cast & Toy Vehicles"},{id:562,label:"Dolls & Accessories"},{id:563,label:"Ride-On Toys & Wagons"},{id:564,label:"Stuffed Toys"},{id:1194,label:"Action Figures"},{id:1195,label:"Educational Toys"},{id:1196,label:"Outdoor Toys & Play Equipment"},{id:1197,label:"Puppets"},{id:1198,label:"Other"}]},{id:1168,label:"Other"},{id:1180,label:"Discount & Outlet Stores"},{id:1186,label:"Green & Eco-Friendly Shopping"},{id:1191,label:"Shopping Portals"},{id:1192,label:"Swap Meets & Outdoor Markets"},{id:1193,label:"Tobacco & Vaping Products"},{id:1199,label:"Wholesalers & Liquidators"}]},{id:565,label:"Sports",children:[{id:566,label:"Animal Sports",children:[{id:1201,label:"Equestrian"},{id:1202,label:"Other"}]},{id:567,label:"College Sports"},{id:568,label:"Combat Sports",children:[{id:569,label:"Boxing"},{id:570,label:"Martial Arts"},{id:571,label:"Wrestling"},{id:1203,label:"Fencing"},{id:1204,label:"Other"}]},{id:572,label:"Extreme Sports",children:[{id:573,label:"Drag & Street Racing"},{id:1205,label:"Climbing & Mountaineering"},{id:1206,label:"Stunts & Dangerous Feats"},{id:1207,label:"Other"}]},{id:574,label:"Fantasy Sports"},{id:575,label:"Individual Sports",children:[{id:576,label:"Cycling"},{id:577,label:"Golf"},{id:578,label:"Gymnastics"},{id:579,label:"Racquet Sports"},{id:580,label:"Skate Sports"},{id:581,label:"Track & Field"},{id:1208,label:"Bowling"},{id:1209,label:"Running & Walking"},{id:1210,label:"Other"}]},{id:582,label:"International Sports Competitions",children:[{id:583,label:"Olympics"},{id:1211,label:"Other"}]},{id:584,label:"Motor Sports",children:[{id:1212,label:"Auto Racing"},{id:1213,label:"Motorcycle Racing"},{id:1214,label:"Other"}]},{id:585,label:"Sporting Goods",children:[{id:586,label:"Sports Memorabilia"},{id:587,label:"Winter Sports Equipment"},{id:1216,label:"American Football Equipment"},{id:1217,label:"Baseball Equipment"},{id:1218,label:"Basketball Equipment"},{id:1219,label:"Bowling Equipment"},{id:1220,label:"Combat Sports Equipment"},{id:1221,label:"Cricket Equipment"},{id:1222,label:"Electric Skateboards & Scooters"},{id:1223,label:"Equestrian Equipment & Tack"},{id:1224,label:"Golf Equipment"},{id:1225,label:"Gymnastics Equipment"},{id:1226,label:"Hockey Equipment"},{id:1227,label:"Ice Skating Equipment"},{id:1228,label:"Roller Skating & Rollerblading Equipment"},{id:1229,label:"Skateboarding Equipment"},{id:1230,label:"Soccer Equipment"},{id:1231,label:"Squash & Racquetball Equipment"},{id:1232,label:"Table Tennis Equipment"},{id:1233,label:"Tennis Equipment"},{id:1234,label:"Volleyball Equipment"},{id:1235,label:"Water Sports Equipment"},{id:1236,label:"Other"}]},{id:588,label:"Sports Coaching & Training"},{id:589,label:"Team Sports",children:[{id:590,label:"American Football"},{id:591,label:"Australian Football"},{id:592,label:"Baseball"},{id:593,label:"Basketball"},{id:594,label:"Cheerleading"},{id:595,label:"Cricket"},{id:596,label:"Hockey"},{id:597,label:"Rugby"},{id:598,label:"Soccer"},{id:599,label:"Volleyball"},{id:1238,label:"Handball"},{id:1239,label:"Other"}]},{id:600,label:"Water Sports",children:[{id:601,label:"Surfing"},{id:602,label:"Swimming"},{id:1240,label:"Other"}]},{id:603,label:"Winter Sports",children:[{id:604,label:"Ice Skating"},{id:605,label:"Skiing & Snowboarding"},{id:1241,label:"Other"}]},{id:1200,label:"Other"},{id:1215,label:"Sport Scores & Statistics"},{id:1237,label:"Sports Fan Gear & Apparel"}]},{id:606,label:"Travel",children:[{id:607,label:"Air Travel",children:[{id:608,label:"Airport Parking & Transportation"}]},{id:609,label:"Bus & Rail"},{id:610,label:"Car Rental & Taxi Services"},{id:611,label:"Cruises & Charters"},{id:612,label:"Hotels & Accommodations",children:[{id:613,label:"Vacation Rentals & Short-Term Stays"}]},{id:614,label:"Specialty Travel"},{id:615,label:"Tourist Destinations",children:[{id:616,label:"Beaches & Islands"},{id:617,label:"Mountain & Ski Resorts"},{id:618,label:"Regional Parks & Gardens"},{id:619,label:"Theme Parks"},{id:620,label:"Zoos-Aquariums-Preserves"}]}]},{id:1242,label:"Other",children:[{id:1243,label:"Vacation Rentals & Short-Term Stays",children:[{id:1244,label:"Other"}]},{id:1245,label:"Backpacks & Utility Bags",children:[{id:1246,label:"Other"}]},{id:1247,label:"Adventure Travel",children:[{id:1248,label:"Agritourism"},{id:1249,label:"Business Travel"},{id:1250,label:"Ecotourism"},{id:1251,label:"Family Travel"},{id:1252,label:"Honeymoons & Romantic Getaways"},{id:1253,label:"Low Cost & Last Minute Travel"},{id:1254,label:"Luxury Travel"},{id:1255,label:"Medical Tourism"},{id:1256,label:"Religious Travel"},{id:1257,label:"Other"}]},{id:1258,label:"Beaches & Islands",children:[{id:1259,label:"Historical Sites & Buildings"},{id:1260,label:"Mountain & Ski Resorts"},{id:1261,label:"Regional Parks & Gardens"},{id:1262,label:"Theme Parks"},{id:1263,label:"Vineyards & Wine Tourism"},{id:1264,label:"Zoos, Aquariums & Preserves"},{id:1265,label:"Other"}]},{id:1266,label:"Air Travel",children:[{id:1267,label:"Car Rentals"},{id:1268,label:"Carpooling"},{id:1269,label:"Chartered Transportation Rentals"},{id:1270,label:"Cruises & Charters"},{id:1271,label:"Long Distance Bus & Rail"},{id:1272,label:"Other"},{id:1273,label:"Scooter & Bike Rentals"},{id:1274,label:"Taxi & Ride Hail Services"},{id:1275,label:"Traffic & Route Planners"},{id:1276,label:"Urban Transit"}]},{id:1277,label:"Guided Tours & Escorted Vacations",children:[{id:1278,label:"Sightseeing Tours"},{id:1279,label:"Vacation Offers"},{id:1280,label:"Other"}]},{id:1281,label:"Travel Guides & Travelogues"}]}];var ot=JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":2,"name":"humix/humix-block","version":"0.1.0","title":"Humix Block","category":"embed","icon":"humix-icon","description":"Humix Block for embedding videos","attributes":{"url":{"type":"string","default":""},"providerNameSlug":{"type":"string","default":""},"allowResponsive":{"type":"boolean","default":true},"responsive":{"type":"boolean","default":false},"previewable":{"type":"boolean","default":true},"floatOption":{"type":"number","default":1},"displayType":{"type":"string","default":"url"},"html":{"type":"string","default":""},"autoplay":{"type":"boolean","default":true},"loop":{"type":"boolean","default":false},"category":{"type":"string","default":""},"alignment":{"type":"string","default":"none"},"matchOption":{"type":"string","default":"MATCH_BY_TOPIC"},"matchCategories":{"type":"array","default":[]},"videoSourceOption":{"type":"string","default":"ANY_SOURCE"}},"supports":{"spacing":{"margin":true}},"textdomain":"humix-block","editorScript":"file:./index.js","editorStyle":"file:./index.css","style":"file:./style-index.css"}');const lt=()=>{const e={};for(const[t,r]of Object.entries(ot.attributes))r.hasOwnProperty("default")&&(e[t]=r.default);return e},at={...ot,edit:function(e){let{clientId:t,attributes:r,setAttributes:o}=e;const l="1",a="edit",s="preview",c="add_to_posts",d="MATCH_BY_TOPIC",h="MATCH_BY_CATEGORY",m=[{label:"Match video by page topic",value:d},{label:"Match video by category",value:h}],g="ANY_SOURCE",v="NETWORK_VIDEOS_SOURCE",O="MY_VIDEOS_SOURCE",w=[{label:"My videos & 3rd party network videos (recommended)",value:g},{label:"3rd party videos from Humix Network only",value:v},{label:"My videos only",value:O}],S={[`${g}-${d}`]:0,[`${g}-${h}`]:1,[`${v}-${d}`]:2,[`${v}-${h}`]:3,[`${O}-${d}`]:4,[`${O}-${h}`]:5},E="skip_if_video_exists",P="replace_all_videos",C=(0,p.useBlockEditContext)(),x=(0,f.select)("core/editor");let T=null;x&&(T=x.getCurrentPost());let k=0,j=0,_=0,R=0;const{url:A,floatOption:D,displayType:M,html:N,autoplay:B,loop:F,category:I,matchOption:L,matchCategories:H,videoSourceOption:V}=r,[U,G]=(0,i.useState)(A),[q,W]=(0,i.useState)(D),[z,$]=(0,i.useState)(M),[K,Y]=(0,i.useState)(N),[J,Q]=(0,i.useState)(B),[X,Z]=(0,i.useState)(F),[ee,te]=(0,i.useState)(I),[re,ne]=(0,i.useState)(l),[ie,oe]=(0,i.useState)(!1),[le,ae]=(0,i.useState)(!1),[se,ce]=(0,i.useState)(E),[de,ue]=(0,i.useState)(0),[pe,be]=(0,i.useState)(!1),[fe,he]=(0,i.useState)(L||d),[ye,me]=(0,i.useState)(H||[]),[ge,ve]=(0,i.useState)(V||g),[Oe,we]=(0,i.useState)(0),[Se,Ee]=(0,i.useState)(0),[Pe,Ce]=(0,i.useState)(0),[xe,Te]=(0,i.useState)(0),[ke,je]=(0,i.useState)(0),_e=()=>"auto"===z?L===d||ye&&ye.length>0&&ye.length<=3:Re(U),Re=e=>rt.test(e),[Ae,De]=(0,i.useState)(_e()?s:a),Me=e=>(e.forEach((e=>{e.checked=ye.includes(e.id),e.children&&(e.children=Me(e.children))})),e);(0,i.useEffect)((()=>{if(!x)return;let e=0;const r=x.getBlocks();r.forEach(((n,i)=>{"core/paragraph"===n.name&&e++,n.clientId===t&&(0===e?ne("0"):1===e?ne(l):2===e?ne("2"):i<r.length/2?ne("3"):ne("4"))}))}),[]),(0,i.useEffect)((()=>{o({url:U}),Re(U)&&Be()}),[U]),(0,i.useEffect)((()=>{o({floatOption:q}),_e()&&Be()}),[q]),(0,i.useEffect)((()=>{o({displayType:z}),"auto"===z&&G(""),Be()}),[z]),(0,i.useEffect)((()=>{o({html:K})}),[K]),(0,i.useEffect)((()=>{o({autoplay:J}),_e()&&Be()}),[J]),(0,i.useEffect)((()=>{o({loop:X}),_e()&&Be()}),[X]),(0,i.useEffect)((()=>{o({category:ee})}),[ee]),(0,i.useEffect)((()=>{o({matchCategories:ye.slice(0,3)}),_e()&&Be()}),[ye]),(0,i.useEffect)((()=>{o({matchOption:fe}),_e()&&Be()}),[fe]),(0,i.useEffect)((()=>{o({videoSourceOption:ge}),_e()&&Be()}),[ge]),(0,i.useEffect)((()=>{je(0!==Oe?Math.floor((de+Se+Pe+xe)/Oe*100):0)}),[de,Se,Pe,xe]);const Ne=function(){let{autoplay:e=!1,floatOption:t=!0,videoId:r="",autoMatch:n=!1,startTime:i=0,width:o=640,height:l=360,preview:a=!1,embedCodeSource:s="w"}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const c={auto_play:e,float:t,width:o,height:l,embed_code_source:s};if(r&&(c.videoId=r),n){c.auto_match=!0;const e=fe===h;let t=S[`${ge}-${fe}`];void 0===t&&(console.error("Unexpected source-match option combination"),t=e?1:0),c.auto_match_option=S[`${ge}-${fe}`],e&&(c.match_category_ids=ye.map((e=>parseInt(e))))}return i>0&&(c.time_start=i),a&&(c.preview=a),JSON.stringify(c)},Be=async()=>{let e="";if("auto"!==z&&!U)return;if("url"===z&&U&&U.includes("/playlist")){if(e=(e=>{let t=e,r=U.split("/");if(!r)return;if(r=r[r.length-1].split("?"),!r)return;const n=r[0],i=Ne({autoplay:!!J,floatOption:!!q,videoId:n});return i?t+i:void 0})(nt),!e)return}else if("url"===M&&U){if(e=(e=>{let t="https://humix.com/humix/oembed?url=";return t+=U,t+=`&float=${q}`,t+=`&autoplay=${J}`,t+=`&loop=${X}`,t})(),!e)return}else if(e=(e=>{let t=e;const r=Ne({autoplay:!!J,floatOption:!!q,autoMatch:!0});if(r)return t+r})(nt),!e)return;const t=await Qe({method:"get",url:e});if(t&&t.data){const e=t.data;e.html?Y(e.html):Y(e),e.provider_name?o({providerSlug:e.provider_name}):o({providerSlug:"Humix"})}},Fe=()=>{_e()&&De(s)},Ie=()=>{_e()&&De(c)},Le=function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];oe(!1),ae(!e),be(e),Fe(),setTimeout((()=>{ae(!1),be(!1),ue(0)}),15e3)},He=(e,t)=>{e.forEach((e=>{H.includes(e.id)&&t.push(e.label),e.children&&He(e.children,t)}))};return(0,i.createElement)("div",(0,p.useBlockProps)(),(0,i.createElement)(p.BlockControls,null,(0,i.createElement)(p.BlockAlignmentToolbar,{value:r.alignment,onChange:e=>{o({alignment:e})},controls:["left","center","right"]})),Ae===s&&""!=K&&(0,i.createElement)("div",{className:"preview-block"},(0,i.createElement)("div",{class:"preview-btn-group"},(0,i.createElement)("button",{onClick:()=>{De(a)},"aria-label":"Edit Video Settings",style:{marginRight:"15px"}},"Edit"),(0,i.createElement)("button",{onClick:Ie},"Add to Other Posts")),"auto"!==z&&(0,i.createElement)("iframe",{src:(()=>{const e=U.split("/");let t="https://humix.com/embed?contentId="+e[e.length-1].split("?")[0]+"&play_nextvid=0";return J||(t+="&autoplay=0"),X&&(t+="&loop=1"),t})()}),"auto"===z&&(0,i.createElement)("div",{className:"auto-select-preview"},(0,i.createElement)("h3",null,"Auto-Select Video"),(0,i.createElement)("p",null,(()=>{let e="Humix AI will choose an appropriate video to play ";if(ge!==g&&(e+=ge===v?"from the Humix Network ":"from your videos "),L===d)return e+="based on the contents of the page",e;const t=[];return He(it,t),0===t.length?"":(e+="that matches the ",1===t.length?e+`"${t[0]}" category`:2===t.length?e+`"${t[0]}" or "${t[1]}" categories`:e+`"${t[0]}", "${t[1]}", or "${t[2]}" categories`)})())),(le||pe)&&(0,i.createElement)("div",{class:"propagate-notice"},le&&(0,i.createElement)(b.Animate,{type:"slide-in",options:{origin:"top"}},(()=>(0,i.createElement)(b.Notice,{status:de>0?"success":"warning",isDismissible:!1},de>0&&(0,i.createElement)("p",null,(0,i.createElement)(b.Icon,{icon:"saved",className:"ezhx-success"}),"Humix video added to ",(0,i.createElement)("strong",null,de)," other post",1===de?"":"s","!"),0===de&&(0,i.createElement)("p",null,(0,i.createElement)(b.Icon,{icon:"warning",className:"ezhx-warning"}),"No Humix videos were added to other posts"),de!==Oe&&Oe>0&&(0,i.createElement)("ul",null,Se>0&&(0,i.createElement)("li",null,(0,i.createElement)("strong",null,Se)," post",1===Se?" was skipped because it already has":"s were skipped because they already have"," a Humix video"),Pe>0&&(0,i.createElement)("li",null,(0,i.createElement)("strong",null,Pe)," post",1===Pe?"":"s"," did not have an appropriate location to add the video to"),xe>0&&(0,i.createElement)("li",null,(0,i.createElement)("strong",null,xe)," post",1===xe?"":"s"," failed to update due to an internal error, please try again"))))),pe&&(0,i.createElement)(b.Animate,{type:"slide-in",options:{origin:"top"}},(()=>(0,i.createElement)(b.Notice,{status:"error",isDismissible:!1},(0,i.createElement)("p",null,(0,i.createElement)(b.Icon,{icon:"warning",className:"ezhx-error"}),"There was an error adding the Humix video to other pages")))))),Ae===a&&(0,i.createElement)("div",{className:"edit-block"},(0,i.createElement)("div",{style:{height:"35px",maxWidth:"150px",marginBottom:"20px"}},(0,i.createElement)("a",{href:"https://www.humix.com/",target:"_blank"},(0,i.createElement)("img",{src:Ze}))),(0,i.createElement)("div",{className:"humix-display-type-radio-group"},(0,i.createElement)(b.__experimentalRadioGroup,{checked:M,onChange:e=>{$(e)}},(0,i.createElement)(b.Tooltip,{text:"Let Humix AI choose an appropriate video"},(0,i.createElement)(b.__experimentalRadio,{value:"auto"},"Auto Select")),(0,i.createElement)(b.__experimentalRadio,{value:"url"},"Use Humix Link"))),(0,i.createElement)("div",{style:{marginBottom:"18px"}}),"url"===M&&(0,i.createElement)("div",null,(0,i.createElement)("p",{for:"humix-url-input",style:{fontSize:"small",marginBottom:"20px"}},"Please provide a link to the video or playlist you'd like to serve on your website. You can easily copy the links from either ",(0,i.createElement)("a",{href:"https://pubdash.ezoic.com/humix/studio/videos",target:"_blank"},"Humix Studio")," or ",(0,i.createElement)("a",{href:"https://www.humix.com",target:"_blank"},"Humix.com"),". For additional details, please refer to ",(0,i.createElement)("a",{href:"https://support.ezoic.com/scp/article.php?id=595",target:"_blank"},"this article"),"."),(0,i.createElement)(b.TextControl,{id:"humix-url-input",label:"Video or Playlist URL",value:U,placeholder:"Enter URL here",onChange:G})),"auto"===M&&(0,i.createElement)("div",null,(0,i.createElement)("p",null,"Video Match Settings"),(0,i.createElement)(b.RadioControl,{label:"Choose the source(s) that Humix can play videos from",onChange:ve,selected:ge,options:w}),(0,i.createElement)("div",{style:{marginTop:"15px"}},(0,i.createElement)(b.RadioControl,{label:"Choose how Humix selects a match for this video",onChange:he,selected:fe,options:m.map((e=>({...e,label:(0,i.createElement)(i.Fragment,null,e.label,e.value===d&&(0,i.createElement)(b.Tooltip,{text:"Humix will detect your page's content and find a relevant video that matches the page topic"},(0,i.createElement)(b.Icon,{icon:"info",style:{marginLeft:"4px"}})),e.value===h&&(0,i.createElement)(b.Tooltip,{text:"Humix will serve videos that match your chosen categories"},(0,i.createElement)(b.Icon,{icon:"info",style:{marginLeft:"4px"}})))})))})),fe===h&&(0,i.createElement)("div",{style:{marginTop:"15px"}},(0,i.createElement)("label",{for:"match-categories",class:"video-match-categories__label"},"Select up to 3 categories for video matching",ye.length>3&&(0,i.createElement)("span",{style:{color:"red"}}," (only 3 categories are allowed)")),(0,i.createElement)(u,{id:"match-categories",data:Me(tt()(it)),mode:"hierarchical",keepTreeOnSearch:!0,keepChildrenOnSearch:!0,keepOpenOnSelect:!0,texts:{placeholder:"Search..."},currentSelections:ye,onChange:(e,t)=>{me(t.map((e=>e.id)))}}))),(0,i.createElement)("div",{style:{marginBottom:"18px"}}),(0,i.createElement)("hr",null),(0,i.createElement)("p",null,"Video Playback Settings"),(0,i.createElement)(b.CheckboxControl,{label:"Float",style:{marginBottom:"8px"},checked:D,onChange:e=>{W(e)}}),(0,i.createElement)(b.CheckboxControl,{label:"Auto Play",checked:B,onChange:e=>{Q(e)}}),(0,i.createElement)(b.CheckboxControl,{label:"Loop",checked:F,onChange:e=>{Z(e)}}),T&&(0,i.createElement)("span",null),(0,i.createElement)("div",{class:"ezhx-btn-group"},(0,i.createElement)("button",{onClick:Fe,disabled:!_e()},"Done"),(0,i.createElement)("button",{onClick:Ie,disabled:!_e()},"Done & Add to Other Posts")),(0,i.createElement)("div",{class:"share-feedback-container"},(0,i.createElement)("a",{class:"share-feedback-text",onClick:e=>{e.preventDefault(),window.open("https://forms.gle/veiWWjFp1Bya8JEm8","_blank")}},"Share Feedback"))),(0,i.createElement)("div",{className:"edit-block",style:{display:Ae===c?"block":"none"}},(0,i.createElement)("div",{style:{height:"35px",maxWidth:"150px",marginBottom:"20px"}},(0,i.createElement)("a",{href:"https://www.humix.com/",target:"_blank"},(0,i.createElement)("img",{src:Ze}))),(0,i.createElement)("div",{style:{marginBottom:"15px"}},"Add this Humix Video to other posts in your site"),(0,i.createElement)("p",null,(0,i.createElement)(Xe,{disabled:ie,attributes:r,updateSelectedCategory:e=>{te(e)}})),(0,i.createElement)("p",null,(0,i.createElement)(b.SelectControl,{label:"Choose location in post to add this video:",disabled:ie,onChange:e=>{ne(e)},value:re,options:[{label:"Before 1st paragraph",value:"0"},{label:"Under 1st paragraph (recommended)",value:l},{label:"Under 2nd paragraph",value:"2"},{label:"Middle of page",value:"3"},{label:"Bottom of page",value:"4"}]})),(0,i.createElement)("p",null,(0,i.createElement)(b.RadioControl,{label:"If post already has one or more Humix Videos:",disabled:ie,onChange:e=>{ce(e)},selected:se,options:[{label:"Skip adding this video",value:E},{label:"Remove existing videos and add this one",value:P},{label:"Add this video without affecting other videos",value:"add_anyway"}]})),ie&&Oe>0&&(0,i.createElement)(b.Notice,{status:"info",isDismissible:!1,className:"ezhx-notice__loading"},(0,i.createElement)("p",null,(0,i.createElement)(b.Icon,{icon:"update",className:"ezhx-loading ezhx-info"}),(0,i.createElement)("span",null,"Adding video to ",(0,i.createElement)("strong",null,Oe)," posts... (",ke,"%)"))),(0,i.createElement)("div",{class:"ezhx-btn-group"},(0,i.createElement)("button",{disabled:ie,onClick:Fe,style:{backgroundColor:"white"}},"Cancel"),(0,i.createElement)("button",{disabled:ie,onClick:async()=>{if(!K)return;if(ie)return;k=0,j=0,_=0,R=0,Ce(0),Te(0),we(0),ue(0),Ee(0),oe(!0);let e="/wp/v2/posts?context=edit";parseInt(ee)>0&&(e+=`&categories=${ee}`);const t=await y()({path:e,method:"GET"}).catch((e=>{console.error(e),Le(!0)}));if(!Array.isArray(t))return void Le(!0);const i=T.id,o=t.filter((e=>e.id!==i));we(o.length);let a=o.map((e=>{let t=((e,t)=>{const r=e.some((e=>"humix/humix-block"===e.name||!("core/shortcode"!==e.name||"string"!=typeof e.originalContent||!e.originalContent.includes("[humix"))||!("string"!=typeof e.originalContent||!e.originalContent.includes('id="humix-'))));if(se===E&&r)return j++,Ee(j),!1;if(se===P&&r){let t=[];e.forEach((e=>{"humix/humix-block"!==e.name&&("core/shortcode"===e.name&&"string"==typeof e.originalContent&&e.originalContent.includes("[humix")||"string"==typeof e.originalContent&&e.originalContent.includes('id="humix-')||t.push(e))})),e=[...t]}switch(re){case"0":return e.unshift(t),e;case l:let r=[],n=0;return e.forEach((e=>{r.push(e),"core/paragraph"===e.name&&n++,1===n&&r.push(t)})),r.length===e.length?(_++,Ce(_),!1):r;case"2":let i=[],o=0;return e.forEach((e=>{i.push(e),"core/paragraph"===e.name&&o++,2===o&&i.push(t)})),i.length===e.length?(_++,Ce(_),!1):i;case"3":let a=Math.floor(e.length/2);return e.splice(a,0,t),e;case"4":return e.push(t),e;default:return e}})((0,n.parse)(e.content.raw),(0,n.createBlock)(C.name,r));if(!t)return Promise.resolve();const i=(0,n.serialize)(t);return y()({path:`/wp/v2/posts/${e.id}`,method:"POST",data:{content:i}}).then((()=>{k++,ue(k)})).catch((e=>{console.error(e),R++,Te(R)}))}));await Promise.all(a),Le()}},"Add to Posts"))))},save:function(e){let{attributes:t}=e;const r=p.useBlockProps.save(),{html:n,alignment:l}=t;let a={justifyContent:"center"};return"left"===l?a.justifyContent="flex-start":"right"===l&&(a.justifyContent="flex-end"),(0,i.createElement)("div",o({},r,{style:a}),(0,i.createElement)(i.RawHTML,null,n))},transforms:{from:[{type:"block",blocks:["core/embed"],isMatch(e){return rt.test(e.url)},transform(e){const t=lt();return t.url=e.url,t.displayType="url",(0,n.createBlock)("humix/humix-block",t)},priority:2},{type:"raw",isMatch:e=>"P"===e.nodeName&&rt.test(e.textContent),transform:e=>{const t=lt();return t.url=e.textContent.trim(),t.displayType="url",(0,n.createBlock)("humix/humix-block",t)},priority:1}]}};(0,n.registerBlockType)(ot.name,at)},8552:function(e,t,r){var n=r(852)(r(5639),"DataView");e.exports=n},1989:function(e,t,r){var n=r(1789),i=r(401),o=r(7667),l=r(1327),a=r(1866);function s(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}s.prototype.clear=n,s.prototype.delete=i,s.prototype.get=o,s.prototype.has=l,s.prototype.set=a,e.exports=s},8407:function(e,t,r){var n=r(7040),i=r(4125),o=r(2117),l=r(7518),a=r(4705);function s(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}s.prototype.clear=n,s.prototype.delete=i,s.prototype.get=o,s.prototype.has=l,s.prototype.set=a,e.exports=s},7071:function(e,t,r){var n=r(852)(r(5639),"Map");e.exports=n},3369:function(e,t,r){var n=r(4785),i=r(1285),o=r(6e3),l=r(9916),a=r(5265);function s(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}s.prototype.clear=n,s.prototype.delete=i,s.prototype.get=o,s.prototype.has=l,s.prototype.set=a,e.exports=s},3818:function(e,t,r){var n=r(852)(r(5639),"Promise");e.exports=n},8525:function(e,t,r){var n=r(852)(r(5639),"Set");e.exports=n},8668:function(e,t,r){var n=r(3369),i=r(619),o=r(2385);function l(e){var t=-1,r=null==e?0:e.length;for(this.__data__=new n;++t<r;)this.add(e[t])}l.prototype.add=l.prototype.push=i,l.prototype.has=o,e.exports=l},6384:function(e,t,r){var n=r(8407),i=r(7465),o=r(3779),l=r(7599),a=r(4758),s=r(4309);function c(e){var t=this.__data__=new n(e);this.size=t.size}c.prototype.clear=i,c.prototype.delete=o,c.prototype.get=l,c.prototype.has=a,c.prototype.set=s,e.exports=c},2705:function(e,t,r){var n=r(5639).Symbol;e.exports=n},1149:function(e,t,r){var n=r(5639).Uint8Array;e.exports=n},577:function(e,t,r){var n=r(852)(r(5639),"WeakMap");e.exports=n},7412:function(e){e.exports=function(e,t){for(var r=-1,n=null==e?0:e.length;++r<n&&!1!==t(e[r],r,e););return e}},4963:function(e){e.exports=function(e,t){for(var r=-1,n=null==e?0:e.length,i=0,o=[];++r<n;){var l=e[r];t(l,r,e)&&(o[i++]=l)}return o}},4636:function(e,t,r){var n=r(2545),i=r(5694),o=r(1469),l=r(4144),a=r(5776),s=r(6719),c=Object.prototype.hasOwnProperty;e.exports=function(e,t){var r=o(e),d=!r&&i(e),u=!r&&!d&&l(e),p=!r&&!d&&!u&&s(e),b=r||d||u||p,f=b?n(e.length,String):[],h=f.length;for(var y in e)!t&&!c.call(e,y)||b&&("length"==y||u&&("offset"==y||"parent"==y)||p&&("buffer"==y||"byteLength"==y||"byteOffset"==y)||a(y,h))||f.push(y);return f}},2488:function(e){e.exports=function(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}},2908:function(e){e.exports=function(e,t){for(var r=-1,n=null==e?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}},4865:function(e,t,r){var n=r(9465),i=r(7813),o=Object.prototype.hasOwnProperty;e.exports=function(e,t,r){var l=e[t];o.call(e,t)&&i(l,r)&&(void 0!==r||t in e)||n(e,t,r)}},8470:function(e,t,r){var n=r(7813);e.exports=function(e,t){for(var r=e.length;r--;)if(n(e[r][0],t))return r;return-1}},4037:function(e,t,r){var n=r(8363),i=r(3674);e.exports=function(e,t){return e&&n(t,i(t),e)}},3886:function(e,t,r){var n=r(8363),i=r(1704);e.exports=function(e,t){return e&&n(t,i(t),e)}},9465:function(e,t,r){var n=r(8777);e.exports=function(e,t,r){"__proto__"==t&&n?n(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}},5990:function(e,t,r){var n=r(6384),i=r(7412),o=r(4865),l=r(4037),a=r(3886),s=r(4626),c=r(278),d=r(8805),u=r(1911),p=r(8234),b=r(6904),f=r(4160),h=r(3824),y=r(9148),m=r(8517),g=r(1469),v=r(4144),O=r(6688),w=r(3218),S=r(2928),E=r(3674),P=r(1704),C="[object Arguments]",x="[object Function]",T="[object Object]",k={};k[C]=k["[object Array]"]=k["[object ArrayBuffer]"]=k["[object DataView]"]=k["[object Boolean]"]=k["[object Date]"]=k["[object Float32Array]"]=k["[object Float64Array]"]=k["[object Int8Array]"]=k["[object Int16Array]"]=k["[object Int32Array]"]=k["[object Map]"]=k["[object Number]"]=k[T]=k["[object RegExp]"]=k["[object Set]"]=k["[object String]"]=k["[object Symbol]"]=k["[object Uint8Array]"]=k["[object Uint8ClampedArray]"]=k["[object Uint16Array]"]=k["[object Uint32Array]"]=!0,k["[object Error]"]=k[x]=k["[object WeakMap]"]=!1,e.exports=function e(t,r,j,_,R,A){var D,M=1&r,N=2&r,B=4&r;if(j&&(D=R?j(t,_,R,A):j(t)),void 0!==D)return D;if(!w(t))return t;var F=g(t);if(F){if(D=h(t),!M)return c(t,D)}else{var I=f(t),L=I==x||"[object GeneratorFunction]"==I;if(v(t))return s(t,M);if(I==T||I==C||L&&!R){if(D=N||L?{}:m(t),!M)return N?u(t,a(D,t)):d(t,l(D,t))}else{if(!k[I])return R?t:{};D=y(t,I,M)}}A||(A=new n);var H=A.get(t);if(H)return H;A.set(t,D),S(t)?t.forEach((function(n){D.add(e(n,r,j,n,t,A))})):O(t)&&t.forEach((function(n,i){D.set(i,e(n,r,j,i,t,A))}));var V=F?void 0:(B?N?b:p:N?P:E)(t);return i(V||t,(function(n,i){V&&(n=t[i=n]),o(D,i,e(n,r,j,i,t,A))})),D}},3118:function(e,t,r){var n=r(3218),i=Object.create,o=function(){function e(){}return function(t){if(!n(t))return{};if(i)return i(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();e.exports=o},8866:function(e,t,r){var n=r(2488),i=r(1469);e.exports=function(e,t,r){var o=t(e);return i(e)?o:n(o,r(e))}},4239:function(e,t,r){var n=r(2705),i=r(9607),o=r(2333),l=n?n.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":l&&l in Object(e)?i(e):o(e)}},9454:function(e,t,r){var n=r(4239),i=r(7005);e.exports=function(e){return i(e)&&"[object Arguments]"==n(e)}},939:function(e,t,r){var n=r(2492),i=r(7005);e.exports=function e(t,r,o,l,a){return t===r||(null==t||null==r||!i(t)&&!i(r)?t!=t&&r!=r:n(t,r,o,l,e,a))}},2492:function(e,t,r){var n=r(6384),i=r(7114),o=r(8351),l=r(6096),a=r(4160),s=r(1469),c=r(4144),d=r(6719),u="[object Arguments]",p="[object Array]",b="[object Object]",f=Object.prototype.hasOwnProperty;e.exports=function(e,t,r,h,y,m){var g=s(e),v=s(t),O=g?p:a(e),w=v?p:a(t),S=(O=O==u?b:O)==b,E=(w=w==u?b:w)==b,P=O==w;if(P&&c(e)){if(!c(t))return!1;g=!0,S=!1}if(P&&!S)return m||(m=new n),g||d(e)?i(e,t,r,h,y,m):o(e,t,O,r,h,y,m);if(!(1&r)){var C=S&&f.call(e,"__wrapped__"),x=E&&f.call(t,"__wrapped__");if(C||x){var T=C?e.value():e,k=x?t.value():t;return m||(m=new n),y(T,k,r,h,m)}}return!!P&&(m||(m=new n),l(e,t,r,h,y,m))}},5588:function(e,t,r){var n=r(4160),i=r(7005);e.exports=function(e){return i(e)&&"[object Map]"==n(e)}},8458:function(e,t,r){var n=r(3560),i=r(5346),o=r(3218),l=r(346),a=/^\[object .+?Constructor\]$/,s=Function.prototype,c=Object.prototype,d=s.toString,u=c.hasOwnProperty,p=RegExp("^"+d.call(u).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!o(e)||i(e))&&(n(e)?p:a).test(l(e))}},9221:function(e,t,r){var n=r(4160),i=r(7005);e.exports=function(e){return i(e)&&"[object Set]"==n(e)}},8749:function(e,t,r){var n=r(4239),i=r(1780),o=r(7005),l={};l["[object Float32Array]"]=l["[object Float64Array]"]=l["[object Int8Array]"]=l["[object Int16Array]"]=l["[object Int32Array]"]=l["[object Uint8Array]"]=l["[object Uint8ClampedArray]"]=l["[object Uint16Array]"]=l["[object Uint32Array]"]=!0,l["[object Arguments]"]=l["[object Array]"]=l["[object ArrayBuffer]"]=l["[object Boolean]"]=l["[object DataView]"]=l["[object Date]"]=l["[object Error]"]=l["[object Function]"]=l["[object Map]"]=l["[object Number]"]=l["[object Object]"]=l["[object RegExp]"]=l["[object Set]"]=l["[object String]"]=l["[object WeakMap]"]=!1,e.exports=function(e){return o(e)&&i(e.length)&&!!l[n(e)]}},280:function(e,t,r){var n=r(5726),i=r(6916),o=Object.prototype.hasOwnProperty;e.exports=function(e){if(!n(e))return i(e);var t=[];for(var r in Object(e))o.call(e,r)&&"constructor"!=r&&t.push(r);return t}},313:function(e,t,r){var n=r(3218),i=r(5726),o=r(3498),l=Object.prototype.hasOwnProperty;e.exports=function(e){if(!n(e))return o(e);var t=i(e),r=[];for(var a in e)("constructor"!=a||!t&&l.call(e,a))&&r.push(a);return r}},2545:function(e){e.exports=function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}},1717:function(e){e.exports=function(e){return function(t){return e(t)}}},4757:function(e){e.exports=function(e,t){return e.has(t)}},4318:function(e,t,r){var n=r(1149);e.exports=function(e){var t=new e.constructor(e.byteLength);return new n(t).set(new n(e)),t}},4626:function(e,t,r){e=r.nmd(e);var n=r(5639),i=t&&!t.nodeType&&t,o=i&&e&&!e.nodeType&&e,l=o&&o.exports===i?n.Buffer:void 0,a=l?l.allocUnsafe:void 0;e.exports=function(e,t){if(t)return e.slice();var r=e.length,n=a?a(r):new e.constructor(r);return e.copy(n),n}},7157:function(e,t,r){var n=r(4318);e.exports=function(e,t){var r=t?n(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}},3147:function(e){var t=/\w*$/;e.exports=function(e){var r=new e.constructor(e.source,t.exec(e));return r.lastIndex=e.lastIndex,r}},419:function(e,t,r){var n=r(2705),i=n?n.prototype:void 0,o=i?i.valueOf:void 0;e.exports=function(e){return o?Object(o.call(e)):{}}},7133:function(e,t,r){var n=r(4318);e.exports=function(e,t){var r=t?n(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}},278:function(e){e.exports=function(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}},8363:function(e,t,r){var n=r(4865),i=r(9465);e.exports=function(e,t,r,o){var l=!r;r||(r={});for(var a=-1,s=t.length;++a<s;){var c=t[a],d=o?o(r[c],e[c],c,r,e):void 0;void 0===d&&(d=e[c]),l?i(r,c,d):n(r,c,d)}return r}},8805:function(e,t,r){var n=r(8363),i=r(9551);e.exports=function(e,t){return n(e,i(e),t)}},1911:function(e,t,r){var n=r(8363),i=r(1442);e.exports=function(e,t){return n(e,i(e),t)}},4429:function(e,t,r){var n=r(5639)["__core-js_shared__"];e.exports=n},8777:function(e,t,r){var n=r(852),i=function(){try{var e=n(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();e.exports=i},7114:function(e,t,r){var n=r(8668),i=r(2908),o=r(4757);e.exports=function(e,t,r,l,a,s){var c=1&r,d=e.length,u=t.length;if(d!=u&&!(c&&u>d))return!1;var p=s.get(e),b=s.get(t);if(p&&b)return p==t&&b==e;var f=-1,h=!0,y=2&r?new n:void 0;for(s.set(e,t),s.set(t,e);++f<d;){var m=e[f],g=t[f];if(l)var v=c?l(g,m,f,t,e,s):l(m,g,f,e,t,s);if(void 0!==v){if(v)continue;h=!1;break}if(y){if(!i(t,(function(e,t){if(!o(y,t)&&(m===e||a(m,e,r,l,s)))return y.push(t)}))){h=!1;break}}else if(m!==g&&!a(m,g,r,l,s)){h=!1;break}}return s.delete(e),s.delete(t),h}},8351:function(e,t,r){var n=r(2705),i=r(1149),o=r(7813),l=r(7114),a=r(8776),s=r(1814),c=n?n.prototype:void 0,d=c?c.valueOf:void 0;e.exports=function(e,t,r,n,c,u,p){switch(r){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!u(new i(e),new i(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return o(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var b=a;case"[object Set]":var f=1&n;if(b||(b=s),e.size!=t.size&&!f)return!1;var h=p.get(e);if(h)return h==t;n|=2,p.set(e,t);var y=l(b(e),b(t),n,c,u,p);return p.delete(e),y;case"[object Symbol]":if(d)return d.call(e)==d.call(t)}return!1}},6096:function(e,t,r){var n=r(8234),i=Object.prototype.hasOwnProperty;e.exports=function(e,t,r,o,l,a){var s=1&r,c=n(e),d=c.length;if(d!=n(t).length&&!s)return!1;for(var u=d;u--;){var p=c[u];if(!(s?p in t:i.call(t,p)))return!1}var b=a.get(e),f=a.get(t);if(b&&f)return b==t&&f==e;var h=!0;a.set(e,t),a.set(t,e);for(var y=s;++u<d;){var m=e[p=c[u]],g=t[p];if(o)var v=s?o(g,m,p,t,e,a):o(m,g,p,e,t,a);if(!(void 0===v?m===g||l(m,g,r,o,a):v)){h=!1;break}y||(y="constructor"==p)}if(h&&!y){var O=e.constructor,w=t.constructor;O==w||!("constructor"in e)||!("constructor"in t)||"function"==typeof O&&O instanceof O&&"function"==typeof w&&w instanceof w||(h=!1)}return a.delete(e),a.delete(t),h}},1957:function(e,t,r){var n="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g;e.exports=n},8234:function(e,t,r){var n=r(8866),i=r(9551),o=r(3674);e.exports=function(e){return n(e,o,i)}},6904:function(e,t,r){var n=r(8866),i=r(1442),o=r(1704);e.exports=function(e){return n(e,o,i)}},5050:function(e,t,r){var n=r(7019);e.exports=function(e,t){var r=e.__data__;return n(t)?r["string"==typeof t?"string":"hash"]:r.map}},852:function(e,t,r){var n=r(8458),i=r(7801);e.exports=function(e,t){var r=i(e,t);return n(r)?r:void 0}},5924:function(e,t,r){var n=r(5569)(Object.getPrototypeOf,Object);e.exports=n},9607:function(e,t,r){var n=r(2705),i=Object.prototype,o=i.hasOwnProperty,l=i.toString,a=n?n.toStringTag:void 0;e.exports=function(e){var t=o.call(e,a),r=e[a];try{e[a]=void 0;var n=!0}catch(e){}var i=l.call(e);return n&&(t?e[a]=r:delete e[a]),i}},9551:function(e,t,r){var n=r(4963),i=r(479),o=Object.prototype.propertyIsEnumerable,l=Object.getOwnPropertySymbols,a=l?function(e){return null==e?[]:(e=Object(e),n(l(e),(function(t){return o.call(e,t)})))}:i;e.exports=a},1442:function(e,t,r){var n=r(2488),i=r(5924),o=r(9551),l=r(479),a=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)n(t,o(e)),e=i(e);return t}:l;e.exports=a},4160:function(e,t,r){var n=r(8552),i=r(7071),o=r(3818),l=r(8525),a=r(577),s=r(4239),c=r(346),d="[object Map]",u="[object Promise]",p="[object Set]",b="[object WeakMap]",f="[object DataView]",h=c(n),y=c(i),m=c(o),g=c(l),v=c(a),O=s;(n&&O(new n(new ArrayBuffer(1)))!=f||i&&O(new i)!=d||o&&O(o.resolve())!=u||l&&O(new l)!=p||a&&O(new a)!=b)&&(O=function(e){var t=s(e),r="[object Object]"==t?e.constructor:void 0,n=r?c(r):"";if(n)switch(n){case h:return f;case y:return d;case m:return u;case g:return p;case v:return b}return t}),e.exports=O},7801:function(e){e.exports=function(e,t){return null==e?void 0:e[t]}},1789:function(e,t,r){var n=r(4536);e.exports=function(){this.__data__=n?n(null):{},this.size=0}},401:function(e){e.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}},7667:function(e,t,r){var n=r(4536),i=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;if(n){var r=t[e];return"__lodash_hash_undefined__"===r?void 0:r}return i.call(t,e)?t[e]:void 0}},1327:function(e,t,r){var n=r(4536),i=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;return n?void 0!==t[e]:i.call(t,e)}},1866:function(e,t,r){var n=r(4536);e.exports=function(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=n&&void 0===t?"__lodash_hash_undefined__":t,this}},3824:function(e){var t=Object.prototype.hasOwnProperty;e.exports=function(e){var r=e.length,n=new e.constructor(r);return r&&"string"==typeof e[0]&&t.call(e,"index")&&(n.index=e.index,n.input=e.input),n}},9148:function(e,t,r){var n=r(4318),i=r(7157),o=r(3147),l=r(419),a=r(7133);e.exports=function(e,t,r){var s=e.constructor;switch(t){case"[object ArrayBuffer]":return n(e);case"[object Boolean]":case"[object Date]":return new s(+e);case"[object DataView]":return i(e,r);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return a(e,r);case"[object Map]":case"[object Set]":return new s;case"[object Number]":case"[object String]":return new s(e);case"[object RegExp]":return o(e);case"[object Symbol]":return l(e)}}},8517:function(e,t,r){var n=r(3118),i=r(5924),o=r(5726);e.exports=function(e){return"function"!=typeof e.constructor||o(e)?{}:n(i(e))}},5776:function(e){var t=/^(?:0|[1-9]\d*)$/;e.exports=function(e,r){var n=typeof e;return!!(r=null==r?9007199254740991:r)&&("number"==n||"symbol"!=n&&t.test(e))&&e>-1&&e%1==0&&e<r}},7019:function(e){e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},5346:function(e,t,r){var n,i=r(4429),o=(n=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"";e.exports=function(e){return!!o&&o in e}},5726:function(e){var t=Object.prototype;e.exports=function(e){var r=e&&e.constructor;return e===("function"==typeof r&&r.prototype||t)}},7040:function(e){e.exports=function(){this.__data__=[],this.size=0}},4125:function(e,t,r){var n=r(8470),i=Array.prototype.splice;e.exports=function(e){var t=this.__data__,r=n(t,e);return!(r<0||(r==t.length-1?t.pop():i.call(t,r,1),--this.size,0))}},2117:function(e,t,r){var n=r(8470);e.exports=function(e){var t=this.__data__,r=n(t,e);return r<0?void 0:t[r][1]}},7518:function(e,t,r){var n=r(8470);e.exports=function(e){return n(this.__data__,e)>-1}},4705:function(e,t,r){var n=r(8470);e.exports=function(e,t){var r=this.__data__,i=n(r,e);return i<0?(++this.size,r.push([e,t])):r[i][1]=t,this}},4785:function(e,t,r){var n=r(1989),i=r(8407),o=r(7071);e.exports=function(){this.size=0,this.__data__={hash:new n,map:new(o||i),string:new n}}},1285:function(e,t,r){var n=r(5050);e.exports=function(e){var t=n(this,e).delete(e);return this.size-=t?1:0,t}},6e3:function(e,t,r){var n=r(5050);e.exports=function(e){return n(this,e).get(e)}},9916:function(e,t,r){var n=r(5050);e.exports=function(e){return n(this,e).has(e)}},5265:function(e,t,r){var n=r(5050);e.exports=function(e,t){var r=n(this,e),i=r.size;return r.set(e,t),this.size+=r.size==i?0:1,this}},8776:function(e){e.exports=function(e){var t=-1,r=Array(e.size);return e.forEach((function(e,n){r[++t]=[n,e]})),r}},4536:function(e,t,r){var n=r(852)(Object,"create");e.exports=n},6916:function(e,t,r){var n=r(5569)(Object.keys,Object);e.exports=n},3498:function(e){e.exports=function(e){var t=[];if(null!=e)for(var r in Object(e))t.push(r);return t}},1167:function(e,t,r){e=r.nmd(e);var n=r(1957),i=t&&!t.nodeType&&t,o=i&&e&&!e.nodeType&&e,l=o&&o.exports===i&&n.process,a=function(){try{return o&&o.require&&o.require("util").types||l&&l.binding&&l.binding("util")}catch(e){}}();e.exports=a},2333:function(e){var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},5569:function(e){e.exports=function(e,t){return function(r){return e(t(r))}}},5639:function(e,t,r){var n=r(1957),i="object"==typeof self&&self&&self.Object===Object&&self,o=n||i||Function("return this")();e.exports=o},619:function(e){e.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}},2385:function(e){e.exports=function(e){return this.__data__.has(e)}},1814:function(e){e.exports=function(e){var t=-1,r=Array(e.size);return e.forEach((function(e){r[++t]=e})),r}},7465:function(e,t,r){var n=r(8407);e.exports=function(){this.__data__=new n,this.size=0}},3779:function(e){e.exports=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}},7599:function(e){e.exports=function(e){return this.__data__.get(e)}},4758:function(e){e.exports=function(e){return this.__data__.has(e)}},4309:function(e,t,r){var n=r(8407),i=r(7071),o=r(3369);e.exports=function(e,t){var r=this.__data__;if(r instanceof n){var l=r.__data__;if(!i||l.length<199)return l.push([e,t]),this.size=++r.size,this;r=this.__data__=new o(l)}return r.set(e,t),this.size=r.size,this}},346:function(e){var t=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return t.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},361:function(e,t,r){var n=r(5990);e.exports=function(e){return n(e,5)}},7813:function(e){e.exports=function(e,t){return e===t||e!=e&&t!=t}},5694:function(e,t,r){var n=r(9454),i=r(7005),o=Object.prototype,l=o.hasOwnProperty,a=o.propertyIsEnumerable,s=n(function(){return arguments}())?n:function(e){return i(e)&&l.call(e,"callee")&&!a.call(e,"callee")};e.exports=s},1469:function(e){var t=Array.isArray;e.exports=t},8612:function(e,t,r){var n=r(3560),i=r(1780);e.exports=function(e){return null!=e&&i(e.length)&&!n(e)}},4144:function(e,t,r){e=r.nmd(e);var n=r(5639),i=r(5062),o=t&&!t.nodeType&&t,l=o&&e&&!e.nodeType&&e,a=l&&l.exports===o?n.Buffer:void 0,s=(a?a.isBuffer:void 0)||i;e.exports=s},8446:function(e,t,r){var n=r(939);e.exports=function(e,t){return n(e,t)}},3560:function(e,t,r){var n=r(4239),i=r(3218);e.exports=function(e){if(!i(e))return!1;var t=n(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},1780:function(e){e.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}},6688:function(e,t,r){var n=r(5588),i=r(1717),o=r(1167),l=o&&o.isMap,a=l?i(l):n;e.exports=a},3218:function(e){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},7005:function(e){e.exports=function(e){return null!=e&&"object"==typeof e}},2928:function(e,t,r){var n=r(9221),i=r(1717),o=r(1167),l=o&&o.isSet,a=l?i(l):n;e.exports=a},6719:function(e,t,r){var n=r(8749),i=r(1717),o=r(1167),l=o&&o.isTypedArray,a=l?i(l):n;e.exports=a},3674:function(e,t,r){var n=r(4636),i=r(280),o=r(8612);e.exports=function(e){return o(e)?n(e):i(e)}},1704:function(e,t,r){var n=r(4636),i=r(313),o=r(8612);e.exports=function(e){return o(e)?n(e,!0):i(e)}},479:function(e){e.exports=function(){return[]}},5062:function(e){e.exports=function(){return!1}},1038:function(e,t,r){var n;n=e=>(()=>{var t={865:e=>{"use strict";e.exports=function(e,t){var r=e.filter(t);return 0!==r.length&&r.length!==e.length}},703:(e,t,r)=>{"use strict";var n=r(414);function i(){}function o(){}o.resetWarningCache=i,e.exports=function(){function e(e,t,r,i,o,l){if(l!==n){var a=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw a.name="Invariant Violation",a}}function t(){return e}e.isRequired=e;var r={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:i};return r.PropTypes=r,r}},697:(e,t,r)=>{e.exports=r(703)()},414:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},385:function(e,t,r){var n;n=function(e){return function(e){var t={};function r(n){if(t[n])return t[n].exports;var i=t[n]={exports:{},id:n,loaded:!1};return e[n].call(i.exports,i,i.exports,r),i.loaded=!0,i.exports}return r.m=e,r.c=t,r.p="",r(0)}([function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}();function o(e){return e&&e.__esModule?e:{default:e}}var l=r(8),a=o(l),s=o(r(6)),c=o(r(2)),d=r(1),u=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t,r){for(var n=!0;n;){var i=e,o=t,l=r;n=!1,null===i&&(i=Function.prototype);var a=Object.getOwnPropertyDescriptor(i,o);if(void 0!==a){if("value"in a)return a.value;var s=a.get;if(void 0===s)return;return s.call(l)}var c=Object.getPrototypeOf(i);if(null===c)return;e=c,t=o,r=l,n=!0,a=c=void 0}}(Object.getPrototypeOf(t.prototype),"constructor",this).call(this),this.state={showLoader:!1,lastScrollTop:0,actionTriggered:!1,pullToRefreshThresholdBreached:!1},this.startY=0,this.currentY=0,this.dragging=!1,this.maxPullDownDistance=0,this.onScrollListener=this.onScrollListener.bind(this),this.throttledOnScrollListener=(0,c.default)(this.onScrollListener,150).bind(this),this.onStart=this.onStart.bind(this),this.onMove=this.onMove.bind(this),this.onEnd=this.onEnd.bind(this),this.getScrollableTarget=this.getScrollableTarget.bind(this)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"componentDidMount",value:function(){if(this._scrollableNode=this.getScrollableTarget(),this.el=this.props.height?this._infScroll:this._scrollableNode||window,this.el.addEventListener("scroll",this.throttledOnScrollListener),"number"==typeof this.props.initialScrollY&&this.el.scrollHeight>this.props.initialScrollY&&this.el.scrollTo(0,this.props.initialScrollY),this.props.pullDownToRefresh&&(this.el.addEventListener("touchstart",this.onStart),this.el.addEventListener("touchmove",this.onMove),this.el.addEventListener("touchend",this.onEnd),this.el.addEventListener("mousedown",this.onStart),this.el.addEventListener("mousemove",this.onMove),this.el.addEventListener("mouseup",this.onEnd),this.maxPullDownDistance=this._pullDown.firstChild.getBoundingClientRect().height,this.forceUpdate(),"function"!=typeof this.props.refreshFunction))throw new Error('Mandatory prop "refreshFunction" missing.\n Pull Down To Refresh functionality will not work\n as expected. Check README.md for usage\'')}},{key:"componentWillUnmount",value:function(){this.el.removeEventListener("scroll",this.throttledOnScrollListener),this.props.pullDownToRefresh&&(this.el.removeEventListener("touchstart",this.onStart),this.el.removeEventListener("touchmove",this.onMove),this.el.removeEventListener("touchend",this.onEnd),this.el.removeEventListener("mousedown",this.onStart),this.el.removeEventListener("mousemove",this.onMove),this.el.removeEventListener("mouseup",this.onEnd))}},{key:"componentWillReceiveProps",value:function(e){this.props.key===e.key&&this.props.dataLength===e.dataLength||this.setState({showLoader:!1,actionTriggered:!1,pullToRefreshThresholdBreached:!1})}},{key:"getScrollableTarget",value:function(){return this.props.scrollableTarget instanceof HTMLElement?this.props.scrollableTarget:"string"==typeof this.props.scrollableTarget?document.getElementById(this.props.scrollableTarget):(null===this.props.scrollableTarget&&console.warn("You are trying to pass scrollableTarget but it is null. This might\n happen because the element may not have been added to DOM yet.\n See https://github.com/ankeetmaini/react-infinite-scroll-component/issues/59 for more info.\n "),null)}},{key:"onStart",value:function(e){this.state.lastScrollTop||(this.dragging=!0,this.startY=e.pageY||e.touches[0].pageY,this.currentY=this.startY,this._infScroll.style.willChange="transform",this._infScroll.style.transition="transform 0.2s cubic-bezier(0,0,0.31,1)")}},{key:"onMove",value:function(e){this.dragging&&(this.currentY=e.pageY||e.touches[0].pageY,this.currentY<this.startY||(this.currentY-this.startY>=this.props.pullDownToRefreshThreshold&&this.setState({pullToRefreshThresholdBreached:!0}),this.currentY-this.startY>1.5*this.maxPullDownDistance||(this._infScroll.style.overflow="visible",this._infScroll.style.transform="translate3d(0px, "+(this.currentY-this.startY)+"px, 0px)")))}},{key:"onEnd",value:function(e){var t=this;this.startY=0,this.currentY=0,this.dragging=!1,this.state.pullToRefreshThresholdBreached&&this.props.refreshFunction&&this.props.refreshFunction(),requestAnimationFrame((function(){t._infScroll&&(t._infScroll.style.overflow="auto",t._infScroll.style.transform="none",t._infScroll.style.willChange="none")}))}},{key:"isElementAtBottom",value:function(e){var t=arguments.length<=1||void 0===arguments[1]?.8:arguments[1],r=e===document.body||e===document.documentElement?window.screen.availHeight:e.clientHeight,n=(0,d.parseThreshold)(t);return n.unit===d.ThresholdUnits.Pixel?e.scrollTop+r>=e.scrollHeight-n.value:e.scrollTop+r>=n.value/100*e.scrollHeight}},{key:"onScrollListener",value:function(e){var t=this;"function"==typeof this.props.onScroll&&setTimeout((function(){return t.props.onScroll(e)}),0);var r=this.props.height||this._scrollableNode?e.target:document.documentElement.scrollTop?document.documentElement:document.body;this.state.actionTriggered||(this.isElementAtBottom(r,this.props.scrollThreshold)&&this.props.hasMore&&(this.setState({actionTriggered:!0,showLoader:!0}),this.props.next()),this.setState({lastScrollTop:r.scrollTop}))}},{key:"render",value:function(){var e=this,t=n({height:this.props.height||"auto",overflow:"auto",WebkitOverflowScrolling:"touch"},this.props.style),r=this.props.hasChildren||!(!this.props.children||!this.props.children.length),i=this.props.pullDownToRefresh&&this.props.height?{overflow:"auto"}:{};return a.default.createElement("div",{style:i},a.default.createElement("div",{className:"infinite-scroll-component "+(this.props.className||""),ref:function(t){return e._infScroll=t},style:t},this.props.pullDownToRefresh&&a.default.createElement("div",{style:{position:"relative"},ref:function(t){return e._pullDown=t}},a.default.createElement("div",{style:{position:"absolute",left:0,right:0,top:-1*this.maxPullDownDistance}},!this.state.pullToRefreshThresholdBreached&&this.props.pullDownToRefreshContent,this.state.pullToRefreshThresholdBreached&&this.props.releaseToRefreshContent)),this.props.children,!this.state.showLoader&&!r&&this.props.hasMore&&this.props.loader,this.state.showLoader&&this.props.hasMore&&this.props.loader,!this.props.hasMore&&this.props.endMessage))}}]),t}(l.Component);t.default=u,u.defaultProps={pullDownToRefreshContent:a.default.createElement("h3",null,"Pull down to refresh"),releaseToRefreshContent:a.default.createElement("h3",null,"Release to refresh"),pullDownToRefreshThreshold:100,disableBrowserPullToRefresh:!0},u.propTypes={next:s.default.func,hasMore:s.default.bool,children:s.default.node,loader:s.default.node.isRequired,scrollThreshold:s.default.oneOfType([s.default.number,s.default.string]),endMessage:s.default.node,style:s.default.object,height:s.default.number,scrollableTarget:s.default.node,hasChildren:s.default.bool,pullDownToRefresh:s.default.bool,pullDownToRefreshContent:s.default.node,releaseToRefreshContent:s.default.node,pullDownToRefreshThreshold:s.default.number,refreshFunction:s.default.func,onScroll:s.default.func,dataLength:s.default.number.isRequired,key:s.default.string},e.exports=t.default},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseThreshold=function(e){return"number"==typeof e?{unit:r.Percent,value:100*e}:"string"==typeof e?e.match(/^(\d*(\.\d+)?)px$/)?{unit:r.Pixel,value:parseFloat(e)}:e.match(/^(\d*(\.\d+)?)%$/)?{unit:r.Percent,value:parseFloat(e)}:(console.warn('scrollThreshold format is invalid. Valid formats: "120px", "50%"...'),n):(console.warn("scrollThreshold should be string or number"),n)};var r={Pixel:"Pixel",Percent:"Percent"};t.ThresholdUnits=r;var n={unit:r.Percent,value:.8}},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,r){var n,i;return t||(t=250),function(){var o=r||this,l=+new Date,a=arguments;n&&l<n+t?(clearTimeout(i),i=setTimeout((function(){n=l,e.apply(o,a)}),t)):(n=l,e.apply(o,a))}},e.exports=t.default},function(e,t){"use strict";function r(e){return function(){return e}}var n=function(){};n.thatReturns=r,n.thatReturnsFalse=r(!1),n.thatReturnsTrue=r(!0),n.thatReturnsNull=r(null),n.thatReturnsThis=function(){return this},n.thatReturnsArgument=function(e){return e},e.exports=n},function(e,t,r){"use strict";e.exports=function(e,t,r,n,i,o,l,a){if(!e){var s;if(void 0===t)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[r,n,i,o,l,a],d=0;(s=new Error(t.replace(/%s/g,(function(){return c[d++]})))).name="Invariant Violation"}throw s.framesToPop=1,s}}},function(e,t,r){"use strict";var n=r(3),i=r(4),o=r(7);e.exports=function(){function e(e,t,r,n,l,a){a!==o&&i(!1,"Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types")}function t(){return e}e.isRequired=e;var r={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t};return r.checkPropTypes=n,r.PropTypes=r,r}},function(e,t,r){e.exports=r(5)()},function(e,t){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(t,r){t.exports=e}])},e.exports=n(r(787))},787:t=>{"use strict";t.exports=e}},r={};function n(e){var i=r[e];if(void 0!==i)return i.exports;var o=r[e]={exports:{}};return t[e].call(o.exports,o,o.exports,n),o.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};return(()=>{"use strict";n.r(i),n.d(i,{default:()=>Gt});var e=n(697),t=n.n(e),r=n(787),o=n.n(r);const l=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object.keys(e).reduce((function(t,r){return t["data-".concat(function(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}(r))]=e[r],t}),{})},a=function(e){return!e||Array.isArray(e)&&!e.length};var s,c;const d=(s=1,c=new WeakMap,{get:function(e){return c.has(e)||c.set(e,s++),"".concat("rdts").concat(c.get(e))},reset:function(){c=new WeakMap,s=1}}),u=function(e,t,r){if(Array.prototype.findIndex)return e.findIndex(t,r);if(!e)throw new TypeError("findIndex called on null or undefined");if("function"!=typeof t)throw new TypeError("findIndex predicate must be a function");for(var n=0;n<e.length;n++){var i=e[n];if(t.call(r,i,n,e))return n}return-1};function p(e,t){var r=function(e){return e?"#"===e[0]?{"aria-labelledby":e.substring(1).replace(/ #/g," ")}:{"aria-label":e}:{}}(e);return t&&(r["aria-labelledby"]="".concat(r["aria-labelledby"]||""," ").concat(t).trim()),r}function b(e){return b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},b(e)}function f(){return f=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},f.apply(this,arguments)}function h(e,t){return h=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},h(e,t)}function y(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function m(e){return m=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},m(e)}function g(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var v=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&h(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=m(n);if(i){var r=m(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===b(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return y(e)}(this,e)});function a(e){var t,r,n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),g(y(t=l.call(this,e)),"handleInputChange",(function(e){e.persist(),t.delayedCallback(e)})),t.delayedCallback=(r=function(e){return t.props.onInputChange(e.target.value)},function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var o=!n;clearTimeout(n),n=setTimeout((function(){n=null,r.apply(void 0,t)}),300),o&&r.apply(void 0,t)}),t}return t=a,(r=[{key:"render",value:function(){var e=this.props,t=e.inputRef,r=e.texts,n=void 0===r?{}:r,i=e.onFocus,l=e.onBlur,a=e.disabled,s=e.readOnly,c=e.onKeyDown,d=e.activeDescendant,u=e.inlineSearchInput;return o().createElement("input",f({type:"text",disabled:a,ref:t,className:"search",placeholder:u?n.inlineSearchPlaceholder||"Search...":n.placeholder||"Choose...",onKeyDown:c,onChange:this.handleInputChange,onFocus:i,onBlur:l,readOnly:s,"aria-activedescendant":d,"aria-autocomplete":c?"list":void 0},p(n.label)))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);g(v,"propTypes",{tags:t().array,texts:t().object,onInputChange:t().func,onFocus:t().func,onBlur:t().func,onTagRemove:t().func,onKeyDown:t().func,inputRef:t().func,disabled:t().bool,readOnly:t().bool,activeDescendant:t().string,inlineSearchInput:t().bool});const O=v;function w(e){return w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},w(e)}function S(e,t){return S=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},S(e,t)}function E(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function P(e){return P=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},P(e)}function C(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var x=function(e){return"".concat(e,"_tag")},T=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&S(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=P(n);if(i){var r=P(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===w(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return E(e)}(this,e)});function a(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return C(E(e=l.call.apply(l,[this].concat(r))),"handleClick",(function(t){var r=e.props,n=r.id,i=r.onDelete;t.stopPropagation(),t.nativeEvent.stopImmediatePropagation(),i(n,void 0!==(t.key||t.keyCode))})),C(E(e),"onKeyDown",(function(t){"Backspace"===t.key&&(e.handleClick(t),t.preventDefault())})),C(E(e),"onKeyUp",(function(t){(32===t.keyCode||["Delete","Enter"].indexOf(t.key)>-1)&&(e.handleClick(t),t.preventDefault())})),e}return t=a,(r=[{key:"render",value:function(){var e=this.props,t=e.id,r=e.label,n=e.labelRemove,i=void 0===n?"Remove":n,l=e.readOnly,a=e.disabled,s=x(t),c="".concat(t,"_button"),d=["tag-remove",l&&"readOnly",a&&"disabled"].filter(Boolean).join(" "),u=l||a;return o().createElement("span",{className:"tag",id:s,"aria-label":r},r,o().createElement("button",{id:c,onClick:u?void 0:this.handleClick,onKeyDown:u?void 0:this.onKeyDown,onKeyUp:u?void 0:this.onKeyUp,className:d,type:"button","aria-label":i,"aria-labelledby":"".concat(c," ").concat(s),"aria-disabled":u},"x"))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);C(T,"propTypes",{id:t().string.isRequired,label:t().string.isRequired,onDelete:t().func,readOnly:t().bool,disabled:t().bool,labelRemove:t().string});const k=T;function j(e){return j="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},j(e)}function _(e,t){return _=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},_(e,t)}function R(e){return R=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},R(e)}function A(){return A=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},A.apply(this,arguments)}var D,M,N,B=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&_(e,t)}(s,e);var t,r,n,i,a=(n=s,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=R(n);if(i){var r=R(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===j(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function s(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s),a.apply(this,arguments)}return t=s,r=[{key:"render",value:function(){var e=this.props,t=e.tags,r=e.onTagRemove,n=e.texts,i=void 0===n?{}:n,a=e.disabled,s=e.readOnly,c=e.children||o().createElement("span",{className:"placeholder"},i.placeholder||"Choose...");return o().createElement("ul",{className:"tag-list"},function(){var e=arguments.length>1?arguments[1]:void 0,t=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0,n=arguments.length>4?arguments[4]:void 0;return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).map((function(i){var a=i._id,s=i.label,c=i.tagClassName,d=i.dataset,u=i.tagLabel;return o().createElement("li",A({className:["tag-item",c].filter(Boolean).join(" "),key:"tag-item-".concat(a)},l(d)),o().createElement(k,{label:u||s,id:a,onDelete:e,readOnly:t,disabled:r||i.disabled,labelRemove:n}))}))}(t,r,s,a,i.labelRemove),o().createElement("li",{className:"tag-item"},c))}}],r&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),s}(r.PureComponent);D=B,M="propTypes",N={tags:t().array,onTagRemove:t().func,readOnly:t().bool,disabled:t().bool,texts:t().object,children:t().node},M in D?Object.defineProperty(D,M,{value:N,enumerable:!0,configurable:!0,writable:!0}):D[M]=N;const F=B;function I(e){return I="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},I(e)}function L(){return L=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},L.apply(this,arguments)}function H(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function V(e,t){return V=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},V(e,t)}function U(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function G(e){return G=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},G(e)}function q(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var W=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&V(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=G(n);if(i){var r=G(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===I(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return U(e)}(this,e)});function a(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return q(U(e=l.call.apply(l,[this].concat(r))),"getAriaAttributes",(function(){var t=e.props,r=t.mode,n=t.texts,i=void 0===n?{}:n,o=t.showDropdown,l=t.clientId,a=t.tags,s="".concat(l,"_trigger"),c=[],d=p(i.label);return a&&a.length&&(d["aria-label"]&&c.push(s),a.forEach((function(e){c.push(x(e._id))})),d=p(i.label,c.join(" "))),function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?H(Object(r),!0).forEach((function(t){q(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):H(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({id:s,role:"button",tabIndex:e.props.tabIndex,"aria-haspopup":"simpleSelect"===r?"listbox":"tree","aria-expanded":o?"true":"false"},d)})),q(U(e),"handleTrigger",(function(t){t.key&&13!==t.keyCode&&32!==t.keyCode&&40!==t.keyCode||t.key&&e.triggerNode&&e.triggerNode!==document.activeElement||(e.props.showDropdown||32!==t.keyCode||t.preventDefault(),e.props.onTrigger(t))})),e}return t=a,(r=[{key:"render",value:function(){var e=this,t=this.props,r=t.disabled,n=t.readOnly,i=t.showDropdown,l=["dropdown-trigger","arrow",r&&"disabled",n&&"readOnly",i&&"top",!i&&"bottom"].filter(Boolean).join(" ");return o().createElement("a",L({ref:function(t){e.triggerNode=t},className:l,onClick:r?void 0:this.handleTrigger,onKeyDown:r?void 0:this.handleTrigger},this.getAriaAttributes()),this.props.children)}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);q(W,"propTypes",{onTrigger:t().func,disabled:t().bool,readOnly:t().bool,showDropdown:t().bool,mode:t().oneOf(["multiSelect","simpleSelect","radioSelect","hierarchical"]),texts:t().object,clientId:t().string,tags:t().array,tabIndex:t().number});const z=W;var $=n(385),K=n.n($);function Y(e){return Y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Y(e)}function J(e,t){return J=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},J(e,t)}function Q(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function X(e){return X=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},X(e)}function Z(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var ee=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&J(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=X(n);if(i){var r=X(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Y(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Q(e)}(this,e)});function a(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Z(Q(e=l.call.apply(l,[this].concat(r))),"handleClick",(function(){var t=e.props,r=t.onAction,n=t.actionData;r&&r(n.nodeId,n.action)})),e}return t=a,(r=[{key:"render",value:function(){var e=this.props,t=e.title,r=e.className,n=e.text,i=e.readOnly;return o().createElement("i",{title:t,className:r,onClick:i?void 0:this.handleClick},n)}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);Z(ee,"propTypes",{title:t().string,text:t().string,className:t().string,actionData:t().object,onAction:t().func,readOnly:t().bool}),Z(ee,"defaultProps",{onAction:function(){}});const te=ee;function re(e){return re="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},re(e)}var ne=["actions","id"];function ie(){return ie=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ie.apply(this,arguments)}function oe(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function le(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?oe(Object(r),!0).forEach((function(t){ce(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):oe(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function ae(e,t){return ae=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},ae(e,t)}function se(e){return se=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},se(e)}function ce(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var de=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ae(e,t)}(s,e);var t,r,n,i,l=(n=s,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=se(n);if(i){var r=se(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===re(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function s(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s),l.apply(this,arguments)}return t=s,(r=[{key:"render",value:function(){var e=this.props,t=e.actions,r=e.id,n=function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},o=Object.keys(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,ne);return a(t)?null:t.map((function(e,t){var i=e.id||"action-".concat(t);return o().createElement(te,ie({key:i},n,e,{actionData:{action:le(le({},e),{},{id:i}),nodeId:r}}))}))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),s}(r.PureComponent);ce(de,"propTypes",{id:t().string.isRequired,actions:t().array});const ue=de;function pe(e){return pe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},pe(e)}var be=["checked","indeterminate","onChange","disabled","readOnly"];function fe(){return fe=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},fe.apply(this,arguments)}function he(e,t){return he=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},he(e,t)}function ye(e){return ye=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},ye(e)}var me=function(e){var t=e.checked,r=e.indeterminate;return function(e){e&&(e.checked=t,e.indeterminate=r)}},ge=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&he(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=ye(n);if(i){var r=ye(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===pe(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function a(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),l.apply(this,arguments)}return t=a,(r=[{key:"render",value:function(){var e=this.props,t=e.checked,r=e.indeterminate,n=void 0!==r&&r,i=e.onChange,l=e.disabled,a=e.readOnly,s=function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},o=Object.keys(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,be),c=l||a;return o().createElement("input",fe({type:"checkbox",ref:me({checked:t,indeterminate:n}),onChange:i,disabled:c},s))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);!function(e,t,r){t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r}(ge,"propTypes",{checked:t().bool,indeterminate:t().bool,onChange:t().func,disabled:t().bool,readOnly:t().bool});const ve=ge;function Oe(e){return Oe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Oe(e)}var we=["name","checked","onChange","disabled","readOnly"];function Se(){return Se=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Se.apply(this,arguments)}function Ee(e,t){return Ee=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Ee(e,t)}function Pe(e){return Pe=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Pe(e)}var Ce=function(e){var t=e.checked;return function(e){e&&(e.checked=t)}},xe=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Ee(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Pe(n);if(i){var r=Pe(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Oe(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function a(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),l.apply(this,arguments)}return t=a,(r=[{key:"render",value:function(){var e=this.props,t=e.name,r=e.checked,n=e.onChange,i=e.disabled,l=e.readOnly,a=function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},o=Object.keys(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,we),s=i||l;return o().createElement("input",Se({type:"radio",name:t,ref:Ce({checked:r}),onChange:n,disabled:s},a))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);!function(e,t,r){t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r}(xe,"propTypes",{name:t().string.isRequired,checked:t().bool,onChange:t().func,disabled:t().bool,readOnly:t().bool});const Te=xe;function ke(e){return ke="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ke(e)}function je(){return je=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},je.apply(this,arguments)}function _e(e,t){return _e=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},_e(e,t)}function Re(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ae(e){return Ae=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Ae(e)}function De(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Me=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&_e(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Ae(n);if(i){var r=Ae(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===ke(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Re(e)}(this,e)});function a(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return De(Re(e=l.call.apply(l,[this].concat(r))),"handleCheckboxChange",(function(t){var r=e.props,n=r.mode,i=r.id;(0,r.onCheckboxChange)(i,"simpleSelect"===n||"radioSelect"===n||t.target.checked),t.stopPropagation(),t.nativeEvent.stopImmediatePropagation()})),e}return t=a,r=[{key:"render",value:function(){var e=this.props,t=e.mode,r=e.title,n=e.label,i=e.id,l=e.partial,a=e.checked,s=this.props,c=s.value,d=s.disabled,u=s.showPartiallySelected,p=s.readOnly,b=s.clientId,f={className:"node-label"};"simpleSelect"===t&&!p&&!d&&(f.onClick=this.handleCheckboxChange);var h={id:i,value:c,checked:a,disabled:d,readOnly:p,tabIndex:-1},y=["checkbox-item","simpleSelect"===t&&"simple-select"].filter(Boolean).join(" ");return o().createElement("label",{title:r||n,htmlFor:i},"radioSelect"===t?o().createElement(Te,je({name:b,className:"radio-item",onChange:this.handleCheckboxChange},h)):o().createElement(ve,je({name:i,className:y,indeterminate:u&&l,onChange:this.handleCheckboxChange},h)),o().createElement("span",f,n))}}],r&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);De(Me,"propTypes",{id:t().string.isRequired,actions:t().array,title:t().string,label:t().string.isRequired,value:t().string.isRequired,checked:t().bool,partial:t().bool,disabled:t().bool,dataset:t().object,mode:t().oneOf(["multiSelect","simpleSelect","radioSelect","hierarchical"]),showPartiallySelected:t().bool,onCheckboxChange:t().func,readOnly:t().bool,clientId:t().string});const Ne=Me;function Be(e){return Be="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Be(e)}function Fe(e,t){return Fe=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Fe(e,t)}function Ie(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Le(e){return Le=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Le(e)}function He(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Ve=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Fe(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Le(n);if(i){var r=Le(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Be(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Ie(e)}(this,e)});function a(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return He(Ie(e=l.call.apply(l,[this].concat(r))),"onToggle",(function(t){t.stopPropagation(),t.nativeEvent.stopImmediatePropagation(),e.props.onNodeToggle(e.props.id)})),He(Ie(e),"onKeyDown",(function(t){"Enter"!==t.key&&32!==t.keyCode||(e.props.onNodeToggle(e.props.id),t.preventDefault())})),e}return t=a,r=[{key:"render",value:function(){var e=this.props,t=e.expanded,r=e.isLeaf,n=["toggle",t&&"expanded",!t&&"collapsed"].filter(Boolean).join(" ");return r?o().createElement("i",{role:"button",tabIndex:-1,className:n,style:{visibility:"hidden"},"aria-hidden":!0}):o().createElement("i",{role:"button",tabIndex:-1,className:n,onClick:this.onToggle,onKeyDown:this.onKeyDown,"aria-hidden":!0})}}],r&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.PureComponent);He(Ve,"propTypes",{expanded:t().bool,isLeaf:t().bool,onNodeToggle:t().func,id:t().string});const Ue=Ve;function Ge(e){return Ge="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ge(e)}function qe(){return qe=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},qe.apply(this,arguments)}function We(e,t){return We=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},We(e,t)}function ze(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function $e(e){return $e=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},$e(e)}function Ke(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Ye=function(e){return a(e)},Je=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&We(e,t)}(s,e);var t,r,n,i,a=(n=s,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=$e(n);if(i){var r=$e(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Ge(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return ze(e)}(this,e)});function s(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Ke(ze(e=a.call.apply(a,[this].concat(r))),"getAriaAttributes",(function(){var t=e.props,r=t._children,n=t._depth,i=t.checked,o=t.disabled,l=t.expanded,a=t.readOnly,s=t.mode,c=t.partial,d={};return d.role="simpleSelect"===s?"option":"treeitem",d["aria-disabled"]=o||a,d["aria-selected"]=i,"simpleSelect"!==s&&(d["aria-checked"]=c?"mixed":i,d["aria-level"]=(n||0)+1,d["aria-expanded"]=r&&(l?"true":"false")),d})),e}return t=s,r=[{key:"render",value:function(){var e=this.props,t=e.mode,r=e.keepTreeOnSearch,n=e._id,i=e._children,a=e.dataset,s=e._depth,c=e.expanded,d=e.title,u=e.label,p=e.partial,b=e.checked,f=e.value,h=e.disabled,y=e.actions,m=e.onAction,g=e.searchModeOn,v=e.onNodeToggle,O=e.onCheckboxChange,w=e.showPartiallySelected,S=e.readOnly,E=e.clientId,P=function(e){var t=e.keepTreeOnSearch,r=e.keepChildrenOnSearch,n=e._children,i=e.matchInChildren,o=e.matchInParent,l=e.disabled,a=e.partial,s=e.hide,c=e.className,d=e.showPartiallySelected,u=e.readOnly,p=e.checked,b=e._focused;return["node",Ye(n)&&"leaf",!Ye(n)&&"tree",l&&"disabled",s&&"hide",t&&i&&"match-in-children",t&&r&&o&&"match-in-parent",d&&a&&"partial",u&&"readOnly",p&&"checked",b&&"focused",c].filter(Boolean).join(" ")}(this.props),C=r||!g?{paddingLeft:"".concat(20*(s||0),"px")}:{},x="".concat(n,"_li");return o().createElement("li",qe({className:P,style:C,id:x},l(a),this.getAriaAttributes()),o().createElement(Ue,{isLeaf:Ye(i),expanded:c,id:n,onNodeToggle:v}),o().createElement(Ne,{title:d,label:u,id:n,partial:p,checked:b,value:f,disabled:h,mode:t,onCheckboxChange:O,showPartiallySelected:w,readOnly:S,clientId:E}),o().createElement(ue,{actions:y,onAction:m,id:n,readOnly:S}))}}],r&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),s}(r.PureComponent);Ke(Je,"propTypes",{_id:t().string.isRequired,_depth:t().number,_children:t().array,actions:t().array,className:t().string,title:t().string,label:t().string.isRequired,value:t().string.isRequired,checked:t().bool,expanded:t().bool,disabled:t().bool,partial:t().bool,dataset:t().object,keepTreeOnSearch:t().bool,keepChildrenOnSearch:t().bool,searchModeOn:t().bool,onNodeToggle:t().func,onAction:t().func,onCheckboxChange:t().func,mode:t().oneOf(["multiSelect","simpleSelect","radioSelect","hierarchical"]),showPartiallySelected:t().bool,readOnly:t().bool,clientId:t().string});const Qe=Je;function Xe(e){return Xe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Xe(e)}function Ze(){return Ze=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Ze.apply(this,arguments)}function et(e,t){return et=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},et(e,t)}function tt(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function rt(e){return rt=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},rt(e)}function nt(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var it=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&et(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=rt(n);if(i){var r=rt(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Xe(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return tt(e)}(this,e)});function a(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),nt(tt(t=l.call(this,e)),"UNSAFE_componentWillReceiveProps",(function(e){var r=e.activeDescendant===t.props.activeDescendant;t.computeInstanceProps(e,!r),t.setState({items:t.allVisibleNodes.slice(0,t.currentPage*t.props.pageSize)})})),nt(tt(t),"componentDidMount",(function(){t.setState({scrollableTarget:t.node.parentNode})})),nt(tt(t),"computeInstanceProps",(function(e,r){if(t.allVisibleNodes=t.getNodes(e),t.totalPages=Math.ceil(t.allVisibleNodes.length/t.props.pageSize),r&&e.activeDescendant){var n=e.activeDescendant.replace(/_li$/,""),i=u(t.allVisibleNodes,(function(e){return e.key===n}))+1;t.currentPage=i>0?Math.ceil(i/t.props.pageSize):1}})),nt(tt(t),"shouldRenderNode",(function(e,t){var r=t.data,n=t.searchModeOn,i=e.expanded,o=e._parent;if(n||i)return!0;var l=o&&r.get(o);return!l||l.expanded})),nt(tt(t),"getNodes",(function(e){var r=e.data,n=e.keepTreeOnSearch,i=e.keepChildrenOnSearch,l=e.searchModeOn,a=e.mode,s=e.showPartiallySelected,c=e.readOnly,d=e.onAction,u=e.onChange,p=e.onCheckboxChange,b=e.onNodeToggle,f=e.activeDescendant,h=e.clientId,y=[];return r.forEach((function(r){t.shouldRenderNode(r,e)&&y.push(o().createElement(Qe,Ze({keepTreeOnSearch:n,keepChildrenOnSearch:i,key:r._id},r,{searchModeOn:l,onChange:u,onCheckboxChange:p,onNodeToggle:b,onAction:d,mode:a,showPartiallySelected:s,readOnly:c,clientId:h,activeDescendant:f})))})),y})),nt(tt(t),"hasMore",(function(){return t.currentPage<t.totalPages})),nt(tt(t),"loadMore",(function(){t.currentPage=t.currentPage+1;var e=t.allVisibleNodes.slice(0,t.currentPage*t.props.pageSize);t.setState({items:e})})),nt(tt(t),"setNodeRef",(function(e){t.node=e})),nt(tt(t),"getAriaAttributes",(function(){var e=t.props.mode;return{role:"simpleSelect"===e?"listbox":"tree","aria-multiselectable":/multiSelect|hierarchical/.test(e)}})),t.currentPage=1,t.computeInstanceProps(e,!0),t.state={items:t.allVisibleNodes.slice(0,t.props.pageSize)},t}return t=a,(r=[{key:"render",value:function(){var e=this.props.searchModeOn;return o().createElement("ul",Ze({className:"root ".concat(e?"searchModeOn":""),ref:this.setNodeRef},this.getAriaAttributes()),this.state.scrollableTarget&&o().createElement(K(),{dataLength:this.state.items.length,next:this.loadMore,hasMore:this.hasMore(),loader:o().createElement("span",{className:"searchLoader"},"Loading..."),scrollableTarget:this.state.scrollableTarget},this.state.items))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.Component);nt(it,"propTypes",{data:t().object,keepTreeOnSearch:t().bool,keepChildrenOnSearch:t().bool,searchModeOn:t().bool,onChange:t().func,onNodeToggle:t().func,onAction:t().func,onCheckboxChange:t().func,mode:t().oneOf(["multiSelect","simpleSelect","radioSelect","hierarchical"]),showPartiallySelected:t().bool,pageSize:t().number,readOnly:t().bool,clientId:t().string,activeDescendant:t().string}),nt(it,"defaultProps",{pageSize:100});const ot=it;var lt=n(865),at=n.n(lt),st=function(e){return e};const ct=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"children",r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:st;return at()(e[t],(function(e){return r(e).checked}))||e[t].some((function(e){return r(e).partial}))};function dt(e){var t=e.nodes,r=e.parent,n=e.depth,i=void 0===n?0:n,o=e.simple,l=e.radio,s=e.showPartialState,c=e.hierarchical,d=e.rootPrefixId,u=e._rv,p=void 0===u?{list:new Map,defaultValues:[],singleSelectedNode:null}:u,b=o||l;return t.forEach((function(e,t){e._depth=i,r?(e._id=e.id||"".concat(r._id,"-").concat(t),e._parent=r._id,r._children.push(e._id)):e._id=e.id||"".concat(d?"".concat(d,"-").concat(t):t),b&&e.checked&&(p.singleSelectedNode?e.checked=!1:p.singleSelectedNode=e),b&&e.isDefaultValue&&p.singleSelectedNode&&!p.singleSelectedNode.isDefaultValue&&(p.singleSelectedNode.checked=!1,p.singleSelectedNode=null),!e.isDefaultValue||b&&0!==p.defaultValues.length||(p.defaultValues.push(e._id),e.checked=!0,b&&(p.singleSelectedNode=e)),c&&!l||function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]&&!arguments[2]?["disabled"]:["checked","disabled"],n=0;n<r.length;n++){var i=r[n];void 0===e[i]&&void 0!==t[i]&&(e[i]=t[i])}}(e,r,!l),p.list.set(e._id,e),!o&&e.children&&(e._children=[],dt({nodes:e.children,parent:e,depth:i+1,radio:l,showPartialState:s,hierarchical:c,_rv:p}),s&&!e.checked&&(e.partial=ct(e),b||a(e.children)||!e.children.every((function(e){return e.checked}))||(e.checked=!0)),e.children=void 0)})),p}const ut=function(e){var t=e.tree,r=e.simple,n=e.radio,i=e.showPartialState,o=e.hierarchical,l=e.rootPrefixId;return dt({nodes:Array.isArray(t)?t:[t],simple:r,radio:n,showPartialState:i,hierarchical:o,rootPrefixId:l})};var pt=function e(t,r,n){r[t._id]=!0,a(t._children)||t._children.forEach((function(t){return e(n(t),r,n)}))},bt=function(e,t){var r=[],n={};return e.forEach((function(e,i){n[i]||(t(e,i,n)&&r.push(e),n[i]=!0)})),r},ft={getNodesMatching:bt,getVisibleNodes:function(e,t,r){return bt(e,(function(e,n,i){return r&&e._children&&e._children.length&&!0!==e.expanded&&pt(e,i,t),!e.hide}))},markSubTreeVisited:pt};const ht=ft;function yt(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var mt="ArrowUp",gt="ArrowDown",vt="ArrowLeft",Ot="ArrowRight",wt="Enter",St="Home",Et="PageUp",Pt="PageDown",Ct={None:"None",FocusPrevious:"FocusPrevious",FocusNext:"FocusNext",FocusParent:"FocusParent",FocusFirst:"FocusFirst",FocusLast:"FocusLast",ToggleExpanded:"ToggleExpanded",ToggleChecked:"ToggleChecked"},xt=new Set([Ct.FocusPrevious,Ct.FocusNext,Ct.FocusParent,Ct.FocusFirst,Ct.FocusLast]),Tt=[mt,gt,St,Et,"End",Pt],kt=Tt.concat([vt,Ot,wt]),jt=function(e,t,r,n){return t.indexOf(e)>-1||!r&&e===n},_t={isValidKey:function(e,t){return(t?kt:Tt).indexOf(e)>-1},getAction:function(e,t){var r;return r=t===vt?function(e,t){return e&&t===vt?!0===e.expanded?Ct.ToggleExpanded:e._parent?Ct.FocusParent:Ct.None:Ct.None}(e,t):t===Ot?function(e,t){return e&&e._children&&t===Ot?!0!==e.expanded?Ct.ToggleExpanded:Ct.FocusNext:Ct.None}(e,t):function(e,t){return jt(e,[St,Et],t,gt)}(t,e)?Ct.FocusFirst:function(e,t){return jt(e,["End",Pt],t,mt)}(t,e)?Ct.FocusLast:function(e,t){if(!e)return Ct.None;switch(t){case mt:return Ct.FocusPrevious;case gt:return Ct.FocusNext;case wt:return Ct.ToggleChecked;default:return Ct.None}}(e,t),r},getNextFocus:function(e,t,r,n,i){if(r===Ct.FocusParent)return function(e,t){return e&&e._parent?t(e._parent):e}(t,n);if(!xt.has(r))return t;var o=ht.getVisibleNodes(e,n,i);return function(e){return jt(e,[Ct.FocusPrevious,Ct.FocusLast],!0)}(r)&&(o=o.reverse()),function(e,t,r){if(!e||0===e.length)return t;var n,i=t;return function(e){return jt(e,[Ct.FocusFirst,Ct.FocusLast],!0)}(r)?i=(n=e,function(e){if(Array.isArray(e))return e}(n)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,o=[],l=!0,a=!1;try{for(r=r.call(e);!(l=(n=r.next()).done)&&(o.push(n.value),1!==o.length);l=!0);}catch(e){a=!0,i=e}finally{try{l||null==r.return||r.return()}finally{if(a)throw i}}return o}}(n)||function(e,t){if(e){if("string"==typeof e)return yt(e,1);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?yt(e,1):void 0}}(n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0]:[Ct.FocusPrevious,Ct.FocusNext].indexOf(r)>-1&&(i=function(e,t){var r=e.indexOf(t)+1;return r%e.length==0?e[0]:e[r]}(e,t)),i}(o,t,r)},getNextFocusAfterTagDelete:function(e,t,r,n){var i=t?u(t,(function(t){return t._id===e})):-1;if(i<0||!r.length)return n;var o=r[i=r.length>i?i:r.length-1]._id,l=document.getElementById(x(o));return l&&l.firstElementChild||n},handleFocusNavigationkey:function(e,t,r,n,i){var o=_t.getNextFocus(e,r,t,n,i);return _t.adjustFocusedProps(r,o),o?o._id:r&&r._id},handleToggleNavigationkey:function(e,t,r,n,i){return e!==Ct.ToggleChecked||r||t.readOnly||t.disabled?e===Ct.ToggleExpanded&&i(t._id):n(t._id,!0!==t.checked),t&&t._id},adjustFocusedProps:function(e,t){e&&t&&e._id!==t._id&&(e._focused=!1),t&&(t._focused=!0)}};const Rt=_t;var At=function(){function e(t){var r=t.data,n=t.mode,i=t.showPartiallySelected,o=t.rootPrefixId,l=t.searchPredicate;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._src=r,this.simpleSelect="simpleSelect"===n,this.radioSelect="radioSelect"===n,this.hierarchical="hierarchical"===n,this.searchPredicate=l;var a=ut({tree:JSON.parse(JSON.stringify(r)),simple:this.simpleSelect,radio:this.radioSelect,showPartialState:i,hierarchical:this.hierarchical,rootPrefixId:o}),s=a.list,c=a.defaultValues,d=a.singleSelectedNode;this.tree=s,this.defaultValues=c,this.showPartialState=!this.hierarchical&&i,this.searchMaps=new Map,(this.simpleSelect||this.radioSelect)&&d&&(this.currentChecked=d._id)}var t,r;return t=e,r=[{key:"getNodeById",value:function(e){return this.tree.get(e)}},{key:"getMatches",value:function(e){var t=this;if(this.searchMaps.has(e))return this.searchMaps.get(e);var r=-1,n=e;this.searchMaps.forEach((function(t,i){e.startsWith(i)&&i.length>r&&(r=i.length,n=i)}));var i=[],o=this._getAddOnMatch(i,e);return n!==e?this.searchMaps.get(n).forEach((function(e){return o(t.getNodeById(e))})):this.tree.forEach(o),this.searchMaps.set(e,i),i}},{key:"addParentsToTree",value:function(e,t){if(void 0!==e){var r=this.getNodeById(e);this.addParentsToTree(r._parent,t),r.hide=!r._isMatch||r.hide,r.matchInChildren=!0,t.set(e,r)}}},{key:"addChildrenToTree",value:function(e,t,r){var n=this;void 0!==e&&e.forEach((function(e){if(!r||!r.includes(e)){var i=n.getNodeById(e);i.matchInParent=!0,t.set(e,i),n.addChildrenToTree(i._children,t)}}))}},{key:"filterTree",value:function(e,t,r){var n=this,i=this.getMatches(e.toLowerCase()),o=new Map;i.forEach((function(e){var l=n.getNodeById(e);l.hide=!1,l._isMatch=!0,t&&n.addParentsToTree(l._parent,o),o.set(e,l),t&&r&&n.addChildrenToTree(l._children,o,i)}));var l=0===i.length;return this.matchTree=o,{allNodesHidden:l,tree:o}}},{key:"restoreNodes",value:function(){return this.tree.forEach((function(e){e.hide=!1})),this.tree}},{key:"restoreDefaultValues",value:function(){var e=this;return this.defaultValues.forEach((function(t){e.setNodeCheckedState(t,!0)})),this.tree}},{key:"togglePreviousChecked",value:function(e,t){var r=this.currentChecked;if(r&&r!==e){var n=this.getNodeById(r);n.checked=!1,this.radioSelect&&this.showPartialState&&this.partialCheckParents(n)}this.currentChecked=t?e:null}},{key:"setNodeCheckedState",value:function(e,t){this.radioSelect&&this.togglePreviousChecked(e,t);var r=this.getNodeById(e);r.checked=t,this.showPartialState&&(r.partial=!1),this.simpleSelect?this.togglePreviousChecked(e,t):this.radioSelect?(this.showPartialState&&this.partialCheckParents(r),t||this.unCheckParents(r)):(this.hierarchical||this.toggleChildren(e,t),this.showPartialState&&this.partialCheckParents(r),this.hierarchical||t||this.unCheckParents(r))}},{key:"unCheckParents",value:function(e){for(var t=e._parent;t;){var r=this.getNodeById(t);r.checked=!1,r.partial=ct(r,"_children",this.getNodeById.bind(this)),t=r._parent}}},{key:"partialCheckParents",value:function(e){for(var t=this,r=e._parent;r;){var n=this.getNodeById(r);n.checked=n._children.every((function(e){return t.getNodeById(e).checked})),n.partial=ct(n,"_children",this.getNodeById.bind(this)),r=n._parent}}},{key:"toggleChildren",value:function(e,t){var r=this,n=this.getNodeById(e);n.checked=t,this.showPartialState&&(n.partial=!1),a(n._children)||n._children.forEach((function(e){return r.toggleChildren(e,t)}))}},{key:"toggleNodeExpandState",value:function(e){var t=this.getNodeById(e);return t.expanded=!t.expanded,t.expanded||this.collapseChildren(t),this.tree}},{key:"collapseChildren",value:function(e){var t=this;e.expanded=!1,a(e._children)||e._children.forEach((function(e){return t.collapseChildren(t.getNodeById(e))}))}},{key:"tags",get:function(){var e=this;return this.radioSelect||this.simpleSelect?this.currentChecked?[this.getNodeById(this.currentChecked)]:[]:ht.getNodesMatching(this.tree,(function(t,r,n){return t.checked&&!e.hierarchical&&ht.markSubTreeVisited(t,n,(function(t){return e.getNodeById(t)})),t.checked}))}},{key:"getTreeAndTags",value:function(){return{tree:this.tree,tags:this.tags}}},{key:"handleNavigationKey",value:function(e,t,r,n,i,o,l){var a=this,s=e&&this.getNodeById(e),c=Rt.getAction(s,r);return xt.has(c)?Rt.handleFocusNavigationkey(t,c,s,(function(e){return a.getNodeById(e)}),i):s&&t.has(s._id)?Rt.handleToggleNavigationkey(c,s,n,o,l):e}},{key:"_getAddOnMatch",value:function(e,t){var r=function(e,t){return e.label.toLowerCase().indexOf(t)>=0};return"function"==typeof this.searchPredicate&&(r=this.searchPredicate),function(n){r(n,t)&&e.push(n._id)}}}],r&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),e}();const Dt=At;function Mt(e){return Mt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Mt(e)}function Nt(){return Nt=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Nt.apply(this,arguments)}function Bt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Ft(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Bt(Object(r),!0).forEach((function(t){Vt(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Bt(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function It(e,t){return It=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},It(e,t)}function Lt(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ht(e){return Ht=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Ht(e)}function Vt(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Ut=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&It(e,t)}(a,e);var t,r,n,i,l=(n=a,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Ht(n);if(i){var r=Ht(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Mt(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Lt(e)}(this,e)});function a(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),Vt(Lt(t=l.call(this,e)),"initNewProps",(function(e){var r=e.data,n=e.mode,i=e.showDropdown,o=e.showPartiallySelected,l=e.searchPredicate;t.treeManager=new Dt({data:r,mode:n,showPartiallySelected:o,rootPrefixId:t.clientId,searchPredicate:l}),t.setState((function(e){var r=e.currentFocus&&t.treeManager.getNodeById(e.currentFocus);return r&&(r._focused=!0),Ft({showDropdown:/initial|always/.test(i)||!0===e.showDropdown},t.treeManager.getTreeAndTags())}))})),Vt(Lt(t),"resetSearchState",(function(){return t.searchInput&&(t.searchInput.value=""),{tree:t.treeManager.restoreNodes(),searchModeOn:!1,allNodesHidden:!1}})),Vt(Lt(t),"handleClick",(function(e,r){t.setState((function(e){var r="always"===t.props.showDropdown||t.keepDropdownActive||!e.showDropdown;return r!==e.showDropdown&&(r?document.addEventListener("click",t.handleOutsideClick,!1):document.removeEventListener("click",t.handleOutsideClick,!1)),r?t.props.onFocus():t.props.onBlur(),r?{showDropdown:r}:Ft({showDropdown:r},t.resetSearchState())}),r)})),Vt(Lt(t),"handleOutsideClick",(function(e){"always"!==t.props.showDropdown&&function(e,t){return e instanceof Event&&!function(e){if(e.path)return e.path;for(var t=e.target,r=[t];t.parentElement;)t=t.parentElement,r.unshift(t);return r}(e).some((function(e){return e===t}))}(e,t.node)&&t.handleClick()})),Vt(Lt(t),"onInputChange",(function(e){var r=e.length>0;if(r){var n=t.treeManager.filterTree(e,t.props.keepTreeOnSearch,t.props.keepChildrenOnSearch),i=n.allNodesHidden,o=n.tree;t.setState({tree:o,searchModeOn:r,allNodesHidden:i})}else t.setState(t.resetSearchState())})),Vt(Lt(t),"onTagRemove",(function(e,r){var n=t.state.tags;t.onCheckboxChange(e,!1,(function(i){r&&Rt.getNextFocusAfterTagDelete(e,n,i,t.searchInput).focus()}))})),Vt(Lt(t),"onNodeToggle",(function(e){t.treeManager.toggleNodeExpandState(e);var r=t.state.searchModeOn?t.treeManager.matchTree:t.treeManager.tree;t.setState({tree:r}),"function"==typeof t.props.onNodeToggle&&t.props.onNodeToggle(t.treeManager.getNodeById(e))})),Vt(Lt(t),"onCheckboxChange",(function(e,r,n){var i=t.props,o=i.mode,l=i.keepOpenOnSelect,a=i.clearSearchOnChange,s=t.state,c=s.currentFocus,d=s.searchModeOn;t.treeManager.setNodeCheckedState(e,r);var u=t.treeManager.tags,p=["simpleSelect","radioSelect"].indexOf(o)>-1,b=!(p&&!l)&&t.state.showDropdown,f=c&&t.treeManager.getNodeById(c),h=t.treeManager.getNodeById(e);u.length||(t.treeManager.restoreDefaultValues(),u=t.treeManager.tags);var y={tree:d?t.treeManager.matchTree:t.treeManager.tree,tags:u,showDropdown:b,currentFocus:e};(p&&!b||a)&&Object.assign(y,t.resetSearchState()),p&&!b&&document.removeEventListener("click",t.handleOutsideClick,!1),Rt.adjustFocusedProps(f,h),t.setState(y,(function(){n&&n(u)})),t.props.onChange(h,u)})),Vt(Lt(t),"onAction",(function(e,r){t.props.onAction(t.treeManager.getNodeById(e),r)})),Vt(Lt(t),"onInputFocus",(function(){t.keepDropdownActive=!0})),Vt(Lt(t),"onInputBlur",(function(){t.keepDropdownActive=!1})),Vt(Lt(t),"onTrigger",(function(e){t.handleClick(e,(function(){t.state.showDropdown&&t.searchInput.focus()}))})),Vt(Lt(t),"onKeyboardKeyDown",(function(e){var r=t.props,n=r.readOnly,i=r.mode,o=r.disablePoppingOnBackspace,l=t.state,a=l.showDropdown,s=l.tags,c=l.searchModeOn,d=l.currentFocus,u=t.treeManager,p=c?u.matchTree:u.tree;if(a||!Rt.isValidKey(e.key,!1)&&!/^\w$/i.test(e.key))if(a&&Rt.isValidKey(e.key,!0)){var b=u.handleNavigationKey(d,p,e.key,n,!c,t.onCheckboxChange,t.onNodeToggle);b!==d&&t.setState({currentFocus:b},(function(){var e=document&&document.getElementById("".concat(b,"_li"));e&&e.scrollIntoView()}))}else{if(a&&["Escape","Tab"].indexOf(e.key)>-1)return void("simpleSelect"===i&&p.has(d)?t.onCheckboxChange(d,!0):(t.keepDropdownActive=!1,t.handleClick()));if(o||"Backspace"!==e.key||!s.length||0!==t.searchInput.value.length)return;var f=s.pop();t.onCheckboxChange(f._id,!1)}else if(e.persist(),t.handleClick(null,(function(){return t.onKeyboardKeyDown(e)})),/\w/i.test(e.key))return;e.preventDefault()})),Vt(Lt(t),"getAriaAttributes",(function(){var e=t.props,r=e.mode,n=e.texts;return"radioSelect"!==r?{}:Ft({role:"radiogroup"},p(n.label))})),t.state={searchModeOn:!1,currentFocus:void 0},t.clientId=e.id||d.get(Lt(t)),t}return t=a,(r=[{key:"UNSAFE_componentWillMount",value:function(){this.initNewProps(this.props)}},{key:"componentWillUnmount",value:function(){document.removeEventListener("click",this.handleOutsideClick,!1)}},{key:"UNSAFE_componentWillReceiveProps",value:function(e){this.initNewProps(e)}},{key:"render",value:function(){var e=this,t=this.props,r=t.disabled,n=t.readOnly,i=t.mode,l=t.texts,a=t.inlineSearchInput,s=t.tabIndex,c=this.state,d=c.showDropdown,u=c.currentFocus,p=c.tags,b={disabled:r,readOnly:n,activeDescendant:u?"".concat(u,"_li"):void 0,texts:l,mode:i,clientId:this.clientId},f=o().createElement(O,Nt({inputRef:function(t){e.searchInput=t},onInputChange:this.onInputChange,onFocus:this.onInputFocus,onBlur:this.onInputBlur,onKeyDown:this.onKeyboardKeyDown},b,{inlineSearchInput:a}));return o().createElement("div",{id:this.clientId,className:[this.props.className&&this.props.className,"react-dropdown-tree-select"].filter(Boolean).join(" "),ref:function(t){e.node=t}},o().createElement("div",{className:["dropdown","simpleSelect"===i&&"simple-select","radioSelect"===i&&"radio-select"].filter(Boolean).join(" ")},o().createElement(z,Nt({onTrigger:this.onTrigger,showDropdown:d},b,{tags:p,tabIndex:s}),o().createElement(F,Nt({tags:p,onTagRemove:this.onTagRemove},b),!a&&f)),d&&o().createElement("div",Nt({className:"dropdown-content"},this.getAriaAttributes()),a&&f,this.state.allNodesHidden?o().createElement("span",{className:"no-matches"},l.noMatches||"No matches found"):o().createElement(ot,Nt({data:this.state.tree,keepTreeOnSearch:this.props.keepTreeOnSearch,keepChildrenOnSearch:this.props.keepChildrenOnSearch,searchModeOn:this.state.searchModeOn,onAction:this.onAction,onCheckboxChange:this.onCheckboxChange,onNodeToggle:this.onNodeToggle,mode:i,showPartiallySelected:this.props.showPartiallySelected},b)))))}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(r.Component);Vt(Ut,"propTypes",{data:t().oneOfType([t().object,t().array]).isRequired,clearSearchOnChange:t().bool,keepTreeOnSearch:t().bool,keepChildrenOnSearch:t().bool,keepOpenOnSelect:t().bool,texts:t().shape({placeholder:t().string,inlineSearchPlaceholder:t().string,noMatches:t().string,label:t().string,labelRemove:t().string}),showDropdown:t().oneOf(["default","initial","always"]),className:t().string,onChange:t().func,onAction:t().func,onNodeToggle:t().func,onFocus:t().func,onBlur:t().func,mode:t().oneOf(["multiSelect","simpleSelect","radioSelect","hierarchical"]),showPartiallySelected:t().bool,disabled:t().bool,readOnly:t().bool,id:t().string,searchPredicate:t().func,inlineSearchInput:t().bool,tabIndex:t().number,disablePoppingOnBackspace:t().bool}),Vt(Ut,"defaultProps",{onAction:function(){},onFocus:function(){},onBlur:function(){},onChange:function(){},texts:{},showDropdown:"default",inlineSearchInput:!1,tabIndex:0,disablePoppingOnBackspace:!1});const Gt=Ut})(),i})(),e.exports=n(r(9196))},9196:function(e){"use strict";e.exports=window.React}},r={};function n(e){var i=r[e];if(void 0!==i)return i.exports;var o=r[e]={id:e,loaded:!1,exports:{}};return t[e].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}n.m=t,e=[],n.O=function(t,r,i,o){if(!r){var l=1/0;for(d=0;d<e.length;d++){r=e[d][0],i=e[d][1],o=e[d][2];for(var a=!0,s=0;s<r.length;s++)(!1&o||l>=o)&&Object.keys(n.O).every((function(e){return n.O[e](r[s])}))?r.splice(s--,1):(a=!1,o<l&&(l=o));if(a){e.splice(d--,1);var c=i();void 0!==c&&(t=c)}}return t}o=o||0;for(var d=e.length;d>0&&e[d-1][2]>o;d--)e[d]=e[d-1];e[d]=[r,i,o]},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,{a:t}),t},n.d=function(e,t){for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e},function(){var e;n.g.importScripts&&(e=n.g.location+"");var t=n.g.document;if(!e&&t&&(t.currentScript&&(e=t.currentScript.src),!e)){var r=t.getElementsByTagName("script");if(r.length)for(var i=r.length-1;i>-1&&!e;)e=r[i--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),n.p=e}(),function(){var e={826:0,431:0};n.O.j=function(t){return 0===e[t]};var t=function(t,r){var i,o,l=r[0],a=r[1],s=r[2],c=0;if(l.some((function(t){return 0!==e[t]}))){for(i in a)n.o(a,i)&&(n.m[i]=a[i]);if(s)var d=s(n)}for(t&&t(r);c<l.length;c++)o=l[c],n.o(e,o)&&e[o]&&e[o][0](),e[o]=0;return n.O(d)},r=self.webpackChunkhumix_block=self.webpackChunkhumix_block||[];r.forEach(t.bind(null,0)),r.push=t.bind(null,r.push.bind(r))}();var i=n.O(void 0,[431],(function(){return n(5758)}));i=n.O(i)}(); -
humix/trunk/humix-block/src/edit.js
r2972825 r3010711 56 56 */ 57 57 export default function Edit({ clientId, attributes, setAttributes }) { 58 const 58 const 59 59 BEFORE_FIRST_PARAGRAPH = '0', 60 60 UNDER_FIRST_PARAGRAPH = '1', … … 63 63 BOTTOM_OF_PAGE = '4'; 64 64 65 const 65 const 66 66 EDIT_BLOCK_MODE = 'edit', 67 67 PREVIEW_BLOCK_MODE = 'preview', 68 68 ADD_TO_POSTS_BLOCK_MODE = 'add_to_posts'; 69 69 70 const 70 const 71 71 MATCH_BY_TOPIC = 'MATCH_BY_TOPIC', 72 72 MATCH_BY_CATEGORY = 'MATCH_BY_CATEGORY', … … 85 85 86 86 // These are used in the embed code generator API 87 const 87 const 88 88 MY_VIDEOS_AND_NETWORK_BY_TOPIC = 0, 89 89 MY_VIDEOS_AND_NETWORK_BY_CAT = 1, … … 101 101 }; 102 102 103 const 103 const 104 104 PROPOGATE_SKIP_IF_VIDEO_EXISTS = 'skip_if_video_exists', 105 105 PROPAGATE_REPLACE_ALL_VIDEOS = 'replace_all_videos', … … 120 120 121 121 // Propagate to other posts tracking 122 let 122 let 123 123 tmpUpdatedPosts = 0, // posts that were updated 124 124 tmpSkippedPosts = 0, // posts that were skipped due to having video already … … 165 165 166 166 const [ blockMode, setBlockMode ] = useState( isValidConfig() ? PREVIEW_BLOCK_MODE : EDIT_BLOCK_MODE); 167 167 168 168 const ALIGNMENT_CONTROLS = ["left", "center", "right"]; 169 169 170 /** 170 /** 171 171 * Determines approximate location of Humix block with respect to paragraph blocks 172 172 * to provide a default selection for the propagate to location feature … … 210 210 } 211 211 212 useEffect(determineBlockLocationInPost, []); 212 useEffect(determineBlockLocationInPost, []); 213 213 214 214 useEffect(() => { … … 326 326 const generateJSON = ( 327 327 { 328 autoplay=false, 329 floatOption=true, 330 videoId="", 331 autoMatch=false, 328 autoplay=false, 329 floatOption=true, 330 videoId="", 331 autoMatch=false, 332 332 startTime=0, // TODO: allow customization 333 333 width=640, // TODO: allow customization 334 334 height=360, // TODO: allow customization 335 preview=false // TODO: allow customization 335 preview=false, // TODO: allow customization 336 embedCodeSource="w" 336 337 } = {} 337 338 ) => { 338 339 339 340 // set required options first 340 341 const settings = { … … 343 344 width: width, 344 345 height: height, 346 embed_code_source: embedCodeSource, 345 347 }; 346 348 347 // either videoId exists or automatch exists 349 // either videoId exists or automatch exists 348 350 // TODO: enforce check here 349 351 if (videoId) { … … 400 402 } 401 403 ); 402 404 403 405 // should never fail here 404 406 if (!settings) { … … 450 452 return; 451 453 } 452 } else { 454 } else { 453 455 requestURL = generateAutoMatchURL(EZHX_GENERATE_EMBED_CODE_BASE); 454 456 if (!requestURL) { … … 533 535 }); 534 536 // if we return false here that means we didn't add anything new 535 if (newPostBlocksOne.length === postBlocks.length) { 537 if (newPostBlocksOne.length === postBlocks.length) { 536 538 tmpIgnoredPosts++; 537 539 setIgnoredPosts(tmpIgnoredPosts); … … 552 554 }); 553 555 // if we return false here that means we didnt add anything new 554 if (newPostBlocksTwo.length === postBlocks.length) { 556 if (newPostBlocksTwo.length === postBlocks.length) { 555 557 tmpIgnoredPosts++; 556 558 setIgnoredPosts(tmpIgnoredPosts); … … 618 620 resetPropagateTotals(); 619 621 setIsPropagatingBlock(true); 620 let url = '/wp/v2/posts?context=edit'; 622 let url = '/wp/v2/posts?context=edit'; 621 623 622 624 if (parseInt(selectedCategory) > 0) { … … 758 760 )} 759 761 { displayTypeVal === "auto" && ( 760 <div className="auto-select-preview"> 762 <div className="auto-select-preview"> 761 763 <h3>Auto-Select Video</h3> 762 764 <p> … … 961 963 <CategorySelector 962 964 disabled={isPropagatingBlock} 963 attributes={attributes} 965 attributes={attributes} 964 966 updateSelectedCategory={updateCategoryVal} 965 967 ></CategorySelector> … … 993 995 {label: 'Remove existing videos and add this one', value: PROPAGATE_REPLACE_ALL_VIDEOS}, 994 996 {label: 'Add this video without affecting other videos', value: PROPAGATE_ADD_ANYWAY} 995 997 996 998 ] 997 999 } -
humix/trunk/humix.php
r2972825 r3010711 10 10 * 11 11 * @link https://www.humix.com/ 12 * @since 1.2. 012 * @since 1.2.1 13 13 * @package Humix 14 14 * … … 17 17 * Plugin URI: https://wordpress.org/plugins/humix 18 18 * Description: Humix allows you to easily embed videos to your site from the Humix Network. 19 * Version: 1.2. 019 * Version: 1.2.1 20 20 * Author: Humix 21 21 * Author URI: https://www.humix.com/ … … 33 33 * Rename this for your plugin and update it as you release new versions. 34 34 */ 35 define( 'HUMIX_VERSION', '1.2. 0' );35 define( 'HUMIX_VERSION', '1.2.1' ); 36 36 37 37 global $EZHX_REGEX; … … 40 40 global $EZHX_GENERATE_EMBED_CODE_BASE; 41 41 $EZHX_GENERATE_EMBED_CODE_BASE = 'https://www.humix.com/generate-embed-code?j='; 42 43 const EZHX_WORDPRESS_EMBED_CODE_SOURCE = 'w'; 42 44 43 45 function EZHX_add_humix_oembed_provider() { … … 135 137 'preview' => false, 136 138 'autoMatchOption' => 0, 137 'categories' => "" 139 'categories' => "", 140 'embedCodeSource' => EZHX_WORDPRESS_EMBED_CODE_SOURCE, 138 141 ]; 139 142 … … 146 149 'float' => $options['floatOption'], 147 150 'width' => $options['width'], 148 'height' => $options['height'] 151 'height' => $options['height'], 152 'embed_code_source' => $options['embedCodeSource'], 149 153 ]; 150 154
Note: See TracChangeset
for help on using the changeset viewer.