2026-07-20 16:05:17 +00:00
// Module ID: 1733
2026-07-25 08:10:48 +00:00
// Function ID: 19445
2026-07-20 16:05:17 +00:00
// Name: pnpm_processBoxShadowTs1
2026-07-23 10:11:24 +00:00
// Dependencies: [1593]
2026-07-20 16:05:17 +00:00
// Module 1733 (pnpm_processBoxShadowTs1)
2026-07-23 10:11:24 +00:00
const require = arg1 ;
const dependencyMap = arg6 ;
2026-07-20 16:05:17 +00:00
/* worklet (recovered source) */ function pnpm _processBoxShadowTs1 ( value ) { return value . endsWith ( 'px' ) || ! isNaN ( Number ( value ) ) ; }
pnpm _processBoxShadowTs1 . _ _closure = { } ;
pnpm _processBoxShadowTs1 . _ _workletHash = 6091944631530 ;
pnpm _processBoxShadowTs1 . _ _initData = { code : "function pnpm_processBoxShadowTs1(value){return value.endsWith('px')||!isNaN(Number(value));}" } ;
let closure _3 = { code : "function parseBoxShadowString_Pnpm_processBoxShadowTs2(rawBoxShadows){const{isLength}=this.__closure;const result=[];for(const rawBoxShadow of rawBoxShadows.split(/,(?![^()]*\\))/).map(function(bS){return bS.trim();}).filter(function(bS){return bS!=='';})){const boxShadow={offsetX:0,offsetY:0};let offsetX=null;let offsetY=null;let keywordDetectedAfterLength=false;let lengthCount=0;const args=rawBoxShadow.split(/\\s+(?![^(]*\\))/);for(const arg of args){if(isLength(arg)){switch(lengthCount){case 0:offsetX=arg;lengthCount++;break;case 1:if(keywordDetectedAfterLength){return[];}offsetY=arg;lengthCount++;break;case 2:if(keywordDetectedAfterLength){return[];}boxShadow.blurRadius=arg;lengthCount++;break;case 3:if(keywordDetectedAfterLength){return[];}boxShadow.spreadDistance=arg;lengthCount++;break;default:return[];}}else if(arg==='inset'){if(boxShadow.inset){return[];}if(offsetX!==null){keywordDetectedAfterLength=true;}boxShadow.inset=true;continue;}else{if(boxShadow.color){return[];}if(offsetX!=null){keywordDetectedAfterLength=true;}boxShadow.color=arg;continue;}}if(offsetX===null||offsetY===null){return[];}boxShadow.offsetX=offsetX;boxShadow.offsetY=offsetY;result.push(boxShadow);}return result;}" } ;
2026-07-23 10:11:24 +00:00
let closure _4 = ( ( ) => {
2026-07-20 16:05:17 +00:00
function parseBoxShadowString ( str ) {
const items = [ ] ;
const parts = str . split ( /,(?![^()]*\))/ ) ;
const mapped = parts . map ( ( str ) => str . trim ( ) ) ;
const found = mapped . filter ( ( arg0 ) => "" !== arg0 ) ;
const iter = found [ Symbol . iterator ] ( ) ;
while ( iter !== undefined ) {
2026-07-23 10:11:24 +00:00
let obj = { offsetX : 0 , offsetY : 0 } ;
2026-07-20 16:05:17 +00:00
let tmp22 = null ;
let tmp20 = null ;
let flag = false ;
let num = 0 ;
let parts1 = str . split ( /\s+(?![^(]*\))/ ) ;
let tmp32 = parts1 ;
for ( const item10029 of parts1 ) {
let tmp33 = item10029 ;
2026-07-23 10:11:24 +00:00
let tmp34 = outer1 _2 ;
if ( outer1 _2 ( item10029 ) ) {
2026-07-20 16:05:17 +00:00
let tmp10 = num ;
if ( 0 === num ) {
tmp22 = item10029 ;
let tmp23 = num ;
num = num + 1 ;
} else if ( 1 === num ) {
let tmp19 = flag ;
if ( flag ) {
obj2 . return ( ) ;
iter . return ( ) ;
return [ ] ;
} else {
tmp20 = item10029 ;
let tmp21 = num ;
num = num + 1 ;
}
} else if ( 2 === num ) {
let tmp15 = flag ;
if ( flag ) {
obj2 . return ( ) ;
iter . return ( ) ;
return [ ] ;
} else {
let tmp16 = obj ;
let tmp17 = item10029 ;
obj . blurRadius = tmp33 ;
let tmp18 = num ;
num = num + 1 ;
}
} else if ( 3 === num ) {
let tmp11 = flag ;
if ( flag ) {
obj2 . return ( ) ;
iter . return ( ) ;
return [ ] ;
} else {
let tmp12 = obj ;
let tmp13 = item10029 ;
obj . spreadDistance = tmp33 ;
let tmp14 = num ;
num = num + 1 ;
}
} else {
obj2 . return ( ) ;
iter . return ( ) ;
return [ ] ;
}
2026-07-23 10:11:24 +00:00
continue ;
2026-07-20 16:05:17 +00:00
} else {
let tmp2 = item10029 ;
if ( "inset" === tmp33 ) {
let tmp7 = obj ;
if ( obj . inset ) {
obj2 . return ( ) ;
iter . return ( ) ;
return [ ] ;
} else {
let tmp8 = tmp22 ;
if ( null !== tmp22 ) {
flag = true ;
}
let tmp9 = obj ;
obj . inset = true ;
2026-07-23 10:11:24 +00:00
continue ;
2026-07-20 16:05:17 +00:00
}
} else {
let tmp3 = obj ;
if ( obj . color ) {
obj2 . return ( ) ;
iter . return ( ) ;
return [ ] ;
} else {
let tmp4 = tmp22 ;
if ( null != tmp22 ) {
flag = true ;
}
let tmp5 = obj ;
let tmp6 = item10029 ;
obj . color = tmp33 ;
}
}
}
continue ;
}
let tmp24 = tmp22 ;
if ( null !== tmp22 ) {
let tmp25 = tmp20 ;
if ( null !== tmp20 ) {
let tmp26 = obj ;
let tmp27 = tmp22 ;
obj . offsetX = tmp22 ;
let tmp28 = tmp20 ;
obj . offsetY = tmp20 ;
let tmp29 = items ;
let arr = items . push ( obj ) ;
2026-07-23 10:11:24 +00:00
continue ;
2026-07-20 16:05:17 +00:00
}
}
iter . return ( ) ;
return [ ] ;
}
return items ;
}
parseBoxShadowString . _ _closure = { isLength : pnpm _processBoxShadowTs1 } ;
parseBoxShadowString . _ _workletHash = 13799106280870 ;
parseBoxShadowString . _ _initData = closure _3 ;
return parseBoxShadowString ;
2026-07-23 10:11:24 +00:00
} ) ( ) ;
2026-07-20 16:05:17 +00:00
let closure _5 = { code : "function parseLength_Pnpm_processBoxShadowTs3(length){const{isLength}=this.__closure;const argsWithUnitsRegex=/([+-]?\\d*(\\.\\d+)?)([\\w\\W]+)?/g;const match=argsWithUnitsRegex.exec(length);if(!match||!isLength(length)){return null;}return Number(match[1]);}" } ;
2026-07-23 10:11:24 +00:00
let closure _6 = ( ( ) => {
2026-07-20 16:05:17 +00:00
function parseLength ( arg0 ) {
const match = /([+-]?\d*(\.\d+)?)([\w\W]+)?/g . exec ( arg0 ) ;
let NumberResult = null ;
if ( match ) {
NumberResult = null ;
2026-07-23 10:11:24 +00:00
if ( outer1 _2 ( arg0 ) ) {
2026-07-20 16:05:17 +00:00
const _Number = Number ;
NumberResult = Number ( match [ 1 ] ) ;
}
}
return NumberResult ;
}
parseLength . _ _closure = { isLength : pnpm _processBoxShadowTs1 } ;
parseLength . _ _workletHash = 16787390997763 ;
parseLength . _ _initData = closure _5 ;
return parseLength ;
2026-07-23 10:11:24 +00:00
} ) ( ) ;
2026-07-20 16:05:17 +00:00
let closure _7 = { code : "function processBoxShadow_Pnpm_processBoxShadowTs4(props){const{parseBoxShadowString,parseLength}=this.__closure;const result=[];const rawBoxShadows=props.boxShadow;if(rawBoxShadows===null){return result;}let boxShadowList;if(typeof rawBoxShadows==='string'){boxShadowList=parseBoxShadowString(rawBoxShadows.replace(/\\n/g,' '));}else if(Array.isArray(rawBoxShadows)){boxShadowList=rawBoxShadows;}else{throw new ReanimatedError(\"Box shadow value must be an array of shadow objects or a string. Received: \"+JSON.stringify(rawBoxShadows));}for(const rawBoxShadow of boxShadowList){const parsedBoxShadow={offsetX:0,offsetY:0};let value;for(const arg in rawBoxShadow){switch(arg){case'offsetX':value=typeof rawBoxShadow.offsetX==='string'?parseLength(rawBoxShadow.offsetX):rawBoxShadow.offsetX;if(value===null){return[];}parsedBoxShadow.offsetX=value;break;case'offsetY':value=typeof rawBoxShadow.offsetY==='string'?parseLength(rawBoxShadow.offsetY):rawBoxShadow.offsetY;if(value===null){return[];}parsedBoxShadow.offsetY=value;break;case'spreadDistance':value=typeof rawBoxShadow.spreadDistance==='string'?parseLength(rawBoxShadow.spreadDistance):rawBoxShadow.spreadDistance;if(value===null){return[];}parsedBoxShadow.spreadDistance=value;break;case'blurRadius':value=typeof rawBoxShadow.blurRadius==='string'?parseLength(rawBoxShadow.blurRadius):rawBoxShadow.blurRadius;if(value===null||value<0){return[];}parsedBoxShadow.blurRadius=value;break;case'color':parsedBoxShadow.color=rawBoxShadow.color;break;case'inset':parsedBoxShadow.inset=rawBoxShadow.inset;}}result.push(parsedBoxShadow);}props.boxShadow=result;}" } ;
2026-07-23 10:11:24 +00:00
arg5 . processBoxShadow = ( ( ) => {
2026-07-20 16:05:17 +00:00
function processBoxShadow ( boxShadow ) {
const items = [ ] ;
if ( null === boxShadow . boxShadow ) {
return items ;
} else {
if ( "string" === typeof str ) {
2026-07-23 10:11:24 +00:00
let tmp2 = outer1 _4 ( str . replace ( /\n/g , " " ) ) ;
2026-07-20 16:05:17 +00:00
} else {
const _Array = Array ;
tmp2 = str ;
if ( ! Array . isArray ( str ) ) {
2026-07-23 10:11:24 +00:00
const ReanimatedError = outer1 _0 ( outer1 _1 [ 0 ] ) . ReanimatedError ;
2026-07-20 16:05:17 +00:00
const _JSON = JSON ;
const _HermesInternal = HermesInternal ;
const prototype = ReanimatedError . prototype ;
const reanimatedError = new ReanimatedError ( "Box shadow value must be an array of shadow objects or a string. Received: " + JSON . stringify ( str ) ) ;
throw reanimatedError ;
}
}
const iter = tmp2 [ Symbol . iterator ] ( ) ;
const nextResult = iter . next ( ) ;
while ( iter !== undefined ) {
let tmp50 = nextResult ;
2026-07-23 10:11:24 +00:00
let obj = { offsetX : 0 , offsetY : 0 } ;
2026-07-20 16:05:17 +00:00
let tmp51 = nextResult ;
for ( const key10047 in nextResult ) {
let tmp52 = key10047 ;
if ( "offsetX" === key10047 ) {
let tmp39 = nextResult ;
if ( "string" === typeof tmp50 . offsetX ) {
2026-07-23 10:11:24 +00:00
let tmp41 = outer1 _6 ;
2026-07-20 16:05:17 +00:00
let tmp42 = nextResult ;
2026-07-23 10:11:24 +00:00
let offsetX = outer1 _6 ( tmp50 . offsetX ) ;
2026-07-20 16:05:17 +00:00
} else {
let tmp40 = nextResult ;
offsetX = tmp50 . offsetX ;
}
if ( null === offsetX ) {
iter . return ( ) ;
return [ ] ;
} else {
let tmp44 = obj ;
let tmp45 = offsetX ;
obj . offsetX = tmp43 ;
2026-07-23 10:11:24 +00:00
continue ;
2026-07-20 16:05:17 +00:00
}
} else {
if ( "offsetY" === key10047 ) {
let tmp32 = nextResult ;
if ( "string" === typeof tmp50 . offsetY ) {
2026-07-23 10:11:24 +00:00
let tmp34 = outer1 _6 ;
2026-07-20 16:05:17 +00:00
let tmp35 = nextResult ;
2026-07-23 10:11:24 +00:00
let offsetY = outer1 _6 ( tmp50 . offsetY ) ;
2026-07-20 16:05:17 +00:00
} else {
let tmp33 = nextResult ;
offsetY = tmp50 . offsetY ;
}
if ( null === offsetY ) {
iter . return ( ) ;
return [ ] ;
} else {
let tmp37 = obj ;
let tmp38 = offsetY ;
obj . offsetY = tmp36 ;
2026-07-23 10:11:24 +00:00
continue ;
2026-07-20 16:05:17 +00:00
}
} else {
if ( "spreadDistance" === key10047 ) {
let tmp25 = nextResult ;
if ( "string" === typeof tmp50 . spreadDistance ) {
2026-07-23 10:11:24 +00:00
let tmp27 = outer1 _6 ;
2026-07-20 16:05:17 +00:00
let tmp28 = nextResult ;
2026-07-23 10:11:24 +00:00
let spreadDistance = outer1 _6 ( tmp50 . spreadDistance ) ;
2026-07-20 16:05:17 +00:00
} else {
let tmp26 = nextResult ;
spreadDistance = tmp50 . spreadDistance ;
}
if ( null === spreadDistance ) {
iter . return ( ) ;
return [ ] ;
} else {
let tmp30 = obj ;
let tmp31 = spreadDistance ;
obj . spreadDistance = tmp29 ;
2026-07-23 10:11:24 +00:00
continue ;
2026-07-20 16:05:17 +00:00
}
} else {
if ( "blurRadius" === key10047 ) {
let tmp17 = nextResult ;
if ( "string" === typeof tmp50 . blurRadius ) {
2026-07-23 10:11:24 +00:00
let tmp19 = outer1 _6 ;
2026-07-20 16:05:17 +00:00
let tmp20 = nextResult ;
2026-07-23 10:11:24 +00:00
let blurRadius = outer1 _6 ( tmp50 . blurRadius ) ;
2026-07-20 16:05:17 +00:00
} else {
let tmp18 = nextResult ;
blurRadius = tmp50 . blurRadius ;
}
let tmp21 = blurRadius ;
if ( null !== blurRadius ) {
let tmp22 = blurRadius ;
if ( tmp21 >= 0 ) {
let tmp23 = obj ;
let tmp24 = blurRadius ;
obj . blurRadius = tmp21 ;
2026-07-23 10:11:24 +00:00
continue ;
2026-07-20 16:05:17 +00:00
}
}
iter . return ( ) ;
return [ ] ;
} else {
if ( "color" === key10047 ) {
let tmp15 = obj ;
let tmp16 = nextResult ;
obj . color = tmp50 . color ;
2026-07-23 10:11:24 +00:00
continue ;
2026-07-20 16:05:17 +00:00
} else {
if ( "inset" !== key10047 ) {
continue ;
} else {
let tmp13 = obj ;
let tmp14 = nextResult ;
obj . inset = tmp50 . inset ;
2026-07-23 10:11:24 +00:00
continue ;
2026-07-20 16:05:17 +00:00
}
continue ;
}
continue ;
}
continue ;
}
continue ;
}
continue ;
}
continue ;
}
let tmp46 = items ;
let tmp47 = obj ;
let arr = items . push ( obj ) ;
2026-07-23 10:11:24 +00:00
continue ;
2026-07-20 16:05:17 +00:00
}
boxShadow . boxShadow = items ;
}
}
processBoxShadow . _ _closure = { parseBoxShadowString : closure _4 , parseLength : closure _6 } ;
processBoxShadow . _ _workletHash = 5021783745910 ;
processBoxShadow . _ _initData = closure _7 ;
return processBoxShadow ;
2026-07-23 10:11:24 +00:00
} ) ( ) ;