Skip to content

Commit 57a4d1a

Browse files
authored
Merge pull request #224 from himanshugoyal77/fix-comment-box-color
Fix comment box color and text input
2 parents 6e8d592 + fea7630 commit 57a4d1a

File tree

4 files changed

+16
-2
lines changed

4 files changed

+16
-2
lines changed

lib/presentation/authentication/mobile/login_view_mobile.dart

+2-2
Original file line numberDiff line numberDiff line change
@@ -71,13 +71,13 @@ class _LoginViewMobileState extends State<LoginViewMobile> {
7171
ScaffoldMessenger.of(context).showSnackBar(
7272
SnackBar(
7373
content: Text(
74-
state.message,
74+
"Invalid email or password, please try again.",
7575
style: AppTextStyles.s14(
7676
color: AppColor.appWhite,
7777
fontType: FontType.MEDIUM,
7878
),
7979
),
80-
backgroundColor: AppColor.appSecondary,
80+
backgroundColor: AppColor.appWarningRed,
8181
),
8282
);
8383
}

lib/presentation/feed/desktop/widgets/feed_post_card.dart

+3
Original file line numberDiff line numberDiff line change
@@ -315,9 +315,11 @@ class _FeedPostCardState extends State<FeedPostCard>
315315
SizedBox(
316316
width: 430,
317317
child: TextFormField(
318+
cursorColor: AppColor.appPrimary,
318319
focusNode: commentFocusNode,
319320
controller: commentController,
320321
decoration: InputDecoration(
322+
focusColor: AppColor.appPrimary,
321323
suffixIcon: GestureDetector(
322324
onTap: () {
323325
locator<CommentsBloc>().add(
@@ -326,6 +328,7 @@ class _FeedPostCardState extends State<FeedPostCard>
326328
comment: commentController.text,
327329
),
328330
);
331+
commentController.clear();
329332
},
330333
child: Padding(
331334
padding: const EdgeInsets.all(8.0),

lib/presentation/feed/mobile/widgets/comment_bottom_sheet.dart

+10
Original file line numberDiff line numberDiff line change
@@ -213,9 +213,17 @@ class _CommentScreenState extends State<CommentScreen> {
213213
SizedBox(
214214
width: MediaQuery.sizeOf(context).width * 2.2 / 3,
215215
child: TextFormField(
216+
cursorColor: AppColor.appPrimary,
216217
focusNode: commentFocusNode,
217218
controller: commentController,
218219
decoration: InputDecoration(
220+
focusedBorder: const OutlineInputBorder(
221+
borderSide:
222+
BorderSide(color: AppColor.appPrimary, width: 2),
223+
borderRadius: BorderRadius.all(
224+
Radius.circular(20),
225+
),
226+
),
219227
suffixIcon: GestureDetector(
220228
onTap: () {
221229
locator<CommentsBloc>().add(
@@ -224,6 +232,8 @@ class _CommentScreenState extends State<CommentScreen> {
224232
comment: commentController.text,
225233
),
226234
);
235+
// clear the text field
236+
commentController.clear();
227237
},
228238
child: Padding(
229239
padding: const EdgeInsets.all(8.0),

lib/utils/app_colors.dart

+1
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,5 @@ class AppColor {
1212
static const Color appGrey = Color(0xFF4B5669);
1313
static const Color appTextGrey = Color(0xFF838B98);
1414
static const Color appTextLightGrey = Color(0xFF707988);
15+
static const Color appWarningRed = Color(0xFFE74C3C);
1516
}

0 commit comments

Comments
 (0)