TF-4301 Address code review comments on label feature
- Make LabelModalMixin interactor getters non-nullable; remove force-unwraps at call sites - Show positiveLabel and add semanticLabel in progressing button for accessibility - Use timestamp-based label name in E2E scenario to prevent flakiness on reused accounts - Guard labelAs action with isLabelAvailable check in SingleEmailController - Don't pop back on label creation failure so users can retry without losing context - Block modal dismissal while label creation request is in flight - Null-guard email.id before toggling label in ThreadView::onCreateANewLabelAction - Log stackTrace and rethrow in DialogRouter to distinguish errors from user cancel
This commit is contained in:
@@ -41,8 +41,9 @@ class DialogRouter {
|
||||
);
|
||||
|
||||
return returnedValue;
|
||||
} catch (e) {
|
||||
logWarning('DialogRouter::pushGeneralDialog: Exception = $e');
|
||||
} catch (e, stackTrace) {
|
||||
logWarning('DialogRouter::pushGeneralDialog: Exception = $e\n$stackTrace');
|
||||
rethrow;
|
||||
} finally {
|
||||
if (PlatformInfo.isWeb) {
|
||||
_isMapDialogOpened.remove(routeName);
|
||||
@@ -112,8 +113,9 @@ class DialogRouter {
|
||||
barrierLabel: dialogLabel,
|
||||
pageBuilder: (_, __, ___) => child,
|
||||
);
|
||||
} catch (e) {
|
||||
logWarning('DialogRouter::openDialogModal: Exception = $e');
|
||||
} catch (e, stackTrace) {
|
||||
logWarning('DialogRouter::openDialogModal: Exception = $e\n$stackTrace');
|
||||
rethrow;
|
||||
} finally {
|
||||
if (PlatformInfo.isWeb && dialogLabel != null) {
|
||||
_isMapDialogOpened.remove(dialogLabel);
|
||||
|
||||
Reference in New Issue
Block a user