💄 Optimize styles
This commit is contained in:
parent
6260e63b09
commit
43242de659
@ -225,7 +225,7 @@ class SolianMessages extends Translations {
|
|||||||
'accountStatusInvisible': 'Invisible',
|
'accountStatusInvisible': 'Invisible',
|
||||||
'accountStatusInvisibleDesc': 'Will show as offline, but all features still remain normal',
|
'accountStatusInvisibleDesc': 'Will show as offline, but all features still remain normal',
|
||||||
'accountStatusOffline': 'Offline',
|
'accountStatusOffline': 'Offline',
|
||||||
'accountLastSeenAt': 'Last seen at @date ago',
|
'accountLastSeenAt': '@date ago online',
|
||||||
'accountStatusLabel': 'Status Text',
|
'accountStatusLabel': 'Status Text',
|
||||||
'accountStatusClearAt': 'Clear At',
|
'accountStatusClearAt': 'Clear At',
|
||||||
'accountStatusNegative': 'Negative',
|
'accountStatusNegative': 'Negative',
|
||||||
|
@ -130,7 +130,7 @@ class _AccountStatusEditorDialogState extends State<AccountStatusEditorDialog> {
|
|||||||
int _attitude = 0;
|
int _attitude = 0;
|
||||||
DateTime? _clearAt;
|
DateTime? _clearAt;
|
||||||
bool _isInvisible = false;
|
bool _isInvisible = false;
|
||||||
bool _isSlient = false;
|
bool _isSilent = false;
|
||||||
|
|
||||||
final _labelController = TextEditingController();
|
final _labelController = TextEditingController();
|
||||||
final _clearAtController = TextEditingController();
|
final _clearAtController = TextEditingController();
|
||||||
@ -169,7 +169,7 @@ class _AccountStatusEditorDialogState extends State<AccountStatusEditorDialog> {
|
|||||||
_labelController.value.text,
|
_labelController.value.text,
|
||||||
_attitude,
|
_attitude,
|
||||||
clearAt: _clearAt,
|
clearAt: _clearAt,
|
||||||
isSilent: _isSlient,
|
isSilent: _isSilent,
|
||||||
isInvisible: _isInvisible,
|
isInvisible: _isInvisible,
|
||||||
isUpdate: widget.currentStatus != null,
|
isUpdate: widget.currentStatus != null,
|
||||||
);
|
);
|
||||||
@ -183,11 +183,14 @@ class _AccountStatusEditorDialogState extends State<AccountStatusEditorDialog> {
|
|||||||
void syncWidget() {
|
void syncWidget() {
|
||||||
if (widget.currentStatus != null) {
|
if (widget.currentStatus != null) {
|
||||||
_clearAt = widget.currentStatus!.clearAt;
|
_clearAt = widget.currentStatus!.clearAt;
|
||||||
_clearAtController.text = DateFormat('y/M/d HH:mm').format(_clearAt!);
|
if (_clearAt != null) {
|
||||||
|
_clearAtController.text = DateFormat('y/M/d HH:mm').format(_clearAt!);
|
||||||
|
}
|
||||||
|
|
||||||
_labelController.text = widget.currentStatus!.label;
|
_labelController.text = widget.currentStatus!.label;
|
||||||
_attitude = widget.currentStatus!.attitude;
|
_attitude = widget.currentStatus!.attitude;
|
||||||
_isInvisible = widget.currentStatus!.isInvisible;
|
_isInvisible = widget.currentStatus!.isInvisible;
|
||||||
_isSlient = widget.currentStatus!.isNoDisturb;
|
_isSilent = widget.currentStatus!.isNoDisturb;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -223,7 +226,7 @@ class _AccountStatusEditorDialogState extends State<AccountStatusEditorDialog> {
|
|||||||
onTapOutside: (_) =>
|
onTapOutside: (_) =>
|
||||||
FocusManager.instance.primaryFocus?.unfocus(),
|
FocusManager.instance.primaryFocus?.unfocus(),
|
||||||
),
|
),
|
||||||
const SizedBox(height: 16),
|
const SizedBox(height: 5),
|
||||||
TextField(
|
TextField(
|
||||||
controller: _clearAtController,
|
controller: _clearAtController,
|
||||||
readOnly: true,
|
readOnly: true,
|
||||||
@ -278,6 +281,7 @@ class _AccountStatusEditorDialogState extends State<AccountStatusEditorDialog> {
|
|||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
const SizedBox(height: 5),
|
||||||
SingleChildScrollView(
|
SingleChildScrollView(
|
||||||
scrollDirection: Axis.horizontal,
|
scrollDirection: Axis.horizontal,
|
||||||
child: Wrap(
|
child: Wrap(
|
||||||
@ -285,10 +289,10 @@ class _AccountStatusEditorDialogState extends State<AccountStatusEditorDialog> {
|
|||||||
runSpacing: 0,
|
runSpacing: 0,
|
||||||
children: [
|
children: [
|
||||||
ChoiceChip(
|
ChoiceChip(
|
||||||
selected: _isSlient,
|
selected: _isSilent,
|
||||||
label: Text('accountStatusSilent'.tr),
|
label: Text('accountStatusSilent'.tr),
|
||||||
onSelected: (val) {
|
onSelected: (val) {
|
||||||
setState(() => _isSlient = val);
|
setState(() => _isSilent = val);
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
ChoiceChip(
|
ChoiceChip(
|
||||||
|
@ -273,21 +273,24 @@ class _PostItemState extends State<PostItem> {
|
|||||||
attachmentsId: item.attachments ?? List.empty(),
|
attachmentsId: item.attachments ?? List.empty(),
|
||||||
divided: true,
|
divided: true,
|
||||||
),
|
),
|
||||||
PostQuickAction(
|
SizedBox(
|
||||||
isShowReply: widget.isShowReply,
|
width: MediaQuery.of(context).size.width * 0.9,
|
||||||
isReactable: widget.isReactable,
|
child: PostQuickAction(
|
||||||
item: widget.item,
|
isShowReply: widget.isShowReply,
|
||||||
onReact: (symbol, changes) {
|
isReactable: widget.isReactable,
|
||||||
setState(() {
|
item: widget.item,
|
||||||
item.reactionList[symbol] =
|
onReact: (symbol, changes) {
|
||||||
(item.reactionList[symbol] ?? 0) + changes;
|
setState(() {
|
||||||
});
|
item.reactionList[symbol] =
|
||||||
},
|
(item.reactionList[symbol] ?? 0) + changes;
|
||||||
).paddingOnly(
|
});
|
||||||
top: hasAttachment ? 10 : 6,
|
},
|
||||||
left: hasAttachment ? 24 : 60,
|
).paddingOnly(
|
||||||
right: 16,
|
top: hasAttachment ? 10 : 6,
|
||||||
bottom: 10,
|
left: hasAttachment ? 24 : 60,
|
||||||
|
right: 16,
|
||||||
|
bottom: 10,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
);
|
);
|
||||||
|
Loading…
Reference in New Issue
Block a user