I need to make the InkResponse Widget to have a rectangular highlight on click, How could i do so?
InkResponse(
highlightColor: Colors.amber,
onTap: () async {}
),
CodePudding user response:
You can use highlightShape parameter of InkResponse like highlightShape: BoxShape.rectangle,.
InkResponse(
highlightColor: Colors.amber,
highlightShape: BoxShape.rectangle,
onTap: () async {},
),
Does it solve in your case?
For more, visit InkResponse
CodePudding user response:
While both can be customized, it's easier to:
- Use
InkWellfor a rectangular ripple effect. - Use
InkResponsefor a circular ripple effect.
