Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@

## [Unreleased]

### Added

- **`patches/expo-dev-menu@57.0.18.patch`** — Dev Menu 헤더의 앱 아이콘이 홈 화면과 같은 모양으로 나온다.
iOS 는 과한 cornerRadius(16/38pt) 가 배지 가장자리를 잘랐고, Android 는 adaptive 레이어를 마스크·크롭
없이 겹쳐 배지 위치가 어긋났다(dev 전용). 이력·조건은 `patches/README.md`

## [0.0.12] — 2026-09-28

### Added
Expand Down
42 changes: 37 additions & 5 deletions patches/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,12 @@ pnpm 패치. `pnpm-workspace.yaml` 의 `patchedDependencies` 에 등록돼 있

패치를 넣거나 뺄 때 한 줄씩 남긴다. 지운 것도 지우지 않는다 — 왜 있었는지가 다음 사람의 판단 근거다.

| 날짜 | 패키지 | 왜 | 상태 |
| ---------- | ----------------------------- | ---------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------ |
| 2026-09-15 | `expo@57.0.22` | Xcode 27 SDK 가 UIScene 을 요구 — AppDelegate 에 scene 진입점 주입 | **2026-09-16 제거.** 공식 `expo-build-properties` `ios.enableSceneSupport` 로 대체(v0.0.6) |
| 2026-09-17 | `@bacons/apple-targets@4.0.6` | 타깃이 이미 있는 prebuild(`--no-clean`)에서 크래시 — 아래 절 | **유지 중.** 업스트림 #206 미리뷰, 5.0.0 도 같음 |
| 2026-09-28 | `react-native@0.86.3` | 인스펙터 Touchables 토글이 앱 트리를 리마운트해 내비게이션·상태가 날아감 — 아래 절 | **유지 중.** 업스트림 PR #58705 리뷰 대기 |
| 날짜 | 패키지 | 왜 | 상태 |
| ---------- | ----------------------------- | -------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------ |
| 2026-09-15 | `expo@57.0.22` | Xcode 27 SDK 가 UIScene 을 요구 — AppDelegate 에 scene 진입점 주입 | **2026-09-16 제거.** 공식 `expo-build-properties` `ios.enableSceneSupport` 로 대체(v0.0.6) |
| 2026-09-17 | `@bacons/apple-targets@4.0.6` | 타깃이 이미 있는 prebuild(`--no-clean`)에서 크래시 — 아래 절 | **유지 중.** 업스트림 #206 미리뷰, 5.0.0 도 같음 |
| 2026-09-28 | `react-native@0.86.3` | 인스펙터 Touchables 토글이 앱 트리를 리마운트해 내비게이션·상태가 날아감 — 아래 절 | **유지 중.** 업스트림 PR #58705 리뷰 대기 |
| 2026-10-12 | `expo-dev-menu@57.0.18` | Dev Menu 헤더의 앱 아이콘이 홈 화면과 다르게 그려짐(iOS 과한 모서리, Android 마스크·크롭 없음) — 아래 절 | **유지 중.** 업스트림 미보고 |

## `@bacons/apple-targets@4.0.6`

Expand Down Expand Up @@ -65,3 +66,34 @@ grep -c useIsEnabled node_modules/react-native/Libraries/Pressability/Pressabili

**검증** — 시뮬레이터에서 첫 화면이 아닌 화면으로 이동 → Dev Menu → Toggle Element Inspector →
Touchables. 화면이 그대로 남고 터치 영역에 점선 박스가 나오면 살아 있다(패치 전에는 첫 화면으로 튕긴다).

## `expo-dev-menu@57.0.18`

**무엇** — Dev Menu(흔들면 뜨는 메뉴) 헤더의 앱 아이콘이 홈 화면 아이콘과 다르게 그려진다.

- iOS: `HeaderView.swift` 가 38pt 박스를 `cornerRadius: 16` 으로 자른다. 한 변의 42% 라 거의 원형이고
iOS 아이콘 마스크(약 22%)보다 훨씬 깊게 가장자리를 먹는다. `app-icon-badge` 의 하단 배너 양끝과 우상단
리본이 잘린다. 패치는 8.5pt(38 × 0.22)·continuous 로 바꾼다.
- Android: `AppIcon.kt` 가 `AdaptiveIconDrawable` 의 background·foreground 를 `LayerDrawable` 로 겹쳐
그대로 비트맵으로 그린다. 런처가 하는 마스크와 중앙 72/108 크롭이 빠져 108dp 캔버스 전체(여백 포함)가
보이고, 배지는 크롭을 전제로 그려져 있어 위치·크기가 어긋난다. 패치는 그 분기를 지우고
`AdaptiveIconDrawable` 이 스스로 그리게 한다(`toBitmap` → `draw` 가 마스크·크롭을 적용한다).

