define(["require","exports","../.chunks/field-Cvv0SRcJ.amd"],(function(f,a,c){"use strict";if(typeof N>"u")var N=window.Vue;const o=t=>{const e=[];return Object.keys(t).forEach(r=>{const s=r,n=t[s];if(n===void 0)return;let i;s==="tags_ids"||s==="tags"?l(s,e,n):typeof n=="string"||typeof n=="number"||typeof n=="boolean"?i=u(s,n):(Array.isArray(n)||n instanceof Set)&&(i=b(s,n)),i&&e.push(i)}),e},g=t=>{let e=t,r="EQUALS",s;switch((t[1]===":"||t[2]===":")&&([s,e]=t.split(":")),s){case">":r="GREATER_THAN",e=Number(e);break;case">=":r="GREATER_THAN_EQUALS",e=Number(e);break;case"<":r="LESS_THAN",e=Number(e);break;case"<=":r="LESS_THAN_EQUALS",e=Number(e);break;case"!=":r="NOT_EQUALS",e.match(/^\d+$/)&&(e=Number(e));break;case"%":r="CONTAINS";break;case"!%":r="DOES_NOT_CONTAIN";break;case"^":r="STARTS_WITH";break;case"null":r="IS_NULL";break;case"!null":r="IS_NOT_NULL";break;case"~":r="REGEXP";break;case"!~":r="NOT_REGEXP";break}return{value:e,operator:r}},l=(t,e,r)=>{const s=[],n=[];r.forEach(i=>{i[0]==="-"?n.push(i.substring(1)):s.push(i)}),s.length&&e.push(c.genFieldFilter(t,"IN",s)),n.length&&e.push(c.genFieldFilter(t,"NOT_IN",n))},u=(t,e)=>{let r=e,s="EQUALS";return typeof e=="string"&&({value:r,operator:s}=g(e)),typeof r=="boolean"&&(r=r?1:0),c.genFieldFilter(t,s,[r])},b=(t,e)=>c.genFieldFilter(t,"IN",Array.isArray(e)?e:[...e]);a.genFilterIn=b,a.genFilterPrimitive=u,a.genFilters=o,a.pushFilterTagsIds=l,Object.defineProperty(a,Symbol.toStringTag,{value:"Module"})}));
//# sourceMappingURL=additional.amd.js.map
