Repository navigation
ヘッダーのdividerの影がboxShadow移行後に数px下へずれる問題を修正 - #6497
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01HNc6WmcBhgkxJP1Y5k1gCB
Contributor
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughHeaderEast と HeaderJRKyushu の Changesヘッダーの影位置の調整
Estimated code review effort: 1 (Trivial) | ~5 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
概要
#6491 で iOS 向けの影設定を RN の
boxShadowに置き換えて以降、ヘッダー下部の divider に付くべき影が数ピクセル下にずれて表示されるようになっていたのを修正します。原因は、影の指定がヘッダーのルート View に付いたままだったことです。旧来の iOS
shadowColor/shadowOffsetは(shadowPath未設定・背景色なしの View では)レイヤーが実際に描画した内容のアルファ形状から影を生成するため、影は divider の下端に密着していました。一方boxShadowは View のボーダーボックス基準で描画されます。ルート View はpaddingBottom: 4の透明領域を持つため、ボーダーボックス下端が divider より 4px 下になり、さらにoffsetY2px 分ずれて、divider と影の間に隙間が見える状態になっていました。変更の種類
変更内容
src/components/HeaderEast/config.ts:tokyoMetroConfigのboxShadowをrootStyleからdivider.extraStyleへ移動src/components/HeaderJRKyushu.tsx: 同じ構造・同じ症状だったため、boxShadowをstyles.rootからstyles.dividerへ移動paddingBottom: 4は据え置き影の値(
0px 2px 2px rgba(51, 51, 51, 0.25))自体は変更していません。tyConfigの divider(0px 2px 0px #ccc)は元から divider 側に付いていたため影響なし。他ヘッダーに legacy shadow 指定が残っていないことも確認済みです。テスト
npm run lintが通ることnpm testが通ることnpm run typecheckが通ることローカルでの実行結果:
npm run lint: Checked 601 files, No fixes appliednpm test: 199 suites / 2156 tests すべて passnpm run typecheck: エラーなしなお、シミュレータ・実機での目視確認は環境の都合で未実施です。UI の最終確認をお願いします。
関連Issue
スクリーンショット(任意)
🤖 Generated with Claude Code
https://claude.ai/code/session_01HNc6WmcBhgkxJP1Y5k1gCB
Generated by Claude Code
Summary by CodeRabbit