TF-4233 Correctly set current label color on edit dialog open
This commit is contained in:
@@ -33,6 +33,13 @@ extension HandleLabelActionTypeExtension on LabelController {
|
||||
required AccountId? accountId,
|
||||
required Label label,
|
||||
}) async {
|
||||
if (accountId == null) {
|
||||
consumeState(
|
||||
Stream.value(Left(EditLabelFailure(NotFoundAccountIdException()))),
|
||||
);
|
||||
return;
|
||||
}
|
||||
|
||||
await DialogRouter().openDialogModal(
|
||||
child: CreateNewLabelModal(
|
||||
labels: labels,
|
||||
|
||||
@@ -76,6 +76,7 @@ class _CreateNewLabelModalState extends State<CreateNewLabelModal> {
|
||||
_nameInputController.text = selectedLabel.safeDisplayName;
|
||||
_nameInputFocusNode.requestFocus();
|
||||
_createLabelStateNotifier.value = true;
|
||||
_labelSelectedColorNotifier.value = _selectedColor;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user