File tree Expand file tree Collapse file tree 1 file changed +11
-20
lines changed
lib/data/view/chat/widgets Expand file tree Collapse file tree 1 file changed +11
-20
lines changed Original file line number Diff line number Diff line change @@ -22,7 +22,6 @@ class ChatMessageBubble extends StatefulWidget {
22
22
23
23
class _ChatMessageBubbleState extends State <ChatMessageBubble > {
24
24
bool _showFullText = false ;
25
- final _textController = TextEditingController ();
26
25
27
26
@override
28
27
void initState () {
@@ -32,12 +31,6 @@ class _ChatMessageBubbleState extends State<ChatMessageBubble> {
32
31
}
33
32
}
34
33
35
- @override
36
- void dispose () {
37
- _textController.dispose ();
38
- super .dispose ();
39
- }
40
-
41
34
@override
42
35
Widget build (BuildContext context) {
43
36
return Column (
@@ -147,23 +140,21 @@ class _ChatMessageBubbleState extends State<ChatMessageBubble> {
147
140
)
148
141
else
149
142
TypeWriterText (
150
- controller : _textController ,
151
- builder : (context, value) {
152
- return Text (
153
- value ,
154
- style: const TextStyle (
155
- color: Color (0xFFD1D5DB ),
156
- fontSize: 16 ,
157
- ),
158
- );
159
- } ,
160
- onComplete : () {
143
+ maintainSize : true ,
144
+ repeat : false ,
145
+ text : Text (
146
+ text ,
147
+ style: const TextStyle (
148
+ color: Color (0xFFD1D5DB ),
149
+ fontSize: 16 ,
150
+ ),
151
+ ),
152
+ duration : const Duration (milliseconds : 30 ) ,
153
+ onEnd : () {
161
154
setState (() {
162
155
_showFullText = true ;
163
156
});
164
157
},
165
- text: Text (text),
166
- duration: const Duration (milliseconds: 30 ),
167
158
),
168
159
if (! isUser) ...[
169
160
const Divider (color: Color (0xFF4D4D4D )),
You can’t perform that action at this time.
0 commit comments