-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Closed
Labels
f: material designflutter/packages/flutter/material repository.flutter/packages/flutter/material repository.frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.r: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-designOwned by Design Languages teamOwned by Design Languages teamtriaged-designTriaged by Design Languages teamTriaged by Design Languages team
Description
Is there an existing issue for this?
- I have searched the existing issues
- I have read the guide to filing a bug
Steps to reproduce
Similar issue #86603.
Other failed workaround attempts were to
- Assign
clipBehaviourtoExpansionTile - Wrapped
InkWellwithborderRadius - Wrapped
ClipRRectwithborderRadius
The only workaround that worked is to wrap ExpansionTile with Card or Material suggested in this SO thread
The core underlying problem is the ListTile under the hood, which has seen many instances of the same problem. Usually the workaround is the wrap the ListTile in an InkWell however this is not possible with ExpansionTile.
- Run the sample code.
- Tap on the ListTile to see that the InkSplash doesn't clip the shape's borderRadius
I would like to help to resolve this issue but I am not clear on the proper way to fix this. Is passing the shape property to ListTile the correct move?
Expected results
InkSplash should not exceed shape's border
Actual results
InkSplash exceeds shape's border
Code sample
Code sample
import 'package:flutter/material.dart';
const Color darkBlue = Color.fromARGB(255, 18, 32, 47);
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
theme: ThemeData.dark().copyWith(
scaffoldBackgroundColor: darkBlue,
),
debugShowCheckedModeBanner: false,
home: Scaffold(
body: Center(
child: MyWidget(),
),
),
);
}
}
class MyWidget extends StatelessWidget {
@override
Widget build(BuildContext context) {
return ClipRRect(
clipBehavior: Clip.antiAlias,
borderRadius: BorderRadius.circular(20),
child: ExpansionTile(
clipBehavior: Clip.antiAlias,
shape: RoundedRectangleBorder(
side: const BorderSide(color: Colors.black, width: 3),
borderRadius: BorderRadius.circular(20),
),
collapsedShape: RoundedRectangleBorder(
side: const BorderSide(color: Colors.black, width: 3),
borderRadius: BorderRadius.circular(20),
),
title: const Text("InkSplash not respecting shape's borderRaidus"),
),
);
}
}
Screenshots or Video
Screenshots / Video demonstration
Screen.Recording.2023-05-01.at.12.07.20.PM.mov
Logs
Logs
[Paste your logs here]Flutter Doctor output
Doctor output
[✓] Flutter (Channel stable, 3.7.12, on macOS 13.3.1 22E261 darwin-arm64,
locale en-MY)
• Flutter version 3.7.12 on channel stable at /Users/samuel/Flutter/flutter
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision 4d9e56e694 (13 days ago), 2023-04-17 21:47:46 -0400
• Engine revision 1a65d409c7
• Dart version 2.19.6
• DevTools version 2.20.1
[✓] Android toolchain - develop for Android devices (Android SDK version
33.0.2)
• Android SDK at /Users/samuel/Library/Android/sdk
• Platform android-33, build-tools 33.0.2
• Java binary at: /Applications/Android
Studio.app/Contents/jbr/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build
17.0.6+0-17.0.6b802.4-9586694)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 14.3)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Build 14E222b
• CocoaPods version 1.12.1
[✓] Chrome - develop for the web
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Android Studio (version 2022.2)
• 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.6+0-17.0.6b802.4-9586694)
[✓] VS Code (version 1.77.3)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.62.0
[✓] Connected device (3 available)
• sdk gphone64 arm64 (mobile) • emulator-5554 • android-arm64 • Android 12
(API 31) (emulator)
• macOS (desktop) • macos • darwin-arm64 • macOS
13.3.1 22E261 darwin-arm64
• Chrome (web) • chrome • web-javascript • Google
Chrome 112.0.5615.137
! Error: Samuel’s iPhone is busy: Waiting to connect and unlock the device.
Xcode will continue when Samuel’s iPhone is finished. (code -10)
[✓] HTTP Host Availability
• All required HTTP hosts are available
• No issues found!bartekpacia, Nicoeevee and feinstein
Metadata
Metadata
Assignees
Labels
f: material designflutter/packages/flutter/material repository.flutter/packages/flutter/material repository.frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.r: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-designOwned by Design Languages teamOwned by Design Languages teamtriaged-designTriaged by Design Languages teamTriaged by Design Languages team
Type
Projects
Status
Done (PR merged)