'use strict';var chunkIHOZOJHA_cjs=require('../chunk-IHOZOJHA.cjs');require('../chunk-X5FCFNQN.cjs'),require('../chunk-GYCEEHZT.cjs');var chunkEXPXWBLP_cjs=require('../chunk-EXPXWBLP.cjs');var $=(n,m,z)=>{n.prototype.toLab=function(){let{l:r,a,b:o,alpha:t}=chunkIHOZOJHA_cjs.e(this._rawRgb());return {l:chunkEXPXWBLP_cjs.b(r,2),a:chunkEXPXWBLP_cjs.b(a,2)||0,b:chunkEXPXWBLP_cjs.b(o,2)||0,alpha:t,colorSpace:"lab"}},n.prototype.toLabString=function(){let{l:r,a,b:o,alpha:t}=this.toLab();return t<1?`lab(${r}% ${a} ${o} / ${t})`:`lab(${r}% ${a} ${o})`},n.prototype.toXyz=function(){let{x:r,y:a,z:o,alpha:t}=chunkIHOZOJHA_cjs.a(this._rawRgb());return {x:chunkEXPXWBLP_cjs.b(r,2),y:chunkEXPXWBLP_cjs.b(a,2),z:chunkEXPXWBLP_cjs.b(o,2),alpha:t}},n.prototype.toXyzString=function(){let{x:r,y:a,z:o,alpha:t}=this.toXyz();return t<1?`color(xyz-d65 ${r} ${a} ${o} / ${t})`:`color(xyz-d65 ${r} ${a} ${o})`},n.prototype.mixLab=function(r,a=.5){let o=chunkIHOZOJHA_cjs.e(this._rawRgb()),t=chunkIHOZOJHA_cjs.e(new n(r)._rawRgb()),l=chunkEXPXWBLP_cjs.a(a,0,1);return new n(chunkIHOZOJHA_cjs.h({l:o.l*(1-l)+t.l*l,a:o.a*(1-l)+t.a*l,b:o.b*(1-l)+t.b*l,alpha:chunkEXPXWBLP_cjs.b(o.alpha*(1-l)+t.alpha*l,3),colorSpace:"lab"}))},n.prototype.delta=function(r="#fff"){return chunkEXPXWBLP_cjs.b(chunkIHOZOJHA_cjs.g(chunkIHOZOJHA_cjs.f(this._rawRgb()),chunkIHOZOJHA_cjs.f(new n(r)._rawRgb()))/100,3)},m.push(chunkIHOZOJHA_cjs.i,chunkIHOZOJHA_cjs.j,chunkIHOZOJHA_cjs.c),z.push([chunkIHOZOJHA_cjs.i,"lab"],[chunkIHOZOJHA_cjs.j,"lab"],[chunkIHOZOJHA_cjs.c,"xyz"]);},w=$;module.exports=w;//# sourceMappingURL=lab.cjs.map
//# sourceMappingURL=lab.cjs.map