resetToDefaults method
void
resetToDefaults()
Reset all drafts to application defaults.
Implementation
void resetToDefaults() {
draftFontSize.value = AppFontSize.medium;
draftFontFamily.value = AppFontFamily.system;
draftAccentColor.value = AppAccentColor.blue;
draftThemeMode.value = AppThemeMode.light;
draftPushNotifications.value = false;
draftBorderRadius.value = AppBorderRadius.medium;
draftLayoutDensity.value = AppLayoutDensity.comfortable;
draftSidebarColor.value = AppSidebarColor.darkCharcoal;
draftSidebarWidth.value = AppSidebarWidth.expanded;
draftCardElevation.value = AppCardElevation.medium;
draftAnimationsEnabled.value = true;
draftUiScale.value = AppUiScale.scale100;
draftGridSize.value = AppGridSize.cols3;
draftTableRowHeight.value = AppTableRowHeight.medium;
draftInputStyle.value = AppInputFieldStyle.outlined;
draftButtonStyle.value = AppButtonStyle.rounded;
draftNavigationStyle.value = AppNavigationStyle.sidebar;
draftAppBarStyle.value = AppAppBarStyle.minimalist;
draftContentWidth.value = AppContentWidth.standard;
draftShadowsEnabled.value = true;
draftUiStyle.value = AppUiStyle.material;
draftSidebarActiveColor.value = SidebarActiveColorOption.accent;
draftSidebarHoverColor.value = SidebarHoverColorOption.translucent;
draftSidebarIconSize.value = SidebarIconSizeOption.medium;
draftSidebarTransparency.value = false;
draftSidebarPosition.value = AppSidebarPosition.left;
draftCustomAccentColorHex.value = '#00457A';
draftCustomSidebarColorHex.value = '#0F172A';
draftCustomSidebarTextColorHex.value = '#FFFFFF';
draftAppBarHeight.value = AppAppBarHeight.standard;
draftAppBarShadow.value = AppAppBarShadow.subtle;
draftAppBarTitleAlignment.value = AppAppBarTitleAlignment.center;
draftDataGridTemplate.value = AppDataGridTemplate.defaultTemplate;
draftActionButtonShape.value = AppActionButtonShape.rounded;
draftActionButtonStyle.value = AppActionButtonStyle.outlined;
draftActionButtonColor.value = AppActionButtonColor.accent;
draftPageTransition.value = AppPageTransition.fadeIn;
draftFontLetterSpacing.value = AppFontLetterSpacing.balanced;
draftFontLineHeight.value = AppFontLineHeight.balanced;
draftLoaderType.value = AppLoaderType.waveSpinner;
draftLoaderColor.value = AppLoaderColor.accent;
draftCustomLoaderColorHex.value = '#00457A';
draftToastStyle.value = AppToastStyle.minimal;
// Apply previews immediately
fontSizeController.applyFontSizePreview(AppFontSize.medium);
fontSizeController.applyFontFamilyPreview(AppFontFamily.system);
fontSizeController.applyAccentColorPreview(AppAccentColor.blue);
fontSizeController.applyThemeModePreview(AppThemeMode.light);
fontSizeController.applyPushNotificationsPreview(false);
fontSizeController.applyBorderRadiusPreview(AppBorderRadius.medium);
fontSizeController.applyLayoutDensityPreview(AppLayoutDensity.comfortable);
fontSizeController.applySidebarColorPreview(AppSidebarColor.darkCharcoal);
fontSizeController.applySidebarWidthPreview(AppSidebarWidth.expanded);
fontSizeController.applyCardElevationPreview(AppCardElevation.medium);
fontSizeController.applyAnimationsEnabledPreview(true);
fontSizeController.applyUiScalePreview(AppUiScale.scale100);
fontSizeController.applyGridSizePreview(AppGridSize.cols3);
fontSizeController.applyTableRowHeightPreview(AppTableRowHeight.medium);
fontSizeController.applyInputStylePreview(AppInputFieldStyle.outlined);
fontSizeController.applyButtonStylePreview(AppButtonStyle.rounded);
fontSizeController.applyNavigationStylePreview(AppNavigationStyle.sidebar);
fontSizeController.applyAppBarStylePreview(AppAppBarStyle.minimalist);
fontSizeController.applyContentWidthPreview(AppContentWidth.standard);
fontSizeController.applyShadowsEnabledPreview(true);
fontSizeController.applyUiStylePreview(AppUiStyle.material);
fontSizeController.applySidebarActiveColorPreview(SidebarActiveColorOption.accent);
fontSizeController.applySidebarHoverColorPreview(SidebarHoverColorOption.translucent);
fontSizeController.applySidebarIconSizePreview(SidebarIconSizeOption.medium);
fontSizeController.applySidebarTransparencyPreview(false);
fontSizeController.applySidebarPositionPreview(AppSidebarPosition.left);
fontSizeController.applyCustomAccentColorPreview('#00457A');
fontSizeController.applyCustomSidebarColorPreview('#0F172A');
fontSizeController.applyCustomSidebarTextColorPreview('#FFFFFF');
fontSizeController.applyAppBarHeightPreview(AppAppBarHeight.standard);
fontSizeController.applyAppBarShadowPreview(AppAppBarShadow.subtle);
fontSizeController.applyAppBarTitleAlignmentPreview(AppAppBarTitleAlignment.center);
fontSizeController.applyDataGridTemplatePreview(AppDataGridTemplate.defaultTemplate);
fontSizeController.applyActionButtonShapePreview(AppActionButtonShape.rounded);
fontSizeController.applyActionButtonStylePreview(AppActionButtonStyle.outlined);
fontSizeController.applyActionButtonColorPreview(AppActionButtonColor.accent);
fontSizeController.applyPageTransitionPreview(AppPageTransition.fadeIn);
fontSizeController.applyFontLetterSpacingPreview(AppFontLetterSpacing.balanced);
fontSizeController.applyFontLineHeightPreview(AppFontLineHeight.balanced);
_applyThemeMode(AppThemeMode.system);
_checkUnsaved();
}