From a2f8b375e128db0c5682582f9a2ab841db8680e4 Mon Sep 17 00:00:00 2001 From: niyari Date: Thu, 27 Jun 2024 21:46:23 +0900 Subject: [PATCH] Fix word-break in Daylight Saving label. --- .../Converters/Date/DateConverterGuiTool.cs | 28 ++++++++++++------- .../Date/DateConverterLayoutEnums.cs | 11 +++++++- 2 files changed, 28 insertions(+), 11 deletions(-) diff --git a/src/DevToys.Tools/Tools/Converters/Date/DateConverterGuiTool.cs b/src/DevToys.Tools/Tools/Converters/Date/DateConverterGuiTool.cs index 140000887..3d9f042a7 100644 --- a/src/DevToys.Tools/Tools/Converters/Date/DateConverterGuiTool.cs +++ b/src/DevToys.Tools/Tools/Converters/Date/DateConverterGuiTool.cs @@ -846,27 +846,35 @@ private IUICard DstInformation() .WithChildren( Grid() .Rows( - (DateConvertDstGridRow.Daylight, Auto), - (DateConvertDstGridRow.Offset, Auto), - (DateConvertDstGridRow.DateTime, Auto) + (DateConvertDstDaylightGridRow.Content, Auto) ) .Columns( - (DateConvertDstGridColumn.LeftTitle, new UIGridLength(1, UIGridUnitType.Fraction)), - (DateConvertDstGridColumn.LeftContent, new UIGridLength(1, UIGridUnitType.Fraction)), - (DateConvertDstGridColumn.RightTitle, new UIGridLength(1, UIGridUnitType.Fraction)), - (DateConvertDstGridColumn.RightContent, new UIGridLength(1, UIGridUnitType.Fraction)) + (DateConvertDstDaylightGridColumn.Content, new UIGridLength(1, UIGridUnitType.Fraction)) ) .Cells( Cell( - DateConvertDstGridRow.Daylight, - DateConvertDstGridColumn.LeftTitle, + DateConvertDstDaylightGridRow.Content, + DateConvertDstDaylightGridColumn.Content, Stack() .Vertical() .SmallSpacing() .WithChildren( _dstDaylightSavingLabel ) - ), + ) + ), + Grid() + .Rows( + (DateConvertDstGridRow.Offset, Auto), + (DateConvertDstGridRow.DateTime, Auto) + ) + .Columns( + (DateConvertDstGridColumn.LeftTitle, new UIGridLength(1, UIGridUnitType.Fraction)), + (DateConvertDstGridColumn.LeftContent, new UIGridLength(1, UIGridUnitType.Fraction)), + (DateConvertDstGridColumn.RightTitle, new UIGridLength(1, UIGridUnitType.Fraction)), + (DateConvertDstGridColumn.RightContent, new UIGridLength(1, UIGridUnitType.Fraction)) + ) + .Cells( Cell( DateConvertDstGridRow.Offset, DateConvertDstGridColumn.LeftTitle, diff --git a/src/DevToys.Tools/Tools/Converters/Date/DateConverterLayoutEnums.cs b/src/DevToys.Tools/Tools/Converters/Date/DateConverterLayoutEnums.cs index c2ce36bcb..0e3be6743 100644 --- a/src/DevToys.Tools/Tools/Converters/Date/DateConverterLayoutEnums.cs +++ b/src/DevToys.Tools/Tools/Converters/Date/DateConverterLayoutEnums.cs @@ -34,7 +34,6 @@ internal enum DateConverterGridTimeColumn internal enum DateConvertDstGridRow { - Daylight, Offset, DateTime } @@ -46,3 +45,13 @@ internal enum DateConvertDstGridColumn RightTitle, RightContent } + +internal enum DateConvertDstDaylightGridRow +{ + Content +} + +internal enum DateConvertDstDaylightGridColumn +{ + Content +}