fix: 评论框切换action时高度跳动
This commit is contained in:
@ -142,9 +142,10 @@ class _VideoReplyNewDialogState extends State<VideoReplyNewDialog>
|
|||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
double keyboardHeight = EdgeInsets.fromViewPadding(
|
double _keyboardHeight = EdgeInsets.fromViewPadding(
|
||||||
View.of(context).viewInsets, View.of(context).devicePixelRatio)
|
View.of(context).viewInsets, View.of(context).devicePixelRatio)
|
||||||
.bottom;
|
.bottom;
|
||||||
|
print('_keyboardHeight: $_keyboardHeight');
|
||||||
return Container(
|
return Container(
|
||||||
clipBehavior: Clip.hardEdge,
|
clipBehavior: Clip.hardEdge,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
@ -235,7 +236,11 @@ class _VideoReplyNewDialogState extends State<VideoReplyNewDialog>
|
|||||||
duration: const Duration(milliseconds: 300),
|
duration: const Duration(milliseconds: 300),
|
||||||
child: SizedBox(
|
child: SizedBox(
|
||||||
width: double.infinity,
|
width: double.infinity,
|
||||||
height: toolbarType == 'input' ? keyboardHeight : emoteHeight,
|
height: toolbarType == 'input'
|
||||||
|
? (_keyboardHeight > keyboardHeight
|
||||||
|
? _keyboardHeight
|
||||||
|
: keyboardHeight)
|
||||||
|
: emoteHeight,
|
||||||
child: EmotePanel(
|
child: EmotePanel(
|
||||||
onChoose: (package, emote) => onChooseEmote(package, emote),
|
onChoose: (package, emote) => onChooseEmote(package, emote),
|
||||||
),
|
),
|
||||||
|
Reference in New Issue
Block a user