mirror of
https://gitlab.com/comunic/comunicmobile
synced 2025-06-19 00:05:16 +00:00
Add counter on comment form
This commit is contained in:
@ -250,27 +250,33 @@ class _PostTileState extends State<PostTile> {
|
||||
// Comment input
|
||||
Expanded(
|
||||
child: TextField(
|
||||
// Comment max size
|
||||
maxLength: 255,
|
||||
maxLines: null,
|
||||
buildCounter: smartInputCounterWidgetBuilder,
|
||||
|
||||
controller: _commentController,
|
||||
onChanged: (s) => setState(() {}),
|
||||
onSubmitted: _canSubmitComment ? (s) => _submitComment() : null,
|
||||
decoration: InputDecoration(
|
||||
hintText: tr("New comment..."),
|
||||
hintStyle: TextStyle(color: Colors.grey, fontSize: 12),
|
||||
fillColor: Colors.white,
|
||||
filled: true,
|
||||
border: OutlineInputBorder(
|
||||
borderSide: BorderSide(width: 0.5, color: Colors.grey),
|
||||
borderRadius: BorderRadius.only(
|
||||
topLeft: Radius.circular(3),
|
||||
bottomLeft: Radius.circular(3),
|
||||
),
|
||||
gapPadding: 1),
|
||||
contentPadding: EdgeInsets.only(
|
||||
left: 10,
|
||||
right: 10,
|
||||
bottom: 5,
|
||||
top: 5,
|
||||
)),
|
||||
hintText: tr("New comment..."),
|
||||
hintStyle: TextStyle(color: Colors.grey, fontSize: 12),
|
||||
fillColor: Colors.white,
|
||||
filled: true,
|
||||
border: OutlineInputBorder(
|
||||
borderSide: BorderSide(width: 0.5, color: Colors.grey),
|
||||
borderRadius: BorderRadius.only(
|
||||
topLeft: Radius.circular(3),
|
||||
bottomLeft: Radius.circular(3),
|
||||
),
|
||||
gapPadding: 1),
|
||||
contentPadding: EdgeInsets.only(
|
||||
left: 10,
|
||||
right: 10,
|
||||
bottom: 5,
|
||||
top: 5,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
|
||||
|
Reference in New Issue
Block a user