!function(o, e) { "object" == typeof exports && "undefined" != typeof module ? e(exports, require("loop-colors"), require("colord"), require("@lazy-color/rand-util")) : "function" == typeof define && define.amd ? define([ "exports", "loop-colors", "colord", "@lazy-color/rand-util" ], e) : e((o = "undefined" != typeof globalThis ? globalThis : o || self).ColordRandLoop = {}, o.loopColors, o.colord, o.randUtil); }(this, (function(o, e, r, l) { "use strict"; function createDefaultGenerator({cache: o, ...e}) { var t; return null !== (t = o) && void 0 !== t || (o = new Set), (t, d) => { let n = r.colord(t[d]); n.isValid() || (n = "function" == typeof e.randFn ? r.colord(l._rgbObjectRand(null, e)) : r.random()); const a = n.toRgb(); let c = 0, u = n; for (;o.has(u.toRgbString()); ) c > 5 && (o.clear(), c = 0), u = r.colord(l._rgbObjectRand(a, e)), c++; return o.add(u.toRgbString()), u; }; } function createColordRandLoop(o) { var r, l, t; let {colors: d, cache: n, ...a} = { ...o }; return null !== (r = d) && void 0 !== r || (d = e.cssColors()), null !== (l = n) && void 0 !== l || (n = new Set), null !== (t = a.generator) && void 0 !== t || (a.generator = createDefaultGenerator({ cache: n })), e.loopColors(d, a); } function colordRandLoop(o, e) { return createColordRandLoop(e)(o); } Object.defineProperty(colordRandLoop, "__esModule", { value: !0 }), Object.defineProperty(colordRandLoop, "colordRandLoop", { value: colordRandLoop }), Object.defineProperty(colordRandLoop, "default", { value: colordRandLoop }), Object.defineProperty(colordRandLoop, "createDefaultGenerator", { value: createDefaultGenerator }), Object.defineProperty(colordRandLoop, "createColordRandLoop", { value: createColordRandLoop }), o.colordRandLoop = colordRandLoop, o.createColordRandLoop = createColordRandLoop, o.createDefaultGenerator = createDefaultGenerator, o.default = colordRandLoop, Object.defineProperty(o, "__esModule", { value: !0 }); })); //# sourceMappingURL=index.umd.production.min.cjs.map