import { Image, isWeb, useThemeName } from '@my/ui'
import { getBaseUrl } from 'app/utils/getBaseUrl'

export const JunwonLogoIcon = () => {
  const themeName = useThemeName()
  const isDarkMode = themeName.includes('dark')

  const baseUrl = getBaseUrl()

  let imageUri = isDarkMode ? `${baseUrl}/junwon-white.png` : `${baseUrl}/junwon-black.png`

  if (!isWeb) {
    imageUri = isDarkMode ? require(`./junwon-white.png`) : require(`./junwon-black.png`)
  }

  return (
    <Image
      source={{
        uri: imageUri,
        width: 48,
        height: 48,
      }}
    />
  )
}
