From 9931e412e0ea2b044f92871a651cc5598bdc11f2 Mon Sep 17 00:00:00 2001 From: lawvs <18554747+lawvs@users.noreply.github.com> Date: Mon, 7 Jul 2025 16:54:43 +0800 Subject: [PATCH] refactor: remove Galeria component on iOS --- .../components/ui/image/galeria/index.ios.tsx | 70 ------------------- 1 file changed, 70 deletions(-) delete mode 100644 apps/mobile/src/components/ui/image/galeria/index.ios.tsx diff --git a/apps/mobile/src/components/ui/image/galeria/index.ios.tsx b/apps/mobile/src/components/ui/image/galeria/index.ios.tsx deleted file mode 100644 index 8fd766a5c..000000000 --- a/apps/mobile/src/components/ui/image/galeria/index.ios.tsx +++ /dev/null @@ -1,70 +0,0 @@ -import { requireNativeView } from "expo" -import { use, useMemo } from "react" -import { Image } from "react-native" - -import { GaleriaContext } from "./context" -import type { GaleriaViewProps } from "./types" - -const NativeImage = requireNativeView< - GaleriaViewProps & { - urls?: string[] - } ->("FollowGaleria") - -const noop = () => {} - -const Galeria = Object.assign( - function Galeria({ - children, - urls, - theme = "dark", - ids, - }: { - children: React.ReactNode - } & Partial>) { - return ( - ({ - urls, - theme, - initialIndex: 0, - open: false, - src: "", - setOpen: noop, - ids, - }), - [urls, theme, ids], - )} - > - {children} - - ) - }, - { - Image(props: GaleriaViewProps) { - const { urls, initialIndex } = use(GaleriaContext) - return ( - { - if (typeof url === "string") { - return url - } - - return Image.resolveAssetSource(url).uri - })} - index={initialIndex} - {...props} - /> - ) - }, - Popup: (() => null) as React.FC<{ - disableTransition?: "web" - }>, - }, -) - -export { Galeria }