object-boolean-combinations 6.1.0 → 6.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,7 +3,7 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
- # 6.1.0 (2023-05-13)
6
+ ## 6.1.0 (2023-05-13)
7
7
 
8
8
  ### Features
9
9
 
@@ -1,10 +1,10 @@
1
1
  /**
2
2
  * @name object-boolean-combinations
3
3
  * @fileoverview Consumes a defaults object with booleans, generates all possible variations of it
4
- * @version 6.1.0
4
+ * @version 6.1.1
5
5
  * @author Roy Revelt, Codsen Ltd
6
6
  * @license MIT
7
7
  * {@link https://codsen.com/os/object-boolean-combinations/}
8
8
  */
9
9
 
10
- import{pull as g,intersection as O}from"lodash-es";import{isPlainObject as r}from"codsen-utils";import x from"rfdc";var j="6.1.0";var f=x(),T=j;function D(i,c={}){function h(e){let t=[];for(let s=0;s<1<<e;s++){let n=[];for(let m=0;m<e;m++)n.push(s&1<<m?1:0);t.push(n)}return t}if(!i)throw new Error("[THROW_ID_01] missing input object");if(!r(i))throw new Error("[THROW_ID_02] the first input object must be a plain object");if(c&&!r(c))throw new Error("[THROW_ID_03] the second override object must be a plain object");let u=f(i),o=f(c),l=Object.keys(u),p=[],b=[];r(o)&&Object.keys(o).length&&(b=O(Object.keys(o),Object.keys(u)),b.forEach(e=>g(l,e)));let d=h(Object.keys(l).length),a;return d.forEach((e,t)=>{a={},l.forEach((s,n)=>{a[s]=d[t][n]===1}),p.push(a)}),r(o)&&Object.keys(o).length&&p.forEach(e=>{b.forEach(t=>{e[t]=o[t]})}),p}export{D as combinations,T as version};
10
+ import{isPlainObject as i,intersection as g}from"codsen-utils";import O from"rfdc";var j="6.1.1";var f=O(),_=j;function R(c,l={}){function h(e){let t=[];for(let s=0;s<1<<e;s++){let r=[];for(let u=0;u<e;u++)r.push(s&1<<u?1:0);t.push(r)}return t}if(!c)throw new Error("[THROW_ID_01] missing input object");if(!i(c))throw new Error("[THROW_ID_02] the first input object must be a plain object");if(l&&!i(l))throw new Error("[THROW_ID_03] the second override object must be a plain object");let m=f(c),o=f(l),n=Object.keys(m),p=[],b=[];i(o)&&Object.keys(o).length&&(b=g(Object.keys(o),Object.keys(m)),n=n.filter(e=>!b.includes(e)));let d=h(Object.keys(n).length),a;return d.forEach((e,t)=>{a={},n.forEach((s,r)=>{a[s]=d[t][r]===1}),p.push(a)}),i(o)&&Object.keys(o).length&&p.forEach(e=>{b.forEach(t=>{e[t]=o[t]})}),p}export{R as combinations,_ as version};
@@ -1,31 +1,18 @@
1
1
  /**
2
2
  * @name object-boolean-combinations
3
3
  * @fileoverview Consumes a defaults object with booleans, generates all possible variations of it
4
- * @version 6.1.0
4
+ * @version 6.1.1
5
5
  * @author Roy Revelt, Codsen Ltd
6
6
  * @license MIT
7
7
  * {@link https://codsen.com/os/object-boolean-combinations/}
8
8
  */
9
9
 
