decord/source/1691_unprocessProps.js

81 lines
2.4 KiB
JavaScript
Raw Normal View History

2026-07-20 16:05:17 +00:00
// Module ID: 1691
2026-07-24 07:16:23 +00:00
// Function ID: 18714
2026-07-20 16:05:17 +00:00
// Name: unprocessProps
2026-07-23 10:11:24 +00:00
// Dependencies: [1590, 1692]
2026-07-20 16:05:17 +00:00
// Module 1691 (unprocessProps)
2026-07-23 10:11:24 +00:00
const require = arg1;
const dependencyMap = arg6;
2026-07-20 16:05:17 +00:00
function unprocessProps(styleProps) {
2026-07-23 10:11:24 +00:00
const result = require(1692) /* pnpm_colorsTs1 */.unprocessColorsInProps(styleProps);
(function unprocessBoxShadow(boxShadow) {
2026-07-20 16:05:17 +00:00
if (Array.isArray(boxShadow.boxShadow)) {
boxShadow = boxShadow.boxShadow;
boxShadow.boxShadow = boxShadow.map((color) => {
2026-07-23 10:11:24 +00:00
const obj = { color: outer2_0(outer2_1[1]).unprocessColor(color.color) };
2026-07-20 16:05:17 +00:00
return Object.assign({}, color, obj);
});
}
2026-07-23 10:11:24 +00:00
})(styleProps);
2026-07-20 16:05:17 +00:00
}
2026-07-23 10:11:24 +00:00
let obj = {
viewsCount: 0,
2026-07-20 16:05:17 +00:00
viewsMap: new Map(),
2026-07-23 10:11:24 +00:00
intervalId: null,
2026-07-20 16:05:17 +00:00
registerView(componentViewTag, self) {
self = this;
const viewsMap = this.viewsMap;
if (!viewsMap.has(componentViewTag)) {
const viewsMap2 = self.viewsMap;
const result = viewsMap2.set(componentViewTag, self);
self.viewsCount = self.viewsCount + 1;
if (1 === self.viewsCount) {
self.registerInterval();
}
}
},
unregisterView(portal) {
const self = this;
const viewsMap = this.viewsMap;
viewsMap.delete(portal);
this.viewsCount = this.viewsCount - 1;
if (0 === this.viewsCount) {
self.unregisterInterval();
}
},
syncPropsBackToReact() {
2026-07-23 10:11:24 +00:00
const ReanimatedModule = require(1590) /* ReanimatedModule */.ReanimatedModule;
2026-07-20 16:05:17 +00:00
const settledUpdates = ReanimatedModule.getSettledUpdates();
const iter = settledUpdates[Symbol.iterator]();
const nextResult = iter.next();
while (iter !== undefined) {
let styleProps = nextResult.styleProps;
let viewsMap = this.viewsMap;
let tmp3 = styleProps;
let value = viewsMap.get(nextResult.viewTag);
let obj = value;
let tmp5 = unprocessProps;
let tmp6 = unprocessProps(styleProps);
if (null != value) {
let tmp7 = value;
let tmp8 = styleProps;
let result = obj._syncStylePropsBackToReact(tmp3);
}
2026-07-23 10:11:24 +00:00
continue;
2026-07-20 16:05:17 +00:00
}
},
registerInterval(arg0) {
const syncPropsBackToReact = this.syncPropsBackToReact;
this.intervalId = setInterval(syncPropsBackToReact.bind(this), 500);
},
unregisterInterval() {
const self = this;
if (null !== this.intervalId) {
const _clearInterval = clearInterval;
clearInterval(self.intervalId);
self.intervalId = null;
}
}
};
arg5.PropsRegistryGarbageCollector = obj;