/* Metro module 11042; source: modules/gif_picker/native/GIFPickerItemView.tsx; dependencies: [31, 27, 33, 4501, 11035, 697, 1848, 4080, 11043, 1962, 1244, 5278, 5475, 2] */
import FastImage from '../../../components_native/common/FastImage.tsx'; /* Metro dependency 5475 */
import * as FileImportTrackerModule from '../../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as ReactModule from '../../../by-id/module-00031-React.js'; /* Metro dependency 31 */
import * as JsxRuntimeModule from '../../../by-id/module-00033-JsxRuntime.js'; /* Metro dependency 33 */
import * as KeyboardManagerUtilsModule from '../../../utils/native/KeyboardManagerUtils.tsx'; /* Metro dependency 1848 */
import * as CreateStylesModule from '../../../design/components/Styles/native/createStyles.tsx'; /* Metro dependency 4501 */
import * as PressablesModule from '../../../design/void/Pressables/native/Pressables.tsx'; /* Metro dependency 5278 */
import * as GIFPickerUtilsModule from './GIFPickerUtils.tsx'; /* Metro dependency 11035 */
function _fun84516(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#84516, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11228:6, offset: 0x01f4d9ad, size: 219 bytes, params: 8, frame: 19
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
let value = ReactModule;
const env0_6 = (CreateStylesModule).createStyles(_fun84517);
value = value.memo(_fun84518);
(FileImportTrackerModule).fileFinishedImporting('modules/gif_picker/native/GIFPickerItemView.tsx');
exports.default = _default_84519;
exports.GIFPickerItemPlaceholder = value;
function _fun84517(a0, a1, a2, a3) { // fn#84517, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11228:159, offset: 0x01f4da88, size: 255 bytes, params: 5, frame: 18
const object = {};
const object2 = {};
const GIF_PICKER_GUTTER_SPACING = (GIFPickerUtilsModule).GIF_PICKER_GUTTER_SPACING;
object2.paddingBottom = GIF_PICKER_GUTTER_SPACING;
const value2 = 0;
object2.paddingLeft = value2 === a1 ? value2 : GIF_PICKER_GUTTER_SPACING / 2;
object2.paddingRight = a1 === a0 - 1 ? value2 : GIF_PICKER_GUTTER_SPACING / 2;
object2.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.xs;
object2.width = a2;
object2.height = a3;
object2.flex = 1;
object.container = object2;
const object3 = {};
const BORDER_SUBTLE = (importDefault(697) /* metro dependency 697: native */).colors.BORDER_SUBTLE;
object3.backgroundColor = BORDER_SUBTLE;
object3.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.xs;
object3.flex = 1;
object.gifImage = object3;
return object;
}
function _fun84518(a0) { // fn#84518, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11228:508, offset: 0x01f4db87, size: 89 bytes, params: 2, frame: 18
const styles = useStyles(a0.columns, a0.columnIndex, a0.width, a0.height);
return (
);
}
function _default_84519({onPressGIF, item, index, columns, columnIndex, width, height}) { // fn#84519, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11228:655, offset: 0x01f4dbe0, size: 294 bytes, params: 2, frame: 23
const styles = useStyles(columns, columnIndex, width, height);
const binding = env0_3;
const value2 = binding.useCallback(_fun84520, [item, index, onPressGIF]);
const value3 = binding.useCallback(_fun84521, [item]);
const value4 = binding.useMemo(_fun84522, [index, item.src]);
const PressableOpacity = (PressablesModule).PressableOpacity;
return (
{((Component) => )(FastImage)}
);
function _fun84520() { // fn#84520, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11228:764, offset: 0x01f4dd06, size: 58 bytes, params: 1, frame: 13
onPressGIF(item, index);
const value = environment.__proto__;
(KeyboardManagerUtilsModule).dismissGlobalKeyboard();
}
function _fun84521() { // fn#84521, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11228:836, offset: 0x01f4dd40, size: 122 bytes, params: 1, frame: 20
let value = environment.__proto__;
const defaultImport = importDefault(dependencyMap[7]);
const openLazy = defaultImport.openLazy;
value = require(dependencyMap[9]);
value = value(dependencyMap[8], dependencyMap.paths);
Reflect.apply(openLazy, defaultImport, [value, 'GIFPickerItemActionSheet', {item: item}, 'stack']);
require(dependencyMap[6]).dismissGlobalKeyboard();
}
function _fun84522() { // fn#84522, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11228:977, offset: 0x01f4ddba, size: 154 bytes, params: 1, frame: 17
var value6;
var intl;
const value3 = item.src.split('/').pop();
let r0 = value3 == null ? undefined : value3.split('.')[0];
if (r0 == null) {
value6 = environment.__proto__;
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
r0 = intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t['5iIGZI'],
{index: index + 1});
}
return r0;
}
}
}
global.__d(_fun84516, 11042, [31, 27, 33, 4501, 11035, 697, 1848, 4080, 11043, 1962, 1244, 5278, 5475,
2]) /* metro module 11042, dependencies: [31, 27, 33, 4501, 11035, 697, 1848, 4080, 11043, 1962, 1244, 5278, 5475, 2] */;