diff --git a/demo/Ursa.Demo/Pages/TimePickerDemo.axaml b/demo/Ursa.Demo/Pages/TimePickerDemo.axaml
index ecdb17f..7c024c6 100644
--- a/demo/Ursa.Demo/Pages/TimePickerDemo.axaml
+++ b/demo/Ursa.Demo/Pages/TimePickerDemo.axaml
@@ -8,5 +8,7 @@
+
+
diff --git a/src/Ursa.Themes.Semi/Controls/TimePicker.axaml b/src/Ursa.Themes.Semi/Controls/TimePicker.axaml
index b6dd161..f294ab8 100644
--- a/src/Ursa.Themes.Semi/Controls/TimePicker.axaml
+++ b/src/Ursa.Themes.Semi/Controls/TimePicker.axaml
@@ -1,6 +1,7 @@
@@ -34,12 +35,12 @@
ShouldLoop="True" />
+ VerticalAlignment="Stretch"
+ Fill="{DynamicResource DateTimePickerSeparatorBackground}" />
+ VerticalAlignment="Stretch"
+ Fill="{DynamicResource DateTimePickerSeparatorBackground}" />
+ VerticalAlignment="Stretch"
+ Fill="{DynamicResource DateTimePickerSeparatorBackground}" />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/Ursa/Controls/DateTimePicker/TimePicker.cs b/src/Ursa/Controls/DateTimePicker/TimePicker.cs
index 9cacca4..83632a4 100644
--- a/src/Ursa/Controls/DateTimePicker/TimePicker.cs
+++ b/src/Ursa/Controls/DateTimePicker/TimePicker.cs
@@ -1,14 +1,32 @@
-using Avalonia;
+using System.Globalization;
+using Avalonia;
using Avalonia.Controls;
+using Avalonia.Controls.Metadata;
using Avalonia.Controls.Primitives;
using Avalonia.Data;
+using Avalonia.Input;
+using Avalonia.Interactivity;
using Irihi.Avalonia.Shared.Contracts;
+using Irihi.Avalonia.Shared.Helpers;
namespace Ursa.Controls;
-public class TimePicker : TemplatedControl, IClearControl
+[TemplatePart( PART_TextBox, typeof(TextBox))]
+[TemplatePart( PART_Popup, typeof(Popup))]
+[TemplatePart( PART_Presenter, typeof(TimePickerPresenter))]
+public class TimePicker : TemplatedControl, IClearControl, IInnerContentControl, IPopupInnerContent
{
- public static readonly StyledProperty DisplayFormatProperty = AvaloniaProperty.Register(
+ public const string PART_TextBox = "PART_TextBox";
+ public const string PART_Popup = "PART_Popup";
+ public const string PART_Presenter = "PART_Presenter";
+
+ private TextBox? _textBox;
+ private Popup? _popup;
+ private TimePickerPresenter? _presenter;
+
+ private bool _updateFromPresenter;
+
+ public static readonly StyledProperty DisplayFormatProperty = AvaloniaProperty.Register(
nameof(DisplayFormat), "HH:mm:ss");
public static readonly StyledProperty PanelFormatProperty = AvaloniaProperty.Register(
@@ -21,8 +39,40 @@ public class TimePicker : TemplatedControl, IClearControl
public static readonly StyledProperty NeedConfirmationProperty = AvaloniaProperty.Register(
nameof(NeedConfirmation));
- public static readonly StyledProperty IsLoopingProperty = AvaloniaProperty.Register(
- nameof(IsLooping));
+ public static readonly StyledProperty