2026-08-24 06:08:38 +00:00
|
|
|
// Module ID: 16530
|
|
|
|
|
// Function ID: 16531
|
2026-07-20 16:05:17 +00:00
|
|
|
// Name: MediaPlaybackPanelController
|
2026-08-24 06:08:38 +00:00
|
|
|
// Dependencies: [32, 19, 4669, 1390, 8701, 13970, 8740, 11490, 21, 4119, 1629, 16326, 13969, 589, 16531, 2]
|
2026-07-20 16:05:17 +00:00
|
|
|
// Exports: default
|
|
|
|
|
|
2026-08-24 06:08:38 +00:00
|
|
|
// Module 16530 (MediaPlaybackPanelController)
|
|
|
|
|
import closure_3 from "_slicedToArray" /* 32 */;
|
|
|
|
|
import closure_4 from "noop" /* 19 */;
|
|
|
|
|
import closure_5 from "maybeApplyNoTextColorForLightCustomTheme" /* 4669 */;
|
|
|
|
|
import closure_6 from "participantFromServer" /* 1390 */;
|
|
|
|
|
import closure_7 from "withEqualityFn" /* 8701 */;
|
|
|
|
|
import { MediaPlaybackPanelModes } from "MediaPlaybackPanelModes" /* 13970 */;
|
|
|
|
|
import { ActivityPanelModes } from "ActivityPanelModes" /* 8740 */;
|
|
|
|
|
import { MorphablePanelModes } from "MIN_PAN_GESTURE_MOVE" /* 11490 */;
|
|
|
|
|
import { jsx } from "jsxProd" /* 21 */;
|
2026-07-23 10:11:24 +00:00
|
|
|
|
|
|
|
|
const require = arg1;
|
2026-07-20 16:05:17 +00:00
|
|
|
let closure_12 = { code: "function MediaPlaybackPanelControllerTsx1(){const{mode,MediaPlaybackPanelModes,MorphablePanelModes}=this.__closure;switch(mode.get()){case MediaPlaybackPanelModes.PIP:{return MorphablePanelModes.PIP;}default:{return MorphablePanelModes.UNDEFINED;}}}" };
|
2026-08-24 06:08:38 +00:00
|
|
|
let result = require("set").fileFinishedImporting("modules/media_panel/native/MediaPlaybackPanelController.tsx");
|
2026-07-20 16:05:17 +00:00
|
|
|
|
|
|
|
|
export default function MediaPlaybackPanelController(children) {
|
2026-07-29 08:29:29 +00:00
|
|
|
let sharedValue;
|
|
|
|
|
let derivedValue;
|
|
|
|
|
let sharedValue1;
|
|
|
|
|
let sharedValue3;
|
|
|
|
|
let sharedValue2;
|
|
|
|
|
let useReducedMotion;
|
|
|
|
|
let sharedValue5;
|
|
|
|
|
let sharedValue4;
|
|
|
|
|
let sharedValue6;
|
2026-08-24 06:08:38 +00:00
|
|
|
closure_9 = undefined;
|
|
|
|
|
closure_10 = undefined;
|
2026-07-29 08:29:29 +00:00
|
|
|
let first;
|
2026-08-24 06:08:38 +00:00
|
|
|
closure_12 = undefined;
|
|
|
|
|
closure_13 = undefined;
|
|
|
|
|
closure_14 = undefined;
|
2026-07-29 08:29:29 +00:00
|
|
|
let stateFromStores;
|
|
|
|
|
sharedValue = undefined;
|
|
|
|
|
derivedValue = undefined;
|
|
|
|
|
let obj = sharedValue(sharedValue1[9]);
|
|
|
|
|
sharedValue = obj.useSharedValue(sharedValue6.PIP);
|
|
|
|
|
sharedValue1 = sharedValue(sharedValue1[9]).useSharedValue({ height: 0, width: 0 });
|
|
|
|
|
const obj3 = sharedValue(sharedValue1[9]);
|
|
|
|
|
sharedValue2 = sharedValue(sharedValue1[9]).useSharedValue({ x: -1, y: -1 });
|
|
|
|
|
const obj4 = sharedValue(sharedValue1[9]);
|
|
|
|
|
sharedValue3 = sharedValue(sharedValue1[9]).useSharedValue(useReducedMotion.useReducedMotion);
|
|
|
|
|
derivedValue = sharedValue3;
|
|
|
|
|
const items = [sharedValue3];
|
|
|
|
|
const effect = sharedValue2.useEffect(() => {
|
|
|
|
|
function onChange() {
|
2026-08-24 06:08:38 +00:00
|
|
|
const useReducedMotion = closure_1_5.useReducedMotion;
|
2026-07-29 08:29:29 +00:00
|
|
|
if (useReducedMotion !== closure_1.get()) {
|
|
|
|
|
const result = closure_1.set(useReducedMotion);
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
}
|
2026-08-24 06:08:38 +00:00
|
|
|
let result = closure_5.addReactChangeListener(onChange);
|
2026-07-29 08:29:29 +00:00
|
|
|
return () => {
|
2026-08-24 06:08:38 +00:00
|
|
|
const result = closure_5.removeReactChangeListener(onChange);
|
2026-07-20 16:05:17 +00:00
|
|
|
};
|
2026-07-29 08:29:29 +00:00
|
|
|
}, items);
|
|
|
|
|
const obj5 = sharedValue(sharedValue1[9]);
|
|
|
|
|
sharedValue4 = sharedValue(sharedValue1[9]).useSharedValue(true);
|
|
|
|
|
const obj6 = sharedValue(sharedValue1[9]);
|
|
|
|
|
sharedValue5 = sharedValue(sharedValue1[9]).useSharedValue(0);
|
|
|
|
|
const obj7 = sharedValue(sharedValue1[9]);
|
|
|
|
|
const fn = function p() {
|
|
|
|
|
if (sharedValue.get() === sharedValue6.PIP) {
|
|
|
|
|
let UNDEFINED = constants2.PIP;
|
|
|
|
|
} else {
|
|
|
|
|
UNDEFINED = constants2.UNDEFINED;
|
|
|
|
|
}
|
|
|
|
|
return UNDEFINED;
|
|
|
|
|
};
|
|
|
|
|
obj = { mode: sharedValue, MediaPlaybackPanelModes: sharedValue6, MorphablePanelModes: closure_10 };
|
|
|
|
|
fn.__closure = obj;
|
|
|
|
|
fn.__workletHash = 10375114450450;
|
2026-08-24 06:08:38 +00:00
|
|
|
fn.__initData = closure_12;
|
2026-07-29 08:29:29 +00:00
|
|
|
derivedValue = sharedValue(sharedValue1[9]).useDerivedValue(fn);
|
|
|
|
|
const obj8 = sharedValue(sharedValue1[9]);
|
|
|
|
|
const tmp8 = derivedValue(sharedValue1[10])();
|
|
|
|
|
const tmp9 = derivedValue(sharedValue1[11])(derivedValue(sharedValue1[10])());
|
|
|
|
|
sharedValue6 = sharedValue(sharedValue1[9]).useSharedValue(false);
|
|
|
|
|
const obj10 = sharedValue(sharedValue1[9]);
|
|
|
|
|
useReducedMotion = tmp9;
|
|
|
|
|
closure_9 = sharedValue(sharedValue1[9]).useSharedValue({ x: 0, y: 0, gestureActive: false });
|
|
|
|
|
closure_10 = sharedValue2.useRef(undefined);
|
|
|
|
|
const tmp11 = sharedValue3(sharedValue2.useState(sharedValue.get()), 2);
|
|
|
|
|
first = tmp11[0];
|
2026-08-24 06:08:38 +00:00
|
|
|
closure_12 = tmp13;
|
2026-07-29 08:29:29 +00:00
|
|
|
const items1 = [first, tmp11[1]];
|
|
|
|
|
closure_13 = sharedValue2.useCallback(() => {
|
|
|
|
|
let flag = first === sharedValue6.PIP;
|
2026-07-20 16:05:17 +00:00
|
|
|
if (flag) {
|
2026-08-24 06:08:38 +00:00
|
|
|
callback(tmp.DISMISSED);
|
2026-07-29 08:29:29 +00:00
|
|
|
derivedValue(sharedValue1[12]).userDidClosePip();
|
2026-07-20 16:05:17 +00:00
|
|
|
flag = true;
|
2026-07-29 08:29:29 +00:00
|
|
|
const obj = derivedValue(sharedValue1[12]);
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
|
|
|
|
return flag;
|
2026-07-29 08:29:29 +00:00
|
|
|
}, items1);
|
|
|
|
|
const tmp14 = sharedValue4((voicePanelsPIP) => voicePanelsPIP.voicePanelsPIP.size > 0);
|
2026-08-24 06:08:38 +00:00
|
|
|
closure_14 = tmp14;
|
2026-07-29 08:29:29 +00:00
|
|
|
const obj11 = sharedValue(sharedValue1[9]);
|
|
|
|
|
const items2 = [sharedValue5];
|
|
|
|
|
stateFromStores = sharedValue(sharedValue1[13]).useStateFromStores(items2, () => sharedValue5.getActivityPanelMode() === constants.PIP);
|
|
|
|
|
const items3 = [sharedValue4, tmp14, stateFromStores];
|
|
|
|
|
const layoutEffect = sharedValue2.useLayoutEffect(() => {
|
2026-08-24 06:08:38 +00:00
|
|
|
let tmp2 = !closure_14;
|
|
|
|
|
if (!closure_14) {
|
2026-07-20 16:05:17 +00:00
|
|
|
tmp2 = !stateFromStores;
|
|
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
const result = sharedValue4.set(tmp2);
|
|
|
|
|
}, items3);
|
2026-08-24 06:08:38 +00:00
|
|
|
return first(derivedValue(sharedValue1[14]).Provider, { value: sharedValue3(sharedValue2.useState(() => ({ mode: sharedValue, setMode: closure_12, morphablePanelMode: derivedValue, wrapperDimensions: sharedValue1, useReducedMotion: sharedValue3, pipState: sharedValue2, pipAvoidanceSpecs: closure_5, dismissToPipGestureRef: closure_10, dismissPanel: closure_13, scrollPosition: sharedValue5, canShowPIP: sharedValue4, lockScrolling: sharedValue6, wrapperOffset: closure_9 })), 1)[0], children: children.children });
|
2026-07-20 16:05:17 +00:00
|
|
|
};
|