10
- "use strict";var objectBooleanCombinations=(()=>{var Xe=Object.create;var D=Object.defineProperty;var Ye=Object.getOwnPropertyDescriptor;var et=Object.getOwnPropertyNames;var tt=Object.getPrototypeOf,rt=Object.prototype.hasOwnProperty;var ot=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),at=(e,t)=>{for(var r in t)D(e,r,{get:t[r],enumerable:!0})},U=(e,t,r,a)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of et(t))!rt.call(e,o)&&o!==r&&D(e,o,{get:()=>t[o],enumerable:!(a=Ye(t,o))||a.enumerable});return e};var ft=(e,t,r)=>(r=e!=null?Xe(tt(e)):{},U(t||!e||!e.__esModule?D(r,"default",{value:e,enumerable:!0}):r,e)),st=e=>U(D({},"__esModule",{value:!0}),e);var Ke=ot((xs,ke)=>{"use strict";ke.exports=to;function _(e){return e instanceof Buffer?Buffer.from(e):new e.constructor(e.buffer.slice(),e.byteOffset,e.length)}function to(e){if(e=e||{},e.circles)return ro(e);return e.proto?a:r;function t(o,i){for(var f=Object.keys(o),s=new Array(f.length),l=0;l<f.length;l++){var n=f[l],p=o[n];typeof p!="object"||p===null?s[n]=p:p instanceof Date?s[n]=new Date(p):ArrayBuffer.isView(p)?s[n]=_(p):s[n]=i(p)}return s}function r(o){if(typeof o!="object"||o===null)return o;if(o instanceof Date)return new Date(o);if(Array.isArray(o))return t(o,r);if(o instanceof Map)return new Map(t(Array.from(o),r));if(o instanceof Set)return new Set(t(Array.from(o),r));var i={};for(var f in o)if(Object.hasOwnProperty.call(o,f)!==!1){var s=o[f];typeof s!="object"||s===null?i[f]=s:s instanceof Date?i[f]=new Date(s):s instanceof Map?i[f]=new Map(t(Array.from(s),r)):s instanceof Set?i[f]=new Set(t(Array.from(s),r)):ArrayBuffer.isView(s)?i[f]=_(s):i[f]=r(s)}return i}function a(o){if(typeof o!="object"||o===null)return o;if(o instanceof Date)return new Date(o);if(Array.isArray(o))return t(o,a);if(o instanceof Map)return new Map(t(Array.from(o),a));if(o instanceof Set)return new Set(t(Array.from(o),a));var i={};for(var f in o){var s=o[f];typeof s!="object"||s===null?i[f]=s:s instanceof Date?i[f]=new Date(s):s instanceof Map?i[f]=new Map(t(Array.from(s),a)):s instanceof Set?i[f]=new Set(t(Array.from(s),a)):ArrayBuffer.isView(s)?i[f]=_(s):i[f]=a(s)}return i}}function ro(e){var t=[],r=[];return e.proto?i:o;function a(f,s){for(var l=Object.keys(f),n=new Array(l.length),p=0;p<l.length;p++){var m=l[p],u=f[m];if(typeof u!="object"||u===null)n[m]=u;else if(u instanceof Date)n[m]=new Date(u);else if(ArrayBuffer.isView(u))n[m]=_(u);else{var d=t.indexOf(u);d!==-1?n[m]=r[d]:n[m]=s(u)}}return n}function o(f){if(typeof f!="object"||f===null)return f;if(f instanceof Date)return new Date(f);if(Array.isArray(f))return a(f,o);if(f instanceof Map)return new Map(a(Array.from(f),o));if(f instanceof Set)return new Set(a(Array.from(f),o));var s={};t.push(f),r.push(s);for(var l in f)if(Object.hasOwnProperty.call(f,l)!==!1){var n=f[l];if(typeof n!="object"||n===null)s[l]=n;else if(n instanceof Date)s[l]=new Date(n);else if(n instanceof Map)s[l]=new Map(a(Array.from(n),o));else if(n instanceof Set)s[l]=new Set(a(Array.from(n),o));else if(ArrayBuffer.isView(n))s[l]=_(n);else{var p=t.indexOf(n);p!==-1?s[l]=r[p]:s[l]=o(n)}}return t.pop(),r.pop(),s}function i(f){if(typeof f!="object"||f===null)return f;if(f instanceof Date)return new Date(f);if(Array.isArray(f))return a(f,i);if(f instanceof Map)return new Map(a(Array.from(f),i));if(f instanceof Set)return new Set(a(Array.from(f),i));var s={};t.push(f),r.push(s);for(var l in f){var n=f[l];if(typeof n!="object"||n===null)s[l]=n;else if(n instanceof Date)s[l]=new Date(n);else if(n instanceof Map)s[l]=new Map(a(Array.from(n),i));else if(n instanceof Set)s[l]=new Set(a(Array.from(n),i));else if(ArrayBuffer.isView(n))s[l]=_(n);else{var p=t.indexOf(n);p!==-1?s[l]=r[p]:s[l]=i(n)}}return t.pop(),r.pop(),s}}});var so={};at(so,{combinations:()=>fo,version:()=>ao});var nt=typeof global=="object"&&global&&global.Object===Object&&global,q=nt;var it=typeof self=="object"&&self&&self.Object===Object&&self,lt=q||it||Function("return this")(),g=lt;var pt=g.Symbol,y=pt;var G=Object.prototype,ut=G.hasOwnProperty,mt=G.toString,S=y?y.toStringTag:void 0;function dt(e){var t=ut.call(e,S),r=e[S];try{e[S]=void 0;var a=!0}catch(i){}var o=mt.call(e);return a&&(t?e[S]=r:delete e[S]),o}var V=dt;var xt=Object.prototype,ct=xt.toString;function ht(e){return ct.call(e)}var k=ht;var bt="[object Null]",gt="[object Undefined]",K=y?y.toStringTag:void 0;function yt(e){return e==null?e===void 0?gt:bt:K&&K in Object(e)?V(e):k(e)}var Q=yt;function vt(e){return e!=null&&typeof e=="object"}var J=vt;function wt(e,t){for(var r=-1,a=e==null?0:e.length,o=Array(a);++r<a;)o[r]=t(e[r],r,e);return o}var v=wt;function jt(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var I=jt;function Ot(e){return e}var M=Ot;var At="[object AsyncFunction]",_t="[object Function]",St="[object GeneratorFunction]",Ct="[object Proxy]";function Dt(e){if(!I(e))return!1;var t=Q(e);return t==_t||t==St||t==At||t==Ct}var B=Dt;var It=g["__core-js_shared__"],T=It;var Z=function(){var e=/[^.]+$/.exec(T&&T.keys&&T.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function Mt(e){return!!Z&&Z in e}var X=Mt;var Bt=Function.prototype,Tt=Bt.toString;function Pt(e){if(e!=null){try{return Tt.call(e)}catch(t){}try{return e+""}catch(t){}}return""}var Y=Pt;var Et=/[\\^$.*+?()[\]{}|]/g,Nt=/^\[object .+?Constructor\]$/,Rt=Function.prototype,Lt=Object.prototype,Wt=Rt.toString,Ft=Lt.hasOwnProperty,Ht=RegExp("^"+Wt.call(Ft).replace(Et,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function zt(e){if(!I(e)||X(e))return!1;var t=B(e)?Ht:Nt;return t.test(Y(e))}var ee=zt;function $t(e,t){return e==null?void 0:e[t]}var te=$t;function Ut(e,t){var r=te(e,t);return ee(r)?r:void 0}var w=Ut;function qt(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}var re=qt;function Gt(e,t){var r=-1,a=e.length;for(t||(t=Array(a));++r<a;)t[r]=e[r];return t}var oe=Gt;var Vt=800,kt=16,Kt=Date.now;function Qt(e){var t=0,r=0;return function(){var a=Kt(),o=kt-(a-r);if(r=a,o>0){if(++t>=Vt)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var ae=Qt;function Jt(e){return function(){return e}}var fe=Jt;var Zt=function(){try{var e=w(Object,"defineProperty");return e({},"",{}),e}catch(t){}}(),L=Zt;var Xt=L?function(e,t){return L(e,"toString",{configurable:!0,enumerable:!1,value:fe(t),writable:!0})}:M,se=Xt;var Yt=ae(se),ne=Yt;function er(e,t,r,a){for(var o=e.length,i=r+(a?1:-1);a?i--:++i<o;)if(t(e[i],i,e))return i;return-1}var ie=er;function tr(e){return e!==e}var le=tr;function rr(e,t,r){for(var a=r-1,o=e.length;++a<o;)if(e[a]===t)return a;return-1}var pe=rr;function or(e,t,r){return t===t?pe(e,t,r):ie(e,le,r)}var P=or;function ar(e,t){var r=e==null?0:e.length;return!!r&&P(e,t,0)>-1}var ue=ar;function fr(e,t){return e===t||e!==e&&t!==t}var me=fr;var de=Math.max;function sr(e,t,r){return t=de(t===void 0?e.length-1:t,0),function(){for(var a=arguments,o=-1,i=de(a.length-t,0),f=Array(i);++o<i;)f[o]=a[t+o];o=-1;for(var s=Array(t+1);++o<t;)s[o]=a[o];return s[t]=r(f),re(e,this,s)}}var xe=sr;function nr(e,t){return ne(xe(e,t,M),e+"")}var E=nr;var ir=9007199254740991;function lr(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=ir}var ce=lr;function pr(e){return e!=null&&ce(e.length)&&!B(e)}var he=pr;function ur(e){return function(t){return e(t)}}var N=ur;var mr=w(Object,"create"),c=mr;function dr(){this.__data__=c?c(null):{},this.size=0}var be=dr;function xr(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var ge=xr;var cr="__lodash_hash_undefined__",hr=Object.prototype,br=hr.hasOwnProperty;function gr(e){var t=this.__data__;if(c){var r=t[e];return r===cr?void 0:r}return br.call(t,e)?t[e]:void 0}var ye=gr;var yr=Object.prototype,vr=yr.hasOwnProperty;function wr(e){var t=this.__data__;return c?t[e]!==void 0:vr.call(t,e)}var ve=wr;var jr="__lodash_hash_undefined__";function Or(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=c&&t===void 0?jr:t,this}var we=Or;function j(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var a=e[t];this.set(a[0],a[1])}}j.prototype.clear=be;j.prototype.delete=ge;j.prototype.get=ye;j.prototype.has=ve;j.prototype.set=we;var W=j;function Ar(){this.__data__=[],this.size=0}var je=Ar;function _r(e,t){for(var r=e.length;r--;)if(me(e[r][0],t))return r;return-1}var h=_r;var Sr=Array.prototype,Cr=Sr.splice;function Dr(e){var t=this.__data__,r=h(t,e);if(r<0)return!1;var a=t.length-1;return r==a?t.pop():Cr.call(t,r,1),--this.size,!0}var Oe=Dr;function Ir(e){var t=this.__data__,r=h(t,e);return r<0?void 0:t[r][1]}var Ae=Ir;function Mr(e){return h(this.__data__,e)>-1}var _e=Mr;function Br(e,t){var r=this.__data__,a=h(r,e);return a<0?(++this.size,r.push([e,t])):r[a][1]=t,this}var Se=Br;function O(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var a=e[t];this.set(a[0],a[1])}}O.prototype.clear=je;O.prototype.delete=Oe;O.prototype.get=Ae;O.prototype.has=_e;O.prototype.set=Se;var Ce=O;var Tr=w(g,"Map"),De=Tr;function Pr(){this.size=0,this.__data__={hash:new W,map:new(De||Ce),string:new W}}var Ie=Pr;function Er(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var Me=Er;function Nr(e,t){var r=e.__data__;return Me(t)?r[typeof t=="string"?"string":"hash"]:r.map}var b=Nr;function Rr(e){var t=b(this,e).delete(e);return this.size-=t?1:0,t}var Be=Rr;function Lr(e){return b(this,e).get(e)}var Te=Lr;function Wr(e){return b(this,e).has(e)}var Pe=Wr;function Fr(e,t){var r=b(this,e),a=r.size;return r.set(e,t),this.size+=r.size==a?0:1,this}var Ee=Fr;function A(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var a=e[t];this.set(a[0],a[1])}}A.prototype.clear=Ie;A.prototype.delete=Be;A.prototype.get=Te;A.prototype.has=Pe;A.prototype.set=Ee;var Ne=A;var Hr="__lodash_hash_undefined__";function zr(e){return this.__data__.set(e,Hr),this}var Re=zr;function $r(e){return this.__data__.has(e)}var Le=$r;function R(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new Ne;++t<r;)this.add(e[t])}R.prototype.add=R.prototype.push=Re;R.prototype.has=Le;var We=R;function Ur(e,t){return e.has(t)}var F=Ur;function qr(e){return J(e)&&he(e)}var Fe=qr;function Gr(e,t,r){for(var a=-1,o=e==null?0:e.length;++a<o;)if(r(t,e[a]))return!0;return!1}var He=Gr;var Vr=Math.min;function kr(e,t,r){for(var a=r?He:ue,o=e[0].length,i=e.length,f=i,s=Array(i),l=1/0,n=[];f--;){var p=e[f];f&&t&&(p=v(p,N(t))),l=Vr(p.length,l),s[f]=!r&&(t||o>=120&&p.length>=120)?new We(f&&p):void 0}p=e[0];var m=-1,u=s[0];e:for(;++m<o&&n.length<l;){var d=p[m],x=t?t(d):d;if(d=r||d!==0?d:0,!(u?F(u,x):a(n,x,r))){for(f=i;--f;){var $=s[f];if(!($?F($,x):a(e[f],x,r)))continue e}u&&u.push(x),n.push(d)}}return n}var ze=kr;function Kr(e){return Fe(e)?e:[]}var $e=Kr;var Qr=E(function(e){var t=v(e,$e);return t.length&&t[0]===e[0]?ze(t):[]}),H=Qr;function Jr(e,t,r,a){for(var o=r-1,i=e.length;++o<i;)if(a(e[o],t))return o;return-1}var Ue=Jr;var Zr=Array.prototype,qe=Zr.splice;function Xr(e,t,r,a){var o=a?Ue:P,i=-1,f=t.length,s=e;for(e===t&&(t=oe(t)),r&&(s=v(e,N(r)));++i<f;)for(var l=0,n=t[i],p=r?r(n):n;(l=o(s,p,l,a))>-1;)s!==e&&qe.call(s,l,1),qe.call(e,l,1);return e}var Ge=Xr;function Yr(e,t){return e&&e.length&&t&&t.length?Ge(e,t):e}var Ve=Yr;var eo=E(Ve),z=eo;function C(e){if(e==null||typeof e!="object")return!1;let t=Object.getPrototypeOf(e);return t!==null&&t!==Object.prototype&&Object.getPrototypeOf(t)!==null?!1:!(Symbol.iterator in e)&&!(Symbol.toStringTag in e)}var Ze=ft(Ke(),1);var Qe="6.1.0";var Je=(0,Ze.default)(),ao=Qe;function fo(e,t={}){function r(p){let m=[];for(let u=0;u<1<<p;u++){let d=[];for(let x=0;x<p;x++)d.push(u&1<<x?1:0);m.push(d)}return m}if(!e)throw new Error("[THROW_ID_01] missing input object");if(!C(e))throw new Error("[THROW_ID_02] the first input object must be a plain object");if(t&&!C(t))throw new Error("[THROW_ID_03] the second override object must be a plain object");let a=Je(e),o=Je(t),i=Object.keys(a),f=[],s=[];C(o)&&Object.keys(o).length&&(s=H(Object.keys(o),Object.keys(a)),s.forEach(p=>z(i,p)));let l=r(Object.keys(i).length),n;return l.forEach((p,m)=>{n={},i.forEach((u,d)=>{n[u]=l[m][d]===1}),f.push(n)}),C(o)&&Object.keys(o).length&&f.forEach(p=>{s.forEach(m=>{p[m]=o[m]})}),f}return st(so);})();
10
+ "use strict";var objectBooleanCombinations=(()=>{var C=Object.create;var d=Object.defineProperty;var B=Object.getOwnPropertyDescriptor;var M=Object.getOwnPropertyNames;var E=Object.getPrototypeOf,R=Object.prototype.hasOwnProperty;var T=(i,r)=>()=>(r||i((r={exports:{}}).exports,r),r.exports),$=(i,r)=>{for(var f in r)d(i,f,{get:r[f],enumerable:!0})},A=(i,r,f,u)=>{if(r&&typeof r=="object"||typeof r=="function")for(let n of M(r))!R.call(i,n)&&n!==f&&d(i,n,{get:()=>r[n],enumerable:!(u=B(r,n))||u.enumerable});return i};var g=(i,r,f)=>(f=i!=null?C(E(i)):{},A(r||!i||!i.__esModule?d(f,"default",{value:i,enumerable:!0}):f,i)),L=i=>A(d({},"__esModule",{value:!0}),i);var w=T((W,j)=>{"use strict";j.exports=P;function m(i){return i instanceof Buffer?Buffer.from(i):new i.constructor(i.buffer.slice(),i.byteOffset,i.length)}function P(i){if(i=i||{},i.circles)return F(i);return i.proto?u:f;function r(n,a){for(var e=Object.keys(n),t=new Array(e.length),o=0;o<e.length;o++){var s=e[o],l=n[s];typeof l!="object"||l===null?t[s]=l:l instanceof Date?t[s]=new Date(l):ArrayBuffer.isView(l)?t[s]=m(l):t[s]=a(l)}return t}function f(n){if(typeof n!="object"||n===null)return n;if(n instanceof Date)return new Date(n);if(Array.isArray(n))return r(n,f);if(n instanceof Map)return new Map(r(Array.from(n),f));if(n instanceof Set)return new Set(r(Array.from(n),f));var a={};for(var e in n)if(Object.hasOwnProperty.call(n,e)!==!1){var t=n[e];typeof t!="object"||t===null?a[e]=t:t instanceof Date?a[e]=new Date(t):t instanceof Map?a[e]=new Map(r(Array.from(t),f)):t instanceof Set?a[e]=new Set(r(Array.from(t),f)):ArrayBuffer.isView(t)?a[e]=m(t):a[e]=f(t)}return a}function u(n){if(typeof n!="object"||n===null)return n;if(n instanceof Date)return new Date(n);if(Array.isArray(n))return r(n,u);if(n instanceof Map)return new Map(r(Array.from(n),u));if(n instanceof Set)return new Set(r(Array.from(n),u));var a={};for(var e in n){var t=n[e];typeof t!="object"||t===null?a[e]=t:t instanceof Date?a[e]=new Date(t):t instanceof Map?a[e]=new Map(r(Array.from(t),u)):t instanceof Set?a[e]=new Set(r(Array.from(t),u)):ArrayBuffer.isView(t)?a[e]=m(t):a[e]=u(t)}return a}}function F(i){var r=[],f=[];return i.proto?a:n;function u(e,t){for(var o=Object.keys(e),s=new Array(o.length),l=0;l<o.length;l++){var p=o[l],c=e[p];if(typeof c!="object"||c===null)s[p]=c;else if(c instanceof Date)s[p]=new Date(c);else if(ArrayBuffer.isView(c))s[p]=m(c);else{var b=r.indexOf(c);b!==-1?s[p]=f[b]:s[p]=t(c)}}return s}function n(e){if(typeof e!="object"||e===null)return e;if(e instanceof Date)return new Date(e);if(Array.isArray(e))return u(e,n);if(e instanceof Map)return new Map(u(Array.from(e),n));if(e instanceof Set)return new Set(u(Array.from(e),n));var t={};r.push(e),f.push(t);for(var o in e)if(Object.hasOwnProperty.call(e,o)!==!1){var s=e[o];if(typeof s!="object"||s===null)t[o]=s;else if(s instanceof Date)t[o]=new Date(s);else if(s instanceof Map)t[o]=new Map(u(Array.from(s),n));else if(s instanceof Set)t[o]=new Set(u(Array.from(s),n));else if(ArrayBuffer.isView(s))t[o]=m(s);else{var l=r.indexOf(s);l!==-1?t[o]=f[l]:t[o]=n(s)}}return r.pop(),f.pop(),t}function a(e){if(typeof e!="object"||e===null)return e;if(e instanceof Date)return new Date(e);if(Array.isArray(e))return u(e,a);if(e instanceof Map)return new Map(u(Array.from(e),a));if(e instanceof Set)return new Set(u(Array.from(e),a));var t={};r.push(e),f.push(t);for(var o in e){var s=e[o];if(typeof s!="object"||s===null)t[o]=s;else if(s instanceof Date)t[o]=new Date(s);else if(s instanceof Map)t[o]=new Map(u(Array.from(s),a));else if(s instanceof Set)t[o]=new Set(u(Array.from(s),a));else if(ArrayBuffer.isView(s))t[o]=m(s);else{var l=r.indexOf(s);l!==-1?t[o]=f[l]:t[o]=a(s)}}return r.pop(),f.pop(),t}}});var V={};$(V,{combinations:()=>_,version:()=>I});var v=g(w(),1);var H=(0,v.default)();function y(i){if(i==null||typeof i!="object")return!1;let r=Object.getPrototypeOf(i);return r!==null&&r!==Object.prototype&&Object.getPrototypeOf(r)!==null?!1:!(Symbol.iterator in i)&&!(Symbol.toStringTag in i)}function O(i=[],r=[]){return!i||!r?[]:Array.from(new Set(Array.from(i).filter(f=>new Set(r).has(f))))}var x=g(w(),1);var D="6.1.1";var S=(0,x.default)(),I=D;function _(i,r={}){function f(l){let p=[];for(let c=0;c<1<<l;c++){let b=[];for(let h=0;h<l;h++)b.push(c&1<<h?1:0);p.push(b)}return p}if(!i)throw new Error("[THROW_ID_01] missing input object");if(!y(i))throw new Error("[THROW_ID_02] the first input object must be a plain object");if(r&&!y(r))throw new Error("[THROW_ID_03] the second override object must be a plain object");let u=S(i),n=S(r),a=Object.keys(u),e=[],t=[];y(n)&&Object.keys(n).length&&(t=O(Object.keys(n),Object.keys(u)),a=a.filter(l=>!t.includes(l)));let o=f(Object.keys(a).length),s;return o.forEach((l,p)=>{s={},a.forEach((c,b)=>{s[c]=o[p][b]===1}),e.push(s)}),y(n)&&Object.keys(n).length&&e.forEach(l=>{t.forEach(p=>{l[p]=n[p]})}),e}return L(V);})();
11
11
  /**
12
12
  * @name codsen-utils
13
13
  * @fileoverview Various utility functions
14
- * @version 1.5.0
14
+ * @version 1.6.0
15
15
  * @author Roy Revelt, Codsen Ltd
16
16
  * @license MIT
17
17
  * {@link https://codsen.com/os/codsen-utils/}
18
18
  */
19
- /*! Bundled license information:
20
-
21
- lodash-es/lodash.js:
22
- (**
23
- * @license
24
- * Lodash (Custom Build) <https://lodash.com/>
25
- * Build: `lodash modularize exports="es" -o ./`
26
- * Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
27
- * Released under MIT license <https://lodash.com/license>
28
- * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
29
- * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
30
- *)
31
- */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "object-boolean-combinations",
3
- "version": "6.1.0",
3
+ "version": "6.1.1",
4
4
  "description": "Consumes a defaults object with booleans, generates all possible variations of it",
5
5
  "keywords": [
6
6
  "all",
@@ -67,9 +67,7 @@
67
67
  }
68
68
  },
69
69
  "dependencies": {
70
- "@types/lodash-es": "^4.17.7",
71
- "codsen-utils": "^1.5.0",
72
- "lodash-es": "^4.17.21",
70
+ "codsen-utils": "^1.6.0",
73
71
  "rfdc": "^1.3.0"
74
72
  }
75
73
  }