@@ -149,10 +149,20 @@ class ContentPage extends BaseStlessWidget<ChatGptProvider> {
149
149
? CrossAxisAlignment .end
150
150
: CrossAxisAlignment .start,
151
151
children: [
152
- Text (
153
- messageEntity.isUser ? 'Question:' : 'GPT Answer:' ,
154
- style:
155
- const TextStyle (fontWeight: FontWeight .bold, color: Colors .white),
152
+ Container (
153
+ width: 48 ,
154
+ height: 48 ,
155
+ padding: const EdgeInsets .all (4 ),
156
+ decoration: BoxDecoration (
157
+ color: messageEntity.isUser
158
+ ? const Color (0xFF9aa37e )
159
+ : GlobalColors .success,
160
+ borderRadius: BorderRadius .circular (4 )),
161
+ alignment: Alignment .center,
162
+ child: Text (
163
+ messageEntity.isUser ? 'ME' : 'AI' ,
164
+ style: const TextStyle (color: Colors .white, fontSize: 20 ),
165
+ ),
156
166
),
157
167
const SizedBox (
158
168
height: 5 ,
@@ -180,35 +190,52 @@ class ContentPage extends BaseStlessWidget<ChatGptProvider> {
180
190
Row (
181
191
mainAxisSize: MainAxisSize .min,
182
192
children: [
183
- InkWell (
184
- child: AnimatedSwitcher (
185
- duration: const Duration (milliseconds: 200 ),
186
- child: Icon (
187
- viewModel.hasCopied
188
- ? Icons .check
189
- : Icons .copy_rounded,
190
- color: GlobalColors .success,
191
- size: 16 ,
192
- key: UniqueKey ()),
193
- ),
194
- onTap: () async {
195
- context
196
- .read <ChatGptProvider >()
197
- .copy (context, messageEntity.content);
198
- },
193
+ TextButton .icon (
194
+ onPressed: () async {
195
+ viewModel.copy (context, messageEntity.content);
196
+ },
197
+ icon: AnimatedSwitcher (
198
+ duration: const Duration (milliseconds: 200 ),
199
+ child: Icon (
200
+ viewModel.hasCopied
201
+ ? Icons .check
202
+ : Icons .copy_rounded,
203
+ color: GlobalColors .success,
204
+ size: 16 ,
205
+ key: UniqueKey ()),
206
+ ),
207
+ label: const Text (
208
+ 'Copy' ,
209
+ style: TextStyle (color: Colors .white),
210
+ )),
211
+ const SizedBox (
212
+ width: 10 ,
213
+ ),
214
+ TextButton .icon (
215
+ onPressed: () async {},
216
+ icon: const Icon (
217
+ Icons .link,
218
+ color: GlobalColors .success,
219
+ size: 16 ,
220
+ ),
221
+ label: const Text (
222
+ 'Copy Link' ,
223
+ style: TextStyle (color: Colors .white),
224
+ )),
225
+ const SizedBox (
226
+ width: 10 ,
199
227
),
200
- // SizedBox(width: 10,),
201
- // InkWell(
202
- // child: AnimatedSwitcher(
203
- // child: Icon(
204
- // Icons.wordpress,
205
- // key: UniqueKey()),
206
- // duration: Duration(milliseconds: 200),
207
- // ),
208
- // onTap: () async {
209
- //
210
- // },
211
- // ),
228
+ TextButton .icon (
229
+ onPressed: () async {},
230
+ icon: const Icon (
231
+ Icons .photo,
232
+ color: GlobalColors .success,
233
+ size: 16 ,
234
+ ),
235
+ label: const Text (
236
+ 'Save Image' ,
237
+ style: TextStyle (color: Colors .white),
238
+ ))
212
239
],
213
240
)
214
241
],
0 commit comments