**언제 터지나** — dev client 에서 Dev Menu 를 열 때마다. 릴리즈 빌드에는 dev menu 가 없어 무관.
배지 없는 아이콘도 모양은 달라지지만 눈에 덜 띈다.

**동작 차이 하나** — Android 는 기기 런처의 마스크 모양(원·스쿼클)이 그대로 나온다. 홈 화면과 같다.

**업스트림** — 미보고. 올리면 같은 변경을 PR 로 낸다.

**지우는 조건** — expo-dev-menu 를 올린 뒤 패치 미적용 원본에서 아래 둘이 **모두 0** 이면 수정이 들어온
것이다. 그때 패치와 등록 줄을 지운다. 하나만 0 이면 그 플랫폼 쪽 hunk 만 걷어내고 재타깃한다.

```bash
grep -c "cornerRadius: 16" node_modules/expo-dev-menu/ios/SwiftUI/HeaderView.swift
grep -c LayerDrawable node_modules/expo-dev-menu/android/src/debug/java/expo/modules/devmenu/compose/primitives/AppIcon.kt
```

**검증** — dev/preview 빌드(배지 있음)로 Dev Menu 를 연다. 헤더 아이콘의 배너와 버전 리본이 홈 화면과
같은 비율로 온전히 보이면 살아 있다(패치 전에는 iOS 가 배너를 "EVELOPMEN" 으로 자르고, Android 는
아이콘이 작게 가운데 몰리며 배너가 과하게 크다).
66 changes: 66 additions & 0 deletions patches/expo-dev-menu@57.0.18.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
diff --git a/android/src/debug/java/expo/modules/devmenu/compose/primitives/AppIcon.kt b/android/src/debug/java/expo/modules/devmenu/compose/primitives/AppIcon.kt
index 62355ae84e5f4db1c689180beb0271018a6cb8d0..8ad83bd6ac55e88b2e00504131168a7f21430dc3 100644
--- a/android/src/debug/java/expo/modules/devmenu/compose/primitives/AppIcon.kt
+++ b/android/src/debug/java/expo/modules/devmenu/compose/primitives/AppIcon.kt
@@ -1,10 +1,6 @@
package expo.modules.devmenu.compose.primitives

-import android.graphics.drawable.AdaptiveIconDrawable
import android.graphics.drawable.BitmapDrawable
-import android.graphics.drawable.Drawable
-import android.graphics.drawable.LayerDrawable
-import android.os.Build
import androidx.compose.foundation.Image
import androidx.compose.foundation.background
import androidx.compose.foundation.layout.Box
@@ -44,23 +40,9 @@ fun AppIcon(
val image = remember {
val sizePx = with(density) { size.toPx() }.toInt()
val icon = context.packageManager.getApplicationIcon(context.applicationInfo)
- return@remember if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O && icon is AdaptiveIconDrawable) {
- val backgroundDr = icon.background
- val foregroundDr = icon.foreground
-
- val drr = arrayOfNulls<Drawable>(2)
- drr[0] = backgroundDr
- drr[1] = foregroundDr
-
- val layerDrawable = LayerDrawable(drr)
- val sizePx = with(density) { size.toPx() }.toInt()
- layerDrawable
- .toBitmap(
- width = sizePx,
- height = sizePx
- )
- .asImageBitmap()
- } else if (icon is BitmapDrawable) {
+ // AdaptiveIconDrawable.draw applies the launcher mask and the 72/108 crop, so the icon
+ // (and any badge on it) lands where it does on the home screen; stacking its layers skips both.
+ return@remember if (icon is BitmapDrawable) {
icon.bitmap.asImageBitmap()
} else {
icon
diff --git a/ios/SwiftUI/HeaderView.swift b/ios/SwiftUI/HeaderView.swift
index 5de3ceabd515a961e6758ed720a2be317d095c26..4089ff1a7d6f3e067394336f630fd8cf67ca7e37 100644
--- a/ios/SwiftUI/HeaderView.swift
+++ b/ios/SwiftUI/HeaderView.swift
@@ -21,7 +21,8 @@ struct HeaderView: View {
.resizable()
.scaledToFit()
.frame(width: 38, height: 38)
- .clipShape(RoundedRectangle(cornerRadius: 16))
+ // 38pt × ~0.22 (iOS icon ratio); 16 nearly makes a circle and chops the icon's edges
+ .clipShape(RoundedRectangle(cornerRadius: 8.5, style: .continuous))
}
#else
if let icon = appIcon {
@@ -29,7 +30,8 @@ struct HeaderView: View {
.resizable()
.scaledToFit()
.frame(width: 38, height: 38)
- .clipShape(RoundedRectangle(cornerRadius: 16))
+ // 38pt × ~0.22 (iOS icon ratio); 16 nearly makes a circle and chops the icon's edges
+ .clipShape(RoundedRectangle(cornerRadius: 8.5, style: .continuous))
}
#endif

Loading
Loading