Repository: flutter
Issue: Dynamically setting the height of the Flutter container causes the Flutter content to be stretched.
Labels: platform-ios,a: existing-apps,has reproducible steps,P2,team-ios,triaged-ios,found in release: 3.22,found in release: 3.24

### Steps to reproduce

on a native page, embed a Flutter container, and after Flutter completes its layout, notify the native side of the actual height of the Flutter container. Then, set up a transition animation for the change.

### Expected results

The Flutter UI will not be stretched.

### Actual results

The Flutter UI will be stretched.

### Code sample

https://github.com/zmtzawqlp/samples/commit/d5e61df956a19267fee8c0ec9a1db0718794b553


### Screenshots or Video

<details open>
<summary>Screenshots / Video demonstration</summary>

https://github.com/flutter/flutter/assets/16477333/02c99f2a-7364-4872-95e6-675d84bde77a




</details>


### Logs

<details open><summary>Logs</summary>

```console
[Paste your logs here]
```

</details>


### Flutter Doctor output

<details open><summary>Doctor output</summary>

```console
 [✓] Flutter (Channel stable, 3.22.2, on macOS 14.5 23F79 darwin-arm64, locale
    zh-Hans-CN)
    • Flutter version 3.22.2 on channel stable at
      /Users/zmtzawqlp/Documents/flutter/3.22.2
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 761747bfc5 (5 weeks ago), 2024-06-05 22:15:13 +0200
    • Engine revision edd8546116
    • Dart version 3.4.3
    • DevTools version 2.34.3
    • Pub download mirror https://pub.flutter-io.cn
    • Flutter download mirror https://storage.flutter-io.cn

[!] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /Users/zmtzawqlp/Library/Android/sdk
    • Platform android-34, build-tools 34.0.0
    • ANDROID_HOME = /Users/zmtzawqlp/Library/Android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 17.0.10+0-17.0.10b1087.21-11572160)
    ! Some Android licenses not accepted. To resolve this, run: flutter doctor
      --android-licenses

[✓] Xcode - develop for iOS and macOS (Xcode 15.4)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15F31d
    • CocoaPods version 1.15.2

[✗] Chrome - develop for the web (Cannot find Chrome executable at /Applications/Google
    Chrome.app/Contents/MacOS/Google Chrome)
    ! Cannot find Chrome. Try setting CHROME_EXECUTABLE to a Chrome executable.

[✓] Android Studio (version 2023.3)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.10+0-17.0.10b1087.21-11572160)

[✓] VS Code (version 1.90.2)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.92.0

[✓] Connected device (4 available)
    • MI 6 (mobile)                   • 5a4b233b                             • android-arm64 •
      Android 9 (API 28)
    • iPhone 15 Pro (mobile)          • C51B7932-C8F9-4F2C-939E-D2267C1289AA • ios           •
      com.apple.CoreSimulator.SimRuntime.iOS-17-5 (simulator)
    • macOS (desktop)                 • macos                                • darwin-arm64  •
      macOS 14.5 23F79 darwin-arm64
    • Mac Designed for iPad (desktop) • mac-designed-for-ipad                • darwin        •
      macOS 14.5 23F79 darwin-arm64
```

</details>