531 lines
32 KiB
JavaScript
531 lines
32 KiB
JavaScript
/* Metro module 1778; source: unknown; dependencies: [1779, 1653, 1780, 1621, 1762, 1654] */
|
|
import Module01780 from './module-01780.js'; /* Metro dependency 1780 */
|
|
import * as Module01621Module from './module-01621.js'; /* Metro dependency 1621 */
|
|
import * as Module01653Module from './module-01653.js'; /* Metro dependency 1653 */
|
|
import * as UseSharedValueModule from './module-01762-useSharedValue.js'; /* Metro dependency 1762 */
|
|
import * as Module01779Module from './module-01779.js'; /* Metro dependency 1779 */
|
|
|
|
function _fun19574(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#19574, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:6, offset: 0x00eadbb2, size: 1005 bytes, params: 8, frame: 24
|
|
let env0_0 = require;
|
|
const Object = global.Object;
|
|
Object.defineProperty(exports, '__esModule', {value: true});
|
|
let closure = pnpm_interpolateColorTs1;
|
|
const object2 = {};
|
|
const interpolate = (Module01779Module).interpolate;
|
|
object2.interpolate = interpolate;
|
|
const Extrapolation = (Module01779Module).Extrapolation;
|
|
object2.Extrapolation = Extrapolation;
|
|
object2.hsvToColor = (require(1653) /* metro dependency 1653 */).hsvToColor;
|
|
closure.__closure = object2;
|
|
closure.__workletHash = 1574790978150;
|
|
closure.__initData = {code: 'function pnpm_interpolateColorTs1(value,inputRange,colors,options){const{interpolate,Extrapolation,hsvToColor}=this.__closure;let h=0;const{useCorrectedHSVInterpolation=true}=options;if(useCorrectedHSVInterpolation){const correctedInputRange=[inputRange[0]];const originalH=colors.h;const correctedH=[originalH[0]];for(let i=1;i<originalH.length;++i){const d=originalH[i]-originalH[i-1];if(originalH[i]>originalH[i-1]&&d>0.5){correctedInputRange.push(inputRange[i]);correctedInputRange.push(inputRange[i]+0.00001);correctedH.push(originalH[i]-1);correctedH.push(originalH[i]);}else if(originalH[i]<originalH[i-1]&&d<-0.5){correctedInputRange.push(inputRange[i]);correctedInputRange.push(inputRange[i]+0.00001);correctedH.push(originalH[i]+1);correctedH.push(originalH[i]);}else{correctedInputRange.push(inputRange[i]);correctedH.push(originalH[i]);}}h=(interpolate(value,correctedInputRange,correctedH,Extrapolation.CLAMP)+1)%1;}else{h=interpolate(value,inputRange,colors.h,Extrapolation.CLAMP);}const s=interpolate(value,inputRange,colors.s,Extrapolation.CLAMP);const v=interpolate(value,inputRange,colors.v,Extrapolation.CLAMP);const a=interpolate(value,inputRange,colors.a,Extrapolation.CLAMP);return hsvToColor(h,s,v,a);}'};
|
|
closure = function(a0, a1) {
|
|
var env0_0 = a1;
|
|
return a0.map(_fun19577);
|
|
};
|
|
closure.__closure = {};
|
|
closure.__workletHash = 16826369876333;
|
|
closure.__initData = {code: 'function pnpm_interpolateColorTs2(x,gamma){return x.map(function(v){return Math.pow(v/255,gamma);});}'};
|
|
const closure2 = function(a0, a1) {
|
|
var Math = global.Math;
|
|
var Math2 = global.Math;
|
|
return Math.round(255 * Math2.pow(a0, 1 / a1));
|
|
};
|
|
closure2.__closure = {};
|
|
closure2.__workletHash = 5856560656141;
|
|
closure2.__initData = {code: 'function pnpm_interpolateColorTs3(x,gamma){return Math.round(Math.pow(x,1/gamma)*255);}'};
|
|
const pnpm_interpolateColorTs42 = pnpm_interpolateColorTs4;
|
|
const object3 = {toLinearSpace: closure};
|
|
object3.interpolate = interpolate;
|
|
object3.Extrapolation = Extrapolation;
|
|
const rgbaColor = (require(1653) /* metro dependency 1653 */).rgbaColor;
|
|
object3.rgbaColor = rgbaColor;
|
|
object3.toGammaSpace = closure2;
|
|
pnpm_interpolateColorTs42.__closure = object3;
|
|
pnpm_interpolateColorTs42.__workletHash = 13883480600753;
|
|
pnpm_interpolateColorTs42.__initData = {code: 'function pnpm_interpolateColorTs4(value,inputRange,colors,options){const{toLinearSpace,interpolate,Extrapolation,rgbaColor,toGammaSpace}=this.__closure;const{gamma=2.2}=options;let{r:outputR,g:outputG,b:outputB}=colors;if(gamma!==1){outputR=toLinearSpace(outputR,gamma);outputG=toLinearSpace(outputG,gamma);outputB=toLinearSpace(outputB,gamma);}const r=interpolate(value,inputRange,outputR,Extrapolation.CLAMP);const g=interpolate(value,inputRange,outputG,Extrapolation.CLAMP);const b=interpolate(value,inputRange,outputB,Extrapolation.CLAMP);const a=interpolate(value,inputRange,colors.a,Extrapolation.CLAMP);if(gamma===1){return rgbaColor(r,g,b,a);}return rgbaColor(toGammaSpace(r,gamma),toGammaSpace(g,gamma),toGammaSpace(b,gamma),a);}'};
|
|
closure = pnpm_interpolateColorTs5;
|
|
const object4 = {};
|
|
object4.interpolate = interpolate;
|
|
object4.Extrapolation = Extrapolation;
|
|
object4.culori = importDefault(1780) /* metro dependency 1780 */;
|
|
object4.rgbaColor = rgbaColor;
|
|
closure.__closure = object4;
|
|
closure.__workletHash = 7788654685113;
|
|
closure.__initData = {code: 'function pnpm_interpolateColorTs5(value,inputRange,colors,_options){const{interpolate,Extrapolation,culori,rgbaColor}=this.__closure;const l=interpolate(value,inputRange,colors.l,Extrapolation.CLAMP);const a=interpolate(value,inputRange,colors.a,Extrapolation.CLAMP);const b=interpolate(value,inputRange,colors.b,Extrapolation.CLAMP);const alpha=interpolate(value,inputRange,colors.alpha,Extrapolation.CLAMP);const{r:_r,g:_g,b:_b,alpha:_alpha}=culori.oklab.convert.toRgb({l:l,a:a,b:b,alpha:alpha});return rgbaColor(_r,_g,_b,_alpha);}'};
|
|
closure = _splitColorsIntoChannels;
|
|
const object5 = {};
|
|
object5.processColor = (require(1653) /* metro dependency 1653 */).processColor;
|
|
object5.red = (require(1653) /* metro dependency 1653 */).red;
|
|
object5.green = (require(1653) /* metro dependency 1653 */).green;
|
|
object5.blue = (require(1653) /* metro dependency 1653 */).blue;
|
|
object5.opacity = (require(1653) /* metro dependency 1653 */).opacity;
|
|
closure.__closure = object5;
|
|
closure.__workletHash = 8764168362190;
|
|
closure.__initData = {code: "function pnpm_interpolateColorTs6(colors,convFromRgb){const{processColor,red,green,blue,opacity}=this.__closure;const ch1=[];const ch2=[];const ch3=[];const alpha=[];for(let i=0;i<colors.length;i++){const color=colors[i];const processedColor=processColor(color);if(typeof processedColor==='number'){const convertedColor=convFromRgb({r:red(processedColor),g:green(processedColor),b:blue(processedColor)});ch1.push(convertedColor.ch1);ch2.push(convertedColor.ch2);ch3.push(convertedColor.ch3);alpha.push(opacity(processedColor));}}return{ch1:ch1,ch2:ch2,ch3:ch3,alpha:alpha};}"};
|
|
const pnpm_interpolateColorTs72 = pnpm_interpolateColorTs7;
|
|
pnpm_interpolateColorTs72.__closure = {_splitColorsIntoChannels: closure};
|
|
pnpm_interpolateColorTs72.__workletHash = 937749076324;
|
|
pnpm_interpolateColorTs72.__initData = {code: 'function pnpm_interpolateColorTs7(colors){const{_splitColorsIntoChannels}=this.__closure;const{ch1:ch1,ch2:ch2,ch3:ch3,alpha:alpha}=_splitColorsIntoChannels(colors,function(color){return{ch1:color.r,ch2:color.g,ch3:color.b};});return{r:ch1,g:ch2,b:ch3,a:alpha};}'};
|
|
const pnpm_interpolateColorTs82 = pnpm_interpolateColorTs8;
|
|
const object7 = {_splitColorsIntoChannels: closure};
|
|
const RGBtoHSV = (require(1653) /* metro dependency 1653 */).RGBtoHSV;
|
|
object7.RGBtoHSV = RGBtoHSV;
|
|
pnpm_interpolateColorTs82.__closure = object7;
|
|
pnpm_interpolateColorTs82.__workletHash = 11798906675452;
|
|
pnpm_interpolateColorTs82.__initData = {code: 'function pnpm_interpolateColorTs8(colors){const{_splitColorsIntoChannels,RGBtoHSV}=this.__closure;const{ch1:ch1,ch2:ch2,ch3:ch3,alpha:alpha}=_splitColorsIntoChannels(colors,function(color){const hsvColor=RGBtoHSV(color.r,color.g,color.b);return{ch1:hsvColor.h,ch2:hsvColor.s,ch3:hsvColor.v};});return{h:ch1,s:ch2,v:ch3,a:alpha};}'};
|
|
const pnpm_interpolateColorTs92 = pnpm_interpolateColorTs9;
|
|
pnpm_interpolateColorTs92.__closure = {_splitColorsIntoChannels: closure,
|
|
culori: importDefault(1780) /* metro dependency 1780 */};
|
|
pnpm_interpolateColorTs92.__workletHash = 11214827752418;
|
|
pnpm_interpolateColorTs92.__initData = {code: 'function pnpm_interpolateColorTs9(colors){const{_splitColorsIntoChannels,culori}=this.__closure;const{ch1:ch1,ch2:ch2,ch3:ch3,alpha:alpha}=_splitColorsIntoChannels(colors,function(color){const labColor=culori.oklab.convert.fromRgb(color);return{ch1:labColor.l,ch2:labColor.a,ch3:labColor.b};});return{l:ch1,a:ch2,b:ch3,alpha:alpha};}'};
|
|
object = {code: 'function interpolateColor_Pnpm_interpolateColorTs10(value,inputRange,outputRange,colorSpace=\'RGB\',options={}){const{interpolateColorsHSV,getInterpolateHSV,interpolateColorsRGB,getInterpolateRGB,interpolateColorsLAB,getInterpolateLAB}=this.__closure;if(colorSpace===\'HSV\'){return interpolateColorsHSV(value,inputRange,getInterpolateHSV(outputRange),options);}else if(colorSpace===\'RGB\'){return interpolateColorsRGB(value,inputRange,getInterpolateRGB(outputRange),options);}else if(colorSpace===\'LAB\'){return interpolateColorsLAB(value,inputRange,getInterpolateLAB(outputRange),options);}throw new ReanimatedError("Invalid color space provided: "+colorSpace+". Supported values are: [\'RGB\', \'HSV\', \'LAB\'].");}'};
|
|
const value = _fun19588();
|
|
object = {RGB: 0};
|
|
object[0] = 'RGB';
|
|
object.HSV = 1;
|
|
object[1] = 'HSV';
|
|
object.LAB = 2;
|
|
object[2] = 'LAB';
|
|
exports.Extrapolate = Extrapolation;
|
|
exports.interpolateColor = value;
|
|
exports.ColorSpace = object;
|
|
exports.useInterpolateConfig = useInterpolateConfig;
|
|
function pnpm_interpolateColorTs1(a0, a1, a2, {useCorrectedHSVInterpolation}) { // fn#19575, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:1364, offset: 0x00eadf9f, size: 699 bytes, params: 5, frame: 28
|
|
var r3;
|
|
var r5;
|
|
var value;
|
|
var interpolate;
|
|
var h;
|
|
const Extrapolation = (require(1779) /* metro dependency 1779 */).Extrapolation;
|
|
var CLAMP;
|
|
var property;
|
|
var items3;
|
|
var items2;
|
|
var length;
|
|
var value2;
|
|
var push;
|
|
var value3;
|
|
var value4;
|
|
var moduleValue;
|
|
reducibleJoin13: while (true) {
|
|
reducibleJoin12: while (true) {
|
|
if (useCorrectedHSVInterpolation === undefined) {
|
|
property = a1[0];
|
|
items3 = [property];
|
|
h = a2.h;
|
|
property = h[0];
|
|
items2 = [property];
|
|
length = h.length;
|
|
value = 1;
|
|
if (!(value < length)) {
|
|
break reducibleJoin12;
|
|
}
|
|
r3 = value;
|
|
reducibleLoop4: while (true) {
|
|
property = h[r3];
|
|
value2 = property - h[r3 - value];
|
|
property = h[r3];
|
|
reducibleJoin11: while (true) {
|
|
reducibleJoin8: while (true) {
|
|
if (property > h[r3 - value]) {
|
|
if (value2 > 0.5) {
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3]]);
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3] + 0.00001]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3] - value]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3]]);
|
|
break reducibleJoin11;
|
|
}
|
|
if (h[r3] < h[r3 - value]) {
|
|
if (value2 < -0.5) {
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3]]);
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3] + 0.00001]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3] + value]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3]]);
|
|
break reducibleJoin11;
|
|
}
|
|
break reducibleJoin8;
|
|
}
|
|
break reducibleJoin8;
|
|
}
|
|
property = h[r3];
|
|
if (property < h[r3 - value]) {
|
|
if (value2 < -0.5) {
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3]]);
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3] + 0.00001]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3] + value]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3]]);
|
|
break reducibleJoin11;
|
|
}
|
|
break reducibleJoin8;
|
|
}
|
|
break reducibleJoin8;
|
|
}
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3]]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3]]);
|
|
break reducibleJoin11;
|
|
}
|
|
value3 = typeof r3 === 'bigint' ? r3 + 1n : +r3 + 1;
|
|
length = h.length;
|
|
if (value3 < length) {
|
|
r3 = value3;
|
|
continue reducibleLoop4;
|
|
}
|
|
break reducibleJoin12;
|
|
}
|
|
} else {
|
|
if (!useCorrectedHSVInterpolation) {
|
|
value = environment;
|
|
value = require(1779) /* metro dependency 1779 */;
|
|
interpolate = value.interpolate;
|
|
h = a2.h;
|
|
CLAMP = Extrapolation.CLAMP;
|
|
value = Reflect.apply(interpolate, value, [a0, a1, h, CLAMP]);
|
|
r5 = value;
|
|
break reducibleJoin13;
|
|
}
|
|
property = a1[0];
|
|
items3 = [property];
|
|
h = a2.h;
|
|
property = h[0];
|
|
items2 = [property];
|
|
length = h.length;
|
|
value = 1;
|
|
if (!(value < length)) {
|
|
break reducibleJoin12;
|
|
}
|
|
r3 = value;
|
|
reducibleLoop4: while (true) {
|
|
property = h[r3];
|
|
value2 = property - h[r3 - value];
|
|
property = h[r3];
|
|
reducibleJoin11: while (true) {
|
|
reducibleJoin8: while (true) {
|
|
if (property > h[r3 - value]) {
|
|
if (value2 > 0.5) {
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3]]);
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3] + 0.00001]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3] - value]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3]]);
|
|
break reducibleJoin11;
|
|
}
|
|
if (h[r3] < h[r3 - value]) {
|
|
if (value2 < -0.5) {
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3]]);
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3] + 0.00001]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3] + value]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3]]);
|
|
break reducibleJoin11;
|
|
}
|
|
break reducibleJoin8;
|
|
}
|
|
break reducibleJoin8;
|
|
}
|
|
property = h[r3];
|
|
if (property < h[r3 - value]) {
|
|
if (value2 < -0.5) {
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3]]);
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3] + 0.00001]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3] + value]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3]]);
|
|
break reducibleJoin11;
|
|
}
|
|
break reducibleJoin8;
|
|
}
|
|
break reducibleJoin8;
|
|
}
|
|
push = items3.push;
|
|
Reflect.apply(push, items3, [a1[r3]]);
|
|
push = items2.push;
|
|
Reflect.apply(push, items2, [h[r3]]);
|
|
break reducibleJoin11;
|
|
}
|
|
value3 = typeof r3 === 'bigint' ? r3 + 1n : +r3 + 1;
|
|
length = h.length;
|
|
if (value3 < length) {
|
|
r3 = value3;
|
|
continue reducibleLoop4;
|
|
}
|
|
break reducibleJoin12;
|
|
}
|
|
}
|
|
}
|
|
value4 = environment;
|
|
moduleValue = require(1779) /* metro dependency 1779 */;
|
|
interpolate = moduleValue.interpolate;
|
|
CLAMP = Extrapolation.CLAMP;
|
|
value = (Reflect.apply(interpolate, moduleValue, [a0, items3, items2, CLAMP]) + value) % value;
|
|
r5 = value;
|
|
break reducibleJoin13;
|
|
}
|
|
interpolate = (require(1779) /* metro dependency 1779 */).interpolate;
|
|
const s = a2.s;
|
|
CLAMP = Extrapolation.CLAMP;
|
|
value = Reflect.apply(interpolate, value, [a0, a1, s, CLAMP]);
|
|
const moduleValue2 = require(1779) /* metro dependency 1779 */;
|
|
interpolate = moduleValue2.interpolate;
|
|
const v = a2.v;
|
|
CLAMP = Extrapolation.CLAMP;
|
|
const value5 = Reflect.apply(interpolate, moduleValue2, [a0, a1, v, CLAMP]);
|
|
const moduleValue3 = moduleValue2;
|
|
interpolate = moduleValue3.interpolate;
|
|
const a = a2.a;
|
|
CLAMP = Extrapolation.CLAMP;
|
|
return (Module01653Module).hsvToColor(r5, value, value5, Reflect.apply(interpolate,
|
|
moduleValue3, [a0, a1, a, CLAMP]));
|
|
}
|
|
|
|
function toLinearSpace_19576(a0, a1) { // fn#19576, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:2387, offset: 0x00eae25a, size: 29 bytes, params: 3, frame: 11
|
|
const env0_0 = a1;
|
|
return a0.map(function(a0) {
|
|
var Math = global.Math;
|
|
return Math.pow(a0 / 255, require);
|
|
});
|
|
function _fun19577(a0) { // fn#19577, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:2440, offset: 0x00eae277, size: 39 bytes, params: 2, frame: 13
|
|
const Math = global.Math;
|
|
return Math.pow(a0 / 255, require);
|
|
}
|
|
|
|
}
|
|
|
|
function pnpm_interpolateColorTs4(a0, a1, {r, g, b, a}, {gamma}) { // fn#19579, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:3545, offset: 0x00eae2d8, size: 428 bytes, params: 5, frame: 27
|
|
var r6;
|
|
var r9;
|
|
var r15;
|
|
var r0;
|
|
var toLinearSpace_19576Binding;
|
|
var value2;
|
|
var value3;
|
|
var moduleValue5;
|
|
var rgbaColor;
|
|
var toGammaSpace_19578Binding;
|
|
let value = 2.2;
|
|
const r12 = gamma === undefined ? value : gamma;
|
|
if (r12 === 1) {
|
|
r6 = r;
|
|
r9 = g;
|
|
r15 = b;
|
|
} else {
|
|
toLinearSpace_19576Binding = toLinearSpace_19576;
|
|
value = toLinearSpace_19576Binding(r, r12);
|
|
value2 = toLinearSpace_19576Binding(g, r12);
|
|
value3 = toLinearSpace_19576Binding(b, r12);
|
|
r6 = value;
|
|
r9 = value2;
|
|
r15 = value3;
|
|
}
|
|
let interpolate = Module01779Module.interpolate;
|
|
const Extrapolation = Module01779Module.Extrapolation;
|
|
let CLAMP = Extrapolation.CLAMP;
|
|
const value4 = Reflect.apply(interpolate, Module01779Module, [a0, a1, r6, CLAMP]);
|
|
interpolate = Module01779Module.interpolate;
|
|
CLAMP = Extrapolation.CLAMP;
|
|
const value5 = Reflect.apply(interpolate, Module01779Module, [a0, a1, r9, CLAMP]);
|
|
interpolate = Module01779Module.interpolate;
|
|
CLAMP = Extrapolation.CLAMP;
|
|
const value6 = Reflect.apply(interpolate, Module01779Module, [a0, a1, r15, CLAMP]);
|
|
interpolate = Module01779Module.interpolate;
|
|
CLAMP = Extrapolation.CLAMP;
|
|
const value7 = Reflect.apply(interpolate, Module01779Module, [a0, a1, a, CLAMP]);
|
|
if (r12 === 1) {
|
|
value = require(1653) /* metro dependency 1653 */;
|
|
value = value.rgbaColor(value4, value5, value6, value7);
|
|
r0 = value;
|
|
} else {
|
|
moduleValue5 = require(1653) /* metro dependency 1653 */;
|
|
rgbaColor = moduleValue5.rgbaColor;
|
|
toGammaSpace_19578Binding = toGammaSpace_19578;
|
|
value = toGammaSpace_19578Binding(value4, r12);
|
|
value = Reflect.apply(rgbaColor, moduleValue5, [value, toGammaSpace_19578Binding(value5, r12),
|
|
toGammaSpace_19578Binding(value6, r12), value7]);
|
|
r0 = value;
|
|
}
|
|
return r0;
|
|
}
|
|
|
|
function pnpm_interpolateColorTs5(a0, a1, {l, a, b, alpha}, a3) { // fn#19580, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:4770, offset: 0x00eae484, size: 353 bytes, params: 5, frame: 25
|
|
let interpolate = Module01779Module.interpolate;
|
|
const Extrapolation = Module01779Module.Extrapolation;
|
|
let CLAMP = Extrapolation.CLAMP;
|
|
const value2 = Reflect.apply(interpolate, Module01779Module, [a0, a1, l, CLAMP]);
|
|
interpolate = Module01779Module.interpolate;
|
|
CLAMP = Extrapolation.CLAMP;
|
|
const value3 = Reflect.apply(interpolate, Module01779Module, [a0, a1, a, CLAMP]);
|
|
interpolate = Module01779Module.interpolate;
|
|
CLAMP = Extrapolation.CLAMP;
|
|
const value4 = Reflect.apply(interpolate, Module01779Module, [a0, a1, b, CLAMP]);
|
|
interpolate = Module01779Module.interpolate;
|
|
CLAMP = Extrapolation.CLAMP;
|
|
const value5 = Reflect.apply(interpolate, Module01779Module, [a0, a1, alpha, CLAMP]);
|
|
const convert = (Module01780).oklab.convert;
|
|
const value = convert.toRgb({l: value2, a: value3, b: value4, alpha: value5});
|
|
return (Module01653Module).rgbaColor(value.r, value.g, value.b, value.alpha);
|
|
}
|
|
|
|
function _splitColorsIntoChannels(a0, a1) { // fn#19581, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:5977, offset: 0x00eae5e5, size: 297 bytes, params: 3, frame: 25
|
|
var r9;
|
|
var property;
|
|
var object;
|
|
var moduleValue;
|
|
var moduleValue2;
|
|
var moduleValue3;
|
|
var value3;
|
|
var push;
|
|
var ch1;
|
|
var ch2;
|
|
var ch3;
|
|
var moduleValue4;
|
|
var opacity;
|
|
const items5 = [];
|
|
const items2 = [];
|
|
const items3 = [];
|
|
const items4 = [];
|
|
let length = a0.length;
|
|
let value = 0;
|
|
if (value < length) {
|
|
r9 = value;
|
|
while (true) {
|
|
property = a0[r9];
|
|
value = require(1653) /* metro dependency 1653 */;
|
|
value = value.processColor(property);
|
|
if (typeof value === 'number') {
|
|
object = {};
|
|
moduleValue = require(1653) /* metro dependency 1653 */;
|
|
object.r = moduleValue.red(value);
|
|
moduleValue2 = require(1653) /* metro dependency 1653 */;
|
|
object.g = moduleValue2.green(value);
|
|
moduleValue3 = require(1653) /* metro dependency 1653 */;
|
|
object.b = moduleValue3.blue(value);
|
|
value3 = a1(object);
|
|
push = items5.push;
|
|
ch1 = value3.ch1;
|
|
Reflect.apply(push, items5, [ch1]);
|
|
push = items2.push;
|
|
ch2 = value3.ch2;
|
|
Reflect.apply(push, items2, [ch2]);
|
|
push = items3.push;
|
|
ch3 = value3.ch3;
|
|
Reflect.apply(push, items3, [ch3]);
|
|
push = items4.push;
|
|
moduleValue4 = require(1653) /* metro dependency 1653 */;
|
|
opacity = moduleValue4.opacity;
|
|
Reflect.apply(push, items4, [Reflect.apply(opacity, moduleValue4, [value])]);
|
|
}
|
|
value = typeof r9 === 'bigint' ? r9 + 1n : +r9 + 1;
|
|
length = a0.length;
|
|
if (value < length) {
|
|
r9 = value;
|
|
continue;
|
|
}
|
|
break;
|
|
}
|
|
}
|
|
return {ch1: items5, ch2: items2, ch3: items3, alpha: items4};
|
|
}
|
|
|
|
function pnpm_interpolateColorTs7(a0) { // fn#19582, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:6777, offset: 0x00eae70e, size: 70 bytes, params: 2, frame: 13
|
|
const value = _splitColorsIntoChannels(a0, function(a0) {
|
|
return {ch1: a0.r, ch2: a0.g, ch3: a0.b};
|
|
});
|
|
return {r: value.ch1, g: value.ch2, b: value.ch3, a: value.alpha};
|
|
}
|
|
|
|
function pnpm_interpolateColorTs8(a0) { // fn#19584, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:7349, offset: 0x00eae77a, size: 69 bytes, params: 2, frame: 13
|
|
const value = _splitColorsIntoChannels(a0, _fun19585);
|
|
return {h: value.ch1, s: value.ch2, v: value.ch3, a: value.alpha};
|
|
function _fun19585({r, g, b}) { // fn#19585, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:7397, offset: 0x00eae7bf, size: 91 bytes, params: 2, frame: 15
|
|
let value = environment.__proto__;
|
|
value = require(1653) /* metro dependency 1653 */;
|
|
value = value.RGBtoHSV(r, g, b);
|
|
return {ch1: value.h, ch2: value.s, ch3: value.v};
|
|
}
|
|
|
|
}
|
|
|
|
function pnpm_interpolateColorTs9(a0) { // fn#19586, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:7994, offset: 0x00eae81a, size: 71 bytes, params: 2, frame: 13
|
|
const value = _splitColorsIntoChannels(a0, _fun19587);
|
|
return {l: value.ch1, a: value.ch2, b: value.ch3, alpha: value.alpha};
|
|
function _fun19587(a0) { // fn#19587, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:8042, offset: 0x00eae861, size: 86 bytes, params: 2, frame: 11
|
|
let value = environment.__proto__;
|
|
value = (importDefault(1780) /* metro dependency 1780 */).oklab.convert.fromRgb(a0);
|
|
return {ch1: value.l, ch2: value.a, ch3: value.b};
|
|
}
|
|
|
|
}
|
|
|
|
function _fun19588() { // fn#19588, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:9007, offset: 0x00eae8b7, size: 112 bytes, params: 1, frame: 4
|
|
const interpolateColor2 = interpolateColor;
|
|
interpolateColor2.__closure = {interpolateColorsHSV: pnpm_interpolateColorTs1,
|
|
getInterpolateHSV: pnpm_interpolateColorTs8, interpolateColorsRGB: pnpm_interpolateColorTs4,
|
|
getInterpolateRGB: pnpm_interpolateColorTs7, interpolateColorsLAB: pnpm_interpolateColorTs5,
|
|
getInterpolateLAB: pnpm_interpolateColorTs9};
|
|
interpolateColor2.__workletHash = 10004340589678;
|
|
interpolateColor2.__initData = env0_12;
|
|
return interpolateColor2;
|
|
function interpolateColor(a0, a1, a2) { // fn#19589, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:9024, offset: 0x00eae927, size: 282 bytes, params: 4, frame: 22
|
|
let value = 'RGB';
|
|
const r9 = arguments.length > 3 ? arguments[3] === undefined ? value : arguments[3] : value;
|
|
const r2 = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : {};
|
|
if (r9 === 'HSV') {
|
|
value = environment.__proto__;
|
|
return pnpm_interpolateColorTs1(a0, a1, pnpm_interpolateColorTs8(a2), r2);
|
|
}
|
|
if (value === r9) {
|
|
value = environment.__proto__;
|
|
return pnpm_interpolateColorTs4(a0, a1, pnpm_interpolateColorTs7(a2), r2);
|
|
}
|
|
if (r9 === 'LAB') {
|
|
value = environment.__proto__;
|
|
return pnpm_interpolateColorTs5(a0, a1, pnpm_interpolateColorTs9(a2), r2);
|
|
}
|
|
value = environment.__proto__;
|
|
const ReanimatedError = (Module01621Module).ReanimatedError;
|
|
value = 'Invalid color space provided: ' + r9 + ". Supported values are: ['RGB', 'HSV', 'LAB'].";
|
|
const value4 = Object.create(ReanimatedError.prototype, {constructor: {value: ReanimatedError}});
|
|
const reanimatedError = new ReanimatedError(value);
|
|
throw reanimatedError instanceof Object ? reanimatedError : value4;
|
|
}
|
|
|
|
}
|
|
|
|
function useInterpolateConfig(a0, a1) { // fn#19590, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1905:9786, offset: 0x00eaea41, size: 162 bytes, params: 3, frame: 17
|
|
const r4 = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : env0_13.RGB;
|
|
const r3 = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};
|
|
const useSharedValue = UseSharedValueModule.useSharedValue;
|
|
const object = {inputRange: a0, outputRange: a1, colorSpace: r4};
|
|
object.cache = (require(1654) /* metro dependency 1654 */).makeMutable(null);
|
|
object.options = r3;
|
|
return Reflect.apply(useSharedValue, UseSharedValueModule, [object]);
|
|
}
|
|
|
|
}
|
|
|
|
global.__d(_fun19574, 1778, [1779, 1653, 1780, 1621, 1762,
|
|
1654]) /* metro module 1778, dependencies: [1779, 1653, 1780, 1621, 1762, 1654] */;
|